/* Deep City 100K. Colour tokens from deep-city/ep02/index.html. */
@font-face { font-family: "Mukta"; src: url("/assets/fonts/mukta-latin-800.woff2") format("woff2"); font-weight: 800; font-display: swap; }
:root {
  --ink0: #030e1f; --ink1: #06203f; --ink2: #0d3766; --ocean: #1a5a8c;
  --panel: #040e20; --panel2: #071428; --edge: #1f3d63; --line: #3f6590; --plate: #0a1526;
  --label: #9cc8ee; --muted: #b5cbe2; --faint: #7f97b5;
  --amber: #ffc35a; --amber-hi: #ffe7a3; --amber-lo: #d98a1f;
  --glass: #8ee8ff; --garden: #5dffb0; --red: #ff6b6b; --text: #ffffff;
  --display: "Mukta", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --body: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { background: var(--ink0); -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; color: var(--text); font: 16px/1.5 var(--body); overflow-x: hidden;
  background: linear-gradient(180deg, var(--ocean) 0, var(--ink2) 28%, var(--ink1) 62%, var(--ink0) 100%); }
a { color: var(--label); }
a:hover { color: var(--amber-hi); }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; }

/* bubbles rising behind everything */
.bubbles { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 0; }
.bubbles i { position: absolute; bottom: -40px; width: 10px; height: 10px; border: 1.5px solid rgba(191, 230, 255, 0.45); border-radius: 50%; animation: rise 14s linear infinite; }
.bubbles i:nth-child(1) { left: 6%; animation-duration: 13s; }
.bubbles i:nth-child(2) { left: 14%; width: 6px; height: 6px; animation-duration: 9s; animation-delay: -4s; }
.bubbles i:nth-child(3) { left: 23%; width: 14px; height: 14px; animation-duration: 17s; animation-delay: -9s; }
.bubbles i:nth-child(4) { left: 35%; width: 5px; height: 5px; animation-duration: 11s; animation-delay: -2s; }
.bubbles i:nth-child(5) { left: 47%; animation-duration: 15s; animation-delay: -12s; }
.bubbles i:nth-child(6) { left: 58%; width: 7px; height: 7px; animation-duration: 10s; animation-delay: -6s; }
.bubbles i:nth-child(7) { left: 66%; width: 16px; height: 16px; animation-duration: 19s; animation-delay: -3s; }
.bubbles i:nth-child(8) { left: 74%; width: 5px; height: 5px; animation-duration: 8s; animation-delay: -5s; }
.bubbles i:nth-child(9) { left: 82%; animation-duration: 14s; animation-delay: -10s; }
.bubbles i:nth-child(10) { left: 90%; width: 8px; height: 8px; animation-duration: 12s; animation-delay: -7s; }
.bubbles i:nth-child(11) { left: 96%; width: 12px; height: 12px; animation-duration: 16s; animation-delay: -1s; }
.bubbles i:nth-child(12) { left: 41%; width: 6px; height: 6px; animation-duration: 9.5s; animation-delay: -8s; }
@keyframes rise { to { transform: translate3d(0, -112vh, 0); } }

.top, .page, .foot { position: relative; z-index: 1; }
.top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; max-width: 1180px; margin: 0 auto; }
.brand { font: 800 19px/1 var(--display); letter-spacing: 3px; color: var(--text); text-decoration: none; }
.brand span { color: var(--amber); }
.ig { font: 800 15px/1 var(--display); letter-spacing: 0.5px; text-decoration: none; }

.page { max-width: 560px; margin: 0 auto; padding: 0 16px; }

/* the city */
.hero { position: relative; margin: 0 -16px; height: clamp(230px, 44vh, 400px); overflow: hidden; }
.hero svg { display: block; width: 100%; height: 100%; }
.pill { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center;
  padding: 7px 20px 6px; border-radius: 18px; background: rgba(4, 14, 32, 0.92); border: 2px solid rgba(255, 195, 90, 0.4); white-space: nowrap; }
.pill-label { font: 800 12px/1.2 var(--display); letter-spacing: 4px; color: var(--label); }
.pill-num { font: 800 26px/1.15 var(--display); color: var(--amber); text-shadow: 0 0 14px rgba(255, 195, 90, 0.55); font-variant-numeric: tabular-nums; }
.anomaly { animation: flick 7s infinite; }
@keyframes flick { 0%, 88%, 100% { opacity: 0.16; } 90% { opacity: 0.7; } 91% { opacity: 0.12; } 92.5% { opacity: 0.55; } 94% { opacity: 0.16; } }   /* ep 2: its light went out */

/* claiming */
h1 { font: 800 clamp(34px, 9vw, 46px)/1.05 var(--display); margin: 20px 0 4px; letter-spacing: 0.2px; }
.lede { margin: 0 0 16px; font-size: 17px; color: var(--muted); }
.lab { display: block; font: 800 13px/1.3 var(--display); letter-spacing: 2.5px; text-transform: uppercase; color: var(--label); margin: 0 0 8px; padding: 0; }
.plate { display: flex; align-items: center; gap: 2px; height: 60px; padding: 0 14px; border-radius: 14px; background: var(--plate);
  border: 3px solid var(--line); transition: border-color 0.2s, box-shadow 0.2s; }
.plate:focus-within { border-color: var(--amber); box-shadow: 0 0 26px rgba(255, 195, 90, 0.35); }
.plate span { font: 800 26px/1 var(--display); color: var(--amber); }
.plate input { flex: 1; min-width: 0; height: 100%; border: 0; outline: none; background: transparent; color: var(--amber); font: 800 25px/1 var(--display); padding: 4px 0 0; }
.plate input::placeholder { color: #4f6a8c; }
.err { margin: 6px 0 0; font-size: 14.5px; color: #ff9a9a; }
.err:empty { display: none; }

.stage { margin: 14px -16px 0; overflow: hidden; }
.stage svg { display: block; width: 100%; height: auto; }

form { margin: 0; }
.districts { border: 0; margin: 16px 0 0; padding: 0; min-width: 0; }
.d { position: relative; display: flex; align-items: center; gap: 12px; margin-top: 8px; padding: 11px 14px; border-radius: 14px; cursor: pointer;
  background: rgba(4, 14, 32, 0.72); border: 2px solid var(--edge); transition: border-color 0.2s, background 0.2s; }
.d input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.d:has(input:checked) { border-color: var(--amber); background: rgba(10, 21, 38, 0.95); }
.d:has(input:focus-visible) { outline: 3px solid var(--amber); outline-offset: 2px; }
.dot { flex: none; width: 22px; height: 22px; border-radius: 50%; border: 3px solid var(--c); }
.dot[data-d="glass"] { --c: var(--glass); } .dot[data-d="gardens"] { --c: var(--garden); } .dot[data-d="next"] { --c: var(--red); }
.d input:checked + .dot { background: var(--c); box-shadow: 0 0 14px var(--c); }
.dtxt { display: flex; flex-direction: column; }
.dn { font: 800 18px/1.25 var(--display); }
.dd { font-size: 14px; color: var(--muted); }
.check { display: flex; gap: 10px; align-items: flex-start; margin: 16px 0 0; font-size: 14.5px; color: var(--muted); cursor: pointer; }
.check input { flex: none; width: 22px; height: 22px; margin: 1px 0 0; accent-color: var(--amber); }
.invite { margin: 16px 0 0; padding: 12px 14px; border-radius: 14px; border: 2px dashed var(--glass); background: rgba(4, 14, 32, 0.72); color: #dff6ff; font-size: 15.5px; }
.invite b { color: var(--glass); font-family: var(--display); font-weight: 800; }
.walklink { margin: 18px 0 0; text-align: center; font-size: 15px; }
.result .btn.alt { margin-top: 10px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.btn { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 58px; margin-top: 18px; padding: 6px 16px 2px; border: 0; border-radius: 16px; cursor: pointer;
  background: linear-gradient(180deg, var(--amber-hi), var(--amber) 55%, var(--amber-lo)); color: #0a1526; font: 800 20px/1.1 var(--display); text-decoration: none;
  box-shadow: 0 8px 28px rgba(255, 170, 60, 0.32); }
.btn:hover { color: #0a1526; filter: brightness(1.05); }
.btn:disabled { opacity: 0.6; cursor: wait; }
.btn.alt { background: transparent; color: var(--amber); border: 2px solid var(--amber); box-shadow: none; }
.ghost { display: block; margin: 14px auto 0; padding: 8px; background: none; border: 0; color: var(--label); font: 15px var(--body); text-decoration: underline; cursor: pointer; }

.result { text-align: center; padding: 16px 0 4px; }
.kick { margin: 0; font: 800 14px/1.3 var(--display); letter-spacing: 5px; color: var(--label); }
.homeNo { margin: 4px 0 0; font: 800 18px/1.2 var(--display); letter-spacing: 3px; color: #cfe3f7; }
.homeNo b { display: block; font-size: clamp(54px, 16vw, 72px); line-height: 1; letter-spacing: 0; color: var(--amber); text-shadow: 0 0 26px rgba(255, 195, 90, 0.5); font-variant-numeric: tabular-nums; }
.who { margin: 10px 0 0; font: 800 21px/1.4 var(--display); overflow-wrap: anywhere; }
.chip { display: inline-block; margin-left: 4px; padding: 2px 12px 0; border-radius: 999px; border: 2px solid var(--c); color: var(--c); font-size: 14px; letter-spacing: 1px; vertical-align: 2px; }
.chip[data-d="glass"] { --c: var(--glass); } .chip[data-d="gardens"] { --c: var(--garden); } .chip[data-d="next"] { --c: var(--red); }
.note { margin: 8px 0 0; color: var(--muted); font-size: 15px; }
.small { margin: 14px 0 0; font-size: 13px; color: var(--faint); }

.foot { max-width: 560px; margin: 36px auto 0; padding: 0 16px calc(28px + env(safe-area-inset-bottom)); font-size: 13px; color: #8aa6c4; text-align: center; }
.foot p { margin: 6px 0; }

/* the Story picture */
dialog { width: min(92vw, 420px); max-height: 94vh; overflow: auto; padding: 18px; border-radius: 22px; background: var(--panel2); color: var(--text); border: 2px solid rgba(255, 195, 90, 0.4); }
dialog::backdrop { background: rgba(2, 6, 15, 0.82); }
dialog h2 { margin: 0 0 12px; font: 800 22px/1.2 var(--display); }
dialog img { display: block; width: 100%; max-height: 50vh; object-fit: contain; border-radius: 12px; background: var(--ink0); }
dialog .row { display: flex; gap: 10px; }
dialog .row .btn { margin-top: 14px; min-height: 52px; font-size: 18px; }
.steps { margin: 14px 0 0; padding-left: 22px; font-size: 14.5px; color: var(--muted); }
.steps li { margin: 3px 0; }

.fade { transition: opacity 0.8s ease; }

/* privacy and house rules */
.doc { position: relative; z-index: 1; max-width: 680px; margin: 0 auto; padding: 8px 16px calc(40px + env(safe-area-inset-bottom)); color: #dbe8f5; }
.doc h1 { margin: 18px 0 2px; }
.doc h2 { margin: 28px 0 6px; font: 800 21px/1.25 var(--display); color: var(--amber); }
.doc p, .doc li { font-size: 16.5px; line-height: 1.6; }
.doc ul { padding-left: 22px; }
.doc li { margin: 4px 0; }
.doc .updated { margin: 0 0 18px; color: var(--faint); font-size: 14px; }
.doc .back { margin-top: 34px; font-size: 15px; }
.todo { padding: 1px 6px; border-radius: 6px; background: #ffc35a; color: #0a1526; font-weight: 700; }

@media (min-width: 980px) {
  .page { max-width: 1180px; display: grid; grid-template-columns: minmax(0, 1fr) 440px; gap: 48px; align-items: start; padding: 0 32px; }
  .hero { position: sticky; top: 20px; margin: 8px 0 0; height: auto; aspect-ratio: 1080 / 1110; border-radius: 28px; }
  .stage { margin: 14px 0 0; border-radius: 22px; }
  .foot { max-width: 1180px; }
}
@media (prefers-reduced-motion: reduce) {
  .bubbles, .anomaly { animation: none; display: none; }
  .anomaly { display: inline; opacity: 0.16; }
  .fade { transition: none; }
}

.unlock { margin: 14px 0 0; padding: 12px; border-radius: 14px; border: 1.5px solid var(--line); background: rgba(4, 14, 32, 0.7); text-align: left; }
.unlock p { margin: 0 0 8px; font-size: 14px; color: var(--muted); }
.pinrow { display: flex; gap: 8px; }
.pinrow input { flex: 1; min-width: 0; height: 52px; padding: 0 14px; border-radius: 14px; border: 2px solid var(--line); background: var(--plate); color: var(--amber); font: 800 22px/1 var(--display); letter-spacing: 8px; }
.pinrow .btn { width: auto; margin-top: 0; min-height: 52px; padding: 6px 18px 2px; }
.votebar { display: block; margin: 14px 0 0; padding: 11px 14px; border-radius: 14px; border: 1.5px solid rgba(255, 107, 107, 0.55); background: rgba(40, 6, 14, 0.55); color: #ffd6d6; text-decoration: none; font-size: 14.5px; }
.votebar b { color: #ff8a8a; font-family: var(--display); }
.votebar span { display: block; margin-top: 2px; font: 800 14px/1.3 var(--display); color: #fff; }

.shiftbar { display: block; margin: 14px 0 0; padding: 11px 14px; border-radius: 14px; border: 1.5px solid rgba(255, 195, 90, 0.5); background: rgba(40, 28, 6, 0.45); color: #ffeac2; text-decoration: none; font-size: 14.5px; }
.shiftbar b { color: var(--amber); font-family: var(--display); }
.shiftbar span { display: block; margin-top: 2px; font: 800 14px/1.3 var(--display); color: #fff; }
