/* css/game.css — Silicon Pulse: Overclock Tycoon (Track B · Style #8 cyber_pcb_terminal · OLED Carbon)
 * STRICT INVARIANTS:
 *   - ZERO backdrop-filter: blur(...) anywhere!
 *   - Genuine Style #8 UI Vault 9-slice border-image across >= 20 UI regions
 *   - overflow: visible !important on buttons hosting .notify-badge; ellipsis ONLY on .btn-label
 *   - repeat(N, minmax(0, 1fr)) + min-width: 0 on all grids for 9-language overflow immunity
 */

:root {
  --bg-void: #04070A;
  --bg-dock: #060A0F;
  --bg-card: #0B1117;
  --bg-surface: #121B24;
  --slate-border: #254655;
  --slate-muted: #587F87;
  --cyber-teal: #63D3DC;
  --teal-accent: #48B3BC;
  --emerald-out: #46E08A;
  --cobalt-req: #5B9DFF;
  --amber-tok: #FFB23E;
  --gold-psu: #FFE066;
  --cryo-cyan: #4FD8FF;
  --thermal-hot: #FF7A2E;
  --crimson-rej: #FF4F4F;
  --violet-mem: #A98BFF;
  --prestige-param: #C77DFF;
  --text-bright: #F0FAF7;
  --text-dim: #A6C2CE;
  --ink-dark: #05100C;

  --font-display: 'Chakra Petch', 'Russo One', 'Segoe UI', sans-serif;
  --font-hero: 'Russo One', 'Chakra Petch', 'Segoe UI', sans-serif;
  --font-num: 'JetBrains Mono', 'Chakra Petch', 'Consolas', monospace;
  --font-body: 'Exo 2', 'Chakra Petch', 'Segoe UI', system-ui, sans-serif;

  /* UI Vault Contract v2.2 Auto-Sync Tokens */
  --tb-slot-style: cyber_pcb_terminal;
  --tb-slot-shape: chamfer;
  --tb-slot-radius: 0px;
  --tb-slot-chamfer: 8px;
  --tb-slot-inset: 2px 2px 2px 2px;
  --tb-slot-palette: emerald;
  --tb-slot-mode: lightning_slot;
  --tb-slot-daylight: 0;
  --tb-slot-z: 3;
}

*, *::before, *::after {
  box-sizing: border-box;
  user-select: none;
  -webkit-user-drag: none;
}

html, body {
  margin: 0;
  padding: 0;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  background: var(--bg-void);
  color: var(--text-bright);
  font-family: var(--font-body);
  font-size: 13.5px;
  line-height: 1.24;
}

.hidden {
  display: none !important;
}

/* =========================================================================
 * STYLE #8 CYBER_PCB_TERMINAL 9-SLICE CHROME & BUTTONS (>= 20 REGIONS)
 * ========================================================================= */
button {
  font-family: var(--font-display);
  cursor: pointer;
  position: relative;
  overflow: visible !important;
  background: transparent;
  color: var(--text-bright);
  transition: transform 0.1s ease, filter 0.12s ease;
}

button:hover:not(:disabled) {
  filter: brightness(1.08) drop-shadow(0 3px 0 rgba(0, 0, 0, 0.55));
}

button:active:not(:disabled) {
  transform: translateY(2px);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.68;
}

.btn-label {
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  vertical-align: middle;
}

.btn-9slice {
  border-style: solid;
  border-color: transparent;
  background: transparent;
  border-radius: 0;
  box-shadow: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 14px;
  line-height: 1.15;
  letter-spacing: 0.03em;
  min-height: 40px;
  padding: 2px 10px;
}

.btn-primary-9s {
  border-width: 10px 11px 10px 11px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/btn_primary.png') 41 39 40 40 fill / 10px 11px 10px 11px / 0 stretch;
  background-color: #32E44E;
  background-clip: padding-box;
  color: #04120A;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.34);
  font-weight: 800;
}

.btn-alt-9s {
  border-width: 10px 11px 10px 11px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/btn_secondary.png') 45 43 42 43 fill / 10px 11px 10px 11px / 0 stretch;
  background-color: #1CD2DC;
  background-clip: padding-box;
  color: #041218;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.34);
  font-weight: 800;
}

.btn-secondary-9s {
  border-width: 10px 11px 10px 11px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/btn_secondary.png') 45 43 42 43 fill / 10px 11px 10px 11px / 0 stretch;
  background-color: #1CD2DC;
  background-clip: padding-box;
  color: #041218;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.34);
  font-weight: 800;
}

.btn-danger-9s {
  border-width: 10px 11px 10px 11px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/btn_danger.png') 39 39 36 38 fill / 10px 11px 10px 11px / 0 stretch;
  background-color: #D92629;
  background-clip: padding-box;
  color: #FFFFFF;
  text-shadow: 0 2px 0 #1A0406;
  font-weight: 800;
}

.btn-disabled-9s,
.btn-9slice:disabled {
  border-width: 9px 10px 9px 10px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/btn_disabled.png') 36 36 36 37 fill / 9px 10px 9px 10px / 0 stretch;
  background-color: #3A434F;
  background-clip: padding-box;
  color: #DCE8F2;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.85);
}

/* Chamfered Style #8 PCB Terminal Buttons (overflow: visible preserved, 0 clip-path clipping badges!) */
.btn-pcb {
  border-style: solid;
  border-color: transparent;
  border-width: 7px 8px 7px 8px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/frame_subpanel.png') 73 73 76 73 fill / 7px 8px 7px 8px / 0 stretch;
  background-color: #0A141E;
  background-clip: padding-box;
  color: var(--text-bright);
  padding: 2px 8px;
  min-height: 34px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  overflow: visible !important;
}

.btn-pcb.active {
  border-width: 7px 9px 9px 9px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/tab_active.png') 25 36 44 31 fill / 7px 9px 9px 9px / 0 stretch;
  background-color: #0D2024;
  background-clip: padding-box;
  color: var(--emerald-out);
}

.btn-pcb.ready-pulse {
  border-width: 8px 9px 8px 9px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/btn_primary.png') 41 39 40 40 fill / 8px 9px 8px 9px / 0 stretch;
  background-color: #32E44E;
  background-clip: padding-box;
  color: #04120A;
  font-weight: 800;
}

/* Red-Dot Notification Badge (NEVER clipped!) */
.notify-badge {
  position: absolute;
  top: -7px;
  right: -7px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #FF3B4E;
  border: 2px solid #FFFFFF;
  z-index: 35;
  pointer-events: none;
  animation: badgePulse 1.4s infinite ease-in-out;
}

@keyframes badgePulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.22); }
}

.kbd-tag {
  display: inline-block;
  padding: 1px 5px;
  font-family: var(--font-num);
  font-size: 13px;
  font-weight: 700;
  background: rgba(4, 10, 15, 0.92);
  color: var(--cyber-teal);
  border: 1px solid rgba(99, 211, 220, 0.52);
  flex-shrink: 0;
}

/* =========================================================================
 * PILLAR 1: HEROIC NO-BOX TITLE SCREEN (0 BOXED_LOGIN_TITLE_SCREEN)
 * ========================================================================= */
#title-screen {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: #020509 url('../assets/art/title_bg.jpg') center center / cover no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
}

#title-screen::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 42%, rgba(4, 12, 18, 0.28) 0%, rgba(4, 8, 13, 0.68) 62%, rgba(2, 5, 9, 0.90) 100%),
    linear-gradient(180deg, rgba(4, 7, 10, 0.45) 0%, rgba(4, 7, 10, 0.12) 45%, rgba(4, 7, 10, 0.76) 100%);
  pointer-events: none;
}

.title-top-bar {
  position: absolute;
  top: 18px;
  right: 22px;
  z-index: 5;
  display: flex;
  align-items: center;
  gap: 8px;
}

.lang-pill-select {
  background: #081119;
  color: var(--emerald-out);
  border: 1.5px solid var(--emerald-out);
  padding: 6px 10px;
  font-family: var(--font-num);
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
}

/* Strictly NO solid box or border around Title Hero Stage! */
.title-hero-stage {
  position: relative;
  z-index: 4;
  width: min(1160px, 94vw);
  padding: 12px 18px;
  background: transparent !important;
  border: none !important;
  border-image: none !important;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
}

#title-hero-showcase {
  width: 188px;
  height: 188px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 12px 24px rgba(0, 0, 0, 0.82)) drop-shadow(0 0 22px rgba(70, 224, 138, 0.42));
}

#title-hero-img {
  width: 168px;
  height: 168px;
  object-fit: contain;
}

.game-logo-title {
  margin: 0;
  font-family: var(--font-hero);
  font-style: italic;
  font-size: clamp(52px, 4.35vw, 68px);
  line-height: 1.05;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #FFFFFF;
  -webkit-text-stroke: 2px #03080D;
  text-shadow:
    0 5px 0 #040910,
    0 10px 24px rgba(0, 0, 0, 0.92),
    0 0 28px rgba(70, 224, 138, 0.55),
    0 0 54px rgba(99, 211, 220, 0.35);
}

.game-logo-sub {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(15px, 1.35vw, 20px);
  color: var(--emerald-out);
  letter-spacing: 0.10em;
  text-transform: uppercase;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.95), 0 0 14px rgba(70, 224, 138, 0.38);
}

.title-loader-wrap {
  width: min(460px, 84%);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.title-bar-track {
  width: 100%;
  height: 22px;
  border-style: solid;
  border-color: transparent;
  border-width: 5px 9px 6px 9px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/bar_track.png') 28 47 56 48 fill / 5px 9px 6px 9px / 0 stretch;
  overflow: hidden;
}

#title-load-fill {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, var(--cyber-teal), var(--emerald-out));
  transition: width 0.12s linear;
}

.title-load-meta {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-num);
  font-size: 13px;
  font-weight: 700;
  color: var(--text-bright);
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.92);
}

.title-cta-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 8px;
}

#btn-title-play {
  min-width: 256px;
  min-height: 62px;
  padding: 6px 28px;
  font-size: clamp(20px, 1.65vw, 25px);
  letter-spacing: 0.08em;
}

/* =========================================================================
 * MAIN 16:9 COMMAND TERMINAL (CENTER PCB >= 66% VIEWPORT, SIDEBARS <= 27%)
 * ========================================================================= */
#game-shell {
  width: 100vw;
  height: 100vh;
  display: grid;
  grid-template-rows: 46px minmax(0, 1fr);
  background: var(--bg-void);
}

/* 1. TOP TELEMETRY COMMAND STRIP (STRICTLY NOWRAP AT 1080p & 720p) */
#top-strip {
  max-width: 100vw;
  box-sizing: border-box;
  background: linear-gradient(180deg, #0B131B 0%, #05080C 100%);
  border-bottom: 1.5px solid #1E3D4B;
  padding: 0 8px;
  display: flex;
  flex-wrap: nowrap !important;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  z-index: 25;
}

.top-group {
  display: flex;
  flex-wrap: nowrap !important;
  align-items: center;
  gap: 5px;
  min-width: 0;
}

.site-tabs {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 3px;
}

.site-pill {
  padding: 3px 6px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  background: #081018;
  border: 1px solid #1E3240;
  color: var(--text-dim);
  max-width: 104px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Show active & adjacent unlocked sites cleanly so top-strip stays spacious across 9 langs */
#top-strip .site-pill.locked {
  display: none;
}

.site-pill.current {
  border-style: solid;
  border-color: transparent;
  border-width: 5px 8px 6px 8px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/tab_active.png') 25 36 44 31 fill / 5px 8px 6px 8px / 0 stretch;
  color: var(--emerald-out);
  max-width: 132px;
}

.wallet-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 8px;
  border-style: solid;
  border-color: transparent;
  border-width: 6px 8px 6px 8px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/hud_pill.png') 28 35 26 34 fill / 6px 8px 6px 8px / 0 stretch;
  min-height: 34px;
  font-family: var(--font-num);
  font-variant-numeric: tabular-nums;
  overflow: visible !important;
}

.wallet-pill img {
  width: 22px;
  height: 22px;
  object-fit: contain;
  flex-shrink: 0;
}

.wallet-val {
  font-weight: 700;
  font-size: 13.5px;
  line-height: 1.05;
  color: #FFFFFF;
}

.wallet-sub {
  font-size: 13px;
  line-height: 1.05;
  color: var(--emerald-out);
}

.bn-badge {
  padding: 2px 9px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  border-style: solid;
  border-color: transparent;
  border-width: 6px 8px 6px 8px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/hud_pill.png') 28 35 26 34 fill / 6px 8px 6px 8px / 0 stretch;
  color: var(--emerald-out);
  white-space: nowrap;
}

.bn-badge.warn {
  color: var(--amber-tok);
}

.bn-badge.crit {
  color: var(--crimson-rej);
}

.icon-sm {
  width: 18px;
  height: 18px;
  object-fit: contain;
  flex-shrink: 0;
}

/* 2. THREE-COLUMN WORKSPACE (220px + 1fr + 314px = 534px = 27.8% sidebars -> 72.2% center!) */
#workspace-grid {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr) 314px;
  width: 100%;
  height: 100%;
  min-height: 0;
}

/* LEFT TELEMETRY & OSCILLOSCOPE DOCK */
#left-dock {
  background: var(--bg-dock);
  border-right: 1.5px solid #1C3846;
  padding: 7px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  overflow-y: auto;
  min-height: 0;
}

.dock-section-hdr {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 12.5px;
  letter-spacing: 0.04em;
  color: var(--cyber-teal);
  text-transform: uppercase;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

#rig-code-badge {
  white-space: nowrap;
  flex-shrink: 0;
  font-family: var(--font-num);
}

.gauge-list {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.gauge-card {
  border-style: solid;
  border-color: transparent;
  border-width: 6px 7px 6px 7px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/frame_subpanel.png') 73 73 76 73 fill / 6px 7px 6px 7px / 0 stretch;
  background-color: #09121A;
  background-clip: padding-box;
  padding: 2px 4px;
}

.gauge-top {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-num);
  font-size: 12px;
  margin-bottom: 3px;
  gap: 1px 4px;
}

.gauge-name {
  color: var(--text-dim);
  flex: 1 1 auto;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.15;
}

.gauge-num {
  color: #FFFFFF;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
  margin-left: auto;
  white-space: nowrap;
}

.gauge-bar-bg {
  width: 100%;
  height: 7px;
  background: #04080C;
  border: 1px solid #19313F;
  overflow: hidden;
}

.gauge-bar-fill {
  height: 100%;
  width: 0%;
  transition: width 0.14s linear;
}

#osc-panel {
  border-style: solid;
  border-color: transparent;
  border-width: 9px 10px 10px 10px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/frame_subpanel.png') 73 73 76 73 fill / 9px 10px 10px 10px / 0 stretch;
  background-color: #09121A;
  background-clip: padding-box;
  padding: 2px 3px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

#osc-canvas {
  width: 100%;
  height: 78px;
  display: block;
  background: #04070A;
  border: 1px solid #172E3B;
}

.osc-legend {
  display: flex;
  flex-wrap: nowrap;
  justify-content: space-between;
  align-items: center;
  gap: 6px;
  font-family: var(--font-num);
  font-size: 12px;
  font-weight: 700;
  color: var(--text-dim);
  white-space: nowrap;
}

.osc-legend span {
  white-space: nowrap;
}

#advisor-box {
  border-style: solid;
  border-color: transparent;
  border-width: 10px 10px 11px 10px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/frame_subpanel.png') 73 73 76 73 fill / 10px 10px 11px 10px / 0 stretch;
  background-color: #09121A;
  background-clip: padding-box;
  padding: 3px 4px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: auto;
}

.advisor-msg {
  font-size: 13px;
  color: #E8F6F2;
  line-height: 1.28;
}

.advisor-preview {
  font-family: var(--font-num);
  font-size: 13px;
  color: var(--emerald-out);
  font-weight: 700;
  padding-top: 4px;
  border-top: 1px solid rgba(99, 211, 220, 0.25);
}

/* CENTER INTERACTIVE 16:9 PCB STAGE (>= 66% VIEWPORT) */
#center-stage {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto auto auto;
  background: var(--bg-void);
  min-width: 0;
  min-height: 0;
  position: relative;
}

#canvas-wrap {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 260px;
  overflow: hidden;
}

#pcb-canvas {
  width: 100%;
  height: 100%;
  display: block;
}

#objective-banner {
  position: absolute;
  top: 10px;
  left: 12px;
  border-style: solid;
  border-color: transparent;
  border-width: 7px 10px 7px 10px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/hud_pill.png') 28 35 26 34 fill / 7px 10px 7px 10px / 0 stretch;
  padding: 2px 8px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13.5px;
  color: #FFFFFF;
  pointer-events: none;
  z-index: 6;
}

/* ACTIVE TACTICAL COMMANDER BAR [1 / 2 / 3 / 4] (v1.5, 0 backdrop-filter) */
#tactical-bar {
  background: #050A0F;
  border-top: 1px solid #1C3847;
  padding: 3px 8px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr)) auto;
  gap: 6px;
  align-items: center;
}

.tac-skill-btn {
  min-height: 40px;
  padding: 2px 6px;
  gap: 5px;
}

.tac-ring-wrap {
  position: relative;
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.tac-cd-ring {
  position: absolute;
  inset: 0;
  width: 32px;
  height: 32px;
  transform: rotate(-90deg);
  pointer-events: none;
}

.tac-ring-bg {
  fill: none;
  stroke: rgba(37, 70, 85, 0.72);
  stroke-width: 2.6;
}

.tac-ring-fg {
  fill: none;
  stroke-width: 2.8;
  stroke-linecap: round;
  stroke-dasharray: 97.4;
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 0.14s linear;
}

.tac-ic {
  width: 20px;
  height: 20px;
  object-fit: contain;
  position: relative;
  z-index: 2;
}

.tac-skill-btn.tac-aura-burst {
  animation: tacAuraPulse 0.42s ease-out;
}

@keyframes tacAuraPulse {
  0% { filter: brightness(1.45); transform: scale(1.03); }
  100% { filter: brightness(1); transform: scale(1); }
}

.tac-syn-pill {
  min-height: 38px;
  padding: 2px 8px;
  font-family: var(--font-num);
  font-size: 12.5px;
  color: var(--cyber-teal);
  white-space: nowrap;
}

.tac-syn-pill.syn-hot {
  color: var(--emerald-out);
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/tab_active.png') 25 36 44 31 fill / 7px 9px 9px 9px / 0 stretch;
}

/* ACTIVE OVERCLOCK COMMAND BAR [Q / W / E / R] */
#overclock-bar {
  background: #060B10;
  border-top: 1.5px solid #1C3947;
  padding: 4px 8px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr)) auto;
  gap: 6px;
  align-items: center;
}

.skill-btn {
  border-style: solid;
  border-color: transparent;
  border-width: 7px 8px 7px 8px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/frame_subpanel.png') 73 73 76 73 fill / 7px 8px 7px 8px / 0 stretch;
  padding: 2px 6px;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  text-align: left;
  min-width: 0;
}

.skill-btn .icon-sm {
  width: 26px;
  height: 26px;
}

.skill-btn.active-buff {
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/tab_active.png') 25 36 44 31 fill / 7px 8px 8px 8px / 0 stretch;
}

.skill-btn.cooldown {
  opacity: 0.72;
}

.feature-locked,
.is-locked,
.skill-btn.feature-locked,
.skill-btn:disabled {
  opacity: 0.52;
  filter: grayscale(0.75);
  cursor: not-allowed;
}

.skill-btn.feature-locked .skill-state,
.skill-btn:disabled .skill-state {
  color: #8FA8B8;
}

.skill-info {
  min-width: 0;
  flex: 1;
}

.skill-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  line-height: 1.12;
  color: #FFFFFF;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.skill-state {
  font-family: var(--font-num);
  font-size: 13px;
  color: var(--emerald-out);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* LIVE CLIENT REQUEST-STREAM TICKER */
#contract-ticker {
  background: #05080D;
  border-top: 1px solid #18303D;
  padding: 4px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.ticker-client {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.client-name-pill {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  color: var(--amber-tok);
  white-space: nowrap;
}

.tag-chip {
  padding: 1px 6px;
  font-family: var(--font-num);
  font-size: 13px;
  font-weight: 700;
  background: #0E2030;
  border: 1px solid #315B7C;
  color: var(--cobalt-req);
  white-space: nowrap;
}

.fit-chip {
  padding: 1px 6px;
  font-family: var(--font-num);
  font-size: 13px;
  font-weight: 700;
  background: rgba(70, 224, 138, 0.16);
  border: 1px solid var(--emerald-out);
  color: var(--emerald-out);
  white-space: nowrap;
}

.ticker-prog-wrap {
  flex: 1;
  min-width: 140px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ticker-prog-track {
  width: 100%;
  height: 11px;
  border-style: solid;
  border-color: transparent;
  border-width: 3px 6px 4px 6px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/bar_track.png') 28 47 56 48 fill / 3px 6px 4px 6px / 0 stretch;
  overflow: hidden;
}

#ticker-prog-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--cobalt-req), var(--emerald-out));
  transition: width 0.15s linear;
}

.ticker-prog-meta {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-num);
  font-size: 13px;
  color: var(--text-dim);
}

/* =========================================================================
 * RIGHT DOCK: 7 HARDWARE ICON RIG ROWS + CURRENT -> NEXT CHIPS (PILLAR 5)
 * ========================================================================= */
#right-dock {
  background: var(--bg-dock);
  border-left: 1.5px solid #1C3846;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  min-height: 0;
  overflow-x: hidden;
}

.dock-nav {
  display: grid;
  grid-template-columns: repeat(10, minmax(0, 1fr)) 26px;
  gap: 5px;
  padding: 7px 8px 6px 6px;
  background: #05090E;
  border-bottom: 1px solid #1A313F;
  min-width: 0;
}

.dock-nav > .dock-tab-btn:nth-child(1) { grid-column: 1 / span 3; }
.dock-nav > .dock-tab-btn:nth-child(2) { grid-column: 4 / span 4; }
.dock-nav > .dock-tab-btn:nth-child(3) { grid-column: 8 / span 4; }
.dock-nav > .dock-tab-btn:nth-child(4) { grid-column: 1 / span 3; }
.dock-nav > .dock-tab-btn:nth-child(5) { grid-column: 4 / span 3; }
.dock-nav > .dock-tab-btn:nth-child(6) { grid-column: 7 / span 4; }
#btn-tab-help { grid-column: 11 / span 1; padding: 2px 0; }

.dock-tab-btn {
  padding: 2px 5px;
  min-height: 30px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 12px;
  border-style: solid;
  border-color: transparent;
  border-width: 4px 4px 4px 4px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/frame_subpanel.png') 73 73 76 73 fill / 4px 4px 4px 4px / 0 stretch;
  background-color: #0A141E;
  background-clip: padding-box;
  color: var(--text-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  overflow: visible !important;
}

.dock-tab-btn .btn-label {
  display: block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.1;
}

.dock-tab-btn .notify-badge {
  top: -4px;
  right: -4px;
  width: 9px;
  height: 9px;
  border-width: 1.5px;
}

.dock-tab-btn.active {
  border-width: 4px 5px 5px 5px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/tab_active.png') 25 36 44 31 fill / 4px 5px 5px 5px / 0 stretch;
  background-color: #0D2024;
  background-clip: padding-box;
  color: var(--emerald-out);
}

#right-dock-body {
  padding: 6px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-height: 0;
}

.unit-selector-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding-bottom: 5px;
  border-bottom: 1px solid #172B38;
}

/* Lesson #34 + Pillar 5: Socketed Hardware Icon + Current -> Next Stat Diff + Icon Buy Button */
.upg-card {
  border-style: solid;
  border-color: transparent;
  border-width: 5px 6px 5px 6px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/frame_subpanel.png') 73 73 76 73 fill / 5px 6px 5px 6px / 0 stretch;
  background-color: #09121A;
  background-clip: padding-box;
  padding: 3px 4px;
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px;
}

.upg-card.recommended {
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/tab_active.png') 25 36 44 31 fill / 5px 6px 6px 6px / 0 stretch;
}

.upg-card.nope {
  animation: cardShake 0.25s linear;
}

@keyframes cardShake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}

.upg-hw-slot {
  position: relative;
  width: 40px;
  height: 40px;
  border-style: solid;
  border-color: transparent;
  border-width: 4px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/slot_tile.png') 30 32 32 31 fill / 4px / 0 stretch;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: visible;
}

.upg-hw-slot .kbd-tag {
  position: absolute;
  top: -5px;
  left: -5px;
  z-index: 3;
  font-size: 12px;
  line-height: 1.05;
  padding: 1px 4px;
}

.upg-hw-icon {
  width: 32px;
  height: 32px;
  object-fit: contain;
  display: block;
}

.upg-title-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 13px;
  color: #FFFFFF;
  min-width: 0;
}

.upg-title-row .btn-label {
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  line-height: 1.12;
}

.upg-lv {
  font-family: var(--font-num);
  font-size: 13px;
  color: var(--cyber-teal);
  margin-left: auto;
  flex-shrink: 0;
}

.upg-stat-chip {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  margin-top: 2px;
  padding: 1px 5px;
  background: rgba(6, 15, 22, 0.88);
  border: 1px solid rgba(70, 224, 138, 0.34);
  font-family: var(--font-num);
  font-size: 13px;
  font-weight: 700;
  color: var(--emerald-out);
  max-width: 100%;
  white-space: nowrap;
}

.upg-buy-btn {
  min-width: 66px;
  min-height: 36px;
  border-width: 7px 8px 7px 8px;
  padding: 2px 5px;
  font-family: var(--font-num);
  font-weight: 800;
  font-size: 13px;
  gap: 3px;
}

/* Keep compact RIG upgrade button hit-box stationary on press so mouse clicks never miss on mouseup */
.upg-buy-btn.tb-btn-juicy:active {
  translate: 0 0;
  scale: 1 1;
  filter: brightness(1.14);
}

.btn-cur-ic {
  width: 16px;
  height: 16px;
  object-fit: contain;
  flex-shrink: 0;
}

/* LIST CARDS FOR CONTRACTS, CREW, LAB, BENCHMARKS, PRESTIGE */
.meta-card {
  border-style: solid;
  border-color: transparent;
  border-width: 8px 9px 8px 9px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/frame_subpanel.png') 73 73 76 73 fill / 8px 9px 8px 9px / 0 stretch;
  background-color: #09121A;
  background-clip: padding-box;
  padding: 4px 6px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
}

.meta-card.equipped, .meta-card.active-row {
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/tab_active.png') 25 36 44 31 fill / 8px 9px 9px 9px / 0 stretch;
}

.meta-row-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 6px;
}

.meta-title-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 1;
  min-width: 0;
}

.meta-ic {
  width: 28px;
  height: 28px;
  object-fit: contain;
  flex-shrink: 0;
}

.meta-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 12.5px;
  line-height: 1.18;
  color: #FFFFFF;
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  overflow-wrap: break-word;
}

.crew-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 5px;
}

.crew-grid > * {
  min-width: 0;
  max-width: 100%;
}

/* =========================================================================
 * MODALS (STYLE #8 FRAME_MODAL + 60/25/15 VISUAL-FIRST ANTI-SAAS)
 * STRICT: ZERO backdrop-filter: blur(...)!
 * ========================================================================= */
.modal-scrim {
  position: fixed;
  inset: 0;
  z-index: 110;
  background: rgba(2, 5, 9, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

#offline-modal { z-index: 125; }
#reward-modal { z-index: 130; }
#coach-modal { z-index: 135; }

.modal-card {
  width: min(980px, 94vw);
  max-height: 90vh;
  border-style: solid;
  border-color: transparent;
  border-width: 20px 24px 26px 24px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/frame_modal.png') 62 75 85 74 fill / 20px 24px 26px 24px / 0 stretch;
  background-color: #070F17;
  background-clip: padding-box;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
}

.modal-card.modal-shop-wide {
  width: min(1140px, 95vw);
}

.modal-card.compact {
  width: min(560px, 92vw);
}

.modal-card.coach-wide {
  width: min(680px, 94vw);
}

.modal-header {
  border-bottom: 1.5px solid rgba(70, 224, 138, 0.32);
  padding: 8px 12px 10px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.modal-hdr-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.modal-hdr-ic {
  width: 34px;
  height: 34px;
  object-fit: contain;
  flex-shrink: 0;
}

.modal-title {
  margin: 0;
  font-family: var(--font-hero);
  font-style: italic;
  font-size: clamp(18px, 1.55vw, 24px);
  letter-spacing: 0.04em;
  color: #FFFFFF;
}

.btn-close-img {
  width: 38px;
  height: 38px;
  padding: 0;
  border: none;
  background: transparent;
  flex-shrink: 0;
}

.btn-close-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.modal-body {
  padding: 12px;
  overflow-y: auto;
  min-height: 0;
}

/* SHOP GRID: Symmetrical 5x2 = 10 Cards (0 orphan holes, >= 58% real art, <= 3-word titles) */
.shop-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.shop-grid > * {
  min-width: 0;
  max-width: 100%;
}

.shop-card {
  border-style: solid;
  border-color: transparent;
  border-width: 14px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/card_rare.png') 114 108 118 107 fill / 14px / 0 stretch;
  background-color: #0B1520;
  background-clip: padding-box;
  padding: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  position: relative;
}

.shop-card.rarity-common {
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/card_common.png') 112 107 112 101 fill / 14px / 0 stretch;
}

.shop-card.rarity-epic {
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/card_epic.png') 117 107 113 102 fill / 14px / 0 stretch;
}

.shop-card.rarity-legendary {
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/card_legendary.png') 115 108 117 107 fill / 14px / 0 stretch;
}

.shop-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  background: var(--amber-tok);
  color: #060C10;
  font-family: var(--font-num);
  font-weight: 800;
  font-size: 11px;
  padding: 2px 6px;
  z-index: 4;
}

.shop-art-wrap {
  width: 100%;
  height: 108px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at 50% 52%, rgba(70, 224, 138, 0.15) 0%, rgba(4, 9, 14, 0.45) 75%);
}

.shop-art-wrap img {
  width: 96px;
  height: 96px;
  object-fit: contain;
}

.shop-card-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 13.5px;
  color: #FFFFFF;
  width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.shop-buy-btn {
  width: 100%;
  margin-top: auto;
}

/* =========================================================================
 * SEASONS 1-5 & NOVA MASTERY + EVENT PASS TRACKS (60/25/15 ANTI-SAAS)
 * ========================================================================= */
.sm-hdr-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: nowrap;
  flex: 1;
  min-width: 0;
}

#seasons-modal .modal-title {
  font-size: clamp(15px, 1.3vw, 20px);
  white-space: nowrap;
  flex-shrink: 0;
}

.sm-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: nowrap;
  min-width: 0;
  flex: 1;
  justify-content: flex-end;
}

.sm-tabs .btn-pcb {
  border-width: 5px 6px 5px 6px;
  padding: 2px 6px;
  min-height: 30px;
  font-size: 12px;
  flex: 0 1 auto;
  min-width: 0;
  max-width: 118px;
}

.sm-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.sm-grid > * {
  min-width: 0;
  max-width: 100%;
}

.vf-card-portrait {
  border-style: solid;
  border-color: transparent;
  border-width: 14px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/card_rare.png') 114 108 118 107 fill / 14px / 0 stretch;
  background-color: #0B1520;
  background-clip: padding-box;
  padding: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  position: relative;
}

.vf-card-portrait.sm-common {
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/card_common.png') 112 107 112 101 fill / 14px / 0 stretch;
}

.vf-card-portrait.sm-epic {
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/card_epic.png') 117 107 113 102 fill / 14px / 0 stretch;
}

.vf-card-portrait.sm-legendary {
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/card_legendary.png') 115 108 117 107 fill / 14px / 0 stretch;
}

.sm-art-stage {
  position: relative;
  width: 100%;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: radial-gradient(circle at 50% 50%, rgba(99, 211, 220, 0.16) 0%, #070D14 80%);
}

.sm-art-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.30;
}

.sm-art-hero {
  position: relative;
  z-index: 2;
  width: 86px;
  height: 86px;
  object-fit: contain;
}

.sm-corner-tag {
  position: absolute;
  top: 4px;
  right: 4px;
  z-index: 3;
  background: rgba(5, 11, 17, 0.94);
  border: 1px solid var(--emerald-out);
  color: var(--emerald-out);
  font-family: var(--font-num);
  font-weight: 700;
  font-size: 11px;
  padding: 2px 6px;
}

.sm-heading {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 14px;
  color: #FFFFFF;
  width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sm-chips {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  background: #071018;
  border: 1px solid #244354;
  padding: 3px 9px;
  font-family: var(--font-num);
  font-weight: 700;
  font-size: 12.5px;
  color: var(--emerald-out);
  max-width: 100%;
}

.sm-chip-ic {
  width: 18px;
  height: 18px;
  object-fit: contain;
  flex-shrink: 0;
}

.sm-actions {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  margin-top: auto;
}

.sm-cta {
  flex: 1;
  min-width: 0;
  min-height: 36px;
  padding: 3px 6px;
  font-size: 12.5px;
}

/* EVENT PASSES VISUAL TRACK (Lesson #43) */
.pass-tabs-bar {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.pass-hero-banner {
  border-style: solid;
  border-color: transparent;
  border-width: 10px 12px 10px 12px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/frame_subpanel.png') 73 73 76 73 fill / 10px 12px 10px 12px / 0 stretch;
  padding: 8px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 12px;
}

.pass-hero-art {
  width: 68px;
  height: 68px;
  object-fit: contain;
  flex-shrink: 0;
}

.pass-prog-track {
  width: 100%;
  height: 16px;
  border-style: solid;
  border-color: transparent;
  border-width: 4px 8px 5px 8px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/bar_track.png') 28 47 56 48 fill / 4px 8px 5px 8px / 0 stretch;
  overflow: hidden;
  margin-top: 6px;
}

.pass-prog-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--cyber-teal), var(--emerald-out));
}

.pass-ms-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

/* PILLAR 6: SETTINGS ICON ROWS & CELEBRATION SUNBURST + 3-STAR SLAM */
.settings-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-style: solid;
  border-color: transparent;
  border-width: 8px 10px 8px 10px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/frame_subpanel.png') 73 73 76 73 fill / 8px 10px 8px 10px / 0 stretch;
  padding: 4px 8px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
}

.setting-actions-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.setting-lbl-wrap {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.setting-svg-ic {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.setting-toggle {
  min-width: 64px;
}

.setting-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

input[type="range"] {
  accent-color: var(--emerald-out);
  cursor: pointer;
  width: 132px;
}

.gift-input {
  background: #050A0F;
  border: 1.5px solid #254858;
  color: #FFFFFF;
  padding: 6px 10px;
  font-family: var(--font-num);
  font-size: 13px;
  width: 150px;
  user-select: text;
}

.giftcode-feedback {
  padding: 7px 11px;
  font-family: var(--font-num);
  font-size: 13px;
  font-weight: 700;
  border: 1.5px solid #254858;
  background: rgba(6, 15, 22, 0.94);
  color: #DCECF2;
  line-height: 1.3;
}

.giftcode-feedback.ok {
  border-color: #46E08A;
  background: rgba(12, 46, 32, 0.92);
  color: #7DF5B2;
}

.giftcode-feedback.err {
  border-color: #FF5E6C;
  background: rgba(54, 16, 22, 0.92);
  color: #FF9AA3;
}

.reward-celebration-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.reward-stars-row {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 10px;
}

.reward-stars-row img {
  width: 38px;
  height: 38px;
  object-fit: contain;
}

.reward-stars-row img.star-mid {
  width: 50px;
  height: 50px;
  transform: translateY(-4px);
}

.reward-hero-stage {
  position: relative;
  width: 148px;
  height: 148px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.reward-sunburst {
  position: absolute;
  inset: -14px;
  background: url('../js/ui_motion/textures/tex_sunburst_rays.png') center / contain no-repeat;
  opacity: 0.78;
  pointer-events: none;
  animation: sunburstSpin 14s linear infinite;
}

@keyframes sunburstSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

#reward-chest-img {
  position: relative;
  z-index: 2;
  width: 98px;
  height: 98px;
  object-fit: contain;
}

.reward-chip-big {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 5px 16px;
  border-style: solid;
  border-color: transparent;
  border-width: 7px 10px 7px 10px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/hud_pill.png') 28 35 26 34 fill / 7px 10px 7px 10px / 0 stretch;
  font-family: var(--font-num);
  font-size: 26px;
  font-weight: 800;
  color: var(--gold-psu);
}

.reward-chip-big img {
  width: 30px;
  height: 30px;
  object-fit: contain;
}

.reward-cta-big {
  min-width: 224px;
  min-height: 52px;
  font-size: 17px;
}

/* PILLAR 3: 3-ICON VISUAL PCB FLOW STRIP FOR FEATURE GUIDES */
.coach-flow-strip {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 8px;
}

.coach-step-card {
  border-style: solid;
  border-color: transparent;
  border-width: 12px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/card_rare.png') 114 108 118 107 fill / 12px / 0 stretch;
  background-color: #0B1520;
  background-clip: padding-box;
  padding: 10px 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
}

.coach-icon-slot {
  width: 72px;
  height: 72px;
  border-style: solid;
  border-color: transparent;
  border-width: 6px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/slot_tile.png') 30 32 32 31 fill / 6px / 0 stretch;
  display: flex;
  align-items: center;
  justify-content: center;
}

.coach-icon-slot img {
  width: 56px;
  height: 56px;
  object-fit: contain;
}

.coach-step-lbl {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 13.5px;
  line-height: 1.18;
  color: var(--emerald-out);
  text-transform: uppercase;
}

.coach-flow-arrow {
  font-family: var(--font-num);
  font-size: 24px;
  font-weight: 800;
  color: var(--cyber-teal);
}

/* =========================================================================
 * PILLAR 2 & 3: SPOTLIGHT RING + ANIMATED POINTER-HAND (0 SKILL BAR CLIP!)
 * ========================================================================= */
#tutorial-overlay {
  position: fixed;
  inset: 0;
  z-index: 105;
  pointer-events: none;
}

#tutorial-ring {
  position: fixed;
  border: 3px solid var(--emerald-out);
  box-shadow: 0 0 0 3000px rgba(2, 6, 10, 0.46);
  pointer-events: none;
  transition: left 0.2s ease, top 0.2s ease, width 0.2s ease, height 0.2s ease;
}

.tut-hand {
  position: fixed;
  z-index: 108;
  width: 54px;
  height: 54px;
  pointer-events: none;
  will-change: transform;
  animation: tutHandPoke 0.95s ease-in-out infinite;
  transition: left 0.2s ease, top 0.2s ease;
}

@keyframes tutHandPoke {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-7px, -7px) scale(0.92); }
}

#tutorial-card {
  position: fixed;
  top: 108px;
  left: 50%;
  transform: translateX(-50%);
  width: min(440px, 84vw);
  border-style: solid;
  border-color: transparent;
  border-width: 14px 16px 16px 16px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/frame_subpanel.png') 73 73 76 73 fill / 14px 16px 16px 16px / 0 stretch;
  padding: 6px 8px;
  pointer-events: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 107;
  transition: left 0.2s ease, top 0.2s ease;
}

.tut-card-hdr {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.tut-hdr-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 13.5px;
  letter-spacing: 0.05em;
  color: var(--cyber-teal);
}

.tut-step-pill {
  font-family: var(--font-num);
  font-weight: 700;
  font-size: 13px;
  color: var(--emerald-out);
  padding: 1px 7px;
  background: rgba(6, 16, 22, 0.9);
  border: 1px solid rgba(70, 224, 138, 0.45);
}

.tut-card-main {
  display: flex;
  align-items: center;
  gap: 10px;
}

.tut-step-ic {
  width: 44px;
  height: 44px;
  object-fit: contain;
  flex-shrink: 0;
}

.tut-callout-text {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 15px;
  line-height: 1.25;
  color: #FFFFFF;
}

.tut-card-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
}

#btn-tutorial-skip {
  min-width: 88px;
  min-height: 38px;
}

#btn-tutorial-next {
  min-width: 118px;
  min-height: 38px;
}

/* TOAST BANNER */
#toast-container {
  position: fixed;
  top: 56px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 260;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  pointer-events: none;
}

.toast-msg {
  border-style: solid;
  border-color: transparent;
  border-width: 7px 10px 7px 10px;
  border-image: url('../assets/ui/vault_cyber_pcb_terminal/hud_pill.png') 28 35 26 34 fill / 7px 10px 7px 10px / 0 stretch;
  background-color: rgba(6, 15, 24, 0.94);
  background-clip: padding-box;
  color: #FFFFFF;
  padding: 4px 14px;
  font-family: var(--font-num);
  font-weight: 700;
  font-size: 13.5px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.65);
}

.toast-msg.toast-ok {
  color: #7DF5B2;
}

.toast-msg.toast-err {
  color: #FF9AA3;
}

/* PREVIEW-ONLY [DEV F2] PILL & PANEL */
#dev-f2-pill {
  position: fixed;
  bottom: 92px;
  right: 326px;
  z-index: 150;
  background: rgba(12, 20, 28, 0.94);
  border: 1px solid var(--amber-tok);
  color: var(--amber-tok);
  font-family: var(--font-num);
  font-size: 12px;
  padding: 3px 7px;
}

#debug-panel {
  position: fixed;
  bottom: 122px;
  right: 326px;
  z-index: 150;
  width: 280px;
  background: #080E15;
  border: 1.5px solid var(--amber-tok);
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* =========================================================================
 * COMPACT LAPTOP / 720p WIDESCREEN (1280x720 .. 1480px)
 * ========================================================================= */
@media (max-width: 1480px) {
  #game-shell {
    grid-template-rows: 44px minmax(0, 1fr);
  }
  #top-strip {
    padding: 0 5px;
    gap: 4px;
    flex-wrap: nowrap !important;
  }
  .top-group {
    gap: 4px;
    flex-wrap: nowrap !important;
  }
  #top-strip .site-pill:not(.current) {
    display: none;
  }
  .site-pill.current {
    max-width: 112px;
    font-size: 12.5px;
  }
  #top-strip .btn-pcb {
    border-width: 4px 5px 4px 5px;
    padding: 2px 5px;
    min-height: 28px;
    font-size: 12px;
    gap: 3px;
    max-width: 134px;
  }
  #top-strip .icon-sm {
    width: 14px;
    height: 14px;
  }
  .wallet-pill {
    padding: 1px 5px;
    gap: 4px;
    min-height: 28px;
  }
  .wallet-pill img {
    width: 16px;
    height: 16px;
  }
  .wallet-val,
  .wallet-sub,
  .bn-badge {
    font-size: 12px;
  }
  #workspace-grid {
    grid-template-columns: 178px minmax(0, 1fr) 280px;
  }
  #left-dock {
    padding: 5px;
    gap: 4px;
  }
  .gauge-card {
    border-width: 5px 6px 5px 6px;
    padding: 1px 3px;
  }
  .gauge-top,
  .osc-legend,
  .advisor-msg,
  .advisor-preview {
    font-size: 12px;
  }
  .gauge-name {
    white-space: nowrap;
    line-height: 1.12;
  }
  #osc-canvas {
    height: 58px;
  }
  #right-dock-body {
    padding: 5px;
    gap: 4px;
  }
  .upg-card {
    grid-template-columns: 36px minmax(0, 1fr) auto;
    padding: 2px 3px;
    gap: 5px;
  }
  .upg-hw-slot {
    width: 36px;
    height: 36px;
  }
  .upg-hw-icon {
    width: 28px;
    height: 28px;
  }
  .upg-title-row {
    font-size: 12px;
    gap: 3px;
  }
  .upg-lv,
  .upg-stat-chip {
    font-size: 12px;
  }
  .upg-buy-btn {
    min-width: 60px;
    min-height: 32px;
    border-width: 6px 7px 6px 7px;
    padding: 1px 4px;
    font-size: 12px;
  }
  #tactical-bar {
    padding: 2px 5px;
    gap: 3px;
  }
  .tac-skill-btn {
    min-height: 35px;
    padding: 1px 4px;
    gap: 3px;
  }
  .tac-ring-wrap,
  .tac-cd-ring {
    width: 24px;
    height: 24px;
  }
  .tac-ic {
    width: 15px;
    height: 15px;
  }
  .tac-skill-btn .kbd-tag {
    padding: 1px 4px;
    font-size: 12px;
  }
  .tac-syn-pill {
    min-height: 34px;
    padding: 1px 6px;
    font-size: 12px;
  }
  .sm-tabs .btn-pcb {
    padding: 2px 5px;
    min-height: 28px;
    font-size: 12px;
    max-width: 108px;
  }
  #overclock-bar {
    padding: 3px 6px;
    gap: 4px;
  }
  .skill-btn {
    padding: 2px 5px;
    min-height: 38px;
    gap: 4px;
  }
  .skill-btn .icon-sm {
    width: 20px;
    height: 20px;
  }
  .skill-name,
  .skill-state {
    font-size: 12px;
  }
  .dock-nav {
    grid-template-columns: repeat(10, minmax(0, 1fr)) 24px;
    gap: 4px;
    padding: 6px 7px 5px 5px;
  }
  .dock-tab-btn {
    padding: 2px 4px;
    font-size: 12px;
    min-height: 28px;
  }
  #dev-f2-pill {
    bottom: 82px;
    right: 292px;
  }
  #debug-panel {
    bottom: 112px;
    right: 292px;
  }
}

@media (max-width: 1100px) {
  .shop-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .pass-ms-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  #game-shell {
    overflow-y: auto;
  }
  #workspace-grid {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: 380px auto auto;
    height: auto;
  }
  #left-dock, #right-dock {
    border: none;
    border-top: 1px solid var(--slate-border);
  }
}
