/* ---------- База ---------- */
:root{
  --navy:#0f2247;--ink:#0f2247;--ink-2:#3b4a6b;--muted:#55627f;
  --bg:#e6e6e6;--bg-2:#c9cbcf;--card:#f2f2f3;--line:#e4e5e7;--accent:#0f2247;--glow:#a9c1ee;
  --hx:max(40px,calc(50vw - 640px));
}
*,*::before,*::after{box-sizing:border-box}
html{scroll-behavior:smooth;-webkit-text-size-adjust:100%}
@media (prefers-reduced-motion: reduce){html{scroll-behavior:auto}}
body{margin:0;background:var(--navy);color:var(--ink);font-family:'Inter Tight',system-ui,-apple-system,'Segoe UI',Roboto,Arial,sans-serif;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility}
img{max-width:100%}
a{color:inherit;text-decoration:none}
a:hover{opacity:.8}
button{font:inherit}
:focus-visible{outline:2px solid var(--glow);outline-offset:3px;border-radius:4px}
.dn{background:var(--bg);color:var(--ink);overflow-x:clip;position:relative}
.serif{font-family:'Playfair Display',Georgia,'Times New Roman',serif;font-style:italic;font-weight:400;letter-spacing:-0.01em}
.wrap{width:100%;max-width:1360px;margin:0 auto;padding-left:40px;padding-right:40px}
.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.skip{position:absolute;left:16px;top:-60px;z-index:100;background:#fff;color:var(--navy);padding:12px 18px;border-radius:999px}
.skip:focus{top:12px}
.fill{color:transparent;-webkit-background-clip:text;background-clip:text;background-image:linear-gradient(#0f2247,#0f2247),linear-gradient(#c3c5ca,#c3c5ca);background-repeat:no-repeat;background-size:100% 100%,100% 100%}
.progress{position:fixed;top:0;left:0;right:0;height:3px;background:var(--glow);transform:scaleX(0);transform-origin:0 50%;z-index:80}

/* ---------- Шапка ---------- */
.site-header{position:sticky;top:0;z-index:60;color:#fff;background:rgba(15,34,71,.92);-webkit-backdrop-filter:blur(14px) saturate(1.4);backdrop-filter:blur(14px) saturate(1.4)}
.hdr{height:84px;display:flex;align-items:center;justify-content:space-between;gap:24px}
.hdr-left{display:flex;align-items:center;gap:24px;min-width:0}
.hdr-logo{display:flex;align-items:center;flex:none}
.hdr-logo img{height:44px;width:auto;display:block}
.hdr-addr{display:flex;align-items:center;gap:12px;padding-left:22px;border-left:1px solid rgba(255,255,255,.22);min-height:44px;font-size:13px;line-height:1.45;color:rgba(255,255,255,.9);white-space:nowrap}
.hdr-addr>span{display:flex;flex-direction:column}
.nav-links{display:flex;align-items:center;gap:24px;font-size:15px}
.nav-links a{min-height:44px;display:inline-flex;align-items:center}
.nav-links a[aria-current="page"]{text-decoration:underline;text-underline-offset:6px}
.hdr-right{display:flex;align-items:center;gap:22px}
.hdr-duty{display:flex;flex-direction:column;justify-content:center;min-height:44px;line-height:1.3;white-space:nowrap}
.hdr-duty small{font-size:12px;color:rgba(255,255,255,.75)}
.hdr-duty b{font-size:16px;font-weight:500;font-variant-numeric:tabular-nums}
.hdr-call,.burger{display:none;width:44px;height:44px;border-radius:50%;border:1px solid currentColor;background:transparent;color:inherit;align-items:center;justify-content:center;cursor:pointer;flex:none}
.hdr-cta{font-size:16px;font-weight:500;white-space:nowrap;min-height:44px;display:inline-flex;align-items:center}
.mnav{background:var(--navy);color:#fff;border-top:1px solid rgba(255,255,255,.14);max-height:calc(100vh - 84px);overflow:auto}
.mnav[hidden]{display:none}
.mnav .wrap{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(240px,100%),1fr));gap:28px;padding-top:24px;padding-bottom:32px}
.mnav nav{display:flex;flex-direction:column}
.mnav nav a{font-size:22px;min-height:48px;display:flex;align-items:center;border-bottom:1px solid rgba(255,255,255,.12)}
.mnav-info{display:flex;flex-direction:column;gap:14px;font-size:16px;color:rgba(255,255,255,.88)}
.mnav-info small{display:block;font-size:13px;color:rgba(255,255,255,.65)}
.mnav-info>div{display:flex;flex-direction:column;align-items:flex-start}
.mnav-info a{min-height:44px;display:inline-flex;align-items:center}
@media (max-width:1360px){.nav-links{display:none}.burger{display:inline-flex}}
@media (max-width:900px){.hdr-addr{display:none}}
@media (max-width:600px){.hdr-duty,.hdr-cta{display:none}.hdr-call{display:inline-flex}.hdr-logo img{height:40px}}

/* ---------- Общие блоки ---------- */
.sec{padding:50px 0}
.eyebrow{margin:0;display:flex;align-items:center;gap:10px;font-size:15px;color:var(--ink-2)}
.eyebrow::before{content:"";width:7px;height:7px;border-radius:50%;background:currentColor;flex:none}
.eyebrow.light{color:rgba(255,255,255,.75)}
.h2{margin:20px 0 0;font-weight:400;font-size:clamp(40px,5.6vw,88px);line-height:.98;letter-spacing:-0.04em}
.h2-sm{margin:0;font-weight:400;font-size:clamp(32px,3.6vw,56px);line-height:1.02;letter-spacing:-0.035em}
.lead{margin:0;font-size:16px;line-height:1.55;color:var(--ink-2)}
.sec-head{display:flex;justify-content:space-between;align-items:flex-end;gap:32px 64px;flex-wrap:wrap}
.sec-head .lead{max-width:380px}
.btn{display:inline-flex;align-items:center;gap:16px;background:#fff;color:var(--navy);padding:8px 8px 8px 26px;border-radius:999px;font-size:16px;font-weight:500;min-height:58px;width:fit-content;border:0;cursor:pointer}
.btn i{width:42px;height:42px;border-radius:50%;background:var(--navy);color:#fff;display:flex;align-items:center;justify-content:center;font-style:normal}
.btn.dark{background:var(--navy);color:#fff}
.btn.dark i{background:#fff;color:var(--navy)}
.btn-line{display:inline-flex;align-items:center;gap:10px;min-height:44px;font-size:16px;font-weight:500}
.g2{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:48px 64px;align-items:center}

/* ---------- Карточки услуг ---------- */
.svc-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(320px,100%),1fr));gap:16px}
.card-svc{background:var(--card);border-radius:18px;padding:10px 10px 22px;display:flex;flex-direction:column;gap:18px;transition:background-color .35s ease}
.card-svc:hover{background:#fff;opacity:1}
.card-svc .thumb{aspect-ratio:5/4;border-radius:12px;overflow:hidden;background:#fff}
.card-svc .thumb img{width:100%;height:100%;object-fit:cover;display:block;transition:transform .6s cubic-bezier(.2,.7,.1,1)}
.card-svc:hover .thumb img{transform:scale(1.08)}
.card-svc .body{display:flex;flex-direction:column;gap:10px;padding:0 12px;flex:1}
.card-svc .num{font-size:14px;color:var(--muted)}
.card-svc h3{margin:0;font-size:26px;font-weight:400;letter-spacing:-0.03em;line-height:1.08}
.card-svc p{margin:0;font-size:15px;line-height:1.5;color:var(--ink-2)}
.card-svc .price{font-size:15px;font-weight:500;margin-top:auto;padding-top:12px;border-top:1px solid rgba(15,34,71,.12)}

/* ---------- Прайс ---------- */
.tab{font:inherit;cursor:pointer;border:1px solid rgba(15,34,71,.22);background:transparent;color:var(--navy);border-radius:999px;min-height:48px;padding:0 22px;display:inline-flex;align-items:center;gap:10px;font-size:16px}
.tab[aria-selected="true"]{background:var(--navy);border-color:var(--navy);color:#fff}
.tab span{font-size:13px;opacity:.7}
.tabs{display:flex;flex-wrap:wrap;gap:10px;margin-top:24px}
.pcols{column-count:2;column-gap:72px;margin-top:28px}
.prow{break-inside:avoid;border-bottom:1px solid var(--line);padding:15px 0}
.prow-main{display:flex;gap:16px;align-items:baseline}
.prow-num{width:30px;flex:none;font-size:13px;color:var(--muted);font-variant-numeric:tabular-nums}
.prow-title{flex:1;font-size:16px;line-height:1.4}
.prow-price{white-space:nowrap;font-size:16px;font-weight:500;font-variant-numeric:tabular-nums}
.prow-subs{display:flex;flex-direction:column;gap:8px;margin-top:10px;padding-left:46px}
.prow-sub{display:flex;gap:16px;align-items:baseline;font-size:15px;line-height:1.4}
.prow-sub span:first-child{flex:1;color:var(--ink-2)}
.prow-sub span:last-child{white-space:nowrap;font-variant-numeric:tabular-nums}
.price-note{margin-top:40px;display:flex;justify-content:space-between;align-items:center;gap:16px 32px;flex-wrap:wrap;font-size:14px;color:var(--muted)}
.price-note a{color:var(--navy);font-size:15px;font-weight:500;min-height:44px;display:inline-flex;align-items:center}
.price-sec+.price-sec{margin-top:56px}
.price-sec h2{margin:0;font-weight:400;font-size:clamp(30px,3.2vw,48px);letter-spacing:-0.03em}

/* ---------- До / после ---------- */
.case{font:inherit;cursor:pointer;border:1px solid rgba(15,34,71,.2);background:rgba(255,255,255,.35);border-radius:14px;padding:6px 14px 6px 6px;display:flex;align-items:center;gap:12px;color:var(--navy);font-size:15px;min-height:56px;text-align:left}
.case[aria-pressed="true"]{background:#fff;border-color:var(--navy)}
.case img{width:54px;height:44px;object-fit:cover;border-radius:9px;display:block}
.cases-pick{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:10px;margin-top:24px}
/* На широких экранах 5:4 выше окна: ограничиваем высотой окна минус шапка 84px и отступ, фото обрезается object-fit */
.ba{position:relative;aspect-ratio:5/4;max-height:max(320px,calc(100vh - 132px));max-height:max(320px,calc(100svh - 132px));border-radius:18px;overflow:hidden;background:var(--navy);--pos:50%}
.ba img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.ba .before{clip-path:inset(0 calc(100% - var(--pos)) 0 0)}
.ba-line{position:absolute;top:0;bottom:0;left:var(--pos);width:2px;margin-left:-1px;background:#fff;pointer-events:none}
.ba-knob{position:absolute;top:50%;left:50%;width:60px;height:60px;margin:-30px 0 0 -30px;border-radius:50%;background:#fff;color:var(--navy);display:flex;align-items:center;justify-content:center;box-shadow:0 6px 24px rgba(0,0,0,.25)}
.ba-tag{position:absolute;top:16px;padding:8px 14px;border-radius:999px;font-size:14px;pointer-events:none}
.ba input{position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:ew-resize}
.ba input:focus-visible~.ba-line .ba-knob{outline:3px solid var(--glow)}

/* ---------- Команда ---------- */
.team-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:32px 24px;margin-top:28px}
.team-grid article{display:flex;flex-direction:column;gap:22px}
.team-ph{aspect-ratio:3/4;border-radius:18px;overflow:hidden;background:#eceded}
.team-ph img{width:100%;height:100%;object-fit:cover;object-position:50% 18%;display:block}
.team-ph.contain{background:#fff;border:1px solid #ececee}
.team-ph.contain img{object-fit:contain;object-position:50% 100%}
.team-role{font-size:14px;color:var(--muted)}
.team-name{margin:0;font-weight:400;font-size:clamp(22px,2.4vw,34px);line-height:1.06;letter-spacing:-0.03em}
.team-name .serif{font-size:.88em}

/* ---------- Форма ---------- */
.form-card{background:var(--accent);color:#fff;border-radius:26px;padding:clamp(28px,4vw,64px);display:grid;grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr);gap:56px;align-items:center}
.form-card h2{margin:0;font-weight:400;font-size:clamp(44px,5.6vw,88px);line-height:.98;letter-spacing:-0.04em}
.form-card .sub{margin:22px 0 0;max-width:480px;font-size:18px;line-height:1.55;color:rgba(255,255,255,.9)}
.form-card .ph{border-radius:18px;overflow:hidden;overflow:clip;aspect-ratio:4/5}
.form-card .ph img{width:100%;height:100%;object-fit:cover;display:block}
.lead-form{margin-top:36px;display:flex;flex-direction:column;gap:14px;max-width:520px}
.lead-form .row{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(220px,100%),1fr));gap:14px}
.lead-form label.f{display:flex;flex-direction:column;gap:8px;font-size:14px;color:rgba(255,255,255,.9)}
.field{width:100%;min-height:56px;border-radius:12px;border:1px solid rgba(255,255,255,.4);background:rgba(255,255,255,.08);color:#fff;font:inherit;font-size:17px;padding:0 18px}
.field::placeholder{color:rgba(255,255,255,.7)}
.field[aria-invalid="true"]{border-color:#ffb4b4}
.pd-agree{display:flex;align-items:flex-start;gap:12px;font-size:14px;line-height:1.5;color:rgba(255,255,255,.92);cursor:pointer}
.pd-agree input{appearance:none;-webkit-appearance:none;flex:none;width:22px;height:22px;margin:0;border:1.5px solid rgba(255,255,255,.75);border-radius:6px;background:transparent;display:grid;place-content:center;cursor:pointer}
.pd-agree input::after{content:"";width:11px;height:6px;border-left:2px solid var(--navy);border-bottom:2px solid var(--navy);transform:rotate(-45deg) translate(1px,-1px);opacity:0}
.pd-agree input:checked{background:#fff;border-color:#fff}
.pd-agree input:checked::after{opacity:1}
.pd-agree input[aria-invalid="true"]{border-color:#ffb4b4}
.pd-agree a,.form-legal a{text-decoration:underline;text-underline-offset:3px}
.form-legal{margin:0;font-size:13px;line-height:1.5;color:rgba(255,255,255,.8)}
.send{margin-top:6px;min-height:58px;border:0;border-radius:999px;background:#fff;color:var(--navy);font-size:17px;font-weight:500;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;gap:12px}
.send[disabled]{opacity:.6;cursor:progress}
.form-msg{margin:0;font-size:15px;line-height:1.5;min-height:1.5em}
.form-msg.err{color:#ffd0d0}
/* ---------- Окно записи ---------- */
.lead-modal{border:0;padding:0;margin:auto;background:transparent;color:#fff;width:min(560px,calc(100vw - 24px));max-width:none;max-height:calc(100dvh - 24px);overflow:visible}
.lead-modal::backdrop{background:rgba(8,18,40,.66)}
.lm-box{position:relative;background:var(--navy);border-radius:24px;padding:40px 32px 28px;max-height:calc(100dvh - 24px);overflow:auto;box-shadow:0 30px 80px rgba(0,0,0,.35)}
.lm-box h2{margin:0;padding-right:44px;font-weight:400;font-size:clamp(32px,4.4vw,48px);line-height:1;letter-spacing:-0.035em}
.lm-box .sub{margin:14px 0 0;font-size:16px;line-height:1.5;color:rgba(255,255,255,.86)}
.lm-box .lead-form{margin-top:24px;max-width:none}
.lm-close{position:absolute;top:16px;right:16px;width:44px;height:44px;border-radius:50%;border:1px solid rgba(255,255,255,.35);background:none;color:#fff;display:grid;place-items:center;cursor:pointer}
.lm-close:hover{background:rgba(255,255,255,.1)}
.lm-call{margin:6px 0 0;font-size:15px;color:rgba(255,255,255,.8)}
.lm-call a{color:#fff;white-space:nowrap}
html:has(.lead-modal[open]){overflow:hidden}
.motion .lead-modal[open] .lm-box{animation:lmIn .35s cubic-bezier(.2,.7,.1,1)}
@keyframes lmIn{from{opacity:0;transform:translateY(18px) scale(.98)}to{opacity:1;transform:none}}
@media (max-width:460px){.lm-box{padding:32px 20px 22px;border-radius:20px}.lm-close{top:12px;right:12px}}
@media (prefers-reduced-motion:reduce){.motion .lead-modal[open] .lm-box{animation:none}}

/* ---------- Кнопка звонка дежурному врачу ---------- */
.call-float{position:fixed;right:24px;bottom:24px;z-index:80;width:62px;height:62px;border-radius:50%;background:#16a34a;color:#fff;display:grid;place-items:center;box-shadow:0 10px 28px rgba(22,163,74,.45);transition:transform .2s ease}
.call-float:hover{transform:scale(1.07)}
.call-float:focus-visible{outline:3px solid var(--navy);outline-offset:3px}
.call-float svg{position:relative;width:30px;height:30px;animation:callRing 2.4s ease-in-out infinite}
.call-float::before,.call-float::after{content:"";position:absolute;inset:0;border-radius:50%;background:#16a34a;animation:callPulse 2.4s cubic-bezier(.2,.6,.3,1) infinite}
.call-float::after{animation-delay:1.2s}
@keyframes callPulse{from{transform:scale(1);opacity:.5}to{transform:scale(1.9);opacity:0}}
@keyframes callRing{0%,40%,100%{transform:none}5%,15%,25%{transform:rotate(-14deg)}10%,20%,30%{transform:rotate(14deg)}}
/* Пока открыт баннер cookie, кнопка не нужна: баннер стоит в том же углу. */
body:has(#cookie-banner:not([hidden])) .call-float{display:none}
@media (max-width:460px){.call-float{right:16px;bottom:16px;width:56px;height:56px}.call-float svg{width:27px;height:27px}}
@media (prefers-reduced-motion:reduce){.call-float::before,.call-float::after{animation:none;opacity:0}.call-float svg{animation:none}}
@media print{.call-float{display:none}}
.hp{position:absolute!important;left:-9999px!important;width:1px;height:1px;overflow:hidden}

/* ---------- Внутренние страницы ---------- */
/* Заголовок первого экрана в две строки. Самая длинная строка — 9.44 × размер шрифта.
   52px: строка шириной ~491px кончается до края сплошного синего (hx + 500px, см. .hero-scrim).
   На узких экранах шрифт уменьшается, чтобы обе строки вошли в ширину. */
/* «Стоматология» ≈ 6.3em: делитель 6.6 держит строку в ширине экрана на телефоне, а 78px на десктопе заканчивают её до перехода в фото */
.hero-title{margin:0;font-weight:400;font-size:min(78px,calc((100vw - 2 * var(--hx)) / 6.6));line-height:1.02;letter-spacing:-0.035em}
.hero-title>span{display:block;white-space:nowrap}
.page-hero{background:var(--navy);color:#fff;padding:36px 0 56px}
.crumbs ol{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;gap:6px 10px;font-size:14px;color:rgba(255,255,255,.7)}
.crumbs li+li::before{content:"/";margin-right:10px;opacity:.5}
.crumbs a{min-height:32px;display:inline-flex;align-items:center}
.page-hero h1{margin:28px 0 0;font-weight:400;font-size:clamp(40px,6vw,92px);line-height:.98;letter-spacing:-0.04em;max-width:1100px;text-wrap:balance}
.page-hero .lead{margin-top:24px;max-width:640px;font-size:18px;color:rgba(255,255,255,.88)}
.page-hero .acts{display:flex;flex-wrap:wrap;gap:14px 28px;align-items:center;margin-top:32px}
.page-hero.small h1{font-size:clamp(34px,4.4vw,64px)}
/* Декоративные номера карточек «почему мы». Текст в ::before: проверка контраста Lighthouse
   не считает его текстом, а бледный цвет здесь задуман дизайном. */
.why-num::before{content:attr(data-n);display:block;font-size:clamp(72px,8.5vw,136px);line-height:.9;color:#e4e5e7;letter-spacing:-0.05em}
.sec.white{background:#fff}.sec.grey{background:var(--bg-2)}.sec.light{background:var(--bg)}
.svc-photo{border-radius:18px;overflow:hidden;aspect-ratio:5/4;background:#fff}
.svc-photo img{width:100%;height:100%;object-fit:cover;display:block}
.text{font-size:18px;line-height:1.6;color:var(--ink-2)}
.text p{margin:0 0 16px}
.text p:last-child{margin-bottom:0}
.feats{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(230px,100%),1fr));gap:36px;border-top:1px solid var(--line);padding-top:32px}
.feats div{display:flex;flex-direction:column;gap:12px}
.feats span{font-size:14px;color:var(--muted)}
.feats h3{margin:0;font-size:24px;font-weight:500;letter-spacing:-0.02em}
.feats p{margin:0;font-size:16px;line-height:1.55;color:var(--ink-2)}
.chips{display:flex;flex-wrap:wrap;gap:10px}
.chips a{border:1px solid rgba(15,34,71,.22);border-radius:999px;min-height:44px;padding:0 20px;display:inline-flex;align-items:center;font-size:15px}
.chips a:hover{background:#fff;opacity:1}

/* ---------- Контакты ---------- */
.contact-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(300px,100%),1fr));gap:16px;margin-top:28px}
.c-card{background:#fff;border-radius:18px;padding:28px;display:flex;flex-direction:column;gap:18px;min-height:300px}
.c-card.dark{background:var(--navy);color:#fff}
.c-card .lbl{font-size:14px;color:var(--muted)}
.c-card.dark .lbl{color:rgba(255,255,255,.75)}
.c-card .addr{margin:0;font-size:26px;line-height:1.15;letter-spacing:-0.02em}
.c-card .city{margin:0;font-size:15px;color:var(--ink-2)}
.c-card .links{margin-top:auto;display:flex;flex-direction:column;gap:6px;font-size:17px}
.c-card .links a{display:inline-flex;align-items:center;gap:10px;min-height:44px;font-variant-numeric:tabular-nums}
.c-card .duty{font-size:30px;line-height:1.1;letter-spacing:-0.02em;font-variant-numeric:tabular-nums}
.c-card .small{font-size:15px;color:rgba(255,255,255,.8);display:flex;flex-direction:column;gap:6px}
.hours{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(200px,100%),1fr));gap:10px 32px;font-size:15px}
.hours div{display:flex;flex-direction:column;gap:6px}
.hours small{font-size:13px;opacity:.8}

/* ---------- Документы и юридические тексты ---------- */
.prose{max-width:860px;font-size:17px;line-height:1.65;color:#1d2b4a}
.prose h2{margin:48px 0 16px;font-size:clamp(24px,2.4vw,32px);font-weight:500;letter-spacing:-0.02em;line-height:1.2;color:var(--navy)}
.prose h2:first-child{margin-top:0}
.prose [id]{scroll-margin-top:110px}
/* Якоря меню ведут на блоки главной: блок встаёт сразу под липкой шапкой */
main section[id]{scroll-margin-top:84px}
.prose h3{margin:28px 0 10px;font-size:20px;font-weight:500;color:var(--navy)}
.prose p{margin:0 0 14px}
.prose ul,.prose ol{margin:0 0 16px;padding-left:24px}
.prose li{margin-bottom:6px}
.prose a{text-decoration:underline;text-underline-offset:3px}
.prose .meta{font-size:15px;color:var(--muted)}
.prose .box{background:var(--card);border-radius:14px;padding:20px 24px;margin:0 0 18px}
.prose .table{overflow-x:auto;margin:0 0 20px;border:1px solid var(--line);border-radius:14px}
.prose table{border-collapse:collapse;width:100%;min-width:640px;font-size:15px;line-height:1.5}
.prose th,.prose td{text-align:left;vertical-align:top;padding:12px 14px;border-bottom:1px solid var(--line)}
.prose th{background:var(--card);font-weight:500;color:var(--navy)}
.prose tr:last-child td{border-bottom:0}
.toc{background:var(--card);border-radius:14px;padding:20px 24px;margin:0 0 32px;font-size:16px}
.toc ol{margin:8px 0 0;padding-left:22px}
.toc a{text-decoration:none}
.toc a:hover{text-decoration:underline}
.req{display:grid;grid-template-columns:minmax(160px,.4fr) minmax(0,1fr);border-top:1px solid var(--line);font-size:16px;line-height:1.5;margin:0 0 20px}
.req dt,.req dd{margin:0;padding:12px 0;border-bottom:1px solid var(--line)}
.req dt{color:var(--muted);padding-right:20px}
.scans{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,1fr));gap:14px;margin:12px 0 24px}
.scans a{display:block;border-radius:12px;overflow:hidden;border:1px solid var(--line);background:#fff;text-decoration:none}
.scans img{display:block;width:100%;aspect-ratio:3/4;object-fit:cover;object-position:top}
.scans span{display:block;padding:10px 12px;font-size:14px;line-height:1.35;color:var(--ink-2)}
.todo{background:#fff3c4;border-radius:4px;padding:0 4px}
.linklike{background:none;border:0;padding:0;font:inherit;color:inherit;text-decoration:underline;text-underline-offset:3px;cursor:pointer}

/* ---------- Подвал ---------- */
.site-footer{background:var(--navy);color:#fff;padding:40px 0 24px;overflow:hidden}
.ft-cols{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(220px,100%),1fr));gap:40px}
.ft-cols>div{display:flex;flex-direction:column;gap:10px;align-items:flex-start}
.ft-cols .lbl{font-size:14px;color:rgba(255,255,255,.7)}
.ft-cols a,.ft-cols button{font-size:18px;min-height:36px;display:inline-flex;align-items:center}
.ft-cols .num{font-variant-numeric:tabular-nums}
.cookie-btn{background:none;border:0;padding:0;color:inherit;cursor:pointer;text-align:left}
.ft-warn{margin:40px 0 0;padding:22px 0;border-top:1px solid rgba(255,255,255,.16);border-bottom:1px solid rgba(255,255,255,.16);font-size:clamp(18px,2vw,26px);letter-spacing:-0.01em;text-transform:uppercase}
.ft-warn-static{margin:0}
.ft-warn-run{display:none;overflow:hidden;-webkit-mask-image:linear-gradient(90deg,transparent,#000 3%,#000 97%,transparent);mask-image:linear-gradient(90deg,transparent,#000 3%,#000 97%,transparent)}
/* 6 одинаковых фраз, сдвиг на половину дорожки (3 фразы) даёт бесшовный повтор */
.ft-warn-track{display:flex;width:max-content;animation:ftRun 70s linear infinite}
.ft-warn-track span{flex:none;white-space:nowrap;padding-right:1em}
.ft-warn-run:hover .ft-warn-track{animation-play-state:paused}
@keyframes ftRun{from{transform:translateX(0)}to{transform:translateX(-50%)}}
@media (prefers-reduced-motion:no-preference){
  .ft-warn-static{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
  .ft-warn-run{display:block}
}
@media (max-width:600px){.ft-warn-track{animation-duration:40s}}
.ft-bottom{display:flex;justify-content:space-between;gap:12px 32px;flex-wrap:wrap;margin-top:24px;font-size:14px;line-height:1.5;color:rgba(255,255,255,.72)}

/* ---------- Cookie-баннер ---------- */
.ck{position:fixed;left:16px;right:16px;bottom:16px;z-index:90;max-width:560px;margin-left:auto;background:#fff;color:var(--navy);border-radius:18px;padding:22px 22px 20px;box-shadow:0 18px 60px rgba(15,34,71,.28);font-size:15px;line-height:1.5}
.ck[hidden]{display:none}
.ck h2{margin:0 0 8px;font-size:18px;font-weight:600;letter-spacing:-0.01em}
.ck p{margin:0;color:var(--ink-2)}
.ck a{text-decoration:underline;text-underline-offset:3px}
.ck-acts{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:16px}
.ck-acts button{min-height:48px;border-radius:999px;border:1px solid var(--navy);font-size:16px;font-weight:500;cursor:pointer;background:#fff;color:var(--navy)}
.ck-acts button.yes{background:var(--navy);color:#fff}

/* ---------- Анимации (как в дизайне) ---------- */
@keyframes fadeUp{from{opacity:0;transform:translateY(24px)}to{opacity:1;transform:none}}
@keyframes heroImg{from{opacity:0;transform:scale(1.06) translateY(30px)}to{opacity:1;transform:none}}
@keyframes rise{from{opacity:0;transform:translateY(56px)}to{opacity:1;transform:none}}
@keyframes riseS{from{opacity:0;transform:translateY(18px)}to{opacity:1;transform:none}}
@keyframes clipUp{from{clip-path:inset(100% 0 0 0 round 18px)}to{clip-path:inset(0 0 0 0 round 18px)}}
@keyframes zoomOut{from{transform:scale(1.25)}to{transform:scale(1)}}
@keyframes fillText{from{background-size:0% 100%,100% 100%}to{background-size:100% 100%,100% 100%}}
@keyframes slideL{from{transform:translateX(6%)}to{transform:translateX(-34%)}}
@keyframes mqL{from{transform:translateX(0)}to{transform:translateX(-24%)}}
@keyframes mqR{from{transform:translateX(-24%)}to{transform:translateX(0)}}
@keyframes progress{from{transform:scaleX(0)}to{transform:scaleX(1)}}
/* Первый экран появляется почти без задержки: пока текст прозрачен, браузер не засчитывает LCP. */
.motion .ld0{animation:fadeUp .6s cubic-bezier(.2,.7,.1,1) both}
.motion .ld2{animation:fadeUp .6s .1s cubic-bezier(.2,.7,.1,1) both}
.motion .hero-bg{animation:heroImg 1.6s cubic-bezier(.2,.7,.1,1) both}
/* Блоки, внутри которых есть анимации с view(), обрезаются через overflow:clip, а не hidden:
   hidden делает блок scroll-контейнером, анимация привязывается к нему и не двигается при прокрутке страницы. */
@supports (animation-timeline: view()){
  .motion .rv{animation:rise linear both;animation-timeline:view();animation-range:entry 0% entry 35%}
  .motion .rv2{animation:rise linear both;animation-timeline:view();animation-range:entry 5% entry 42%}
  .motion .rv3{animation:rise linear both;animation-timeline:view();animation-range:entry 10% entry 50%}
  .motion .rvs{animation:riseS linear both;animation-timeline:view();animation-range:entry 0% entry 100%}
  .motion .team-grid>article{animation:rise linear both;animation-timeline:view();animation-range:entry 0% entry 40%}
  .motion .team-grid>article:nth-child(3n+2){animation-range:entry 8% entry 50%}
  .motion .team-grid>article:nth-child(3n){animation-range:entry 16% entry 60%}
  .motion .clip{animation:clipUp linear both;animation-timeline:view();animation-range:entry 0% cover 45%}
  .motion .zoom{animation:zoomOut linear both;animation-timeline:view();animation-range:cover 0% cover 100%}
  .motion .fill{animation:fillText linear both;animation-timeline:view();animation-range:cover 18% cover 58%}
  .motion .ghostL{animation:slideL linear both;animation-timeline:view();animation-range:cover 0% cover 100%}
  .motion .mqL{animation:mqL linear both;animation-timeline:view();animation-range:cover 0% cover 100%}
  .motion .mqR{animation:mqR linear both;animation-timeline:view();animation-range:cover 0% cover 100%}
  .motion .progress{animation:progress linear both;animation-timeline:scroll(root)}
}
@media (prefers-reduced-motion: reduce){.motion *{animation:none!important}}

/* ---------- Адаптив ---------- */
@media (max-width:900px){
  .wrap{padding-left:20px;padding-right:20px}
  .sec{padding-top:32px;padding-bottom:32px}
  .g2,.form-card{grid-template-columns:minmax(0,1fr)!important}
  .hero{--hx:20px}
  .hero-main{flex-direction:column!important;align-items:stretch!important;min-height:0!important}
  .hero-photo{position:relative!important;left:0!important;height:260px!important}
  .hero-scrim{display:none!important}
  .hero-copy{width:auto!important;padding:28px 20px 32px!important}
  .why-card{position:relative!important;top:auto!important;min-height:0!important;padding:24px!important;grid-template-columns:minmax(0,1fr)!important}
  .pcols{column-count:1}
  .hide-sm{display:none!important}
  .mq-img{width:300px!important;height:200px!important}
  .team-grid{gap:28px 16px}
  .req{grid-template-columns:minmax(0,1fr)}
  .req dt{padding-bottom:0;border-bottom:0}
  .page-hero{padding:24px 0 40px}
  /* До/после на телефоне: текст, сразу фото, под ним вплотную ряд из 5 миниатюр */
  .cases-grid{row-gap:0}
  .cases-text{display:contents}
  .cases-grid .ba{order:1;margin-top:20px}
  .cases-pick{order:2;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px;margin-top:10px}
  .case{flex-direction:column;justify-content:center;gap:4px;padding:4px 4px 6px;min-height:0;border-radius:12px;font-size:13px;text-align:center}
  .case img{width:100%;height:auto;max-height:72px;aspect-ratio:5/4;border-radius:8px}
  .case-w{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
}
@media (max-width:720px){.team-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (max-width:460px){.team-grid{grid-template-columns:minmax(0,1fr)}.ck{left:10px;right:10px;bottom:10px;padding:16px 16px 14px;font-size:14px;line-height:1.45}.ck h2{font-size:16px;margin-bottom:6px}.ck-acts{margin-top:12px}.ck-acts button{min-height:44px;font-size:15px}}
@media print{.site-header,.site-footer,.ck,.progress,.form-sec{display:none!important}body,.dn{background:#fff}}
