:root {
  --bg: #07080d;
  --panel: #10121b;
  --panel2: #161925;
  --line: rgba(255, 255, 255, .08);
  --line2: rgba(255, 255, 255, .14);
  --text: #eef1f7;
  --muted: #8d94a8;
  --gold: #ffc94d;
  --good: #22c55e;
  --bad: #f43f5e;
  --radius: 18px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  --display: 'Bebas Neue', Impact, 'Arial Narrow Bold', sans-serif;
  --quote: 'Playfair Display', Georgia, 'Times New Roman', serif;
  color-scheme: dark;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--text); }
body {
  font: 15px/1.45 Inter, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  min-height: 100vh; min-height: 100dvh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
#bg {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(60vmax 40vmax at 10% -10%, rgba(123, 108, 255, .18), transparent 60%),
    radial-gradient(50vmax 40vmax at 110% 10%, rgba(255, 79, 123, .12), transparent 60%),
    radial-gradient(60vmax 50vmax at 50% 120%, rgba(53, 208, 255, .10), transparent 60%),
    var(--bg);
}
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 800; letter-spacing: -.01em; }
.display { font-family: var(--display); letter-spacing: .04em; font-weight: 400; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.tiny { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; font-weight: 700; }
.row { display: flex; align-items: center; gap: 10px; }
.between { justify-content: space-between; }
.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.center { text-align: center; }
.hidden { display: none !important; }

#app {
  max-width: 760px; margin: 0 auto;
  padding: calc(18px + var(--safe-t)) 16px calc(96px + var(--safe-b));
}
.boot { display: grid; place-items: center; height: 70vh; }
.boot-ring { width: 54px; height: 54px; border-radius: 50%; border: 4px solid var(--line2); border-top-color: var(--gold); animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Tabs ---------- */
#tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  display: flex; justify-content: space-around;
  padding: 8px 6px calc(8px + var(--safe-b));
  background: rgba(10, 11, 18, .86);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  border-top: 1px solid var(--line);
}
#tabs a {
  flex: 1; max-width: 120px; text-decoration: none; text-align: center;
  font-size: 11px; font-weight: 600; color: var(--muted); padding: 4px 0;
  border-radius: 12px; transition: color .2s;
}
#tabs a span { display: block; font-size: 21px; line-height: 1.15; filter: grayscale(1) opacity(.65); transition: filter .2s, transform .2s; }
#tabs a.on { color: var(--text); }
#tabs a.on span { filter: none; transform: translateY(-2px) scale(1.08); }

/* ---------- Common pieces ---------- */
.top { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.top h1 { font-family: var(--display); font-weight: 400; font-size: 40px; letter-spacing: .03em; line-height: .95; }
.top .sub { color: var(--muted); font-size: 13px; margin-top: 4px; }
.section { margin: 26px 0 12px; display: flex; align-items: center; justify-content: space-between; }
.section h2 { font-family: var(--display); font-weight: 400; font-size: 24px; letter-spacing: .05em; }
.card {
  background: linear-gradient(180deg, rgba(255,255,255,.03), rgba(255,255,255,.01)), var(--panel);
  border: 1px solid var(--line); border-radius: var(--radius); padding: 16px;
}
.card + .card { margin-top: 10px; }
.btn {
  appearance: none; border: 1px solid var(--line2); background: var(--panel2);
  color: var(--text); border-radius: 14px; padding: 12px 16px; font-weight: 700;
  cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  transition: transform .12s, background .2s, border-color .2s, opacity .2s;
  text-decoration: none; min-height: 46px;
}
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .5; }
.btn.primary { background: linear-gradient(135deg, #ffd66b, #ff9f1c); color: #1b1203; border-color: transparent; box-shadow: 0 8px 30px rgba(255, 170, 40, .25); }
.btn.good { background: linear-gradient(135deg, #34d399, #16a34a); color: #04190d; border-color: transparent; }
.btn.ghost { background: transparent; }
.btn.danger { color: #ff8da1; border-color: rgba(244, 63, 94, .35); background: rgba(244, 63, 94, .08); }
.btn.block { width: 100%; }
.btn.sm { padding: 7px 12px; min-height: 36px; font-size: 13px; border-radius: 11px; }
.icon-btn { appearance: none; background: var(--panel2); border: 1px solid var(--line); width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; cursor: pointer; font-size: 18px; }
.chip { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; padding: 4px 9px; border-radius: 999px; background: rgba(255,255,255,.06); border: 1px solid var(--line); white-space: nowrap; }
.pill-badge { background: var(--bad); color: #fff; font-size: 12px; font-weight: 800; min-width: 22px; height: 22px; border-radius: 11px; display: inline-grid; place-items: center; padding: 0 6px; }
.empty { text-align: center; padding: 26px 14px; color: var(--muted); border: 1px dashed var(--line2); border-radius: var(--radius); }

label.field { display: block; margin: 0 0 14px; }
label.field > span { display: block; font-size: 12px; font-weight: 700; color: var(--muted); margin-bottom: 6px; letter-spacing: .03em; }
input[type=text], input[type=password], input[type=number], input[type=time], select, textarea {
  width: 100%; background: #0b0d14; border: 1px solid var(--line2); border-radius: 12px;
  padding: 12px 13px; outline: none; font-size: 16px; transition: border-color .2s, box-shadow .2s;
}
input:focus, select:focus, textarea:focus { border-color: rgba(255, 201, 77, .6); box-shadow: 0 0 0 3px rgba(255, 201, 77, .15); }
input[type=color] { width: 46px; height: 46px; border: 1px solid var(--line2); border-radius: 12px; background: #0b0d14; padding: 4px; }
.seg { display: flex; background: #0b0d14; border: 1px solid var(--line2); border-radius: 13px; padding: 3px; gap: 3px; flex-wrap: wrap; }
.seg button { flex: 1; appearance: none; border: 0; background: transparent; border-radius: 10px; padding: 9px 8px; font-weight: 700; font-size: 13px; color: var(--muted); cursor: pointer; min-width: 60px; }
.seg button.on { background: var(--panel2); color: var(--text); box-shadow: inset 0 0 0 1px var(--line2); }
.daypick { display: flex; gap: 6px; }
.daypick button { flex: 1; appearance: none; aspect-ratio: 1; max-width: 46px; border-radius: 50%; border: 1px solid var(--line2); background: #0b0d14; font-weight: 800; font-size: 13px; cursor: pointer; color: var(--muted); }
.daypick button.on { background: var(--gold); color: #1b1203; border-color: transparent; }
.err { color: #ff8da1; font-size: 13px; margin: 8px 0 0; min-height: 1em; }

/* ---------- Hero meters ---------- */
.hero-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 620px) { .hero-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.hero {
  --c1: #38bdf8; --c2: #0b1640;
  position: relative; overflow: hidden; border-radius: 22px; padding: 14px 12px 12px;
  background: radial-gradient(120% 90% at 50% 0%, color-mix(in srgb, var(--c1) 28%, transparent), transparent 65%), linear-gradient(160deg, color-mix(in srgb, var(--c2) 85%, #000), #08090f 85%);
  border: 1px solid color-mix(in srgb, var(--c1) 30%, transparent);
  text-align: center; cursor: pointer; text-decoration: none; display: block;
  transition: transform .15s;
  isolation: isolate;
}
.hero:active { transform: scale(.97); }
.hero::after {
  content: ''; position: absolute; inset: -40%; z-index: -1;
  background: conic-gradient(from 0deg, transparent 0 70%, color-mix(in srgb, var(--c1) 22%, transparent) 80%, transparent 90%);
  animation: sweep 7s linear infinite; opacity: .6;
}
@keyframes sweep { to { transform: rotate(360deg); } }
.hero .meter-name { font-family: var(--display); font-size: 19px; letter-spacing: .05em; line-height: 1; margin-top: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hero .rank { font-size: 12px; font-weight: 700; color: color-mix(in srgb, var(--c1) 70%, white); margin-top: 3px; min-height: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hero .power { margin-top: 9px; }
.ring { position: relative; width: 100%; max-width: 150px; margin: 0 auto; aspect-ratio: 1; }
.ring > svg { width: 100%; height: 100%; transform: rotate(135deg); overflow: visible; }
.ring .track { stroke: rgba(255,255,255,.08); }
.ring .fill { filter: drop-shadow(0 0 6px var(--c1)); transition: stroke-dashoffset 1.2s cubic-bezier(.2,.9,.2,1); }
.ring .mid { position: absolute; inset: 0; display: grid; place-items: center; align-content: center; }
.ring .emoji { font-size: 40px; line-height: 1; filter: drop-shadow(0 4px 12px rgba(0,0,0,.6)); animation: bob 4s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-4px); } }
.ring .lvl { font-family: var(--display); font-size: 18px; letter-spacing: .08em; margin-top: 4px; color: #fff; }
.ring .lvl b { font-size: 26px; font-weight: 400; color: var(--c1); }
.bar { height: 8px; border-radius: 8px; background: rgba(255,255,255,.08); overflow: hidden; position: relative; }
.bar > i { position: absolute; inset: 0 auto 0 0; border-radius: 8px; background: linear-gradient(90deg, var(--c2, #333), var(--c1)); box-shadow: 0 0 12px var(--c1); transition: width 1.2s cubic-bezier(.2,.9,.2,1); }
.bar.thin { height: 5px; }
.power-label { display: flex; justify-content: space-between; font-size: 10px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.fuel { font-size: 11px; color: var(--muted); margin-top: 7px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.hero-big { padding: 22px 18px; cursor: default; }
.hero-big .ring { max-width: 230px; }
.hero-big .ring .emoji { font-size: 70px; }
.hero-big .ring .lvl { font-size: 24px; }
.hero-big .ring .lvl b { font-size: 36px; }
.hero-big .meter-name { font-size: 36px; }
.hero-big .tagline { font-family: var(--quote); font-style: italic; color: color-mix(in srgb, var(--c1) 50%, white); margin-top: 4px; }
.ladder { list-style: none; margin: 0; padding: 0; }
.ladder li { display: flex; align-items: center; gap: 12px; padding: 10px 4px; border-bottom: 1px solid var(--line); }
.ladder li:last-child { border-bottom: 0; }
.ladder .lv { font-family: var(--display); font-size: 18px; width: 48px; color: var(--muted); }
.ladder li.got .lv { color: var(--c1, var(--gold)); }
.ladder li.got .name { font-weight: 700; }
.ladder li.now { background: rgba(255,255,255,.04); border-radius: 12px; }
.ladder li.locked { opacity: .45; }

.mix-row { display: grid; grid-template-columns: 34px 1fr 54px; align-items: center; gap: 10px; padding: 8px 0; }
.mix-row input[type=range] { width: 100%; accent-color: var(--gold); }
.mix-row .pct { text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; }

/* ---------- Today ---------- */
.quote-card { position: relative; padding: 18px 18px 16px 18px; overflow: hidden; }
.quote-card .q { font-family: var(--quote); font-style: italic; font-size: 18px; line-height: 1.4; }
.quote-card .who { margin-top: 8px; font-size: 13px; color: var(--muted); }
.quote-card .theme { position: absolute; top: 14px; right: 14px; }
.checkin-cta {
  display: flex; align-items: center; gap: 14px; width: 100%; text-align: left;
  border-radius: 20px; padding: 16px; margin-top: 12px; cursor: pointer; border: 0;
  background: linear-gradient(120deg, #ffcf5a, #ff7a1a 60%, #ff3d6e); color: #180c02;
  box-shadow: 0 14px 40px rgba(255, 120, 30, .28);
  position: relative; overflow: hidden;
}
.checkin-cta::after { content: ''; position: absolute; top: 0; bottom: 0; width: 60px; left: -80px; background: rgba(255,255,255,.35); transform: skewX(-20deg); animation: shine 3.6s ease-in-out infinite; }
@keyframes shine { 0%, 60% { left: -80px; } 100% { left: 110%; } }
.checkin-cta .big { font-family: var(--display); font-size: 28px; letter-spacing: .04em; line-height: 1; }
.checkin-cta .ico { font-size: 34px; }

.goal {
  display: flex; align-items: center; gap: 12px; padding: 12px 12px 12px 14px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 16px; margin-bottom: 8px;
  position: relative; overflow: hidden;
}
.goal::before { content: ''; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; background: var(--cc, var(--gold)); }
.goal .t { font-weight: 700; }
.goal .meta { font-size: 12px; color: var(--muted); display: flex; gap: 8px; flex-wrap: wrap; margin-top: 2px; }
.goal.done .t { color: var(--muted); text-decoration: line-through; text-decoration-color: rgba(255,255,255,.25); }
.check {
  appearance: none; flex: none; width: 44px; height: 44px; border-radius: 50%;
  border: 2px solid var(--cc, var(--line2)); background: transparent; cursor: pointer;
  display: grid; place-items: center; font-size: 20px; transition: transform .15s, background .25s;
}
.check:active { transform: scale(.88); }
.goal.done .check { background: var(--cc, var(--good)); border-color: transparent; color: #fff; }
.check .n { font-size: 12px; font-weight: 800; color: var(--muted); }
.cat-head { display: flex; align-items: center; gap: 8px; margin: 18px 0 8px; font-weight: 800; font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.cat-head i { font-style: normal; font-size: 16px; }
.streak { color: #ff9a3c; font-weight: 700; }

.stat-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 12px; }
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 12px; text-align: center; }
.stat b { display: block; font-family: var(--display); font-weight: 400; font-size: 30px; letter-spacing: .04em; line-height: 1; }
.stat span { font-size: 11px; color: var(--muted); font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }

/* ---------- Check-in ---------- */
.ci {
  position: fixed; inset: 0; z-index: 40; overflow-y: auto;
  background: radial-gradient(90vmax 70vmax at 50% -20%, rgba(255, 190, 80, .16), transparent 60%), #06070b;
  padding: calc(16px + var(--safe-t)) 20px calc(24px + var(--safe-b));
  display: flex; flex-direction: column;
}
.ci-top { display: flex; align-items: center; justify-content: space-between; }
.ci-dots { display: flex; gap: 5px; }
.ci-dots i { width: 22px; height: 4px; border-radius: 4px; background: rgba(255,255,255,.15); }
.ci-dots i.on { background: var(--gold); }
.ci-body { flex: 1; display: flex; flex-direction: column; justify-content: center; max-width: 560px; width: 100%; margin: 0 auto; padding: 20px 0; }
.ci .theme-tag { font-family: var(--display); letter-spacing: .3em; font-size: 15px; color: var(--gold); }
.ci blockquote { margin: 14px 0 0; font-family: var(--quote); font-style: italic; font-size: clamp(22px, 6vw, 32px); line-height: 1.32; }
.ci blockquote::before { content: '“'; display: block; font-size: 80px; line-height: .6; color: rgba(255, 201, 77, .5); margin-bottom: 8px; font-style: normal; }
.ci .who { margin-top: 14px; color: var(--muted); }
.ci .who b { color: var(--text); }
.ci .ask { margin-top: 34px; padding-top: 24px; border-top: 1px solid var(--line); }
.ci .ask-goal { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 700; color: var(--muted); }
.ci h2 { font-size: 26px; margin-top: 6px; line-height: 1.2; }
.ci .choices { display: grid; gap: 10px; margin-top: 18px; }
.ci .choices .btn { min-height: 56px; font-size: 16px; justify-content: flex-start; padding-left: 18px; }
.ci .say { font-size: 22px; font-weight: 700; line-height: 1.35; }
.ci .big-emoji { font-size: 72px; line-height: 1; margin-bottom: 14px; animation: pop .6s cubic-bezier(.2,1.6,.4,1); }
@keyframes pop { from { transform: scale(.2); opacity: 0; } }
.fade-in { animation: fadeUp .45s ease both; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } }
.xp-burst { font-family: var(--display); font-size: 64px; letter-spacing: .04em; color: var(--gold); text-shadow: 0 0 30px rgba(255, 201, 77, .6); animation: pop .6s cubic-bezier(.2,1.6,.4,1); line-height: 1; }
.mini-meters { display: grid; gap: 10px; margin-top: 22px; text-align: left; }
.mini-meter { --c1: #fff; --c2: #333; }
.mini-meter .row { font-size: 13px; font-weight: 700; margin-bottom: 4px; }

/* ---------- Sheets ---------- */
.sheet-bg { position: fixed; inset: 0; z-index: 50; background: rgba(0,0,0,.6); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); animation: fade .2s; display: flex; align-items: flex-end; justify-content: center; }
@keyframes fade { from { opacity: 0; } }
.sheet {
  width: 100%; max-width: 640px; max-height: 92vh; max-height: 92dvh; overflow-y: auto;
  background: #0e1018; border: 1px solid var(--line2); border-bottom: 0;
  border-radius: 24px 24px 0 0; padding: 10px 18px calc(22px + var(--safe-b));
  animation: up .28s cubic-bezier(.2,.9,.2,1);
}
@keyframes up { from { transform: translateY(40px); opacity: 0; } }
.sheet .grab { width: 40px; height: 5px; border-radius: 5px; background: var(--line2); margin: 0 auto 12px; }
.sheet h2 { font-family: var(--display); font-weight: 400; font-size: 30px; letter-spacing: .04em; margin-bottom: 14px; }
.sheet .actions { display: flex; gap: 10px; margin-top: 18px; }
.sheet .actions .btn { flex: 1; }

.gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 560px) { .gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.gal {
  --c1: #fff; --c2: #000;
  border-radius: 16px; padding: 14px 10px; text-align: center; cursor: pointer; border: 1px solid color-mix(in srgb, var(--c1) 30%, transparent);
  background: linear-gradient(160deg, color-mix(in srgb, var(--c2) 80%, #000), #08090f); position: relative;
}
.gal .e { font-size: 36px; }
.gal .n { font-weight: 800; margin-top: 6px; font-size: 14px; }
.gal .m { font-size: 11px; color: var(--muted); }
.gal.on { outline: 3px solid var(--c1); }
.gal.on::after { content: '✓'; position: absolute; top: 6px; right: 8px; background: var(--c1); color: #000; width: 22px; height: 22px; border-radius: 50%; font-weight: 900; font-size: 13px; display: grid; place-items: center; }
.gal.have { opacity: .45; }

/* ---------- Toasts, level up ---------- */
#toast-root { position: fixed; left: 0; right: 0; top: calc(12px + var(--safe-t)); z-index: 70; display: grid; justify-items: center; pointer-events: none; gap: 8px; }
.toast { background: rgba(20, 22, 32, .96); border: 1px solid var(--line2); padding: 10px 16px; border-radius: 14px; font-weight: 700; box-shadow: 0 10px 30px rgba(0,0,0,.4); animation: toastIn .3s cubic-bezier(.2,1.4,.4,1); max-width: 92vw; }
.toast.xp { background: linear-gradient(135deg, #ffd66b, #ff9f1c); color: #1b1203; border: 0; font-family: var(--display); font-size: 24px; letter-spacing: .05em; font-weight: 400; }
@keyframes toastIn { from { transform: translateY(-20px) scale(.9); opacity: 0; } }
#confetti { position: fixed; inset: 0; z-index: 90; pointer-events: none; width: 100%; height: 100%; }
.levelup {
  --c1: #ffc94d; --c2: #222;
  position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; text-align: center; padding: 24px;
  background: radial-gradient(70vmax 70vmax at 50% 40%, color-mix(in srgb, var(--c1) 35%, transparent), transparent 60%), rgba(4, 5, 9, .94);
  animation: fade .3s;
}
.levelup .rays { position: absolute; width: 160vmax; height: 160vmax; left: 50%; top: 40%; transform: translate(-50%, -50%); background: repeating-conic-gradient(from 0deg, color-mix(in srgb, var(--c1) 16%, transparent) 0 6deg, transparent 6deg 18deg); animation: spin 30s linear infinite; mask-image: radial-gradient(circle, #000 10%, transparent 55%); -webkit-mask-image: radial-gradient(circle, #000 10%, transparent 55%); }
.levelup .inner { position: relative; }
.levelup .e { font-size: 110px; animation: pop .8s cubic-bezier(.2,1.6,.4,1); filter: drop-shadow(0 10px 30px rgba(0,0,0,.6)); }
.levelup .lu { font-family: var(--display); font-size: clamp(56px, 16vw, 96px); line-height: .9; letter-spacing: .04em; color: var(--c1); text-shadow: 0 0 40px var(--c1); animation: pop .8s .1s cubic-bezier(.2,1.6,.4,1) both; }
.levelup .who { font-size: 18px; font-weight: 700; margin-top: 8px; }
.levelup .newrank { margin-top: 18px; display: inline-block; padding: 10px 18px; border-radius: 14px; border: 1px solid var(--c1); font-weight: 800; background: rgba(0,0,0,.35); animation: fadeUp .5s .5s both; }
.levelup .tap { margin-top: 30px; color: var(--muted); font-size: 13px; animation: fadeUp .5s 1s both; }

/* ---------- Progress ---------- */
.heat { display: grid; grid-auto-flow: column; grid-template-rows: repeat(7, 1fr); gap: 3px; overflow-x: auto; padding-bottom: 4px; }
.heat i { width: 14px; height: 14px; border-radius: 3px; background: rgba(255,255,255,.05); display: block; }
.cat-meter { display: grid; grid-template-columns: 36px 1fr auto; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); }
.cat-meter:last-child { border-bottom: 0; }
.cat-meter .e { font-size: 24px; text-align: center; }
.cat-meter .lv { font-family: var(--display); font-size: 22px; letter-spacing: .04em; }

/* ---------- Auth ---------- */
.auth { max-width: 400px; margin: 8vh auto 0; }
.auth .logo { width: 96px; height: 96px; border-radius: 24px; display: block; margin: 0 auto 16px; box-shadow: 0 20px 60px rgba(123, 108, 255, .3); }
.auth h1 { font-family: var(--display); font-weight: 400; font-size: 52px; letter-spacing: .04em; text-align: center; line-height: .9; }
.auth .tag { text-align: center; color: var(--muted); margin: 8px 0 24px; }

.list-item { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.list-item:last-child { border-bottom: 0; }
.swatch { width: 14px; height: 14px; border-radius: 50%; flex: none; }
.note { background: rgba(255, 201, 77, .08); border: 1px solid rgba(255, 201, 77, .25); border-radius: 14px; padding: 12px 14px; font-size: 14px; }
.note.bad { background: rgba(244, 63, 94, .08); border-color: rgba(244, 63, 94, .3); }
.copy-box { display: flex; gap: 8px; margin-top: 8px; }
.copy-box input { font-size: 13px; }
code { background: rgba(255,255,255,.08); padding: 1px 6px; border-radius: 6px; font-size: 13px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Custom hero art */
.hi { width: 1.1em; height: 1.1em; display: inline-block; vertical-align: -.2em; overflow: visible; }
.ring .emoji .hi, .levelup .e .hi, .gal .e .hi { width: 1.4em; height: 1.4em; filter: drop-shadow(0 4px 10px rgba(0,0,0,.5)); }
.hi-cycle { position: relative; display: inline-block; width: 1.1em; height: 1.1em; vertical-align: -.2em; }
.ring .emoji .hi-cycle, .levelup .e .hi-cycle, .gal .e .hi-cycle { width: 1.4em; height: 1.4em; }
.hi-cycle > span { position: absolute; inset: 0; opacity: 0; animation: artcycle 9s infinite; }
.hi-cycle > span .hi { width: 100%; height: 100%; vertical-align: top; }
@keyframes artcycle { 0% { opacity: 0; transform: scale(.85); } 4%, 30% { opacity: 1; transform: none; } 36%, 100% { opacity: 0; transform: scale(1.08); } }
.art-pick { font-size: 22px; }
@media (prefers-reduced-motion: reduce) { .hi-cycle > span:first-child { opacity: 1; } }

/* Evolving hero pictures */
.ring .emoji.max { filter: drop-shadow(0 0 10px var(--c1)) drop-shadow(0 0 22px var(--c1)); }
.evo { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px 6px; }
.evo-step { text-align: center; }
.evo-ic { font-size: 30px; height: 52px; display: grid; place-items: center; border-radius: 14px; background: rgba(255,255,255,.04); border: 1px solid var(--line); }
.evo-lv { font-family: var(--display); font-size: 14px; letter-spacing: .06em; color: var(--muted); margin-top: 4px; }
.evo-step.now .evo-ic { border-color: var(--c1); box-shadow: 0 0 18px color-mix(in srgb, var(--c1) 45%, transparent); background: color-mix(in srgb, var(--c1) 14%, transparent); }
.evo-step.now .evo-lv { color: var(--c1); }
.evo-step.locked .evo-ic > * { filter: brightness(0) opacity(.55); }
.evo-step.locked .evo-ic { background: rgba(0,0,0,.25); }
.levelup .evolve { display: flex; align-items: center; justify-content: center; gap: 14px; }
.levelup .evolve .old { font-size: 54px; opacity: .45; filter: grayscale(.6); animation: fadeUp .5s both; }
.levelup .evolve .arrow { font-size: 28px; color: var(--c1); animation: fadeUp .5s .2s both; }
.levelup .evolve .e { animation-delay: .35s; animation-fill-mode: both; }
.levelup .evolve .old .hi, .levelup .evolve .old .hi-cycle { width: 1.25em; height: 1.25em; }
.evo-ic > span { display: inline-block; line-height: 1; }

/* Sub-categories */
.cat-head.sub { margin: 10px 0 6px 14px; font-size: 12px; }
.sub-goals { margin-left: 14px; }
.goal.sub-cat { margin-left: 22px; padding-top: 9px; padding-bottom: 9px; }
.sub-add { margin: -2px 0 10px 22px; }
.sub-meter { display: flex; align-items: center; gap: 8px; font-size: 11px; color: var(--muted); margin-top: 6px; }
.sub-meter > span:first-child { width: 112px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.evo-step[data-act] { cursor: pointer; }
.evo-cap { grid-column: 1 / -1; margin: 6px 0 0; }

details.tune { margin-top: 14px; }
details.tune > summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 28px; }
details.tune > summary::-webkit-details-marker { display: none; }
details.tune > summary::after { content: '›'; font-size: 22px; color: var(--muted); transition: transform .2s; }
details.tune[open] > summary::after { transform: rotate(90deg); }
details.tune[open] > summary { margin-bottom: 10px; }
details.tune > summary .small { margin-left: auto; }
details.tune > summary b { white-space: nowrap; }
.times-row { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
.times-row input { width: 76px; text-align: center; font-size: 18px; font-weight: 800; }
.times-row span { color: var(--muted); font-size: 14px; }
.times-row b { color: var(--text); }
.mix-row { grid-template-columns: 44px 1fr 54px; }
.mix-row.off > div, .mix-row.off .pct { opacity: .4; }
.mix-pick { display: flex; align-items: center; gap: 4px; cursor: pointer; font-size: 20px; }
.mix-pick input { width: 18px; height: 18px; accent-color: var(--gold); margin: 0; }
.mix-total { display: flex; align-items: center; gap: 10px; margin-top: 10px; padding-top: 12px; border-top: 1px solid var(--line2); }
.mix-bar { flex: 1; height: 10px; border-radius: 10px; background: #0b0d14; overflow: hidden; }
.mix-bar i { display: block; height: 100%; width: 0; background: #f87171; border-radius: 10px; transition: width .2s; }
.mix-total.ok .mix-bar i { background: #4ade80; }
.mix-sum { font-variant-numeric: tabular-nums; min-width: 46px; text-align: right; color: #f87171; }
.mix-total.ok .mix-sum { color: #4ade80; }
.mix-hint { margin: 8px 0 0; color: #4ade80; }
.mix-hint.bad { color: #f87171; }
button[disabled].primary { opacity: .45; cursor: not-allowed; }
