/* «Компас Здоровья» — основа: шрифты, цвета, типографика, кнопки, формы.
   Палитра взята с брошюры клиники: тёмная листва, олива, шалфей, солнечный лайм. */

@font-face { font-family: 'Golos Text'; font-style: normal; font-weight: 400 700; font-display: swap; src: url('../fonts/golos-cyr.woff2') format('woff2'); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: 'Golos Text'; font-style: normal; font-weight: 400 700; font-display: swap; src: url('../fonts/golos-lat.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+20BD, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Fira XC'; font-style: normal; font-weight: 500; font-display: swap; src: url('../fonts/fira-xc-500-cyr.woff2') format('woff2'); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: 'Fira XC'; font-style: normal; font-weight: 500; font-display: swap; src: url('../fonts/fira-xc-500-lat.woff2') format('woff2'); unicode-range: U+0000-00FF, U+2000-206F, U+20BD; }
@font-face { font-family: 'Fira XC'; font-style: normal; font-weight: 600; font-display: swap; src: url('../fonts/fira-xc-600-cyr.woff2') format('woff2'); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: 'Fira XC'; font-style: normal; font-weight: 600; font-display: swap; src: url('../fonts/fira-xc-600-lat.woff2') format('woff2'); unicode-range: U+0000-00FF, U+2000-206F, U+20BD; }
@font-face { font-family: 'Fira XC'; font-style: normal; font-weight: 700; font-display: swap; src: url('../fonts/fira-xc-700-cyr.woff2') format('woff2'); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: 'Fira XC'; font-style: normal; font-weight: 700; font-display: swap; src: url('../fonts/fira-xc-700-lat.woff2') format('woff2'); unicode-range: U+0000-00FF, U+2000-206F, U+20BD; }

:root {
  /* Цвета */
  --forest: #1E2B17;      /* тень листвы — тёмные блоки, подвал */
  --forest-2: #2A3A20;
  --moss: #3F5124;        /* основной фирменный зелёный */
  --olive: #66772E;       /* олива с брошюры */
  --sage: #D6DCBF;        /* плашки брошюры */
  --mist: #EDF0E2;        /* фон секций */
  --paper: #FAFBF6;       /* фон страницы */
  --white: #FFFFFF;
  --leaf: #C8D46A;        /* солнечный лайм — главная кнопка */
  --leaf-2: #B4C352;
  --ink: #23271D;         /* текст (цвет логотипа) */
  --ink-2: #565D4A;       /* второстепенный текст */
  --ink-3: #697160;
  --line: #DCE1CC;
  --danger: #A8321F;
  --sun: #E9C46A;

  /* Шрифты */
  --f-display: 'Fira XC', 'Arial Narrow', 'Roboto Condensed', sans-serif;
  --f-body: 'Golos Text', 'Segoe UI', Roboto, Arial, sans-serif;

  /* Формы */
  --r: 22px;
  --r-s: 12px;
  --r-leaf: 140px 18px 140px 18px;
  --r-leaf-s: 48px 10px 48px 10px;
  --shadow: 0 22px 60px -30px rgba(30, 43, 23, .45);
  --shadow-s: 0 8px 24px -14px rgba(30, 43, 23, .35);

  --wrap: 1280px;
  --gutter: clamp(16px, 4vw, 40px);
  --hdr-h: 84px;
  --ease: cubic-bezier(.22, .8, .24, 1);

  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--hdr-h) + 16px); }
body {
  margin: 0;
  font-family: var(--f-body);
  font-size: 17px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg, video { max-width: 100%; height: auto; display: block; }
picture { display: contents; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--moss); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--forest); }
:focus-visible { outline: 3px solid var(--olive); outline-offset: 3px; border-radius: 6px; }
::selection { background: var(--leaf); color: var(--forest); }
hr { border: 0; border-top: 1px solid var(--line); margin: 32px 0; }
.ico { width: 1.15em; height: 1.15em; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ico.f { fill: currentColor; stroke: none; }

/* ---------- Типографика ---------- */
h1, h2, h3, h4, .h1, .h2, .h3 {
  font-family: var(--f-display);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: -.005em;
  color: var(--forest);
  margin: 0 0 .45em;
  text-wrap: balance;
}
h1, .h1 { font-size: clamp(40px, 5.4vw, 80px); font-weight: 700; }
h2, .h2 { font-size: clamp(32px, 3.7vw, 54px); }
h3, .h3 { font-size: clamp(23px, 2vw, 29px); line-height: 1.12; }
h4 { font-size: 21px; line-height: 1.2; }
p { margin: 0 0 1em; }
.lead { font-size: clamp(18px, 1.5vw, 21px); line-height: 1.55; color: var(--ink-2); max-width: 62ch; }
.muted { color: var(--ink-2); }
.small { font-size: 14px; line-height: 1.5; }
.tiny { font-size: 12.5px; line-height: 1.45; color: var(--ink-3); }
.nowrap { white-space: nowrap; }
.prose { max-width: 74ch; }
.prose h2 { font-size: clamp(28px, 3vw, 40px); margin-top: 1.4em; }
.prose h3 { margin-top: 1.4em; }
.prose ul, .prose ol { padding-left: 1.25em; margin: 0 0 1.1em; }
.prose li { margin: .35em 0; }
.prose li::marker { color: var(--olive); }
.prose table { width: 100%; border-collapse: collapse; margin: 1.2em 0; font-size: 15.5px; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose th { font-weight: 600; background: var(--mist); }
.prose blockquote { margin: 1.4em 0; padding: 18px 22px; border-left: 4px solid var(--leaf); background: var(--mist); border-radius: 0 var(--r-s) var(--r-s) 0; }
.prose img { border-radius: var(--r-s); margin: 1.2em 0; }
.prose > :first-child { margin-top: 0; }

/* ---------- Сетка ---------- */
.wrap { width: 100%; max-width: calc(var(--wrap) + var(--gutter) * 2); margin: 0 auto; padding: 0 var(--gutter); }
.wrap-n { max-width: calc(900px + var(--gutter) * 2); }
.sec { padding: clamp(56px, 8vw, 112px) 0; position: relative; overflow-x: clip; }
.sec-tight { padding: clamp(36px, 5vw, 64px) 0; }
.sec-mist { background: var(--mist); }
.sec-white { background: var(--white); }
.sec-dark { background: var(--forest); color: #E6EAD8; }
.sec-dark h2, .sec-dark h3, .sec-dark h4 { color: #F4F6EC; }
.sec-dark .lead, .sec-dark .muted { color: #B9C2A6; }
.sec-dark a:not(.btn) { color: var(--leaf); }
.sec-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: clamp(28px, 4vw, 48px); flex-wrap: wrap; }
.sec-head h2 { margin: 0; max-width: 20ch; }
.sec-head .lead { margin: 10px 0 0; }
.sec-head-l { max-width: 760px; }
.grid { display: grid; gap: clamp(16px, 2vw, 24px); }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1080px) { .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 680px) { .g2, .g3, .g4 { grid-template-columns: minmax(0, 1fr); } }
.split { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
@media (max-width: 900px) { .split { grid-template-columns: minmax(0, 1fr); } }
.stack > * + * { margin-top: 14px; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 1000; background: var(--forest); color: #fff; padding: 10px 16px; border-radius: 8px; }
.skip-link:focus { top: 12px; color: #fff; }

/* ---------- Кнопки ---------- */
.btn {
  --bh: 54px;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: var(--bh); padding: 0 26px;
  border: 1.5px solid transparent; border-radius: 999px;
  font-family: var(--f-body); font-weight: 600; font-size: 16px; line-height: 1.15; text-align: center;
  text-decoration: none; white-space: nowrap; cursor: pointer;
  transition: background .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease), transform .25s var(--ease), box-shadow .25s var(--ease);
}
.btn:active { transform: translateY(1px) scale(.99); }
.btn .ico { width: 20px; height: 20px; }
.btn-leaf { background: var(--leaf); color: var(--forest); box-shadow: 0 10px 24px -14px rgba(120, 140, 30, .9); }
.btn-leaf:hover { background: var(--leaf-2); color: var(--forest); }
.btn-moss { background: var(--moss); color: #fff; }
.btn-moss:hover { background: var(--forest); color: #fff; }
.btn-ghost { background: transparent; border-color: currentColor; color: var(--moss); }
.btn-ghost:hover { background: var(--moss); border-color: var(--moss); color: #fff; }
.sec-dark .btn-ghost, .on-dark .btn-ghost { color: #EEF2DF; }
.sec-dark .btn-ghost:hover, .on-dark .btn-ghost:hover { background: #EEF2DF; color: var(--forest); border-color: #EEF2DF; }
.btn-white { background: #fff; color: var(--forest); }
.btn-white:hover { background: var(--mist); color: var(--forest); }
.btn-s { --bh: 42px; padding: 0 18px; font-size: 15px; }
.btn-l { --bh: 62px; padding: 0 34px; font-size: 17px; }
.btn-block { width: 100%; }
.link-arrow { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; text-decoration: none; }
.link-arrow .ico { transition: transform .25s var(--ease); }
.link-arrow:hover .ico { transform: translateX(4px); }

/* ---------- Плашки и бейджи ---------- */
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 999px; background: var(--sage); color: var(--forest); font-size: 14px; font-weight: 500; line-height: 1.2; }
.pill-leaf { background: var(--leaf); }
.pill-dark { background: var(--forest); color: var(--leaf); }
.pill-line { background: transparent; border: 1px solid var(--line); }
.price-tag { display: inline-flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.price-tag b { font-family: var(--f-display); font-size: clamp(30px, 3vw, 42px); font-weight: 700; color: var(--forest); line-height: 1; }
.price-tag s { color: var(--ink-3); font-size: 18px; }
.price-tag .from { font-size: 15px; color: var(--ink-2); }
.sec-dark .price-tag b { color: var(--leaf); }

/* ---------- Формы ---------- */
.field { display: block; position: relative; }
.field + .field { margin-top: 12px; }
.field-label { display: block; font-size: 14px; font-weight: 500; color: var(--ink-2); margin-bottom: 6px; }
.input, .select, .textarea {
  width: 100%; min-height: 54px; padding: 14px 18px;
  background: #fff; border: 1.5px solid var(--line); border-radius: 14px;
  font-size: 16px; line-height: 1.3; color: var(--ink);
  transition: border-color .2s, box-shadow .2s;
}
.textarea { min-height: 110px; resize: vertical; }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' fill='none' stroke='%233F5124' stroke-width='2'%3E%3Cpath d='m1 1 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 18px center; padding-right: 44px; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--olive); box-shadow: 0 0 0 4px rgba(102, 119, 46, .16); }
.input::placeholder, .textarea::placeholder { color: #9AA18C; }
.field.has-error .input, .field.has-error .textarea { border-color: var(--danger); }
.field-error { display: none; color: var(--danger); font-size: 13.5px; margin-top: 6px; }
.has-error > .field-error { display: block; }
.on-dark .input, .on-dark .select, .on-dark .textarea { background: rgba(255, 255, 255, .07); border-color: rgba(255, 255, 255, .18); color: #fff; }
.on-dark .input::placeholder, .on-dark .textarea::placeholder { color: #A9B396; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; line-height: 1.45; color: var(--ink-2); cursor: pointer; margin-top: 14px; }
.check input { appearance: none; flex: none; width: 22px; height: 22px; margin: 0; border: 1.5px solid #A3AC8F; border-radius: 6px; background: #fff; display: grid; place-items: center; cursor: pointer; transition: background .2s, border-color .2s; }
.check input::after { content: ''; width: 11px; height: 6px; border: 2.5px solid var(--forest); border-top: 0; border-right: 0; transform: rotate(-45deg) scale(0); margin-top: -3px; transition: transform .2s var(--ease); }
.check input:checked { background: var(--leaf); border-color: var(--leaf-2); }
.check input:checked::after { transform: rotate(-45deg) scale(1); }
.check a { color: inherit; text-decoration: underline; }
.check.has-error input { border-color: var(--danger); box-shadow: 0 0 0 3px rgba(168, 50, 31, .14); }
.on-dark .check { color: #B9C2A6; }
.on-dark .check input { background: transparent; border-color: #7D8869; }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; }
.form-note { font-size: 12.5px; color: var(--ink-3); margin-top: 12px; line-height: 1.45; }
.form-msg { display: none; padding: 14px 16px; border-radius: 12px; margin-top: 14px; font-size: 15px; }
.form-msg.is-ok { display: block; background: #E7F0D2; color: var(--forest); }
.form-msg.is-err { display: block; background: #F7E2DC; color: var(--danger); }
.form-done { text-align: center; padding: 22px 6px; }
.form-done .done-ico { width: 74px; height: 74px; margin: 0 auto 14px; color: var(--moss); }
.captcha-box { margin-top: 12px; min-height: 0; }
.file-drop { display: grid; place-items: center; text-align: center; gap: 8px; padding: 26px 18px; border: 2px dashed #B6BF9E; border-radius: 18px; background: #fff; cursor: pointer; transition: background .2s, border-color .2s; }
.file-drop:hover, .file-drop.is-over { background: var(--mist); border-color: var(--olive); }
.file-drop input { position: absolute; opacity: 0; pointer-events: none; }
.file-list { list-style: none; padding: 0; margin: 10px 0 0; font-size: 14px; }
.file-list li { display: flex; justify-content: space-between; gap: 10px; padding: 6px 0; border-bottom: 1px dashed var(--line); }

/* ---------- Появление при прокрутке ---------- */
.rv { opacity: 0; transform: translateY(26px); transition: opacity .8s var(--ease), transform .8s var(--ease); transition-delay: var(--d, 0s); }
.rv.in { opacity: 1; transform: none; }
.no-js .rv { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .rv { opacity: 1; transform: none; }
}
