/* Ready to move: Housing.com portfolio. Mobile first; desktop from 900px. Base styles are the final state; html.js adds start states. */
:root {
  --stage: #1A0933; --panel: #241047; --panel2: #2F1660; --line: rgba(255,255,255,.12);
  --purple: #8E44FF; --purple2: #B98CFF; --yellow: #FFD60A; --pink: #FF4F8B; --green: #2BD49A; --sky: #8FD3FF;
  --paper: #FFF7EA; --paper2: #F3E7D3; --ink: #1A0933; --text: #F6F0FF; --mut: rgba(246,240,255,.7);
  --disp: 'Fraunces', Georgia, serif; --body: 'Manrope', system-ui, sans-serif; --mono: 'JetBrains Mono', ui-monospace, monospace; --hand: 'Caveat', cursive;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --padl: max(20px, env(safe-area-inset-left)); --padr: max(20px, env(safe-area-inset-right));
  --r: 22px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; -webkit-tap-highlight-color: transparent; }
html:has(dialog[open]) { overflow: hidden; }
body { margin: 0; background: var(--stage); color: var(--text); font: 400 16px/1.55 var(--body); overflow-x: clip; }
a, button, input, summary { touch-action: manipulation; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
img, svg { display: block; }
.mono { font-family: var(--mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; }
.dim { opacity: .66; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 99; background: var(--yellow); color: var(--ink); padding: 12px 16px; border-radius: 12px; }
.skip:focus { left: 12px; }
:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; border-radius: 6px; }

/* ---------- type ---------- */
.disp { font-family: var(--disp); font-weight: 900; letter-spacing: -.02em; line-height: .98; font-variation-settings: 'SOFT' 100, 'WONK' 1; margin: 0; }
.disp .b { color: var(--yellow); }
.paper .disp .b { color: var(--purple); }
.lbl { color: var(--purple2); margin: 0 0 14px; }
.paper .lbl { color: var(--purple); }
.sh { max-width: 760px; margin-bottom: 36px; }
.sh .disp { font-size: clamp(40px, 11vw, 92px); }
.sh .disp span { display: inline; }
.sub { color: var(--mut); font-size: 17px; max-width: 58ch; margin: 18px 0 0; }
.paper .sub { color: rgba(26,9,51,.72); }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 12px 22px; border-radius: 999px; font-weight: 800; text-decoration: none; border: 2px solid transparent; transition: transform .25s var(--ease), background .25s; }
.btn.sm { min-height: 44px; padding: 10px 16px; font-size: 14px; }
.btn.pri { background: var(--yellow); color: var(--ink); }
.btn.ghost { border-color: rgba(255,255,255,.35); color: var(--text); }
.paper .btn.ghost { border-color: rgba(26,9,51,.3); color: var(--ink); }

/* ---------- badges ---------- */
.badge { display: inline-flex; align-items: center; gap: 6px; font: 700 12px/1 var(--mono); letter-spacing: .04em; text-transform: uppercase; padding: 7px 10px; border-radius: 999px; }
.badge svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.badge.v { background: var(--green); color: #06291D; }
.tag { font: 700 12px/1 var(--mono); text-transform: uppercase; letter-spacing: .05em; padding: 8px 11px; border-radius: 999px; }
.tag.rtm { background: var(--yellow); color: var(--ink); }

/* ---------- nav ---------- */
.top { display: none; }
.tabbar { position: fixed; z-index: 40; left: 50%; transform: translateX(-50%); bottom: max(12px, env(safe-area-inset-bottom)); display: flex; align-items: center; gap: 2px; padding: 4px; border-radius: 999px; background: rgba(36,16,71,.92); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border: 1px solid var(--line); box-shadow: 0 10px 30px rgba(0,0,0,.35); max-width: calc(100vw - 24px); }
.tabbar a { min-height: 44px; min-width: 44px; display: inline-flex; align-items: center; padding: 0 12px; border-radius: 999px; font-weight: 700; font-size: 14px; text-decoration: none; }
.status { display: inline-flex; align-items: center; gap: 8px; font: 700 12px/1 var(--mono); text-transform: uppercase; letter-spacing: .05em; color: var(--ink); background: var(--yellow); padding: 9px 12px; border-radius: 999px; white-space: nowrap; }
.status i { width: 8px; height: 8px; border-radius: 50%; background: var(--purple); }
.status.sm { padding: 9px 10px; font-size: 11px; }

/* ---------- sections ---------- */
main { padding-bottom: 72px; }
.sec { position: relative; padding: 84px var(--padr) 84px var(--padl); }
.sec > * { max-width: 1200px; margin-left: auto; margin-right: auto; }
.paper { background: var(--paper); color: var(--ink); }

/* ---------- single-column grids never grow past the page ---------- */
.hero, .identity, .map-ui, .case-grid, .case-low, .jd-top, .b-grid, .ending { grid-template-columns: minmax(0, 1fr); }

/* ---------- hero ---------- */
.hero { display: grid; gap: 34px; padding-top: 40px; overflow: hidden; }
.hero::before { content: ''; position: absolute; inset: -20% -30% auto auto; width: 80vw; height: 80vw; max-width: 900px; max-height: 900px; background: radial-gradient(circle, rgba(142,68,255,.45), transparent 65%); filter: blur(10px); animation: drift 14s ease-in-out infinite alternate; pointer-events: none; }
.hero-obj { order: -1; position: relative; width: 100%; max-width: 460px; }
.hero-copy { position: relative; }
.h1 { font-size: clamp(64px, 21vw, 168px); line-height: .88; margin: 4px 0 0; }
.h1 span { display: block; }
.h1 span + span { color: var(--yellow); }
.hero .sub { font-size: 17px; }
.hero-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 26px 0; }
.hero-stats div { border-top: 2px solid var(--line); padding-top: 10px; }
.hero-stats b { display: block; font: 900 clamp(24px, 7vw, 40px)/1 var(--disp); color: var(--yellow); }
.hero-stats span { display: block; font-size: 13px; color: var(--mut); margin-top: 6px; line-height: 1.35; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 10px; }
.disc { font-size: 13px; color: var(--mut); margin: 22px 0 0; }

.search { position: relative; z-index: 3; }
.search-bar { display: flex; align-items: center; gap: 10px; background: #fff; color: var(--ink); border-radius: 999px; padding: 14px 18px; font-weight: 700; font-size: 15px; box-shadow: 0 14px 40px rgba(0,0,0,.35); }
.search-bar svg { width: 20px; height: 20px; flex: none; fill: none; stroke: var(--purple); stroke-width: 2.4; stroke-linecap: round; }
.search-bar .q { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.caret { width: 2px; height: 18px; background: var(--purple); animation: blink 1s steps(2) infinite; flex: none; }
.filters { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 0; }
.fchip { font: 700 11px/1 var(--mono); letter-spacing: .04em; text-transform: uppercase; padding: 8px 10px; border-radius: 999px; background: rgba(43,212,154,.16); color: var(--green); border: 1px solid rgba(43,212,154,.35); }
.pins { position: absolute; inset: 70px -10px -10px; z-index: 0; pointer-events: none; }
.pins i { position: absolute; left: calc(var(--x) * 1%); top: calc(var(--y) * 1%); width: 18px; opacity: .45; }
.pins i:nth-child(3n) { width: 12px; }
.pins svg path { fill: var(--pink); } .pins i:nth-child(2n) svg path { fill: var(--purple2); }
.pins svg circle { fill: var(--stage); }
.listing { position: relative; z-index: 2; margin-top: 16px; background: var(--paper); color: var(--ink); border-radius: var(--r); overflow: hidden; box-shadow: 0 30px 70px rgba(0,0,0,.45); transform-style: preserve-3d; }
.l-photo { position: relative; background: linear-gradient(180deg, #CFC0FF, #F6EEFF); padding: 22px 22px 0; }
.l-photo .house { width: 100%; height: auto; max-height: 300px; }
.l-photo .tag { position: absolute; left: 14px; top: 14px; }
.l-photo .badge { position: absolute; right: 14px; top: 14px; }
.heart { position: absolute; right: 16px; bottom: 30px; width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; background: #fff; color: var(--pink); font-size: 18px; box-shadow: 0 4px 12px rgba(0,0,0,.15); }
.l-body { padding: 18px 20px 20px; }
.l-k { color: var(--purple); margin: 0; }
.l-name { font: 900 28px/1.05 var(--disp); margin: 6px 0 2px; }
.l-role { font-weight: 800; margin: 0; }
.l-place { display: flex; align-items: center; gap: 6px; margin: 6px 0 0; color: rgba(26,9,51,.7); font-size: 14px; }
.l-place svg { width: 13px; flex: none; } .l-place svg path { fill: var(--pink); } .l-place svg circle { fill: #fff; }
.l-lines { list-style: none; padding: 0; margin: 12px 0; display: flex; flex-wrap: wrap; gap: 6px; }
.l-lines li { font-size: 13px; font-weight: 600; background: var(--paper2); padding: 6px 10px; border-radius: 10px; }
.l-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; border-top: 1px dashed rgba(26,9,51,.2); padding-top: 14px; }
.l-owner { color: rgba(26,9,51,.6); }

/* house drawing */
.house .h-ground { fill: #7EDDB8; } .house .h-sun { fill: var(--yellow); }
.house .h-wall { fill: #fff; stroke: var(--ink); stroke-width: 3; stroke-linejoin: round; }
.house .h-roof { fill: none; stroke: var(--purple); stroke-width: 9; stroke-linecap: round; stroke-linejoin: round; }
.house .h-chim { fill: var(--purple); }
.house .h-win { fill: var(--yellow); stroke: var(--ink); stroke-width: 3; }
.house .h-door { fill: var(--pink); stroke: var(--ink); stroke-width: 3; }
.house .h-knob { fill: var(--ink); }
.house .h-wing { fill: #EFE4FF; stroke: var(--ink); stroke-width: 3; }
.house .h-tree { fill: var(--green); } .house .h-trunk { fill: #6B4B2A; }
.draw { stroke-dasharray: 100; stroke-dashoffset: 0; }

/* ---------- ticker ---------- */
.ticker { overflow: hidden; border-block: 1px solid var(--line); background: var(--panel); padding: 14px 0; }
.tk { display: flex; gap: 40px; width: max-content; animation: tick 46s linear infinite; }
.tk span { white-space: nowrap; color: var(--mut); font-size: 15px; }
.tk b { color: var(--yellow); font-family: var(--disp); font-size: 20px; margin-right: 4px; }

/* ---------- identity ---------- */
.identity { display: grid; gap: 30px; align-items: center; }
.spec { background: var(--paper); color: var(--ink); border-radius: var(--r); padding: 20px; box-shadow: 0 24px 60px rgba(0,0,0,.4); width: 100%; max-width: 520px; }
.spec-h { display: flex; justify-content: space-between; gap: 10px; border-bottom: 2px solid var(--ink); padding-bottom: 10px; }
.spec-top { display: grid; grid-template-columns: minmax(0, 1fr) 96px; gap: 14px; align-items: center; margin: 14px 0; }
.plan { width: 100%; height: auto; }
.plan .p-out { fill: #EEF5FF; stroke: var(--ink); stroke-width: 3; }
.plan .p-in { fill: none; stroke: var(--ink); stroke-width: 2.5; }
.plan .p-door { fill: none; stroke: var(--purple); stroke-width: 1.5; stroke-dasharray: 3 3; }
.plan text { font: 700 8px var(--mono); fill: rgba(26,9,51,.55); letter-spacing: .05em; }
.seal { position: relative; width: 96px; height: 96px; transform: rotate(-12deg); }
.seal svg { width: 100%; height: 100%; } .seal .sc { fill: var(--green); }
.seal span { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; font: 800 11px/1.1 var(--mono); text-transform: uppercase; color: #06291D; }
.seal b { font-size: 22px; }
.spec-dl { margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 14px; }
.spec-dl div { border-top: 1px solid rgba(26,9,51,.14); padding: 9px 0; }
.spec-dl dt { font: 700 11px/1.2 var(--mono); text-transform: uppercase; letter-spacing: .05em; color: var(--purple); }
.spec-dl dd { margin: 3px 0 0; font-weight: 700; font-size: 14px; line-height: 1.3; }
.spec-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 12px; padding-top: 12px; border-top: 2px solid var(--ink); }
.barcode { width: 96px; height: 26px; background: repeating-linear-gradient(90deg, var(--ink) 0 2px, transparent 2px 4px, var(--ink) 4px 5px, transparent 5px 8px); }

/* ---------- parts ---------- */
.part { border-top: 2px solid var(--line); padding-top: 22px; margin-bottom: 56px; }
.part-n { color: var(--pink); }
.part-t { font-size: clamp(34px, 9vw, 64px); margin-top: 8px; }
.part-q { color: var(--mut); font-size: 18px; margin: 10px 0 0; max-width: 46ch; }

/* ---------- map ---------- */
.map-ui { display: grid; gap: 18px; }
.map { position: relative; aspect-ratio: 1 / 1; border-radius: var(--r); background: radial-gradient(circle at 1px 1px, rgba(255,255,255,.16) 1px, transparent 1.5px) 0 0 / 18px 18px, var(--panel); border: 1px solid var(--line); overflow: hidden; }
.map-lines { position: absolute; inset: 0; width: 100%; height: 100%; }
.map-lines .route { fill: none; stroke: var(--purple2); stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; stroke-width: 3; opacity: .8; }
.map-lines .flight { fill: none; stroke: var(--sky); stroke-width: 2; stroke-dasharray: 6 6; vector-effect: non-scaling-stroke; }
.pin { position: absolute; left: calc(var(--x) * 1%); top: calc(var(--y) * 1%); transform: translate(-16px, -36px); display: inline-flex; align-items: center; gap: 4px; min-height: 44px; padding: 0 10px 0 0; border: 0; background: none; }
.pin.abroad { flex-direction: row-reverse; transform: translate(calc(-100% + 16px), -36px); padding: 0 0 0 10px; }
.pin-i { width: 32px; display: block; transition: transform .3s var(--ease); }
.pin-i svg { width: 32px; height: auto; filter: drop-shadow(0 4px 6px rgba(0,0,0,.4)); }
.pin-i path { fill: var(--purple2); } .pin-i circle { fill: var(--stage); }
.pin.hs .pin-i path { fill: var(--pink); }
.pin-l { font: 700 13px/1 var(--mono); background: rgba(26,9,51,.85); padding: 6px 8px; border-radius: 8px; white-space: nowrap; }
.pin.on .pin-i { transform: translateY(-6px) scale(1.15); }
.pin.on .pin-l { background: var(--yellow); color: var(--ink); }
.pin.hs .pin-i { animation: bob 2.6s ease-in-out infinite; }
.map-note { position: absolute; right: 12px; bottom: 10px; color: var(--mut); font-size: 11px; }
.addrs { position: relative; }
.addr { background: var(--paper); color: var(--ink); border-radius: var(--r); padding: 20px; border-left: 8px solid var(--purple); }
.addr.hs { border-left-color: var(--pink); }
.addr h3 { font: 900 30px/1 var(--disp); margin: 0 0 8px; }
.addr p { margin: 0 0 10px; }
.addr .lbl { color: var(--purple); margin-bottom: 8px; }
.addr[hidden] { display: none; }

/* ---------- hunt ---------- */
.hunt { padding-top: 90px; }
.frames { list-style: none; padding: 0; display: grid; gap: 26px; }
.frames li { position: relative; display: grid; grid-template-columns: 104px minmax(0, 1fr); gap: 4px 18px; align-items: center; }
.ph { grid-row: span 2; position: relative; width: 104px; aspect-ratio: 9 / 18; border-radius: 22px; background: #fff; border: 3px solid var(--ink); padding: 22px 8px 8px; box-shadow: 6px 6px 0 var(--purple); }
.ph-notch { position: absolute; top: 7px; left: 50%; width: 34px; height: 6px; border-radius: 6px; background: var(--ink); transform: translateX(-50%); }
.mini-search { display: flex; align-items: center; gap: 4px; font: 700 10px/1 var(--mono); border: 2px solid var(--purple); border-radius: 999px; padding: 5px 6px; }
.mini-search svg { width: 10px; height: 10px; fill: none; stroke: var(--purple); stroke-width: 3; }
.mini-rows { display: grid; gap: 6px; margin-top: 10px; }
.mini-rows i { display: block; height: 30px; border-radius: 6px; background: linear-gradient(90deg, #E9DDFF 34%, #F4EEE2 34%); }
.mini-card { position: relative; background: #EEE4FF; border-radius: 8px; padding: 6px; }
.mini-card .house { width: 100%; height: auto; }
.mini-heart { position: absolute; right: 4px; top: 2px; color: var(--pink); font-size: 14px; }
.mini-tag .badge { font-size: 9px; padding: 5px 6px; margin-top: 8px; }
.ph.dim { opacity: .45; box-shadow: 6px 6px 0 rgba(26,9,51,.25); }
.ph-empty { display: grid; place-items: center; height: 100%; font: 900 40px var(--disp); color: rgba(26,9,51,.35); }
.exit-line { position: absolute; left: 70px; top: 6px; width: 100px; height: 50px; overflow: visible; }
.exit-line path { fill: none; stroke: var(--pink); stroke-width: 3; stroke-dasharray: 4 6; }
.keys { position: absolute; left: 150px; top: -10px; width: 46px; height: 46px; border-radius: 50%; background: var(--yellow); display: grid; place-items: center; box-shadow: 0 6px 14px rgba(26,9,51,.25); }
.keys svg { width: 30px; height: 30px; fill: none; stroke: var(--ink); stroke-width: 4; stroke-linecap: round; } .keys .kh { fill: var(--ink); }
.f-step { margin: 0; color: var(--purple); align-self: end; }
.f-step.warn { color: #C2185B; }
.f-line { margin: 0; font-weight: 700; font-size: 17px; line-height: 1.35; align-self: start; }
.frames li.exit .f-step { padding-top: 40px; }

/* ---------- bridge ---------- */
.bridge { background: var(--purple); color: #fff; padding: 80px var(--padr) 80px var(--padl); }
.bridge-in { max-width: 980px; margin: 0 auto; }
.morph { width: 84px; height: 70px; margin-bottom: 18px; }
.morph svg { width: 100%; height: 100%; } .morph path { fill: none; stroke: #fff; stroke-width: 5; stroke-linejoin: round; }
.morph .m-h { stroke: var(--yellow); }
.bridge-l { font-size: clamp(30px, 7.4vw, 60px); font-weight: 800; line-height: 1.05; }
.bridge-p { font-size: 18px; max-width: 60ch; margin: 22px 0 0; color: rgba(255,255,255,.88); }

/* ---------- results ---------- */
.rc-grid { display: grid; grid-auto-flow: column; grid-auto-columns: min(80vw, 330px); gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 6px 4px 18px; margin: 0 calc(-1 * var(--padr)) 0 calc(-1 * var(--padl)); padding-inline: var(--padl) var(--padr); scrollbar-width: none; }
.rc-grid::-webkit-scrollbar { display: none; }
.rc { scroll-snap-align: start; display: flex; flex-direction: column; align-items: flex-start; gap: 12px; text-align: left; min-height: 380px; padding: 20px; border-radius: var(--r); border: 0; color: var(--ink); transition: transform .35s var(--ease), box-shadow .35s; }
.rc-purple { background: var(--purple); color: #fff; } .rc-yellow { background: var(--yellow); } .rc-pink { background: var(--pink); color: #fff; } .rc-green { background: var(--green); } .rc-sky { background: var(--sky); }
.rc-green .badge.v { background: var(--ink); color: var(--green); }
.rc-top { display: flex; width: 100%; justify-content: space-between; align-items: center; gap: 8px; }
.rc-num { font: 900 clamp(30px, 8vw, 44px)/1 var(--disp); letter-spacing: -.02em; }
.rc-title { font-weight: 700; font-size: 16px; }
.rc-more { margin-top: auto; opacity: .8; }
.swipe-hint { color: var(--mut); text-align: right; margin: 0; }
.pic { width: 100%; height: 120px; display: flex; align-items: flex-end; gap: 12px; }
.pic-bars i { position: relative; flex: 1; border-radius: 12px 12px 4px 4px; background: rgba(255,255,255,.35); transition: height 1.2s var(--ease); }
.pic-bars .a { height: 45%; } .pic-bars .b { height: 100%; background: var(--yellow); }
.pic-bars em { position: absolute; bottom: 8px; left: 10px; font: 700 11px var(--mono); font-style: normal; text-transform: uppercase; color: var(--ink); }
.pic-clock svg { width: 120px; height: 120px; }
.pic-clock .face { fill: rgba(26,9,51,.08); stroke: var(--ink); stroke-width: 3; }
.pic-clock .sweep { fill: none; stroke: var(--purple); stroke-width: 10; stroke-dasharray: 16 100; transform: rotate(-90deg); transform-origin: 60px 60px; transition: stroke-dasharray 1.4s var(--ease); }
.pic-clock .hand { stroke: var(--ink); stroke-width: 4; stroke-linecap: round; transform-origin: 60px 60px; transform: rotate(58deg); transition: transform 1.4s var(--ease); }
.pic-clock .hub { fill: var(--ink); }
.pic-dots { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 6px; align-content: end; position: relative; }
.pic-dots i { aspect-ratio: 1; border-radius: 50%; background: rgba(255,255,255,.35); transition: background .4s calc(var(--i) * 40ms); }
.pic-dots i.on { background: var(--yellow); box-shadow: 0 0 0 2px rgba(26,9,51,.2); }
.pic-dots .plus { position: absolute; right: -2px; bottom: -6px; font: 900 22px var(--disp); }
.pic-ring { position: relative; }
.pic-ring svg { width: 120px; height: 120px; transform: rotate(-90deg); }
.pic-ring .trk { fill: none; stroke: rgba(26,9,51,.15); stroke-width: 14; }
.pic-ring .val { fill: none; stroke: var(--purple); stroke-width: 14; stroke-linecap: round; stroke-dasharray: var(--v) 100; transition: stroke-dasharray 1.5s var(--ease); }
.pr-l { font: 700 12px var(--mono); text-transform: uppercase; align-self: center; }
.pic-funnel svg { width: 140px; height: 100px; }
.pic-funnel .fn { fill: rgba(26,9,51,.1); stroke: var(--ink); stroke-width: 3; stroke-linejoin: round; }
.pic-funnel .leak { fill: var(--pink); stroke: var(--ink); stroke-width: 2; }
.pic-funnel .plug { stroke: var(--ink); stroke-width: 5; stroke-linecap: round; transition: transform .6s var(--ease) .8s; }
.pic-funnel .fl { display: grid; gap: 4px; font: 800 18px var(--disp); }
.pic-funnel s { opacity: .55; }

/* ---------- case ---------- */
.case { background: linear-gradient(180deg, var(--stage), #12062A); }
.case-grid { display: grid; gap: 26px; }
.sw-row { display: inline-flex; padding: 4px; background: var(--panel); border-radius: 999px; border: 1px solid var(--line); margin-bottom: 14px; }
.sw { min-height: 40px; min-width: 40px; padding: 0 16px; border-radius: 999px; border: 0; background: none; font-weight: 800; font-size: 14px; color: var(--mut); }
.sw.on { background: var(--yellow); color: var(--ink); }
.results-ph { background: var(--paper); color: var(--ink); border-radius: 28px; border: 6px solid #0E0420; padding: 16px 12px; max-width: 420px; box-shadow: 0 24px 60px rgba(0,0,0,.45); }
.rp-h { color: var(--purple); padding: 2px 6px 10px; }
.mock { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.mr { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 10px; align-items: center; background: #fff; border-radius: 14px; padding: 8px; order: var(--o); transition: opacity .5s, filter .5s; }
.mr-ph { width: 52px; height: 42px; border-radius: 10px; background: #EEE4FF; overflow: hidden; display: grid; place-items: end center; }
.mr-ph .house { width: 52px; height: auto; }
.mr-b { min-width: 0; display: grid; }
.mr-b b { font-size: 14px; }
.mr-b span { font-size: 12px; color: rgba(26,9,51,.6); }
.mr-st span { font: 700 11px/1 var(--mono); text-transform: uppercase; padding: 6px 8px; border-radius: 999px; background: #E9F9F2; color: #0B6B49; display: inline-block; }
.mr.gone .mr-st .mr-now { background: #FFE3EC; color: #B0144B; }
.results-ph .mr-fix { display: none; }
.results-ph[data-state="fix"] .mr-now { display: none; }
.results-ph[data-state="fix"] .mr-fix { display: inline-block; }
.results-ph[data-state="fix"] .mr-b .mr-fix { display: block; color: #0B6B49; font-weight: 700; }
.results-ph[data-state="fix"] .mr { order: var(--a); }
.results-ph[data-state="fix"] .mr.gone { opacity: .45; filter: grayscale(1); }
.results-ph[data-state="fix"] .mr.gone .mr-b .mr-fix { color: #B0144B; }
.results-ph[data-state="fix"] .mr.gone .mr-st .mr-fix { background: #EEE; color: #555; }
.rp-call { margin: 12px 6px 2px; font-family: var(--hand); font-size: 22px; line-height: 1.1; color: #B0144B; }
.rp-call.ok { color: #0B6B49; }
.note { color: var(--sky); margin: 12px 0 0; font-size: 11px; }
.evid { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.evid li { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; }
.evid .lbl { color: var(--pink); margin-bottom: 4px; }
.evid p { margin: 0 0 6px; }
.evid a, .evid span.dim { font-size: 13px; color: var(--sky); }
.why { margin: 16px 0 0; color: var(--mut); }
.why b { color: var(--text); }
.moves { list-style: none; padding: 0; margin: 40px auto 0; display: grid; gap: 12px; }
.moves li { position: relative; background: var(--paper); color: var(--ink); border-radius: var(--r); padding: 20px 20px 20px 22px; border-top: 8px solid var(--purple); }
.moves li:nth-child(2) { border-top-color: var(--yellow); } .moves li:nth-child(3) { border-top-color: var(--green); }
.mv-n { color: var(--purple); }
.moves h3 { font: 900 26px/1.05 var(--disp); margin: 6px 0 8px; }
.moves p { margin: 0; }
.case-low { display: grid; gap: 14px; margin-top: 14px; }
.calc { background: #0E0420; border: 2px dashed var(--sky); border-radius: var(--r); padding: 20px; }
.calc .lbl { color: var(--sky); }
.calc-q { margin: 0; color: var(--mut); }
.calc-v { font: 900 clamp(64px, 18vw, 120px)/1 var(--disp); color: var(--yellow); margin: 10px 0 14px; display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.calc-v small { font: 700 16px var(--mono); color: var(--mut); text-transform: uppercase; }
.calc-in { display: grid; gap: 10px; }
.calc-in label { display: grid; gap: 6px; font-size: 13px; font-weight: 700; color: var(--mut); }
.calc-in input { font: 700 16px var(--mono); min-height: 48px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel); color: var(--text); width: 100%; }
.plan-card { background: var(--panel); border-radius: var(--r); padding: 20px; border: 1px solid var(--line); }
.target { margin: 0 0 14px; font: 800 22px/1.25 var(--disp); }
.target .lbl { display: block; color: var(--yellow); font-family: var(--mono); font-size: 12px; margin-bottom: 8px; }
.plan-acc details { border-top: 1px solid var(--line); }
.plan-acc summary { list-style: none; min-height: 44px; display: flex; align-items: center; justify-content: space-between; font: 700 12px var(--mono); text-transform: uppercase; color: var(--purple2); cursor: pointer; }
.plan-acc summary::-webkit-details-marker { display: none; }
.plan-acc summary::after { content: '+'; font-size: 18px; color: var(--yellow); }
.plan-acc details[open] summary::after { content: '−'; }
.plan-acc p { margin: 0 0 14px; color: var(--mut); }
.plan-dl dt { font: 700 12px var(--mono); text-transform: uppercase; color: var(--purple2); }
.plan-dl dd { margin: 4px 0 0; color: var(--mut); }
.srcs { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: baseline; }
.srcs .lbl { width: 100%; margin: 0; }
.srcs a { font-size: 14px; color: var(--sky); }

/* ---------- JD ---------- */
.jd-top { display: grid; gap: 20px; align-items: end; }
.ring { position: relative; width: 170px; height: 170px; }
.ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring .trk { fill: none; stroke: rgba(26,9,51,.12); stroke-width: 12; }
.ring .val { fill: none; stroke: var(--green); stroke-width: 12; stroke-linecap: round; stroke-dasharray: var(--v) 100; transition: stroke-dasharray 1.6s var(--ease); }
.ring b { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font: 900 38px var(--disp); }
.ring .mono { position: absolute; left: 0; right: 0; bottom: -22px; text-align: center; color: var(--purple); }
.jd-list { list-style: none; padding: 0; margin: 44px auto 0; display: grid; gap: 10px; }
.jd-r { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 8px 12px; background: #fff; border-radius: 16px; padding: 14px; border: 1px solid rgba(26,9,51,.08); }
.jd-tick { grid-row: span 2; width: 30px; height: 30px; border-radius: 50%; background: var(--green); color: #06291D; display: grid; place-items: center; font-weight: 900; }
.jd-q { margin: 0; font-weight: 700; }
.jd-a { display: flex; flex-wrap: wrap; gap: 8px; }
.jd-rec, .jd-also { display: grid; text-align: left; gap: 2px; min-height: 44px; padding: 8px 12px; border-radius: 12px; border: 0; font-weight: 700; font-size: 14px; }
.jd-rec { background: var(--yellow); color: var(--ink); }
.jd-also { background: var(--paper2); color: var(--ink); }
.jd-rec .mono, .jd-also .mono { font-size: 11px; color: var(--purple); }
.jd-text { margin: 0; color: rgba(26,9,51,.75); font-size: 14px; }

/* ---------- building ---------- */
.building { background: radial-gradient(ellipse at 50% 0%, #2B1260, var(--stage) 60%); }
.fl-count { color: var(--yellow); margin-top: -16px; margin-bottom: 24px; }
.b-grid { display: grid; gap: 22px; }
.tower { position: relative; width: 100%; max-width: 360px; margin: 0 auto; }
.roof { height: 54px; background: var(--purple); clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.tf { display: grid; grid-template-columns: 82px minmax(0, 1fr); align-items: center; gap: 10px; min-height: 48px; background: #EFE4FF; border: 3px solid var(--ink); border-bottom: 0; padding: 6px 10px; text-decoration: none; color: var(--ink); }
.tf-l { font-size: 11px; color: var(--purple); }
.tf-w { display: flex; flex-wrap: wrap; gap: 5px; }
.tf-w i { width: 14px; height: 14px; border-radius: 3px; background: var(--yellow); border: 2px solid var(--ink); transition: background .3s calc(var(--i) * 70ms); }
.tdoor { height: 34px; background: #EFE4FF; border: 3px solid var(--ink); display: grid; place-items: end center; }
.tdoor i { width: 34px; height: 24px; background: var(--pink); border: 3px solid var(--ink); border-bottom: 0; border-radius: 14px 14px 0 0; }
.floors { display: grid; gap: 10px; }
.floor { background: var(--panel); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.floor summary { list-style: none; display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: 'n c' 's c'; gap: 2px 10px; align-items: center; min-height: 64px; padding: 14px 18px; cursor: pointer; }
.floor summary::-webkit-details-marker { display: none; }
.fl-n { grid-area: n; color: var(--purple2); }
.fl-s { grid-area: s; font-size: 30px; }
.fl-c { grid-area: c; font: 700 13px var(--mono); background: var(--yellow); color: var(--ink); padding: 8px 10px; border-radius: 999px; }
.units { list-style: none; padding: 0 12px 12px; margin: 0; display: grid; gap: 8px; }
.unit { width: 100%; display: grid; text-align: left; gap: 2px; min-height: 44px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel2); }
.u-t { font-weight: 800; }
.u-n { color: var(--yellow); font-weight: 700; font-size: 14px; }
.u-o { color: var(--mut); font-size: 11px; }

/* ---------- amenities ---------- */
.amen { list-style: none; padding: 0; margin: 0 auto; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.am { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; display: grid; gap: 6px; align-content: start; }
.am svg { width: 48px; height: 48px; fill: none; stroke: var(--yellow); stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; background: rgba(255,214,10,.1); border-radius: 14px; padding: 4px; }
.am b { font: 800 18px/1.15 var(--disp); }
.am span { font-size: 13px; color: var(--mut); }

/* ---------- title history ---------- */
.title-chain { list-style: none; padding: 0; margin: 0 auto; border-left: 3px solid var(--ink); }
.title-chain li { position: relative; display: grid; gap: 2px; padding: 0 0 22px 22px; }
.title-chain li::before { content: ''; position: absolute; left: -10px; top: 2px; width: 17px; height: 17px; border-radius: 50%; background: var(--purple); border: 3px solid var(--paper); }
.tc-when { color: var(--purple); }
.tc-who { font-size: 15px; } .tc-who b { display: block; font: 900 22px/1.15 var(--disp); }
.tc-where { color: rgba(26,9,51,.6); }
.tc-line { font-weight: 700; color: #0B6B49; }
.h-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; }
.h-stamp { display: none; }
.h-stamp .seal { width: 220px; height: 220px; transform: rotate(-10deg); }
.h-stamp .seal .sc { fill: var(--purple); }
.h-stamp .seal span { color: #fff; font-size: 22px; }
.h-stamp .seal b { font-size: 40px; font-family: var(--disp); text-transform: none; }
.certs { margin: 10px auto 0; color: rgba(26,9,51,.7); text-transform: none; letter-spacing: .02em; font-size: 12px; }

/* ---------- ending ---------- */
.ending { display: grid; gap: 34px; align-items: center; padding-bottom: 110px; }
.end-cta { display: flex; flex-wrap: wrap; gap: 10px; }
.end-cta .btn.pri { font-size: 15px; }
.pass { position: relative; background: var(--paper); color: var(--ink); border-radius: 18px; padding: 22px 22px 26px; max-width: 440px; width: 100%; box-shadow: 0 28px 70px rgba(0,0,0,.45); }
.pass::before, .pass::after { content: ''; position: absolute; top: 58%; width: 22px; height: 22px; border-radius: 50%; background: var(--stage); }
.pass::before { left: -11px; } .pass::after { right: -11px; }
.pass-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; border-bottom: 2px dashed rgba(26,9,51,.3); padding-bottom: 12px; }
.pass-h .house { width: 84px; height: auto; }
.pass dl { margin: 12px 0 0; display: grid; gap: 0; }
.pass dl div { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 10px; padding: 8px 0; border-bottom: 1px solid rgba(26,9,51,.1); }
.pass dt { font: 700 11px/1.6 var(--mono); text-transform: uppercase; color: var(--purple); }
.pass dd { margin: 0; font-weight: 800; }
.pass dl div:last-child dd { color: #B0144B; }
.pass-sig { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-top: 14px; }
.sig { font: 600 34px/1 var(--hand); color: var(--purple); }
.keytag { position: absolute; right: -6px; top: -22px; width: 150px; height: 54px; background: var(--yellow); color: var(--ink); border-radius: 10px 26px 26px 10px; display: grid; place-items: center; transform: rotate(9deg); box-shadow: 0 8px 18px rgba(0,0,0,.3); font: 800 12px var(--mono); text-transform: uppercase; }
.keytag::before { content: ''; position: absolute; right: 12px; width: 12px; height: 12px; border-radius: 50%; background: var(--stage); }
.keytag span { padding-right: 26px; }

/* ---------- footer ---------- */
.foot { padding: 40px var(--padr) 110px var(--padl); border-top: 1px solid var(--line); text-align: center; }
.foot > * { max-width: 900px; margin-left: auto; margin-right: auto; }
.ladder { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 8px; color: var(--purple2); }
.ladder i { color: var(--mut); font-style: normal; }
.foot .disc { color: var(--text); }
.foot p { font-size: 14px; color: var(--mut); }

/* ---------- sheet ---------- */
dialog#sheet { padding: 0; border: 0; background: transparent; max-width: 100vw; width: 100%; margin: auto 0 0; max-height: 86svh; }
dialog#sheet::backdrop { background: rgba(10,3,24,.65); backdrop-filter: blur(3px); }
.sheet-in { position: relative; background: var(--paper); color: var(--ink); border-radius: 26px 26px 0 0; padding: 26px var(--padr) max(24px, env(safe-area-inset-bottom)) var(--padl); max-height: 86svh; overflow: auto; }
dialog[open] .sheet-in { animation: sheetUp .4s var(--ease); }
.sheet-x { position: absolute; right: 12px; top: 12px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--paper2); font-size: 24px; line-height: 1; }
.sheet-l { color: var(--purple); margin: 0 0 8px; }
#sheet-body h3 { font: 900 30px/1.05 var(--disp); margin: 0 50px 10px 0; }
.sheet-n { font: 900 24px/1.15 var(--disp); color: var(--purple); margin: 0 0 14px; }
.sheet-dl { margin: 0; display: grid; gap: 12px; }
.sheet-dl dt { font: 700 11px var(--mono); text-transform: uppercase; color: rgba(26,9,51,.6); }
.sheet-dl dd { margin: 3px 0 0; font-size: 16px; }

/* ---------- motion (start states only under html.js) ---------- */
@keyframes rise { from { transform: translateY(.3em); } to { transform: none; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes cardIn { from { opacity: 0; transform: translateY(40px) scale(.96) rotate(-1.5deg); } to { opacity: 1; transform: none; } }
@keyframes drop { 0% { opacity: 0; transform: translateY(-40px); } 70% { opacity: .5; transform: translateY(4px); } 100% { opacity: .45; transform: none; } }
@keyframes drawIn { from { stroke-dashoffset: 100; } to { stroke-dashoffset: 0; } }
@keyframes pop { 0% { transform: scale(0); } 70% { transform: scale(1.15); } 100% { transform: scale(1); } }
@keyframes blink { 50% { opacity: 0; } }
@keyframes tick { to { transform: translateX(-50%); } }
@keyframes drift { to { transform: translate(-8%, 10%) scale(1.1); } }
@keyframes bob { 50% { transform: translateY(-6px); } }
@keyframes sheetUp { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes glowWin { 0%, 100% { fill: var(--yellow); } 50% { fill: #FFF3A3; } }
@keyframes walk { to { stroke-dashoffset: -100; } }
@keyframes morphF { 0%, 35% { opacity: 1; } 50%, 85% { opacity: 0; } 100% { opacity: 1; } }
@keyframes morphH { 0%, 35% { opacity: 0; } 50%, 85% { opacity: 1; } 100% { opacity: 0; } }
@keyframes huntStep { 0%, 100% { opacity: .55; } 15%, 40% { opacity: 1; } }

.js .h1 span { animation: rise .85s var(--ease) both; animation-delay: calc(var(--i) * 130ms); }
.js .rise:not(.h1 span) { animation: fadeUp .8s var(--ease) both; animation-delay: calc(var(--i) * 130ms + 150ms); }
.js .listing { animation: cardIn .9s var(--ease) 1.3s both; }
.js .listing .h-roof { animation: drawIn 1.1s var(--ease) 1.7s both; }
.js .listing .badge, .js .listing .tag, .js .listing .heart { animation: pop .5s var(--ease) 2.4s both; }
.js .listing .h-win { animation: glowWin 3s ease-in-out 3s 2; }
.js .fchip { animation: fadeUp .5s var(--ease) both; animation-delay: calc(1s + var(--i) * 120ms); }
.js .pins i { animation: drop .7s var(--ease) both; animation-delay: calc(1.5s + var(--i) * 35ms); }
.js .reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s var(--ease), transform .7s var(--ease); transition-delay: calc(var(--i, 0) * 60ms); }
.js .reveal.in { opacity: 1; transform: none; }
.js .plan .draw { stroke-dashoffset: 100; transition: stroke-dashoffset 1.3s var(--ease) .3s; }
.js .spec.in .plan .draw, .js .identity.in .plan .draw { stroke-dashoffset: 0; }
.js .frames.in li:not(.exit) .ph { animation: huntStep 7s ease-in-out infinite; animation-delay: calc(var(--n, 0) * 1.6s); }
.js .frames li:nth-child(2) { --n: 1; } .js .frames li:nth-child(3) { --n: 2; }
.js .frames.in .exit-line path { animation: walk 2.4s linear infinite; stroke-dasharray: 4 6; }
.js .morph .m-f { animation: morphF 6s ease-in-out infinite; } .js .morph .m-h { animation: morphH 6s ease-in-out infinite; }
.js .rc-grid:not(.in) .pic-bars i { height: 6%; }
.js .rc-grid:not(.in) .pic-clock .sweep { stroke-dasharray: 100 100; }
.js .rc-grid:not(.in) .pic-clock .hand { transform: rotate(-10deg); }
.js .rc-grid:not(.in) .pic-dots i.on { background: rgba(255,255,255,.35); box-shadow: none; }
.js .rc-grid:not(.in) .pic-ring .val { stroke-dasharray: 0 100; }
.js .rc-grid:not(.in) .pic-funnel .plug { transform: translateX(40px); }
.js .ring:not(.in) .val { stroke-dasharray: 0 100; }
.js .b-grid:not(.in) .tf-w i { background: #4A3A70; }

/* ---------- hover devices only ---------- */
@media (hover: hover) {
  .btn:hover { transform: translateY(-2px); }
  .rc:hover { transform: translateY(-6px) rotate(-.6deg); box-shadow: 0 22px 40px rgba(0,0,0,.35); }
  .unit:hover, .jd-rec:hover, .jd-also:hover { transform: translateY(-2px); }
  .pin:hover .pin-i { transform: translateY(-4px); }
  .listing.tilt, .spec.tilt { transition: transform .4s var(--ease); }
}
@media (hover: none) {
  .rc:hover, .btn:hover { transform: none; }
}

/* ---------- phones ---------- */
@media (max-width: 699px) {
  .l-photo { padding: 14px 48px 0; }
  .l-lines { display: none; }
  .l-name { font-size: 24px; }
  .evid { grid-auto-flow: column; grid-auto-columns: min(78vw, 300px); overflow-x: auto; scroll-snap-type: x mandatory; margin: 0 calc(-1 * var(--padr)) 0 calc(-1 * var(--padl)); padding: 0 var(--padr) 8px var(--padl); scrollbar-width: none; }
  .evid li { scroll-snap-align: start; }
  .evid::-webkit-scrollbar { display: none; }
  .jd-also { display: none; }
  .jd-r { padding: 12px; }
  .jd-q { font-size: 15px; }
}
/* ---------- small phones ---------- */
@media (max-width: 360px) {
  :root { --padl: max(16px, env(safe-area-inset-left)); --padr: max(16px, env(safe-area-inset-right)); }
  .hero-stats { gap: 8px; }
  .hero-stats span { font-size: 12px; }
  .spec-dl { grid-template-columns: minmax(0, 1fr); }
  .spec-top { grid-template-columns: minmax(0, 1fr) 78px; } .seal { width: 78px; height: 78px; }
  .frames li { grid-template-columns: 88px minmax(0, 1fr); } .ph { width: 88px; }
  .keys { left: 128px; } .exit-line { left: 60px; width: 80px; }
  .tabbar a { padding: 0 9px; font-size: 13px; }
  .pin-l { font-size: 12px; }
  .mr { grid-template-columns: minmax(0, 1fr) auto; }
  .mr-ph { display: none; }
}
@media (max-height: 700px) and (max-width: 759px) {
  .hero { padding-top: 24px; gap: 24px; }
  .filters { display: none; }
  .listing { margin-top: 12px; }
  .l-photo { padding: 10px 70px 0; }
  .l-photo .house { max-height: 110px; }
  .l-body { padding: 12px 16px 14px; }
  .l-name { font-size: 21px; }
  .l-place { display: none; }
  .l-foot { padding-top: 10px; }
}
@media (max-height: 500px) {
  .h1 { font-size: min(13vw, 22svh); }
  .sh .disp { font-size: min(9vw, 16svh); }
  .hero-obj { max-width: 340px; }
}

/* ---------- tablet + desktop ---------- */
@media (min-width: 700px) {
  .hero-obj { max-width: 520px; }
  .amen { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .moves { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .calc-in { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; }
}
@media (min-width: 900px) {
  .top { display: flex; position: fixed; z-index: 40; inset: 0 0 auto; height: 68px; align-items: center; gap: 24px; padding: 0 var(--padr) 0 var(--padl); background: rgba(26,9,51,.82); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
  .brand { display: flex; align-items: center; gap: 10px; font-weight: 800; text-decoration: none; min-height: 44px; }
  .b-mark { width: 22px; } .b-mark path { fill: var(--pink); } .b-mark circle { fill: var(--stage); }
  .top-links { margin-left: auto; display: flex; gap: 4px; }
  .top-links a { min-height: 44px; display: inline-flex; align-items: center; padding: 0 14px; border-radius: 999px; text-decoration: none; font-weight: 700; color: var(--mut); }
  .top-links a:hover { color: var(--text); background: var(--panel); }
  .tabbar { display: none; }
  main { padding-top: 68px; padding-bottom: 0; }
  .sec { padding: 120px max(48px, var(--padr)) 120px max(48px, var(--padl)); }
  .hero { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); align-items: center; min-height: calc(100svh - 68px); padding-top: 60px; padding-bottom: 80px; }
  .hero > * { max-width: none; margin: 0; }
  .hero-obj { order: 0; justify-self: end; }
  .l-photo { padding: 18px 70px 0; }
  .h1 { font-size: clamp(110px, 12vw, 190px); }
  .identity { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 60px; }
  .identity > * { max-width: none; margin: 0; }
  .spec { justify-self: end; transform: rotate(1.5deg); }
  .map-ui { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); align-items: center; gap: 30px; }
  .map { aspect-ratio: 16 / 11; }
  .frames { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; }
  .frames li { grid-template-columns: 1fr; justify-items: start; }
  .ph { grid-row: auto; width: 168px; margin-bottom: 18px; padding: 30px 12px 12px; border-radius: 30px; }
  .mini-search { font-size: 13px; padding: 8px 10px; } .mini-rows i { height: 50px; }
  .exit-line { left: 140px; top: 60px; width: 160px; height: 80px; }
  .keys { left: 270px; top: 40px; width: 70px; height: 70px; } .keys svg { width: 44px; height: 44px; }
  .frames li.exit .f-step { padding-top: 0; }
  .rc-grid { grid-auto-flow: row; grid-template-columns: repeat(6, minmax(0, 1fr)); overflow: visible; margin: 0 auto; padding: 0; }
  .rc { grid-column: span 2; min-height: 360px; }
  .rc.big { grid-column: span 3; min-height: 400px; }
  .rc.big .pic { height: 150px; }
  .swipe-hint { display: none; }
  .case-grid { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 48px; align-items: start; }
  .case-low { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); }
  .jd-top { grid-template-columns: minmax(0, 1fr) auto; }
  .jd-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .b-grid { grid-template-columns: 360px minmax(0, 1fr); gap: 48px; align-items: start; }
  .tower { position: sticky; top: 100px; }
  .tf { min-height: 64px; }
  .ending { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 60px; }
  .ending > * { max-width: none; margin: 0; }
  .pass { justify-self: center; }
  .h-grid { grid-template-columns: minmax(0, 1fr) 280px; align-items: center; }
  .h-stamp { display: block; }
  dialog#sheet { max-width: 620px; margin: auto; }
  .sheet-in { border-radius: 26px; padding: 34px; }
  .foot { padding-bottom: 40px; }
}

/* ---------- phone landscape ---------- */
@media (max-height: 500px) and (orientation: landscape) and (max-width: 1000px) {
  .hero { grid-template-columns: minmax(0, 1fr) minmax(0, .85fr); align-items: start; gap: 28px; }
  .hero-obj { order: 0; max-width: none; }
  .filters, .l-place { display: none; }
  .l-photo { padding: 10px 60px 0; }
  .l-photo .house { max-height: 90px; }
  .l-body { padding: 10px 16px 12px; }
  .l-name { font-size: 20px; }
  .h1 { font-size: min(11vw, 24svh); }
  .hero-stats { margin: 14px 0; }
}

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
  .js .draw, .js .map-ui:not(.in) .draw, .js .plan .draw { stroke-dashoffset: 0; }
  .js .rc-grid:not(.in) .pic-bars .a { height: 45%; } .js .rc-grid:not(.in) .pic-bars .b { height: 100%; }
  .js .rc-grid:not(.in) .pic-clock .sweep { stroke-dasharray: 16 100; } .js .rc-grid:not(.in) .pic-clock .hand { transform: rotate(58deg); }
  .js .rc-grid:not(.in) .pic-dots i.on { background: var(--yellow); }
  .js .rc-grid:not(.in) .pic-ring .val, .js .ring:not(.in) .val { stroke-dasharray: var(--v) 100; }
  .js .rc-grid:not(.in) .pic-funnel .plug { transform: none; }
  .js .b-grid:not(.in) .tf-w i { background: var(--yellow); }
}
