
/* SVD NEWS FIX V1 */

/* ===== Блок "Последние новости" ===== */

#news .section-head{
    display:flex !important;
    flex-direction:row !important;
    justify-content:space-between !important;
    align-items:flex-end !important;
    gap:30px !important;
    margin-bottom:30px !important;
}

#news .section-head > div{
    flex:1 1 auto !important;
}

#news .section-head h2{
    margin-bottom:0 !important;
}

#news .section-head > a.btn{
    position:static !important;
    display:inline-flex !important;
    flex:0 0 auto !important;
    width:auto !important;
    margin:0 !important;
    transform:none !important;
    float:none !important;
    white-space:nowrap !important;
}


/* ===== Карточка новости ===== */

#news .news-grid{
    display:grid !important;
    grid-template-columns:1fr !important;
    grid-template-rows:none !important;
    gap:20px !important;
}

#news article.news-card.svd-news-card{
    position:relative !important;
    display:block !important;
    width:100% !important;
    height:390px !important;
    min-height:390px !important;
    padding:0 !important;
    overflow:hidden !important;
    border-radius:26px !important;
    background-size:cover !important;
    background-position:center !important;
}

#news article.news-card.svd-news-card::before{
    content:"" !important;
    position:absolute !important;
    inset:0 !important;
    z-index:1 !important;
    background:linear-gradient(
        180deg,
        rgba(0,0,0,.05) 0%,
        rgba(0,0,0,.22) 45%,
        rgba(0,0,0,.88) 100%
    ) !important;
    pointer-events:none !important;
}

#news article.news-card.svd-news-card > a.svd-news-card__link{
    position:absolute !important;
    inset:0 !important;
    z-index:20 !important;
    display:block !important;
    width:100% !important;
    height:100% !important;
    pointer-events:auto !important;
}

#news article.news-card.svd-news-card > .svd-news-card__content{
    position:absolute !important;
    left:32px !important;
    right:32px !important;
    bottom:28px !important;
    z-index:10 !important;
    width:auto !important;
    min-height:0 !important;
    height:auto !important;
    padding:0 !important;
    pointer-events:none !important;
}

#news .svd-news-card__content h3{
    margin:8px 0 12px !important;
    color:#fff !important;
    font-size:clamp(28px,3vw,42px) !important;
    line-height:1.08 !important;
}

#news .svd-news-card__content .category{
    color:#d7b85f !important;
}

#news .svd-news-card__content time{
    color:rgba(255,255,255,.75) !important;
}


/* ===== Галерея внутри новости ===== */








/* ===== Телефон ===== */

@media(max-width:700px){

    #news .section-head{
        flex-direction:column !important;
        align-items:flex-start !important;
        gap:18px !important;
    }

    #news .section-head > a.btn{
        align-self:flex-start !important;
    }

    #news article.news-card.svd-news-card{
        height:285px !important;
        min-height:285px !important;
    }

    #news article.news-card.svd-news-card > .svd-news-card__content{
        left:21px !important;
        right:21px !important;
        bottom:21px !important;
    }

    #news .svd-news-card__content h3{
        font-size:25px !important;
    }

    
}


/* =====================================================
   СТРАНИЦА /NOVOSTI/
   ===================================================== */

.svd-news-archive .archive-head p{
    margin:12px 0 0;
    color:rgba(255,255,255,.68);
    font-size:16px;
}

.svd-news-archive-grid{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:24px;
}

.svd-news-archive-card{
    overflow:hidden;
    min-width:0;
    border-radius:22px;
    background:#fff;
    box-shadow:0 10px 35px rgba(20,30,23,.09);
    transition:transform .2s ease,box-shadow .2s ease;
}

.svd-news-archive-card:hover{
    transform:translateY(-4px);
    box-shadow:0 16px 42px rgba(20,30,23,.14);
}

.svd-news-archive-card__link{
    display:flex;
    flex-direction:column;
    height:100%;
    color:inherit;
    text-decoration:none;
}

.svd-news-archive-card__image{
    width:100%;
    aspect-ratio:16/10;
    background-size:cover;
    background-position:center;
    background-repeat:no-repeat;
}

.svd-news-archive-card__body{
    display:flex;
    flex-direction:column;
    flex:1;
    padding:22px;
}

.svd-news-archive-card__meta{
    margin-bottom:10px;
    color:#8b948d;
    font-size:12px;
    font-weight:700;
}

.svd-news-archive-card h2{
    margin:0 0 13px;
    color:#172019;
    font-size:23px;
    line-height:1.12;
}

.svd-news-archive-card p{
    margin:0 0 18px;
    color:#6b746d;
    font-size:14px;
    line-height:1.55;
}

.svd-news-archive-card__more{
    margin-top:auto;
    color:#89702e;
    font-size:13px;
    font-weight:800;
}

.svd-news-pagination{
    display:flex;
    justify-content:center;
    gap:7px;
    margin-top:45px;
}

.svd-news-pagination .page-numbers{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-width:42px;
    height:42px;
    padding:0 12px;
    border-radius:10px;
    background:#eef0ee;
    color:#202720;
    text-decoration:none;
}

.svd-news-pagination .page-numbers.current{
    background:#1b241d;
    color:#fff;
}

@media(max-width:1000px){
    .svd-news-archive-grid{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }
}

@media(max-width:650px){
    .svd-news-archive-grid{
        grid-template-columns:1fr;
    }

    .svd-news-archive-card h2{
        font-size:21px;
    }
}

/* =====================================================
   /СТРАНИЦА /NOVOSTI/
   ===================================================== */

/* ===== SVD TELEGRAM GALLERY FINAL ===== */

body.single-post .svd-news-content div.svd-tg-gallery{
    display:grid !important;
    grid-template-columns:repeat(3,minmax(0,1fr)) !important;
    grid-auto-rows:240px !important;
    grid-auto-flow:row !important;
    gap:14px !important;

    width:100% !important;
    max-width:960px !important;

    margin:36px auto 10px !important;
    padding:0 !important;
}

/* ВСЕ фотографии абсолютно одинаковые */
body.single-post .svd-news-content div.svd-tg-gallery > a,
body.single-post .svd-news-content div.svd-tg-gallery > a:nth-child(n),
body.single-post .svd-news-content div.svd-tg-gallery > a:first-child,
body.single-post .svd-news-content div.svd-tg-gallery > a:last-child{
    display:block !important;

    position:relative !important;

    grid-column:auto !important;
    grid-row:auto !important;

    width:auto !important;
    min-width:0 !important;

    height:auto !important;
    min-height:0 !important;

    margin:0 !important;
    padding:0 !important;

    overflow:hidden !important;
    border-radius:15px !important;

    float:none !important;
    clear:none !important;

    transform:none !important;
}

body.single-post .svd-news-content div.svd-tg-gallery > a > img{
    display:block !important;

    position:static !important;

    width:100% !important;
    height:100% !important;

    min-width:0 !important;
    max-width:none !important;
    min-height:0 !important;
    max-height:none !important;

    margin:0 !important;
    padding:0 !important;

    object-fit:cover !important;
    object-position:center !important;

    float:none !important;
    clear:none !important;

    transform:none !important;
    border-radius:0 !important;
}


/* ПЛАНШЕТ */

@media(max-width:900px){

    body.single-post .svd-news-content div.svd-tg-gallery{
        grid-template-columns:repeat(2,minmax(0,1fr)) !important;
        grid-auto-rows:240px !important;
    }
}


/* ТЕЛЕФОН */

@media(max-width:650px){

    body.single-post .svd-news-content div.svd-tg-gallery{
        grid-template-columns:1fr !important;
        grid-auto-rows:auto !important;
        gap:10px !important;
        margin-top:25px !important;
    }

    body.single-post .svd-news-content div.svd-tg-gallery > a,
    body.single-post .svd-news-content div.svd-tg-gallery > a:nth-child(n){
        width:100% !important;
        height:auto !important;
        aspect-ratio:4 / 3 !important;
    }
}

/* ===== /SVD TELEGRAM GALLERY FINAL ===== */

/* WordPress wpautop inserts BR between Telegram gallery items */
body.single-post .svd-tg-gallery > br{
    display:none !important;
}

/* ===== /SVD GALLERY BR FIX ===== */
