/*
 * NorthMed (стиль «Строгий стандарт»): белая бумага, глубокий тёмно-синий, тонкие линейки.
 * Шрифты: Archivo (узковатая ширина для заголовков, обычная для текста), IBM Plex Mono (телефон, часы,
 * номера, счётчики), Noto Sans Georgian (ka). Скругления почти нулевые: прямоугольник — часть характера.
 * Главный приём — первый экран как разлинованный бланк: линии прочерчиваются по очереди, на пересечениях
 * появляются метки совмещения, числа считаются; полоса со статусом «открыто до…» и телефоном всегда сверху.
 * @author Maksym Mariukhnik <max@absoluteweb.com>
 */
:root {
    --navy: #0b2545;
    --navy-2: #173a6a;
    --ink: #0d1b2e;
    --muted: #556275;
    --paper: #fff;
    --band: #f3f5f8;
    --tint: #e9eff8;
    --line: #dde3eb;
    --line-2: #b8c2d0;
    --rule: #0b2545;
    --ok: #3ccf91;
    --closed: #f2b84b;
    --sans: 'Archivo', 'Noto Sans Georgian', system-ui, -apple-system, sans-serif;
    --ka: 'Noto Sans Georgian', 'Archivo', system-ui, sans-serif;
    --mono: 'IBM Plex Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;
    --strip-h: 40px;

    --bk-accent: var(--navy);
    --bk-on-accent: #fff;
    --bk-radius: 4px;
    --bk-font: var(--sans);
    --bk-ink: var(--ink);
    --bk-muted: var(--muted);
    --bk-line: var(--line-2);
    --bk-soft: var(--band);
    --bk-surface: #fff;

    --m-bg: var(--band);
    --m-accent: var(--navy);
    --m-on-accent: #fff;
    --m-line: var(--line);
    --m-chip: #fff;
    --m-chip-hover: var(--tint);
    --m-radius: 2px;
    --m-btn-radius: 2px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 130px; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 16px/1.55 var(--sans); -webkit-font-smoothing: antialiased; }
:lang(ka) body, :lang(ka) .bk-overlay { font-family: var(--ka); }
:lang(ka) { --bk-font: var(--ka); --cf-font: var(--ka); }
img { max-width: 100%; display: block; }
a { color: inherit; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; letter-spacing: -.01em; }
.wrap { max-width: 1280px; margin: 0 auto; padding: 0 40px; }
:where(a, button, input, textarea, iframe, [tabindex]):focus-visible { outline: 2px solid var(--navy); outline-offset: 3px; }
.strip :focus-visible, .foot :focus-visible, .plate:focus-visible { outline-color: #fff; }

/* ---- Кнопки: прямоугольные, тёмно-синие ---- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 52px; padding: 0 26px;
    border: 0; border-radius: 2px; background: var(--navy); color: #fff; cursor: pointer;
    font: 600 16px/1.2 var(--sans); text-decoration: none; text-align: center; transition: background .15s, color .15s, box-shadow .15s;
}
:lang(ka) .btn { font-family: var(--ka); font-size: 15px; }
.btn:hover { background: var(--navy-2); }
.btn.ghost, .btn-ghost, .svc-book { background: transparent; color: var(--navy); box-shadow: inset 0 0 0 1px var(--navy); }
.btn.ghost:hover, .btn-ghost:hover, .svc-book:hover { background: var(--tint); }
.shine::after { background: linear-gradient(105deg, transparent 0%, rgba(255, 255, 255, .32) 50%, transparent 100%) !important; }

/* ---- Полоса: статус, часы, телефон — всегда сверху ---- */
.strip { position: sticky; top: 0; z-index: 60; background: var(--navy); color: #fff; font-size: 14px; }
.strip .wrap { display: flex; align-items: center; gap: 28px; min-height: var(--strip-h); }
.strip p { margin: 0; white-space: nowrap; }
.st { display: inline-flex; align-items: center; gap: 9px; font-weight: 600; }
.st .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--closed); flex: none; }
.st.is-open .dot { background: var(--ok); box-shadow: 0 0 0 3px rgba(60, 207, 145, .22); }
.st-short { display: none; }
.st-hours, .st-addr { color: rgba(255, 255, 255, .72); }
.st-hours { padding-left: 28px; border-left: 1px solid rgba(255, 255, 255, .2); }
.st-phone { display: inline-flex; align-items: center; gap: 8px; margin-left: auto; color: #fff; text-decoration: none; font-weight: 500; font-size: 15px; white-space: nowrap; }
.st-phone svg { opacity: .8; }
.st-phone:hover .mono { text-decoration: underline; text-underline-offset: 4px; }

/* ---- Шапка ---- */
.top { position: sticky; top: var(--strip-h); z-index: 50; background: rgba(255, 255, 255, .96); border-bottom: 1px solid var(--line); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.top .wrap { display: flex; align-items: center; gap: 28px; min-height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 11px; font: 700 23px/1 var(--sans); font-stretch: 88%; letter-spacing: -.01em; text-decoration: none; color: var(--navy); flex: none; }
.nav { display: flex; align-self: stretch; gap: 4px; margin-left: 8px; }
.nav a { display: flex; align-items: center; padding: 0 12px; color: var(--muted); text-decoration: none; font-size: 15px; font-weight: 500; white-space: nowrap; box-shadow: inset 0 -2px 0 transparent; transition: color .15s, box-shadow .15s; }
.nav a:hover { color: var(--navy); box-shadow: inset 0 -2px 0 var(--line-2); }
body[data-page="home"] .nav a[data-href="home"],
body[data-page="services"] .nav a[data-href="services"],
body[data-page="doctors"] .nav a[data-href="doctors"],
body[data-page="about"] .nav a[data-href="about"],
body[data-page="contacts"] .nav a[data-href="contacts"] { color: var(--navy); box-shadow: inset 0 -2px 0 var(--navy); }
.langs { display: flex; margin-left: auto; border: 1px solid var(--line-2); border-radius: 2px; }
.langs button { min-width: 40px; height: 34px; padding: 0 8px; border: 0; background: none; color: var(--muted); cursor: pointer; font: 500 13px/1 var(--sans); }
.langs button + button { border-left: 1px solid var(--line); }
.langs button:hover { color: var(--navy); background: var(--band); }
.langs button[aria-pressed="true"] { background: var(--navy); color: #fff; }
.top-book { min-height: 42px; padding: 0 20px; font-size: 15px; flex: none; }

/* ---- Первый экран: разлинованный лист ---- */
.hero { padding: 28px 0 80px; }
.sheet { position: relative; display: grid; grid-template-columns: minmax(0, 6.2fr) minmax(0, 5fr); grid-template-areas: "copy photo" "metrics metrics"; }
.sheet::before, .sheet::after { content: ""; position: absolute; left: 0; right: 0; height: 1px; background: var(--rule); transform-origin: 0 50%; }
.sheet::before { top: 0; }
.sheet::after { bottom: 0; }
.reg { position: absolute; z-index: 2; width: 13px; height: 13px; margin: -6px 0 0 -6px; pointer-events: none;
    background: linear-gradient(var(--rule), var(--rule)) 50% 0 / 1px 100% no-repeat, linear-gradient(var(--rule), var(--rule)) 0 50% / 100% 1px no-repeat; }
.sheet > .r-tl { top: 0; left: 0; }
.sheet > .r-tr { top: 0; left: 100%; }

.sheet-copy { grid-area: copy; padding: 44px 56px 48px 0; display: flex; flex-direction: column; justify-content: center; }
.depts-line { display: flex; flex-wrap: wrap; gap: 6px 0; margin: 0 0 26px; color: var(--navy); font-size: 15px; font-weight: 600; }
.depts-line span { padding: 0 16px; border-left: 1px solid var(--line-2); }
.depts-line span:first-child { padding-left: 0; border-left: 0; }
.hero h1 { margin: 0 0 24px; color: var(--navy); font: 650 clamp(44px, 4.5vw, 66px)/1 var(--sans); font-stretch: 78%; letter-spacing: -.022em; text-wrap: balance; }
:lang(ka) .hero h1 { font: 700 clamp(32px, 3.4vw, 50px)/1.22 var(--ka); font-stretch: 88%; letter-spacing: 0; }
.lead { margin: 0 0 32px; max-width: 44ch; color: var(--muted); font-size: 19px; line-height: 1.55; }
:lang(ka) .lead { font-size: 17px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

.sheet-photo { grid-area: photo; position: relative; margin: 0; min-height: 480px; }
.sheet-photo::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 1px; background: var(--rule); transform-origin: 50% 0; }
.sheet-photo img { position: absolute; top: 28px; bottom: 28px; left: 28px; width: calc(100% - 28px); height: calc(100% - 56px); object-fit: cover; object-position: 28% 50%; filter: saturate(.78) contrast(1.03); background: var(--band); }
.plates { position: absolute; left: 0; bottom: 64px; display: flex; flex-direction: column; align-items: flex-start; gap: 0; }
.plate { display: flex; align-items: center; gap: 14px; padding: 14px 20px; }
.plate-years { background: var(--navy); color: #fff; }
.plate-years b { font-size: 46px; font-weight: 600; line-height: 1; letter-spacing: -.04em; }
.plate-years > span { font-size: 15px; font-weight: 600; line-height: 1.25; }
.plate-years small { color: rgba(255, 255, 255, .7); font-weight: 400; font-size: 13px; }
.plate-lic { flex-direction: column; align-items: flex-start; gap: 2px; max-width: 290px; background: #fff; color: var(--navy); box-shadow: inset 0 0 0 1px var(--navy); }
.plate-lic small { font-size: 12.5px; line-height: 1.3; color: var(--muted); }
.plate-lic b { font-size: 19px; font-weight: 600; }

.metrics { grid-area: metrics; position: relative; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 0; padding: 0; list-style: none; }
.metrics li { position: relative; padding: 22px 28px 26px; }
.metrics li:first-child { padding-left: 0; }
.metrics li::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px; background: var(--rule); transform-origin: 0 50%; }
.metrics li + li::after { content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 1px; background: var(--line-2); transform-origin: 50% 0; }
.metrics .reg { top: 0; left: 0; }
.metrics b { display: block; color: var(--navy); font-size: 40px; font-weight: 500; line-height: 1; letter-spacing: -.04em; }
.metrics span { display: block; margin-top: 10px; max-width: 24ch; color: var(--muted); font-size: 14.5px; line-height: 1.4; }

/* ---- Разделы ---- */
.sec { padding: 104px 0; }
.sec-head { position: relative; display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 12px 24px; margin-bottom: 44px; padding-bottom: 22px; }
.sec-head::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--rule); transform-origin: 0 50%; }
.h2 { margin: 0; color: var(--navy); font: 650 clamp(32px, 3.3vw, 48px)/1.05 var(--sans); font-stretch: 80%; letter-spacing: -.02em; }
:lang(ka) .h2 { font: 700 clamp(25px, 2.5vw, 34px)/1.3 var(--ka); font-stretch: 88%; letter-spacing: 0; }
.more-link { color: var(--navy); font-weight: 500; text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 6px; }
.more-link:hover { text-decoration-color: var(--navy); }

/* Стандарт приёма: четыре обязательства на сером поле */
.std-sec { background: var(--band); }
.std { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2.4fr); gap: 0 64px; align-items: start; }
.std-head { margin: 0; padding-bottom: 0; }
.std-head::after { display: none; }
.std-list { list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 48px; margin: 0; padding: 0; }
.std-list li { position: relative; padding-top: 20px; border-top: 1px solid var(--rule); }
.tick { display: block; margin-bottom: 14px; fill: none; stroke: var(--navy); stroke-width: 2.2; stroke-linecap: square; }
.std-list h3 { margin: 0 0 8px; color: var(--navy); font: 600 20px/1.25 var(--sans); }
:lang(ka) .std-list h3 { font: 700 17px/1.4 var(--ka); }
.std-list p { margin: 0; max-width: 40ch; color: var(--muted); font-size: 15.5px; }

/* Отделения: три колонки-таблицы */
.deps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.dep { display: flex; flex-direction: column; padding: 0 32px; border-left: 1px solid var(--line); }
.dep:first-child { padding-left: 0; border-left: 0; }
.dep:last-child { padding-right: 0; }
.dep-head h3 { margin: 0 0 16px; color: var(--navy); font: 650 26px/1.15 var(--sans); font-stretch: 82%; letter-spacing: -.01em; }
:lang(ka) .dep-head h3 { font: 700 21px/1.3 var(--ka); }
.dep-doc { display: flex; align-items: center; gap: 12px; margin: 0 0 22px; font-size: 14.5px; font-weight: 600; line-height: 1.3; }
.dep-doc img { width: 44px; height: 44px; border-radius: 2px; object-fit: cover; object-position: 50% 15%; flex: none; }
.dep-doc small { display: block; color: var(--muted); font-weight: 400; font-size: 13px; }
.dep ul { list-style: none; margin: 0 0 24px; padding: 0; }
.dep li { padding: 16px 0; border-top: 1px solid var(--line); }
.dep h4 { margin: 0 0 4px; font: 600 16.5px/1.3 var(--sans); }
:lang(ka) .dep h4 { font-family: var(--ka); font-size: 15.5px; }
.dep li p { margin: 0; color: var(--muted); font-size: 14.5px; line-height: 1.5; }
.dep-book { margin-top: auto; width: 100%; min-height: 46px; font-size: 15px; }

/* Врачи: «личное дело» */
.docs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.doc { display: flex; flex-direction: column; background: #fff; box-shadow: inset 0 0 0 1px var(--line); }
.doc-ph { position: relative; aspect-ratio: 1 / 1; overflow: hidden; background: var(--band); }
.doc-ph img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 12%; filter: saturate(.85); }
.doc-body { flex: 1; display: flex; flex-direction: column; padding: 22px 24px 24px; }
.doc h3, .doc h2 { margin: 0; color: var(--navy); font: 650 22px/1.2 var(--sans); font-stretch: 85%; }
:lang(ka) .doc h3, :lang(ka) .doc h2 { font: 700 19px/1.35 var(--ka); }
.doc .role { margin: 4px 0 16px; color: var(--muted); font-size: 15px; }
.spec { margin: 0; font-size: 14px; }
.spec > div { display: grid; grid-template-columns: 104px minmax(0, 1fr); gap: 12px; padding: 9px 0; border-top: 1px solid var(--line); }
.spec > div:last-child { border-bottom: 1px solid var(--line); }
.spec dt { color: var(--muted); }
.spec dd { margin: 0; color: var(--ink); font-weight: 500; }
.doc .bio { margin: 16px 0 0; font-size: 15px; color: #2b3a50; }
.doc .row { margin-top: auto; padding-top: 20px; }
.doc .bk-book { width: 100%; }
.doc-inline { padding: 0 24px 24px; }
.doc-inline .bk-inline { margin-top: 0; }

/* О клинике */
.about-sec { background: var(--band); }
.about { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; align-items: center; }
.about-ph { margin: 0; }
.about-ph img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; filter: saturate(.78) contrast(1.03); }
.about-copy #about-text p { margin: 22px 0 0; font-size: 18px; max-width: 48ch; }
.lic-line { margin: 28px 0 32px; padding-top: 14px; border-top: 1px solid var(--line-2); color: var(--navy); font-size: 14px; }

/* Адрес и часы по дням */
.contact { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 64px; align-items: start; }
.addr { margin: 26px 0 22px; color: var(--navy); font: 600 26px/1.3 var(--sans); font-stretch: 90%; }
:lang(ka) .addr { font: 700 21px/1.4 var(--ka); }
.week { width: 100%; max-width: 440px; border-collapse: collapse; font-size: 15px; }
.week th, .week td { padding: 9px 10px; border-bottom: 1px solid var(--line); text-align: left; font-weight: 400; }
.week tr:first-child th, .week tr:first-child td { border-top: 1px solid var(--rule); }
.week td { text-align: right; }
.week .off { color: var(--muted); font-family: var(--sans); }
.week .is-today th, .week .is-today td { background: var(--tint); color: var(--navy); font-weight: 600; }
.week .is-today th { box-shadow: inset 3px 0 0 var(--navy); }
.btns { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }
.map iframe, .ct-map { display: block; width: 100%; height: 440px; border: 0; box-shadow: inset 0 0 0 1px var(--line); background: var(--band); filter: grayscale(.4) contrast(1.04); }

/* Футер */
.foot { background: var(--navy); color: rgba(255, 255, 255, .78); padding: 52px 0 36px; font-size: 14.5px; }
.foot .wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); gap: 28px 48px; }
.foot .brand { color: #fff; }
.foot .brand img { box-shadow: 0 0 0 1px rgba(255, 255, 255, .35); }
.foot-lic { margin: 14px 0 0; font-size: 13px; color: rgba(255, 255, 255, .62); }
.foot-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 40px; }
.foot-cols p { margin: 0; line-height: 1.7; }
.foot a { color: #fff; text-decoration: none; }
.foot a:hover { text-decoration: underline; text-underline-offset: 4px; }
.foot-links { display: inline-flex; flex-wrap: wrap; gap: 4px 18px; }
.foot-note { grid-column: 1 / -1; margin: 12px 0 0; padding-top: 20px; border-top: 1px solid rgba(255, 255, 255, .16); font-size: 13px; color: rgba(255, 255, 255, .55); }

/* ---- Внутренние страницы (общие блоки shared/pages и свой doctors.html) ---- */
.page { max-width: 1280px; margin: 0 auto; padding: 56px 40px 104px; }
.page-title { margin: 0 0 44px; padding-bottom: 24px; border-bottom: 1px solid var(--rule); color: var(--navy); font: 650 clamp(40px, 4.6vw, 66px)/1 var(--sans); font-stretch: 78%; letter-spacing: -.022em; }
:lang(ka) .page-title { font: 700 clamp(28px, 3.2vw, 42px)/1.3 var(--ka); font-stretch: 88%; letter-spacing: 0; }
.svc-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 56px; }
.svc-card { display: flex; flex-direction: column; align-items: flex-start; padding: 26px 0 30px; border-bottom: 1px solid var(--line); }
.svc-title { margin: 0 0 8px; color: var(--navy); font: 600 20px/1.3 var(--sans); }
:lang(ka) .svc-title { font: 700 17px/1.4 var(--ka); }
.svc-text { margin: 0 0 10px; font-size: 15.5px; color: #2b3a50; }
.svc-docs { margin: 0 0 18px; color: var(--muted); font-size: 14px; }
.svc-docs b { color: var(--ink); font-weight: 600; }
.svc-book { margin-top: auto; min-height: 44px; padding: 0 20px; font-size: 15px; }
.about-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 64px; align-items: start; }
.about-text p { margin: 0 0 20px; font-size: 18px; max-width: 54ch; }
.about-photo img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; filter: saturate(.78) contrast(1.03); }
.about-facts { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 64px 0 0; padding: 0; }
.about-facts li { padding: 22px 24px 0; border-top: 1px solid var(--rule); border-left: 1px solid var(--line-2); }
.about-facts li:first-child { padding-left: 0; border-left: 0; }
.about-facts strong { display: block; margin-bottom: 8px; color: var(--navy); font: 500 46px/1 var(--mono); letter-spacing: -.04em; }
.about-facts span { display: block; max-width: 22ch; color: var(--muted); font-size: 15px; }
.ct-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px 64px; align-items: start; }
.ct-list { margin: 0; }
.ct-list dt { margin: 0; padding-top: 14px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13.5px; }
.ct-list dt:first-child { border-top-color: var(--rule); }
.ct-list dd { margin: 2px 0 14px; color: var(--navy); font: 600 21px/1.35 var(--sans); }
:lang(ka) .ct-list dd { font: 700 18px/1.45 var(--ka); }
.ct-list a { text-underline-offset: 5px; text-decoration-color: var(--line-2); }
.ct-msgs { display: flex; flex-wrap: wrap; gap: 4px 20px; }
.ct-actions { display: flex; flex-wrap: wrap; gap: 12px; align-content: start; }
.ct-map { grid-column: 1 / -1; height: 400px; }

/* ---- Окно записи и блоки записи ---- */
.bk-dialog { border-radius: 4px; box-shadow: 0 0 0 1px var(--line-2), 0 30px 80px rgba(11, 37, 69, .28); }
.bk-dialog::before { content: ""; display: block; height: 4px; background: var(--navy); }
.bk-x, .bk-back { border-radius: 2px; }
.bk-time, .bk-chip, .bk-day b { font-family: var(--mono); }
.bk-chip { border-radius: 2px; }
.bk-pick img, .bk-sum img, .bk-row-who img { border-radius: 2px; object-position: 50% 15%; }
.bk-row { border-radius: 2px; }

/* Форма обратной связи: серое поле, тёмно-синяя линейка сверху, прямые углы */
[data-contact-form] {
    --cf-accent: var(--navy);
    --cf-on-accent: #fff;
    --cf-radius: 2px;
    --cf-btn-radius: 2px;
    --cf-ink: var(--ink);
    --cf-muted: var(--muted);
    --cf-line: var(--line-2);
    --cf-field-bg: #fff;
    --cf-error: #b42318;
    --cf-bg: var(--band);
    --cf-soft: #fff;
    --cf-pad: 44px;
    border-top: 2px solid var(--navy);
    margin-top: 72px;
}
.cf-intro h2 { color: var(--navy); font: 650 clamp(30px, 3.2vw, 42px)/1.05 var(--sans); font-stretch: 80%; letter-spacing: -.02em; }
:lang(ka) .cf-intro h2 { font: 700 clamp(24px, 2.5vw, 32px)/1.3 var(--ka); letter-spacing: 0; }
.cf-pill span { border-radius: 2px; }
.cf-tick { border-radius: 2px; }
@media (max-width: 820px) { [data-contact-form] { --cf-pad: 26px 18px; } }

/* ---- Движение: линии прочерчиваются, метки совмещения встают на место, числа считаются ---- */
@media (prefers-reduced-motion: no-preference) {
    .sheet::before { animation: nm-x 1.1s cubic-bezier(.65, 0, .25, 1) .1s backwards; }
    .sheet-photo::before { animation: nm-y .9s cubic-bezier(.65, 0, .25, 1) .55s backwards; }
    .metrics li::before { animation: nm-x .8s cubic-bezier(.65, 0, .25, 1) backwards; animation-delay: calc(.7s + var(--i, 0) * .12s); }
    .metrics li + li::after { animation: nm-y .6s cubic-bezier(.65, 0, .25, 1) backwards; animation-delay: calc(1s + var(--i, 0) * .12s); }
    .sheet::after { animation: nm-x 1.1s cubic-bezier(.65, 0, .25, 1) 1.1s backwards; }
    .reg { animation: nm-reg .5s cubic-bezier(.2, 1.4, .4, 1) backwards; animation-delay: calc(1.25s + var(--i, 0) * .1s); }
    .sheet > .r-tl { animation-delay: .15s; }
    .sheet > .r-tr { animation-delay: 1.15s; }
    .sheet-photo img { animation: nm-wipe 1.2s cubic-bezier(.65, 0, .25, 1) .45s backwards; }
    .plate { animation: nm-plate .7s cubic-bezier(.2, .8, .2, 1) backwards; }
    .plate-years { animation-delay: 1.25s; }
    .plate-lic { animation-delay: 1.4s; }
    .metrics li > b, .metrics li > span { animation: m-rise .7s cubic-bezier(.2, .7, .2, 1) backwards; animation-delay: calc(.9s + var(--i, 0) * .12s); }

    /* Линейка под заголовком раздела прочерчивается при прокрутке */
    html.motion .sec-head[data-reveal] { opacity: 1; transform: none; }
    html.motion .sec-head[data-reveal] > * { opacity: 0; transform: translateY(14px); }
    html.motion .sec-head[data-reveal]::after { transform: scaleX(0); }
    html.motion .sec-head[data-reveal].in > * { opacity: 1; transform: none; transition: opacity .7s ease .15s, transform .8s cubic-bezier(.2, .7, .2, 1) .15s; }
    html.motion .sec-head[data-reveal].in::after { transform: none; transition: transform 1.1s cubic-bezier(.65, 0, .25, 1); }
    html.motion [data-stagger].in .tick path { animation: nm-tick .6s cubic-bezier(.65, 0, .25, 1) backwards; animation-delay: .45s; }
    .tick path { stroke-dasharray: 24; }
    html.motion [data-stagger].in > :nth-child(2) .tick path { animation-delay: .55s; }
    html.motion [data-stagger].in > :nth-child(3) .tick path { animation-delay: .65s; }
    html.motion [data-stagger].in > :nth-child(4) .tick path { animation-delay: .75s; }
    .st.is-open .dot { animation: nm-beat 2.6s ease-in-out infinite; }
    .doc-ph img { transition: transform .8s cubic-bezier(.2, .8, .2, 1); }
    .doc:hover .doc-ph img { transform: scale(1.03); }
}
.metrics li:nth-child(2) { --i: 1; }
.metrics li:nth-child(3) { --i: 2; }
.metrics li:nth-child(4) { --i: 3; }
@keyframes nm-x { from { transform: scaleX(0); } }
@keyframes nm-y { from { transform: scaleY(0); } }
@keyframes nm-reg { from { opacity: 0; transform: rotate(-90deg) scale(.3); } }
@keyframes nm-wipe { from { clip-path: inset(0 0 100% 0); } }
@keyframes nm-plate { from { opacity: 0; transform: translateX(-14px); } }
@keyframes nm-tick { from { stroke-dashoffset: 24; } }
@keyframes nm-beat { 50% { box-shadow: 0 0 0 5px rgba(60, 207, 145, .1); } }

/* ---- Ширины ---- */
@media (max-width: 1180px) {
    .st-addr { display: none; }
    .nav a { padding: 0 9px; font-size: 14.5px; }
    .top .wrap { gap: 18px; }
}
@media (max-width: 980px) {
    html { scroll-padding-top: 56px; }
    .st-hours { display: none; }
    .wrap, .page { padding-left: 28px; padding-right: 28px; }
    .top { position: static; }
    .top .wrap { flex-wrap: wrap; row-gap: 0; min-height: 64px; padding-top: 10px; }
    .nav { order: 5; align-self: auto; width: calc(100% + 56px); margin: 8px -28px 0; padding: 0 18px; overflow-x: auto; scrollbar-width: none; border-top: 1px solid var(--line); }
    .nav::-webkit-scrollbar { display: none; }
    .nav a { min-height: 46px; }
    .sheet { grid-template-columns: minmax(0, 1fr); grid-template-areas: "copy" "photo" "metrics"; }
    .sheet-copy { padding: 44px 0 40px; }
    .sheet-photo { min-height: 0; padding: 0 0 28px; }
    .sheet-photo::before { display: none; }
    .sheet-photo img { position: static; width: 100%; height: auto; aspect-ratio: 16 / 9; }
    .plates { bottom: 52px; }
    .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .metrics li:nth-child(3) { padding-left: 0; }
    .metrics li:nth-child(3)::after { display: none; }
    .std { grid-template-columns: minmax(0, 1fr); gap: 36px; }
    .deps { grid-template-columns: minmax(0, 1fr); gap: 48px; }
    .dep { padding: 0; border-left: 0; }
    .docs { grid-template-columns: minmax(0, 1fr); gap: 20px; }
    .doc { flex-direction: row; flex-wrap: wrap; }
    .doc-ph { flex: 0 0 240px; aspect-ratio: auto; min-height: 280px; }
    .doc-body { flex: 1 1 300px; }
    [data-mode="inline"] .doc-inline { flex: 1 0 100%; padding-top: 0; }
    .about, .contact, .about-grid, .ct-grid, .svc-list { grid-template-columns: minmax(0, 1fr); }
    .about, .contact { gap: 40px; }
    .about-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 28px; }
    .about-facts li:nth-child(3) { padding-left: 0; border-left: 0; }
    .sec { padding: 80px 0; }
    .foot .wrap { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 760px) {
    .top-book { display: none; }
}
@media (max-width: 640px) {
    .wrap, .page { padding-left: 16px; padding-right: 16px; }
    .strip { font-size: 13px; }
    .strip .wrap { gap: 12px; }
    .st-text { display: none; }
    .st-short { display: inline; }
    .st-phone { font-size: 14px; gap: 6px; }
    .top .wrap { min-height: 58px; }
    .nav { width: calc(100% + 32px); margin: 8px -16px 0; padding: 0 6px; }
    .brand { font-size: 21px; }
    .hero { padding: 16px 0 56px; }
    /* Плашки лицензии и стажа — на первом экране сразу под заголовком */
    .sheet { display: flex; flex-direction: column; }
    .sheet-copy, .sheet-photo { display: contents; }
    .depts-line { order: 1; margin: 30px 0 18px; font-size: 14px; }
    .depts-line span { padding: 0 10px; }
    .hero h1 { order: 2; margin-bottom: 18px; font-size: 40px; }
    :lang(ka) .hero h1 { font-size: 27px; }
    .plates { order: 3; position: static; flex-direction: row; align-items: stretch; margin: 0 0 20px; }
    .plate { flex: 1 1 0; min-width: 0; padding: 12px 14px; }
    .plate-years { gap: 10px; }
    .plate-years b { font-size: 36px; }
    .plate-years > span { font-size: 13px; }
    .plate-years small { font-size: 12px; }
    .plate-lic b { font-size: 16px; }
    .plate-lic small { font-size: 11.5px; }
    .lead { order: 4; margin-bottom: 24px; font-size: 16.5px; }
    .hero-actions { order: 5; margin-bottom: 28px; }
    .hero-actions .btn { flex: 1 1 100%; }
    .sheet-photo img { order: 6; aspect-ratio: 3 / 2; }
    .metrics { order: 7; }
    .metrics li { padding: 18px 14px 22px; }
    .metrics li:nth-child(odd) { padding-left: 0; }
    .metrics b { font-size: 34px; }
    .metrics span { font-size: 13.5px; }
    .sheet > .r-tr { display: none; }
    .sec { padding: 64px 0; }
    .sec-head { margin-bottom: 32px; }
    .std-list { grid-template-columns: minmax(0, 1fr); gap: 28px; }
    .doc { flex-direction: column; }
    .doc-ph { flex: none; aspect-ratio: 1 / 1; min-height: 0; }
    .doc-body { flex: 1 1 auto; padding: 20px 18px 20px; }
    .doc-inline { padding: 0 18px 18px; }
    .spec > div { grid-template-columns: 92px minmax(0, 1fr); }
    .addr { font-size: 22px; }
    .btns .btn, .ct-actions .btn { flex: 1 1 100%; }
    .map iframe, .ct-map { height: 300px; }
    .page { padding-top: 36px; padding-bottom: 72px; }
    .page-title { margin-bottom: 32px; font-size: 42px; }
    .about-facts strong { font-size: 36px; }
    .about-facts li { padding-left: 14px; }
    .about-facts li:nth-child(odd) { padding-left: 0; border-left: 0; }
    .ct-list dd { overflow-wrap: anywhere; }
    .foot-cols { grid-template-columns: minmax(0, 1fr); }
}
