/* =====================================================================
   Hoodcamp Idle — stylesheet
   Night forest + ember. Lilita One for display, DM Sans for everything else.
   ===================================================================== */
:root {
  --night: #0b1322;
  --night-2: #0f1a2e;
  --night-3: #142238;
  --pine: #12261f;
  --panel: rgba(18, 28, 46, 0.86);
  --panel-solid: #141f33;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.14);
  --ember: #ff8a3d;
  --ember-2: #ff5d2e;
  --ember-glow: rgba(255, 138, 61, 0.35);
  --gold: #ffd23d;
  --gold-2: #ffe34d;
  --ash: #e6ecf7;
  --smoke: #8a97b0;
  --smoke-2: #5f6c86;
  --danger: #ff5d6c;
  --good: #52d98b;
  --warn: #ffb43d;
  --r-comun: #b8c0cc;
  --r-raro: #43c0ff;
  --r-epico: #b46bff;
  --r-legendario: #ffb43d;
  --display: "Lilita One", "Russo One", Impact, sans-serif;
  --body: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --radius: 10px;
  --radius-sm: 7px;
  --top-h: 60px;
  --rail-w: 220px;
  --tab-h: 62px;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; min-height: 100%; background: var(--night); color: var(--ash); }
body {
  font-family: var(--body);
  font-size: 15px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
body.hc-shell { overflow: hidden; height: 100dvh; }
body.hc-modal-open { overflow: hidden; }
#app { min-height: 100dvh; }
img { max-width: 100%; display: block; }
a { color: var(--gold); }
button { font: inherit; color: inherit; cursor: pointer; }
input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; font-weight: 700; line-height: 1.15; }
p { margin: 0; }
ul.plain, ol.plain { list-style: none; margin: 0; padding: 0; }
ul.plain li { padding: 6px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
ul.plain li:last-child { border-bottom: 0; }
ul.plain.small li { font-size: 13px; padding: 4px 0; }
code { font-size: 12px; color: var(--smoke); word-break: break-all; }
.hc-display { font-family: var(--display); font-weight: 400; letter-spacing: 0.01em; }
.hc-muted { color: var(--smoke); }
.hc-muted.sm, .sm { font-size: 12.5px; }
.gold { color: var(--gold); }
.bad { color: var(--danger); }
.hc-empty { padding: 36px 16px; text-align: center; color: var(--smoke); }
[hidden] { display: none !important; }

/* ---------------------------------------------------------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 16px; border-radius: var(--radius-sm); border: 1px solid var(--line-2);
  background: var(--night-3); color: var(--ash); font-weight: 700; font-size: 14px;
  transition: transform 0.12s ease, filter 0.12s ease, background 0.12s ease; white-space: nowrap;
}
.btn:hover { filter: brightness(1.1); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; filter: none; }
.btn.primary {
  border-color: #ff9a4d; color: #1a0d05;
  background: linear-gradient(180deg, #ffb060 0%, var(--ember) 55%, var(--ember-2) 100%);
  box-shadow: 0 6px 18px -6px var(--ember-glow), inset 0 1px 0 #ffd9b0;
}
.btn.ghost { background: transparent; }
.btn.danger { border-color: #ff6f7c; background: linear-gradient(180deg, #ff7a86, #e0404f); color: #fff; }
.btn.big { padding: 14px 22px; font-size: 16px; border-radius: var(--radius); }
.btn.sm { padding: 7px 12px; font-size: 13px; }
.btn.xs { padding: 4px 9px; font-size: 12px; }
.btn.is-busy { position: relative; color: transparent !important; }
.btn.is-busy::after {
  content: ""; position: absolute; width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid #0003; border-top-color: #000a; animation: spin 0.7s linear infinite;
}
.btn.ghost.is-busy::after, .btn.danger.is-busy::after { border-color: #fff3; border-top-color: #fff; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------------------------------------------------------- fields */
.hc-field { display: flex; flex-direction: column; gap: 5px; font-size: 13px; color: var(--smoke); }
.hc-field > span { font-weight: 600; }
.hc-field input, .hc-field select, textarea {
  width: 100%; padding: 10px 12px; border-radius: var(--radius-sm); border: 1px solid var(--line-2);
  background: #0a1221; color: var(--ash); outline: none; font-size: 15px;
}
.hc-field input:focus, textarea:focus { border-color: var(--ember); box-shadow: 0 0 0 3px rgba(255, 138, 61, 0.18); }
.hc-check { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ash); cursor: pointer; }
.hc-check input { width: 16px; height: 16px; accent-color: var(--ember); }
textarea { font-family: ui-monospace, monospace; font-size: 12px; resize: vertical; }

.seg { display: inline-flex; gap: 2px; padding: 3px; border-radius: 9px; background: #0a1221; border: 1px solid var(--line); flex-wrap: wrap; }
.seg button { padding: 6px 12px; border: 0; border-radius: 6px; background: transparent; color: var(--smoke); font-weight: 600; font-size: 13px; }
.seg button.on { background: var(--night-3); color: var(--ash); box-shadow: inset 0 0 0 1px var(--line-2); }
.seg.sm button { padding: 5px 10px; font-size: 12px; }
.seg.wide { display: flex; width: 100%; }
.seg.wide button { flex: 1; }
.filters { display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; margin-bottom: 14px; }

/* ---------------------------------------------------------- toasts */
#toasts { position: fixed; left: 50%; bottom: calc(var(--tab-h) + 16px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 1200; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: min(92vw, 420px); }
.toast {
  padding: 10px 14px; border-radius: 9px; background: #1a2740; border: 1px solid var(--line-2); color: var(--ash);
  font-size: 14px; font-weight: 600; opacity: 0; transform: translateY(8px); transition: all 0.25s ease; box-shadow: 0 10px 30px #0008; text-align: center;
}
.toast.show { opacity: 1; transform: none; }
.toast.good { border-color: #52d98b66; background: #123326; }
.toast.bad { border-color: #ff5d6c66; background: #3a1a22; }
.toast.warn { border-color: #ffb43d66; background: #3a2a12; }
@media (min-width: 900px) { #toasts { bottom: 24px; } }

/* ---------------------------------------------------------- modal */
.hc-modal-wrap { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 16px; opacity: 0; transition: opacity 0.2s ease; }
.hc-modal-wrap.in { opacity: 1; }
.hc-modal-bg { position: absolute; inset: 0; background: rgba(4, 8, 16, 0.78); backdrop-filter: blur(3px); }
.hc-modal {
  position: relative; width: min(100%, 480px); max-height: calc(100dvh - 32px); overflow: auto;
  background: var(--panel-solid); border: 1px solid var(--line-2); border-radius: 14px; padding: 22px;
  box-shadow: 0 30px 80px #000c; transform: translateY(10px) scale(0.98); transition: transform 0.22s ease;
}
.hc-modal-wrap.in .hc-modal { transform: none; }
.hc-modal-wrap.wide .hc-modal { width: min(100%, 860px); }
.hc-modal-title { font-size: 20px; margin-bottom: 10px; }
.hc-modal-body { color: var(--smoke); margin-bottom: 14px; }
.hc-modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 18px; flex-wrap: wrap; }
.hc-modal-x { position: absolute; top: 10px; right: 10px; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line-2); background: #0008; color: var(--ash); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 12px 0; font-size: 14px; }
.kv dt { color: var(--smoke); }
.kv dd { margin: 0; }
.kv.nested { margin: 2px 0; font-size: 12.5px; }

/* ---------------------------------------------------------- gate / login */
.hc-gate { min-height: 100dvh; display: grid; place-items: center; align-content: center; gap: 14px; text-align: center; padding: 24px; }
.hc-gate-logo { width: 90px; height: 90px; border-radius: 50%; box-shadow: 0 0 0 2px #ffd23d55, 0 10px 30px #0008; }
.hc-login { position: relative; min-height: 100dvh; display: grid; place-items: center; padding: 20px; overflow: hidden; }
.hc-login-bg {
  position: absolute; inset: 0; z-index: 0;
  background:
    linear-gradient(180deg, rgba(6, 12, 22, 0.35) 0%, rgba(6, 12, 22, 0.55) 55%, rgba(6, 12, 22, 0.78) 100%),
    url('/assets/hoodcamp-login-night.jpg') center / cover no-repeat;
}
.hc-login-card {
  position: relative; z-index: 2; width: min(100%, 400px); display: flex; flex-direction: column; gap: 12px;
  padding: 26px 24px 20px; border-radius: 16px; background: rgba(12, 19, 33, 0.86); border: 1px solid var(--line-2);
  backdrop-filter: blur(10px); box-shadow: 0 30px 80px #000a;
}
.hc-login-logo { width: 72px; height: 72px; border-radius: 50%; margin: -58px auto 0; box-shadow: 0 0 0 3px var(--night), 0 0 0 5px #ffd23d66, 0 10px 30px #000a; }
.hc-login-title { text-align: center; font-size: 34px; color: var(--gold); text-shadow: 0 2px 0 #7a4a00, 0 6px 24px #ff8a3d55; }
.hc-login-sub { text-align: center; color: var(--smoke); font-size: 14px; margin-top: -6px; margin-bottom: 4px; }
.hc-login-note { font-size: 12.5px; color: var(--warn); background: #ffb43d14; border: 1px solid #ffb43d33; padding: 8px 10px; border-radius: 8px; text-align: center; }
.hc-login-links { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; flex-wrap: wrap; }
.hc-lang { display: flex; gap: 4px; justify-content: center; }
.hc-lang-btn { padding: 4px 9px; border-radius: 6px; border: 1px solid var(--line); background: transparent; color: var(--smoke); font-size: 11.5px; font-weight: 700; }
.hc-lang-btn.on { color: var(--ash); border-color: var(--line-2); background: var(--night-3); }

/* ---------------------------------------------------------- shell */
.hc-app { display: grid; grid-template-rows: var(--top-h) 1fr; grid-template-columns: 1fr; height: 100dvh; }
.hc-top {
  grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 0 14px; padding-top: env(safe-area-inset-top); border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, #0f1a2e, #0b1322); position: relative; z-index: 20;
}
.hc-brand { display: flex; align-items: center; gap: 10px; background: none; border: 0; padding: 0; color: var(--gold); font-size: 22px; text-shadow: 0 2px 0 #6a3f00; min-width: 0; }
.hc-brand .hc-display { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hc-brand img { width: 36px; height: 36px; border-radius: 50%; box-shadow: 0 0 0 2px #ffd23d55; flex-shrink: 0; }
.hc-top-right { display: flex; align-items: center; gap: 8px; min-width: 0; flex-shrink: 1; }
.hc-pill { display: inline-flex; align-items: center; gap: 6px; padding: 6px 11px; border-radius: 999px; border: 1px solid var(--line-2); background: #0a1221; font-size: 13.5px; font-weight: 700; max-width: 42vw; }
.hc-pill b { font-variant-numeric: tabular-nums; }
.hc-pill i { font-style: normal; color: var(--smoke); font-size: 11px; }
.hc-pill-stars { color: var(--gold-2); }
.hc-tok-dot { width: 10px; height: 10px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #ffd27a, var(--ember) 55%, #a8320f); box-shadow: 0 0 10px var(--ember-glow); display: inline-block; }
.hc-user { position: relative; }
.hc-user-btn { display: flex; align-items: center; gap: 8px; background: none; border: 0; padding: 4px; }
.hc-avatar { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(135deg, #ffd23d, #ff8a3d); color: #1a0d05; font-family: var(--display); font-size: 16px; }
.hc-user-name { font-weight: 700; font-size: 14px; }
.hc-user-menu { position: absolute; right: 0; top: calc(100% + 6px); min-width: 180px; background: var(--panel-solid); border: 1px solid var(--line-2); border-radius: 10px; padding: 8px; display: none; flex-direction: column; gap: 4px; box-shadow: 0 20px 50px #000a; }
.hc-user-menu.open { display: flex; }
.hc-menu-item { text-align: left; padding: 8px 10px; border: 0; background: transparent; border-radius: 6px; font-weight: 600; }
.hc-menu-item:hover { background: var(--night-3); }
.hc-menu-ver { font-size: 11px; color: var(--smoke-2); padding: 4px 10px; }

.hc-rail { display: none; }
.hc-view { overflow: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; padding-bottom: calc(var(--tab-h) + env(safe-area-inset-bottom)); }
.hc-nav-item { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; background: none; border: 0; color: var(--smoke); font-weight: 600; font-size: 11px; padding: 6px 4px; border-radius: 8px; }
.hc-nav-item.on { color: var(--gold); }
.hc-nav-ico { font-size: 20px; line-height: 1; }
/* Mobile: horizontal scroll — all tabs visible, swipe freely */
.hc-tabbar {
  position: fixed; left: 0; right: 0; bottom: 0;
  height: calc(var(--tab-h) + env(safe-area-inset-bottom));
  padding: 0 8px env(safe-area-inset-bottom);
  display: flex; flex-direction: row; align-items: stretch;
  gap: 2px;
  overflow-x: auto; overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  scroll-snap-type: x proximity;
  background: #0a1221f2; border-top: 1px solid var(--line); z-index: 30;
  backdrop-filter: blur(8px);
  scrollbar-width: none;
  touch-action: pan-x;
}
.hc-tabbar::-webkit-scrollbar { display: none; }
.hc-tabbar .hc-nav-item {
  flex: 0 0 auto;
  min-width: 64px;
  max-width: 88px;
  padding: 8px 10px;
  scroll-snap-align: center;
}
.hc-tabbar .hc-nav-lbl {
  font-size: 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 72px;
}

@media (max-width: 899px) {
  .hc-top { padding-left: 10px; padding-right: 10px; gap: 8px; }
  .hc-brand { font-size: 18px; gap: 8px; }
  .hc-brand img { width: 30px; height: 30px; }
  .hc-user-name { display: none; }
  .hc-pill { padding: 5px 8px; font-size: 12px; gap: 4px; }
  .hc-pill i { display: none; }
  .hc-pill b { overflow: hidden; text-overflow: ellipsis; }
  .camp-hud-bottom { gap: 6px; }
  .camp-hud-bottom .btn { font-size: 12px; padding: 8px 10px; }
  .page { padding: 14px 12px 36px; }
}

@media (min-width: 900px) {
  .hc-app { grid-template-columns: var(--rail-w) 1fr; }
  .hc-rail { display: flex; flex-direction: column; gap: 4px; padding: 14px 10px; border-right: 1px solid var(--line); background: #0a1221; }
  .hc-rail .hc-nav-item { flex-direction: row; justify-content: flex-start; gap: 12px; padding: 11px 12px; font-size: 14px; }
  .hc-rail .hc-nav-item.on { background: linear-gradient(90deg, #ff8a3d1f, transparent); box-shadow: inset 3px 0 0 var(--ember); }
  .hc-rail .hc-nav-ico { width: 24px; text-align: center; }
  .hc-tabbar { display: none !important; }
  .hc-view { padding-bottom: 24px; }
}

/* ---------------------------------------------------------- page scaffold */
.page { padding: 18px 16px 40px; max-width: 1180px; margin: 0 auto; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 14px; flex-wrap: wrap; margin-bottom: 16px; }
.page-head h2 { font-size: 30px; color: var(--gold); text-shadow: 0 2px 0 #6a3f00; }
.page-head p { max-width: 62ch; }
.page-actions { display: flex; gap: 8px; }
.hc-panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.hc-panel-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.hc-panel-head h3 { font-size: 15px; letter-spacing: 0.01em; }
.hc-panel.wide { grid-column: 1 / -1; }
.hc-pager { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 14px 0 4px; font-size: 13px; color: var(--smoke); }

/* ---------------------------------------------------------- camp */
.camp { display: flex; flex-direction: column; }
.camp-stage { position: relative; height: clamp(360px, 54dvh, 560px); overflow: hidden; background: var(--night); }
.camp-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.camp-hud-top { position: absolute; top: 12px; left: 12px; right: 12px; display: flex; justify-content: space-between; gap: 10px; pointer-events: none; }
.camp-power, .camp-rate { display: flex; flex-direction: column; padding: 10px 14px; border-radius: 10px; background: #060b14b8; border: 1px solid var(--line-2); backdrop-filter: blur(6px); min-width: 140px; }
.camp-rate { align-items: flex-end; text-align: right; }
.camp-power-lbl, .camp-rate-lbl { font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--smoke); font-weight: 700; }
.camp-power-num { font-family: var(--display); font-size: 30px; color: #fff; line-height: 1.05; text-shadow: 0 0 18px var(--ember-glow); }
.camp-rate-num { font-family: var(--display); font-size: 30px; color: var(--gold); line-height: 1.05; font-variant-numeric: tabular-nums; }
.camp-power-sub, .camp-rate-sub { font-size: 12px; color: var(--smoke); }
.camp-empty { position: absolute; left: 50%; top: 42%; transform: translate(-50%, -50%); width: min(92%, 440px); text-align: center; padding: 22px 20px; border-radius: 14px; background: #060b14cc; border: 1px solid var(--line-2); backdrop-filter: blur(8px); display: flex; flex-direction: column; gap: 10px; align-items: center; }
.camp-empty h2 { font-size: 26px; color: var(--gold); }
.camp-empty p { color: var(--smoke); font-size: 14px; }
.camp-hud-bottom { position: absolute; bottom: 12px; left: 12px; right: 12px; display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; }
.camp-hud-bottom .btn { backdrop-filter: blur(6px); background: #060b14b8; }
.camp-hud-bottom .btn.primary { background: linear-gradient(180deg, #ffb060 0%, var(--ember) 55%, var(--ember-2) 100%); }
/* Same full width as camp-stage (hoodie field) — no centered max-width card column */
.camp-grid { display: grid; grid-template-columns: 1fr; gap: 12px; padding: 12px 12px 30px; width: 100%; max-width: none; margin: 0; box-sizing: border-box; }
.stat-row { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 12px; }
.stat { display: flex; flex-direction: column; padding: 10px 12px; border-radius: 8px; background: #0a1221; border: 1px solid var(--line); }
.stat-l { font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--smoke); font-weight: 700; }
.stat-v { font-family: var(--display); font-size: 24px; line-height: 1.1; margin-top: 2px; }
.stat-s { font-size: 11.5px; color: var(--smoke); }
.chest-row { display: flex; gap: 10px; flex-wrap: wrap; }
.chest { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; width: 120px; padding: 10px 8px 8px; border-radius: 10px; border: 1px solid var(--line-2); background: #0a1221; transition: transform 0.12s ease; }
.chest:hover { transform: translateY(-2px); border-color: var(--rc, var(--line-2)); }
.chest img { width: 84px; height: 46px; object-fit: contain; }
.chest-qty { position: absolute; top: 6px; right: 8px; font-size: 12px; font-weight: 800; color: var(--gold); }
.chest-name { font-size: 12px; font-weight: 600; text-align: center; }
.chest-cta { font-size: 11px; color: var(--ember); font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; }
.hc-events { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.hc-ev { display: grid; grid-template-columns: 34px 1fr auto; gap: 10px; align-items: center; padding: 7px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.hc-ev:last-child { border-bottom: 0; }
.hc-ev-ico { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 8px; background: #0a1221; font-size: 16px; overflow: hidden; }
.hc-ev-ico img { width: 30px; height: 30px; object-fit: contain; }
.hc-ev time { font-size: 11.5px; color: var(--smoke-2); white-space: nowrap; }
.hc-ev b { white-space: nowrap; }
@media (min-width: 900px) {
  .camp-grid { grid-template-columns: 1.1fr 0.9fr; }
  .camp-log { grid-column: 1 / -1; }
  .stat-row { grid-template-columns: repeat(4, 1fr); }
}

/* report */
.report-wrap .hc-modal { width: min(100%, 560px); text-align: center; }
.report-title { font-size: 28px; color: var(--gold); }
.report-grid { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); margin: 14px 0; }
.report-stat { padding: 12px; border-radius: 10px; background: #0a1221; border: 1px solid var(--line); display: flex; flex-direction: column; gap: 4px; }
.report-stat span { font-size: 12px; color: var(--smoke); }
.report-stat b { font-family: var(--display); font-size: 22px; }
.report h4 { margin: 14px 0 8px; font-size: 13px; color: var(--smoke); text-transform: uppercase; letter-spacing: 0.05em; }
.report-row { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.mini { width: 64px; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 4px; border-radius: 8px; background: #0a1221; border: 1px solid var(--rc, var(--line)); font-size: 11px; font-weight: 700; }
.mini img { width: 46px; height: 46px; object-fit: contain; }
.mini.more { justify-content: center; color: var(--smoke); }

/* ---------------------------------------------------------- hoodie cards */
.rar-comun { --rc: var(--r-comun); }
.rar-raro { --rc: var(--r-raro); }
.rar-epico { --rc: var(--r-epico); }
.rar-legendario { --rc: var(--r-legendario); }
.hd-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.hd-grid.compact { grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 8px; }
.hd-grid.in-modal { max-height: 60dvh; overflow: auto; padding: 2px; }
.hd-card {
  position: relative; display: flex; flex-direction: column; border-radius: 12px; overflow: hidden; cursor: pointer;
  background: linear-gradient(180deg, #152238, #0d1627); border: 1px solid var(--line-2);
  transition: transform 0.14s ease, box-shadow 0.14s ease, border-color 0.14s ease;
}
.hd-card:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--rc) 70%, transparent); box-shadow: 0 12px 30px -12px color-mix(in srgb, var(--rc) 60%, transparent); }
.hd-card.sel { border-color: var(--ember); box-shadow: 0 0 0 2px var(--ember), 0 10px 30px -10px var(--ember-glow); }
.hd-card.listed { opacity: 0.75; }
.hd-art { aspect-ratio: 1; display: grid; place-items: center; padding: 10px; background: radial-gradient(circle at 50% 70%, color-mix(in srgb, var(--rc) 22%, transparent), transparent 70%); }
.hd-art img { width: 86%; height: 86%; object-fit: contain; filter: drop-shadow(0 8px 14px #0009); }
.hd-card.camp .hd-art::after { content: "🔥"; position: absolute; top: 8px; left: 8px; font-size: 13px; filter: drop-shadow(0 0 6px var(--ember)); }
.hd-meta { padding: 8px 10px 10px; display: flex; flex-direction: column; gap: 3px; }
.hd-name { font-weight: 800; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hd-sub { display: flex; justify-content: space-between; align-items: center; gap: 6px; font-size: 11.5px; }
.hd-rar { color: var(--rc, var(--smoke)); font-weight: 800; text-transform: uppercase; letter-spacing: 0.05em; font-size: 10.5px; }
.hd-status { color: var(--smoke); white-space: nowrap; }
.hd-grid.compact .hd-sub { font-size: 10.5px; }
.hd-status.s-camp { color: var(--ember); }
.hd-status.s-listed { color: var(--gold); }
.hd-power { font-weight: 800; font-size: 15px; font-variant-numeric: tabular-nums; }
.hd-power small { color: var(--good); font-size: 11px; margin-left: 4px; }
.hd-check { position: absolute; top: 8px; right: 8px; width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line-2); background: #0008; display: grid; place-items: center; font-size: 13px; font-weight: 900; color: #1a0d05; z-index: 2; }
.hd-card.sel .hd-check { background: var(--ember); border-color: var(--ember); }
.hd-badge { position: absolute; top: 8px; left: 8px; font-size: 11px; font-weight: 800; padding: 2px 7px; border-radius: 999px; background: #0008; color: var(--gold); z-index: 2; }
.hd-grid.compact .hd-meta { padding: 6px 8px 8px; }
.hd-grid.compact .hd-name { font-size: 12.5px; }
.hd-grid.compact .hd-power { font-size: 13px; }
.sel-bar { position: sticky; bottom: 8px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; justify-content: center; padding: 10px 12px; margin-top: 14px; border-radius: 12px; background: #0a1221f2; border: 1px solid var(--line-2); box-shadow: 0 10px 30px #000a; font-size: 13px; }

/* detail */
.hd-detail-wrap .hc-modal { padding: 0; overflow: hidden; width: min(100%, 560px); }
.hd-detail { display: grid; grid-template-columns: 1fr; }
.hd-detail-art { display: grid; place-items: center; padding: 20px; background: radial-gradient(circle at 50% 60%, color-mix(in srgb, var(--rc) 30%, transparent), #0a1221 72%); }
.hd-detail-art img { width: min(60%, 220px); filter: drop-shadow(0 12px 24px #000a); }
.hd-detail-body { padding: 18px 20px 20px; }
.hd-detail-body h3 { font-size: 26px; }
.hd-detail-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
@media (min-width: 640px) { .hd-detail { grid-template-columns: 220px 1fr; } .hd-detail-art img { width: 170px; } }
.sell-preview { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; padding: 10px; border-radius: 10px; background: #0a1221; border: 1px solid var(--rc); }
.sell-preview img { width: 56px; height: 56px; object-fit: contain; }

/* ---------------------------------------------------------- mint */
.mint-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 900px) { .mint-grid { grid-template-columns: 1fr 1fr; } }
.mint-box { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px; padding: 22px 18px; background: radial-gradient(ellipse at 50% 0%, #ff8a3d22, transparent 60%), var(--panel); }
.mint-ball { position: relative; width: 150px; height: 150px; display: grid; place-items: center; }
.mint-ball img { width: 120px; position: relative; z-index: 1; animation: ballFloat 3.6s ease-in-out infinite; filter: drop-shadow(0 14px 24px #000a); }
.mint-ball-glow { position: absolute; inset: 10px; border-radius: 50%; background: radial-gradient(circle, #ffb04d55, transparent 65%); animation: glowPulse 2.4s ease-in-out infinite; }
@keyframes ballFloat { 0%, 100% { transform: translateY(0) rotate(-3deg); } 50% { transform: translateY(-10px) rotate(3deg); } }
@keyframes glowPulse { 0%, 100% { opacity: 0.6; transform: scale(0.95); } 50% { opacity: 1; transform: scale(1.1); } }
.mint-price { display: flex; flex-direction: column; gap: 2px; }
.mint-price b { font-family: var(--display); font-size: 30px; color: var(--gold); }
.mint-price span { font-size: 13px; color: var(--smoke); }
.mint-qty { display: flex; flex-direction: column; align-items: center; gap: 8px; font-size: 13px; color: var(--smoke); }
.stepper { display: inline-flex; align-items: center; gap: 2px; border-radius: 10px; background: #0a1221; border: 1px solid var(--line-2); overflow: hidden; }
.stepper button { width: 44px; height: 42px; border: 0; background: transparent; color: var(--ash); font-size: 22px; font-weight: 700; }
.stepper button:disabled { opacity: 0.3; }
.stepper b { min-width: 48px; text-align: center; font-family: var(--display); font-size: 24px; color: #fff; }
.mint-total { font-size: 16px; font-weight: 800; }
.mint-need { color: var(--warn); font-weight: 700; }
.mint-btn { min-width: 220px; animation: mintPulse 2.2s ease-in-out infinite; }
@keyframes mintPulse { 0%, 100% { box-shadow: 0 6px 18px -6px var(--ember-glow); } 50% { box-shadow: 0 10px 34px -6px #ff8a3d99; } }
.odds { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.odds li { display: grid; grid-template-columns: 96px 1fr 52px; gap: 10px; align-items: center; padding: 8px 10px; border-radius: 8px; background: #0a1221; border: 1px solid var(--line); }
.odds li small { grid-column: 1 / -1; color: var(--smoke); font-size: 12px; }
.odds-bar { height: 8px; border-radius: 4px; background: #ffffff10; overflow: hidden; }
.odds-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--rc), color-mix(in srgb, var(--rc) 50%, #fff)); border-radius: 4px; }
.odds li b { text-align: right; font-variant-numeric: tabular-nums; }
.odds-img { width: 48px; height: 28px; object-fit: contain; }

/* reveal */
.reveal-wrap .hc-modal { width: min(100%, 900px); background: radial-gradient(ellipse at 50% 100%, #ff8a3d22, transparent 55%), var(--panel-solid); text-align: center; }
.reveal-title { font-size: 28px; color: var(--gold); margin-bottom: 14px; }
.reveal-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); justify-items: center; }
.reveal-grid.n1 { grid-template-columns: 1fr; }
.reveal-grid.n1 .rv { width: 220px; }
.rv { width: 100%; max-width: 170px; aspect-ratio: 3 / 4; perspective: 900px; }
.rv-inner { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1); }
.rv.flip .rv-inner { transform: rotateY(180deg); }
.rv-back, .rv-front { position: absolute; inset: 0; border-radius: 12px; backface-visibility: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; border: 1px solid var(--line-2); }
.rv-back { background: linear-gradient(160deg, #1b2a45, #0d1627); }
.rv-back img { width: 60%; animation: ballFloat 2s ease-in-out infinite; }
.rv-front { transform: rotateY(180deg); background: radial-gradient(circle at 50% 35%, color-mix(in srgb, var(--rc) 30%, transparent), #0d1627 70%); border-color: var(--rc); box-shadow: 0 0 24px -4px var(--rc); padding: 8px; }
.rv-front img { width: 70%; filter: drop-shadow(0 8px 14px #000a); }
.rv-name { font-weight: 800; font-size: 13px; }
.rv-rar { font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em; color: var(--rc); }
.rv-pow { font-weight: 800; font-size: 14px; }
.rv.rar-legendario.flip .rv-front { animation: legendaryGlow 1.4s ease-in-out infinite alternate; }
@keyframes legendaryGlow { from { box-shadow: 0 0 20px -4px var(--rc); } to { box-shadow: 0 0 44px 2px var(--rc); } }
.reveal.shake { animation: shake 0.45s ease; }
@keyframes shake { 0%, 100% { transform: none; } 20% { transform: translate(-4px, 2px); } 40% { transform: translate(4px, -2px); } 60% { transform: translate(-3px, -1px); } 80% { transform: translate(3px, 1px); } }
.reveal-actions { justify-content: center; }

/* ---------------------------------------------------------- forge */
.forge-grid { display: grid; grid-template-columns: 1fr; gap: 14px; margin-top: 14px; }
@media (min-width: 900px) { .forge-grid { grid-template-columns: 1fr 300px; align-items: start; } .forge-side { position: sticky; top: 12px; } }
.forge-left { display: flex; flex-direction: column; gap: 14px; }
.forge-target { display: flex; gap: 12px; align-items: center; padding: 10px; border-radius: 10px; background: #0a1221; border: 1px solid var(--rc); cursor: pointer; }
.forge-target img { width: 64px; height: 64px; object-fit: contain; }
.forge-target > div { flex: 1; font-size: 13.5px; }
.forge-side h3 { font-size: 13px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--smoke); }
.forge-gain { font-family: var(--display); font-size: 42px; color: var(--gold); margin: 6px 0; text-shadow: 0 0 20px var(--ember-glow); }
.forge-side .btn { width: 100%; margin-top: 12px; }
.forge-tier { font-size: 14px; margin: 6px 0; }
.forge-tier-img { width: 120px; height: 66px; object-fit: contain; margin: 4px 0; }
.thresholds { list-style: none; padding: 0; margin: 8px 0 0; font-size: 13px; }
.thresholds li { padding: 4px 0; color: var(--smoke); }
.thresholds li.on { color: var(--gold); font-weight: 700; }
.chest-open { text-align: center; }
.chest-open h3 { font-size: 24px; color: var(--gold); margin-bottom: 10px; }
.chest-anim { height: 120px; display: grid; place-items: center; }
.chest-anim img { width: 180px; height: 100px; object-fit: contain; filter: drop-shadow(0 10px 20px #000a); }
.chest-anim img.shake { animation: chestShake 0.65s ease; }
.chest-anim img.pop { animation: chestPop 0.5s ease; }
@keyframes chestShake { 0%, 100% { transform: rotate(0); } 20% { transform: rotate(-6deg) scale(1.03); } 40% { transform: rotate(6deg) scale(1.05); } 60% { transform: rotate(-5deg) scale(1.06); } 80% { transform: rotate(4deg) scale(1.04); } }
@keyframes chestPop { 0% { transform: scale(1); filter: brightness(1); } 40% { transform: scale(1.15); filter: brightness(1.8) drop-shadow(0 0 30px var(--gold)); } 100% { transform: scale(1); } }
.chest-results { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }
.chest-res { display: flex; align-items: center; justify-content: center; gap: 10px; flex-wrap: wrap; padding: 8px; border-radius: 8px; background: #0a1221; animation: fadeUp 0.35s ease; }
.chest-res b { font-family: var(--display); font-size: 22px; }
.chest-res em { font-size: 12px; color: var(--smoke); font-style: normal; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ---------------------------------------------------------- market */
.listing-price { font-family: var(--display); font-size: 18px; color: var(--gold); margin-top: 2px; }
.hd-card.listing { cursor: default; }
.hd-card.listing .btn { margin-top: 6px; }
.sales .hc-ev-txt { font-size: 13px; }

/* ---------------------------------------------------------- pool */
.pool-hero { display: grid; grid-template-columns: 1fr; gap: 10px; padding: 16px; border-radius: 14px; margin-bottom: 14px; background: radial-gradient(ellipse at 20% 0%, #ffd23d22, transparent 55%), linear-gradient(135deg, #182642, #0f1a2e); border: 1px solid #ffd23d33; }
@media (min-width: 720px) { .pool-hero { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .pool-hero { grid-template-columns: repeat(4, 1fr); } }
.pool-hero > div { display: flex; flex-direction: column; gap: 2px; }
.pool-hero span { font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--smoke); font-weight: 700; }
.pool-hero b { font-family: var(--display); font-size: 32px; line-height: 1.05; font-variant-numeric: tabular-nums; }
.pool-hero b small { font-size: 14px; color: var(--smoke); font-family: var(--body); font-weight: 700; }
.pool-hero small { font-size: 12.5px; color: var(--smoke); }
.pool-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 900px) { .pool-grid { grid-template-columns: 1.4fr 1fr; align-items: start; } }
.pool-side { display: flex; flex-direction: column; gap: 14px; }
.board { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.board th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--smoke); padding: 6px 8px; border-bottom: 1px solid var(--line-2); }
.board td { padding: 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.board tr:last-child td { border-bottom: 0; }
.board tr.me td { background: #ff8a3d14; }
.board tr.top1 td:first-child, .board tr.top2 td:first-child, .board tr.top3 td:first-child { font-size: 18px; }
.board td small { color: var(--smoke); }
.board img.tiny { width: 28px; height: 28px; object-fit: contain; display: inline-block; vertical-align: middle; }
.pool-days { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.pool-days li { padding: 8px 10px; border-radius: 8px; background: #0a1221; border: 1px solid var(--line); font-size: 13px; }
.pool-day-head { display: flex; justify-content: space-between; gap: 8px; }
.pool-top { margin: 6px 0 0; padding-left: 18px; color: var(--smoke); font-size: 12.5px; }

/* ---------------------------------------------------------- wallet */
.wallet-balances { display: grid; grid-template-columns: 1fr; gap: 10px; margin-bottom: 14px; }
@media (min-width: 640px) { .wallet-balances { grid-template-columns: 1fr 1fr; } }
.bal { display: flex; flex-direction: column; gap: 2px; padding: 16px; border-radius: 12px; border: 1px solid var(--line-2); background: linear-gradient(135deg, #182642, #0f1a2e); }
.bal.stars { border-color: #ffd23d44; }
.bal.tok { border-color: #ff8a3d44; }
.bal span { font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--smoke); font-weight: 700; }
.bal b { font-family: var(--display); font-size: 32px; line-height: 1.05; display: flex; align-items: center; gap: 8px; }
.bal.stars b { color: var(--gold); }
.bal small { color: var(--smoke); font-size: 12.5px; }
.wallet-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 900px) { .wallet-grid { grid-template-columns: 1fr 1fr; } .wallet-ledger { grid-column: 1 / -1; } }
.wallet-grid .hc-field { margin: 8px 0; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; margin: 8px 0; }
.shop-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 720px) { .shop-grid { grid-template-columns: repeat(3, 1fr); } }
.shop-card { text-align: center; }
.shop-card-art { width: 72px; height: 72px; margin: 0 auto 10px; display: grid; place-items: center; }
.shop-card-art img { width: 56px; height: 56px; object-fit: contain; image-rendering: pixelated; }
.shop-price { margin: 8px 0; }
.page.shop .page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.bal.sm { padding: 8px 12px; border-radius: 12px; background: #182642; border: 1px solid var(--line-2); display: flex; gap: 6px; align-items: center; }
.wd-pending { color: var(--warn); }
.wd-paid { color: var(--good); }
.wd-rejected { color: var(--danger); }
.ledger .hc-ev { grid-template-columns: 34px 1fr auto auto; }

/* ---------------------------------------------------------- admin */
.adm-nav { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.adm-nav button { padding: 8px 12px; border-radius: 8px; border: 1px solid var(--line); background: #0a1221; color: var(--smoke); font-weight: 700; font-size: 13px; }
.adm-nav button.on { color: var(--ash); border-color: var(--ember); background: #ff8a3d14; }
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 8px; margin-bottom: 14px; }
.kpi-grid.small { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
.kpi { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 8px; background: #0a1221; border: 1px solid var(--line); }
.kpi span { font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--smoke); font-weight: 700; }
.kpi b { font-size: 18px; font-variant-numeric: tabular-nums; }
.kpi.gold b { color: var(--gold); }
.adm-cols { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 900px) { .adm-cols { grid-template-columns: 1fr 1fr; } }
.adm-toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.adm-search { display: flex; gap: 6px; }
.adm-search input { padding: 7px 10px; border-radius: 7px; border: 1px solid var(--line-2); background: #0a1221; color: var(--ash); min-width: 220px; }
.adm-table { font-size: 13px; }
.adm-table input, .adm-table select { padding: 5px 8px; border-radius: 6px; border: 1px solid var(--line-2); background: #0a1221; color: var(--ash); width: 90px; }
.adm-table tr.banned td { opacity: 0.6; }
.adm-table tr.adm td:nth-child(2) { color: var(--gold); }
.adm-form { display: flex; flex-direction: column; gap: 10px; }
.adm-fields { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; margin-bottom: 8px; }
.adm-fields .wide, .hc-field.wide { grid-column: 1 / -1; }
.adm-fields b.wide { font-size: 12px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--smoke); margin-top: 6px; }
.adm-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.inline { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.inline input, .inline select { padding: 7px 10px; border-radius: 7px; border: 1px solid var(--line-2); background: #0a1221; color: var(--ash); max-width: 170px; }
.adm-save { position: sticky; bottom: 8px; display: flex; justify-content: flex-end; padding: 10px; background: #0a1221f2; border: 1px solid var(--line-2); border-radius: 12px; }
.cfg { gap: 14px; }
.cfg textarea { margin-bottom: 8px; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.chip { padding: 4px 10px; border-radius: 999px; background: #0a1221; border: 1px solid var(--rc, var(--line-2)); font-size: 12px; color: var(--smoke); }
.chip.on { border-color: var(--good); color: var(--good); }
.chip.bad { border-color: var(--danger); color: var(--danger); }
.bars { display: flex; align-items: flex-end; gap: 6px; height: 140px; padding-top: 8px; }
.bar { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; gap: 4px; }
.bar i { display: block; width: 100%; border-radius: 4px 4px 0 0; background: linear-gradient(180deg, var(--gold), var(--ember)); }
.bar span { font-size: 10px; color: var(--smoke-2); }
.wd-row { display: flex; flex-direction: column; gap: 6px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.pool-detail { padding: 8px 0; border-bottom: 1px solid var(--line); }
.pool-detail summary { cursor: pointer; font-size: 13.5px; }

/* ---------------------------------------------------------- bank */
.bank-hero { display: grid; grid-template-columns: 1fr; gap: 10px; padding: 16px; border-radius: 14px; margin-bottom: 12px; background: radial-gradient(ellipse at 15% 0%, #ffd23d22, transparent 55%), linear-gradient(135deg, #182642, #0f1a2e); border: 1px solid #ffd23d33; }
@media (min-width: 720px) { .bank-hero { grid-template-columns: repeat(3, 1fr); } }
.bank-hero > div { display: flex; flex-direction: column; gap: 2px; }
.bank-hero span { font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--smoke); font-weight: 700; }
.bank-hero b { font-family: var(--display); font-size: 28px; line-height: 1.05; }
.bank-hero b.sm { font-size: 16px; font-family: var(--body); }
.bank-hero b small { font-size: 14px; color: var(--smoke); font-family: var(--body); }
.bank-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 900px) { .bank-grid { grid-template-columns: 1fr 1fr; } .bank-ledger { grid-column: 1 / -1; } }

/* ---------------------------------------------------------- map */
.page.map { display: flex; flex-direction: column; min-height: 0; height: 100%; gap: 0; }
.page.map .page-head { flex-shrink: 0; display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; flex-wrap: wrap; }
.map-actions { display: flex; gap: 8px; }
.map-stage {
  /* Match Hoodcamp world grid 64×34 tiles — no letterbox around the art */
  position: relative;
  width: 100%;
  flex: 0 0 auto;
  aspect-ratio: 64 / 34;
  max-height: min(62dvh, 620px);
  border-radius: 14px 14px 0 0;
  overflow: hidden;
  border: 1px solid var(--line-2);
  border-bottom: none;
  background: #0a1428;
}
.map-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  -ms-interpolation-mode: nearest-neighbor;
}
.map-hud {
  position: relative;
  z-index: 2;
  flex-shrink: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: flex-end;
  padding: 10px 12px;
  border-radius: 0 0 14px 14px;
  background: rgba(8, 14, 24, 0.96);
  border: 1px solid #ffd23d33;
  border-top: 1px solid #ffd23d22;
}
.map-stat { display: flex; flex-direction: column; gap: 2px; min-width: 110px; }
.map-stat span { font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--smoke); font-weight: 700; }
.map-stat b { font-variant-numeric: tabular-nums; font-size: 15px; }
.map-stat b.bad { color: var(--danger); font-size: 12px; }
.map-balls { min-width: 160px; }
.map-ball-row { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.map-ball {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 2px 6px; border-radius: 6px; background: #0a1221; border: 1px solid var(--line-2);
  font-size: 12px; font-weight: 700; color: var(--ash);
}
.map-ball img { width: 18px; height: 18px; object-fit: contain; image-rendering: pixelated; }
.map-log {
  position: absolute; top: 10px; right: 10px; z-index: 2; width: min(220px, 46%);
  display: flex; flex-direction: column; gap: 4px; pointer-events: none;
}
.map-log-row {
  padding: 6px 8px; border-radius: 8px; font-size: 12px; font-weight: 700;
  background: rgba(8, 14, 24, 0.78); border: 1px solid #ffd23d44; color: var(--ash);
  animation: map-log-in 0.35s ease-out;
}
.map-log-row.catch { border-color: #ffd23d88; color: var(--gold); }
.map-log-row.item { border-color: #7cffb288; color: #7cffb2; }
@keyframes map-log-in {
  from { opacity: 0; transform: translateX(8px); }
  to { opacity: 1; transform: translateX(0); }
}
.page.map .page-head { margin-bottom: 8px; }
.page.map .map-stage { border: 2px solid #ffd23d33; border-bottom: none; box-shadow: inset 0 0 40px #0008; }
.page.map .map-hud { border: 2px solid #ffd23d33; border-top: 1px solid #ffd23d22; }
