/* ================================================================
   DOWNPOUR — design system
   Modern dark. One gold. Everything eased, nothing snaps.
   ================================================================ */
@font-face {
  font-family: "Baloo 2";
  src: url("fonts/baloo2.woff2") format("woff2");
  font-weight: 400 800;
  font-display: swap;
}

:root {
  --display: "Baloo 2", -apple-system, "Segoe UI", Roboto, sans-serif;
  --bg: #070b14;
  --bg-2: #0b1120;
  --surface: rgba(255, 255, 255, 0.045);
  --surface-2: rgba(255, 255, 255, 0.08);
  --stroke: rgba(255, 255, 255, 0.09);
  --ink: #eef2fa;
  --dim: #8b96ad;
  --faint: #55617a;
  --gold: #ffc23e;
  --gold-hot: #ffdd7a;
  --cyan: #57d7ff;
  --violet: #b18cff;
  --ember: #ff7a59;
  --danger: #ff5d6e;
  --green: #4ade80;
  --r-lg: 22px;
  --r-md: 16px;
  --r-sm: 12px;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --tab-h: 64px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
  height: 100%;
  overscroll-behavior: none;
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, "SF Pro Display", "Segoe UI Variable Display", "Segoe UI", Roboto, Inter, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  -webkit-user-select: none;
  touch-action: manipulation;
  overflow: hidden;
  position: fixed;
  inset: 0;
}

/* ---------- app frame ---------- */
#app {
  position: fixed;
  inset: 0;
  max-width: 520px;
  margin: 0 auto;
  overflow: hidden;
  background:
    radial-gradient(120% 60% at 50% -10%, #101a33 0%, transparent 60%),
    radial-gradient(90% 50% at 50% 115%, #0d1526 0%, transparent 55%),
    var(--bg);
}

.screen {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  padding: calc(env(safe-area-inset-top, 0px) + 18px) 20px calc(var(--tab-h) + env(safe-area-inset-bottom, 0px) + 14px);
  overflow-y: auto;
  overflow-x: hidden;
  opacity: 0;
  transform: translateY(14px) scale(0.995);
  pointer-events: none;
  transition: opacity 0.26s var(--ease), transform 0.26s var(--ease);
  scrollbar-width: none;
}
.screen::-webkit-scrollbar { display: none; }
.screen.active {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}
#screen-play { padding: 0; overflow: hidden; }

/* ---------- tab bar ---------- */
#tabbar {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: calc(var(--tab-h) + env(safe-area-inset-bottom, 0px));
  padding-bottom: env(safe-area-inset-bottom, 0px);
  display: flex;
  background: rgba(9, 13, 24, 0.82);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-top: 1px solid var(--stroke);
  z-index: 40;
  transition: transform 0.32s var(--ease), opacity 0.32s var(--ease);
}
#tabbar.hidden { transform: translateY(110%); opacity: 0; pointer-events: none; }
.tab {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  color: var(--faint);
  font-family: var(--display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.2s var(--ease);
}
.tab .ico {
  position: relative;
  display: flex; align-items: center; justify-content: center;
  width: 46px; height: 30px;
  border-radius: 999px;
  transition: background 0.25s var(--ease);
}
.tab.on .ico { background: rgba(255, 194, 62, 0.14); }
.tab svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform 0.25s var(--ease); }
.tab.on { color: var(--gold); }
.tab.on svg { transform: translateY(-1px) scale(1.08); fill: rgba(255,194,62,0.18); }
.tab:active svg { transform: scale(0.9); }

/* ---------- shared bits ---------- */
.h-eyebrow {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
}
.h1 {
  font-family: var(--display);
  font-size: 32px;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.05;
  margin: 6px 0 4px;
}
.sub { color: var(--dim); font-size: 14px; line-height: 1.45; }

.card {
  background: linear-gradient(180deg, rgba(255,255,255,0.065), rgba(255,255,255,0.03));
  border: 1px solid var(--stroke);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08), 0 10px 30px -18px rgba(0,0,0,0.8);
  border-radius: var(--r-lg);
  padding: 16px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 18px;
  font-family: var(--display);
  font-weight: 800;
  letter-spacing: 0.03em;
  cursor: pointer;
  color: var(--ink);
  background: linear-gradient(180deg, rgba(255,255,255,0.12), rgba(255,255,255,0.05));
  border: 1px solid var(--stroke);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.12), 0 4px 14px -6px rgba(0,0,0,0.6);
  padding: 14px 22px;
  font-size: 16px;
  transition: transform 0.16s var(--ease), filter 0.2s var(--ease), opacity 0.2s;
}
.btn:active { transform: scale(0.95); }
.btn.primary {
  background: linear-gradient(180deg, #ffe9a8, var(--gold-hot) 30%, var(--gold) 62%, #e39c15);
  color: #2c1f04;
  border: 0;
  text-shadow: 0 1px 0 rgba(255,255,255,0.4);
  box-shadow:
    0 10px 30px -6px rgba(255, 194, 62, 0.5),
    inset 0 2px 0 rgba(255,255,255,0.55),
    inset 0 -4px 0 rgba(146, 92, 8, 0.35);
}
.btn.primary:active { transform: scale(0.95); filter: brightness(1.07); }
.btn.ghost { background: transparent; border: 1px solid var(--stroke); color: var(--dim); box-shadow: none; }
.btn[disabled] { opacity: 0.4; pointer-events: none; }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: linear-gradient(180deg, rgba(255,255,255,0.09), rgba(255,255,255,0.03));
  border: 1px solid var(--stroke);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.1);
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 700;
  color: var(--dim);
}
.pill b { color: var(--ink); font-family: var(--display); font-weight: 800; font-size: 14px; }
.pill .orb-ico { width: 11px; height: 11px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, var(--gold-hot), var(--gold) 55%, #b97e12); box-shadow: 0 0 8px rgba(255,194,62,.7); }

/* ================================================================
   HOME
   ================================================================ */
#home-rain {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.9;
}
#screen-home { justify-content: flex-end; gap: 14px; }
.home-top {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  min-height: 220px;
}
.wordmark {
  font-family: var(--display);
  font-size: clamp(46px, 14vw, 62px);
  font-weight: 800;
  letter-spacing: 0;
  line-height: 0.92;
  background: linear-gradient(180deg, #fff 8%, var(--gold-hot) 45%, var(--gold) 72%, #d9962a);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 6px 30px rgba(255, 194, 62, 0.28));
}
.tagline {
  margin-top: 10px;
  color: var(--dim);
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.home-stats { display: flex; gap: 8px; justify-content: center; position: relative; }
.squad-row {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.squad-chip {
  width: 58px; height: 58px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--stroke);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.squad-chip canvas { width: 46px; height: 46px; }
.squad-edit {
  font-size: 12px; font-weight: 700; color: var(--cyan);
  padding: 8px 4px; cursor: pointer;
}
#btn-pour {
  position: relative;
  width: 100%;
  padding: 19px;
  font-size: 19px;
  letter-spacing: 0.14em;
  border-radius: 22px;
  animation: pourGlow 2.6s var(--ease) infinite;
}
@keyframes pourGlow {
  0%, 100% { box-shadow: 0 8px 28px -6px rgba(255,194,62,.4), inset 0 1px 0 rgba(255,255,255,.5); }
  50% { box-shadow: 0 10px 40px -4px rgba(255,194,62,.65), inset 0 1px 0 rgba(255,255,255,.5); }
}
.home-foot { text-align: center; color: var(--faint); font-size: 11px; font-weight: 600; letter-spacing: 0.08em; }

/* ================================================================
   HEROES
   ================================================================ */
.heroes-head { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 14px; }
.hero-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding-bottom: 90px; }
.hero-card {
  position: relative;
  background: linear-gradient(180deg, rgba(255,255,255,0.07), rgba(255,255,255,0.028));
  border: 1px solid var(--stroke);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.09), 0 12px 30px -18px rgba(0,0,0,0.9);
  border-radius: var(--r-lg);
  padding: 16px 12px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  cursor: pointer;
  overflow: hidden;
  transition: transform 0.18s var(--ease), border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.hero-card::before {
  content: "";
  position: absolute;
  top: -22px; left: 50%;
  width: 130px; height: 130px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(circle, var(--pg, #ffc23e) 0%, transparent 62%);
  opacity: 0.2;
  pointer-events: none;
}
.hero-card:active { transform: scale(0.965); }
.hero-card.picked {
  border-color: rgba(255, 194, 62, 0.65);
  box-shadow: 0 0 0 1px rgba(255,194,62,.4), 0 10px 30px -12px rgba(255,194,62,.35);
}
.hero-card.locked { opacity: 0.88; }
.hero-card .slot-badge {
  position: absolute;
  top: 8px; left: 8px;
  width: 22px; height: 22px;
  border-radius: 8px;
  background: linear-gradient(180deg, var(--gold-hot), var(--gold));
  color: #241a05;
  font-size: 12px; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 3px 10px rgba(255,194,62,.4);
}
.hero-face { width: 76px; height: 76px; }
.hero-card.locked .hero-face { filter: grayscale(1) brightness(0.5) contrast(0.9); }
.hero-name { font-family: var(--display); font-size: 18px; font-weight: 800; }
.hero-epithet { font-size: 10.5px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: var(--dim); margin-top: -5px; }
.hero-rule { font-size: 11.5px; line-height: 1.45; color: var(--dim); }
.hero-rule b { color: var(--ink); font-weight: 700; }
.hero-rule .k {
  display: inline-block;
  font-weight: 800; letter-spacing: 0.1em; font-size: 9px;
  padding: 1.5px 7px; border-radius: 7px; margin-right: 2px;
  vertical-align: 1px;
}
.k.fall { color: var(--cyan); background: rgba(87, 215, 255, 0.13); }
.k.fight { color: var(--ember); background: rgba(255, 122, 89, 0.13); }
.unlock-btn {
  margin-top: 4px;
  width: 100%;
  padding: 9px;
  font-size: 12.5px;
  border-radius: 12px;
}
.lv-badge {
  position: absolute;
  top: 8px; right: 8px;
  font-family: var(--display);
  font-size: 11px;
  font-weight: 800;
  color: var(--cyan);
  background: rgba(87, 215, 255, 0.12);
  border: 1px solid rgba(87, 215, 255, 0.3);
  border-radius: 8px;
  padding: 2px 7px;
}
.lv-power {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--gold);
  min-height: 13px;
}
.squad-bar {
  position: absolute;
  left: 16px; right: 16px;
  bottom: calc(var(--tab-h) + env(safe-area-inset-bottom, 0px) + 12px);
  background: rgba(14, 20, 36, 0.9);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--stroke);
  border-radius: 18px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 30;
  transition: transform 0.3s var(--ease), opacity 0.3s var(--ease);
}
.squad-bar .msg { font-size: 13px; font-weight: 700; color: var(--dim); }
.squad-bar .msg b { color: var(--gold); }

/* ================================================================
   DROPS
   ================================================================ */
.drop-card { margin-bottom: 12px; position: relative; overflow: hidden; }
.drop-card .drop-num {
  font-size: 11px; font-weight: 800; letter-spacing: 0.2em;
  color: var(--gold); text-transform: uppercase;
}
.drop-card h3 { font-family: var(--display); font-size: 20px; font-weight: 800; margin: 3px 0 2px; }
.drop-card .date { font-size: 12px; color: var(--faint); font-weight: 600; margin-bottom: 10px; }
.drop-card ul { list-style: none; }
.drop-card li {
  font-size: 13.5px; color: var(--dim); line-height: 1.5;
  padding-left: 18px; position: relative; margin-bottom: 6px;
}
.drop-card li::before {
  content: "";
  position: absolute; left: 2px; top: 7px;
  width: 7px; height: 7px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, var(--gold-hot), var(--gold));
  box-shadow: 0 0 6px rgba(255,194,62,.55);
}
.drop-card.roadmap { border-style: dashed; background: transparent; }
.drop-card.roadmap li::before { background: var(--faint); box-shadow: none; }

/* ================================================================
   PLAY — canvas + HUD
   ================================================================ */
#stage-wrap {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg);
}
#stage { touch-action: none; display: block; }

.hud {
  position: absolute;
  left: 0; right: 0;
  pointer-events: none;
  z-index: 20;
}
#hud-top {
  top: 0;
  padding: calc(env(safe-area-inset-top, 0px) + 12px) 16px 0;
  display: flex; align-items: center; justify-content: space-between;
}
#hud-top .pill { pointer-events: auto; background: rgba(9,13,24,.72); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
#orb-count { min-width: 86px; justify-content: center; transition: transform .12s var(--ease); }
#orb-count.bump { transform: scale(1.12); }
#btn-quit { pointer-events: auto; }

#pour-hint {
  position: absolute;
  left: 0; right: 0; top: 24%;
  text-align: center;
  font-size: 13px; font-weight: 800;
  letter-spacing: 0.24em; text-transform: uppercase;
  color: rgba(238, 242, 250, 0.85);
  text-shadow: 0 2px 14px rgba(0,0,0,.6);
  pointer-events: none;
  z-index: 20;
  opacity: 0;
  transition: opacity .4s var(--ease);
}
#pour-hint.show { opacity: 1; animation: hintFloat 1.8s ease-in-out infinite; }
@keyframes hintFloat { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }

/* the hero chips you tap to drop each faller */
#hero-queue {
  position: absolute;
  left: 0; right: 0;
  top: calc(env(safe-area-inset-top, 0px) + 62px);
  display: flex;
  justify-content: center;
  gap: 10px;
  z-index: 22;
  pointer-events: none;
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 0.28s var(--ease), transform 0.28s var(--ease);
}
#hero-queue.show { opacity: 1; transform: none; }
.hq-chip {
  pointer-events: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  width: 62px;
  padding: 7px 4px 5px;
  border-radius: 16px;
  background: rgba(9, 13, 24, 0.78);
  border: 1px solid rgba(255, 194, 62, 0.45);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.12), 0 6px 18px -8px rgba(0,0,0,0.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  cursor: pointer;
  transition: transform 0.18s var(--ease), opacity 0.25s var(--ease), border-color 0.25s;
  animation: chipPulse 2s var(--ease) infinite;
}
@keyframes chipPulse {
  0%, 100% { border-color: rgba(255, 194, 62, 0.45); }
  50% { border-color: rgba(255, 194, 62, 0.85); }
}
.hq-chip:active { transform: scale(0.9); }
.hq-chip canvas { width: 38px; height: 38px; }
.hq-chip span {
  font-family: var(--display);
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--gold);
  text-transform: uppercase;
}
.hq-chip.selected {
  border-color: var(--gold);
  transform: translateY(-3px) scale(1.06);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.15), 0 0 0 1.5px rgba(255,194,62,0.5), 0 10px 24px -8px rgba(255,194,62,0.45);
  animation: none;
}
.hq-chip.dropped {
  opacity: 0.28;
  transform: scale(0.86);
  pointer-events: none;
  animation: none;
  border-color: var(--stroke);
  box-shadow: none;
}
.hq-chip.dropped span { color: var(--faint); }

#hero-banner {
  position: absolute;
  left: 0; right: 0; top: 15%;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  z-index: 21;
  opacity: 0;
  transform: translateY(-10px) scale(.9);
  transition: opacity .22s var(--ease), transform .22s var(--ease);
  pointer-events: none;
}
#hero-banner.show { opacity: 1; transform: none; }
#hero-banner canvas { width: 40px; height: 40px; filter: drop-shadow(0 4px 12px rgba(0,0,0,.5)); }
#hero-banner span {
  font-size: 15px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase;
  color: #fff; text-shadow: 0 2px 16px rgba(0,0,0,.7);
}

#btn-speed {
  position: absolute;
  right: 14px;
  bottom: calc(env(safe-area-inset-bottom, 0px) + 16px);
  z-index: 22;
  pointer-events: auto;
  padding: 10px 16px;
  font-size: 13px;
  border-radius: 999px;
  background: rgba(9,13,24,.72);
  border: 1px solid var(--stroke);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: none;
}
#btn-speed.show { display: inline-flex; }
#btn-speed.on { color: var(--gold); border-color: rgba(255,194,62,.5); }

/* overlays inside play (shop / summary) */
.overlay {
  position: absolute; inset: 0;
  z-index: 30;
  display: flex; flex-direction: column;
  align-items: center; justify-content: flex-end;
  padding: 20px 18px calc(env(safe-area-inset-bottom, 0px) + 22px);
  background: linear-gradient(180deg, transparent 0%, rgba(5, 8, 15, 0.72) 34%, rgba(5, 8, 15, 0.94) 70%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s var(--ease);
}
.overlay.show { opacity: 1; pointer-events: auto; }
.overlay .panel {
  width: 100%;
  transform: translateY(26px);
  transition: transform 0.34s var(--ease);
}
.overlay.show .panel { transform: none; }

.shop-title { text-align: center; margin-bottom: 4px; }
.shop-sub { text-align: center; color: var(--dim); font-size: 13px; font-weight: 600; margin-bottom: 14px; }
.shop-cards { display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
.shop-card {
  position: relative;
  display: flex; align-items: center; gap: 13px;
  background: linear-gradient(180deg, rgba(255,255,255,0.075), rgba(255,255,255,0.03));
  border: 1px solid var(--stroke);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.09);
  border-radius: var(--r-md);
  padding: 13px 14px;
  cursor: pointer;
  overflow: hidden;
  transition: transform 0.15s var(--ease), border-color 0.2s, opacity 0.2s;
}
.shop-card:active { transform: scale(0.97); }
.shop-card.bought { border-color: rgba(74, 222, 128, 0.5); opacity: 0.6; pointer-events: none; }
.shop-card.bought::after {
  content: "SOLD";
  position: absolute;
  right: 12px; top: 50%;
  transform: translateY(-50%) rotate(-8deg);
  font-family: var(--display);
  font-weight: 800;
  font-size: 15px;
  letter-spacing: 0.14em;
  color: var(--green);
  border: 2px solid var(--green);
  border-radius: 8px;
  padding: 2px 8px;
  background: rgba(5, 8, 15, 0.6);
}
.shop-card.bought .shop-cost { visibility: hidden; }
.shop-card.cant { opacity: 0.42; }
.shop-ico {
  width: 44px; height: 44px; flex: none;
  border-radius: 13px;
  display: flex; align-items: center; justify-content: center;
  font-size: 21px;
  background: linear-gradient(180deg, rgba(255,255,255,0.14), rgba(255,255,255,0.05));
  border: 1px solid var(--stroke);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.15);
}
.shop-card .t { flex: 1; }
.shop-card .t b { display: block; font-family: var(--display); font-size: 15.5px; font-weight: 800; }
.shop-card .t span { font-size: 12px; color: var(--dim); }
.shop-cost { font-family: var(--display); font-size: 15px; font-weight: 800; color: var(--gold); white-space: nowrap; display: flex; align-items: center; gap: 5px; }
.shop-cost .orb-ico { width: 10px; height: 10px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, var(--gold-hot), var(--gold) 55%, #b97e12); }
.shop-actions { display: flex; gap: 10px; }
.shop-actions .btn { flex: 1; padding: 15px; }

.sum-hero { text-align: center; margin-bottom: 16px; }
.sum-big {
  font-family: var(--display);
  font-size: 58px; font-weight: 800; line-height: 1;
  background: linear-gradient(180deg, #fff, var(--gold-hot) 60%, var(--gold));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.sum-label { font-size: 12px; font-weight: 800; letter-spacing: 0.22em; text-transform: uppercase; color: var(--dim); margin-top: 6px; }
.sum-record { color: var(--gold); font-weight: 800; font-size: 13px; margin-top: 8px; letter-spacing: .06em; height: 18px; }
.sum-stats { display: flex; gap: 8px; margin-bottom: 12px; }
.sum-stat { flex: 1; text-align: center; padding: 12px 6px; }
.sum-stat b { display: block; font-family: var(--display); font-size: 23px; font-weight: 800; }
.sum-stat span { font-size: 10.5px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--dim); }
.sum-unlock {
  display: none;
  align-items: center; gap: 12px;
  border-color: rgba(255, 194, 62, 0.5);
  background: linear-gradient(180deg, rgba(255,194,62,.12), rgba(255,194,62,.04));
  margin-bottom: 12px;
  animation: unlockPop .5s var(--ease);
}
.sum-unlock.show { display: flex; }
@keyframes unlockPop { 0% { transform: scale(.85); opacity: 0; } 100% { transform: none; opacity: 1; } }
.sum-unlock canvas { width: 52px; height: 52px; }
.sum-unlock .t b { display: block; font-size: 15px; }
.sum-unlock .t span { font-size: 12px; color: var(--gold); font-weight: 700; }

/* wave intro flash */
#wave-flash {
  position: absolute;
  left: 0; right: 0; top: 38%;
  text-align: center;
  z-index: 25;
  pointer-events: none;
  opacity: 0;
}
#wave-flash .w1 { font-size: 13px; font-weight: 800; letter-spacing: 0.3em; text-transform: uppercase; color: var(--gold); }
#wave-flash .w2 { font-family: var(--display); font-size: 46px; font-weight: 800; text-shadow: 0 4px 30px rgba(0,0,0,.6); }
#wave-flash.gold .w2 {
  background: linear-gradient(180deg, #fff 10%, var(--gold-hot) 55%, var(--gold));
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 4px 22px rgba(255,194,62,0.5));
}
#wave-flash.go { animation: waveFlash 1.5s var(--ease) forwards; }
@keyframes waveFlash {
  0% { opacity: 0; transform: translateY(16px) scale(.92); }
  18% { opacity: 1; transform: none; }
  78% { opacity: 1; transform: none; }
  100% { opacity: 0; transform: translateY(-12px) scale(.98); }
}

/* toast */
#toast {
  position: fixed;
  left: 50%; bottom: calc(var(--tab-h) + 26px);
  transform: translateX(-50%) translateY(16px);
  background: rgba(14,20,36,.95);
  border: 1px solid var(--stroke);
  border-radius: 999px;
  padding: 10px 18px;
  font-size: 13px; font-weight: 700;
  z-index: 90;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s var(--ease), transform .25s var(--ease);
  max-width: 86vw; text-align: center;
}
#toast.show { opacity: 1; transform: translateX(-50%); }

@media (min-width: 521px) {
  #app { border-left: 1px solid var(--stroke); border-right: 1px solid var(--stroke); }
}
