/* ═══════════════════════════════════════════════
   Ак юл — Белый путь Татарстана
   Палитра: изумруд (флаг РТ), рубин, золото орнамента, кремовая бумага
   ═══════════════════════════════════════════════ */
:root {
  --bg: #F4EEE2;
  --paper: #FBF8F1;
  --card: #FFFFFF;
  --ink: #18211E;
  --ink-2: #3A4642;
  --muted: #6A7570;
  --line: rgba(24, 33, 30, .12);
  --emerald: #0E4D3C;
  --emerald-2: #13634D;
  --emerald-deep: #082A21;
  --ruby: #B23A2E;
  --gold: #C99A3B;
  --gold-soft: #E8D3A2;
  --serif: "Cormorant Garamond", "Times New Roman", serif;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --r: 18px;
  --r-sm: 12px;
  --shadow: 0 1px 2px rgba(8, 42, 33, .06), 0 12px 32px -12px rgba(8, 42, 33, .22);
  --shadow-lg: 0 30px 80px -20px rgba(8, 42, 33, .45);
  --ease: cubic-bezier(.22, .8, .24, 1);
  --nav-h: 68px;
}

*, *::before, *::after { box-sizing: border-box; font-feature-settings: "lnum" 1; }
html { scroll-behavior: smooth; scroll-padding-top: var(--nav-h); }
body {
  font-variant-numeric: lining-nums;
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
svg { flex-shrink: 0; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 6px; }

.container { width: min(1200px, 100% - 32px); margin-inline: auto; }

.eyebrow {
  margin: 0 0 14px;
  font: 700 12px/1 var(--sans);
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--ruby);
  display: inline-flex; align-items: center; gap: 10px;
}
.eyebrow::before { content: ""; width: 26px; height: 1.5px; background: currentColor; }
.eyebrow--light { color: var(--gold-soft); }

.h2 {
  font-variant-numeric: lining-nums;
  font: 600 clamp(34px, 4.6vw, 56px)/1.05 var(--serif);
  margin: 0 0 18px;
  letter-spacing: -.01em;
  text-wrap: balance;
}
.h2 em { font-style: italic; color: var(--emerald); }

/* ─── Кнопки ─── */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  height: 52px; padding: 0 26px;
  border-radius: 999px; border: 0;
  font: 700 15px/1 var(--sans);
  text-decoration: none;
  transition: transform .25s var(--ease), background .25s, box-shadow .25s, color .25s;
}
.btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform .25s var(--ease); }
.btn:hover svg { transform: translateX(4px); }
.btn--gold { background: var(--gold); color: var(--emerald-deep); box-shadow: 0 10px 30px -10px rgba(201, 154, 59, .8); }
.btn--gold:hover { background: #D8AB4E; transform: translateY(-2px); }
.btn--ghost { color: #fff; box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.4); }
.btn--ghost:hover { box-shadow: inset 0 0 0 1.5px #fff; background: rgba(255,255,255,.08); }
.btn--small { height: 40px; padding: 0 18px; font-size: 14px; }

/* ═════════ Навигация ═════════ */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 1000;
  height: var(--nav-h);
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 0 clamp(16px, 4vw, 40px);
  color: #fff;
  transition: background .35s, color .35s, box-shadow .35s;
}
.nav.is-solid {
  background: rgba(251, 248, 241, .86);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  color: var(--ink);
  box-shadow: 0 1px 0 var(--line);
}
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font: 700 26px/1 var(--serif); }
.brand__mark { width: 32px; height: 32px; color: var(--gold); --mark-inner: var(--emerald-deep); }
.nav.is-solid .brand__mark { --mark-inner: var(--paper); }
.nav__links { display: flex; gap: 30px; }
.nav__right { display: flex; align-items: center; gap: 14px; }
.lang { display: inline-flex; padding: 3px; border-radius: 999px; box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.35); }
.lang button { border: 0; background: transparent; color: inherit; font: 700 12px/1 var(--sans, Manrope, sans-serif); letter-spacing: .06em; padding: 8px 11px; border-radius: 999px; opacity: .75; cursor: pointer; transition: background .25s, color .25s, opacity .25s; }
.lang button:hover { opacity: 1; }
.lang button[aria-pressed="true"] { background: var(--gold); color: var(--emerald-deep, #0B3A2E); opacity: 1; }
.lang button:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.nav.is-solid .lang { box-shadow: inset 0 0 0 1.5px var(--line); }
.audio__note { font-size: 11px; font-weight: 600; color: var(--muted); text-transform: none; letter-spacing: 0; margin-left: 4px; }
.audio__note:empty { display: none; }
.nav__links a { text-decoration: none; font-weight: 600; font-size: 14.5px; opacity: .85; position: relative; padding: 6px 0; }
.nav__links a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1.5px; background: var(--gold); transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease); }
.nav__links a:hover { opacity: 1; }
.nav__links a:hover::after { transform: scaleX(1); }

/* ═════════ Hero ═════════ */
.hero {
  position: relative; min-height: 100svh;
  display: grid; align-items: center;
  color: #fff; overflow: hidden; isolation: isolate;
  padding: calc(var(--nav-h) + 40px) 0 80px;
}
.hero__bg {
  position: absolute; inset: 0; z-index: -2;
  background:
    linear-gradient(100deg, rgba(8,42,33,.96) 0%, rgba(8,42,33,.82) 38%, rgba(8,42,33,.25) 75%, rgba(8,42,33,.45) 100%),
    url("../img/kremlin.jpg") center 30% / cover no-repeat;
  transform: scale(1.06);
  animation: heroZoom 18s var(--ease) forwards;
}
@keyframes heroZoom { to { transform: scale(1); } }
.hero__ornament {
  position: absolute; inset: 0; z-index: -1; opacity: .09;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120' viewBox='0 0 120 120'%3E%3Cg fill='none' stroke='%23E8D3A2' stroke-width='1.4'%3E%3Cpath d='M60 18c-8 10-15 20-15 32a15 15 0 0 0 30 0c0-12-7-22-15-32z'/%3E%3Cpath d='M60 65v30M60 80c-7-8-15-9-21-8M60 80c7-8 15-9 21-8'/%3E%3Cpath d='M0 0l20 20M120 0l-20 20M0 120l20-20M120 120l-20-20'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 120px;
  mask-image: linear-gradient(90deg, #000 0%, transparent 60%);
  -webkit-mask-image: linear-gradient(90deg, #000 0%, transparent 60%);
}
.hero__inner { width: min(1200px, 100% - 32px); margin-inline: auto; }
.hero__title {
  margin: 0 0 24px;
  font: 600 clamp(84px, 14vw, 180px)/.86 var(--serif);
  letter-spacing: -.02em;
  animation: rise 1s var(--ease) both;
}
.hero__title span {
  display: block; margin-top: 14px;
  font: italic 500 clamp(26px, 3.4vw, 44px)/1.1 var(--serif);
  color: var(--gold-soft); letter-spacing: 0;
}
.hero__lead { max-width: 560px; font-size: clamp(16px, 1.5vw, 18.5px); color: rgba(255,255,255,.82); margin: 0 0 34px; animation: rise 1s .12s var(--ease) both; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; animation: rise 1s .22s var(--ease) both; }
.hero__stats {
  display: grid; grid-template-columns: repeat(4, auto); justify-content: start; gap: 0;
  margin: 64px 0 0; animation: rise 1s .32s var(--ease) both;
}
.hero__stats div { padding: 0 36px; border-left: 1px solid rgba(232,211,162,.3); }
.hero__stats div:first-child { padding-left: 0; border-left: 0; }
.hero__stats dt { font: 600 44px/1 var(--serif); color: var(--gold); }
.hero__stats dd { margin: 6px 0 0; font-size: 13px; letter-spacing: .04em; color: rgba(255,255,255,.7); }
.hero__scroll { position: absolute; left: 50%; bottom: 28px; width: 26px; height: 42px; border: 1.5px solid rgba(255,255,255,.5); border-radius: 14px; translate: -50% 0; }
.hero__scroll span { position: absolute; left: 50%; top: 8px; width: 3px; height: 8px; border-radius: 2px; background: var(--gold); translate: -50% 0; animation: scrollDot 1.8s infinite; }
@keyframes scrollDot { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }

/* ═════════ Секции ═════════ */
.section { padding: clamp(80px, 10vw, 130px) 0; }
.section__head { max-width: 720px; margin-bottom: 52px; }
.section__sub { color: var(--muted); font-size: 17px; margin: 0; }
.section__head--light .section__sub { color: rgba(255,255,255,.7); }

/* Идея */
.idea__head { max-width: 820px; margin-bottom: 60px; }
.idea__text { font-size: 18.5px; color: var(--ink-2); margin: 0; max-width: 700px; }
.chapters { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.chapter {
  position: relative; padding: 30px 26px 26px;
  background: var(--paper); border-radius: var(--r);
  border: 1px solid var(--line);
  display: flex; flex-direction: column;
  transition: transform .35s var(--ease), box-shadow .35s;
}
.chapter:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.chapter__num { font: italic 600 46px/1 var(--serif); color: var(--gold); }
.chapter h3 { font: 600 26px/1.1 var(--serif); margin: 14px 0 10px; }
.chapter p { margin: 0 0 22px; color: var(--muted); font-size: 15px; flex: 1; }
.chapter__stops { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--emerald); }

/* ═════════ Карта ═════════ */
.mapwrap {
  position: relative;
  height: 100svh; min-height: 640px;
  display: grid; grid-template-columns: 380px 1fr;
  background: var(--paper);
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.panel { display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--line); background: var(--paper); z-index: 2; padding-top: var(--nav-h); }
.panel__head { padding: 22px 24px 16px; border-bottom: 1px solid var(--line); }
.panel__title { font: 600 32px/1.05 var(--serif); margin: 0 0 16px; }
.progress { display: flex; align-items: center; gap: 12px; font-size: 13px; color: var(--muted); font-weight: 600; margin-bottom: 16px; }
.progress__bar { flex: 1; height: 6px; background: rgba(14,77,60,.1); border-radius: 6px; overflow: hidden; }
.progress__bar span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--emerald), var(--gold)); border-radius: inherit; transition: width .6s var(--ease); }
.filters { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  border: 1px solid var(--line); background: transparent;
  padding: 7px 12px; border-radius: 999px;
  font-size: 13px; font-weight: 600; color: var(--ink-2);
  transition: background .2s, color .2s, border-color .2s;
}
.chip:hover { border-color: var(--emerald); color: var(--emerald); }
.chip[aria-selected="true"] { background: var(--emerald); color: #fff; border-color: var(--emerald); }

.stoplist { list-style: none; margin: 0; padding: 8px 12px 24px; overflow-y: auto; flex: 1; scrollbar-width: thin; }
.stoplist li { position: relative; }
.stoplist li:not(:last-child)::after {
  content: ""; position: absolute; left: 33px; top: 54px; bottom: -6px; width: 0;
  border-left: 2px dotted rgba(14,77,60,.25);
}
.stop {
  width: 100%; display: flex; align-items: center; gap: 14px;
  padding: 10px 12px; border: 0; background: transparent; text-align: left;
  border-radius: var(--r-sm);
  transition: background .2s;
}
.stop:hover { background: rgba(14,77,60,.06); }
.stop.is-active { background: rgba(14,77,60,.1); }
.stop__num {
  position: relative; z-index: 1;
  width: 42px; height: 42px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--card); border: 2px solid var(--emerald);
  font: 700 15px/1 var(--sans); color: var(--emerald);
  transition: background .2s, color .2s;
}
.stop.is-unesco .stop__num { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(201,154,59,.2); }
.stop.is-active .stop__num { background: var(--emerald); color: #fff; }
.stop.is-visited .stop__num::after {
  content: ""; position: absolute; right: -3px; bottom: -3px; width: 16px; height: 16px; border-radius: 50%;
  background: var(--gold) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23082A21' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5 9-10'/%3E%3C/svg%3E") center/10px no-repeat;
  border: 2px solid var(--paper);
}
.stop__txt { min-width: 0; flex: 1; }
.stop__title { display: block; font-weight: 700; font-size: 15px; line-height: 1.3; }
.stop__meta { display: block; font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.stop__star { color: var(--gold); font-size: 11px; font-weight: 800; letter-spacing: .06em; }
.stoplist li.is-hidden { display: none; }

.mapbox { position: relative; min-width: 0; isolation: isolate; }
#leaflet { position: absolute; inset: 0; background: #E9E3D6; }
.leaflet-container { font-family: var(--sans); }
/* Яндекс.Карты */
.ypin { position: absolute; left: -22px; top: -40px; width: 44px; height: 44px; }
.mapbox:has(.is-yandex) .map-legend { bottom: 40px; }
.mapbox:has(.is-yandex) .map-hint { bottom: 96px; }
.tiles-scheme { filter: sepia(.18) saturate(.85) brightness(1.02); }
.leaflet-control-layers { border: 0 !important; border-radius: 12px !important; box-shadow: var(--shadow) !important; background: var(--paper) !important; }
.leaflet-control-layers-expanded { padding: 10px 14px !important; font-weight: 600; }
.leaflet-top { top: calc(var(--nav-h) + 6px); }
.leaflet-control-zoom { border: 0 !important; box-shadow: var(--shadow) !important; border-radius: 12px !important; overflow: hidden; }
.leaflet-control-zoom a { width: 38px !important; height: 38px !important; line-height: 38px !important; color: var(--emerald) !important; }
.leaflet-control-attribution { font-size: 10.5px; background: rgba(251,248,241,.8) !important; }

/* Маркеры */
.pin-wrap { background: none; border: 0; }
.pin {
  position: relative; width: 44px; height: 44px;
  display: grid; place-items: center;
  transition: transform .3s var(--ease);
}
.pin__dot {
  position: relative; z-index: 2;
  width: 36px; height: 36px; border-radius: 50% 50% 50% 4px;
  transform: rotate(-45deg);
  background: var(--emerald);
  border: 2.5px solid #fff;
  box-shadow: 0 6px 16px -4px rgba(8,42,33,.6);
  display: grid; place-items: center;
  transition: background .25s;
}
.pin__dot b { transform: rotate(45deg); color: #fff; font: 800 14px/1 var(--sans); }
.pin--unesco .pin__dot { background: var(--ruby); }
.pin--unesco .pin__star {
  position: absolute; z-index: 3; top: -4px; right: -2px;
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--gold); color: var(--emerald-deep);
  display: grid; place-items: center; font-size: 11px; line-height: 1;
  border: 2px solid #fff;
}
.pin:hover { transform: translateY(-4px) scale(1.08); }
.pin.is-active { transform: translateY(-6px) scale(1.2); }
.pin.is-active .pin__dot { background: var(--gold); }
.pin.is-active .pin__dot b { color: var(--emerald-deep); }
.pin.is-active::before {
  content: ""; position: absolute; left: 50%; top: 50%; width: 44px; height: 44px;
  margin: -22px 0 0 -22px; border-radius: 50%;
  background: rgba(201,154,59,.45);
  animation: ping 1.8s var(--ease) infinite;
}
.pin.is-dim { opacity: .25; filter: grayscale(1); }
@keyframes ping { from { transform: scale(.6); opacity: 1; } to { transform: scale(2.2); opacity: 0; } }

.pin-label {
  background: var(--emerald-deep) !important; color: #fff !important;
  border: 0 !important; border-radius: 8px !important;
  font: 700 12.5px/1 var(--sans) !important; padding: 7px 10px !important;
  box-shadow: var(--shadow) !important;
}
.pin-label::before { border-top-color: var(--emerald-deep) !important; }

.route-line { stroke-dasharray: 2 10; animation: dash 30s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -600; } }

.map-legend {
  position: absolute; left: 16px; bottom: 16px; z-index: 500;
  display: flex; gap: 16px; flex-wrap: wrap;
  padding: 10px 14px; border-radius: 12px;
  background: rgba(251,248,241,.92); backdrop-filter: blur(8px);
  box-shadow: var(--shadow);
  font-size: 12.5px; font-weight: 600; color: var(--ink-2);
}
.map-legend span { display: inline-flex; align-items: center; gap: 7px; }
.lg { display: inline-block; width: 12px; height: 12px; border-radius: 50%; }
.lg--pin { background: var(--emerald); }
.lg--unesco { background: var(--ruby); box-shadow: 0 0 0 2px var(--gold); }
.lg--route { width: 22px; height: 0; border-top: 3px dotted var(--emerald); border-radius: 0; }

.map-tools { position: absolute; right: 16px; top: calc(var(--nav-h) + 12px); z-index: 500; display: flex; gap: 8px; }
.tool {
  height: 42px; padding: 0 16px; border: 0; border-radius: 12px;
  background: var(--emerald); color: #fff;
  display: inline-flex; align-items: center; gap: 8px;
  font-weight: 700; font-size: 14px;
  box-shadow: var(--shadow);
  transition: background .2s, transform .2s;
}
.tool:hover { background: var(--emerald-2); transform: translateY(-1px); }
.tool svg { width: 18px; height: 18px; fill: currentColor; }
.tool--icon { width: 42px; padding: 0; justify-content: center; background: var(--paper); color: var(--emerald); }
.tool--icon:hover { background: #fff; }
.tool--icon svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.tool.is-playing { background: var(--ruby); }

.map-hint {
  position: absolute; left: 50%; bottom: 74px; z-index: 500; margin: 0;
  translate: -50% 0;
  padding: 10px 18px; border-radius: 999px;
  background: var(--emerald-deep); color: #fff; font-size: 13.5px; font-weight: 600;
  box-shadow: var(--shadow); white-space: nowrap;
  transition: opacity .4s, transform .4s;
  animation: hintBob 2.4s ease-in-out infinite;
}
.map-hint.is-hidden { opacity: 0; pointer-events: none; }
@keyframes hintBob { 50% { transform: translateY(-5px); } }

/* ═════════ Карточка объекта ═════════ */
.drawer {
  position: absolute; top: var(--nav-h); right: 0; bottom: 0; z-index: 800;
  width: min(500px, 100%);
  background: var(--paper);
  box-shadow: var(--shadow-lg);
  display: flex; flex-direction: column;
  transform: translateX(105%);
  transition: transform .55s var(--ease);
  outline: none;
}
.drawer.is-open { transform: none; }
.drawer__close {
  position: absolute; top: 14px; right: 14px; z-index: 5;
  width: 42px; height: 42px; border-radius: 50%; border: 0;
  background: rgba(8,42,33,.55); backdrop-filter: blur(6px); color: #fff;
  display: grid; place-items: center; transition: background .2s, transform .2s;
}
.drawer__close:hover { background: var(--ruby); transform: rotate(90deg); }
.drawer__close svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; }
.drawer__scroll { flex: 1; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.drawer__media { position: relative; margin: 0; height: 300px; background: var(--emerald-deep); }
.drawer__media img { width: 100%; height: 100%; object-fit: cover; animation: imgIn .8s var(--ease); }
@keyframes imgIn { from { opacity: 0; } }
.drawer__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(8,42,33,.45) 0%, transparent 35%, transparent 60%, rgba(8,42,33,.75) 100%); pointer-events: none; }
.drawer__media figcaption { position: absolute; left: 24px; right: 90px; bottom: 16px; z-index: 2; color: rgba(255,255,255,.88); font-size: 12.5px; font-style: italic; }
.drawer__num {
  position: absolute; right: 22px; bottom: -28px; z-index: 3;
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--gold); color: var(--emerald-deep);
  display: grid; place-items: center;
  font: 700 30px/1 var(--serif);
  border: 4px solid var(--paper);
}
.drawer__body { padding: 26px 28px 34px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.tag { font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; padding: 5px 10px; border-radius: 6px; background: rgba(14,77,60,.09); color: var(--emerald); }
.tag--unesco { background: var(--ruby); color: #fff; }
.tag--era { background: rgba(201,154,59,.18); color: #7A5A17; }
.drawer__title { font: 600 38px/1.02 var(--serif); margin: 0 0 6px; text-wrap: balance; }
.drawer__place { margin: 0 0 20px; color: var(--muted); font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.drawer__place::before { content: ""; width: 14px; height: 14px; background: var(--ruby); mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a7 7 0 0 0-7 7c0 5 7 13 7 13s7-8 7-13a7 7 0 0 0-7-7zm0 9.5A2.5 2.5 0 1 1 12 6.5a2.5 2.5 0 0 1 0 5z'/%3E%3C/svg%3E") center/contain no-repeat; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a7 7 0 0 0-7 7c0 5 7 13 7 13s7-8 7-13a7 7 0 0 0-7-7zm0 9.5A2.5 2.5 0 1 1 12 6.5a2.5 2.5 0 0 1 0 5z'/%3E%3C/svg%3E") center/contain no-repeat; }

.audio {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 14px 12px 12px; margin-bottom: 22px;
  border: 1px solid var(--line); border-radius: 14px; background: var(--card);
  transition: border-color .2s, box-shadow .2s;
}
.audio:hover, .audio.is-playing { border-color: rgba(14,77,60,.4); box-shadow: var(--shadow); }
.audio__icon {
  position: relative; width: 48px; height: 48px; border-radius: 50%; border: 0;
  background: var(--emerald); color: #fff; display: grid; place-items: center;
  transition: background .2s, transform .2s;
}
.audio__icon:hover { transform: scale(1.06); }
.audio__icon svg { width: 18px; height: 18px; fill: currentColor; }
.audio.is-playing .audio__icon { background: var(--ruby); }
.audio.is-playing .audio__icon::before {
  content: ""; position: absolute; inset: -5px; border-radius: 50%;
  border: 2px solid rgba(178,58,46,.35); animation: ping 1.8s var(--ease) infinite;
}
.audio.is-loading .audio__icon svg { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.audio__main { flex: 1; min-width: 0; }
.audio__row { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-bottom: 6px; }
.audio__row b { font-size: 15px; }
.audio__time { font-size: 12.5px; color: var(--muted); font-weight: 600; font-variant-numeric: tabular-nums; }
.audio__seek {
  --p: 0%;
  width: 100%; height: 6px; margin: 0; cursor: pointer;
  -webkit-appearance: none; appearance: none; border-radius: 6px;
  background: linear-gradient(90deg, var(--emerald) var(--p), rgba(14,77,60,.12) var(--p));
}
.audio__seek::-webkit-slider-thumb { -webkit-appearance: none; width: 14px; height: 14px; border-radius: 50%; background: var(--gold); border: 2px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.3); }
.audio__seek::-moz-range-thumb { width: 14px; height: 14px; border-radius: 50%; background: var(--gold); border: 2px solid #fff; }
.audio__speed {
  min-width: 46px; height: 32px; padding: 0 8px; border-radius: 8px;
  border: 1px solid var(--line); background: transparent;
  font-size: 13px; font-weight: 700; color: var(--emerald);
}
.audio__speed:hover { border-color: var(--emerald); }

.drawer__lead { font: italic 500 22px/1.35 var(--serif); color: var(--emerald); margin: 0 0 18px; }
.drawer__text p { margin: 0 0 14px; color: var(--ink-2); font-size: 15.5px; line-height: 1.7; }
.signif {
  margin: 24px 0; padding: 20px 22px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--emerald-deep), var(--emerald));
  color: #fff; position: relative; overflow: hidden;
}
.signif::after {
  content: ""; position: absolute; right: -20px; top: -20px; width: 120px; height: 120px; opacity: .12;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40'%3E%3Cpath d='M20 4c-3.5 4.5-7 9-7 15a7 7 0 0 0 14 0c0-6-3.5-10.5-7-15z' fill='%23E8D3A2'/%3E%3C/svg%3E") center/contain no-repeat;
}
.signif h4, .nextstep h4 { margin: 0 0 8px; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; }
.signif h4 { color: var(--gold-soft); }
.signif p { margin: 0; font-size: 15px; line-height: 1.65; color: rgba(255,255,255,.9); }
.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 0 0 24px; }
.facts div { padding: 14px 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); }
.facts dt { font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.facts dd { margin: 0; font-weight: 700; font-size: 14.5px; line-height: 1.35; }
.nextstep { padding: 18px 20px; border-radius: 14px; border: 1.5px dashed rgba(201,154,59,.7); background: rgba(201,154,59,.07); }
.nextstep h4 { color: #8A6418; }
.nextstep p { margin: 0; font-size: 15px; color: var(--ink-2); }
.credit { margin: 18px 0 0; font-size: 12px; }
.credit a { color: var(--muted); }

.drawer__nav { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line); background: var(--paper); }
.navbtn { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border: 0; background: transparent; text-align: left; min-width: 0; transition: background .2s; }
.navbtn:hover { background: rgba(14,77,60,.07); }
.navbtn + .navbtn { border-left: 1px solid var(--line); }
.navbtn--next { justify-content: flex-end; text-align: right; }
.navbtn svg { width: 20px; height: 20px; fill: none; stroke: var(--emerald); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.navbtn span { display: flex; flex-direction: column; min-width: 0; }
.navbtn small { font-size: 11.5px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .08em; }
.navbtn b { font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ═════════ Карточки ═════════ */
.cards { display: grid; grid-template-columns: repeat(12, 1fr); gap: 20px; }
.card {
  grid-column: span 4;
  position: relative; border: 0; padding: 0; text-align: left;
  aspect-ratio: 4 / 5; border-radius: var(--r); overflow: hidden;
  background: var(--emerald-deep); color: #fff;
  isolation: isolate;
  box-shadow: var(--shadow);
}
.card:nth-child(1), .card:nth-child(6) { grid-column: span 8; aspect-ratio: auto; }
.card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform .9s var(--ease); }
.card::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(8,42,33,0) 30%, rgba(8,42,33,.9) 100%); transition: background .4s; }
.card:hover img { transform: scale(1.06); }
.card__inner { position: absolute; inset: auto 0 0; padding: 24px; }
.card__num { position: absolute; top: 18px; left: 18px; width: 40px; height: 40px; border-radius: 50%; background: rgba(251,248,241,.94); color: var(--emerald); display: grid; place-items: center; font: 700 20px/1 var(--serif); }
.card__unesco { position: absolute; top: 22px; right: 18px; padding: 6px 10px; border-radius: 6px; background: var(--ruby); font-size: 11px; font-weight: 800; letter-spacing: .08em; }
.card__place { font-size: 12.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--gold-soft); }
.card h3 { font: 600 30px/1.05 var(--serif); margin: 6px 0 8px; }
.card p { margin: 0; font-size: 14.5px; color: rgba(255,255,255,.8); max-height: 0; opacity: 0; overflow: hidden; transition: max-height .5s var(--ease), opacity .4s; }
.card:hover p, .card:focus-visible p { max-height: 120px; opacity: 1; }
.card__more { display: inline-flex; align-items: center; gap: 6px; margin-top: 12px; font-weight: 700; font-size: 13.5px; color: var(--gold); }

/* ═════════ Хронология ═════════ */
.timeline { background: var(--emerald-deep); color: #fff; position: relative; overflow: hidden; }
.timeline::before {
  content: ""; position: absolute; inset: 0; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120' viewBox='0 0 120 120'%3E%3Cg fill='none' stroke='%23E8D3A2' stroke-width='1.4'%3E%3Cpath d='M60 18c-8 10-15 20-15 32a15 15 0 0 0 30 0c0-12-7-22-15-32z'/%3E%3Cpath d='M60 65v30M60 80c-7-8-15-9-21-8M60 80c7-8 15-9 21-8'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 120px;
}
.timeline .h2 em { color: var(--gold); }
.tl { list-style: none; margin: 0; padding: 0; position: relative; display: grid; grid-template-columns: repeat(5, 1fr); gap: 46px 20px; }
.tl li { position: relative; }
.tl li::before { content: ""; position: absolute; left: 0; right: -20px; top: 23px; height: 1.5px; background: linear-gradient(90deg, var(--gold), rgba(201,154,59,.2)); }
.tl li:nth-child(5n)::before { right: 0; }
.tl__btn { border: 0; background: none; text-align: left; padding: 0; color: inherit; width: 100%; }
.tl__dot { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; background: var(--emerald); border: 2px solid var(--gold); font: 700 20px/1 var(--serif); color: var(--gold); position: relative; z-index: 1; transition: background .25s, color .25s, transform .25s var(--ease); }
.tl__btn:hover .tl__dot { background: var(--gold); color: var(--emerald-deep); transform: scale(1.1); }
.tl__year { display: block; margin: 16px 0 4px; font: 600 34px/1 var(--serif); color: var(--gold); }
.tl__name { display: block; font-weight: 700; font-size: 15px; }
.tl__era { display: block; font-size: 13px; color: rgba(255,255,255,.6); margin-top: 2px; }

/* ═════════ Футер ═════════ */
.footer { background: #061F18; color: rgba(255,255,255,.75); padding: 72px 0 28px; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 48px; }
.brand--footer { color: #fff; margin-bottom: 16px; }
.brand--footer .brand__mark { --mark-inner: #061F18; }
.footer h4 { color: var(--gold-soft); font-size: 12px; letter-spacing: .14em; text-transform: uppercase; margin: 6px 0 16px; }
.footer__text { margin: 0; max-width: 420px; font-size: 15px; }
.footer__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; font-size: 14.5px; }
.footer__list a { color: var(--gold-soft); }
.footer__bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-top: 56px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.1); font-size: 13px; }

/* ═════════ Появление при прокрутке ═════════ */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }

/* ═════════ Адаптив ═════════ */
@media (max-width: 1080px) {
  .chapters { grid-template-columns: 1fr 1fr; }
  .card, .card:nth-child(1), .card:nth-child(6) { grid-column: span 6; aspect-ratio: 4 / 5; }
  .tl { grid-template-columns: repeat(2, 1fr); }
  .tl li::before { display: none; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .footer__grid > :first-child { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
  :root { --nav-h: 60px; }
  .nav__links { display: none; }
  .mapwrap { grid-template-columns: 1fr; grid-template-rows: 58% 42%; height: 100svh; }
  .mapbox { grid-row: 1; }
  .panel { grid-row: 2; padding-top: 0; border-right: 0; border-top: 1px solid var(--line); }
  .panel__head { padding: 14px 16px 12px; }
  .panel__head .eyebrow, .progress { display: none; }
  .panel__title { font-size: 22px; margin-bottom: 10px; }
  .filters { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .chip { flex-shrink: 0; }
  .map-legend { display: none; }
  .map-hint { bottom: 16px; font-size: 12.5px; }
  .drawer { width: 100%; position: fixed; top: 0; z-index: 1100; }
  .drawer__close { top: 14px; }
  .drawer__media { height: 260px; }
  .drawer__title { font-size: 32px; }
  .hero__stats { grid-template-columns: repeat(2, auto); gap: 24px 0; }
  .hero__stats div:nth-child(3) { padding-left: 0; border-left: 0; }
}
@media (max-width: 600px) {
  .chapters { grid-template-columns: 1fr; }
  .card, .card:nth-child(1), .card:nth-child(6) { grid-column: 1 / -1; aspect-ratio: 4 / 3.4; }
  .card p { max-height: 120px; opacity: 1; }
  .tl { grid-template-columns: 1fr; gap: 26px; }
  .footer__grid { grid-template-columns: 1fr; }
  .nav .btn { display: none; }
  .hero__stats div { padding: 0 20px; }
  .hero__stats dt { font-size: 36px; }
  .facts { grid-template-columns: 1fr; }
  .drawer__body { padding: 24px 20px 28px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}
