/* Compact global header + news feed redesign */

:root{
    --header-h:48px !important;
}

/* =========================
   COMPACT HEADER — ALL PAGES
   ========================= */
.header{
    height:var(--header-h) !important;
    overflow:hidden;
}

.header-inner{
    height:100%;
    padding:0 3.8vw !important;
    gap:12px !important;
}

.header .brand{
    height:100%;
    max-height:100%;
    display:flex;
    align-items:center;
    overflow:hidden;
    flex-shrink:0;
}

.header .brand-image{
    width:auto !important;
    height:34px !important;
    max-width:150px !important;
    max-height:34px !important;
    object-fit:contain !important;
    object-position:left center;
    flex-shrink:0;
}

.header .brand-description{
    max-width:168px !important;
    margin-left:4px !important;
    padding-left:12px !important;
    font-size:8px !important;
    line-height:1.25 !important;
}

.nav{
    gap:clamp(14px,1.45vw,25px) !important;
}

.nav a{
    padding:6px 0 !important;
    font-size:10px !important;
}

.nav a.active:after{
    bottom:0 !important;
}

.header-actions{
    gap:7px !important;
}

.search-toggle{
    width:30px !important;
    height:30px !important;
}

.search-toggle svg{
    width:15px !important;
    height:15px !important;
}

.header-cta{
    min-height:31px !important;
    padding:0 14px !important;
    gap:10px !important;
    font-size:9px !important;
}

.header-cta-arrow{
    font-size:13px !important;
}

.search-panel{
    top:44px !important;
}

/* =========================
   BOLD TITLES — ALL PAGES
   ========================= */
h1,
h2,
.home-title,
.about-title,
#services h2,
#news h2,
#vacancies h2{
    font-weight:700 !important;
}

.accent,
.home-title .accent,
.about-title .accent{
    font-weight:700 !important;
}

.home-services-title h3,
.service-card h3,
.news-card h3,
.vacancy-title,
.contact-form h3{
    font-weight:700 !important;
}

/* =========================
   NEWS — LATEST STORY + FEED
   ========================= */
#news{
    background:
        radial-gradient(circle at 78% 13%, color-mix(in srgb,var(--primary) 9%,transparent), transparent 30%),
        linear-gradient(112deg,#fff 0%,#fbfeff 60%,color-mix(in srgb,var(--primary) 6%,white) 100%);
}

#news .news-shell{
    height:calc(100vh - var(--header-h));
    min-height:600px;
    padding:14px 4vw 16px;
    display:flex;
    flex-direction:column;
    overflow:hidden;
}

#news .news-head{
    display:block;
    flex:0 0 auto;
    min-height:0;
}

#news .news-head > div:first-child{
    padding-left:1vw;
}

#news .eyebrow{
    margin-bottom:7px;
    letter-spacing:4px;
}

#news h2{
    margin:0;
    font-size:clamp(48px,4.25vw,70px);
    line-height:.94;
}

#news .lead{
    max-width:660px;
    margin:8px 0 0;
    font-size:12px;
    line-height:1.42;
}

/* Главное окно всегда показывает самую свежую новость. */
#news .news-banner{
    position:relative;
    width:100%;
    height:clamp(245px,33vh,355px);
    margin-top:10px;
    overflow:hidden;
    border-radius:20px;
    background:linear-gradient(135deg,#e7f3f7,color-mix(in srgb,var(--primary) 22%,white));
}

#news .news-banner::after{
    content:"";
    position:absolute;
    inset:0;
    z-index:1;
    pointer-events:none;
    background:linear-gradient(90deg,rgba(9,37,54,.54) 0%,rgba(9,37,54,.22) 42%,rgba(9,37,54,0) 72%);
}

#news .news-banner > img,
#news .news-feature-image{
    position:absolute;
    inset:0;
    width:100%;
    height:100%;
    object-fit:cover;
    object-position:center;
}

#news .news-feature-placeholder{
    position:absolute;
    inset:0;
    background:linear-gradient(135deg,#dcecf2,color-mix(in srgb,var(--primary) 25%,white));
}

#news .news-feature-content{
    position:absolute;
    z-index:3;
    left:clamp(22px,3vw,48px);
    bottom:clamp(18px,2.4vw,34px);
    width:min(520px,46%);
    padding:0;
    color:#fff;
    pointer-events:none;
}

#news .news-feature-content .news-meta-row{
    justify-content:flex-start;
    gap:10px;
    margin-bottom:8px;
}

#news .news-feature-content .news-date{
    color:rgba(255,255,255,.82);
    font-size:9px;
}

#news .news-feature-content .news-category{
    max-width:none;
    color:#fff;
    background:rgba(255,255,255,.16);
    border:1px solid rgba(255,255,255,.28);
    font-size:8px;
}

#news .news-feature-content h3{
    margin:0;
    color:#fff;
    font-size:clamp(20px,2vw,32px);
    line-height:1.08;
    font-weight:700;
}

#news .news-feature-content p{
    max-width:470px;
    margin:9px 0 0;
    color:rgba(255,255,255,.88);
    font-size:10px;
    line-height:1.45;
    display:-webkit-box;
    -webkit-line-clamp:2;
    -webkit-box-orient:vertical;
    overflow:hidden;
}

/* Лента начинается со второй по свежести новости. */
#news .news-feed-viewport{
    position:relative;
    margin-top:8px;
    width:100%;
    overflow:hidden;
    flex:1 1 auto;
    min-height:188px;
    max-height:245px;
}

#news .news-grid{
    margin:0 !important;
    display:flex !important;
    align-items:stretch;
    gap:1%;
    width:100%;
    height:100%;
    min-height:0;
    transition:transform .38s cubic-bezier(.2,.8,.2,1);
    will-change:transform;
}

#news .news-card{
    position:relative;
    flex:0 0 21.55%;
    min-width:0;
    height:100%;
    overflow:hidden;
    border:1px solid #dce9ed;
    border-radius:15px;
    background:rgba(255,255,255,.96);
    box-shadow:0 9px 28px rgba(23,56,76,.035);
    user-select:none;
    pointer-events:none;
    transition:filter .25s ease, opacity .25s ease, transform .25s ease;
}

#news .news-card.is-preview{
    filter:blur(3.3px);
    opacity:.76;
}

#news .news-image{
    height:43%;
    min-height:82px;
    background:linear-gradient(135deg,#e4f1f5,color-mix(in srgb,var(--primary) 16%,white));
}

#news .news-image img{
    width:100%;
    height:100%;
    object-fit:cover;
}

#news .news-card-body{
    padding:9px 11px 11px;
}

#news .news-meta-row{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:8px;
    margin-bottom:5px;
}

#news .news-date{
    color:#8ba0aa;
    font-size:8px;
}

#news .news-category{
    max-width:48%;
    padding:3px 8px;
    overflow:hidden;
    text-overflow:ellipsis;
    white-space:nowrap;
    border-radius:999px;
    color:var(--primary);
    background:color-mix(in srgb,var(--primary) 11%,white);
    font-size:7px;
    font-weight:600;
}

#news .news-card h3{
    min-height:31px;
    margin:0;
    color:#294a5c;
    font-size:11.5px;
    font-weight:700;
    line-height:1.32;
}

#news .news-card p{
    margin:6px 0 0;
    color:#8297a2;
    font-size:7.8px;
    line-height:1.42;
    display:-webkit-box;
    -webkit-line-clamp:2;
    -webkit-box-orient:vertical;
    overflow:hidden;
}

#news .news-feed-arrow{
    position:absolute;
    z-index:10;
    top:50%;
    width:44px;
    height:44px;
    display:grid;
    place-items:center;
    border:0;
    border-radius:50%;
    background:var(--primary);
    color:#fff;
    font-size:21px;
    line-height:1;
    cursor:pointer;
    transform:translateY(-50%);
    box-shadow:0 12px 30px rgba(23,56,76,.18);
    transition:transform .18s ease,opacity .18s ease,filter .18s ease;
}

#news .news-feed-arrow:hover{
    transform:translateY(-50%) scale(1.05);
    filter:brightness(.95);
}

#news .news-feed-arrow.next{
    right:3.2%;
}

#news .news-feed-arrow.prev{
    left:8px;
}

#news .news-feed-arrow[hidden]{
    display:none;
}

#news .news-feed-status{
    position:absolute;
    left:0;
    bottom:0;
    z-index:6;
    display:flex;
    align-items:center;
    gap:5px;
}

#news .news-feed-status[hidden]{
    display:none;
}

#news .news-feed-dot{
    width:5px;
    height:5px;
    border-radius:50%;
    background:#d4e4e9;
}

#news .news-feed-dot.active{
    width:8px;
    height:8px;
    background:var(--primary);
}

#news .news-empty{
    width:100%;
    min-height:180px;
    display:grid;
    place-items:center;
    color:#8297a2;
    border:1px solid #dce9ed;
    border-radius:16px;
    background:#fff;
    font-size:13px;
}

@media(max-height:820px){
    :root{--header-h:44px !important}
    .header .brand-image{width:auto !important;height:31px !important;max-width:138px !important;max-height:31px !important}
    #news .news-shell{padding-top:10px;padding-bottom:12px}
    #news h2{font-size:clamp(43px,4vw,60px)}
    #news .lead{margin-top:5px}
    #news .news-banner{height:clamp(205px,29vh,275px);margin-top:7px}
    #news .news-feed-viewport{min-height:168px;max-height:202px;margin-top:6px}
    #news .news-image{min-height:72px}
    #news .news-card-body{padding:7px 9px 9px}
    #news .news-card h3{font-size:10px;min-height:26px}
    #news .news-card p{font-size:7px;-webkit-line-clamp:2}
}

@media(max-width:1180px){
    .header .brand-image{width:auto !important;height:31px !important;max-width:132px !important;max-height:31px !important}
    .header .brand-description{display:none !important}
    .nav{gap:13px !important}
    .nav a{font-size:9px !important}
    #news .news-card{flex-basis:27.1%}
    #news .news-feature-content{width:min(500px,58%)}
}

@media(max-width:900px){
    :root{--header-h:58px !important}
    .header{height:58px !important}
    .header .brand-image{width:auto !important;height:38px !important;max-width:140px !important;max-height:38px !important}
    .header-cta{min-height:32px !important}
    #news .news-shell{height:auto;min-height:calc(100dvh - var(--header-h));padding:24px 20px 46px;overflow:visible}
    #news .news-banner{height:300px;min-height:300px;max-height:none;margin-top:14px}
    #news .news-feature-content{width:calc(100% - 40px);left:20px;bottom:20px}
    #news .news-feature-content h3{font-size:23px}
    #news .news-feed-viewport{min-height:310px;height:310px;max-height:none;flex-basis:310px;margin-top:12px}
    #news .news-card{flex-basis:76%}
    #news .news-image{height:150px}
    #news .news-feed-arrow.next{right:10px}
}
