/* =========================================================
   Мадина Досаева · подолог — стили
   Палитра в :root. Запасная голубая тема: добавить
   data-theme="blue" к тегу <html> в index.html.
   ========================================================= */

/* ---------- Шрифты (self-host) ---------- */
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal; font-weight: 500; font-display: swap;
  src: url("../fonts/cormorant-garamond-cyrillic-500-normal.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal; font-weight: 500; font-display: swap;
  src: url("../fonts/cormorant-garamond-latin-500-normal.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;
}
@font-face {
  font-family: "Cormorant Garamond";
  font-style: italic; font-weight: 500; font-display: swap;
  src: url("../fonts/cormorant-garamond-cyrillic-500-italic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Cormorant Garamond";
  font-style: italic; font-weight: 500; font-display: swap;
  src: url("../fonts/cormorant-garamond-latin-500-italic.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;
}
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal; font-weight: 600; font-display: swap;
  src: url("../fonts/cormorant-garamond-cyrillic-600-normal.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal; font-weight: 600; font-display: swap;
  src: url("../fonts/cormorant-garamond-latin-600-normal.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;
}
@font-face {
  font-family: "Manrope";
  font-style: normal; font-weight: 200 800; font-display: swap;
  src: url("../fonts/manrope-cyrillic-wght-normal.woff2") format("woff2-variations");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Manrope";
  font-style: normal; font-weight: 200 800; font-display: swap;
  src: url("../fonts/manrope-latin-wght-normal.woff2") format("woff2-variations");
  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: #FBF8F3;          /* фон страницы */
  --sand: #F3ECE1;        /* фон альтернативных секций */
  --paper: #FFFFFF;       /* бумага: сертификаты, раскрытые группы */
  --ink: #2B2B2B;         /* основной текст */
  --ink-soft: #5C5750;    /* вторичный текст, AA на --bg и --sand */
  --gold: #B8944F;        /* линии, декор (не для мелкого текста) */
  --gold-text: #85652B;   /* золото для текста и кнопок, AA */
  --line: rgba(184, 148, 79, .38);
  --wa: #3DAA66;          /* иконка WhatsApp, приглушённый зелёный */
  --photo-bg: #F2F0ED;    /* подложка под фото на светлом фоне */

  --serif: "Cormorant Garamond", "Times New Roman", Georgia, serif;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  --r-lg: 24px;
  --r-md: 16px;
  --shadow: 0 18px 40px -24px rgba(60, 45, 20, .28);
  --header-h: 68px;
}

/* запасная тема: мягкий голубой */
:root[data-theme="blue"] {
  --bg: #F6F9FC;
  --sand: #E9F1F7;
  --paper: #FFFFFF;
  --ink: #23303B;
  --ink-soft: #4E5D69;
  --gold: #7FA6C4;
  --gold-text: #2F5F84;
  --line: rgba(127, 166, 196, .45);
  --photo-bg: #EEF2F5;
  --shadow: 0 18px 40px -24px rgba(20, 45, 70, .28);
}

/* ---------- База ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 12px); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  font-feature-settings: "lnum", "tnum" 0;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: var(--gold-text); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--ink); }
p { margin: 0 0 1em; }
ul, dl { margin: 0; padding: 0; }
figure { margin: 0; }

h1, h2, h3 { font-family: var(--serif); font-weight: 500; color: var(--ink); margin: 0; }
h1 { font-size: clamp(2.3rem, 6vw, 4.3rem); line-height: 1.02; letter-spacing: -.01em; }
h2 { font-size: clamp(2.1rem, 5.4vw, 3.4rem); line-height: 1.08; margin-bottom: .5em; }
h3 { font-size: clamp(1.35rem, 2.6vw, 1.6rem); line-height: 1.2; font-weight: 600; }

:focus-visible { outline: 2px solid var(--gold-text); outline-offset: 3px; border-radius: 6px; }

.wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 20px; }
@media (min-width: 700px) { .wrap { padding: 0 32px; } }

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 8px;
}
.skip-link:focus { top: 12px; }

.lead-text { font-size: clamp(1.15rem, 2vw, 1.3rem); line-height: 1.55; color: var(--ink); }
.note { font-size: .95rem; color: var(--ink-soft); }

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6em;
  min-height: 54px; padding: 0 28px;
  border-radius: 999px; border: 1px solid var(--ink);
  background: var(--ink); color: var(--bg);
  font: 600 1rem/1.2 var(--sans); text-decoration: none;
  transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}
.btn:hover { background: var(--gold-text); border-color: var(--gold-text); color: #fff; }
.btn .wa-icon { width: 24px; height: 24px; color: var(--wa); flex: none; }
.btn:hover .wa-icon { color: #fff; }
.btn-small { min-height: 44px; padding: 0 20px; font-size: .95rem; }
.btn-outline { background: transparent; color: var(--ink); border-color: var(--gold-text); }
.btn-outline:hover { background: var(--ink); border-color: var(--ink); color: var(--bg); }

/* ---------- Шапка ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .25s ease;
}
.site-header.is-scrolled { border-bottom-color: var(--line); }
.header-row { display: flex; align-items: center; gap: 16px; min-height: var(--header-h); }

.wordmark { display: flex; align-items: baseline; gap: .5em; text-decoration: none; color: var(--ink); margin-right: auto; }
.wordmark-name { font: 600 1.45rem/1 var(--serif); letter-spacing: .005em; }
.wordmark-role { font-size: .9rem; color: var(--gold-text); font-weight: 500; }
.wordmark-role::before { content: "·"; margin-right: .45em; color: var(--gold); }

.nav-toggle {
  display: inline-flex; flex-direction: column; justify-content: center; gap: 6px;
  width: 44px; height: 44px; padding: 0 11px;
  background: transparent; border: 0; border-radius: 10px; cursor: pointer;
}
.nav-toggle span { display: block; height: 1.5px; background: var(--ink); transition: transform .25s ease; }
.nav-toggle[aria-expanded="true"] span:first-child { transform: translateY(3.75px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:last-child { transform: translateY(-3.75px) rotate(-45deg); }

.nav { display: none; }
.nav.is-open {
  display: block; position: absolute; left: 0; right: 0; top: 100%;
  background: var(--bg); border-bottom: 1px solid var(--line);
  padding: 8px 20px 20px; box-shadow: var(--shadow);
}
.nav ul { list-style: none; }
.nav a {
  display: block; padding: 14px 0; color: var(--ink); text-decoration: none;
  font-family: var(--serif); font-size: 1.5rem; font-weight: 500;
  border-bottom: 1px solid var(--line);
}
.nav li:last-child a { border-bottom: 0; }

.header-cta { display: none; }
@media (min-width: 600px) { .header-cta { display: inline-flex; } }

@media (min-width: 980px) {
  :root { --header-h: 80px; }
  .nav-toggle { display: none; }
  .nav, .nav.is-open { display: block; position: static; padding: 0; background: none; border: 0; box-shadow: none; }
  .nav ul { display: flex; gap: 28px; }
  .nav a { padding: 6px 0; font: 500 .98rem/1 var(--sans); border: 0; position: relative; }
  .nav a::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 1px;
    background: var(--gold); transform: scaleX(0); transform-origin: left; transition: transform .25s ease;
  }
  .nav a:hover::after, .nav a:focus-visible::after { transform: scaleX(1); }
  .header-row { gap: 36px; }
}

/* ---------- Арка (мотив свода стопы) ---------- */
.arch { position: relative; isolation: isolate; }
.arch picture, .arch > img {
  display: block; overflow: hidden;
  border-radius: 999px 999px var(--r-lg) var(--r-lg);
  background: var(--photo-bg);
}
.arch img { width: 100%; height: 100%; object-fit: cover; }
.arch::before {          /* тонкая золотая линия-арка, смещённая за фото */
  content: ""; position: absolute; inset: -14px 14px 14px -14px; z-index: -1;
  border: 1px solid var(--gold);
  border-radius: 999px 999px var(--r-lg) var(--r-lg);
}

/* ---------- Hero ---------- */
.hero { padding: 28px 0 72px; }
.hero-grid { display: grid; gap: 48px; align-items: center; }
.hero-text h1 { max-width: 100%; }
.hero-lead { font-size: clamp(1.1rem, 2.2vw, 1.3rem); color: var(--ink-soft); margin: 18px 0 28px; max-width: 34ch; }
.hero-facts { margin-top: 32px; display: grid; gap: 18px; border-top: 1px solid var(--line); padding-top: 22px; max-width: 460px; }
.hero-facts dt, .contact-list dt { font-size: .86rem; font-weight: 600; color: var(--gold-text); margin-bottom: 2px; }
.hero-facts dd, .contact-list dd { margin: 0; }
.hero-photo { width: min(86%, 420px); justify-self: center; margin-left: 14px; }
.hero-photo picture { aspect-ratio: 660 / 890; }

@media (min-width: 900px) {
  .hero { padding: 56px 0 112px; }
  .hero-grid { grid-template-columns: 1.15fr .85fr; gap: 64px; }
  .hero-facts { grid-template-columns: 1fr 1.5fr; column-gap: 40px; max-width: 600px; }
  .hero-photo { width: 100%; max-width: 440px; justify-self: end; }
}

/* одна оркестрованная анимация при загрузке: арка проявляется */
@media (prefers-reduced-motion: no-preference) {
  .hero-photo::before { animation: arch-draw 1.1s .25s cubic-bezier(.2,.7,.2,1) both; }
  .hero-photo picture { animation: arch-rise .9s .05s cubic-bezier(.2,.7,.2,1) both; }
}
@keyframes arch-draw { from { opacity: 0; transform: translate(14px, -14px); } to { opacity: 1; transform: none; } }
@keyframes arch-rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* ---------- Секции ---------- */
.section { padding: clamp(64px, 10vw, 120px) 0; }
.section + .section { border-top: 1px solid var(--line); }
.services, .education { background: var(--sand); }
.services + .section, .education + .section, .section + .services, .section + .education { border-top: 0; }

/* Подология */
.podology-intro { max-width: 760px; }
.podology-lists { display: grid; gap: 48px; margin-top: 56px; }
.podology-col h3 { margin-bottom: 20px; }
@media (min-width: 860px) { .podology-lists { grid-template-columns: 1fr 1fr; gap: 72px; } }

.check-list { list-style: none; columns: 1; }
.check-list li { position: relative; padding: 9px 0 9px 30px; border-bottom: 1px solid var(--line); break-inside: avoid; }
.check-list li::before {   /* маленькая арка вместо галочки */
  content: ""; position: absolute; left: 2px; top: 1.05em;
  width: 13px; height: 9px; border: 1.5px solid var(--gold); border-bottom: 0;
  border-radius: 999px 999px 0 0;
}
.problem-list > div { padding: 12px 0; border-bottom: 1px solid var(--line); }
.problem-list dt { font-weight: 600; }
.problem-list dd { margin: 2px 0 0; color: var(--ink-soft); font-size: .98rem; }

.mission {
  margin: 72px 0 24px; padding: 40px 0 0; max-width: 900px;
  border-top: 1px solid var(--gold); position: relative;
}
.mission p {
  font: italic 500 clamp(1.55rem, 3.6vw, 2.35rem)/1.3 var(--serif);
  margin: 0;
}

/* Услуги и цены */
.services-grid { display: grid; gap: 40px; }
.services-head p { max-width: 42ch; }
.services-cta { margin-top: 12px; }
@media (min-width: 980px) {
  .services-grid { grid-template-columns: .8fr 1.2fr; gap: 72px; align-items: start; }
  .services-head { position: sticky; top: calc(var(--header-h) + 32px); }
}

.price-list { border-top: 1px solid var(--gold); }
.price-group { border-bottom: 1px solid var(--line); }
.price-group summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: 64px; padding: 14px 4px;
}
.price-group summary::-webkit-details-marker { display: none; }
.price-group summary h3 { font-size: clamp(1.3rem, 2.4vw, 1.55rem); }
.price-group summary::after {         /* плюс / минус */
  content: ""; flex: none; width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid var(--gold);
  background:
    linear-gradient(var(--gold-text), var(--gold-text)) center / 12px 1.5px no-repeat,
    linear-gradient(var(--gold-text), var(--gold-text)) center / 1.5px 12px no-repeat;
  transition: transform .25s ease;
}
.price-group[open] summary::after {
  background: linear-gradient(var(--gold-text), var(--gold-text)) center / 12px 1.5px no-repeat;
}
.price-group summary:hover h3 { color: var(--gold-text); }

.price-rows { list-style: none; padding: 0 4px 20px; }
.price-rows li {
  display: grid; grid-template-columns: 1fr auto; column-gap: 12px; align-items: baseline;
  padding: 10px 0;
}
.price-rows li + li { border-top: 1px dotted var(--line); }
.p-name { grid-column: 1; }
.p-cost { grid-column: 2; grid-row: 1; font-weight: 700; white-space: nowrap; font-variant-numeric: tabular-nums; }
.p-time { grid-column: 1; font-size: .88rem; color: var(--ink-soft); }
.p-time:empty { display: none; }
@media (min-width: 640px) {
  .price-rows li { grid-template-columns: 1fr 72px 96px; }
  .p-time { grid-column: 2; grid-row: 1; text-align: right; font-size: .92rem; }
  .p-cost { grid-column: 3; text-align: right; }
}

/* Обо мне */
.about-grid { display: grid; gap: 56px; align-items: center; }
.about-photo { width: min(82%, 380px); justify-self: center; margin-left: 14px; }
.about-photo picture { aspect-ratio: 660 / 880; }
.about-text p { max-width: 60ch; }
.credentials { list-style: none; margin-top: 32px; border-top: 1px solid var(--gold); }
.credentials li { padding: 13px 0; border-bottom: 1px solid var(--line); font-weight: 500; }
@media (min-width: 900px) {
  .about-grid { grid-template-columns: 5fr 7fr; gap: 88px; }
  .about-photo { width: 100%; max-width: 400px; justify-self: start; }
}

/* Обучение */
.education-head { max-width: 760px; }
.education-grid { display: grid; gap: 40px; margin-top: 40px; }
.course-list { list-style: none; border-top: 1px solid var(--gold); }
.course-list li {
  padding: 13px 0; border-bottom: 1px solid var(--line);
  font: 500 clamp(1.2rem, 2.2vw, 1.4rem)/1.3 var(--serif);
  break-inside: avoid;
}
.education-aside h3 { margin-bottom: 12px; }
.education-aside .btn { margin-top: 8px; }
@media (min-width: 900px) {
  .education-grid { grid-template-columns: 1.5fr 1fr; gap: 72px; }
  .course-list { columns: 2; column-gap: 40px; }
  .course-list li:first-child { border-top: 0; }
}

.gallery { display: grid; gap: 20px; margin-top: 56px; }
.gallery figure { display: flex; flex-direction: column; gap: 10px; }
.gallery picture { overflow: hidden; border-radius: var(--r-lg); background: var(--photo-bg); }
.gallery img { width: 100%; height: 100%; object-fit: cover; }
.gallery figcaption { font-size: .9rem; color: var(--ink-soft); }
.g-screen picture { aspect-ratio: 1 / 1; }
.g-table picture { aspect-ratio: 4 / 3; }
.g-congress picture { aspect-ratio: 3 / 2; }
@media (min-width: 760px) {
  .gallery { grid-template-columns: 1fr 1.33fr; gap: 24px; align-items: end; }
  .g-congress { grid-column: 1 / -1; }
  .g-congress picture { aspect-ratio: 21 / 10; }
}

/* Сертификаты (заглушки) */
.cert-grid { list-style: none; display: grid; gap: 28px; margin-top: 24px; }
@media (min-width: 760px) { .cert-grid { grid-template-columns: repeat(3, 1fr); } }
.cert-plate {
  position: relative; aspect-ratio: 4 / 3; display: grid; place-items: center; padding: 28px;
  background: var(--paper); border-radius: var(--r-md); box-shadow: var(--shadow);
  text-align: center;
}
.cert-plate::before {    /* внутренняя рамка документа */
  content: ""; position: absolute; inset: 12px; border: 1px solid var(--line); border-radius: 8px;
}
.cert-mark { font: 600 clamp(1.35rem, 2.6vw, 1.7rem)/1.15 var(--serif); color: var(--gold-text); max-width: 14ch; }
.cert-seal {
  position: absolute; right: 26px; bottom: 24px; width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid var(--gold); box-shadow: inset 0 0 0 4px var(--paper), inset 0 0 0 5px var(--line);
}
.cert-title { margin: 16px 0 0; font-weight: 600; }
.cert-sub { margin: 0; color: var(--ink-soft); font-size: .95rem; }
.certificates .note { margin-top: 28px; }

/* Отзывы */
.reviews-sub {
  font: 600 1rem/1.2 var(--sans); color: var(--gold-text);
  margin: 40px 0 0; padding-bottom: 12px; border-bottom: 1px solid var(--gold);
}
.review-grid { display: grid; gap: 0 48px; }
.review { padding: 28px 0; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; }
.review blockquote { margin: 0; }
.review p { font: italic 500 1.3rem/1.42 var(--serif); margin: 0 0 14px; }
.review p::before { content: "«"; color: var(--gold); margin-right: .06em; }
.review p::after { content: "»"; color: var(--gold); margin-left: .04em; }
.review figcaption { margin-top: auto; font-size: .9rem; color: var(--ink-soft); }
.review-wide p { font-size: clamp(1.45rem, 3vw, 2rem); line-height: 1.32; max-width: 46ch; }
@media (min-width: 860px) {
  .review-grid { grid-template-columns: repeat(3, 1fr); }
  .review-wide { grid-column: 1 / -1; }
  .review-grid-2 { grid-template-columns: repeat(2, 1fr); }
}

/* Контакты */
.contacts-grid { display: grid; gap: 48px; }
.contact-list { display: grid; gap: 20px; margin-bottom: 32px; }
.contact-list a { color: var(--ink); }
.map-links { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 24px; font-weight: 500; }
.map-links a { color: var(--gold-text); }
.map { min-height: 340px; border-radius: var(--r-lg); overflow: hidden; background: var(--sand); box-shadow: var(--shadow); }
.map iframe { display: block; width: 100%; height: 100%; min-height: 340px; border: 0; }
@media (min-width: 900px) {
  .contacts-grid { grid-template-columns: 1fr 1.2fr; gap: 72px; align-items: stretch; }
  .map, .map iframe { min-height: 440px; }
}

/* Подвал */
.site-footer { background: var(--sand); padding: 48px 0 56px; font-size: .95rem; color: var(--ink-soft); }
.footer-grid { display: grid; gap: 20px; }
.footer-name { font: 600 1.3rem/1.2 var(--serif); color: var(--ink); margin-bottom: 6px; }
.placeholder { display: inline-block; background: #FFE9A8; color: #4A3A10; padding: 2px 8px; border-radius: 6px; font-weight: 600; }
.disclaimer { max-width: 52ch; }
.copy { margin: 0; }
@media (min-width: 900px) { .footer-grid { grid-template-columns: 1fr 1.4fr auto; align-items: start; gap: 48px; } }

/* Липкая кнопка WhatsApp (мобильный) */
.sticky-wa {
  position: fixed; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom));
  z-index: 40; display: flex; align-items: center; justify-content: center; gap: .6em;
  min-height: 56px; border-radius: 999px;
  background: var(--ink); color: var(--bg); text-decoration: none; font-weight: 600;
  box-shadow: 0 12px 30px -10px rgba(0, 0, 0, .45);
  transition: transform .3s ease, opacity .3s ease;
}
.sticky-wa .wa-icon { width: 24px; height: 24px; color: var(--wa); }
.sticky-wa.is-hidden { transform: translateY(140%); opacity: 0; pointer-events: none; }
body { padding-bottom: 84px; }
@media (min-width: 900px) {
  .sticky-wa { display: none; }
  body { padding-bottom: 0; }
}

/* Лёгкие появления при скролле (только если есть JS и пользователь не против анимации) */
@media (prefers-reduced-motion: no-preference) {
  .js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1); }
  .js .reveal.is-visible { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
.nw { white-space: nowrap; }
