/* =========================================================================
   MAIDAN PLAZA — styles
   ========================================================================= */
:root {
  --blue: #0057b7;
  --blue-deep: #24357a;
  --yellow: #ffd700;
  --yellow-soft: #fff3b0;
  --red: #c8102e;
  --ink: #14213d;
  --ink-soft: #4a5672;
  --paper: #fbf8f1;
  --card: #ffffff;
  --line: #e7e1d3;
  --radius: 18px;
  --shadow: 0 10px 30px -12px rgba(10, 42, 94, .25);
  --font-display: "Unbounded", system-ui, sans-serif;
  --font-body: "Manrope", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--blue); }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.1; margin: 0; letter-spacing: -.01em; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .45em;
  padding: .85em 1.35em; border-radius: 999px;
  font-weight: 700; text-decoration: none; font-size: .98rem;
  border: 2px solid transparent; cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, background .15s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--blue); color: #fff; box-shadow: 0 6px 0 var(--blue-deep); }
.btn-primary:hover { box-shadow: 0 8px 0 var(--blue-deep); }
.btn-primary:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--blue-deep); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: #fff; }
.btn-call { background: var(--yellow); color: var(--ink); padding: .6em 1em; }
.btn-yellow { background: var(--yellow); color: var(--ink); box-shadow: 0 6px 0 #c9a600; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: .75rem clamp(1rem, 4vw, 2.5rem);
  background: rgba(251, 248, 241, .85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--ink); }
.brand-mark {
  width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; flex: none;
  transition: transform .3s;
}
.brand-mark img { width: 46px; height: 46px; object-fit: contain; mix-blend-mode: multiply; }
.brand:hover .brand-mark { transform: rotate(-6deg) scale(1.06); }
/* fallback when assets/logo.png is missing: blue/yellow tile */
.brand-mark.no-logo { width: 36px; height: 36px; border-radius: 10px; background: linear-gradient(var(--blue) 50%, var(--yellow) 50%); transform: rotate(-6deg); }
.brand-flag {
  width: 36px; height: 36px; border-radius: 10px;
  background: linear-gradient(var(--blue) 50%, var(--yellow) 50%);
  box-shadow: inset 0 0 0 2px rgba(0,0,0,.05);
  transform: rotate(-6deg);
  transition: transform .3s;
}
.brand:hover .brand-mark {
  width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; flex: none;
  transition: transform .3s;
}
.brand-mark img { width: 46px; height: 46px; object-fit: contain; mix-blend-mode: multiply; }
.brand:hover .brand-mark { transform: rotate(-6deg) scale(1.06); }
/* fallback when assets/logo.png is missing: blue/yellow tile */
.brand-mark.no-logo { width: 36px; height: 36px; border-radius: 10px; background: linear-gradient(var(--blue) 50%, var(--yellow) 50%); transform: rotate(-6deg); }
.brand-flag { transform: rotate(6deg) scale(1.05); }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-text strong { font-family: var(--font-display); font-size: 1.15rem; letter-spacing: .06em; }
.brand-text small { font-size: .72rem; color: var(--ink-soft); font-weight: 600; letter-spacing: .04em; }
.main-nav { display: flex; gap: 1.6rem; }
.main-nav a { color: var(--ink); text-decoration: none; font-weight: 600; position: relative; }
.main-nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 3px; border-radius: 2px;
  background: var(--yellow); transform: scaleX(0); transition: transform .2s;
}
.main-nav a:hover::after { transform: scaleX(1); }
.header-tools { display: flex; align-items: center; gap: .6rem; }
.lang-switch { position: relative; }
.lang-btn {
  display: inline-flex; align-items: center; gap: .35em; cursor: pointer;
  background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: .5em .85em;
  font: 800 .82rem var(--font-body); color: var(--ink);
}
.lang-btn:hover, .lang-btn[aria-expanded="true"] { border-color: var(--ink); }
.lang-btn .caret { font-size: .7em; opacity: .6; }
.lang-menu {
  position: absolute; right: 0; top: calc(100% + 8px); z-index: 60; list-style: none; margin: 0; padding: 6px;
  background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); min-width: 170px;
  animation: pop .18s ease-out;
}
.lang-menu[hidden] { display: none; }
.lang-menu button {
  width: 100%; display: flex; align-items: center; gap: .6em; text-align: left; cursor: pointer;
  border: 0; background: transparent; border-radius: 10px; padding: .55em .7em; font: 600 .95rem var(--font-body); color: var(--ink);
}
.lang-menu button:hover, .lang-menu button:focus-visible { background: var(--paper); outline: none; }
.lang-menu button[aria-selected="true"] { background: var(--blue); color: #fff; }
.lang-menu .code { font: 800 .7rem var(--font-display); width: 2.2em; opacity: .7; }

/* ---------- hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background: linear-gradient(180deg, #d9ecff 0%, #f3f8ff 55%, var(--paper) 100%);
  padding: clamp(3rem, 8vw, 6rem) clamp(1rem, 4vw, 2.5rem) 5.5rem;
}
.hero-inner { position: relative; max-width: 980px; margin: 0 auto; text-align: center; z-index: 2; }
.eyebrow {
  display: inline-flex; align-items: center; gap: .5rem; margin: 0 0 1.2rem;
  background: #fff; border: 1px solid var(--line); padding: .45em 1em; border-radius: 999px;
  font-weight: 700; font-size: .85rem; color: var(--ink-soft);
}
.eyebrow .dot { width: 8px; height: 8px; border-radius: 50%; background: #2fbf71; box-shadow: 0 0 0 4px rgba(47,191,113,.2); animation: pulse 2s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 8px rgba(47,191,113,0); } }
.hero h1 { font-size: clamp(2.3rem, 7vw, 5.2rem); font-weight: 800; }
.h1-top { display: block; color: var(--blue-deep); }
.h1-bottom {
  display: inline-block; color: var(--ink);
  background: linear-gradient(transparent 62%, var(--yellow) 62%, var(--yellow) 92%, transparent 92%);
  padding: 0 .15em;
}
.lede { max-width: 640px; margin: 1.4rem auto 2rem; font-size: clamp(1rem, 2vw, 1.18rem); color: var(--ink-soft); }
.hero-ctas { display: flex; flex-wrap: wrap; gap: .9rem; justify-content: center; }
.hero-chips { list-style: none; padding: 0; margin: 2.4rem auto 0; display: flex; flex-wrap: wrap; gap: .55rem; justify-content: center; max-width: 820px; }
.hero-chips li {
  background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: .45em .95em;
  font-weight: 600; font-size: .9rem; box-shadow: 0 2px 0 var(--line);
  animation: floaty 6s ease-in-out infinite;
}
.hero-chips li:nth-child(2n) { animation-delay: -2s; }
.hero-chips li:nth-child(3n) { animation-delay: -4s; }
@keyframes floaty { 50% { transform: translateY(-5px); } }

.hero-sky { position: absolute; inset: 0; pointer-events: none; }
.sun {
  position: absolute; top: 9%; right: 9%; width: 120px; height: 120px; border-radius: 50%;
  background: radial-gradient(circle, #fff6b8 0 40%, var(--yellow) 41% 60%, rgba(255,215,0,0) 61%);
  animation: spin 40s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.cloud { position: absolute; height: 34px; background: #fff; border-radius: 40px; opacity: .9; }
.cloud::before, .cloud::after { content: ""; position: absolute; background: #fff; border-radius: 50%; }
.cloud::before { width: 50px; height: 50px; top: -24px; left: 18px; }
.cloud::after { width: 36px; height: 36px; top: -16px; left: 56px; }
.c1 { width: 130px; top: 20%; left: -150px; animation: drift 55s linear infinite; }
.c2 { width: 100px; top: 48%; left: -150px; animation: drift 75s linear infinite -30s; transform: scale(.8); }
@keyframes drift { to { left: 110%; } }

/* Ukrainian embroidery-inspired band */
.vyshyvanka {
  position: absolute; left: 0; right: 0; bottom: 0; height: 34px;
  background-color: var(--paper);
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='34' viewBox='0 0 48 34'%3E%3Cg shape-rendering='crispEdges'%3E%3Cpath fill='%23c8102e' d='M22 5h4v4h-4zM18 9h4v4h-4zM26 9h4v4h-4zM14 13h4v4h-4zM30 13h4v4h-4zM22 13h4v8h-4zM18 17h4v4h-4zM26 17h4v4h-4zM10 15h4v4h-4zM34 15h4v4h-4zM18 21h4v4h-4zM26 21h4v4h-4zM22 25h4v4h-4z'/%3E%3Cpath fill='%23141414' d='M0 15h4v4H0zM44 15h4v4h-4zM4 11h2v2H4zM4 21h2v2H4zM42 11h2v2h-2zM42 21h2v2h-2z'/%3E%3C/g%3E%3C/svg%3E");
  background-repeat: repeat-x; background-position: center;
  border-top: 3px solid var(--red);
}
.vyshyvanka.small { position: static; height: 30px; border-top: 0; background-color: transparent; }

/* ---------- section heads ---------- */
section { position: relative; }
.section-head { max-width: 1240px; margin: 0 auto 1.6rem; padding: 0 clamp(1rem, 4vw, 2.5rem); }
.section-head h2 { font-size: clamp(1.7rem, 4vw, 2.6rem); }
.section-head p { color: var(--ink-soft); margin: .5rem 0 0; font-size: 1.05rem; }

/* ---------- explore / map ---------- */
.explore { padding: 4rem 0 3rem; }
.map-toolbar {
  max-width: 1240px; margin: 0 auto 1.2rem; padding: 0 clamp(1rem, 4vw, 2.5rem);
  display: flex; flex-wrap: wrap; gap: .8rem; justify-content: space-between; align-items: center;
}
.filters, .map-toggles { display: flex; flex-wrap: wrap; gap: .5rem; }
.chip, .toggle {
  display: inline-flex; align-items: center; gap: .45em;
  border: 2px solid var(--line); background: #fff; color: var(--ink);
  font: 700 .88rem var(--font-body); padding: .5em .95em; border-radius: 999px; cursor: pointer;
  transition: all .15s;
}
.chip:hover, .toggle:hover { border-color: var(--ink); }
.chip .sw { width: 10px; height: 10px; border-radius: 50%; background: var(--c, var(--ink)); }
.chip[aria-pressed="true"] { background: var(--c, var(--ink)); border-color: var(--c, var(--ink)); color: #fff; }
.chip[aria-pressed="true"] .sw { background: #fff; }
.toggle[aria-pressed="true"] { background: var(--ink); color: #fff; border-color: var(--ink); }

.explore-grid {
  max-width: 1240px; margin: 0 auto; padding: 0 clamp(1rem, 4vw, 2.5rem);
  display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(320px, 1fr); gap: 1.5rem; align-items: start;
}
.map-frame {
  background: #fff; border-radius: 26px; padding: 12px; box-shadow: var(--shadow);
  border: 1px solid var(--line);
}
.map-stage {
  position: relative; border-radius: 18px; overflow: hidden;
  aspect-ratio: 952 / 1275; max-height: 82vh; margin: 0 auto;
  background: #e9ecef;
}
.map-img { width: 100%; height: 100%; object-fit: cover; transition: filter .8s ease; user-select: none; }
.map-svg { position: absolute; inset: 0; width: 100%; height: 100%; }

.unit {
  fill: var(--c, var(--blue)); fill-opacity: 0;
  stroke: var(--c, var(--blue)); stroke-width: 0; stroke-linejoin: round;
  cursor: pointer; transition: fill-opacity .2s, stroke-width .2s;
  outline: none;
}
.unit:hover, .unit:focus-visible, .unit.is-hover { fill-opacity: .32; stroke-width: 5; }
.unit.is-active { fill-opacity: .45; stroke-width: 7; filter: url(#glow); }
.unit.is-match { fill-opacity: .28; stroke-width: 4; animation: blink 1.6s ease-in-out infinite; }
.unit.is-dim { fill: #0b1530; fill-opacity: .35; stroke-width: 0; }
.unit.vacant { stroke-dasharray: 10 8; }
@keyframes blink { 50% { fill-opacity: .1; } }

.pin { pointer-events: none; transition: transform .25s cubic-bezier(.3,1.6,.5,1); transform-box: fill-box; transform-origin: 50% 100%; }
.pin circle { fill: #fff; stroke: var(--c, var(--blue)); stroke-width: 3; }
.pin text { font-size: 22px; text-anchor: middle; dominant-baseline: central; }
.pin .num { font: 800 11px var(--font-display); fill: var(--ink); }
.pin.is-up { transform: translateY(-10px) scale(1.25); }
.pin.is-dim { opacity: .35; }

.lamps circle { opacity: 0; transition: opacity .8s; }
.car { pointer-events: none; }
.car .beams { opacity: 0; transition: opacity .6s; }
.map-stage.night .car .beams { opacity: 1; }
.npc-car .brake { opacity: .55; }
.npc-car.braking .brake { opacity: 1; fill: #ff3b3b; }
.car-bubble.small { font-size: 13px; }
.busy-chip {
  position: absolute; top: 62px; left: 12px; z-index: 3;
  background: var(--yellow); color: var(--ink); font-weight: 800; font-size: .78rem;
  padding: .4em .8em; border-radius: 999px; box-shadow: 0 3px 10px rgba(0,0,0,.2);
  max-width: calc(100% - 24px);
}
.busy-chip[hidden] { display: none; }
.car-bubble { font: 800 18px var(--font-display); fill: var(--ink); stroke: #fff; stroke-width: 5px; paint-order: stroke; text-anchor: middle; animation: rise .9s ease-out forwards; }
@keyframes rise { to { transform: translateY(-24px); opacity: 0; } }

/* drive mode */
.drive-toggle { border-color: var(--blue); }
.drive-toggle[aria-pressed="true"] { background: var(--blue); border-color: var(--blue); }
.map-stage.driving { outline: 4px solid var(--yellow); outline-offset: -4px; }
.map-stage.driving .unit { pointer-events: none; }
.drive-hint {
  position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); z-index: 4;
  background: rgba(20, 33, 61, .92); color: #fff; padding: .55em 1em; border-radius: 999px;
  font-weight: 600; font-size: .85rem; white-space: nowrap; max-width: calc(100% - 24px); overflow: hidden; text-overflow: ellipsis;
  display: none;
}
.map-stage.driving .drive-hint { display: block; }
.visit-btn { border: 0; background: var(--yellow); color: var(--ink); font: 800 .8rem var(--font-body); border-radius: 999px; padding: .25em .7em; margin-left: .3em; cursor: pointer; }
.drive-pad {
  position: absolute; right: 12px; bottom: 58px; z-index: 4; display: none;
  grid-template-columns: repeat(3, 42px); grid-template-rows: repeat(3, 42px); gap: 3px; opacity: .85;
  grid-template-areas: ". up ." "left honk right" ". down .";
  touch-action: none; user-select: none; -webkit-user-select: none;
}
.drive-pad button {
  border: 0; border-radius: 12px; background: rgba(255,255,255,.9); color: var(--ink);
  font-size: 1.1rem; box-shadow: 0 3px 0 rgba(0,0,0,.25); cursor: pointer; touch-action: none;
}
.drive-pad button.down { transform: translateY(2px); box-shadow: 0 1px 0 rgba(0,0,0,.25); background: var(--yellow); }
.k-up { grid-area: up; } .k-down { grid-area: down; } .k-left { grid-area: left; } .k-right { grid-area: right; } .k-honk { grid-area: honk; font-size: 1rem !important; }
@media (hover: none), (pointer: coarse) { .map-stage.driving .drive-pad { display: grid; } }

.map-tooltip {
  position: absolute; pointer-events: none; z-index: 5;
  background: var(--ink); color: #fff; padding: .55em .85em; border-radius: 12px;
  font-weight: 700; font-size: .9rem; white-space: nowrap;
  transform: translate(-50%, calc(-100% - 14px)); opacity: 0; transition: opacity .15s;
  box-shadow: 0 8px 20px rgba(0,0,0,.25);
}
.map-tooltip small { display: block; font-weight: 500; opacity: .75; font-size: .78rem; }
.map-tooltip::after {
  content: ""; position: absolute; left: 50%; bottom: -6px; width: 12px; height: 12px; background: var(--ink);
  transform: translateX(-50%) rotate(45deg);
}
.map-tooltip.show { opacity: 1; }

.compass {
  position: absolute; top: 12px; left: 12px; width: 42px; height: 42px; border-radius: 50%;
  background: rgba(255,255,255,.9); display: grid; place-items: center;
  font: 800 .8rem var(--font-display); box-shadow: 0 2px 8px rgba(0,0,0,.15);
}
.compass::before { content: "▲"; position: absolute; top: 2px; font-size: .55rem; color: var(--red); }
.street-label {
  position: absolute; top: 4.6%; left: 50%; transform: translateX(-50%) rotate(-3deg);
  font: 800 clamp(.55rem, 1.3vw, .8rem) var(--font-display); letter-spacing: .3em; color: rgba(255,255,255,.95);
  text-shadow: 0 1px 2px rgba(0,0,0,.4); pointer-events: none;
}

/* night mode */
.map-stage::before {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: #0b1f5e; mix-blend-mode: multiply; opacity: 0; transition: opacity .8s ease;
}
.map-svg { z-index: 2; }
.map-ground { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; transition: filter .8s ease; }
.map-stage.night .map-ground { filter: brightness(.7) saturate(.55); }
.compass, .street-label { z-index: 3; }
.map-stage.night::before { opacity: .62; }
.map-stage.night .map-img { filter: brightness(.7) saturate(.55); }
.map-stage.night .lamps circle { opacity: 1; }
.map-stage.night .unit:not(.is-dim) { fill: #ffd76a; fill-opacity: .2; }
.map-stage.night .unit:hover { fill-opacity: .45; }
.map-stage.night .unit.is-active { fill: #ffe27a; fill-opacity: .7; stroke: #fff; }
.map-stage.night .unit.vacant { fill-opacity: .04; }
.map-stage.night .street-label { color: #ffd76a; }

/* ---------- detail panel ---------- */
.detail {
  position: sticky; top: 90px;
  background: var(--card); border-radius: 26px; border: 1px solid var(--line); box-shadow: var(--shadow);
  padding: 1.6rem; min-height: 420px;
}
.detail-empty-art { font-size: 2.4rem; animation: floaty 2.5s ease-in-out infinite; }
.detail-empty h3 { font-size: 1.5rem; margin: .4rem 0; }
.detail-empty p { color: var(--ink-soft); margin: 0 0 1rem; }
.search input {
  width: 100%; padding: .9em 1.1em; border-radius: 14px; border: 2px solid var(--line);
  font: 600 1rem var(--font-body); background: var(--paper);
}
.search input:focus { outline: none; border-color: var(--blue); background: #fff; }
.quick-list { list-style: none; padding: 0; margin: 1rem 0 0; display: grid; gap: .35rem; max-height: 420px; overflow: auto; }
.quick-list button {
  width: 100%; display: flex; align-items: center; gap: .75rem; text-align: left;
  border: 0; background: transparent; padding: .55rem .6rem; border-radius: 12px; cursor: pointer;
  font: 600 .95rem var(--font-body); color: var(--ink);
}
.quick-list button:hover, .quick-list button:focus-visible { background: var(--paper); outline: none; }
.quick-list .em { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 10px; background: color-mix(in srgb, var(--c, #999) 16%, white); font-size: 1.15rem; flex: none; }
.quick-list .u { margin-left: auto; font: 700 .72rem var(--font-display); color: var(--ink-soft); }
.quick-list .none { color: var(--ink-soft); padding: .5rem; }

.detail-card { animation: pop .35s cubic-bezier(.3,1.4,.5,1); }
@keyframes pop { from { opacity: 0; transform: translateY(12px) scale(.98); } }
.dc-top { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin-bottom: 1rem; }
.dc-back { border: 0; background: var(--paper); border-radius: 999px; padding: .45em .9em; font: 700 .85rem var(--font-body); cursor: pointer; }
.dc-nav { display: flex; gap: .3rem; }
.dc-nav button { width: 34px; height: 34px; border-radius: 50%; border: 2px solid var(--line); background: #fff; cursor: pointer; font-weight: 800; }
.dc-nav button:hover { border-color: var(--ink); }
.dc-hero {
  border-radius: 18px; padding: 1.3rem; color: #fff; position: relative; overflow: hidden;
  background: linear-gradient(135deg, var(--c, var(--blue)), color-mix(in srgb, var(--c, var(--blue)) 60%, #0a2a5e));
}
.dc-hero .big-em { position: absolute; right: -8px; bottom: -18px; font-size: 6rem; opacity: .25; transform: rotate(-12deg); }
.dc-badge { display: inline-block; background: rgba(255,255,255,.2); border-radius: 999px; padding: .25em .75em; font: 700 .72rem var(--font-display); letter-spacing: .05em; }
.dc-hero h3 { font-size: 1.45rem; margin: .6rem 0 .2rem; max-width: 85%; }
.dc-hero .ua { margin: 0; opacity: .85; font-weight: 600; font-size: .9rem; }
.dc-hero .tag { margin: .6rem 0 0; font-weight: 600; max-width: 90%; }
.dc-body { padding-top: 1.1rem; }
.dc-body p { margin: 0 0 1rem; color: var(--ink-soft); }
.dc-hours { display: flex; align-items: center; gap: .5rem; font-weight: 700; margin-bottom: .9rem; }
.dc-highlights { list-style: none; padding: 0; margin: 0 0 1.2rem; display: flex; flex-wrap: wrap; gap: .4rem; }
.dc-highlights li { background: color-mix(in srgb, var(--c, var(--blue)) 12%, white); color: var(--ink); border-radius: 999px; padding: .35em .8em; font-weight: 600; font-size: .85rem; }
.dc-phones { display: grid; gap: .55rem; }
.phone-btn {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: .85rem 1rem; border-radius: 14px; text-decoration: none; color: var(--ink);
  border: 2px solid var(--ink); font-weight: 700; transition: all .15s;
}
.phone-btn:hover { background: var(--yellow); transform: translateY(-2px); }
.phone-btn .vanity { font-family: var(--font-display); font-size: .95rem; }
.phone-btn .digits { color: var(--ink-soft); font-size: .88rem; }

/* ---------- directory ---------- */
.directory { padding: 3rem 0 4rem; }
.cards {
  max-width: 1240px; margin: 0 auto; padding: 0 clamp(1rem, 4vw, 2.5rem);
  display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1.1rem;
}
.card {
  position: relative; background: #fff; border: 1px solid var(--line); border-radius: 22px; padding: 1.3rem;
  cursor: pointer; text-align: left; font: inherit; color: inherit;
  transition: transform .2s, box-shadow .2s, border-color .2s;
  display: flex; flex-direction: column; gap: .5rem; overflow: hidden;
}
.card::before { content: ""; position: absolute; left: 0; top: 0; right: 0; height: 6px; background: var(--c, var(--blue)); }
.card:hover, .card:focus-visible { transform: translateY(-5px) rotate(-.4deg); box-shadow: var(--shadow); border-color: var(--c); outline: none; }
.card .em { font-size: 2rem; transition: transform .3s; }
.card:hover .em { transform: scale(1.2) rotate(-8deg); }
.card h3 { font-size: 1.05rem; }
.card .tag { color: var(--ink-soft); font-size: .92rem; margin: 0; flex: 1; }
.card .meta { display: flex; justify-content: space-between; align-items: center; font-size: .8rem; font-weight: 700; margin-top: .4rem; }
.card .cat { color: var(--c); }
.card .unitno { font-family: var(--font-display); color: var(--ink-soft); }
.card.vacant { background: repeating-linear-gradient(-45deg, #fff, #fff 12px, #fffbe6 12px, #fffbe6 24px); }

/* ---------- strip ---------- */
.strip {
  background: var(--blue); color: #fff;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem;
  padding: 2.4rem clamp(1rem, 4vw, 2.5rem); text-align: center;
}
.strip strong { display: block; font: 800 clamp(2rem, 5vw, 3.2rem) var(--font-display); color: var(--yellow); }
.strip span { font-weight: 600; opacity: .9; }

/* ---------- visit ---------- */
.visit {
  max-width: 1240px; margin: 0 auto; padding: 4.5rem clamp(1rem, 4vw, 2.5rem);
  display: grid; grid-template-columns: 1fr 1.2fr; gap: 2.5rem; align-items: center;
}
.visit h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
.addr { font: 700 1.35rem var(--font-display); margin: 1rem 0; line-height: 1.35; }
.visit-list { list-style: none; padding: 0; margin: 0 0 1.6rem; display: grid; gap: .7rem; }
.visit-list li { display: flex; gap: .7rem; align-items: flex-start; font-weight: 600; }
.visit .hero-ctas { justify-content: flex-start; }
.visit-map { border-radius: 26px; overflow: hidden; box-shadow: var(--shadow); border: 6px solid #fff; aspect-ratio: 4 / 3; }
.visit-map iframe { width: 100%; height: 100%; border: 0; }

/* ---------- footer ---------- */
.site-footer { background: var(--ink); color: #dfe6f5; padding-bottom: 1.5rem; }
.site-footer a { color: var(--yellow); }
.footer-inner {
  max-width: 1240px; margin: 0 auto; padding: 2rem clamp(1rem, 4vw, 2.5rem) 1rem;
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem;
}
.footer-inner p { margin: .3rem 0 0; opacity: .85; }
.footer-right { text-align: right; }
.footer-brand { display: flex; align-items: center; gap: 1rem; }
.footer-logo { width: 60px; height: 60px; border-radius: 16px; background: #fff; display: grid; place-items: center; flex: none; }
.footer-logo img { width: 52px; height: 52px; object-fit: contain; }
.hero-logo {
  position: absolute; left: -7%; top: 52%; width: min(40vw, 500px); transform: translateY(-50%) rotate(-8deg);
  opacity: .045; mix-blend-mode: multiply; pointer-events: none; z-index: 1;
}
.slava { font-family: var(--font-display); color: var(--yellow); }
.copyright { text-align: center; opacity: .5; font-size: .85rem; margin: 0; }

/* ---------- reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .explore-grid { grid-template-columns: 1fr; }
  .detail { position: relative; top: 0; min-height: 0; }
  .map-stage { max-height: none; }
  .visit { grid-template-columns: 1fr; }
  .strip { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 720px) {
  .main-nav { display: none; }
  .hide-sm { display: none; }
  .footer-right { text-align: left; }
  .sun { width: 80px; height: 80px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
