/*
  «Готовый сайт» — стили главной и политики. Без внешних ресурсов, шрифт Jost локально (OFL, assets/fonts/OFL.txt).
  Палитра — гамма шаблона салонов (assets/css/tokens.css репозитория): бирюзовый акцент, тёплые бежевые фоны.
  Правило цвета то же, что в шаблоне:
    --accent (#00b7b0) — только заливки кнопок, рамки, иконки, линии (на белом контраст 2.5, для текста не годится);
    текст на заливке акцентом — чёрный (8.4:1); акцентный текст и ссылки — --accent-text (#007a74, 5.2:1 на белом, 4.7:1 на бежевом).
  Контраст на белом / на --surface-alt (#f7f4ef): ink 21 / 19; muted #5e564b 7.2 / 6.6; taupe #716655 5.7 / 5.2;
  field-border #8d8478 3.7 / 3.4 (>= 3:1 для рамок полей); error #b3261e 6.5 / 5.9.
*/
@font-face {
  font-family: "Jost";
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url("fonts/jost-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Jost";
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url("fonts/jost-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Jost";
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: url("fonts/jost-latin.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+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg: #ffffff;
  --surface-alt: #f7f4ef;
  --ink: #15130f;
  --muted: #5e564b;
  --taupe: #716655;
  --line: #e8e3dd;
  --field-border: #8d8478;
  --accent: #00b7b0;
  --accent-hover: #00a29c;
  --accent-text: #007a74;
  --on-accent: #000000;
  --error: #b3261e;
  --error-bg: #fdf1f0;
  --focus: #007a74;
  --footer-bg: #1d1a16;
  --footer-text: #e9e4dc;

  --font: "Jost", Arial, sans-serif;
  --radius: 12px;
  --radius-pill: 60px;
  --container: 1120px;
  --gutter: 20px;
  --section-y: 64px;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
}
@media (min-width: 768px) {
  :root { --gutter: 32px; --section-y: 88px; }
}
@media (min-width: 1280px) {
  :root { --gutter: 40px; --section-y: 104px; }
}

*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 16px;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
a { color: var(--accent-text); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
button, input, textarea { font: inherit; color: inherit; }

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 4px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip-link {
  position: absolute;
  left: 12px; top: -80px;
  z-index: 100;
  background: var(--ink);
  color: #fff;
  padding: 12px 16px;
  border-radius: 8px;
}
.skip-link:focus { top: 12px; }

.container {
  width: 100%;
  max-width: calc(var(--container) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.narrow { max-width: 760px; }

/* ---------- Шапка ---------- */
.site-header { border-bottom: 1px solid var(--line); background: var(--bg); }
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; min-height: 64px;
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--ink); text-decoration: none;
  font-weight: 500; font-size: 1.25rem; letter-spacing: 0.01em;
}
.brand svg { width: 32px; height: 32px; flex: none; }
.brand:hover { text-decoration: none; }

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; padding: 0 28px;
  border: 2px solid var(--accent);
  border-radius: var(--radius-pill);
  background: var(--accent); color: var(--on-accent);
  font-weight: 500; font-size: 1.0625rem; line-height: 1.2;
  text-align: center; text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s var(--ease), border-color 0.2s var(--ease), transform 0.2s var(--ease);
}
.btn:hover { background: var(--accent-hover); border-color: var(--accent-hover); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.6; cursor: progress; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--accent-text); }
.btn-ghost:hover { background: #e6f6f5; border-color: var(--accent-text); }
.btn-sm { min-height: 44px; padding: 0 20px; font-size: 1rem; }
.btn-block { width: 100%; }

/* ---------- Типографика секций ---------- */
.section { padding-block: var(--section-y); }
.section-alt { background: var(--surface-alt); }
.eyebrow {
  margin-bottom: 12px;
  color: var(--taupe);
  font-size: 0.9375rem; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase;
}
.section-title {
  font-size: clamp(1.625rem, 1.25rem + 1.5vw, 2.5rem);
  font-weight: 500; line-height: 1.15; letter-spacing: -0.01em;
  max-width: 22ch;
}
.section-lead { margin-top: 14px; max-width: 56ch; color: var(--muted); font-size: 1.125rem; }
.section-head { margin-bottom: 32px; }
@media (min-width: 768px) { .section-head { margin-bottom: 44px; } }

/* ---------- Первый экран ---------- */
.hero {
  padding-block: 40px 56px;
  background: linear-gradient(180deg, var(--surface-alt) 0%, var(--bg) 100%);
}
.hero-grid { display: grid; gap: 36px; align-items: center; }
.hero h1 {
  font-size: clamp(2.125rem, 1.4rem + 3vw, 3.75rem);
  font-weight: 500; line-height: 1.06; letter-spacing: -0.015em;
}
.hero h1 .nowrap { white-space: nowrap; }
.hero-lead { margin-top: 18px; max-width: 46ch; color: var(--muted); font-size: 1.1875rem; }
.hero-actions { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.hero-actions .btn { width: 100%; }
.hero-points { margin-top: 24px; display: flex; flex-wrap: wrap; gap: 8px 18px; color: var(--muted); font-size: 1rem; }
.hero-points li { display: inline-flex; align-items: center; gap: 8px; }
.hero-points svg, .included-list svg { width: 20px; height: 20px; flex: none; color: var(--accent-text); }
@media (min-width: 600px) { .hero-actions .btn { width: auto; min-width: 260px; } }
@media (min-width: 900px) {
  .hero { padding-block: 72px 88px; }
  .hero-grid { grid-template-columns: 1.1fr 0.9fr; gap: 56px; }
}

/* Макет телефона с вымышленным салоном */
.phone-wrap { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.phone {
  position: relative;
  width: 100%; max-width: 270px;
  border: 9px solid var(--ink);
  border-radius: 38px;
  background: #fff;
  overflow: hidden;
  box-shadow: 0 24px 56px rgba(21, 19, 15, 0.16);
  font-size: 0.8125rem; line-height: 1.35;
  user-select: none;
}
.phone::before {
  content: "";
  position: absolute; z-index: 2;
  top: 8px; left: 50%; transform: translateX(-50%);
  width: 64px; height: 6px; border-radius: 6px;
  background: var(--ink);
}
.phone-cover {
  padding: 36px 16px 18px;
  background: linear-gradient(160deg, #f1e6d6 0%, #f7f4ef 55%, #d8f1ef 100%);
}
.phone-badge { font-size: 0.6875rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--taupe); font-weight: 500; }
.phone-title { margin-top: 6px; font-size: 1.5rem; font-weight: 500; line-height: 1.1; color: var(--ink); }
.phone-addr { margin-top: 6px; color: var(--muted); }
.phone-call {
  display: flex; align-items: center; justify-content: center;
  margin-top: 14px; height: 38px; border-radius: var(--radius-pill);
  background: var(--accent); color: var(--on-accent); font-weight: 500;
}
.phone-body { padding: 14px 16px 18px; }
.phone-h { font-size: 0.6875rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--taupe); font-weight: 500; }
.phone-list { margin-top: 6px; }
.phone-list li {
  display: flex; align-items: center; justify-content: space-between;
  padding: 9px 0; border-bottom: 1px solid var(--line); color: var(--ink);
}
.phone-list li::after { content: ""; width: 7px; height: 7px; border-right: 2px solid var(--accent); border-top: 2px solid var(--accent); transform: rotate(45deg); margin-right: 2px; }
.phone-hours { margin-top: 12px; color: var(--muted); }
.phone-caption { max-width: 270px; text-align: center; color: var(--muted); font-size: 0.9375rem; }

/* ---------- Шаги ---------- */
.steps { display: grid; gap: 16px; counter-reset: step; }
.step {
  position: relative;
  padding: 24px 22px 24px 22px;
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius);
}
.step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--accent); color: var(--on-accent); font-weight: 500; font-size: 1.125rem;
}
.step h3 { margin-top: 16px; font-size: 1.3125rem; font-weight: 500; line-height: 1.25; }
.step p { margin-top: 8px; color: var(--muted); }
@media (min-width: 768px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 24px; } .step { padding: 28px 26px; } }

/* ---------- Формы ---------- */
.form-card {
  max-width: 760px; margin-inline: auto;
  padding: 24px 20px;
  background: var(--bg); border: 1px solid var(--line); border-radius: 16px;
}
@media (min-width: 768px) { .form-card { padding: 40px; } }
.form-card h2 { font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.125rem); font-weight: 500; line-height: 1.15; }
.form-intro { margin-top: 10px; color: var(--muted); }
form { margin-top: 24px; }
.field { margin-bottom: 20px; }
.field > label:not(.consent), .field > .label, .field > legend {
  display: block; padding: 0;
  margin-bottom: 6px; font-weight: 500; font-size: 1rem; color: var(--ink);
}
.req { color: var(--error); }
.opt { color: var(--muted); font-weight: 400; }
.hint { margin-top: 6px; color: var(--muted); font-size: 0.9375rem; }
fieldset { border: 0; margin: 0 0 20px; padding: 0; min-width: 0; }
.field-row { display: grid; gap: 0 16px; }
@media (min-width: 640px) { .field-row { grid-template-columns: 1fr 1fr; } }

input[type="text"], input[type="tel"], textarea {
  display: block; width: 100%; min-height: 52px;
  padding: 12px 14px;
  background: #fff;
  border: 1.5px solid var(--field-border); border-radius: 10px;
  font-size: 1rem; /* 16px: iOS не приближает страницу при фокусе */
  line-height: 1.4;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
textarea { min-height: 104px; resize: vertical; }
input::placeholder, textarea::placeholder { color: #6f675b; opacity: 1; }
input[type="text"]:focus-visible, input[type="tel"]:focus-visible, textarea:focus-visible {
  outline: 3px solid var(--focus); outline-offset: 1px; border-color: var(--focus);
}
input[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: var(--error); background: var(--error-bg); }
.field-error {
  margin-top: 6px; color: var(--error); font-size: 0.9375rem; font-weight: 500;
}
.field-error[hidden] { display: none; }
.is-invalid .chip span { border-color: var(--error); }

/* Чипы услуг */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { position: relative; display: inline-block; margin: 0 !important; }
.chip input {
  position: absolute; inset: 0; width: 100%; height: 100%;
  margin: 0; opacity: 0; cursor: pointer; z-index: 1;
}
.chip span {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 46px; padding: 0 18px;
  border: 1.5px solid var(--field-border); border-radius: var(--radius-pill);
  background: #fff; font-weight: 400; font-size: 1rem; line-height: 1.2;
  transition: background-color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.chip:hover span { border-color: var(--ink); }
.chip input:checked + span { background: var(--accent); border-color: var(--accent); color: var(--on-accent); font-weight: 500; }
.chip input:checked + span::before {
  content: ""; width: 6px; height: 11px; margin-right: 2px;
  border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translate(-1px, -1px);
}
.chip input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 3px; }

/* Чекбокс согласия */
.consent { display: flex; gap: 12px; align-items: flex-start; font-weight: 400 !important; }
.consent input {
  flex: none; width: 24px; height: 24px; margin: 2px 0 0;
  accent-color: var(--accent-text); cursor: pointer;
}
.consent span { font-size: 1rem; line-height: 1.45; }

/* Honeypot: не для людей */
.hp { position: absolute !important; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }

.form-actions { margin-top: 8px; }
.form-status { margin-top: 14px; min-height: 1.5em; color: var(--muted); font-size: 1rem; }
.form-status.is-error {
  padding: 12px 14px; border-radius: 10px;
  background: var(--error-bg); color: var(--error); font-weight: 500;
}
.form-note { margin-top: 14px; color: var(--muted); font-size: 0.9375rem; }

/* Экран успеха */
.success[hidden], [hidden] { display: none !important; }
.success h2:focus { outline: none; }
.draft-link {
  display: block; margin-top: 18px; padding: 16px 18px;
  background: var(--surface-alt); border: 2px solid var(--accent); border-radius: var(--radius);
  color: var(--accent-text); font-weight: 500;
  font-size: clamp(1.125rem, 0.9rem + 1.2vw, 1.5rem);
  line-height: 1.3; word-break: break-all; text-decoration: none;
}
.draft-link:hover { text-decoration: underline; text-decoration-thickness: 2px; }
.success-actions { margin-top: 16px; display: flex; flex-wrap: wrap; gap: 12px; }
.success-actions .btn { flex: 1 1 220px; }
.success-note { margin-top: 14px; color: var(--muted); }
.success-sep { margin-block: 32px 0; padding-top: 28px; border-top: 1px solid var(--line); }
.success-sep h3 { font-size: 1.375rem; font-weight: 500; line-height: 1.2; }
.lead-thanks { padding: 18px; border-radius: var(--radius); background: #e6f6f5; color: var(--ink); font-size: 1.125rem; }
.link-btn {
  background: none; border: 0; padding: 8px 0; cursor: pointer;
  color: var(--accent-text); text-decoration: underline; text-underline-offset: 3px; font-size: 1rem;
}

/* ---------- Что входит ---------- */
.included-list { display: grid; gap: 14px; }
.included-list li {
  display: flex; gap: 14px; align-items: flex-start;
  padding: 18px; background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius);
}
.included-list svg { margin-top: 2px; }
.included-list strong { display: block; font-weight: 500; font-size: 1.125rem; line-height: 1.3; }
.included-list span { display: block; margin-top: 4px; color: var(--muted); font-size: 1rem; }
.price-note {
  margin-top: 24px; padding: 18px 20px; border-left: 4px solid var(--accent);
  background: var(--bg); font-size: 1.125rem; border-radius: 0 var(--radius) var(--radius) 0;
}
@media (min-width: 768px) { .included-list { grid-template-columns: 1fr 1fr; gap: 16px; } }

/* ---------- Вопросы ---------- */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  position: relative; display: block; cursor: pointer; list-style: none;
  padding: 20px 44px 20px 0; font-size: 1.1875rem; font-weight: 500; line-height: 1.3;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before, .faq summary::after {
  content: ""; position: absolute; right: 8px; top: 50%;
  width: 16px; height: 2px; background: var(--accent-text); transition: transform 0.2s var(--ease);
}
.faq summary::after { transform: rotate(90deg); }
.faq details[open] summary::after { transform: rotate(0deg); }
.faq summary:focus-visible { outline-offset: -3px; }
.faq .answer { padding: 0 0 22px; max-width: 62ch; color: var(--muted); }

/* ---------- Подвал ---------- */
.site-footer { background: var(--footer-bg); color: var(--footer-text); padding-block: 40px; font-size: 1rem; }
.site-footer a { color: #fff; }
.footer-grid { display: grid; gap: 16px; }
.footer-brand { color: #fff; font-weight: 500; font-size: 1.25rem; }
.footer-meta { color: #cfc8bd; font-size: 0.9375rem; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 1fr auto; align-items: start; } }

/* ---------- Политика ---------- */
.doc { padding-block: 40px 72px; }
.doc h1 { font-size: clamp(1.75rem, 1.3rem + 2vw, 2.75rem); font-weight: 500; line-height: 1.12; }
.doc .updated { margin-top: 10px; color: var(--muted); }
.doc h2 { margin-top: 36px; font-size: 1.375rem; font-weight: 500; line-height: 1.25; }
.doc p, .doc ul, .doc ol { margin-top: 12px; }
.doc ul { padding-left: 1.25rem; list-style: disc; }
.doc ol { padding-left: 1.5rem; list-style: decimal; }
.doc li + li { margin-top: 6px; }
.doc .ph { background: #fff3c4; padding: 0 4px; border-radius: 4px; }

/* ---------- Движение ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
  .btn:active { transform: none; }
}
@media (forced-colors: active) {
  .chip input:checked + span { outline: 2px solid Highlight; }
}
