/* =========================================================
   ГЛОБАЛЬНЫЕ НАСТРОЙКИ / СБРОС СТИЛЕЙ
   Тут задаются базовые переменные цвета, шрифты и сброс.
   ========================================================= */
:root {
    --color-bg: #ffffff;
    --color-text: #1a1a1a;
    --color-muted: #8a8a8a;
    --color-accent: #f1c40a;      /* жёлтый акцент баннера */
    --color-dark: #111111;        /* тёмный подвал */
    --color-ellipse: #e5e5e5;     /* серые декоративные эллипсы */
    

    --container: 1560px;
    --container-narrow: 1560px;

    /* боковой отступ (gutter) внутри контейнеров — единое значение для всех секций.
       Менять здесь → меняется одновременно в hero, about, features, banner. */
    --gutter: 60px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
    background: var(--color-bg);
    color: var(--color-text);
    font-family: 'Montserrat', Arial, sans-serif;
    font-weight: 400;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    /* защита от горизонтальной прокрутки:
       декоративные элементы (силуэт дрона, фоновая картинка about)
       могут вылезать за край viewport — скрываем их переполнение по X. */
    overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }
a   { color: inherit; text-decoration: none; }

/* =========================================================
   HERO (ШАПКА) — большой белый фон с дроном
   Контент: логотип слева, телефон справа, подзаголовок слева.
   Фоновая картинка: Media/big-header.jpg
   Чтобы изменить высоту — правь `min-height`.
   Чтобы сдвинуть текст внутри — правь `padding` у `.hero__inner`.
   ========================================================= */
.hero {
    position: relative;
    width: 100%;
    min-height: 720px;
    background: #ffffff url('Media/big-header.jpg') center center / cover no-repeat;
}

.hero__inner {
    max-width: var(--container);
    margin: 0 auto;
    padding: 32px var(--gutter) 0;
    position: relative;
}

/* верхняя строка: логотип + телефон */
.hero__top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;   /* выравнивание по верхней линии */
}

/* логотип-SVG в шапке (Media/SUVOROV_LOGO(ONLY TEXT).svg)
   высоту логотипа регулируем через `height` у img */
.hero__logo {
    display: flex;
    align-items: center;
    margin-top: 35px;
    margin-left: -10px;
}
.hero__logo img {
    height: 110px;
    width: auto;
    display: block;
}

.hero__phone {
    font-weight: 600;
    margin-top: 35px;   /* синхронно с .hero__logo, чтобы верхние края совпадали */
    font-size: 25px;
    color: #111;
    letter-spacing: .1px;
}

/* текст-описание под логотипом */
.hero__text {
    margin-top: 30px;
    max-width: 750px;
}

.hero__title {
    font-size: 25px;
    font-weight: 600;
    color: #3a3a3a;
    line-height: 1.2;
}

.hero__subtitle {
    font-size: 25px;
    font-weight: 600;
    color: #3a3a3a;    
    line-height: 1.2;
}

/* =========================================================
   QUOTE — блок с цитатой Суворова
   Круглый портрет слева, цитата справа.
   Отступы сверху/снизу правь через `padding` у `.quote`.
   ========================================================= */
.quote {
    padding: 00px 60px 80px;
}

.quote__inner {
    max-width: var(--container-narrow);
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 60px;
    justify-content: center;
}

/* круглый портрет Суворова: больше по размеру и с белым кольцом вокруг.
   Кольцо сделано через двойную box-shadow (внутренняя белая обводка + внешнее серое кольцо).
   Размер — `width/height`; толщина белого кольца — первая тень (inset).
   Толщина внешнего серого кольца — вторая тень. */
.quote__portrait {
    flex: 0 0 400px;
    width: 400px;
    height: 400px;
    margin-top: -100px;
    position: relative;
    z-index: 1;
    border-radius: 50%;
    overflow: hidden;
    background: #eee;
    border: 12px solid #ffffff;             /* белое кольцо вокруг фото */
    /*box-shadow: 0 0 0 1px #e5e5e5;         /* тонкая серая обводка снаружи */
    box-sizing: content-box;
}

.quote__portrait img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.quote__body {
    position: relative;
    padding-left: 10px;
    max-width: 700px;
}

/* крупные кавычки рядом с цитатой — шрифт Roboto (жирный),
   лежат абсолютно относительно `.quote__body`. */
.quote__mark {
    position: absolute;
    top: 55px;
    left: -10px;
    font-family: 'Roboto', Arial, sans-serif;
    font-size: 200px;
    line-height: 0.9;
    color: #1a1a1a;
    font-weight: 500;
}

.quote__text {
    font-style: italic;
    margin-top: 150px;
    font-size: 40px;
    font-weight: 580;
    color: #1a1a1a;
    line-height: 1.1;
}

.quote__author {
    margin-top: 14px;
    margin-right: -40px;
    text-align: right;
    font-style: italic;
    font-size: 40px;
    font-weight: 580;
    color: #1a1a1a;
}

/* =========================================================
   ABOUT (О НАС) — текст слева, изображение справа
   Слева — серые декоративные эллипсы (absolute).
   Чтобы сдвинуть/подправить эллипсы — меняй `.ellipse--N` ниже.
   ========================================================= */
.about {
    position: relative;
    padding: 60px var(--gutter) 120px;
    z-index: 0;
    margin: 0px 0 550px 0;
    /* overflow: visible — чтобы декоративный дрон мог вылезать за границы секции */
    overflow: visible;
}

.about__inner {
    /* было margin: 0 500px — жёстко фиксировало отступы.
       Теперь max-width + auto: на 2K (2560) отступы по 500px сохраняются автоматически,
       на FHD (1920) блок корректно центрируется.
       padding 0 60px — чтобы содержимое начиналось на одной линии с hero/features
       (у которых 60px padding задан на .hero__inner / .features). */
    max-width: var(--container-narrow);
    margin: 0 auto;
    padding: 0 var(--gutter);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
    position: relative;
    z-index: 2;
}

.about__title {
    font-size: 40px;
    font-weight: 800;
    letter-spacing: 1px;
    margin-bottom: 22px;
    color: #111;
}

.about__desc {
    font-size: 20px;
    font-weight: 600;
    line-height: 1.4;
    color: #2a2a2a;
    max-width: 500px;
}

/* фоновая картинка about — привязана к краям общей контентной колонки.
   left/right = позиция края контейнера + 60px (внутренний padding),
   так что картинка точно совпадает с левым/правым краем текста «О НАС» и карточек. */
.about__image {
    position: absolute;
    top: 40%;
    left:  max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter)));
    right: max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter)));
    pointer-events: none;
    z-index: -1;
}

.about__image img {
    width: 100%;
    height: auto;
    max-width: none;
    display: block;
    filter: contrast(1.25) brightness(1.05) saturate(1.15);
}

/* --- декоративная картинка дрона слева (Media/drone.svg) ---
   Position: absolute относительно `.about`.
   Размер регулируется `width`; положение — `top`/`left`.
   Цвет заливки в исходном SVG — чёрный, делаем его светло-серым
   через `filter` + прозрачность. */
.about__decor {
    position: absolute;
    /* параллакс: смещение по Y берётся из CSS-переменной, обновляется в JS.
       Поворот сохраняем здесь же, в одном transform. */
    --parallax-y: 0px;
    transform: translateY(var(--parallax-y)) rotate(-15deg);
    will-change: transform;
    top: -100px;
    left: -200px;
    width: 1500px;
    height: auto;
    z-index: 1;
    opacity: 0.07;
    pointer-events: none;
    user-select: none;
    filter: grayscale(1) brightness(1.7);
}

/* =========================================================
   BANNER — жёлтая плашка «НАШИ ВОЗМОЖНОСТИ»
   Короткая жёлтая полоса по левому краю контента.
   Положение и ширину правь через `.banner__label`.
   ========================================================= */
.banner {
    /* баннер теперь на всю ширину viewport — плашка внутри тянется
       до правого края экрана (как на макете). */
    padding: 0 0 60px;
    width: 100%;
}

.banner__label {
    display: inline-block;          /* справа обрезается по тексту + padding */
    background: var(--color-accent);
    color: #111;
    font-weight: 800;
    font-size: 40px;
    letter-spacing: 1px;
    /* padding-left рассчитывается автоматически:
       (ширина viewport − контейнер) / 2  даёт позицию левой границы контейнера,
       + 60px (внутренний отступ, как у .about__inner / .hero__inner)
       = текст плашки встаёт на одной линии с «О НАС» и карточками features.
       max() гарантирует минимум 60px даже на узких экранах. */
    padding: 14px 40px 14px max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter)));
}

/* =========================================================
   FEATURES — сетка карточек возможностей
   5 карточек в асимметричной сетке (как на макете).
   Сетка: 3 колонки × 3 ряда.
   Чтобы переставить карточки — меняй `grid-area` у каждой.
   ========================================================= */
.features {
    padding: 0 var(--gutter) 50px;
    max-width: var(--container);
    margin: 0 auto;
}

.features__grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    grid-template-rows: 400px 400px 400px;
    gap: 16px;
    grid-template-areas:
        "pilot    pilot    assembly"
        "med      hall     hall"
        "ai       hall     hall";
}

.feature {
    position: relative;
    overflow: hidden;
    display: block;
    background: #ddd;
    color: #fff;
}

.feature img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .4s ease;
}

.feature:hover img { transform: scale(1.04); }

/* градиент-штора сверху вниз — появляется при наведении на карточку.
   По умолчанию сдвинут вверх и прозрачен; на :hover плавно спускается. */
.feature::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg,
        rgba(0,0,0,0.85) 0%,
        rgba(0,0,0,0.65) 55%,
        rgba(0,0,0,0.0) 100%);
    opacity: 0;
    transform: translateY(-100%);
    transition: transform .55s ease, opacity .4s ease;
    z-index: 1;
    pointer-events: none;
}

.feature:hover::after {
    opacity: 1;
    transform: translateY(0);
}

.feature__caption {
    position: absolute;
    left: 20px;
    top: 18px;
    z-index: 2;
    max-width: 75%;
}

.feature__caption h3 {
    font-size: 25px;
    font-weight: 700;
    letter-spacing: 0.5px;
    line-height: 1.25;
    margin-bottom: 4px;
    color: #111;
}

/* описание карточки (<p>) — скрыто по умолчанию, плавно появляется на :hover */
.feature__caption p {
    font-size: 20px;
    font-weight: 500;
    color: #fff;
    line-height: 1.45;
    margin-top: 8px;
    max-width: 320px;

    opacity: 0;
    transform: translateY(-6px);
    transition: opacity .35s ease .05s, transform .4s ease .05s;
}

/* на ховере: заголовок становится белым, описание проявляется */
.feature:hover .feature__caption h3 {
    color: #fff;
    transition: color .3s ease;
}

.feature:hover .feature__caption p {
    opacity: 1;
    transform: translateY(0);
}

/* отдельный цвет заголовка для карточки «Тактическая медицина» (вне ховера) */
.feature--med .feature__caption h3 {
    color: #fff;
}

/* размещение карточек в сетке */
.feature--pilot    { grid-area: pilot; }
.feature--assembly { grid-area: assembly; }
.feature--med      { grid-area: med; }
.feature--hall     { grid-area: hall; }
.feature--ai       { grid-area: ai; }

/* =========================================================
   BRAND — центральный логотип «Суворов Центр»
   Иконка дрона + подпись. Просто центрируем блок.
   ========================================================= */
.brand {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px 20px 80px;
}

.brand__logo {
    width: 600px;
    height: auto;    
}

/* =========================================================
   FOOTER — тёмный подвал с адресом и копирайтом
   Контент отцентрирован. Высота регулируется `padding`.
   ========================================================= */
.footer {
    background: var(--color-dark);
    color: #cfcfcf;
    padding: 70px 20px 40px;
}

.footer__inner {
    max-width: 1420px;
    margin: 0 auto;
    text-align: left;
}

.footer__line {
    font-size: 25px;
    line-height: 1.4;
    color: #d7d7d7;
}

.footer__line--muted {
    margin-top: 16px;
    font-size: 20px;
    color: #8a8a8a;
    line-height: 1.4;
}

.footer__copy {
    margin-top: 40px;
    font-size: 20px;
    color: #b5b5b5;
}

/* =========================================================
   АДАПТИВ — ПЛАНШЕТЫ И УЗКИЕ ДЕСКТОПЫ (≤ 1200px)
   Уменьшаем шрифты и отступы, структура остаётся как на десктопе.
   ========================================================= */
@media (max-width: 1200px) {
    :root {
        --gutter: 32px;
    }

    /* Hero */
    .hero { min-height: 520px; }
    .hero__logo img { height: 72px; }
    .hero__phone { font-size: 18px; margin-top: 20px; }
    .hero__logo  { margin-top: 20px; }
    .hero__title,
    .hero__subtitle { font-size: 18px; }
    .hero__text { max-width: 520px; margin-top: 24px; }

    /* Quote */
    .quote__portrait { flex: 0 0 240px; width: 240px; height: 240px; margin-top: -60px; border-width: 8px; }
    .quote__body { max-width: 520px; }
    .quote__mark { font-size: 140px; top: 30px; }
    .quote__text { font-size: 28px; margin-top: 100px; }
    .quote__author { font-size: 28px; margin-right: 0; }

    /* About */
    .about { padding: 40px var(--gutter) 80px; margin-bottom: 320px; }
    .about__title { font-size: 30px; margin-bottom: 16px; }
    .about__desc { font-size: 16px; max-width: 420px; }
    .about__decor { width: 900px; left: -140px; top: -60px; }

    /* Banner */
    .banner__label { font-size: 26px; padding-top: 10px; padding-bottom: 10px; }

    /* Features */
    .features__grid {
        grid-template-rows: 260px 260px 260px;
        gap: 12px;
    }
    .feature__caption { left: 16px; top: 14px; }
    .feature__caption h3 { font-size: 18px; }
    .feature__caption p  { font-size: 15px; margin-top: 6px; }

    /* Brand */
    .brand { padding: 30px 20px 50px; }
    .brand__logo { width: 380px; }

    /* Footer */
    .footer { padding: 50px 24px 32px; }
    .footer__line { font-size: 17px; }
    .footer__line--muted { font-size: 14px; }
    .footer__copy { font-size: 14px; margin-top: 24px; }
}

/* =========================================================
   АДАПТИВ — МОБИЛЬНЫЕ УСТРОЙСТВА (≤ 700px)
   Структуру упрощаем: всё в одну колонку, декор скрываем.
   ========================================================= */
@media (max-width: 700px) {
    :root {
        --gutter: 16px;
    }

    /* Hero: логотип и телефон колонкой */
    .hero { min-height: 380px; }
    .hero__inner { padding: 20px var(--gutter) 0; }
    .hero__top {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    .hero__logo  { margin-top: 0; margin-left: 0; }
    .hero__logo img { height: 48px; }
    .hero__phone { margin-top: 0; font-size: 15px; }
    .hero__text { margin-top: 16px; max-width: 100%; }
    .hero__title,
    .hero__subtitle { font-size: 14px; }

    /* Quote: портрет сверху, текст снизу */
    .quote { padding: 60px var(--gutter) 40px; }
    .quote__inner {
        flex-direction: column;
        align-items: center;
        gap: 20px;
        text-align: center;
    }
    .quote__portrait {
        flex: 0 0 160px;
        width: 160px;
        height: 160px;
        margin-top: -40px;
        border-width: 6px;
    }
    .quote__body { max-width: 100%; padding-left: 0; }
    .quote__mark { display: none; }  /* кавычка съедает место */
    .quote__text {
        font-size: 20px;
        margin-top: 0;
        text-align: center;
    }
    .quote__text br { display: none; }
    .quote__author { font-size: 18px; text-align: center; margin-right: 0; }

    /* About: одна колонка, декор и фоновая картинка скрыты */
    .about {
        padding: 40px var(--gutter) 40px;
        margin-bottom: 0;
    }
    .about__inner {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 0 var(--gutter);
    }
    .about__title { font-size: 22px; letter-spacing: 0; margin-bottom: 10px; }
    .about__desc  { font-size: 14px; max-width: 100%; line-height: 1.5; }
    .about__desc br { display: none; }
    .about__decor { display: none; }
    .about__image { display: none; }

    /* Banner */
    .banner { padding: 0 0 30px; }
    .banner__label {
        font-size: 16px;
        padding: 10px 20px 10px var(--gutter);
        min-width: 0;
        letter-spacing: 0.5px;
    }

    /* Features: всё в одну колонку */
    .features { padding: 0 var(--gutter) 40px; }
    .features__grid {
        grid-template-columns: 1fr;
        grid-template-rows: repeat(5, 200px);
        grid-template-areas:
            "pilot"
            "assembly"
            "med"
            "hall"
            "ai";
        gap: 10px;
    }
    .feature__caption { left: 14px; top: 12px; max-width: 85%; }
    .feature__caption h3 { font-size: 15px; }
    .feature__caption p  { font-size: 13px; margin-top: 4px; }
    .feature__caption h3 br { display: none; }

    /* на мобилке показываем описание сразу (hover не работает на touch) */
    .feature::after {
        opacity: 1;
        transform: translateY(0);
    }
    .feature__caption p {
        opacity: 1;
        transform: translateY(0);
    }
    .feature__caption h3 { color: #fff; }

    /* Brand */
    .brand { padding: 24px 16px 32px; }
    .brand__logo { width: 220px; }

    /* Footer */
    .footer { padding: 32px var(--gutter) 24px; }
    .footer__inner { max-width: 100%; }
    .footer__line { font-size: 14px; }
    .footer__line--muted { font-size: 12px; margin-top: 12px; }
    .footer__line--muted br { display: none; }
    .footer__copy { font-size: 12px; margin-top: 20px; }
}
