/* Cohort 9 Daily: midnight-navy, glass, glow.
   Display: Outfit. Accent: Instrument Serif italic (headline accents, big numerals). */

:root {
  --bg: #050b1f;
  --bg-deep: #030716;
  --ink: #eef2ff;
  --muted: #8e9bc4;
  --faint: #5d6a94;
  --line: rgba(130, 160, 255, 0.14);
  --line-strong: rgba(130, 160, 255, 0.3);
  --glass: linear-gradient(180deg, rgba(26, 40, 88, 0.62), rgba(12, 21, 52, 0.66));
  --glass-flat: rgba(14, 24, 58, 0.6);
  --field: rgba(4, 9, 28, 0.55);
  --accent: #5c8dff;
  --accent-soft: #9db8ff;
  --accent-deep: #3461f0;
  --agree: #3ddc97;
  --disagree: #ff6b8b;
  --gold: #e8c37a;
  --wa: #25d366;
  --radius: 24px;
  --serif: "Instrument Serif", ui-serif, Georgia, serif;
  --sans: "Outfit", system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; background: var(--bg-deep); }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
  padding-bottom: calc(110px + env(safe-area-inset-bottom));
}
/* Glow + dotted texture, fixed behind everything */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background:
    radial-gradient(70% 45% at 88% -5%, rgba(56, 98, 255, 0.55), transparent 70%),
    radial-gradient(55% 40% at -10% 35%, rgba(40, 70, 210, 0.2), transparent 70%),
    radial-gradient(60% 35% at 50% 110%, rgba(60, 90, 230, 0.16), transparent 70%),
    linear-gradient(180deg, #081232 0%, #050b1f 40%, #030716 100%);
}
body::after {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image: radial-gradient(rgba(150, 180, 255, 0.28) 1px, transparent 1.5px);
  background-size: 18px 18px;
  -webkit-mask-image: radial-gradient(75% 55% at 75% 8%, #000 0%, transparent 72%);
  mask-image: radial-gradient(75% 55% at 75% 8%, #000 0%, transparent 72%);
}

h1, h2, h3 { font-family: var(--sans); font-weight: 500; letter-spacing: -0.025em; }
h2 { font-size: 27px; line-height: 1.12; margin: 0 0 2px; }
h1 em, h2 em, .brand-name em {
  font-family: var(--serif); font-style: italic; font-weight: 400; letter-spacing: -0.01em;
}
h2 em { color: var(--accent-soft); font-size: 1.12em; }
p { margin: 0; }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
::selection { background: rgba(92, 141, 255, 0.4); }

/* ---------- header: floating glass pill ---------- */
.top {
  position: sticky; top: 10px; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  max-width: 560px; margin: 10px auto 0; width: calc(100% - 24px);
  padding: 8px 8px 8px 18px;
  background: rgba(8, 15, 40, 0.62);
  border: 1px solid var(--line);
  border-radius: 999px;
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  backdrop-filter: blur(18px) saturate(140%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 10px 30px -12px rgba(0, 0, 0, 0.7);
}
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand-logo { height: 30px; width: auto; display: block; flex: none; }
.brand-divider { width: 1px; height: 28px; background: var(--line-strong); flex: none; }
.brand-name { font: 600 18px/1 var(--sans); letter-spacing: -0.02em; white-space: nowrap; }
.brand-name em { color: var(--accent-soft); font-size: 21px; margin-left: 1px; }
.brand-sub {
  font-size: 11px; font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--muted); margin-top: 4px; white-space: nowrap;
}
.me-chip {
  display: flex; align-items: center; gap: 8px; max-width: 46vw;
  border: 0; background: #fff; color: #0a1433; border-radius: 999px;
  padding: 7px 14px 7px 8px; font-size: 14px; font-weight: 600;
  box-shadow: 0 6px 20px -8px rgba(255, 255, 255, 0.4);
}
.me-chip span:first-child {
  display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%;
  background: #e8eeff; font-size: 15px;
}
.me-chip span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- layout ---------- */
main { max-width: 560px; margin: 0 auto; padding: 22px 16px; display: grid; gap: 30px; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.section-head .meta { color: var(--muted); font-size: 13px; white-space: nowrap; padding-bottom: 4px; }
.kicker {
  display: inline-flex; align-items: center; gap: 6px;
  font: 600 10.5px/1 var(--sans); letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--accent-soft);
  padding: 7px 10px; margin-bottom: 10px;
  border: 1px solid rgba(120, 150, 255, 0.32); border-radius: 9px;
  background: rgba(60, 90, 220, 0.14);
}
.card > .kicker, .card .kicker { justify-self: start; }
.kicker.gold { color: var(--gold); border-color: rgba(232, 195, 122, 0.4); background: rgba(232, 195, 122, 0.08); }
.card {
  position: relative;
  background: var(--glass);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 24px 48px -28px rgba(0, 0, 0, 0.9);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}
.stack { display: grid; gap: 12px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
b, strong { font-weight: 600; }

/* Countdown strip with a live dot */
.countdown {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px; border-radius: 999px;
  background: var(--glass-flat); border: 1px solid var(--line);
  font-size: 14px; color: var(--muted);
}
.countdown b { color: var(--ink); font: 400 19px/1 var(--serif); font-variant-numeric: tabular-nums; letter-spacing: 0.01em; }
.live-dot {
  width: 8px; height: 8px; border-radius: 50%; background: #ff5d6c; flex: none;
  box-shadow: 0 0 0 4px rgba(255, 93, 108, 0.18); animation: pulse 1.8s ease-in-out infinite;
}
@keyframes pulse { 50% { box-shadow: 0 0 0 7px rgba(255, 93, 108, 0.06); } }

/* ---------- buttons ---------- */
.primary {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; border-radius: 999px; padding: 15px 22px; width: 100%;
  background: linear-gradient(180deg, #6a97ff 0%, #3b67f5 100%);
  color: #fff; font: 600 16px/1 var(--sans); letter-spacing: -0.01em; text-decoration: none;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.35),
    0 0 0 1px rgba(150, 180, 255, 0.45),
    0 12px 32px -8px rgba(59, 103, 245, 0.75),
    0 0 48px -6px rgba(59, 103, 245, 0.35);
  transition: transform 0.12s, filter 0.15s;
}
.primary:hover { filter: brightness(1.08); }
.primary:active { transform: scale(0.985); }
.primary:disabled { opacity: 0.45; box-shadow: none; }

/* White pill, WhatsApp mark in front (like a "Join community" button) */
.share-btn {
  display: inline-flex; align-items: center; gap: 7px; text-decoration: none; white-space: nowrap;
  border: 0; border-radius: 999px; padding: 8px 14px 8px 10px;
  background: #fff; color: #0a1433; font: 600 13px/1 var(--sans);
  box-shadow: 0 6px 18px -8px rgba(255, 255, 255, 0.35);
  transition: transform 0.12s;
}
.share-btn:active { transform: scale(0.97); }
.share-btn::before {
  content: ""; width: 17px; height: 17px; flex: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%2325D366' d='M17.47 14.38c-.3-.15-1.76-.87-2.03-.97-.27-.1-.47-.15-.67.15-.2.3-.77.97-.94 1.16-.17.2-.35.22-.64.07-.3-.15-1.26-.46-2.39-1.47-.88-.79-1.48-1.76-1.65-2.06-.17-.3-.02-.46.13-.6.13-.14.3-.35.45-.52.15-.17.2-.3.3-.5.1-.2.05-.37-.03-.52-.07-.15-.67-1.61-.92-2.2-.24-.58-.49-.5-.67-.51h-.57c-.2 0-.52.07-.79.37-.27.3-1.04 1.02-1.04 2.48 0 1.46 1.07 2.88 1.21 3.07.15.2 2.1 3.2 5.08 4.49.71.31 1.26.49 1.7.63.71.22 1.36.19 1.87.12.57-.09 1.76-.72 2.01-1.41.25-.7.25-1.29.17-1.41-.07-.13-.27-.2-.57-.35M12.05 21.78h-.01a9.87 9.87 0 0 1-5.03-1.38l-.36-.21-3.74.98 1-3.65-.24-.37a9.86 9.86 0 0 1-1.51-5.26c0-5.45 4.44-9.88 9.89-9.88 2.64 0 5.12 1.03 6.99 2.9a9.83 9.83 0 0 1 2.89 6.99c0 5.45-4.44 9.88-9.88 9.88m8.41-18.3A11.82 11.82 0 0 0 12.05 0C5.5 0 .16 5.34.16 11.89c0 2.1.55 4.14 1.59 5.95L.06 24l6.3-1.65a11.88 11.88 0 0 0 5.68 1.45h.01c6.55 0 11.89-5.34 11.89-11.89 0-3.18-1.24-6.16-3.48-8.41'/%3E%3C/svg%3E") center / contain no-repeat;
}
.share-btn.no-wa::before { display: none; }
.share-btn.no-wa { padding-left: 14px; }

.link-btn {
  border: 0; background: none; padding: 6px 0; font-size: 14px; font-weight: 500;
  color: var(--muted); text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 4px;
}
.link-btn:hover { color: var(--ink); }
.pill {
  border: 1px solid var(--line-strong); background: rgba(255, 255, 255, 0.04); border-radius: 999px;
  padding: 8px 14px; font-size: 13px; font-weight: 600; color: var(--ink);
}
.pill.on { background: #fff; color: #0a1433; border-color: #fff; }

/* ---------- hot takes ---------- */
.take-text { font: 500 21px/1.28 var(--sans); letter-spacing: -0.02em; margin-bottom: 16px; }
.vote-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.vote-btn {
  border: 1px solid var(--line-strong); background: rgba(255, 255, 255, 0.03); border-radius: 999px;
  padding: 12px 8px; font-weight: 600; font-size: 15px; color: var(--ink);
  transition: transform 0.08s, background 0.15s, border-color 0.15s, box-shadow 0.15s;
}
.vote-btn:active { transform: scale(0.97); }
.vote-btn.agree:hover, .vote-btn.agree.on {
  border-color: var(--agree); background: rgba(61, 220, 151, 0.12); box-shadow: 0 0 24px -6px rgba(61, 220, 151, 0.5);
}
.vote-btn.disagree:hover, .vote-btn.disagree.on {
  border-color: var(--disagree); background: rgba(255, 107, 139, 0.12); box-shadow: 0 0 24px -6px rgba(255, 107, 139, 0.5);
}
.split { margin-top: 16px; }
.split-bar { display: flex; height: 6px; border-radius: 999px; overflow: hidden; background: rgba(255, 255, 255, 0.06); gap: 3px; }
.split-bar i { display: block; height: 100%; transition: width 0.6s cubic-bezier(0.2, 0.8, 0.2, 1); }
.split-bar .a { background: linear-gradient(90deg, #22b07a, var(--agree)); border-radius: 999px; box-shadow: 0 0 12px rgba(61, 220, 151, 0.5); }
.split-bar .d { background: linear-gradient(90deg, var(--disagree), #ff8fa6); border-radius: 999px; box-shadow: 0 0 12px rgba(255, 107, 139, 0.45); }
.split-legend { display: flex; justify-content: space-between; font-size: 13px; margin-top: 8px; font-weight: 600; }
.split-legend .a { color: var(--agree); }
.split-legend .d { color: var(--disagree); }
.take-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 14px; gap: 8px; }

/* ---------- take-twin / opposite ---------- */
.matches { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 12px; }
.match { display: grid; gap: 12px; align-content: start; }
.match.twin { border-color: rgba(61, 220, 151, 0.28); }
.match.opposite { border-color: rgba(255, 107, 139, 0.28); }
.match-label { font: 600 10.5px/1 var(--sans); letter-spacing: 0.2em; text-transform: uppercase; color: var(--accent-soft); }
.match.twin .match-label { color: var(--agree); }
.match.opposite .match-label { color: var(--disagree); }
.match-who { display: grid; grid-template-columns: 46px 1fr auto; gap: 12px; align-items: center; }
.match-who .em {
  display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%;
  font-size: 24px; line-height: 1; background: rgba(255, 255, 255, 0.06); border: 1px solid var(--line-strong);
}
.match-who b { font: 600 18px var(--sans); letter-spacing: -0.01em; }
.match-pct { font: 400 34px/1 var(--serif); }
.match.twin .match-pct { color: var(--agree); }
.match.opposite .match-pct { color: var(--disagree); }
.match .share-btn { justify-self: start; }
.match-empty { font-size: 15px; color: var(--muted); }
.match-empty b { color: var(--ink); }

/* ---------- coffee roulette ---------- */
.coffee-card { display: grid; gap: 12px; }
.coffee-in { border-color: rgba(61, 220, 151, 0.3); }
.coffee-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.share-btn.big { flex: 1 1 210px; justify-content: center; padding: 15px 18px; font-size: 15px; }
.share-btn.big::before { width: 20px; height: 20px; }
.date-tile { text-align: right; line-height: 1; }
.date-tile b { display: block; font: 400 42px/0.9 var(--serif); color: var(--ink); }
.date-tile span { font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted); }
.card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
hr.soft { border: 0; border-top: 1px dashed var(--line-strong); margin: 4px 0; width: 100%; }
.starters { background: rgba(4, 9, 28, 0.45); border: 1px solid var(--line); border-radius: 16px; padding: 12px 14px; }
.starters ul { margin: 8px 0 0; padding-left: 18px; display: grid; gap: 6px; font-size: 14px; color: #cfd8f5; }
.starters li::marker { color: var(--accent); }
.met-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
label.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: #cfd8f5; }
label.check input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--accent); flex: none; }

/* ---------- estimate ---------- */
.q { font: 500 22px/1.28 var(--sans); letter-spacing: -0.02em; }
.hint { font-size: 14px; color: var(--muted); margin-top: 8px; }
label.field { display: grid; gap: 7px; font-size: 13px; font-weight: 600; color: #cfd8f5; letter-spacing: 0.01em; }
input[type=text], input[type=password], input[type=search], textarea {
  width: 100%; border: 1px solid var(--line-strong); background: var(--field); border-radius: 14px;
  padding: 13px 14px; outline: none; font-size: 16px; color: var(--ink); font-weight: 400;
  transition: border-color 0.15s, box-shadow 0.15s;
  -webkit-appearance: none; appearance: none;
}
input::placeholder, textarea::placeholder { color: var(--faint); }
input:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(92, 141, 255, 0.18); }
textarea { resize: vertical; min-height: 78px; }
.parse-preview { font-size: 13px; color: var(--muted); min-height: 18px; }
.parse-preview.bad { color: var(--disagree); }
.your-guess {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 14px; border-radius: 16px; background: rgba(4, 9, 28, 0.45); border: 1px solid var(--line);
  font-size: 14px; color: var(--muted);
}
.your-guess b { font: 400 26px/1 var(--serif); color: var(--ink); }

.strip { width: 100%; height: auto; display: block; overflow: visible; }
.strip .axis { stroke: var(--line-strong); stroke-width: 1.5; }
.strip .tick { fill: var(--faint); font-size: 11px; font-family: var(--sans); }
.strip .answer-line { stroke: var(--accent); stroke-width: 2; stroke-dasharray: 4 3; filter: drop-shadow(0 0 4px rgba(92, 141, 255, 0.8)); }
.strip .answer-label { fill: var(--accent-soft); font-size: 11px; font-weight: 600; font-family: var(--sans); }
.strip .me-ring { fill: none; stroke: #fff; stroke-width: 1.5; }
.strip .dot { fill: var(--accent-soft); opacity: 0.45; }
.strip .dot.me { fill: #fff; opacity: 1; stroke: var(--accent); stroke-width: 2.5; }
.me-key { color: #fff; }

details.more summary {
  cursor: pointer; font-size: 14px; font-weight: 600; color: var(--muted); padding: 6px 2px; list-style: none;
}
details.more summary::-webkit-details-marker { display: none; }
details.more summary::before { content: "+ "; color: var(--accent); }
details.more[open] summary::before { content: "– "; }
details.more .reasons { margin-top: 8px; }

.reasons { display: grid; gap: 8px; }
.reason {
  display: grid; grid-template-columns: 30px 1fr; gap: 10px; align-items: start;
  padding: 11px 12px; border-radius: 16px; background: rgba(4, 9, 28, 0.4); border: 1px solid var(--line);
  font-size: 14px; color: #cfd8f5;
}
.reason .who { font-weight: 600; color: var(--ink); }
.reason .em { font-size: 22px; line-height: 1; }

/* ---------- reveal ---------- */
.reveal-answer {
  font: 400 52px/0.95 var(--serif); letter-spacing: -0.01em; color: #fff;
  text-shadow: 0 0 40px rgba(92, 141, 255, 0.55);
}
.rank { display: grid; gap: 6px; }
.rank-row {
  display: grid; grid-template-columns: 26px 28px 1fr auto; gap: 8px; align-items: center;
  padding: 10px 12px; border-radius: 14px; background: rgba(4, 9, 28, 0.4); border: 1px solid var(--line); font-size: 14px;
}
.rank-row.me { border-color: var(--accent); box-shadow: 0 0 20px -8px rgba(92, 141, 255, 0.7); }
.rank-row .pos { font-weight: 700; color: var(--muted); text-align: center; }
.rank-row .pts { font: 400 19px var(--serif); }

/* ---------- cohort ---------- */
.members { display: grid; grid-template-columns: repeat(auto-fill, minmax(156px, 1fr)); gap: 10px; }
.member { display: grid; gap: 6px; align-content: start; padding: 16px; }
.member.me { border-color: var(--accent); box-shadow: 0 0 30px -12px rgba(92, 141, 255, 0.8); cursor: pointer; }
.member .avatar {
  display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%;
  font-size: 26px; line-height: 1; background: rgba(255, 255, 255, 0.06); border: 1px solid var(--line-strong); margin-bottom: 4px;
}
.member .name { font: 600 17px var(--sans); letter-spacing: -0.01em; }
.member .role { font-size: 13px; color: var(--muted); }
.member .fact { font-size: 14px; color: #cfd8f5; }
.badges { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 4px; }
.badge {
  font-size: 11px; font-weight: 600; padding: 4px 9px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.05); border: 1px solid var(--line); color: #cfd8f5;
}
.match-badge {
  border-color: rgba(61, 220, 151, 0.35);
  background: rgba(61, 220, 151, calc(var(--p) * 0.0018));
  color: #b9f5da;
}

.squad-card { display: grid; gap: 10px; }
.squad-title { display: flex; align-items: center; gap: 10px; }
.squad-title span { font-size: 30px; }
.squad-title h2 { margin: 0; }
.squad-faces { display: flex; flex-wrap: wrap; gap: 0; padding-left: 8px; }
.squad-faces span {
  display: grid; place-items: center; width: 34px; height: 34px; margin-left: -8px; border-radius: 50%;
  font-size: 18px; background: #16224d; border: 2px solid #0b1535;
}
.squad-faces .idle { filter: grayscale(1); opacity: 0.45; }
.squad-card .share-btn { justify-self: start; }

.wall-tools { display: grid; gap: 10px; }
.chips {
  display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none;
  margin: 0 -16px; padding: 0 16px;
}
.chips::-webkit-scrollbar { display: none; }
.chips button, .tabs-inline button {
  flex: none; border: 1px solid var(--line-strong); background: rgba(255, 255, 255, 0.03); border-radius: 999px;
  padding: 8px 13px; font-size: 13px; font-weight: 600; white-space: nowrap; color: var(--ink);
}
.chips button.on, .tabs-inline button.on { background: #fff; color: #0a1433; border-color: #fff; }

/* ---------- board ---------- */
.tabs-inline { display: flex; gap: 6px; margin-bottom: 12px; }
.board-row {
  display: grid; grid-template-columns: 30px 36px 1fr auto; gap: 10px; align-items: center;
  padding: 12px; border-bottom: 1px solid var(--line);
}
.board-row:last-child { border-bottom: 0; }
.board-row.me { background: rgba(92, 141, 255, 0.12); border-radius: 16px; }
.board-row .pos { font: 400 22px var(--serif); text-align: center; color: var(--muted); }
.board-row .em { font-size: 26px; }
.board-row .pts { font: 400 24px var(--serif); text-align: right; }
.board-row .sub { font-size: 12px; color: var(--muted); font-family: var(--sans); }
.board-gap { text-align: center; color: var(--faint); padding: 2px 0; }
.mini-bar { height: 4px; border-radius: 999px; background: rgba(255, 255, 255, 0.07); margin-top: 6px; overflow: hidden; max-width: 140px; }
.mini-bar i { display: block; height: 100%; background: linear-gradient(90deg, #22b07a, var(--agree)); border-radius: 999px; }

/* ---------- welcome ---------- */
.hero { display: grid; gap: 16px; padding: 18px 2px 4px; }
.hero .kicker { justify-self: start; margin-bottom: 0; }
.hero-logo { height: 52px; width: auto; justify-self: start; margin-bottom: 6px; filter: drop-shadow(0 0 24px rgba(92, 141, 255, 0.35)); }
.footnote { text-align: center; font-size: 12px; color: var(--faint); padding: 0 24px; margin-top: -10px; }
.hero h1 { font-size: clamp(42px, 12vw, 62px); line-height: 0.98; margin: 0; letter-spacing: -0.035em; }
.hero h1 em {
  font-size: 1.08em;
  background: linear-gradient(90deg, #b9cbff 0%, #6a97ff 70%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  padding-right: 0.06em;
}
.hero .lede { color: #b4c0e6; font-size: 17px; line-height: 1.5; max-width: 30em; }
.joined { display: grid; gap: 10px; margin-top: 6px; }
.joined-row { display: flex; align-items: center; gap: 12px; }
.faces { display: flex; padding-left: 10px; }
.faces span {
  display: grid; place-items: center; width: 38px; height: 38px; margin-left: -10px; border-radius: 50%;
  font-size: 20px; background: #16224d; border: 2px solid #0a1433; box-shadow: 0 0 0 1px var(--line-strong);
}
.joined-row b { font-weight: 600; font-size: 16px; }
.progress-meta { display: flex; justify-content: space-between; font-size: 14px; }
.progress-meta .num { color: var(--gold); font-weight: 600; }
.progress-meta .left { font-size: 12px; letter-spacing: 0.14em; color: var(--accent-soft); font-weight: 600; }
.progress { height: 6px; border-radius: 999px; background: rgba(255, 255, 255, 0.08); overflow: hidden; }
.progress i {
  display: block; height: 100%; border-radius: 999px;
  background: linear-gradient(90deg, #3b67f5, #8fb0ff); box-shadow: 0 0 14px rgba(92, 141, 255, 0.8);
}
.how { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 4px; }
.how div {
  background: var(--glass-flat); border: 1px solid var(--line); border-radius: 18px;
  padding: 12px 12px 14px; font-size: 13px; color: #cfd8f5; line-height: 1.3;
}
.how b { display: block; font: 400 26px/1 var(--serif); color: var(--accent-soft); margin-bottom: 8px; }

.emoji-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 6px; }
.emoji-grid button {
  aspect-ratio: 1; border: 1px solid var(--line); border-radius: 50%; background: rgba(255, 255, 255, 0.04); font-size: 20px; padding: 0;
  transition: transform 0.1s;
}
.emoji-grid button.on { border-color: var(--accent); background: rgba(92, 141, 255, 0.2); box-shadow: 0 0 16px -2px rgba(92, 141, 255, 0.7); transform: scale(1.06); }

/* Join / Log in segmented control */
.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; border-radius: 999px; background: rgba(4, 9, 28, 0.55); border: 1px solid var(--line); }
.seg button { border: 0; background: transparent; border-radius: 999px; padding: 11px; font-weight: 600; font-size: 15px; color: var(--muted); }
.seg button.on { background: #fff; color: #0a1433; box-shadow: 0 6px 18px -8px rgba(255, 255, 255, 0.5); }
.pw { position: relative; }
.pw input { padding-right: 64px; }
.pw-toggle {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  border: 0; background: none; font-size: 13px; font-weight: 600; color: var(--accent-soft); padding: 6px;
}

/* ---------- sheet ---------- */
dialog {
  border: 1px solid var(--line-strong); border-bottom: 0; padding: 0; width: min(560px, 100vw); max-height: 92vh;
  margin: auto auto 0; border-radius: 28px 28px 0 0;
  background: linear-gradient(180deg, #111d47 0%, #0a1433 100%); color: var(--ink);
  box-shadow: 0 -20px 60px -10px rgba(40, 80, 220, 0.35);
}
dialog::backdrop { background: rgba(2, 5, 15, 0.72); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
dialog .sheet-body { padding: 22px 18px calc(22px + env(safe-area-inset-bottom)); display: grid; gap: 14px; }
dialog .sheet-head { display: flex; justify-content: space-between; align-items: center; }
dialog .sheet-head h2 { margin: 0; }
dialog .close {
  border: 1px solid var(--line-strong); background: rgba(255, 255, 255, 0.05); border-radius: 999px;
  width: 36px; height: 36px; font-size: 15px; color: var(--ink);
}

/* ---------- bottom tabs: floating glass pill ---------- */
.tabs {
  position: fixed; z-index: 6; left: 50%; transform: translateX(-50%);
  bottom: calc(12px + env(safe-area-inset-bottom));
  width: min(400px, calc(100% - 24px));
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 6px;
  background: rgba(8, 15, 40, 0.72);
  border: 1px solid var(--line); border-radius: 999px;
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  backdrop-filter: blur(18px) saturate(140%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 16px 40px -12px rgba(0, 0, 0, 0.8);
}
.tabs a {
  display: flex; align-items: center; justify-content: center; gap: 6px; padding: 11px 0; border-radius: 999px;
  text-decoration: none; font-size: 14px; font-weight: 600; color: var(--muted);
  transition: background 0.15s, color 0.15s;
}
.tabs a span { font-size: 16px; filter: grayscale(1); opacity: 0.6; }
.tabs a.on {
  color: #fff; background: linear-gradient(180deg, rgba(106, 151, 255, 0.35), rgba(59, 103, 245, 0.3));
  box-shadow: inset 0 0 0 1px rgba(150, 180, 255, 0.4), 0 0 24px -6px rgba(59, 103, 245, 0.8);
}
.tabs a.on span { filter: none; opacity: 1; }

.toast {
  position: fixed; left: 50%; bottom: calc(92px + env(safe-area-inset-bottom)); transform: translate(-50%, 20px);
  background: #fff; color: #0a1433; padding: 11px 18px; border-radius: 999px; font-size: 14px; font-weight: 600;
  box-shadow: 0 12px 30px -10px rgba(0, 0, 0, 0.7);
  opacity: 0; pointer-events: none; transition: opacity 0.2s, transform 0.2s; max-width: calc(100vw - 32px); z-index: 10;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.empty { text-align: center; padding: 30px 16px; color: var(--muted); }
.empty b { display: block; font: 400 40px var(--serif); color: var(--accent-soft); margin-bottom: 6px; }

@media (prefers-reduced-motion: reduce) { *, *::before { transition: none !important; animation: none !important; } }
