/* CrackerCorp — neon HUD. Cyan = you/your actions, magenta = threats against
   you, amber = heat/warnings, purple = the Handler. Everything else neutral. */
:root {
  --bg: #06070b; --panel: #0e1119; --panel2: #14171f; --line: #1a1e2b;
  --text: #e8ecf4; --muted: #8a93a8; --dim: #4a5268;
  --cyan: #22e4ff; --magenta: #ff3d8b; --amber: #ffb547; --purple: #b69cff; --green: #3ddc84;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
  --disp: 'Unbounded', system-ui, sans-serif;
  --body: 'IBM Plex Sans', system-ui, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--bg); color: var(--text); font-family: var(--body); font-size: 14px;
  background-image: radial-gradient(circle at 30% 20%, #0f2230 0, transparent 640px), radial-gradient(#12151f 1px, transparent 1px);
  background-size: 100% 100%, 26px 26px; background-attachment: fixed;
  -webkit-font-smoothing: antialiased; overflow: hidden;
}
body::after { /* scanlines */
  content: ''; position: fixed; inset: 0; pointer-events: none; z-index: 5;
  background-image: repeating-linear-gradient(0deg, rgba(255,255,255,.016) 0, rgba(255,255,255,.016) 1px, transparent 1px, transparent 3px);
}
a { color: var(--cyan); text-decoration: none; } a:hover { color: #8ff1ff; }
button { font-family: var(--body); cursor: pointer; }
::-webkit-scrollbar { width: 10px; height: 10px; } ::-webkit-scrollbar-thumb { background: #20242f; border-radius: 5px; }
.mono { font-family: var(--mono); } .disp { font-family: var(--disp); }
.cut { clip-path: polygon(12px 0,100% 0,100% calc(100% - 12px),calc(100% - 12px) 100%,0 100%,0 12px); }
.muted { color: var(--muted); } .dim { color: var(--dim); }

/* ---- app shell ---- */
#app { height: 100vh; height: 100dvh; display: flex; flex-direction: column; }
.topbar {
  height: 60px; flex-shrink: 0; display: flex; align-items: center; gap: 20px; padding: 0 20px;
  border-bottom: 1px solid var(--line); background: rgba(11,16,14,.6); backdrop-filter: blur(6px); z-index: 4;
}
.logo { font-family: var(--disp); font-weight: 800; font-size: 18px; letter-spacing: 1px; white-space: nowrap;
  text-shadow: 2px 0 rgba(255,61,139,.55), -2px 0 rgba(34,228,255,.55); }
.topstat { display: flex; flex-direction: column; gap: 1px; align-items: flex-end; }
.topstat .k { font-family: var(--mono); font-size: 10px; letter-spacing: 1.5px; color: var(--muted); }
.topstat .v { font-family: var(--mono); font-weight: 700; font-size: 14px; }
.spacer { flex: 1; }
.season-chip { font-family: var(--mono); font-size: 12px; padding: 5px 12px; border: 1px solid #232838; background: var(--panel); display: flex; gap: 8px; }
.season-chip b { color: var(--cyan); }
.heatbar { width: 120px; display: flex; flex-direction: column; gap: 5px; }
.heatbar .row { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 10px; letter-spacing: 1.5px; }
.pips { display: grid; grid-template-columns: repeat(10, 1fr); gap: 3px; }
.pips i { height: 6px; background: #232838; display: block; }
.pips i.on { background: var(--amber); }

.body { flex: 1; display: flex; min-height: 0; }
.nav { width: 76px; flex-shrink: 0; display: flex; flex-direction: column; gap: 4px; padding: 14px 8px; border-right: 1px solid var(--line); overflow-y: auto; }
.nav button { width: 100%; height: 58px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  background: transparent; border: 1px solid transparent; color: var(--muted); font-size: 9px; letter-spacing: .5px; border-radius: 8px; position: relative; }
.nav button svg { width: 20px; height: 20px; }
.nav button.active { color: var(--cyan); background: linear-gradient(180deg, rgba(34,228,255,.12), transparent); border-color: #1e3a44; }
.nav button:hover { color: var(--text); }
.nav .badge { position: absolute; top: 6px; right: 12px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px;
  background: var(--magenta); color: #06070b; font-family: var(--mono); font-size: 10px; font-weight: 700; display: flex; align-items: center; justify-content: center; }

.main { flex: 1; overflow-y: auto; padding: 24px; min-width: 0; }
.screen-title { font-family: var(--disp); font-weight: 700; font-size: 24px; margin: 0 0 4px; letter-spacing: -.3px; }
.screen-sub { color: var(--muted); margin: 0 0 20px; font-size: 13px; }

/* ---- panels / cards ---- */
.panel { background: var(--panel); border: 1px solid var(--line); padding: 18px; }
.grid { display: grid; gap: 16px; }
.cols-2 { grid-template-columns: 1fr 1fr; } .cols-3 { grid-template-columns: repeat(3, 1fr); }
.stat { display: flex; flex-direction: column; gap: 6px; }
.stat .k { font-family: var(--mono); font-size: 11px; letter-spacing: 1.5px; color: var(--muted); }
.stat .v { font-family: var(--disp); font-weight: 700; font-size: 24px; }
.tag { display: inline-flex; align-items: center; gap: 5px; padding: 3px 8px; font-family: var(--mono); font-size: 11px; border-radius: 3px; }
.tag.cy { background: rgba(34,228,255,.12); color: var(--cyan); } .tag.mg { background: rgba(255,61,139,.12); color: #ff7aad; }
.tag.am { background: rgba(255,181,71,.14); color: var(--amber); } .tag.dim { background: #171b24; color: var(--muted); }

.btn { height: 40px; padding: 0 18px; border: 1px solid #2c3244; background: transparent; color: var(--text); font-size: 13px; font-weight: 500; border-radius: 8px; }
.btn:hover { border-color: var(--cyan); }
.btn.primary { background: var(--cyan); color: #06070b; border: none; font-weight: 700; }
.btn.primary:hover { filter: brightness(1.1); }
.btn.danger { background: var(--magenta); color: #06070b; border: none; font-weight: 700; }
.btn.sm { height: 32px; padding: 0 12px; font-size: 12px; }
.btn:disabled { opacity: .4; cursor: not-allowed; }
.btn.block { width: 100%; }
input, select { height: 40px; padding: 0 12px; background: #0a0c12; border: 1px solid var(--line); color: var(--text); font-family: var(--mono); font-size: 13px; border-radius: 8px; }
input:focus, select:focus { outline: none; border-color: var(--cyan); }

/* progress */
.bar { height: 8px; background: #16211d; border-radius: 4px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--cyan); }
.bar.am > i { background: var(--amber); } .bar.mg > i { background: var(--magenta); }

/* the breach ring hero */
.hero { display: flex; gap: 40px; align-items: center; flex-wrap: wrap; }
.ring { flex-shrink: 0; }
.list { display: flex; flex-direction: column; gap: 10px; }
.rowcard { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: var(--panel); border: 1px solid var(--line); }
.rowcard.alert { background: #1a1214; border-color: #3a2226; }
.rowcard .grow { flex: 1; min-width: 0; }
.rowcard .t { font-weight: 600; } .rowcard .s { font-size: 12px; color: var(--muted); }

/* network target cards — responsive grid, replaces the old wide table so Scan/Crack
 * are always reachable on a phone (no horizontal scroll). */
.target-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 10px; margin-top: 4px; }
.tcard { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 14px; display: flex; flex-direction: column; gap: 10px; transition: border-color .12s, box-shadow .12s; }
.tcard.scanned { border-color: #26303f; }
.tcard.goal { border-color: #3a2230; background: linear-gradient(180deg, rgba(255,61,139,.06), transparent); }
.tcard.owned { opacity: .55; }
.tcard:hover { border-color: #2c3648; }
.tc-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.tc-name { display: flex; align-items: center; gap: 8px; min-width: 0; }
.tc-name b { font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tc-ip { font-size: 12px; margin-top: -4px; }
.tc-stats { display: flex; gap: 6px; background: var(--panel2); border-radius: 8px; padding: 8px 4px; }
.tc-stat { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; border-right: 1px solid var(--line); }
.tc-stat:last-child { border-right: none; }
.tc-k { font-family: var(--mono); font-size: 9px; letter-spacing: 1.5px; color: var(--dim); }
.tc-v { font-size: 14px; font-weight: 600; }
.tc-actions { display: flex; gap: 8px; }
.tc-actions .btn { flex: 1; height: 40px; justify-content: center; }
.tc-actions .tag { align-self: center; }
.dotc { width: 8px; height: 8px; border-radius: 4px; flex-shrink: 0; }
.dotc.cy { background: var(--cyan); box-shadow: 0 0 8px var(--cyan); } .dotc.mg { background: var(--magenta); box-shadow: 0 0 8px var(--magenta); } .dotc.am { background: var(--amber); }

.hexlog { font-family: var(--mono); font-size: 11px; line-height: 1.7; color: #2f5867; max-height: 90px; overflow: hidden; }
.hexlog .hot { color: var(--cyan); }

table { width: 100%; border-collapse: collapse; font-size: 13px; }
th { text-align: left; font-family: var(--mono); font-size: 10px; letter-spacing: 1.5px; color: var(--muted); font-weight: 500; padding: 8px 10px; border-bottom: 1px solid var(--line); }
td { padding: 10px; border-bottom: 1px solid #12151d; }
tr:hover td { background: #10131a; }

.section-label { font-family: var(--mono); font-size: 11px; letter-spacing: 2px; color: var(--muted); margin: 22px 0 10px; }

/* skill tree */
.tree { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.branch h4 { font-family: var(--disp); font-size: 14px; margin: 0 0 10px; }
.skill { padding: 12px; border: 1px solid var(--line); background: var(--panel); margin-bottom: 8px; }
.skill .n { font-weight: 600; display: flex; justify-content: space-between; }
.skill .d { font-size: 12px; color: var(--muted); margin: 4px 0 8px; }
.pipsrow { display: flex; gap: 3px; } .pipsrow i { width: 16px; height: 6px; background: #232838; } .pipsrow i.on { background: var(--cyan); }
.branch.infiltration h4 { color: var(--cyan); } .branch.ghost h4 { color: var(--purple); }
.branch.syndicate h4 { color: var(--amber); } .branch.sentinel h4 { color: var(--green); }

/* market chart */
.chart { width: 100%; height: 140px; display: block; }

/* login */
.login { margin: auto; max-width: 420px; text-align: center; padding: 40px 24px; }
.login .logo { font-size: 30px; display: block; margin-bottom: 8px; }
.login p { color: var(--muted); line-height: 1.6; }
.login form { display: flex; gap: 10px; margin-top: 20px; }
.login input { flex: 1; }

/* handler */
.handler { display: flex; gap: 14px; padding: 16px; background: #121015; border: 1px solid #3a2f4a; }
.handler .av { width: 40px; height: 40px; flex-shrink: 0; background: #1c1630; color: var(--purple); display: flex; align-items: center; justify-content: center; font-family: var(--disp); font-weight: 800; }
.handler .who { color: var(--purple); font-weight: 600; font-family: var(--mono); font-size: 12px; letter-spacing: 1px; }
.handler p { margin: 6px 0 0; line-height: 1.5; }

/* toasts */
#toasts { position: fixed; bottom: 20px; right: 20px; display: flex; flex-direction: column; gap: 8px; z-index: 50; max-width: 340px; }
.toast { padding: 12px 16px; background: var(--panel2); border-left: 3px solid var(--cyan); font-size: 13px; box-shadow: 0 6px 24px rgba(0,0,0,.5); animation: slideIn .18s ease; }
.toast.err { border-left-color: var(--magenta); } .toast.warn { border-left-color: var(--amber); }
@keyframes slideIn { from { transform: translateX(20px); opacity: 0; } }

/* modal / puzzle */
#modal-root:empty { display: none; }
.backdrop { position: fixed; inset: 0; background: rgba(3,4,7,.7); backdrop-filter: blur(3px); display: flex; align-items: center; justify-content: center; z-index: 60; }
.modal { width: 420px; max-width: 92vw; background: var(--panel2); border: 1px solid #2b4a5a; padding: 24px; }
.modal h3 { font-family: var(--disp); margin: 0 0 6px; }
.modal .prompt { font-family: var(--mono); background: #0a0c12; padding: 14px; border: 1px solid var(--line); margin: 14px 0; line-height: 1.5; }
.newsfeed { display: flex; flex-direction: column; gap: 8px; font-size: 13px; }
.newsfeed .t { display: flex; gap: 8px; } .newsfeed .ts { font-family: var(--mono); font-size: 11px; color: var(--dim); flex-shrink: 0; }

.training-banner { padding: 10px 16px; background: rgba(34,228,255,.08); border: 1px solid #1e3a44; color: var(--cyan); font-size: 13px; margin-bottom: 16px; }

/* mobile */
.mobile-only { display: none; }

/* Base bottom-tab styling MUST come before the media query below: same specificity,
 * so whichever is later wins. Declared first, the query's `display: grid` reveals it. */
.mobile-tab { display: none; position: fixed; bottom: 0; left: 0; right: 0; z-index: 40;
  grid-template-columns: repeat(5, 1fr); align-items: stretch;
  /* clear the phone's home indicator / browser chrome so the bar is never buried */
  height: calc(60px + env(safe-area-inset-bottom, 0px));
  padding-bottom: env(safe-area-inset-bottom, 0px);
  background: rgba(8,10,15,.97); border-top: 1px solid var(--line);
  box-shadow: 0 -10px 28px rgba(0,0,0,.55); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.mobile-tab button { background: none; border: none; border-top: 2px solid transparent; color: var(--muted);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  font-family: var(--mono); font-size: 10px; letter-spacing: .04em; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.mobile-tab button svg { width: 23px; height: 23px; }
.mobile-tab button.active { color: var(--cyan); border-top-color: var(--cyan); background: linear-gradient(180deg, rgba(34,228,255,.12), transparent); }
.mobile-tab button:active { color: var(--text); background: rgba(255,255,255,.05); }

/* phones in portrait (narrow) OR landscape (short) get the bottom tab instead of the side rail */
@media (max-width: 780px), (orientation: landscape) and (max-height: 540px) {
  .main { padding: 16px; padding-bottom: calc(80px + env(safe-area-inset-bottom, 0px)); }
  .nav { display: none; }
  .cols-2, .cols-3, .tree { grid-template-columns: 1fr; }
  .topbar { gap: 12px; padding: 0 14px; height: 54px; }
  .season-chip, .desktop-only { display: none; }
  .hero { gap: 20px; justify-content: center; }
  .mobile-tab { display: grid; }
  #toasts { left: 12px; right: 12px; bottom: calc(80px + env(safe-area-inset-bottom, 0px)); max-width: none; }
}

/* ---- Overclock: neon casino wheel ---- */
.oc-modal { position: relative; width: 430px; padding: 22px 24px 20px; border-color: #1e3a44; overflow: hidden;
  background: radial-gradient(circle at 50% 46%, rgba(15,40,56,.9) 0, rgba(20,23,31,0) 62%),
              radial-gradient(#1a2130 1px, transparent 1px) 0 0 / 18px 18px, var(--panel2); }
.oc-modal::after { content: ''; position: absolute; inset: 0; pointer-events: none; opacity: 0; }
.oc-modal.win::after { background: radial-gradient(circle at 50% 50%, rgba(34,228,255,.32), transparent 62%); animation: ocflash 1.2s ease-out; }
.oc-modal.lose::after { background: radial-gradient(circle at 50% 50%, rgba(255,61,139,.32), transparent 62%); animation: ocflash 1.2s ease-out; }
.oc-modal.lose { animation: ocshake .45s ease; }
@keyframes ocflash { 0% { opacity: 0; } 22% { opacity: 1; } 100% { opacity: 0; } }
.oc-head { display: flex; justify-content: space-between; align-items: center; }
.oc-proc { font-family: var(--disp); font-weight: 700; font-size: 17px; margin: 10px 0 8px; letter-spacing: -.2px; }
.oc-oddsbar { display: flex; height: 6px; border-radius: 3px; overflow: hidden; margin-top: 14px; background: #1a1e2b; }
.oc-oddsbar i { display: block; height: 100%; }
.oc-oddsbar .c { background: var(--cyan); box-shadow: 0 0 10px var(--cyan); }
.oc-oddsbar .b { background: var(--magenta); box-shadow: 0 0 10px var(--magenta); }
.oc-oddslbl { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 11px; margin-top: 6px; letter-spacing: .5px; }
.wheel-wrap { position: relative; width: min(300px, 74vw); aspect-ratio: 1; margin: 18px auto 2px; }
.wheel-bezel { position: absolute; inset: 0; }
.wheel-bezel svg { display: block; }
.wheel-bezel .bulb { fill: #3a2f1a; }
.wheel-wrap.idle .bulb { animation: breathe 2.4s ease-in-out infinite; }
.wheel-wrap.lit .bulb { animation: chase .96s linear infinite; }
.wheel-wrap.win .bulb { animation: flashCyan .3s steps(2) 7; }
.wheel-wrap.lose .bulb { animation: flashMag .3s steps(2) 7; }
@keyframes breathe { 50% { fill: #7a5c28; } }
@keyframes chase { 0%, 70% { fill: #3a2f1a; } 80% { fill: #ffe2a0; } 100% { fill: #3a2f1a; } }
@keyframes flashCyan { 50% { fill: #22e4ff; } }
@keyframes flashMag { 50% { fill: #ff3d8b; } }
.wheel { position: absolute; inset: 6.4%; border-radius: 50%; will-change: transform; transform-origin: 50% 50%;
  box-shadow: 0 0 0 1px #0b0d13, 0 0 40px rgba(34,228,255,.1); }
.wheel svg { display: block; transition: filter .35s; }
.wheel.spinning { animation: ocspin .4s linear infinite; }
.wheel.spinning svg { filter: blur(1.5px) saturate(1.35) brightness(1.15); }
.wheel.decel svg { filter: blur(.4px) saturate(1.15); }
@keyframes ocspin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
.wheel path.hit-good { fill: rgba(34,228,255,.3); animation: hitpulse .45s ease-in-out 7 alternate; }
.wheel path.hit-bad { fill: rgba(255,61,139,.3); animation: hitpulse .45s ease-in-out 7 alternate; }
@keyframes hitpulse { from { opacity: 1; } to { opacity: .4; } }
.wheel-pointer { position: absolute; top: -3.5%; left: 50%; transform: translateX(-50%); transform-origin: 50% 10px; z-index: 3; line-height: 0; }
.wheel-wrap.lit .wheel-pointer { animation: flick .08s linear infinite alternate; }
@keyframes flick { from { transform: translateX(-50%) rotate(-8deg); } to { transform: translateX(-50%) rotate(6deg); } }
.wheel-hub { position: absolute; top: 50%; left: 50%; width: 76px; height: 76px; transform: translate(-50%, -50%); z-index: 2;
  clip-path: polygon(25% 4%, 75% 4%, 100% 50%, 75% 96%, 25% 96%, 0 50%); background: linear-gradient(160deg, #ffe2a0, #ff9f1c 70%); }
.wheel-hub-in { position: absolute; inset: 3px; clip-path: polygon(25% 4%, 75% 4%, 100% 50%, 75% 96%, 25% 96%, 0 50%);
  background: radial-gradient(circle at 50% 28%, #1a1f2b, #06070b 70%);
  display: flex; flex-direction: column; align-items: center; justify-content: center; }
.wheel-hub-in b { font-family: var(--disp); font-weight: 800; font-size: 18px; color: var(--amber); text-shadow: 0 0 12px rgba(255,181,71,.65); line-height: 1; }
.wheel-hub-in span { font-family: var(--mono); font-size: 7px; letter-spacing: 1.6px; color: var(--muted); margin-top: 4px; }
.oc-result { text-align: center; font-family: var(--disp); font-size: 36px; font-weight: 800; min-height: 46px; margin-top: 10px; letter-spacing: -.5px; }
.oc-result.good { color: var(--cyan); text-shadow: 2px 0 rgba(255,61,139,.45), -2px 0 rgba(34,228,255,.85), 0 0 26px rgba(34,228,255,.55); animation: ocpop .45s cubic-bezier(.2,1.6,.4,1); }
.oc-result.bad { color: var(--magenta); text-shadow: 2px 0 rgba(34,228,255,.4), -2px 0 rgba(255,61,139,.9), 0 0 26px rgba(255,61,139,.55); animation: ocpop .45s cubic-bezier(.2,1.6,.4,1); }
.oc-sub { text-align: center; font-family: var(--mono); font-size: 11px; letter-spacing: 2px; color: var(--muted); min-height: 16px; }
.oc-sub.good { color: var(--cyan); } .oc-sub.bad { color: #ff7aad; }
@keyframes ocpop { from { transform: scale(.4); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes ocshake { 0%, 100% { transform: translateX(0); } 20% { transform: translateX(-8px); } 40% { transform: translateX(7px); } 60% { transform: translateX(-5px); } 80% { transform: translateX(3px); } }
.btn-spin { flex: 1; height: 52px; border: none; border-radius: 10px; cursor: pointer; font-family: var(--mono); font-weight: 700; font-size: 15px; letter-spacing: 5px;
  color: #06070b; background: linear-gradient(90deg, #22e4ff, #9ff5ff 50%, #22e4ff); background-size: 200% 100%;
  box-shadow: 0 0 0 1px rgba(34,228,255,.55), 0 0 28px rgba(34,228,255,.38); animation: spinsheen 2.2s linear infinite; }
.btn-spin:hover { filter: brightness(1.08); }
.btn-spin:disabled { opacity: .6; cursor: default; animation: none; }
@keyframes spinsheen { to { background-position: -200% 0; } }
.oc-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; font-size: 12px; }
@media (prefers-reduced-motion: reduce) {
  .wheel.spinning { animation-duration: 1.4s; } .wheel.spinning svg, .wheel.decel svg { filter: none; }
  .wheel-wrap .bulb, .wheel-wrap.lit .wheel-pointer, .btn-spin { animation: none !important; }
}

/* ---- cosmetic themes (pure cosmetics — no gameplay effect) ---- */
body[data-theme="amber"] { --cyan: #ffb547; --magenta: #ff5f57; --amber: #ffd27a; --purple: #f0c78a; --text: #f3e6cf; --muted: #a8977b; }
body[data-theme="amber"] .logo { text-shadow: 2px 0 rgba(255,95,87,.5), -2px 0 rgba(255,181,71,.5); }
body[data-theme="phosphor"] { --cyan: #3ddc84; --magenta: #ff6b6b; --amber: #d9f99d; --purple: #86efac; --text: #d7f5e3; --muted: #7fa48e; }
body[data-theme="phosphor"] .logo { text-shadow: 2px 0 rgba(255,107,107,.45), -2px 0 rgba(61,220,132,.55); }
.oc-result.idle { color: #283042; font-size: 26px; letter-spacing: 10px; }
.oc-result.idle.rolling { color: #3d4a63; animation: rollblink .5s steps(2) infinite; }
@keyframes rollblink { 50% { color: #6b7a99; } }

/* ---- live status strip (progress on every screen) ---- */
.livestrip { flex-shrink: 0; display: flex; gap: 10px; padding: 8px 14px; border-bottom: 1px solid var(--line);
  background: rgba(10,13,18,.75); overflow-x: auto; align-items: center; }
.live-item { display: flex; align-items: center; gap: 8px; min-width: 200px; max-width: 300px; padding: 6px 10px; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; }
.live-item.alert { border-color: #3a2226; background: #160f11; }
.live-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.live-lbl { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.live-lbl span:first-child { overflow: hidden; text-overflow: ellipsis; }
.live-btn { width: 26px; height: 26px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; background: transparent; border: 1px solid var(--line); border-radius: 6px; color: var(--muted); cursor: pointer; font-size: 12px; }
.live-btn:hover { color: var(--text); border-color: var(--cyan); }

/* ---- tutorial: highlight where to go ---- */
.nav button.pulse { color: var(--cyan); animation: navpulse 1.3s ease-in-out infinite; }
@keyframes navpulse { 0%,100% { box-shadow: 0 0 0 0 rgba(34,228,255,.5); } 50% { box-shadow: 0 0 0 4px rgba(34,228,255,0); background: rgba(34,228,255,.1); } }
.tut-banner { display: flex; gap: 12px; align-items: center; padding: 12px 16px; margin-bottom: 16px; border-radius: 10px;
  background: linear-gradient(90deg, rgba(182,156,255,.14), transparent); border: 1px solid #3a2f4a; }
.tut-banner .n { width: 28px; height: 28px; flex-shrink: 0; border-radius: 14px; background: #1c1630; color: var(--purple); display: flex; align-items: center; justify-content: center; font-weight: 700; font-family: var(--mono); }
.tut-banner .step { color: var(--purple); font-family: var(--mono); font-size: 11px; letter-spacing: 1px; }
.tut-banner .hint { font-size: 13px; }
@media (prefers-reduced-motion: reduce) { .nav button.pulse { animation: none; background: rgba(34,228,255,.12); } }

/* ---- menu grid (mobile) + settings ---- */
.menu-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.menu-tile { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 18px 8px; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; color: var(--text); cursor: pointer; font-size: 12px; }
.menu-tile:hover { border-color: var(--cyan); color: var(--cyan); }
.menu-tile svg { width: 22px; height: 22px; }
.theme-row { display: flex; gap: 10px; flex-wrap: wrap; }
.theme-swatch { display: flex; align-items: center; gap: 8px; padding: 8px 12px; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; color: var(--text); cursor: pointer; font-size: 13px; }
.theme-swatch.on { border-color: var(--cyan); }
.sw-dots { display: inline-flex; gap: 3px; }
.sw-dots i { width: 10px; height: 10px; border-radius: 5px; }
.theme-swatch.neon .sw-dots i:nth-child(1) { background: #22e4ff; } .theme-swatch.neon .sw-dots i:nth-child(2) { background: #ff3d8b; } .theme-swatch.neon .sw-dots i:nth-child(3) { background: #ffb547; }
.theme-swatch.amber .sw-dots i:nth-child(1) { background: #ffb547; } .theme-swatch.amber .sw-dots i:nth-child(2) { background: #ff5f57; } .theme-swatch.amber .sw-dots i:nth-child(3) { background: #ffd27a; }
.theme-swatch.phosphor .sw-dots i:nth-child(1) { background: #3ddc84; } .theme-swatch.phosphor .sw-dots i:nth-child(2) { background: #ff6b6b; } .theme-swatch.phosphor .sw-dots i:nth-child(3) { background: #d9f99d; }

/* ---- xp bar + locked skills ---- */
.xpwrap { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.xpwrap .bar { flex: 1; }
.skill.locked { opacity: .5; }
.skill .lockmsg { font-size: 11px; color: var(--amber); margin-top: 6px; }
.skill .lockmsg svg { width: 12px; height: 12px; vertical-align: -2px; }

/* ---- action buttons: icon + press/working feel ---- */
.btn.act { display: inline-flex; align-items: center; gap: 6px; }
.btn.act svg { width: 14px; height: 14px; }
.btn.act:active { transform: translateY(1px) scale(.98); }
.btn { transition: border-color .12s, background .12s, transform .06s, filter .12s; }
.btn.primary:active { filter: brightness(.92); }
tr.unscanned td { opacity: .78; }
tr.unscanned:hover td { opacity: 1; }
