/* =====================================================================
   theme.css — дизайн-система «Clean Clinic»
   Токены (палитра, тени, радиусы, спейсинг, шрифты), база, кнопки, утилиты.
   Подключается ПЕРВЫМ, до main.css.
   ===================================================================== */

:root {
    /* Палитра — navy + crimson (AWSMCOLOR) */
    --brand: #0b245b;
    --brand-600: #081a45;
    --brand-050: #eaeef7;
    --accent: #9a073c;
    --accent-600: #7c052f;
    --ink: #131a2b;
    --body: #454d5c;
    --muted: #7b8290;
    --bg: #f9faf5;
    --surface: #ffffff;
    --line: #e1e0e0;
    --price: var(--brand);

    /* Полупрозрачные фоны секций — сквозь них проступает скетч-фон */
    --sec-white: rgba(255, 255, 255, 0.86);
    --sec-tint: rgba(224, 230, 245, 0.84);

    /* Тени */
    --shadow-sm: 0 1px 3px rgba(16, 26, 48, .07);
    --shadow-md: 0 6px 20px rgba(16, 26, 48, .09);
    --shadow-lg: 0 14px 36px rgba(16, 26, 48, .13);

    /* Радиусы */
    --r-sm: 8px;
    --r-md: 14px;
    --r-lg: 22px;
    --r-pill: 999px;

    /* Ритм / раскладка */
    --section-y: clamp(48px, 8vw, 96px);
    --container: 1160px;

    /* Шрифты */
    --font-head: "Poppins", "Segoe UI", Arial, sans-serif;
    --font-body: "Inter", "Segoe UI", Arial, sans-serif;
}

/* ------------------------------------------------------------------ */
/* База                                                                */
/* ------------------------------------------------------------------ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    /* учитываем sticky-навбар при переходе по якорям */
    scroll-padding-top: 84px;
}

body {
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.7;
    color: var(--body);
    background-color: var(--bg);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

/* Фоновый скетч стоп — зафиксирован за страницей, проступает сквозь
   полупрозрачные секции («мелькает» по всему фону) */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background: url("../images/background.jpg") center center / cover no-repeat;
    opacity: 0.45;
}

h1, h2, h3, h4 {
    font-family: var(--font-head);
    color: var(--ink);
    line-height: 1.2;
    font-weight: 700;
}

h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); }
h3 { font-size: 1.25rem; font-weight: 600; }

p { color: var(--body); }

a {
    color: var(--brand);
    text-decoration: none;
    transition: color .25s ease;
}

a:hover { color: var(--brand-600); }

img { max-width: 100%; }

/* ------------------------------------------------------------------ */
/* Утилиты раскладки                                                   */
/* ------------------------------------------------------------------ */

.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 20px;
}

/* Единый вертикальный ритм секций */
.section {
    padding-top: var(--section-y);
    padding-bottom: var(--section-y);
}

/* Заголовок секции + «надзаголовок» (kicker) */
.section-kicker {
    display: inline-block;
    font-family: var(--font-head);
    font-weight: 600;
    font-size: .8rem;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--brand);
    background: var(--brand-050);
    padding: 6px 14px;
    border-radius: var(--r-pill);
    margin-bottom: 16px;
}

/* ------------------------------------------------------------------ */
/* Система кнопок                                                      */
/* ------------------------------------------------------------------ */

.btn,
.btn--ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-family: var(--font-head);
    font-weight: 600;
    font-size: 1rem;
    line-height: 1;
    padding: 15px 30px;
    border-radius: var(--r-pill);
    border: 2px solid transparent;
    cursor: pointer;
    text-decoration: none;
    transition: background-color .25s ease, color .25s ease,
                border-color .25s ease, transform .2s ease, box-shadow .25s ease;
}

/* Основная CTA — crimson */
.btn {
    background-color: var(--accent);
    color: #fff;
    box-shadow: 0 6px 16px rgba(154, 7, 60, .26);
}

.btn:hover {
    background-color: var(--accent-600);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 10px 22px rgba(154, 7, 60, .32);
}

/* Вторичная — обводка тил */
.btn--ghost {
    background-color: transparent;
    color: var(--brand);
    border-color: var(--brand);
}

.btn--ghost:hover {
    background-color: var(--brand);
    color: #fff;
    transform: translateY(-2px);
}

/* Кнопка поверх тёмного фона (hero, стельки) */
.btn--on-dark.btn--ghost {
    color: #fff;
    border-color: rgba(255, 255, 255, .7);
}

.btn--on-dark.btn--ghost:hover {
    background-color: #fff;
    color: var(--ink);
    border-color: #fff;
}

/* ------------------------------------------------------------------ */
/* Доступность / motion                                                */
/* ------------------------------------------------------------------ */

:focus-visible {
    outline: 3px solid var(--brand);
    outline-offset: 2px;
    border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: .001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .001ms !important;
        scroll-behavior: auto !important;
    }
}


