@import url('https://fonts.googleapis.com/css2?family=Anton&family=Inter:wght@400;500;600;700;800&display=swap');

/* === DESIGN SYSTEM === */
:root {
    /* 1. RGB-компоненты */
    --bs-primary-rgb: 242, 183, 5;       /* #F2B705 */
    --bs-secondary-rgb: 226, 63, 63;     /* #E23F3F */
    --bs-success-rgb: 31, 122, 63;       /* #1F7A3F */
    --bs-info-rgb: 43, 58, 103;          /* #2B3A67 */
    --bs-light-rgb: 242, 242, 240;       /* #F2F2F0 */
    --bs-dark-rgb: 13, 13, 13;           /* #0D0D0D */
    --bs-body-bg-rgb: 255, 255, 255;     /* #ffffff */
    --bs-body-color-rgb: 26, 26, 26;     /* #1A1A1A */
    --bs-secondary-color-rgb: 107, 107, 107; /* #6B6B6B */

    /* 2. ИСПРАВЛЕНО: Современный синтаксис rgb() без разделения прозрачности через запятую */
    --bs-primary: rgb(var(--bs-primary-rgb));
    --bs-secondary: rgb(var(--bs-secondary-rgb));
    --bs-success: rgb(var(--bs-success-rgb));
    --bs-info: rgb(var(--bs-info-rgb));
    --bs-light: rgb(var(--bs-light-rgb));
    --bs-dark: rgb(var(--bs-dark-rgb));
    --bs-body-bg: rgb(var(--bs-body-bg-rgb));
    --bs-body-color: rgb(var(--bs-body-color-rgb));
    --bs-secondary-color: rgb(var(--bs-secondary-color-rgb));

    /* Шрифты */
    --bs-body-font-family: 'Inter', sans-serif;
    --font-heading: 'Anton', 'Inter', sans-serif;
}

body {
    font-family: var(--bs-body-font-family);
    color: var(--bs-body-color);
    background-color: var(--bs-body-bg);
}

h1,
h2,
h3,
h4,
.display-1,
.display-2,
.display-3,
.display-4,
.display-5,
.display-6 {
    font-family: var(--font-heading);
    text-transform: uppercase;
    letter-spacing: 0.01em;
    line-height: 1.02;
}

/* --- Контентные узлы --- */
p {
    margin-bottom: 1rem;
}

p:last-child {
    margin-bottom: 0;
}

small,
blockquote footer,
.eyebrow {
    text-transform: uppercase;
    letter-spacing: .05em;
}

blockquote {
    margin: 0;
}

blockquote p {
    font-style: italic;
    font-size: 1.05rem;
}

blockquote footer {
    margin-top: .5rem;
    font-size: .82rem;
    font-style: normal;
    font-weight: 600;
}

/* Секции-контейнеры */
.section-dark {
    background: var(--bs-dark);
    color: #fff;
}

.section-dark p,
.section-dark small,
.section-dark blockquote footer,
.section-dark .text-body {
    color: rgba(255, 255, 255, .62);
}

.section-light {
    background: var(--bs-light);
}

.section-light p,
.section-light small,
.section-light blockquote footer,
.section-light .text-body {
    color: var(--bs-secondary-color);
}

.section-white {
    background: #fff;
}

.section-white p,
.section-white small,
.section-white blockquote footer,
.section-white .text-body {
    color: var(--bs-secondary-color);
}

/* Текст */
.lede p {
    font-size: 1.2rem;
}

.note p {
    font-size: .92rem;
}

/* Отступы */
.section-py {
    padding-top: 5rem;
    padding-bottom: 5rem;
}

.section-py-lg {
    padding-top: 6rem;
    padding-bottom: 6rem;
}

/* Ограничители ширины */
.measure-sm {
    max-width: 480px;
}

.measure-md {
    max-width: 560px;
}

.measure-lg {
    max-width: 640px;
}

.measure-xl {
    max-width: 720px;
}

/* Кнопки */
.btn-primary {
    --bs-btn-bg: var(--bs-primary);
    --bs-btn-border-color: var(--bs-primary);
    --bs-btn-color: #14110a;
    --bs-btn-hover-bg: #ffffff;
    --bs-btn-hover-border-color: #ffffff;
    --bs-btn-hover-color: #14110a;
    --bs-btn-font-weight: 700;
    --bs-btn-border-radius: 2px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-size: 0.9rem;
}

.btn-outline-light {
    --bs-btn-border-radius: 2px;
    --bs-btn-font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
    font-size: .9rem;
}

/* Ссылки и элементы декора */
.link-accent {
    display: inline-block;
    color: var(--bs-secondary);
    font-weight: 700;
    text-decoration: none;
    border-bottom: 2px solid var(--bs-secondary);
    padding-bottom: .15rem;
}

.link-accent:hover {
    opacity: .7;
    color: var(--bs-secondary);
}

.eyebrow {
    font-family: var(--font-heading);
    color: var(--bs-secondary);
    font-size: .95rem;
    font-weight: 400;
    margin-bottom: .9rem;
}

.eyebrow-line {
    display: inline-block;
    width: 32px;
    height: 3px;
    background: var(--bs-primary);
    margin-right: .6rem;
    vertical-align: middle;
}

.signature {
    font-family: var(--font-heading);
    font-style: normal;
    color: var(--bs-primary);
    letter-spacing: .02em;
    font-size: 1.05rem;
    display: block;
}

figure {
    margin: 0;
}

figure figcaption {
    margin-top: .75rem;
    font-size: .9rem;
    font-style: italic;
}

.section-dark figure figcaption {
    color: rgba(255, 255, 255, .55);
}

.section-light figure figcaption,
.section-white figure figcaption {
    color: var(--bs-secondary-color);
}

.stat-figure {
    font-size: 2.4rem;
    margin-bottom: 0;
}

.stat-divider {
    width: 40px;
    height: 3px;
    background: var(--bs-primary);
}

.brand-mark {
    font-family: var(--font-heading);
    letter-spacing: .03em;
}

/* === Визуальные блоки (hero-разрывы) ===
   Фон теперь — обычный <img> внутри секции (см. HTML), а не CSS background-image.
   .visual-break — позиционирующий контейнер с собственным stacking context (isolation),
   чтобы отрицательные z-index слоёв (фото/градиент) не утекали за пределы секции.
   Порядок слоёв внутри секции: 1) <img class="visual-break-img"> — фото,
   2) <div class="visual-break-overlay"> — тёмный градиент,
   3) .container с текстом — обычный поток, поверх (z-index не нужен, т.к. предыдущие слои в минусе). */
.visual-break {
    position: relative;
    color: #fff;
    padding-top: 5rem;
    padding-bottom: 5rem;
    display: flex;
    align-items: center;
    overflow: hidden;
    isolation: isolate;
}

.visual-break-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: -2;
}

.visual-break-overlay {
    position: absolute;
    inset: 0;
    z-index: -1;
}

.visual-hero .visual-break-overlay {
    background-image: linear-gradient(90deg, rgba(var(--bs-dark-rgb), .88) 0%, rgba(var(--bs-dark-rgb), .55) 45%, rgba(var(--bs-dark-rgb), .15) 100%);
}

.visual-trackdays .visual-break-overlay {
    background-image: linear-gradient(0deg, rgba(var(--bs-dark-rgb), .85), rgba(var(--bs-dark-rgb), .35));
}

.visual-crew .visual-break-overlay {
    background-image: linear-gradient(0deg, rgba(var(--bs-dark-rgb), .9), rgba(var(--bs-dark-rgb), .55));
}

.spec-strip {
    background: rgba(var(--bs-dark-rgb), .5);
}

.spec-tile {
    border: 1px solid rgba(255, 255, 255, .14);
}

/* Карточки */
.card-programme {
    border: none;
    border-top: 4px solid var(--bs-primary);
    transition: transform .2s ease, box-shadow .2s ease;
}

.card-programme:hover {
    transform: translateY(-6px);
    box-shadow: 0 1rem 2rem rgba(var(--bs-dark-rgb), .15);
}

/* Таблицы */
.table-comparison {
    border-collapse: collapse;
}

.table-comparison thead th {
    font-family: var(--font-heading);
    text-transform: uppercase;
    font-weight: 400;
    font-size: 1.15rem;
    border-bottom: 2px solid var(--bs-dark);
    padding: .75rem;
    vertical-align: bottom;
}

.table-comparison thead th:first-child {
    border-bottom-color: transparent;
}

.table-comparison tbody th {
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--bs-secondary-color);
    font-weight: 700;
    white-space: nowrap;
    padding: 1.1rem .75rem;
    vertical-align: top;
    border-bottom: 1px solid rgba(var(--bs-dark-rgb), .08);
}

.table-comparison tbody td {
    padding: 1.1rem .75rem;
    vertical-align: top;
    border-bottom: 1px solid rgba(var(--bs-dark-rgb), .08);
    color: var(--bs-secondary-color);
}

/* Таймлайн */
.timeline-item {
    position: relative;
    padding-left: 3.2rem;
    padding-bottom: 1.75rem;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-item::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--bs-primary);
}

.timeline-item::after {
    content: "";
    position: absolute;
    left: 16px;
    top: 34px;
    bottom: -1.75rem;
    width: 2px;
    background: var(--bs-secondary-color);
    opacity: .3;
}

.timeline-item:last-child::after {
    display: none;
}

.timeline-year {
    font-size: .8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: var(--bs-secondary);
    margin-bottom: .25rem;
    display: block;
}

.track-thumb {
    aspect-ratio: 4/3;
    object-fit: cover;
}

.partner-logo {
    max-width: 180px;
}

.step-row {
    display: flex;
    margin-bottom: 1.5rem;
}

.step-num {
    font-family: var(--font-heading);
    color: var(--bs-primary);
    font-size: 1.6rem;
    margin-right: 1.25rem;
    line-height: 1;
}

footer.site-footer a {
    color: rgba(255, 255, 255, .75);
}

footer.site-footer a:hover {
    color: var(--bs-primary);
}