body:not(.in-app) .dev { display: none; }
:root {
  --bg: #0b0820;
  --bg2: #120d33;
  --card: rgba(255, 255, 255, 0.06);
  --card-line: rgba(255, 255, 255, 0.12);
  --text: #f3f1ff;
  --muted: #a9a3d6;
  --violet: #8b5cf6;
  --pink: #ec4899;
  --cyan: #22d3ee;
  --lime: #a3e635;
  --amber: #fbbf24;
  --red: #f87171;
  --grad: linear-gradient(90deg, var(--violet), var(--pink) 50%, var(--cyan));
  --radius: 20px;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: "Space Grotesk", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
.mono { font-family: "JetBrains Mono", ui-monospace, Menlo, monospace; }
.bg-grid {
  position: fixed; inset: 0; z-index: -2;
  background-image: linear-gradient(rgba(139,92,246,.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(139,92,246,.08) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: radial-gradient(ellipse at 50% 0%, #000 30%, transparent 75%);
}
.bg-glow {
  position: fixed; inset: -20% -20% auto; height: 70vh; z-index: -1;
  background: radial-gradient(circle at 20% 30%, rgba(236,72,153,.35), transparent 40%),
    radial-gradient(circle at 80% 20%, rgba(34,211,238,.3), transparent 40%),
    radial-gradient(circle at 50% 60%, rgba(139,92,246,.35), transparent 50%);
  filter: blur(40px);
  animation: drift 14s ease-in-out infinite alternate;
}
@keyframes drift { to { transform: translate3d(0, 4vh, 0) scale(1.08); } }

.screen { max-width: 560px; margin: 0 auto; padding: 16px 16px 110px; }
.screen.center { min-height: 100vh; display: grid; place-items: center; padding-bottom: 16px; }
.card {
  background: var(--card);
  border: 1px solid var(--card-line);
  border-radius: var(--radius);
  padding: 20px;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  margin-bottom: 14px;
}
.hero { text-align: center; width: 100%; }
h1 { font-size: clamp(28px, 7vw, 40px); line-height: 1.05; margin: 12px 0 8px; letter-spacing: -0.02em; }
h2 { font-size: 22px; margin: 4px 0 6px; letter-spacing: -0.01em; }
h3.section-title { font-size: 14px; text-transform: uppercase; letter-spacing: .14em; color: var(--muted); margin: 22px 4px 10px; }
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.muted { color: var(--muted); }
.tiny { font-size: 13px; }
.kicker { font-size: 12px; text-transform: uppercase; letter-spacing: .16em; color: var(--cyan); margin: 0; font-weight: 700; }
.row { display: flex; align-items: center; }
.between { justify-content: space-between; }
.gap { gap: 10px; }
.stack { display: grid; gap: 12px; margin-top: 16px; text-align: left; }
.label { display: grid; gap: 6px; font-size: 14px; color: var(--muted); }

input, textarea {
  width: 100%; font: inherit; color: var(--text);
  background: rgba(0,0,0,.3); border: 1px solid var(--card-line);
  border-radius: 14px; padding: 13px 14px; outline: none;
  transition: border-color .2s, box-shadow .2s;
}
input:focus, textarea:focus { border-color: var(--violet); box-shadow: 0 0 0 4px rgba(139,92,246,.25); }
input[type=range] { padding: 0; height: 28px; accent-color: var(--pink); background: none; border: 0; box-shadow: none; }

.btn {
  font: inherit; font-weight: 700; border: 0; cursor: pointer; color: var(--text);
  border-radius: 14px; padding: 14px 18px; transition: transform .12s, filter .2s, box-shadow .2s;
}
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn-primary { background: var(--grad); box-shadow: 0 10px 30px -10px rgba(236,72,153,.7); }
.btn-primary:hover { filter: brightness(1.1); }
.btn-ghost { background: transparent; border: 1px solid var(--card-line); width: 100%; margin-top: 10px; }
.btn-power {
  width: 72px; height: 72px; border-radius: 50%; font-size: 22px; flex: none;
  background: radial-gradient(circle at 30% 30%, #d9f99d, var(--lime) 45%, #65a30d);
  color: #1a2e05; box-shadow: 0 0 0 6px rgba(163,230,53,.15), 0 0 30px rgba(163,230,53,.5);
  animation: pulse 2.2s ease-in-out infinite;
}
@keyframes pulse { 50% { box-shadow: 0 0 0 12px rgba(163,230,53,.05), 0 0 40px rgba(163,230,53,.7); } }

.logo-mark {
  width: 84px; height: 84px; margin: 0 auto; border-radius: 26px; display: grid; place-items: center;
  background: var(--grad); box-shadow: 0 20px 50px -15px rgba(139,92,246,.9);
  transform: rotate(-8deg); animation: float 4s ease-in-out infinite;
}
.logo-mark span { font-family: "JetBrains Mono", monospace; font-weight: 700; font-size: 24px; transform: rotate(8deg); }
@keyframes float { 50% { transform: rotate(-4deg) translateY(-6px); } }

/* Top bar */
.topbar { position: sticky; top: 0; z-index: 5; display: flex; justify-content: space-between; align-items: center;
  padding: 10px 0 14px; background: linear-gradient(var(--bg) 70%, transparent); }
.player { display: flex; gap: 12px; align-items: center; }
.avatar { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; font-weight: 700; font-size: 20px;
  background: var(--grad); box-shadow: 0 0 20px rgba(139,92,246,.6); }
.player-name { font-weight: 700; font-size: 17px; }
.tier-chip { display: inline-block; margin-top: 3px; font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  padding: 3px 8px; border-radius: 999px; background: rgba(34,211,238,.15); color: var(--cyan); border: 1px solid rgba(34,211,238,.4); }
.credits { display: flex; align-items: center; gap: 8px; cursor: pointer; font: inherit; color: var(--text);
  background: rgba(0,0,0,.35); border: 1px solid rgba(251,191,36,.45); border-radius: 999px; padding: 8px 14px;
  box-shadow: 0 0 20px rgba(251,191,36,.2); }
.credits #credits { font-size: 18px; color: var(--amber); }
.credits.bump { animation: bump .5s; }
@keyframes bump { 40% { transform: scale(1.18); box-shadow: 0 0 40px rgba(251,191,36,.7); } }
.credit-gem { width: 16px; height: 16px; transform: rotate(45deg); border-radius: 4px;
  background: linear-gradient(135deg, #fde68a, var(--amber) 50%, #d97706); box-shadow: 0 0 10px var(--amber); }

/* XP */
.xp-bar { height: 14px; border-radius: 999px; background: rgba(0,0,0,.4); overflow: hidden; margin: 12px 0 8px; border: 1px solid var(--card-line); }
.xp-fill { height: 100%; width: 0; border-radius: 999px; background: var(--grad); box-shadow: 0 0 16px rgba(236,72,153,.7);
  transition: width 1s cubic-bezier(.2,.9,.3,1.2); }
.power-card { display: flex; justify-content: space-between; align-items: center; gap: 14px;
  background: linear-gradient(135deg, rgba(163,230,53,.12), rgba(34,211,238,.08)); border-color: rgba(163,230,53,.3); }

/* Missions */
.missions { display: grid; gap: 10px; }
.mission { display: flex; gap: 14px; align-items: center; padding: 14px 16px; border-radius: 16px;
  background: var(--card); border: 1px solid var(--card-line); }
.mission .orb { width: 38px; height: 38px; border-radius: 12px; flex: none; display: grid; place-items: center; font-weight: 700;
  font-family: "JetBrains Mono", monospace; background: rgba(139,92,246,.2); border: 1px solid rgba(139,92,246,.5); color: #c4b5fd; }
.mission.done .orb { background: rgba(163,230,53,.2); border-color: var(--lime); color: var(--lime); }
.mission.done { border-color: rgba(163,230,53,.35); }
.mission .m-title { font-weight: 700; }
.mission .m-sub { font-size: 13px; color: var(--muted); }
.mission .m-bar { height: 6px; border-radius: 99px; background: rgba(0,0,0,.4); margin-top: 6px; overflow: hidden; }
.mission .m-bar div { height: 100%; background: var(--grad); }

/* Squad meter */
.squad { display: grid; grid-template-columns: repeat(10, 1fr); gap: 6px; }
.slot { aspect-ratio: 1; border-radius: 8px; background: rgba(255,255,255,.05); border: 1px dashed var(--card-line); }
.slot.on { border: 0; background: linear-gradient(135deg, var(--violet), var(--pink)); box-shadow: 0 0 10px rgba(139,92,246,.6);
  animation: pop .3s backwards; }
@keyframes pop { from { transform: scale(.3); opacity: 0; } }
.cost-line { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; border-radius: 14px;
  background: rgba(0,0,0,.3); font-weight: 700; }
.cost-line #cost { font-size: 22px; }
.btn-launch.go { animation: liftoff .9s cubic-bezier(.5,0,.5,1); }
@keyframes liftoff { 30% { transform: translateY(4px) scale(.97); } 100% { transform: translateY(-14px); filter: brightness(1.5); } }

/* Lists */
.list { display: grid; gap: 10px; }
.item { padding: 16px; border-radius: 16px; background: var(--card); border: 1px solid var(--card-line); }
.item .i-top { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.item .i-name { font-weight: 700; font-size: 17px; }
.item .i-sub { color: var(--muted); font-size: 13px; margin-top: 4px; word-break: break-word; }
.pill { font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 99px; text-transform: uppercase; letter-spacing: .08em; white-space: nowrap; }
.pill.open { background: rgba(163,230,53,.15); color: var(--lime); }
.pill.soon { background: rgba(251,191,36,.15); color: var(--amber); }
.amount { font-family: "JetBrains Mono", monospace; font-weight: 700; }
.amount.plus { color: var(--lime); }
.amount.minus { color: var(--pink); }
.empty { text-align: center; color: var(--muted); padding: 26px 10px; border: 1px dashed var(--card-line); border-radius: 16px; }

/* Tab bar */
.tabbar { position: fixed; left: 50%; bottom: 14px; transform: translateX(-50%); z-index: 10;
  width: min(528px, calc(100% - 32px)); display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
  padding: 6px; border-radius: 22px; background: rgba(18,13,51,.8); border: 1px solid var(--card-line);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); box-shadow: 0 20px 40px -10px rgba(0,0,0,.6); }
.tabbar button { font: inherit; font-size: 12px; font-weight: 700; color: var(--muted); background: none; border: 0;
  padding: 8px 4px; border-radius: 16px; cursor: pointer; display: grid; justify-items: center; gap: 4px; }
.tabbar button.active { color: var(--text); background: rgba(139,92,246,.25); }
.ico { width: 20px; height: 20px; border-radius: 6px; border: 2px solid currentColor; display: block; }
.ico-hq { border-radius: 50%; }
.ico-launch { border-radius: 50% 50% 4px 4px; }
.ico-arena { transform: rotate(45deg) scale(.85); }
.ico-log { border-radius: 3px; border-width: 2px 2px 6px; }
.tabbar button.active .ico { border-color: var(--pink); box-shadow: 0 0 10px var(--pink); }

/* Modal, toast, burst */
.modal { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; padding: 16px; background: rgba(5,3,15,.75); }
.modal-card { width: min(420px, 100%); text-align: center; }
.fake-ad { margin: 16px 0; height: 170px; border-radius: 16px; display: grid; place-items: center; align-content: center; gap: 14px;
  background: repeating-linear-gradient(45deg, rgba(255,255,255,.04) 0 12px, rgba(255,255,255,.08) 12px 24px); color: var(--muted); font-weight: 700; }
.ad-progress { width: 70%; height: 8px; border-radius: 99px; background: rgba(0,0,0,.4); overflow: hidden; }
.ad-progress div { height: 100%; width: 0; background: var(--lime); }
.toast { position: fixed; left: 50%; top: 18px; transform: translateX(-50%); z-index: 30; max-width: calc(100% - 32px);
  padding: 12px 18px; border-radius: 14px; font-weight: 700; background: #1d1645; border: 1px solid var(--violet);
  box-shadow: 0 10px 30px rgba(0,0,0,.5); animation: drop .3s; }
.toast.bad { border-color: var(--red); }
@keyframes drop { from { transform: translate(-50%, -20px); opacity: 0; } }
.burst { position: fixed; inset: 0; pointer-events: none; z-index: 25; }
.spark { position: absolute; width: 8px; height: 8px; border-radius: 2px; animation: spark .9s ease-out forwards; }
@keyframes spark { to { transform: translate(var(--dx), var(--dy)) rotate(260deg); opacity: 0; } }
.legal { text-align: center; padding: 0 16px 100px; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* Bonus round */
.bonus-card { background: linear-gradient(135deg, rgba(251,191,36,.14), rgba(236,72,153,.12)); border-color: rgba(251,191,36,.35); }
.kicker-amber { color: var(--amber); }
.bonus-dots { display: flex; gap: 6px; }
.bonus-dots span { width: 14px; height: 14px; border-radius: 50%; border: 2px solid rgba(251,191,36,.6); }
.bonus-dots span.on { background: var(--amber); box-shadow: 0 0 10px var(--amber); }
.btn-bonus { width: 100%; margin-top: 12px; color: #2a1600;
  background: linear-gradient(90deg, #fde68a, var(--amber), #fb923c); box-shadow: 0 10px 30px -10px rgba(251,191,36,.8); }

[hidden] { display: none !important; }

.slot.on:nth-child(3n+2) { background: linear-gradient(135deg, var(--pink), var(--cyan)); }
.slot.on:nth-child(3n) { background: linear-gradient(135deg, var(--cyan), var(--violet)); }

/* Step 3: joining */
.seats { display: flex; gap: 3px; margin-top: 10px; }
.seats span { flex: 1; height: 6px; border-radius: 99px; background: rgba(255,255,255,.1); }
.seats span.on { background: linear-gradient(90deg, var(--violet), var(--cyan)); box-shadow: 0 0 6px rgba(34,211,238,.5); }
.i-actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.btn-sm { padding: 9px 14px; font-size: 14px; border-radius: 12px; }
.btn-join { background: linear-gradient(90deg, var(--lime), #4ade80); color: #0f2a05; }
.btn-out { background: transparent; border: 1px solid var(--card-line); color: var(--muted); }
.btn-ok { background: rgba(163,230,53,.18); color: var(--lime); border: 1px solid rgba(163,230,53,.5); }
.btn-no { background: rgba(248,113,113,.12); color: var(--red); border: 1px solid rgba(248,113,113,.45); }
.pill.mine { background: rgba(139,92,246,.2); color: #c4b5fd; }
.pill.wait { background: rgba(251,191,36,.15); color: var(--amber); }
.pill.live { background: rgba(34,211,238,.15); color: var(--cyan); }
.pill.done { background: rgba(163,230,53,.15); color: var(--lime); }
.pill.gone { background: rgba(255,255,255,.08); color: var(--muted); }
.days { display: grid; grid-template-columns: repeat(14, 1fr); gap: 4px; margin-top: 12px; }
.days span { aspect-ratio: 1; border-radius: 6px; background: rgba(255,255,255,.07); display: grid; place-items: center;
  font: 700 10px "JetBrains Mono", monospace; color: var(--muted); }
.days span.on { background: linear-gradient(135deg, var(--violet), var(--pink)); color: #fff; box-shadow: 0 0 8px rgba(236,72,153,.5); }
.days span.today { outline: 2px solid var(--cyan); outline-offset: 1px; }
.tester-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 0;
  border-top: 1px solid var(--card-line); flex-wrap: wrap; }
.tester-row .mono { font-size: 12px; color: var(--muted); word-break: break-all; }
.join-card { text-align: left; }
.join-steps { color: var(--muted); padding-left: 20px; margin: 10px 0 14px; display: grid; gap: 6px; font-size: 14px; }
.join-card input { margin-bottom: 6px; }
.join-card .btn-ghost { width: auto; margin-top: 0; }
a.btn { text-decoration: none; display: inline-block; }

/* Step 4: check-ins */
.cps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 12px; }
.cp { border-radius: 14px; padding: 10px; text-align: center; border: 1px solid var(--card-line); background: rgba(0,0,0,.25); }
.cp b { display: block; font-size: 13px; }
.cp span { font: 700 12px "JetBrains Mono", monospace; color: var(--muted); }
.cp.done { border-color: rgba(163,230,53,.5); background: rgba(163,230,53,.1); }
.cp.done span { color: var(--lime); }
.cp.ready { border-color: var(--amber); background: rgba(251,191,36,.12); box-shadow: 0 0 16px rgba(251,191,36,.3); animation: glow 1.8s ease-in-out infinite; }
.cp.ready span { color: var(--amber); }
@keyframes glow { 50% { box-shadow: 0 0 26px rgba(251,191,36,.55); } }
.btn-checkin { background: linear-gradient(90deg, #fde68a, var(--amber), #fb923c); color: #2a1600; }
.btn-dev { background: transparent; border: 1px dashed rgba(255,255,255,.25); color: var(--muted); font-size: 12px; }
.check { display: flex; gap: 10px; align-items: center; font-size: 14px; margin: 12px 0; color: var(--text); }
.check input { width: 20px; height: 20px; accent-color: var(--lime); flex: none; }
.fb { margin-top: 12px; padding: 12px; border-radius: 12px; background: rgba(0,0,0,.25); border-left: 3px solid var(--cyan); }
.fb .fb-top { font-size: 12px; color: var(--muted); display: flex; justify-content: space-between; gap: 8px; }
.fb p { margin: 6px 0 0; white-space: pre-wrap; word-break: break-word; }
.finish-banner { margin-top: 12px; padding: 12px; border-radius: 12px; text-align: center; font-weight: 700;
  background: linear-gradient(90deg, rgba(163,230,53,.2), rgba(34,211,238,.2)); color: var(--lime); }

/* Dev, the credit buddy */
.dev { position: fixed; right: 4px; bottom: 84px; z-index: 15; width: 150px; pointer-events: none; }
.dev-body { pointer-events: auto; width: 150px; height: 150px; padding: 0; border: 0; background: none; cursor: pointer;
  display: block; transform-origin: 50% 100%; animation: dev-bob 2.6s ease-in-out infinite; }
.dev-pose { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 8px 14px rgba(0,0,0,.5)); }
.dev.has-art .dev-standin { display: none; }
@keyframes dev-bob { 50% { transform: translateY(-5px) rotate(-2deg); } }
.dev.hop .dev-body { animation: dev-hop .5s; }
@keyframes dev-hop { 40% { transform: translateY(-22px) scale(1.05, .95); } }
.dev.giving .dev-body { animation: dev-give 1.7s ease-in-out; }
@keyframes dev-give { 25%, 70% { transform: translateY(-8px) scale(1.04); } }
.dev.cheering .dev-body { animation: dev-cheer .4s 4; }
@keyframes dev-cheer { 50% { transform: translateY(-16px); } }
.dev.shake .dev-body { animation: dev-shake .45s; }
@keyframes dev-shake { 25% { transform: rotate(-8deg); } 75% { transform: rotate(8deg); } }
.dev-bubble { position: absolute; right: 8px; bottom: 150px; width: min(250px, calc(100vw - 40px)); pointer-events: auto;
  padding: 12px 14px; border-radius: 16px 16px 4px 16px; font-size: 14px; font-weight: 500; line-height: 1.35;
  background: #fff; color: #1b1240; box-shadow: 0 10px 30px rgba(0,0,0,.45), 0 0 0 2px rgba(139,92,246,.5); }
.dev-bubble.pop { animation: bubble .35s cubic-bezier(.3,1.6,.5,1); }
@keyframes bubble { from { transform: scale(.4) translateY(20px); opacity: 0; } }
/* Temporary stand-in until the ChatGPT pictures are saved in web/art/ */
.dev-standin { width: 100%; height: 100%; position: relative; }
.dev-monitors { position: absolute; top: 8px; left: 4px; right: 4px; display: flex; gap: 4px; justify-content: center; }
.dev-monitors i { width: 30px; height: 24px; border-radius: 4px; background: #0e2a3a; border: 2px solid var(--cyan);
  box-shadow: 0 0 10px rgba(34,211,238,.6); background-image: repeating-linear-gradient(transparent 0 4px, rgba(163,230,53,.6) 4px 6px);
  animation: code 1.2s steps(4) infinite; }
.dev-monitors i:nth-child(2) { transform: translateY(-6px); border-color: var(--pink); animation-delay: .3s; }
@keyframes code { to { background-position: 0 -24px; } }
.dev-guy { position: absolute; left: 34px; top: 36px; width: 48px; height: 52px; border-radius: 22px 22px 14px 14px;
  background: linear-gradient(160deg, #7c3aed, #5b21b6); border: 3px solid var(--pink); display: grid; place-items: center; }
.dev[data-pose="type2"] .dev-guy { transform: translateY(-2px) rotate(-3deg); }
.dev-face { font: 700 13px "JetBrains Mono", monospace; color: #fff; }
.dev-desk { position: absolute; left: 6px; right: 6px; bottom: 16px; height: 10px; border-radius: 4px; background: #3b2a70; border: 2px solid #6d28d9; }
.dev-label { position: absolute; bottom: 0; left: 0; right: 0; text-align: center; font-size: 11px; font-weight: 700; letter-spacing: .12em; color: var(--cyan); }
.fly-gem { position: fixed; z-index: 40; width: 14px; height: 14px; margin: -7px; border-radius: 3px; pointer-events: none;
  background: linear-gradient(135deg, #fde68a, var(--amber) 50%, #d97706); box-shadow: 0 0 12px var(--amber); }
@media (prefers-reduced-motion: reduce) { .fly-gem { display: none; } }
.dev.calendaring .dev-body { animation: dev-look 2.4s ease-in-out; }
@keyframes dev-look { 15%, 85% { transform: rotate(-6deg) translateX(-4px); } 50% { transform: rotate(-6deg) translateX(-4px) translateY(-6px); } }
.dev-cal { position: absolute; left: 2px; top: 40px; width: 26px; height: 28px; border-radius: 4px; background: #fff;
  border-top: 6px solid var(--red); display: grid; place-items: center; font: 700 11px "JetBrains Mono", monospace; color: #1b1240;
  background-image: repeating-conic-gradient(#111 0 25%, #fff 0 50%); background-size: 6px 6px; background-position: 0 100%; background-repeat: repeat-x; }
.dev-cal b { background: #fff; padding: 0 2px; border-radius: 2px; }
.dev.calendaring .dev-cal { animation: cal-glow 2.4s; }
@keyframes cal-glow { 30%, 70% { box-shadow: 0 0 14px var(--amber); transform: scale(1.15); } }
/* Happy small jump dance when someone joins */
.dev.dancing .dev-body { animation: dev-dance 1.7s ease-in-out; }
@keyframes dev-dance {
  0% { transform: none; }
  12% { transform: translateY(-16px) rotate(-8deg); } 22% { transform: translateY(0) scale(1.06, .94); }
  34% { transform: translateY(-16px) rotate(8deg); } 44% { transform: translateY(0) scale(1.06, .94); }
  56% { transform: translateY(-20px) rotate(-6deg); } 66% { transform: translateY(0) scale(1.06, .94); }
  78% { transform: translateY(-10px) rotate(360deg); } 100% { transform: none; } }

/* Characters */
.char-grid { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 8px; max-height: 300px; overflow-y: auto;
  padding: 4px; border-radius: 14px; background: rgba(0,0,0,.25); }
.char-opt { aspect-ratio: 1; border-radius: 14px; border: 2px solid transparent; background: rgba(255,255,255,.05);
  padding: 4px; cursor: pointer; display: grid; place-items: center; transition: transform .12s; }
.char-opt img { width: 100%; height: 100%; object-fit: contain; }
.char-opt:hover { transform: scale(1.06); }
.char-opt.on { border-color: var(--cyan); background: rgba(34,211,238,.15); box-shadow: 0 0 14px rgba(34,211,238,.5); }
.char-name { text-align: center; font-weight: 700; color: var(--cyan); min-height: 1.3em; }
.char-card { text-align: left; } .char-card .char-grid { max-height: 52vh; margin: 12px 0; }
.char-card .btn-ghost { width: auto; margin-top: 0; }
button.avatar { border: 0; padding: 0; cursor: pointer; color: var(--text); font: inherit; font-weight: 700; font-size: 20px; overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: contain; background: rgba(255,255,255,.08); }
.mini-av { width: 26px; height: 26px; border-radius: 8px; vertical-align: middle; margin-right: 6px; object-fit: contain;
  background: rgba(255,255,255,.08); }

/* Hall of Fame and sponsoring */
.hof { padding: 10px 14px; }
.hof-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--card-line); }
.hof-row:last-child { border-bottom: 0; }
.hof-rank { width: 24px; text-align: center; font: 700 15px "JetBrains Mono", monospace; color: var(--muted); }
.hof-row:nth-child(1) .hof-rank { color: var(--amber); } .hof-row:nth-child(2) .hof-rank { color: #cbd5e1; } .hof-row:nth-child(3) .hof-rank { color: #fb923c; }
.hof-av { width: 40px; height: 40px; border-radius: 12px; object-fit: contain; background: rgba(255,255,255,.08); flex: none; }
.hof-name { font-weight: 700; } .hof-sub { font-size: 12px; color: var(--muted); }
.badge { display: inline-block; font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: 2px 7px;
  border-radius: 99px; margin-left: 4px; vertical-align: middle; }
.badge.sponsor { background: rgba(251,191,36,.18); color: var(--amber); }
.badge.tier { background: rgba(34,211,238,.15); color: var(--cyan); }
.btn-sponsor { background: rgba(251,191,36,.14); color: var(--amber); border: 1px solid rgba(251,191,36,.5); }
.pools { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; }
.pool { padding: 10px; border-radius: 12px; background: rgba(0,0,0,.25); font-size: 12px; color: var(--muted); }
.pool b { display: block; font: 700 20px "JetBrains Mono", monospace; color: var(--text); }

/* Step 6 */
#summary-text { font: 12px/1.45 "JetBrains Mono", monospace; }
.btn-summary { background: rgba(34,211,238,.14); color: var(--cyan); border: 1px solid rgba(34,211,238,.5); }
.fb-help { margin-top: 8px; font-size: 12px; padding: 5px 10px; border-radius: 10px; cursor: pointer; font-weight: 700;
  background: transparent; color: var(--muted); border: 1px solid var(--card-line); }
.fb-help.on { color: var(--lime); border-color: rgba(163,230,53,.6); background: rgba(163,230,53,.12); }
.legal a { color: var(--muted); }

/* ---- Nov 23 round ---- */
/* Dev tucks away into a small circle so he never covers cards */
.dev-tuck { position: absolute; right: 2px; bottom: 132px; z-index: 2; pointer-events: auto; width: 26px; height: 26px;
  border-radius: 50%; border: 1px solid rgba(255,255,255,.35); background: rgba(11,8,32,.9); color: #fff;
  font: 700 16px/1 "Space Grotesk", sans-serif; cursor: pointer; display: grid; place-items: center; }
.dev.tucked { width: 58px; }
.dev.tucked .dev-tuck { display: none; }
.dev.tucked .dev-body { width: 58px; height: 58px; border-radius: 50%; overflow: hidden; animation: none;
  background: rgba(11,8,32,.92); border: 2px solid var(--cyan); box-shadow: 0 6px 18px rgba(0,0,0,.45); }
.dev.tucked .dev-pose { filter: none; }
.dev.tucked .dev-standin { transform: scale(.38); transform-origin: 0 0; width: 150px; height: 150px; }
.dev.tucked .dev-bubble { bottom: 64px; }

/* Ads today counter */
.ads-today { margin: 4px 0 0; color: var(--cyan); font-family: "JetBrains Mono", monospace; }
.ads-today.full { color: var(--amber, #fbbf24); }
.btn:disabled { opacity: .45; cursor: not-allowed; filter: grayscale(.4); }

/* Your to-do */
.todo { display: flex; align-items: center; gap: 10px; justify-content: space-between; padding: 12px 14px;
  border-radius: 14px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); font-size: 14px; }
.todo.urgent { border-color: rgba(34,211,238,.55); background: rgba(34,211,238,.08); }
.todo > span { flex: 1; min-width: 0; }
.todo .btn { flex: none; width: auto; white-space: nowrap; }

/* T4T-style question box */
.box-card { text-align: left; }
.box-text { white-space: pre-line; font-size: 14px; }
.btn-danger { background: linear-gradient(135deg, #f87171, #ec4899); box-shadow: 0 10px 30px -10px rgba(248,113,113,.7); }
#box-modal { z-index: 30; }

.push-card { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.push-card .btn { flex: none; width: auto; white-space: nowrap; }

.boost-line { background: rgba(163,230,53,.10); border: 1px solid rgba(163,230,53,.4); color: var(--lime); margin-bottom: 8px; }

/* Arena search and filters (round 5) */
.filters { display: grid; gap: 8px; margin-bottom: 10px; }
.filters .row > select { flex: 1; min-width: 0; }
select { width: 100%; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--card-line); background: rgba(255,255,255,.04);
  color: inherit; font: inherit; }
select option { background: #15102e; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 4px; }
.tag { font-size: 11px; padding: 3px 8px; border-radius: 999px; background: rgba(139,92,246,.16); border: 1px solid rgba(139,92,246,.4); }
.tag.hot { background: rgba(251,191,36,.14); border-color: rgba(251,191,36,.5); color: var(--amber); }

/* Round 5: bell, badges, invite, messages, notices */
.topbar { gap: 8px; }
.bell { position: relative; margin-left: auto; width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--card-line);
  background: rgba(255,255,255,.04); cursor: pointer; display: grid; place-items: center; }
.bell-ico { width: 16px; height: 16px; border: 2px solid var(--cyan); border-radius: 8px 8px 3px 3px; border-bottom-width: 3px; position: relative; }
.bell-ico::after { content: ""; position: absolute; left: 50%; bottom: -6px; width: 5px; height: 3px; margin-left: -2.5px; border-radius: 0 0 3px 3px; background: var(--cyan); }
.bell-n { position: absolute; top: -5px; right: -5px; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 9px; background: var(--pink, #ec4899);
  color: #fff; font: 700 11px/18px "JetBrains Mono", monospace; }
.badges { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.badge-pill { display: grid; padding: 8px 12px; border-radius: 12px; background: rgba(251,191,36,.10); border: 1px solid rgba(251,191,36,.45); font-size: 12px; }
.badge-pill b { color: var(--amber); font-size: 13px; }
.badge-pill span { color: var(--muted); }
.invite-card { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.invite-card .btn { flex: none; width: auto; white-space: nowrap; }
.btn-ghost-sm { background: transparent; border: 1px solid var(--card-line); color: inherit; }
.pkg { font-size: 12px; opacity: .8; }
.msg-list { max-height: 45vh; overflow-y: auto; display: grid; gap: 8px; margin: 10px 0; text-align: left; }
.msg { padding: 10px 12px; border-radius: 14px; background: rgba(255,255,255,.05); border: 1px solid var(--card-line); max-width: 85%; }
.msg.mine { justify-self: end; background: rgba(139,92,246,.18); border-color: rgba(139,92,246,.45); }
.msg-who { font-size: 11px; color: var(--muted); margin-bottom: 4px; }
.msg-body { white-space: pre-wrap; word-break: break-word; font-size: 14px; }
.msg-report { margin-top: 6px; background: none; border: 0; padding: 0; color: var(--muted); font-size: 11px; text-decoration: underline; cursor: pointer; }
.notice-list { max-height: 55vh; overflow-y: auto; text-align: left; margin: 10px 0; }
.notice.unread { border-color: rgba(34,211,238,.55); }

/* Round 6: safety */
#box-select { margin-bottom: 8px; }
.msg-actions { justify-content: flex-end; margin-top: 6px; }
.msg-actions .btn { width: auto; }
.account-card { margin-top: 14px; }
.ico-review { border-radius: 50%; }
.tabbar button[hidden] { display: none !important; }

/* New logo (Patricia chose Dev with the 14-day calendar, Nov 23) */
.logo-img { display: block; width: 128px; height: 128px; margin: 0 auto 6px; object-fit: contain; filter: drop-shadow(0 10px 24px rgba(251,191,36,.25)); animation: dev-bob 3s ease-in-out infinite; }

/* Nov 23: Dev is now just the small character with the calendar (Patricia's logo), smaller,
   with no desk or computers. The same picture is used for every mood; his moves show the mood. */
.dev { width: 96px; right: 6px; }
.dev-body { width: 96px; height: 96px; }
.dev-pose { filter: drop-shadow(0 6px 10px rgba(0,0,0,.45)); }
.dev-bubble { bottom: 98px; }
.dev-tuck { bottom: 84px; right: -2px; }
.dev.tucked { width: 58px; }

.brand-name { margin: 0 0 4px; font: 700 20px/1.1 "Space Grotesk", sans-serif; letter-spacing: .02em; color: var(--amber); }
