/* ==========================================================================
   CARTEL.io — High-Contrast Syndicate HUD & Lobby Stylesheet
   ========================================================================== */

:root {
  --bg-obsidian: rgba(15, 23, 42, 0.88);
  --bg-obsidian-solid: #0f172a;
  --bg-card: rgba(30, 41, 59, 0.92);
  --border-subtle: rgba(255, 255, 255, 0.14);
  --border-gold: rgba(245, 158, 11, 0.65);
  --gold-primary: #f59e0b;
  --gold-bright: #fbbf24;
  --cash-green: #10b981;
  --cash-bright: #34d399;
  --crimson: #ef4444;
  --crimson-dark: #b91c1c;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  /* Fallbacks keep the layout sane when Google Fonts can't be loaded (offline / blocked) */
  --font-display: 'Outfit', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'Cascadia Mono', 'Consolas', 'SFMono-Regular', Menlo, monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  user-select: none;
  -webkit-user-select: none;
}

html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background-color: #cbd5e1;
  font-family: var(--font-display);
  color: var(--text-main);
}

#game-canvas {
  position: fixed;
   inset: 0;
  width: 100vw;
  height: 100vh;
  display: block;
  z-index: 1;
  cursor: crosshair;
}

.hidden {
  display: none !important;
}

/* ==========================================================================
   OVERLAYS (LOBBY & DEATH MODAL) — THE SYNDICATE EXECUTIVE SUITE
   ========================================================================== */
.overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: radial-gradient(circle at 50% 35%, rgba(15, 23, 42, 0.72) 0%, rgba(2, 4, 8, 0.94) 100%);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  animation: fadeIn 0.22s ease-out;
  overflow-y: auto;
}

@keyframes fadeIn {
  from { opacity: 0; transform: scale(0.98); }
  to { opacity: 1; transform: scale(1); }
}

/* Master Executive Lobby Card (Zero Overflow Issue, Luxury Custom Scrollbar) */
.lobby-card {
  width: 100%;
  max-width: 1040px;
  max-height: 94vh;
  margin: auto;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: #d4af37 rgba(8, 12, 20, 0.75);
  background: linear-gradient(170deg, #0e131d 0%, #07090f 100%);
  border: 1.5px solid rgba(212, 175, 55, 0.45);
  border-radius: 20px;
  padding: 16px 22px 14px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.88), 0 0 50px rgba(212, 175, 55, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
}

/* Custom Luxury Gold Scrollbar (Şık Kaydırma Butonu / Çubuğu) */
.lobby-card::-webkit-scrollbar {
  width: 7px;
}

.lobby-card::-webkit-scrollbar-track {
  background: rgba(8, 12, 20, 0.85);
  border-radius: 999px;
  margin: 6px 0;
}

.lobby-card::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #d4af37 0%, #b45309 100%);
  border-radius: 999px;
  border: 1px solid rgba(254, 240, 138, 0.4);
  box-shadow: 0 0 6px rgba(212, 175, 55, 0.5);
}

.lobby-card::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #fde047 0%, #d97706 100%);
  box-shadow: 0 0 12px rgba(253, 224, 71, 0.8);
}

/* Ambient Corner Filigrees */
.lobby-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent 0%, #d4af37 30%, #fef08a 50%, #d4af37 70%, transparent 100%);
  pointer-events: none;
}

/* --------------------------------------------------------------------------
   Top Prestige Vault Bar & Audio Controls
   -------------------------------------------------------------------------- */
.vault-bar {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(212, 175, 55, 0.2);
}

.vault-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, rgba(16, 24, 38, 0.95) 0%, rgba(9, 14, 24, 0.95) 100%);
  border: 1px solid rgba(212, 175, 55, 0.4);
  padding: 5px 14px;
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.vault-crest {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(212, 175, 55, 0.15);
  border: 1px solid rgba(212, 175, 55, 0.35);
  font-size: 1.1rem;
}

.vault-info {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.vault-label {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  color: #d4af37;
  text-transform: uppercase;
}

.vault-amount {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 850;
  color: #34d399;
  letter-spacing: -0.01em;
  text-shadow: 0 0 12px rgba(52, 211, 153, 0.35);
}

/* Brand Header */
.brand-header {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1;
}

.brand-tag {
  display: inline-block;
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.22em;
  color: #fde047;
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid rgba(212, 175, 55, 0.35);
  padding: 3px 10px;
  border-radius: 999px;
  margin-bottom: 4px;
  text-transform: uppercase;
}

.brand-title {
  font-size: 2.3rem;
  font-weight: 900;
  letter-spacing: -0.03em;
  color: #ffffff;
  text-shadow: 0 4px 18px rgba(0, 0, 0, 0.7);
}

.brand-title span {
  color: #f59e0b;
  text-shadow: 0 0 16px rgba(245, 158, 11, 0.45);
}

.vault-audio-box {
  display: flex;
  align-items: center;
  gap: 10px;
}

.vol-slider-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(212, 175, 55, 0.25);
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.vol-icon {
  font-size: 0.95rem;
}

.vol-val {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 750;
  color: #fde047;
  min-width: 32px;
}

.vol-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 80px;
  height: 5px;
  background: rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  outline: none;
  cursor: pointer;
  transition: background 0.15s;
}

.vol-slider:hover {
  background: rgba(255, 255, 255, 0.32);
}

.vol-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #f59e0b;
  box-shadow: 0 0 8px rgba(245, 158, 11, 0.8);
  cursor: pointer;
}

.vol-slider::-moz-range-thumb {
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #f59e0b;
  box-shadow: 0 0 8px rgba(245, 158, 11, 0.8);
  cursor: pointer;
  border: none;
}

.icon-btn {
  background: rgba(212, 175, 55, 0.08);
  border: 1px solid rgba(212, 175, 55, 0.3);
  color: #f8fafc;
  padding: 6px 12px;
  border-radius: 10px;
  font-family: var(--font-display);
  font-weight: 750;
  font-size: 0.78rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.icon-btn:hover {
  background: rgba(212, 175, 55, 0.2);
  border-color: #fde047;
}

.lang-btn {
  background: rgba(56, 189, 248, 0.12);
  border-color: rgba(56, 189, 248, 0.4);
  color: #e0f2fe;
  min-width: 72px;
  text-align: center;
}

.lang-btn:hover {
  background: rgba(56, 189, 248, 0.25);
  border-color: #38bdf8;
  color: #ffffff;
}

/* --------------------------------------------------------------------------
   Main Split Layout (Left: Showcase Podium | Right: Action & 2x3 Dossiers)
   -------------------------------------------------------------------------- */
.lobby-main-split {
  display: grid;
  grid-template-columns: 290px minmax(0, 1fr);
  gap: 16px;
  align-items: stretch;
  min-width: 0;
  width: 100%;
}

@media (max-width: 860px) {
  .lobby-main-split {
    grid-template-columns: 1fr;
  }
}

/* LEFT: Interactive Boss Showcase Podium */
.boss-showcase-panel {
  background: linear-gradient(180deg, rgba(17, 24, 38, 0.8) 0%, rgba(9, 12, 20, 0.95) 100%);
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-radius: 16px;
  padding: 14px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  text-align: center;
  box-shadow: inset 0 0 35px rgba(0, 0, 0, 0.65), 0 10px 30px rgba(0, 0, 0, 0.4);
  position: relative;
  overflow: hidden;
}

.boss-showcase-panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 20%;
  right: 20%;
  height: 1px;
  background: linear-gradient(90deg, transparent, #d4af37, transparent);
}

.podium-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  width: 100%;
}

.podium-eyebrow {
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  color: #94a3b8;
  text-transform: uppercase;
}

.podium-title-badge {
  font-size: 0.76rem;
  font-weight: 800;
  color: #fde047;
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.35);
  padding: 2px 10px;
  border-radius: 999px;
  letter-spacing: 0.04em;
}

/* Podium Carousel Stage & Avatar */
.podium-stage-wrap {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 4px;
  margin: 4px 0;
}

/* Şık Sağa-Sola Kaydırma Butonları */
.podium-nav-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.95) 0%, rgba(15, 23, 42, 0.95) 100%);
  border: 1.5px solid rgba(212, 175, 55, 0.5);
  color: #fde047;
  font-size: 0.92rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transition: all 0.14s ease;
  z-index: 5;
  user-select: none;
  flex-shrink: 0;
}

.podium-nav-btn:hover {
  transform: scale(1.12);
  border-color: #fde047;
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.35) 0%, rgba(180, 83, 9, 0.45) 100%);
  box-shadow: 0 0 16px rgba(245, 158, 11, 0.7);
}

.podium-nav-btn:active {
  transform: scale(0.94);
}

.podium-stage {
  position: relative;
  width: 150px;
  height: 135px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.podium-spotlight {
  position: absolute;
  top: -15px;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(212, 175, 55, 0.22) 0%, rgba(212, 175, 55, 0.04) 60%, transparent 100%);
  filter: blur(8px);
  pointer-events: none;
}

.podium-avatar-wrap {
  position: relative;
  z-index: 2;
  animation: bossFloat 3.2s ease-in-out infinite;
  display: flex;
  align-items: center;
  justify-content: center;
}

@keyframes bossFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

.podium-base {
  position: absolute;
  bottom: 6px;
  width: 110px;
  height: 22px;
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(212, 175, 55, 0.4) 0%, rgba(0, 0, 0, 0.8) 75%);
  border-bottom: 2px solid rgba(212, 175, 55, 0.5);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.8);
  z-index: 1;
}

/* Podium Details */
.podium-details {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  width: 100%;
}

.podium-boss-name {
  font-size: 1.2rem;
  font-weight: 900;
  color: #ffffff;
  letter-spacing: -0.01em;
  margin: 0;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

.podium-bonus-tag {
  font-size: 0.66rem;
  font-weight: 750;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.3);
  padding: 3px 8px;
  border-radius: 6px;
  line-height: 1.25;
  width: 100%;
}

.podium-stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  width: 100%;
}

.stat-pill {
  background: rgba(2, 6, 23, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.stat-ico {
  font-size: 0.72rem;
}

.stat-val {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 800;
  color: #f8fafc;
}

.podium-action-slot {
  width: 100%;
  margin-top: 4px;
}

/* RIGHT: Name Input, Raid Button & 2x3 Dossiers */
.lobby-right-panel {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
  width: 100%;
}

.lobby-action-row {
  display: grid;
  grid-template-columns: 1fr 220px;
  gap: 12px;
  align-items: stretch;
}

@media (max-width: 580px) {
  .lobby-action-row {
    grid-template-columns: 1fr;
  }
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.input-group label {
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.12em;
  color: #d4af37;
  text-transform: uppercase;
}

.input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  height: 48px;
}

.input-icon {
  position: absolute;
  left: 14px;
  font-size: 1.1rem;
  pointer-events: none;
  opacity: 0.8;
}

.input-wrap input {
  width: 100%;
  height: 100%;
  padding: 0 16px 0 44px;
  border-radius: 12px;
  border: 1.5px solid rgba(212, 175, 55, 0.35);
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.95) 0%, rgba(8, 12, 20, 0.95) 100%);
  color: #ffffff;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 750;
  outline: none;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.6);
  user-select: text;
  -webkit-user-select: text;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.input-wrap input:focus {
  border-color: #fde047;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.3), inset 0 2px 6px rgba(0, 0, 0, 0.6);
}

/* Primary Raid Button (Tactile 3D Gold Seal) */
.play-btn {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 6px 16px;
  border-radius: 12px;
  border: 1.5px solid #fde047;
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 48%, #9a3412 100%);
  color: #ffffff;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(217, 119, 6, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.35);
  transition: transform 0.12s ease, box-shadow 0.12s ease, filter 0.12s ease;
  overflow: hidden;
}

.play-btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
  box-shadow: 0 12px 30px rgba(217, 119, 6, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.play-btn:active {
  transform: translateY(1px);
  box-shadow: 0 4px 12px rgba(217, 119, 6, 0.4);
}

.play-btn-main {
  font-size: 1.2rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
  line-height: 1.1;
}

.play-btn-sub {
  font-size: 0.66rem;
  font-weight: 800;
  opacity: 0.95;
  letter-spacing: 0.08em;
  color: #fef08a;
  text-transform: uppercase;
}

/* --------------------------------------------------------------------------
   2x3 Symmetrical Syndicate Dossiers Grid (Strictly 6 Cards, Zero Wrap)
   -------------------------------------------------------------------------- */
.roster-section {
  display: flex;
  flex-direction: column;
  gap: 7px;
  min-width: 0;
  width: 100%;
}

.roster-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.74rem;
  font-weight: 850;
  color: #cbd5e1;
}

.roster-title-box {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.roster-title {
  color: #d4af37;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.72rem;
}

.roster-hint {
  font-size: 0.68rem;
  color: #94a3b8;
  font-weight: 600;
}

.roster-nav-arrows {
  display: flex;
  align-items: center;
  gap: 5px;
}

.mini-nav-btn {
  width: 28px;
  height: 24px;
  border-radius: 6px;
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid rgba(212, 175, 55, 0.35);
  color: #fde047;
  font-size: 0.72rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.12s ease;
  user-select: none;
}

.mini-nav-btn:hover {
  background: rgba(212, 175, 55, 0.3);
  border-color: #fde047;
  transform: scale(1.08);
}

.skin-grid-2x3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 8px;
  min-width: 0;
  width: 100%;
}

@media (max-width: 680px) {
  .skin-grid-2x3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Syndicate Dossier Card */
.skin-card {
  position: relative;
  min-width: 0;
  overflow: hidden;
  background: linear-gradient(145deg, rgba(19, 27, 42, 0.9) 0%, rgba(10, 14, 23, 0.95) 100%);
  border: 1.5px solid rgba(212, 175, 55, 0.22);
  border-radius: 12px;
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  transition: transform 0.14s ease, border-color 0.14s ease, box-shadow 0.14s ease;
  text-align: center;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}

.skin-card:hover {
  transform: translateY(-2px);
  border-color: rgba(212, 175, 55, 0.6);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
}

.skin-card.selected {
  border-color: #fde047;
  background: linear-gradient(145deg, rgba(245, 158, 11, 0.22) 0%, rgba(15, 23, 42, 0.95) 100%);
  box-shadow: 0 0 20px rgba(245, 158, 11, 0.45), inset 0 0 15px rgba(245, 158, 11, 0.15);
}

.skin-card.locked {
  background: linear-gradient(145deg, rgba(12, 16, 26, 0.85) 0%, rgba(6, 8, 14, 0.95) 100%);
  border-color: rgba(255, 255, 255, 0.08);
}

/* Card Badge Header Row */
.card-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.card-title-pill {
  font-size: 0.62rem;
  font-weight: 800;
  color: #fde047;
  background: rgba(245, 158, 11, 0.14);
  padding: 1px 6px;
  border-radius: 4px;
  letter-spacing: 0.02em;
}

.card-cost-tag {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  font-weight: 800;
  color: #34d399;
}

.skin-card.locked .card-cost-tag {
  color: #f87171;
}

.card-avatar-wrap {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  margin: 1px 0;
}

.card-name {
  font-size: 0.84rem;
  font-weight: 850;
  color: #ffffff;
  line-height: 1.1;
  letter-spacing: -0.01em;
}

.card-bonus-summary {
  font-size: 0.62rem;
  font-weight: 750;
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.22);
  padding: 2px 6px;
  border-radius: 4px;
  width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Action Buttons (Select, Active, Buy, Locked) */
.skin-action-btn {
  font-family: var(--font-display);
  font-size: 0.7rem;
  font-weight: 850;
  padding: 5px 8px;
  border-radius: 8px;
  text-align: center;
  width: 100%;
  transition: all 0.12s ease;
  border: 1px solid transparent;
  margin-top: 3px;
  cursor: pointer;
}

.skin-action-btn.active {
  background: #f59e0b;
  color: #0b0f19;
  border-color: #fde047;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.45);
}

.skin-action-btn.select {
  background: rgba(16, 185, 129, 0.18);
  color: #34d399;
  border-color: rgba(16, 185, 129, 0.45);
}

.skin-action-btn.select:hover {
  background: rgba(16, 185, 129, 0.35);
}

.skin-action-btn.buy {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #ffffff;
  border-color: #fde047;
  box-shadow: 0 3px 10px rgba(217, 119, 6, 0.45);
}

.skin-action-btn.buy:hover {
  filter: brightness(1.12);
  transform: scale(1.02);
}

.skin-action-btn.disabled {
  background: rgba(255, 255, 255, 0.06);
  color: #94a3b8;
  border-color: rgba(255, 255, 255, 0.1);
  font-size: 0.66rem;
  cursor: not-allowed;
}

/* --------------------------------------------------------------------------
   Bottom Controls Bar
   -------------------------------------------------------------------------- */
.lobby-controls-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 16px;
  padding-top: 8px;
  border-top: 1px solid rgba(212, 175, 55, 0.18);
  font-size: 0.72rem;
  color: #94a3b8;
}

.ctrl-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

kbd {
  display: inline-block;
  padding: 2px 6px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 800;
  color: #fde047;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(212, 175, 55, 0.35);
  border-bottom-width: 2px;
  border-radius: 5px;
}

/* ==========================================================================
   IN-GAME HUD LAYOUT (COMPACT & HIGH-VISIBILITY)
   ========================================================================== */
.hud-container {
  position: fixed;
  inset: 0;
  z-index: 10;
  pointer-events: none;
}

/* Allow clicks on interactive HUD widgets */
.hud-audio-controls,
.hud-vol-slider,
.hud-mute-btn,
.hud-vol-val,
.shop-card,
.perk-card,
.dash-badge,
.clan-panel,
.clan-header-bar,
.clan-btn {
  pointer-events: auto;
}

/* TOP-LEFT: Player Status Card & Clan Widget */
.hud-top-left {
  position: absolute;
  top: 10px;
  left: 10px;
  width: 220px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: calc(100vh - 20px);
}

.status-card {
  background: rgba(15, 23, 42, 0.84);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-left: 4px solid var(--gold-primary);
  border-radius: 12px;
  padding: 9px 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45), 0 0 15px rgba(245, 158, 11, 0.12);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.status-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.player-identity {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
}

.player-title-badge {
  font-size: 0.56rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--gold-bright);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.player-name-display {
  font-size: 0.88rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Top-Left Audio Controls (Mute + Volume Slider + Percentage) */
.hud-audio-controls {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(2, 6, 23, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.14);
  padding: 2px 7px;
  border-radius: 999px;
  flex-shrink: 0;
  pointer-events: auto;
  user-select: none;
  -webkit-user-select: none;
  transition: border-color 0.15s, background 0.15s;
}

.hud-audio-controls:hover {
  border-color: rgba(245, 158, 11, 0.45);
  background: rgba(2, 6, 23, 0.9);
}

.hud-mute-btn {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: #ffffff;
  font-size: 0.74rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: transform 0.12s, opacity 0.15s;
  flex-shrink: 0;
  pointer-events: auto;
}

.hud-mute-btn:hover {
  transform: scale(1.18);
  opacity: 0.95;
}

.hud-vol-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 48px;
  height: 4px;
  background: rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  outline: none;
  cursor: pointer;
  pointer-events: auto;
  transition: background 0.15s;
  padding: 0;
  margin: 0;
}

.hud-vol-slider:hover {
  background: rgba(255, 255, 255, 0.38);
}

.hud-vol-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #f59e0b;
  box-shadow: 0 0 6px rgba(245, 158, 11, 0.9);
  cursor: pointer;
  transition: transform 0.1s;
}

.hud-vol-slider::-webkit-slider-thumb:hover {
  transform: scale(1.25);
}

.hud-vol-slider::-moz-range-thumb {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #f59e0b;
  box-shadow: 0 0 6px rgba(245, 158, 11, 0.9);
  cursor: pointer;
  border: none;
  transition: transform 0.1s;
}

.hud-vol-slider::-moz-range-thumb:hover {
  transform: scale(1.25);
}

.hud-vol-val {
  font-family: var(--font-mono, monospace);
  font-size: 0.58rem;
  font-weight: 700;
  color: #cbd5e1;
  min-width: 22px;
  text-align: right;
  pointer-events: auto;
  line-height: 1;
}

/* Cash & Income Row */
.cash-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(2, 6, 23, 0.5);
  padding: 4px 8px;
  border-radius: 7px;
  border: 1px solid rgba(16, 185, 129, 0.28);
}

.cash-main {
  display: flex;
  flex-direction: column;
}

.cash-label {
  font-size: 0.52rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #6ee7b7;
}

.cash-value {
  font-family: var(--font-mono);
  font-size: 1.12rem;
  font-weight: 800;
  color: var(--cash-bright);
  line-height: 1.05;
}

.income-pill {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: rgba(16, 185, 129, 0.16);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #a7f3d0;
  padding: 2px 6px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 700;
}

/* Progress Bars (HP & Level) */
.bar-group {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.bar-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: #cbd5e1;
}

.progress-track {
  width: 100%;
  height: 6px;
  background: rgba(2, 6, 23, 0.75);
  border-radius: 999px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.progress-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.18s ease-out;
}

.hp-fill {
  background: linear-gradient(90deg, #ef4444 0%, #22c55e 100%);
}

.level-fill {
  background: linear-gradient(90deg, #f59e0b 0%, #fde047 100%);
}

/* Stats Mini Grid (2x2 for Kills, Turfs, Guards, Weapon) */
.stats-mini-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 5px;
}

.stat-box {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  padding: 4px 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.stat-box.kill-stat-box {
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.38);
}

.stat-box-label {
  font-size: 0.5rem;
  font-weight: 800;
  color: var(--text-muted);
}

.stat-box.kill-stat-box .stat-box-label {
  color: #fca5a5;
}

.stat-box-val {
  font-size: 0.68rem;
  font-weight: 800;
  color: #ffffff;
  margin-top: 1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.stat-box-val.kill-val {
  font-family: var(--font-mono);
  color: #f87171;
}

/* Active Roguelite Perks Row */
.active-perks-row {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
}

.active-perks-row:empty {
  display: none;
}

.active-perk-pill {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: 5px;
  padding: 1px 5px;
  font-size: 0.6rem;
  font-weight: 700;
  color: #fde68a;
}

/* ==========================================================================
   CLAN / SYNDICATE MANAGEMENT WIDGET (TOP-LEFT BELOW STATUS CARD)
   ========================================================================== */
.clan-panel {
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid var(--border-subtle);
  border-left: 3px solid #10b981;
  border-radius: 10px;
  padding: 6px 9px;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.clan-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
}

.clan-header-left {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
}

.clan-shield-icon {
  font-size: 0.78rem;
}

.clan-header-title {
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  color: #6ee7b7;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.clan-req-badge {
  background: #ef4444;
  color: #ffffff;
  font-family: var(--font-mono);
  font-size: 0.58rem;
  font-weight: 800;
  padding: 1px 5px;
  border-radius: 999px;
  animation: pulseBadge 1s infinite alternate;
}

@keyframes pulseBadge {
  from { transform: scale(1); }
  to { transform: scale(1.12); }
}

.clan-toggle-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-subtle);
  color: #cbd5e1;
  font-family: var(--font-mono);
  font-size: 0.58rem;
  font-weight: 800;
  padding: 1px 5px;
  border-radius: 5px;
  cursor: pointer;
  transition: background 0.15s;
  flex-shrink: 0;
}

.clan-toggle-btn:hover {
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
}

.clan-body {
  display: flex;
  flex-direction: column;
  gap: 5px;
  border-top: 1px solid var(--border-subtle);
  padding-top: 6px;
}

.clan-view {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.clan-create-row {
  display: flex;
  gap: 4px;
}

#clan-name-input {
  flex: 1;
  min-width: 0;
  height: 26px;
  padding: 0 7px;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(2, 6, 23, 0.8);
  color: #ffffff;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  outline: none;
  user-select: text;
  -webkit-user-select: text;
}

#clan-name-input:focus {
  border-color: #10b981;
}

.clan-action-btn {
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 5px;
  padding: 2px 6px;
  font-family: var(--font-display);
  font-size: 0.62rem;
  font-weight: 800;
  cursor: pointer;
  color: #ffffff;
  white-space: nowrap;
  transition: filter 0.12s, transform 0.1s;
}

.clan-action-btn:hover:not(:disabled) {
  filter: brightness(1.12);
  transform: translateY(-1px);
}

.clan-action-btn:disabled {
  opacity: 0.48;
  cursor: not-allowed;
}

.clan-action-btn.create,
.clan-action-btn.accept {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  border-color: #34d399;
}

.clan-action-btn.join {
  background: rgba(59, 130, 246, 0.28);
  border-color: rgba(96, 165, 250, 0.6);
  color: #bfdbfe;
}

.clan-action-btn.danger,
.clan-action-btn.kick {
  background: rgba(239, 68, 68, 0.24);
  border-color: rgba(248, 113, 113, 0.55);
  color: #fecaca;
}

.clan-sub-label {
  font-size: 0.54rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.clan-sub-label.highlight {
  color: var(--gold-bright);
}

.clan-scroll-list,
.clan-members-list,
.clan-requests-list {
  display: flex;
  flex-direction: column;
  gap: 3px;
  max-height: 92px;
  overflow-y: auto;
  padding-right: 2px;
}

.clan-empty-hint {
  font-size: 0.62rem;
  color: var(--text-muted);
  text-align: center;
  padding: 4px 2px;
}

.clan-dir-row,
.clan-member-row,
.clan-req-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 5px;
  padding: 3px 5px;
  font-size: 0.64rem;
}

.clan-dir-info,
.clan-member-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
}

.clan-dir-title,
.clan-member-name {
  font-weight: 800;
  color: #f8fafc;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.clan-dir-sub,
.clan-member-sub {
  font-size: 0.56rem;
  color: var(--text-muted);
}

.clan-info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.38);
  border-radius: 6px;
  padding: 4px 6px;
}

.clan-info-meta {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.68rem;
  color: #ecfdf5;
  min-width: 0;
}

.clan-count-pill {
  font-family: var(--font-mono);
  font-size: 0.58rem;
  font-weight: 800;
  background: rgba(16, 185, 129, 0.25);
  color: #6ee7b7;
  padding: 1px 4px;
  border-radius: 999px;
}

.clan-requests-section {
  display: flex;
  flex-direction: column;
  gap: 3px;
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.4);
  border-radius: 6px;
  padding: 4px;
}

.clan-req-actions {
  display: flex;
  gap: 3px;
}

/* ==========================================================================
   TOP-CENTER: Kill Feed & Zero-Pause Roguelite Perk Bar
   ========================================================================== */
.hud-top-center {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  width: min(460px, calc(100vw - 440px));
  min-width: 280px;
}

.kill-feed {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  width: 100%;
}

.feed-item {
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #f8fafc;
  padding: 3px 11px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  animation: slideDownFade 0.2s ease-out;
  white-space: nowrap;
}

@keyframes slideDownFade {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Zero-Pause Roguelite Perk Selection Bar */
.perk-bar {
  background: rgba(15, 23, 42, 0.9);
  border: 1.5px solid var(--gold-bright);
  border-radius: 12px;
  padding: 6px 10px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.55), 0 0 18px rgba(245, 158, 11, 0.3);
  width: 100%;
  animation: pulseGoldBorder 1.8s infinite alternate;
}

@keyframes pulseGoldBorder {
  from { box-shadow: 0 8px 22px rgba(0, 0, 0, 0.5), 0 0 10px rgba(245, 158, 11, 0.2); }
  to { box-shadow: 0 8px 22px rgba(0, 0, 0, 0.5), 0 0 20px rgba(251, 191, 36, 0.5); }
}

.perk-bar-header {
  text-align: center;
  margin-bottom: 5px;
}

.perk-spark {
  font-size: 0.64rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  color: var(--gold-bright);
}

.perk-cards-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}

.perk-card {
  background: linear-gradient(155deg, rgba(30, 41, 59, 0.95) 0%, rgba(15, 23, 42, 0.95) 100%);
  border: 1px solid rgba(251, 191, 36, 0.45);
  border-radius: 9px;
  padding: 5px 7px;
  color: var(--text-main);
  text-align: left;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 2px;
  transition: transform 0.12s ease, border-color 0.12s ease, background 0.12s ease;
}

.perk-card:hover {
  transform: translateY(-2px);
  border-color: #fde047;
  background: rgba(245, 158, 11, 0.18);
}

.perk-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.perk-icon {
  font-size: 1rem;
}

.perk-hotkey {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  font-weight: 800;
  background: var(--gold-primary);
  color: #0f172a;
  padding: 1px 5px;
  border-radius: 4px;
}

.perk-title {
  font-size: 0.7rem;
  font-weight: 800;
  color: #fde68a;
}

.perk-desc {
  font-size: 0.58rem;
  line-height: 1.2;
  color: #cbd5e1;
}

/* ==========================================================================
   TOP-RIGHT: Live Leaderboard
   ========================================================================== */
.hud-top-right {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 205px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.leaderboard-card {
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  padding: 7px 9px;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
}

.leaderboard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.64rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  color: var(--gold-bright);
  padding-bottom: 4px;
  margin-bottom: 4px;
  border-bottom: 1px solid var(--border-subtle);
}

.online-pill {
  font-size: 0.55rem;
  background: rgba(16, 185, 129, 0.2);
  color: #6ee7b7;
  padding: 1px 5px;
  border-radius: 999px;
}

.leaderboard-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.lb-row {
  display: grid;
  grid-template-columns: 18px 1fr auto auto;
  align-items: center;
  gap: 4px;
  padding: 2px 5px;
  border-radius: 5px;
  font-size: 0.65rem;
  background: rgba(255, 255, 255, 0.03);
}

.lb-row.is-me {
  background: rgba(245, 158, 11, 0.2);
  border: 1px solid rgba(245, 158, 11, 0.45);
  font-weight: 800;
}

.lb-row.is-baron {
  border-left: 2px solid var(--gold-bright);
}

.lb-rank {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  font-weight: 800;
  color: var(--text-muted);
}

.lb-name {
  font-weight: 700;
  color: #f8fafc;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lb-turfs {
  font-family: var(--font-mono);
  font-size: 0.58rem;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.07);
  padding: 0 4px;
  border-radius: 4px;
}

.lb-cash {
  font-family: var(--font-mono);
  font-weight: 800;
  color: var(--cash-bright);
  font-size: 0.65rem;
}

/* ==========================================================================
   BOTTOM-CENTER: Quick Cartel Shop Bar & Dash Indicator
   ========================================================================== */
.hud-bottom-center {
  position: absolute;
  bottom: 10px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  /* Leave room for the minimap card (≈190px + margin) on both sides so they never overlap */
  width: min(680px, calc(100vw - 440px));
  min-width: 300px;
}

.dash-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(15, 23, 42, 0.82);
  border: 1px solid rgba(245, 158, 11, 0.5);
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.63rem;
  font-weight: 800;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
  cursor: pointer;
  transition: transform 0.1s ease, opacity 0.15s ease;
}

.dash-badge.cooldown {
  opacity: 0.52;
  border-color: rgba(148, 163, 184, 0.35);
}

.dash-key {
  font-family: var(--font-mono);
  background: var(--gold-primary);
  color: #0f172a;
  padding: 1px 5px;
  border-radius: 4px;
  font-size: 0.58rem;
  font-weight: 800;
}

.dash-title {
  color: #f8fafc;
}

.dash-cost {
  font-family: var(--font-mono);
  color: var(--cash-bright);
}

/* 4 Compact Tactile Shop Cards */
.shop-bar {
  display: grid;
  /* minmax(0, 1fr): let long nowrap labels ellipsize instead of stretching the grid
     past its container (that's what pushed card [4] under the minimap) */
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  width: 100%;
}

.shop-card {
  position: relative;
  background: rgba(15, 23, 42, 0.8);
  border: 1.5px solid rgba(255, 255, 255, 0.15);
  border-radius: 9px;
  padding: 5px 7px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-main);
  cursor: pointer;
  text-align: left;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
  transition: transform 0.12s ease, border-color 0.12s ease, background 0.12s ease;
}

.shop-card.affordable {
  border-color: rgba(16, 185, 129, 0.7);
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.22);
}

.shop-card.affordable:hover {
  transform: translateY(-2px);
  border-color: var(--cash-bright);
  background: rgba(16, 185, 129, 0.22);
  box-shadow: 0 4px 16px rgba(16, 185, 129, 0.35);
}

.shop-card.locked {
  opacity: 0.58;
  cursor: not-allowed;
}

.shop-card.maxed {
  border-color: var(--gold-primary);
  opacity: 0.82;
  cursor: default;
}

.shop-key-badge {
  position: absolute;
  top: -6px;
  left: 7px;
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: var(--gold-bright);
  font-family: var(--font-mono);
  font-size: 0.56rem;
  font-weight: 800;
  padding: 0 4px;
  border-radius: 4px;
}

.shop-icon {
  font-size: 1.1rem;
  flex-shrink: 0;
}

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

.shop-name {
  font-size: 0.67rem;
  font-weight: 800;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.shop-sub {
  font-size: 0.56rem;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.shop-price {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 800;
  color: var(--cash-bright);
  flex-shrink: 0;
}

/* ==========================================================================
   BOTTOM-RIGHT: Live 2D Canvas Mini-Map (Compact 145x145 Display)
   ========================================================================== */
.hud-bottom-right {
  position: absolute;
  bottom: 10px;
  right: 10px;
}

.minimap-card {
  width: 176px;
  background: rgba(15, 23, 42, 0.84);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 12px;
  padding: 5px 7px 7px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45), 0 0 16px rgba(56, 189, 248, 0.12);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.minimap-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1px 6px;
  font-size: 0.58rem;
  font-weight: 800;
  color: #cbd5e1;
}

.minimap-legend {
  font-size: 0.52rem;
  color: var(--gold-bright);
}

#minimap-canvas {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  border-radius: 7px;
  background: #090d16;
  border: 1px solid rgba(255, 255, 255, 0.14);
  display: block;
}

/* ==========================================================================
   DEATH / CASH-OUT SUMMARY MODAL
   ========================================================================== */
.death-card {
  width: 100%;
  max-width: 500px;
  max-height: 95vh;
  overflow-y: auto;
  background: linear-gradient(165deg, rgba(15, 23, 42, 0.97) 0%, rgba(30, 41, 59, 0.97) 100%);
  border: 2px solid var(--crimson);
  border-radius: 20px;
  padding: 28px;
  text-align: center;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.75), 0 0 40px rgba(239, 68, 68, 0.25);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.death-badge {
  display: inline-block;
  align-self: center;
  background: rgba(239, 68, 68, 0.18);
  border: 1px solid rgba(239, 68, 68, 0.5);
  color: #fca5a5;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  padding: 4px 14px;
  border-radius: 999px;
}

.death-title {
  font-size: 2.2rem;
  font-weight: 900;
  color: #ffffff;
  line-height: 1.05;
}

.death-killer {
  font-size: 0.95rem;
  color: #cbd5e1;
  background: rgba(2, 6, 23, 0.6);
  padding: 8px 14px;
  border-radius: 10px;
  border: 1px solid rgba(239, 68, 68, 0.35);
}

.death-killer strong {
  color: #f87171;
}

.death-stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.death-stat-item {
  background: rgba(2, 6, 23, 0.65);
  border: 1px solid var(--border-subtle);
  border-radius: 12px;
  padding: 12px 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.death-stat-item.highlight {
  border-color: rgba(16, 185, 129, 0.55);
  background: rgba(16, 185, 129, 0.12);
}

.death-stat-label {
  font-size: 0.66rem;
  font-weight: 800;
  color: var(--text-muted);
}

.death-stat-value {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 800;
  color: #ffffff;
}

.death-stat-item.highlight .death-stat-value {
  color: var(--cash-bright);
}

.death-vault-total {
  font-size: 0.88rem;
  color: #cbd5e1;
}

.death-vault-total strong {
  font-family: var(--font-mono);
  color: var(--gold-bright);
}

.death-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 4px;
}

.respawn-btn {
  width: 100%;
  padding: 14px 20px;
}

.secondary-btn {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--border-subtle);
  color: #cbd5e1;
  padding: 10px 16px;
  border-radius: 10px;
  font-family: var(--font-display);
  font-size: 0.86rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s;
}

.secondary-btn:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
}

/* Responsive Adjustments */
@media (max-width: 1024px) {
  .skin-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .howto-grid {
    grid-template-columns: 1fr;
  }
  .lobby-form-row {
    grid-template-columns: 1fr;
  }
  .shop-bar {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Connection lost / reconnecting toast */
.conn-toast {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 100;
  background: rgba(15, 23, 42, 0.94);
  border: 1.5px solid var(--crimson);
  color: #fff;
  padding: 10px 18px;
  border-radius: 12px;
  font-weight: 800;
  font-size: 0.85rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  pointer-events: none;
}

/* Medium screens (≈1280–1366 wide): tighten the HUD so the bottom bar fits between the minimap and the left edge */
@media (max-width: 1400px) {
  .hud-bottom-center {
    width: min(600px, calc(100vw - 420px));
  }
  .shop-card {
    padding: 5px 6px;
    gap: 5px;
  }
}

/* Short screens (≈720px tall): keep the left column from running into the shop bar */
@media (max-height: 760px) {
  .hud-top-left {
    max-height: calc(100vh - 130px);
    overflow-y: auto;
  }
  .minimap-card {
    width: 150px;
  }
}

/* Narrow screens: shop moves to 2x2 so it no longer needs the side room */
@media (max-width: 1024px) {
  .hud-bottom-center {
    width: min(420px, calc(100vw - 200px));
    min-width: 0;
    left: 10px;
    transform: none;
  }
}

/* ==========================================================================
   PERSONAL RECORDS & CARTEL CONTRACTS (LOBBY, HUD & DEATH MODAL)
   ========================================================================== */
.lobby-meta-row {
  display: grid;
  grid-template-columns: 290px minmax(0, 1fr);
  gap: 16px;
  width: 100%;
  padding-top: 8px;
  border-top: 1px solid rgba(212, 175, 55, 0.2);
}

@media (max-width: 860px) {
  .lobby-meta-row {
    grid-template-columns: 1fr;
  }
}

.records-card,
.contracts-card {
  background: linear-gradient(155deg, rgba(17, 24, 38, 0.88) 0%, rgba(10, 14, 23, 0.94) 100%);
  border: 1px solid rgba(212, 175, 55, 0.3);
  border-radius: 12px;
  padding: 9px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.meta-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.meta-card-title {
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.07em;
  color: #fde047;
  text-transform: uppercase;
}

.meta-card-sub {
  font-size: 0.62rem;
  font-weight: 600;
  color: #94a3b8;
}

.records-pills-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
}

.record-pill {
  background: rgba(2, 6, 23, 0.72);
  border: 1px solid rgba(245, 158, 11, 0.22);
  border-radius: 8px;
  padding: 5px 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 2px;
}

.record-pill-label {
  font-size: 0.52rem;
  font-weight: 800;
  color: #94a3b8;
  letter-spacing: 0.03em;
}

.record-pill-val {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 850;
  color: #fef08a;
}

/* Lobby Contracts Grid (3 Columns) */
.lobby-contracts-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

@media (max-width: 680px) {
  .lobby-contracts-grid {
    grid-template-columns: 1fr;
  }
}

.contract-item {
  background: rgba(2, 6, 23, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-left: 3px solid #f59e0b;
  border-radius: 8px;
  padding: 6px 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  transition: border-color 0.2s, background 0.2s;
}

.contract-item.completed {
  border-color: rgba(16, 185, 129, 0.55);
  border-left: 3px solid #10b981;
  background: rgba(16, 185, 129, 0.12);
}

.contract-top-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
}

.contract-title {
  font-size: 0.66rem;
  font-weight: 850;
  color: #f8fafc;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.contract-reward-pill {
  font-family: var(--font-mono);
  font-size: 0.58rem;
  font-weight: 850;
  color: #34d399;
  background: rgba(16, 185, 129, 0.16);
  border: 1px solid rgba(16, 185, 129, 0.35);
  padding: 1px 5px;
  border-radius: 4px;
  white-space: nowrap;
  flex-shrink: 0;
}

.contract-desc {
  font-size: 0.58rem;
  color: #cbd5e1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.contract-progress-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.contract-bar-track {
  flex: 1;
  height: 5px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  overflow: hidden;
}

.contract-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #f59e0b 0%, #34d399 100%);
  border-radius: 999px;
  transition: width 0.2s ease-out;
}

.contract-progress-txt {
  font-family: var(--font-mono);
  font-size: 0.56rem;
  font-weight: 800;
  color: #fde68a;
  flex-shrink: 0;
}

/* HUD Top-Right Active Contracts Widget */
.hud-contracts-card {
  background: rgba(15, 23, 42, 0.78);
  border: 1px solid var(--border-subtle);
  border-left: 3px solid #f59e0b;
  border-radius: 10px;
  padding: 6px 8px;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.hud-contracts-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.6rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  color: var(--gold-bright);
  padding-bottom: 3px;
  border-bottom: 1px solid var(--border-subtle);
}

.contracts-vault-tag {
  font-size: 0.52rem;
  background: rgba(245, 158, 11, 0.18);
  color: #fde047;
  padding: 1px 5px;
  border-radius: 999px;
}

.hud-contracts-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.hud-contract-row {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 5px;
  padding: 3px 5px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.hud-contract-row.completed {
  background: rgba(16, 185, 129, 0.16);
  border-color: rgba(16, 185, 129, 0.5);
}

.hud-contract-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  font-size: 0.58rem;
  font-weight: 750;
  color: #f8fafc;
}

.hud-contract-desc {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hud-contract-reward {
  font-family: var(--font-mono);
  font-size: 0.55rem;
  font-weight: 800;
  color: #34d399;
  flex-shrink: 0;
}

/* Death Modal New Record Banner & Records Strip */
.death-new-record-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.24) 0%, rgba(16, 185, 129, 0.22) 100%);
  border: 1.5px solid #fde047;
  border-radius: 12px;
  padding: 8px 14px;
  box-shadow: 0 0 20px rgba(250, 204, 21, 0.35);
  animation: pulseGoldBorder 1.2s infinite alternate;
}

.record-trophy-icon {
  font-size: 1.45rem;
}

.record-banner-text {
  display: flex;
  flex-direction: column;
  text-align: left;
  line-height: 1.2;
}

.record-banner-text strong {
  font-size: 0.82rem;
  font-weight: 900;
  color: #fef08a;
  letter-spacing: 0.05em;
}

.record-banner-text span {
  font-size: 0.72rem;
  font-weight: 700;
  color: #ecfdf5;
}

.death-records-strip {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 10px;
  background: rgba(2, 6, 23, 0.55);
  border: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: 10px;
  padding: 6px 10px;
}

.death-record-chip {
  font-size: 0.7rem;
  color: #cbd5e1;
}

.death-record-chip strong {
  font-family: var(--font-mono);
  color: #fde047;
}

/* ==========================================================================
   CRAZYGAMES REWARDED AD BOOSTERS & SILKY 60FPS FLAME STRIPS (LOBBY & DEATH)
   ========================================================================== */
@keyframes emberGlowPulse {
  0%, 100% {
    opacity: 0.88;
    transform: scaleY(0.95);
  }
  50% {
    opacity: 1;
    transform: scaleY(1.12);
  }
}

/* Shared Thin Flame Strip on Top of All Active Ad Click Targets */
.ad-boost-btn:not(.active),
.revive-ad-btn,
.ad-vault-double-btn:not(.claimed),
.skin-action-btn.ad-trial {
  position: relative;
  overflow: visible !important;
}

/* 1) Glowing Hot Ember Base Line on the Top Border (100% GPU Composited) */
.ad-boost-btn:not(.active)::before,
.revive-ad-btn::before,
.ad-vault-double-btn:not(.claimed)::before,
.skin-action-btn.ad-trial::before {
  content: '';
  position: absolute;
  top: -2px;
  left: 6px;
  right: 6px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    #ef4444 10%,
    #f97316 25%,
    #fde047 50%,
    #f97316 75%,
    #ef4444 90%,
    transparent 100%
  );
  box-shadow:
    0 -2px 10px rgba(249, 115, 22, 0.95),
    0 -5px 18px rgba(239, 68, 68, 0.75),
    0 1px 6px rgba(254, 240, 138, 0.9);
  animation: emberGlowPulse 1.4s ease-in-out infinite;
  will-change: opacity, transform;
  pointer-events: none;
  z-index: 3;
}

/* 2) 60FPS Native SVG Morphing 3-Layer Liquid Flame Strip (Zero Seams, Zero Stutter) */
.ad-boost-btn:not(.active)::after,
.revive-ad-btn::after,
.ad-vault-double-btn:not(.claimed)::after,
.skin-action-btn.ad-trial::after {
  content: '';
  position: absolute;
  top: -10px;
  left: 8px;
  right: 8px;
  height: 10px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 14' preserveAspectRatio='none'%3E%3Cpath fill='%23ef4444' opacity='0.78'%3E%3Canimate attributeName='d' dur='1.15s' repeatCount='indefinite' values='M0,14 Q12,3 25,8 Q38,1 50,7 Q62,2 75,9 Q88,1 100,6 Q112,2 125,8 Q138,1 150,7 Q162,3 175,9 Q188,4 200,14 Z;M0,14 Q12,8 25,3 Q38,9 50,2 Q62,8 75,2 Q88,9 100,1 Q112,8 125,2 Q138,9 150,2 Q162,8 175,3 Q188,8 200,14 Z;M0,14 Q12,5 25,6 Q38,2 50,8 Q62,1 75,6 Q88,4 100,8 Q112,1 125,6 Q138,4 150,9 Q162,2 175,6 Q188,5 200,14 Z;M0,14 Q12,3 25,8 Q38,1 50,7 Q62,2 75,9 Q88,1 100,6 Q112,2 125,8 Q138,1 150,7 Q162,3 175,9 Q188,4 200,14 Z'/%3E%3C/path%3E%3Cpath fill='%23f97316' opacity='0.92'%3E%3Canimate attributeName='d' dur='0.82s' repeatCount='indefinite' values='M0,14 Q12,9 25,4 Q38,10 50,3 Q62,9 75,4 Q88,10 100,3 Q112,9 125,4 Q138,10 150,3 Q162,9 175,4 Q188,9 200,14 Z;M0,14 Q12,4 25,9 Q38,3 50,9 Q62,3 75,10 Q88,3 100,9 Q112,3 125,9 Q138,3 150,10 Q162,4 175,9 Q188,5 200,14 Z;M0,14 Q12,7 25,5 Q38,7 50,5 Q62,8 75,3 Q88,7 100,5 Q112,8 125,3 Q138,7 150,5 Q162,7 175,5 Q188,7 200,14 Z;M0,14 Q12,9 25,4 Q38,10 50,3 Q62,9 75,4 Q88,10 100,3 Q112,9 125,4 Q138,10 150,3 Q162,9 175,4 Q188,9 200,14 Z'/%3E%3C/path%3E%3Cpath fill='%23fde047' opacity='0.96'%3E%3Canimate attributeName='d' dur='0.62s' repeatCount='indefinite' values='M0,14 Q12,7 25,11 Q38,6 50,10 Q62,6 75,11 Q88,5 100,10 Q112,6 125,11 Q138,6 150,10 Q162,7 175,11 Q188,8 200,14 Z;M0,14 Q12,11 25,6 Q38,11 50,6 Q62,11 75,6 Q88,11 100,6 Q112,11 125,6 Q138,11 150,6 Q162,11 175,7 Q188,11 200,14 Z;M0,14 Q12,7 25,11 Q38,6 50,10 Q62,6 75,11 Q88,5 100,10 Q112,6 125,11 Q138,6 150,10 Q162,7 175,11 Q188,8 200,14 Z'/%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: 100% 100%;
  pointer-events: none;
  z-index: 4;
}

.lobby-ad-boosters {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 4px;
}

.ad-boost-btn {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid rgba(249, 115, 22, 0.55);
  background: linear-gradient(180deg, rgba(30, 27, 38, 0.94) 0%, rgba(15, 23, 42, 0.96) 100%);
  color: #f8fafc;
  cursor: pointer;
  text-align: left;
  transition: transform 0.14s ease, border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(254, 240, 138, 0.18);
}

.ad-boost-btn.cash-boost {
  border-color: rgba(245, 158, 11, 0.55);
}

.ad-boost-btn.skin-boost {
  border-color: rgba(249, 115, 22, 0.55);
}

.ad-boost-btn:hover {
  transform: translateY(-2px);
  border-color: #fde047;
  box-shadow: 0 6px 20px rgba(249, 115, 22, 0.35), inset 0 1px 0 rgba(254, 240, 138, 0.35);
}

.ad-boost-btn.active {
  border-color: rgba(52, 211, 153, 0.65);
  background: linear-gradient(135deg, rgba(6, 78, 59, 0.55) 0%, rgba(15, 23, 42, 0.95) 100%);
  box-shadow: 0 2px 10px rgba(16, 185, 129, 0.22);
}

.ad-boost-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4));
}

.ad-boost-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.22;
}

.ad-boost-title {
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.03em;
  color: #fef08a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ad-boost-btn.active .ad-boost-title {
  color: #6ee7b7;
}

.ad-boost-sub {
  font-size: 0.62rem;
  font-weight: 700;
  color: #cbd5e1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.skin-action-btn.ad-trial {
  background: linear-gradient(135deg, #f59e0b 0%, #ea580c 100%);
  color: #ffffff;
  border: 1px solid #fef08a;
  font-weight: 900;
  cursor: pointer;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  box-shadow: 0 0 12px rgba(249, 115, 22, 0.45);
}

.skin-action-btn.ad-trial:hover {
  filter: brightness(1.1);
}

/* Death Modal Vault Row & 2x Vault Button */
.death-vault-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  background: rgba(15, 23, 42, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 8px 11px;
}

.ad-vault-double-btn {
  padding: 6px 12px;
  border-radius: 8px;
  border: 1px solid rgba(253, 224, 71, 0.7);
  background: linear-gradient(135deg, rgba(124, 45, 18, 0.65) 0%, rgba(30, 41, 59, 0.95) 100%);
  color: #fef08a;
  font-family: var(--font-main);
  font-size: 0.68rem;
  font-weight: 850;
  cursor: pointer;
  transition: transform 0.12s, background 0.15s;
}

.ad-vault-double-btn:hover:not(:disabled) {
  transform: translateY(-1px);
  border-color: #fde047;
}

.ad-vault-double-btn.claimed {
  border-color: #34d399;
  background: rgba(16, 185, 129, 0.25);
  color: #6ee7b7;
  cursor: default;
}

/* Death Modal 1x Per-Game Revive Box */
.death-revive-box {
  width: 100%;
  margin-top: 4px;
}

.revive-ad-btn {
  width: 100%;
  background: linear-gradient(180deg, rgba(20, 83, 45, 0.92) 0%, rgba(6, 78, 59, 0.96) 100%) !important;
  border: 1.5px solid rgba(253, 224, 71, 0.75) !important;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(254, 240, 138, 0.25) !important;
  padding: 10px 14px !important;
}

.revive-ad-btn:hover {
  border-color: #fde047 !important;
  box-shadow: 0 8px 24px rgba(249, 115, 22, 0.35), inset 0 1px 0 rgba(254, 240, 138, 0.4) !important;
}

.revive-ad-btn .play-btn-main {
  font-size: 0.88rem !important;
  color: #ffffff !important;
  letter-spacing: 0.02em;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.6);
}

.revive-ad-btn .play-btn-sub {
  font-size: 0.68rem !important;
  color: #fef08a !important;
  font-weight: 700 !important;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

/* Tone down the normal new-game Respawn button in Death Modal so it doesn't clash with the fiery Ad Revive button */
.death-actions .respawn-btn {
  background: linear-gradient(135deg, #334155 0%, #1e293b 100%);
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  padding: 9px 14px;
}

.death-actions .respawn-btn:hover {
  background: linear-gradient(135deg, #475569 0%, #334155 100%);
  border-color: rgba(255, 255, 255, 0.38);
}

.death-actions .respawn-btn .play-btn-main {
  font-size: 0.84rem;
  color: #f8fafc;
}

.death-actions .respawn-btn .play-btn-sub {
  font-size: 0.64rem;
  color: #94a3b8;
}

.death-revive-used-note {
  font-size: 0.68rem;
  font-weight: 700;
  color: #94a3b8;
  background: rgba(2, 6, 23, 0.55);
  border: 1px dashed rgba(148, 163, 184, 0.3);
  border-radius: 8px;
  padding: 6px 10px;
  text-align: center;
}

/* Simulated Rewarded Ad Overlay (Localhost / Dev Preview) */
.ad-sim-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(2, 6, 23, 0.88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.ad-sim-overlay.hidden {
  display: none !important;
}

.ad-sim-card {
  width: min(420px, 92vw);
  background: linear-gradient(145deg, #0f172a 0%, #020617 100%);
  border: 2px solid #f59e0b;
  border-radius: 16px;
  padding: 22px 24px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.75), 0 0 30px rgba(245, 158, 11, 0.25);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
}

.ad-sim-badge {
  background: rgba(245, 158, 11, 0.2);
  border: 1px solid rgba(245, 158, 11, 0.5);
  color: #fde047;
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  padding: 3px 10px;
  border-radius: 999px;
}

.ad-sim-title {
  font-size: 1.15rem;
  font-weight: 900;
  color: #ffffff;
  margin: 0;
}

.ad-sim-desc {
  font-size: 0.78rem;
  color: #94a3b8;
  margin: 0;
}

.ad-sim-progress-track {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  overflow: hidden;
}

.ad-sim-progress-fill {
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #f59e0b 0%, #10b981 100%);
  border-radius: 999px;
  transition: width 1.15s linear;
}

.ad-sim-footer {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 4px;
}

.ad-sim-timer {
  font-size: 0.72rem;
  font-weight: 700;
  color: #cbd5e1;
}

.ad-sim-skip-btn {
  padding: 6px 12px;
  border-radius: 8px;
  border: 1px solid #34d399;
  background: rgba(16, 185, 129, 0.22);
  color: #6ee7b7;
  font-size: 0.72rem;
  font-weight: 800;
  cursor: pointer;
}

.ad-sim-skip-btn:hover {
  background: rgba(16, 185, 129, 0.38);
}
