@font-face {
  font-family: "Inter Tight";
  src: url(./fonts/inter-tight-latin-wght-normal.woff2) format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: Inter;
  src: url(./fonts/inter-latin-wght-normal.woff2) format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --k: #0b0b0b;
  --w: #fff;
  --t2: #b4b4b4;
  --t3: #8e8e8e;
  --line: rgb(255 255 255 / 0.09);
  --line2: rgb(255 255 255 / 0.16);
  --glass: rgb(14 14 14 / 0.84);
  --raised: #1e1e1e;
  --tile: #171717;
  --blue: #3b82f6;
  --brand: #e85002;
  --err: #ff7b7f;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --m: 16px;
  --head: "Inter Tight", system-ui, sans-serif;
  --body: Inter, system-ui, sans-serif;
  --mark-filter: none;
}

body[data-theme="light"] {
  color-scheme: light;
  --k: #f2f2f7;
  --w: #0b0b0b;
  --t2: #5c5c5c;
  --t3: #8e8e93;
  --line: rgb(0 0 0 / 0.08);
  --line2: rgb(0 0 0 / 0.14);
  --glass: rgb(255 255 255 / 0.88);
  --raised: #ffffff;
  --tile: #ffffff;
  --mark-filter: invert(1);
}

body[data-theme="sepia"] {
  color-scheme: light;
  --k: #e8dcc8;
  --w: #2a2118;
  --t2: #6b5a48;
  --t3: #8a7660;
  --line: rgb(42 33 24 / 0.12);
  --line2: rgb(42 33 24 / 0.2);
  --glass: rgb(244 234 214 / 0.9);
  --raised: #f4ead6;
  --tile: #f7f0e4;
  --mark-filter: invert(1) sepia(0.2);
}

body[data-glass="1"] {
  --glass: rgb(14 14 14 / 0.55);
}
body[data-theme="light"][data-glass="1"],
body[data-theme="sepia"][data-glass="1"] {
  --glass: rgb(255 255 255 / 0.55);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html, body {
  height: 100%;
  margin: 0;
  background: var(--k);
  color: var(--w);
  font: 400 15px/1.5 var(--body);
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}

h1, h2, h3, p, ul { margin: 0; padding: 0; }
ul { list-style: none; }
a { color: inherit; text-decoration: none; }

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

:focus-visible {
  outline: 2px solid var(--w);
  outline-offset: 2px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip {
  position: fixed;
  top: -80px;
  left: 16px;
  z-index: 50;
  background: #fff;
  color: #000;
  padding: 12px 16px;
  border-radius: 10px;
}
.skip:focus { top: 16px; }

/* Atmosphere — map as stage */
.sky {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background: var(--k);
}
.sky picture, .sky img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
}
.sky img {
  filter: saturate(0.45) brightness(0.32) contrast(1.08);
  transform: scale(1.04);
  opacity: 0.9;
}
body[data-theme="light"] .sky img {
  filter: saturate(0.35) brightness(0.85) contrast(0.95);
  opacity: 0.35;
}
body[data-theme="sepia"] .sky img {
  filter: saturate(0.4) brightness(0.75) sepia(0.25);
  opacity: 0.4;
}
body[data-view="map"] .sky { opacity: 0.25; }

.vignette {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(90deg, rgb(11 11 11 / 0.97) 0, rgb(11 11 11 / 0.7) 280px, transparent 560px),
    linear-gradient(180deg, rgb(11 11 11 / 0.8), transparent 130px);
}
body[data-theme="light"] .vignette {
  background:
    linear-gradient(90deg, rgb(242 242 247 / 0.92) 0, rgb(242 242 247 / 0.55) 280px, transparent 560px),
    linear-gradient(180deg, rgb(242 242 247 / 0.75), transparent 130px);
}
body[data-theme="sepia"] .vignette {
  background:
    linear-gradient(90deg, rgb(232 220 200 / 0.92) 0, rgb(232 220 200 / 0.55) 280px, transparent 560px),
    linear-gradient(180deg, rgb(232 220 200 / 0.75), transparent 130px);
}

/* Splash — mark only, always ink (no double-brand, theme-safe) */
.splash {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  background: #0b0b0b;
  color: #fff;
  animation: splash-out 1450ms var(--ease) forwards;
}
.splash-sig {
  display: flex;
  align-items: center;
  justify-content: center;
}
.splash-sig img {
  width: clamp(76px, 12vw, 108px);
  height: auto;
  filter: none;
  animation: mark-in 720ms var(--ease) 150ms both;
}
@keyframes mark-in {
  from { opacity: 0; transform: translateX(-14px); }
  to { opacity: 1; transform: none; }
}
@keyframes splash-out {
  0%, 76% { opacity: 1; visibility: visible; }
  100% { opacity: 0; visibility: hidden; }
}
body.still .splash { display: none; }

/* Top chrome */
.top {
  position: fixed;
  z-index: 5;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: calc(20px + env(safe-area-inset-top)) 28px 0;
  pointer-events: none;
}
.top > * { pointer-events: auto; }

.lockup {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  min-height: 44px;
  margin: 0;
}
.lockup img {
  display: block;
  width: 72px;
  height: auto;
  filter: var(--mark-filter);
}
.lockup i {
  width: 1px;
  height: 22px;
  background: rgb(255 255 255 / 0.35);
}
body[data-theme="light"] .lockup i,
body[data-theme="sepia"] .lockup i {
  background: rgb(0 0 0 / 0.28);
}
.lockup span {
  font: 500 19px/1 var(--head);
  letter-spacing: -0.01em;
  color: var(--t2);
}

.top-r { display: flex; gap: 10px; align-items: center; }

.pill {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 6px;
  background: var(--glass);
  border: 1px solid var(--line2);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  font: 500 13px/1 var(--body);
  transition: border-color 0.2s;
}
.pill:hover { border-color: rgb(255 255 255 / 0.4); }
body[data-theme="light"] .pill:hover,
body[data-theme="sepia"] .pill:hover {
  border-color: rgb(0 0 0 / 0.35);
}

.led {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--t3);
}
.led.on {
  background: #fff;
  box-shadow: 0 0 0 4px rgb(255 255 255 / 0.14);
}
body[data-theme="light"] .led.on,
body[data-theme="sepia"] .led.on {
  background: var(--w);
  box-shadow: 0 0 0 4px rgb(0 0 0 / 0.1);
}

.round {
  width: 44px;
  height: 44px;
  flex: none;
  border-radius: 50%;
  display: grid;
  place-items: center;
  transition: background 0.2s;
}
.round:hover { background: rgb(255 255 255 / 0.1); }

/* Views */
.view {
  position: fixed;
  z-index: 4;
  inset: calc(76px + env(safe-area-inset-top)) 0 calc(96px + env(safe-area-inset-bottom));
  max-width: 720px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  flex-direction: column;
  animation: in 0.35s var(--ease);
}
.view-scroll {
  overflow-y: auto;
  min-height: 0;
  flex: 1;
  padding-bottom: 12px;
  scrollbar-width: none;
}
.view-scroll::-webkit-scrollbar { display: none; }

@keyframes in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}
.enter {
  animation: in 0.35s var(--ease) both;
  animation-delay: calc(var(--i, 0) * 55ms);
}
body.still .enter,
body.still .view { animation: none; }

/* Home — centered greeting + deck + Ask bar */
.home-view {
  justify-content: stretch;
}
.home-mid {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding-bottom: 4vh;
}
.home-view h1,
#home-hello {
  font: 600 clamp(32px, 4.4vw, 48px) / 1.05 var(--head);
  letter-spacing: -0.04em;
  margin: 0;
}
.sub {
  font: 400 clamp(18px, 2vw, 22px) / 1.3 var(--head);
  letter-spacing: -0.015em;
  color: var(--t2);
  margin-top: 8px;
}

.page-h {
  font: 600 40px/1 var(--head);
  letter-spacing: -0.04em;
  margin: 4px 0 8px;
}
.page-sub {
  color: var(--t2);
  font-size: 15px;
  margin-bottom: 8px;
  max-width: 40ch;
}
.muted { color: var(--t2); }
.legal {
  margin-top: 18px;
  color: var(--t3);
  font-size: 12px;
  line-height: 1.45;
}

/* Deck recommendation */
.deck {
  position: relative;
  width: 100%;
  max-width: 480px;
  min-height: 88px;
  margin-top: 30px;
}
.under {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: -9px;
  height: 40px;
  border-radius: 0 0 26px 26px;
  background: #161616;
  border: 1px solid var(--line);
}
body[data-theme="light"] .under,
body[data-theme="sepia"] .under {
  background: color-mix(in srgb, var(--tile) 80%, #000 8%);
}
.deck-card {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 88px;
  border-radius: 28px;
  background: var(--raised);
  border: 1px solid var(--line2);
  box-shadow: 0 24px 50px -20px #000;
}
.deck-main {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 16px;
  text-align: left;
  padding: 18px 0 18px 18px;
  min-height: 86px;
  border-radius: 28px;
}
.deck-ic {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: #fff;
  color: #000;
  display: grid;
  place-items: center;
  flex: none;
}
body[data-theme="light"] .deck-ic,
body[data-theme="sepia"] .deck-ic {
  background: #0b0b0b;
  color: #fff;
}
.deck-t { min-width: 0; display: block; }
.deck-t b {
  display: block;
  font: 600 17px/1.3 var(--head);
  letter-spacing: -0.01em;
}
.deck-t small {
  display: block;
  font-size: 14px;
  color: var(--t2);
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.deck-next {
  width: 48px;
  height: 56px;
  display: grid;
  place-items: center;
  color: var(--t2);
  border-radius: 20px;
  flex: none;
}
.deck-next:hover { color: var(--w); }

/* Ask OX composer */
.bar {
  position: relative;
  display: flex;
  align-items: center;
  gap: 4px;
  height: 60px;
  padding: 0 8px;
  border-radius: 30px;
  background: rgb(30 30 30 / 0.94);
  border: 1px solid var(--line2);
  flex: none;
  margin-bottom: 4px;
}
body[data-theme="light"] .bar,
body[data-theme="sepia"] .bar {
  background: var(--glass);
}
.bar:focus-within { border-color: rgb(255 255 255 / 0.6); }
body[data-theme="light"] .bar:focus-within,
body[data-theme="sepia"] .bar:focus-within {
  border-color: rgb(0 0 0 / 0.45);
}
.bar input {
  flex: 1;
  min-width: 0;
  height: 100%;
  background: none;
  border: 0;
  outline: 0;
  color: var(--w);
  font: 400 17px var(--body);
  text-align: center;
}
.bar input:focus { text-align: left; }
.bar input::placeholder { color: var(--t3); }

.ask {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 60px;
  padding: 0 8px 0 20px;
  background: rgb(26 26 26 / 0.88);
  border: 1px solid var(--line2);
  border-radius: 30px;
  backdrop-filter: blur(30px);
  -webkit-backdrop-filter: blur(30px);
  box-shadow: 0 24px 60px -18px #000;
}
body[data-theme="light"] .ask,
body[data-theme="sepia"] .ask {
  background: var(--glass);
  box-shadow: 0 16px 40px -18px rgb(0 0 0 / 0.2);
}
.ask > svg { color: var(--t3); }
.ask input {
  flex: 1;
  min-width: 0;
  height: 100%;
  background: none;
  border: 0;
  outline: 0;
  color: var(--w);
  font: 400 17px var(--body);
}
.ask input::placeholder { color: var(--t3); }

.quick-pop {
  position: absolute;
  left: 8px;
  bottom: 70px;
  display: grid;
  min-width: 220px;
  padding: 8px;
  border-radius: 24px;
  background: #1c1c1c;
  border: 1px solid var(--line2);
  box-shadow: 0 30px 70px #000;
  z-index: 6;
}
body[data-theme="light"] .quick-pop,
body[data-theme="sepia"] .quick-pop {
  background: var(--raised);
}
.quick-pop button {
  min-height: 46px;
  padding: 0 14px;
  text-align: left;
  border-radius: 16px;
  font: 500 15px var(--head);
}
.quick-pop button:hover { background: rgb(255 255 255 / 0.09); }

/* Chips */
.chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 12px 4px 8px;
  margin: 0 -4px;
  scrollbar-width: none;
}
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 6px;
  border: 1px solid var(--line2);
  background: #151515;
  font-size: 14px;
  font-weight: 500;
  color: var(--t2);
}
body[data-theme="light"] .chip,
body[data-theme="sepia"] .chip {
  background: var(--tile);
}
.chip.on {
  background: #fff;
  color: #000;
  border-color: transparent;
}
body[data-theme="light"] .chip.on,
body[data-theme="sepia"] .chip.on {
  background: #0b0b0b;
  color: #fff;
}

/* Lists / cards */
.list { display: grid; gap: 10px; }
.list.compact { gap: 8px; }

.card-item,
.lot-item {
  display: grid;
  gap: 4px;
  width: 100%;
  text-align: left;
  padding: 16px 18px;
  border-radius: 28px;
  background: var(--tile);
  border: 1px solid var(--line);
}
.lot-item {
  grid-template-columns: 1fr auto;
  align-items: center;
}
.card-item strong,
.lot-item strong {
  font: 600 16px/1.25 var(--head);
  letter-spacing: -0.02em;
}
.card-item .muted,
.lot-item .muted { font-size: 14px; }
.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--t3);
}
.tag .live {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--brand);
}
.walk {
  font: 650 18px/1 var(--head);
  letter-spacing: -0.03em;
}

/* Hero rows — white on dark themes, ink on light */
.card-item.hero,
.lot-item.hero {
  background: #fff;
  color: #000;
  border-color: transparent;
}
.card-item.hero .muted,
.lot-item.hero .muted,
.card-item.hero .tag,
.lot-item.hero .tag {
  color: rgb(0 0 0 / 0.55);
}
.lot-item.hero .walk { color: #000; }

body[data-theme="light"] .card-item.hero,
body[data-theme="light"] .lot-item.hero,
body[data-theme="sepia"] .card-item.hero,
body[data-theme="sepia"] .lot-item.hero {
  background: #0b0b0b;
  color: #fff;
}
body[data-theme="light"] .card-item.hero .muted,
body[data-theme="light"] .lot-item.hero .muted,
body[data-theme="light"] .card-item.hero .tag,
body[data-theme="light"] .lot-item.hero .tag,
body[data-theme="sepia"] .card-item.hero .muted,
body[data-theme="sepia"] .lot-item.hero .muted,
body[data-theme="sepia"] .card-item.hero .tag,
body[data-theme="sepia"] .lot-item.hero .tag {
  color: rgb(255 255 255 / 0.62);
}
body[data-theme="light"] .lot-item.hero .walk,
body[data-theme="sepia"] .lot-item.hero .walk {
  color: #fff;
}

/* Reserve */
.spot-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 8px 0 18px;
}
.spot {
  position: relative;
  min-height: 72px;
  border-radius: 20px;
  border: 1px solid var(--line2);
  background: var(--tile);
  display: grid;
  place-items: center;
  font: 600 16px/1 var(--head);
  letter-spacing: -0.02em;
}
.spot.busy {
  color: var(--t3);
  background:
    linear-gradient(135deg, transparent 46%, var(--line2) 46%, var(--line2) 54%, transparent 54%),
    var(--tile);
}
.spot-busy-id {
  position: relative;
  z-index: 1;
  font-size: 12px;
  opacity: 0.7;
}
.spot.free.on {
  border-color: var(--blue);
  color: var(--blue);
  box-shadow: inset 0 0 0 1px var(--blue);
}
.pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 14px;
}
.pair-card {
  padding: 14px;
  border-radius: 20px;
  background: var(--raised);
  border: 1px solid var(--line);
  display: grid;
  gap: 4px;
}
.pair-card strong {
  font: 650 18px/1.1 var(--head);
  letter-spacing: -0.03em;
}
.pair-card span { color: var(--t3); font-size: 12px; }
.field { margin-bottom: 14px; }
.field .label {
  display: block;
  margin-bottom: 8px;
  color: var(--t2);
  font-size: 13px;
}

.btn {
  width: 100%;
  border-radius: 6px;
  min-height: 52px;
  padding: 0 20px;
  background: #fff;
  color: #000;
  font-weight: 650;
}
.btn:active { transform: scale(0.97); }
.btn:hover { background: #e4e4e4; }
body[data-theme="light"] .btn,
body[data-theme="sepia"] .btn {
  background: #0b0b0b;
  color: #fff;
}
body[data-theme="light"] .btn:hover,
body[data-theme="sepia"] .btn:hover {
  background: #222;
}

/* Map */
.map-view {
  max-width: none;
  padding: 0 12px;
  gap: 12px;
}
.map-stage {
  position: relative;
  flex: 1;
  min-height: 200px;
  border-radius: 28px;
  overflow: hidden;
  border: 1px solid var(--line);
  background:
    radial-gradient(80% 60% at 30% 20%, #1a2430, transparent),
    linear-gradient(160deg, #121212, #0a0f14 60%, #101820);
}
.map-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgb(255 255 255 / 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgb(255 255 255 / 0.04) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: radial-gradient(circle at 50% 45%, #000 30%, transparent 75%);
}
.map-route {
  position: absolute;
  left: 18%;
  top: 30%;
  width: 58%;
  height: 42%;
  border: 2px solid rgb(59 130 246 / 0.75);
  border-left: 0;
  border-bottom: 0;
  border-radius: 0 40% 0 0;
  filter: drop-shadow(0 0 8px rgb(59 130 246 / 0.35));
}
.map-pin {
  position: absolute;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--blue);
  transform: translate(-50%, -50%);
  box-shadow: 0 0 0 4px rgb(59 130 246 / 0.2);
}
.map-pin[data-kind="event"] { background: var(--brand); border-color: #fff; }
.map-pin[data-kind="civic"] { background: var(--blue); border-color: #fff; }
.map-pill {
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  padding: 6px 12px;
  border-radius: 6px;
  background: var(--glass);
  border: 1px solid var(--line2);
  backdrop-filter: blur(16px);
  font-size: 12px;
  color: var(--t2);
  white-space: nowrap;
}
.sheet {
  flex: none;
  max-height: 46%;
  overflow: auto;
  padding: 4px 14px 14px;
  border-radius: 30px 30px 24px 24px;
  background: var(--glass);
  border: 1px solid var(--line);
  backdrop-filter: blur(22px);
  scrollbar-width: none;
}
.sheet::-webkit-scrollbar { display: none; }
.grip {
  display: grid;
  place-items: center;
  width: 100%;
  height: 28px;
}
.grip i {
  width: 40px;
  height: 5px;
  border-radius: 3px;
  background: rgb(255 255 255 / 0.32);
}
body[data-theme="light"] .grip i,
body[data-theme="sepia"] .grip i {
  background: rgb(0 0 0 / 0.25);
}
.live-card {
  margin: 10px 0;
  padding: 14px;
  border-radius: 20px;
  background: var(--raised);
  border: 1px solid var(--line);
}
.live-head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--t2);
}
.rec {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--err);
  box-shadow: 0 0 0 3px rgb(255 123 127 / 0.2);
}
.live-big {
  font: 650 24px/1.15 var(--head);
  letter-spacing: -0.035em;
  margin: 6px 0 2px;
}

/* Empty / wallet */
.empty {
  padding: 34px 24px;
  border-radius: 28px;
  background: var(--tile);
  border: 1px solid var(--line);
  margin-top: 8px;
}
.empty svg { width: 34px; height: 34px; color: var(--t2); }
.empty h2 {
  font: 600 24px var(--head);
  letter-spacing: -0.03em;
  margin: 18px 0 6px;
}
.empty p { color: var(--t2); max-width: 46ch; }

/* You tiles */
.tiles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 10px;
}
.tile {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  min-height: 132px;
  padding: 20px;
  border-radius: 28px;
  background: var(--tile);
  border: 1px solid var(--line);
  transition: background 0.2s, transform 0.15s;
  min-width: 0;
}
.tile:hover { background: #1f1f1f; }
body[data-theme="light"] .tile:hover,
body[data-theme="sepia"] .tile:hover {
  background: color-mix(in srgb, var(--tile) 90%, #000 6%);
}
.tile:active { transform: scale(0.98); }
.tile svg { width: 26px; height: 26px; margin-bottom: auto; }
.tile b {
  font: 600 17px/1.3 var(--head);
  letter-spacing: -0.01em;
  margin-top: 18px;
}
.tile small {
  font-size: 13px;
  color: var(--t2);
  overflow-wrap: anywhere;
}

/* Settings rows + liquid switch */
.back {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--t2);
  min-height: 36px;
  margin-bottom: 6px;
}
.rows {
  border-radius: 28px;
  background: var(--tile);
  border: 1px solid var(--line);
  overflow: hidden;
  margin-top: 14px;
}
.set {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  width: 100%;
  text-align: left;
  padding: 16px 20px;
  border-top: 1px solid var(--line);
}
.rows .set:first-child { border-top: 0; }
.set b {
  display: block;
  font: 500 16px var(--head);
}
.set small {
  display: block;
  color: var(--t2);
  font-size: 13px;
  margin-top: 2px;
}
.set.static b { font-weight: 560; color: var(--t2); }
.chev { opacity: 0.45; width: 18px; height: 18px; }

.set.toggle { cursor: pointer; position: relative; }
.set.toggle input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.liq-sw {
  position: relative;
  width: 64px;
  height: 44px;
  flex: none;
}
.liq-sw::before {
  content: "";
  position: absolute;
  inset: 4px 0;
  border-radius: 99px;
  background: #333;
  transition: background 0.42s ease;
}
.liq-thumb {
  position: absolute;
  left: 4px;
  top: 8px;
  width: 28px;
  height: 28px;
  border-radius: 99px;
  background: #fff;
  transition: left 0.42s cubic-bezier(0.3, 1.3, 0.5, 1), background 0.42s;
}
.set.toggle input:checked + .liq-sw::before { background: #fff; }
.set.toggle input:checked + .liq-sw .liq-thumb {
  left: 32px;
  background: #0b0b0b;
}
body[data-theme="light"] .set.toggle input:checked + .liq-sw::before,
body[data-theme="sepia"] .set.toggle input:checked + .liq-sw::before {
  background: #0b0b0b;
}
body[data-theme="light"] .set.toggle input:checked + .liq-sw .liq-thumb,
body[data-theme="sepia"] .set.toggle input:checked + .liq-sw .liq-thumb {
  background: #fff;
}

.theme-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 14px 0 8px;
}
.theme-card {
  display: grid;
  gap: 8px;
  justify-items: center;
  padding: 10px;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: var(--tile);
  font-size: 13px;
  color: var(--t2);
}
.theme-card.on {
  border-color: var(--w);
  color: var(--w);
}
.theme-preview {
  width: 100%;
  aspect-ratio: 1 / 1.15;
  border-radius: 12px;
  border: 1px solid var(--line2);
}
.theme-preview.dark { background: #111; }
.theme-preview.light { background: #f4f4f4; }
.theme-preview.sepia { background: #e8dcc8; }

/* Floating dock — Parking sibling */
.dock {
  position: fixed;
  z-index: 7;
  left: 50%;
  bottom: calc(16px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  display: flex;
  gap: 4px;
  padding: 6px;
  border-radius: 34px;
  background: rgb(22 22 22 / 0.86);
  border: 1px solid var(--line2);
  backdrop-filter: blur(30px);
  -webkit-backdrop-filter: blur(30px);
  box-shadow: 0 20px 60px #000;
}
body[data-theme="light"] .dock,
body[data-theme="sepia"] .dock {
  background: var(--glass);
  box-shadow: 0 16px 40px rgb(0 0 0 / 0.18);
}
.dock button {
  width: 78px;
  height: 52px;
  border-radius: 27px;
  display: grid;
  place-items: center;
  color: var(--t2);
  transition: background 0.25s, color 0.2s, transform 0.15s;
}
.dock button:active { transform: scale(0.95); }
.dock button[aria-current] {
  background: rgb(255 255 255 / 0.14);
  color: #fff;
}
body[data-theme="light"] .dock button[aria-current],
body[data-theme="sepia"] .dock button[aria-current] {
  background: rgb(0 0 0 / 0.1);
  color: var(--w);
}
.dock svg { width: 24px; height: 24px; }
.dock button[aria-current] svg { fill: currentColor; }

.toast {
  position: fixed;
  z-index: 60;
  left: 50%;
  bottom: calc(96px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  max-width: min(420px, calc(100% - 32px));
  padding: 12px 16px;
  border-radius: 16px;
  background: #fff;
  color: #000;
  font-weight: 560;
  box-shadow: 0 10px 30px rgb(0 0 0 / 0.35);
}
body[data-theme="light"] .toast,
body[data-theme="sepia"] .toast {
  background: #0b0b0b;
  color: #fff;
}

@media (max-width: 820px) {
  .view {
    inset-block: calc(66px + env(safe-area-inset-top)) calc(92px + env(safe-area-inset-bottom));
    padding: 0 16px;
  }
  .top { padding-inline: 16px; }
  .pill { padding: 0 14px; }
  .map-view { padding: 0 12px; }
}

@media (min-width: 821px) {
  .dock { bottom: 20px; }
  .tiles { grid-template-columns: repeat(3, 1fr); }
  .map-view {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    max-width: 1100px;
    inset-inline: 28px;
    margin-inline: auto;
  }
  .map-stage { min-height: 0; }
  .sheet { max-height: none; }
}

@media (max-width: 380px) {
  .lockup { gap: 9px; }
  .lockup img { width: 60px; }
  .lockup span { font-size: 16px; }
  .dock button { width: 68px; height: 48px; }
}

@media (prefers-reduced-motion: reduce) {
  .splash { display: none; }
  .enter, .view, .splash-sig img { animation: none !important; }
}
