﻿:root {
  --bg-0: #080c16;
  --bg-1: #0d1225;
  --bg-2: #151c35;
  --bg-3: #1c2545;
  --realism-x: 50%;
  --realism-y: 50%;
  --ui-tilt-x: 0.5;
  --ui-tilt-y: 0.5;
  --risk-intensity: 0.12;
  --wealth-intensity: 0.08;
  --panel: rgba(13, 18, 37, 0.82);
  --panel-2: rgba(21, 28, 53, 0.92);
  --line: rgba(130, 160, 220, 0.08);
  --line-strong: rgba(130, 160, 220, 0.15);
  --text-main: #e8edf5;
  --text-muted: #7b8baa;
  --text-dim: #4a577a;
  --blue: #4f8fff;
  --cyan: #22d3ee;
  --green: #34d399;
  --amber: #fbbf24;
  --red: #f87171;
  --purple: #a78bfa;
  --pink: #f472b6;
  --font-ui: "Nunito", sans-serif;
  --font-mono: "JetBrains Mono", monospace;
  --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.25);
  --shadow-lift: 0 12px 40px -8px rgba(0, 0, 0, 0.45);
  --border-dim: rgba(130, 160, 220, 0.06);
  --border-bright: rgba(130, 160, 220, 0.12);
  --border-light: rgba(130, 160, 220, 0.1);
  --text-main-legacy: #e2e8f0;
  --accent-blue: #60a5fa;
  --accent-green: #4ade80;
  --accent-red: #f87171;
  --accent-amber: #fbbf24;
  --accent-cyan: #22d3ee;
  --accent-purple: #c084fc;
  --ui-radius: 16px;
  --glass: rgba(13, 18, 37, 0.65);
  --glass-border: rgba(130, 160, 220, 0.1);
  --glass-blur: 20px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html,
body {
  width: 100%;
  height: 100%;
}

body.tension-mid {
  filter: saturate(1.08) contrast(1.06);
}
body.tension-high {
  filter: saturate(1.16) contrast(1.1);
}
body.tension-critical {
  filter: saturate(1.24) contrast(1.16);
}

body {
  font-family: var(--font-ui);
  color: var(--text-main);
  background: var(--bg-0);
  overflow: hidden;
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* â•â• ANIMATED BACKGROUND MESH â•â• */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(
      ellipse 800px 600px at 15% 20%,
      rgba(79, 143, 255, 0.06),
      transparent 70%
    ),
    radial-gradient(
      ellipse 600px 500px at 85% 75%,
      rgba(167, 139, 250, 0.05),
      transparent 70%
    ),
    radial-gradient(
      ellipse 700px 400px at 50% 90%,
      rgba(52, 211, 153, 0.04),
      transparent 70%
    );
  animation: meshFloat 20s ease-in-out infinite;
}
@keyframes meshFloat {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.7;
  }
}

.app-shell::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0;
  transition: opacity 0.28s ease;
}

body.ui-decay-mild .app-shell::before {
  opacity: 0.2;
  background: radial-gradient(
    1000px 620px at 15% 115%,
    rgba(251, 191, 36, 0.1),
    transparent 68%
  );
}
body.ui-decay-high .app-shell::before {
  opacity: 0.28;
  background:
    radial-gradient(
      1050px 680px at -5% 115%,
      rgba(248, 113, 113, 0.2),
      transparent 70%
    ),
    linear-gradient(180deg, rgba(18, 10, 14, 0.18), transparent 40%);
}
body.ui-decay-critical .app-shell::before {
  opacity: 0.42;
  background:
    radial-gradient(
      1100px 700px at 50% 120%,
      rgba(239, 68, 68, 0.3),
      transparent 72%
    ),
    linear-gradient(180deg, rgba(8, 4, 7, 0.35), rgba(8, 4, 7, 0.05));
}

#bg-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  opacity: 0.5;
  pointer-events: none;
  mix-blend-mode: screen;
  filter: saturate(1.3) contrast(1.1);
}

.app-shell {
  position: relative;
  z-index: 1;
  padding: 10px;
  height: 100%;
}

.app-container {
  display: grid;
  grid-template-columns: 290px 1fr;
  height: 100vh;
  width: 100vw;
  overflow: hidden;
  background: transparent;
  gap: 10px;
  padding: 10px;
  position: relative;
}

body.tension-high .app-container,
body.tension-critical .app-container {
  border-color: rgba(248, 113, 113, 0.6);
  box-shadow:
    0 0 0 1px rgba(248, 113, 113, 0.35) inset,
    0 30px 70px rgba(0, 0, 0, 0.65);
}
body.tension-critical .app-container {
  animation: dangerPulse 1.45s ease-in-out infinite;
}
@keyframes dangerPulse {
  0%,
  100% {
    box-shadow:
      0 0 0 1px rgba(248, 113, 113, 0.25) inset,
      0 30px 80px rgba(0, 0, 0, 0.6);
  }
  50% {
    box-shadow:
      0 0 0 2px rgba(248, 113, 113, 0.5) inset,
      0 30px 80px rgba(0, 0, 0, 0.6),
      0 0 40px rgba(239, 68, 68, 0.15);
  }
}
@keyframes heatPulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.7;
    border-color: rgba(248, 113, 113, 0.4);
  }
}
body.ui-decay-high .app-container {
  filter: saturate(0.9) contrast(1.08);
}
body.ui-decay-critical .app-container {
  filter: saturate(0.78) contrast(1.14) brightness(0.9);
}
body.ui-debt-high .sidebar {
  box-shadow: inset 0 0 0 1px rgba(245, 158, 11, 0.35);
}
body.ui-crime-hot .risk-hud {
  box-shadow:
    inset 0 0 0 1px rgba(248, 113, 113, 0.35),
    0 0 22px rgba(239, 68, 68, 0.22);
}
body.ui-aging .age-display {
  color: #fca5a5;
  text-shadow: 0 0 10px rgba(248, 113, 113, 0.3);
}

/* â•â• GLASS SIDEBAR â•â• */
.sidebar {
  display: flex;
  flex-direction: column;
  background: var(--glass);
  backdrop-filter: blur(var(--glass-blur)) saturate(1.3);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(1.3);
  border-radius: 20px;
  border: 1px solid var(--glass-border);
  overflow-y: auto;
  box-shadow:
    var(--shadow-lift),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
  position: relative;
}
.sidebar::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 120px;
  background: linear-gradient(180deg, rgba(79, 143, 255, 0.06), transparent);
  border-radius: 20px 20px 0 0;
  pointer-events: none;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 20px;
  background: transparent;
  position: relative;
  z-index: 1;
}
.brand i {
  color: var(--amber);
  font-size: 1.5rem;
  filter: drop-shadow(0 0 8px rgba(251, 191, 36, 0.5));
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  animation: gemPulse 3s ease-in-out infinite;
}
.brand-logo {
  width: 66px;
  height: 66px;
  object-fit: contain;
  filter: drop-shadow(0 0 8px rgba(251, 191, 36, 0.5));
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  animation: gemPulse 3s ease-in-out infinite;
}
.brand:hover .brand-logo {
  transform: rotate(15deg) scale(1.15);
}
@keyframes gemPulse {
  0%,
  100% {
    filter: drop-shadow(0 0 8px rgba(251, 191, 36, 0.5));
  }
  50% {
    filter: drop-shadow(0 0 16px rgba(251, 191, 36, 0.8));
  }
}
.brand:hover i {
  transform: rotate(15deg) scale(1.15);
}
.brand h1 {
  font-family: var(--font-ui);
  font-weight: 900;
  font-size: 1.2rem;
  letter-spacing: 1px;
  background: linear-gradient(135deg, #fff, #a0b4d0);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.brand p {
  color: var(--text-muted);
  font-size: 0.75rem;
  font-weight: 600;
  margin-top: 2px;
  letter-spacing: 0.5px;
}

/* â•â• STATS â•â• */
.stats-grid,
.stat-bars {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px 14px;
}
.stat-bars {
  border-top: 1px solid var(--line);
}

.stat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--border-dim);
  background: rgba(21, 28, 53, 0.5);
  font-family: var(--font-ui);
  margin-bottom: 4px;
  transition: all 0.2s ease;
}
.stat-row:hover {
  background: rgba(21, 28, 53, 0.8);
  border-color: var(--border-bright);
}

.stat-row.hero {
  background: linear-gradient(
    135deg,
    rgba(79, 143, 255, 0.08),
    rgba(167, 139, 250, 0.05)
  );
  padding: 20px;
  border: 1px solid rgba(79, 143, 255, 0.15);
  text-align: center;
  flex-direction: column;
  gap: 6px;
  border-radius: 16px;
}
.stat-row.hero .label {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
}
.stat-row.hero .value {
  font-size: 2.6rem;
  font-weight: 900;
  color: var(--text-main);
  text-align: center;
  line-height: 1;
  font-family: var(--font-mono);
  letter-spacing: -1px;
}
.stat-row.hero.networth-rich .value {
  color: var(--green);
  text-shadow: 0 0 30px rgba(52, 211, 153, 0.4);
}
.stat-row.hero.networth-danger .value {
  color: var(--red);
  text-shadow: 0 0 20px rgba(248, 113, 113, 0.3);
}
.stat-row .label {
  color: var(--text-muted);
  font-size: 0.72rem;
  letter-spacing: 0.6px;
  text-transform: uppercase;
}
.stat-row .value {
  color: var(--accent-blue);
  font-weight: 800;
  font-family: var(--font-mono);
}
.mono-strong {
  font-family: var(--font-mono);
  font-weight: 700;
  color: var(--accent-blue);
}
.econ-widget {
  display: none;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02);
  padding: 8px;
}
.econ-row {
  background: transparent;
  border: 0;
  padding: 2px 1px;
}
.econ-value {
  color: var(--amber) !important;
}

/* â•â• PROGRESS BARS â€” ANIMATED SHIMMER â•â• */
.bar-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.bar-label {
  display: flex;
  justify-content: space-between;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.7rem;
}
.bar-label span:last-child {
  font-size: 0.75rem;
  color: #c8d6f0;
  font-weight: 700;
}

.progress-bg {
  width: 100%;
  height: 12px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(21, 28, 53, 0.8);
  border: 1px solid var(--border-dim);
  position: relative;
}
.progress-fill {
  height: 100%;
  border-radius: 999px;
  min-width: 8px;
  transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}
.progress-fill::after {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 200%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.15) 45%,
    rgba(255, 255, 255, 0.3) 50%,
    rgba(255, 255, 255, 0.15) 55%,
    transparent 100%
  );
  animation: shimmer 2.5s ease-in-out infinite;
}
@keyframes shimmer {
  0% {
    transform: translateX(-30%);
  }
  100% {
    transform: translateX(70%);
  }
}

.fill-health {
  background: linear-gradient(90deg, #ef4444, #f97316, #fbbf24);
}
.fill-energy {
  background: linear-gradient(90deg, #f59e0b, #eab308, #84cc16);
}
.fill-happiness {
  background: linear-gradient(90deg, #06b6d4, #38bdf8, #818cf8);
}
.fill-smarts {
  background: linear-gradient(90deg, #3b82f6, #6366f1, #8b5cf6);
}

/* â•â• RISK HUD â•â• */
.risk-hud {
  margin: 8px 12px;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid var(--border-dim);
  background: rgba(21, 28, 53, 0.5);
  backdrop-filter: blur(12px);
  transition: all 0.3s ease;
}
.risk-hud:hover {
  border-color: var(--border-bright);
  background: rgba(21, 28, 53, 0.7);
}
.hud-title {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-dim);
  margin-bottom: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}
.hud-title::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
  animation: statusBlink 2s ease-in-out infinite;
}
@keyframes statusBlink {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.3;
  }
}
.hud-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 0.78rem;
  padding: 5px 0;
  border-bottom: 1px solid var(--border-dim);
  font-weight: 600;
  transition: color 0.2s ease;
}
.hud-row:hover {
  color: var(--text-main);
}
.hud-row:last-child {
  border-bottom: 0;
}
.hud-row span:last-child {
  font-family: var(--font-mono);
  color: var(--text-main);
  font-weight: 600;
  font-size: 0.75rem;
}
#hud-death-risk,
#hud-burnout {
  font-size: 0.85rem;
  font-weight: 700;
}
.risk-critical {
  color: var(--red) !important;
  font-weight: 800;
  text-shadow: 0 0 8px rgba(248, 113, 113, 0.4);
}

.age-display {
  margin-top: auto;
  border-top: 1px solid var(--line);
  padding: 14px 16px;
  font-family: var(--font-mono);
  color: var(--text-muted);
  text-align: right;
  font-size: 0.85rem;
  letter-spacing: 0.5px;
  background: rgba(0, 0, 0, 0.15);
  border-radius: 0 0 20px 20px;
}

/* â•â• MAIN AREA â•â• */
.main-area {
  display: grid;
  grid-template-columns: 1fr 180px;
  grid-template-rows: 1fr auto;
  overflow: hidden;
  background: var(--glass);
  backdrop-filter: blur(var(--glass-blur)) saturate(1.2);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(1.2);
  border-radius: 20px;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-lift);
  position: relative;
}

/* â•â• NAV TABS â€” GLOWING PILLS â•â• */
.nav-tabs {
  grid-column: 2;
  grid-row: 1 / -1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 12px 8px;
  border-left: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.12);
  overflow-y: auto;
  overflow-x: hidden;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 14px;
  border-radius: 10px;
  color: var(--text-dim);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  background: transparent;
  border: 1px solid transparent;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
  white-space: nowrap;
}
.nav-item i {
  font-size: 0.85rem;
  transition: transform 0.2s ease;
  width: 18px;
  text-align: center;
  flex-shrink: 0;
}
.nav-item:hover {
  background: rgba(79, 143, 255, 0.06);
  color: var(--text-main);
  border-color: var(--border-dim);
}
.nav-item:hover i {
  transform: scale(1.15);
}
.nav-item.active {
  background: linear-gradient(
    135deg,
    rgba(79, 143, 255, 0.2),
    rgba(99, 102, 241, 0.15)
  );
  color: #fff;
  border-color: rgba(79, 143, 255, 0.3);
  box-shadow:
    0 0 20px rgba(79, 143, 255, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}
.nav-item.active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 15%;
  bottom: 15%;
  width: 3px;
  background: var(--blue);
  border-radius: 2px;
  box-shadow: 0 0 10px var(--blue);
}
.nav-save-item {
  display: none;
}
.nav-close-btn {
  display: none;
}

/* â•â• VIEW CONTAINERS â•â• */
.view-container {
  grid-column: 1;
  display: none;
  overflow-y: auto;
  padding: 28px;
  background: transparent;
}
.view-container.active {
  display: block;
  animation: viewFadeIn 0.3s ease;
}
@keyframes viewFadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

body.run-ended .nav-tabs {
  border-bottom-color: rgba(248, 113, 113, 0.45);
  background: linear-gradient(
    180deg,
    rgba(38, 12, 19, 0.95),
    rgba(14, 8, 13, 0.94)
  );
}

.section-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-ui);
  color: var(--text-main);
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: 0.5px;
}
.section-title i {
  color: var(--accent-blue);
  font-size: 1rem;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(79, 143, 255, 0.1);
  border-radius: 8px;
  border: 1px solid rgba(79, 143, 255, 0.15);
}

.section-subtitle {
  margin: 32px 0 16px;
  font-size: 0.95rem;
  color: var(--text-muted);
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}
.section-subtitle::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--line-strong), transparent);
}
.section-subtitle.tight {
  margin-top: 0;
}

/* â•â• JS DYNAMIC CONTENT HELPERS â•â• */
.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-dim);
}
.panel-title h2 {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 4px;
}
.panel-subtitle {
  font-size: 0.95rem;
  color: var(--text-muted);
  font-weight: 600;
}
.stats-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 24px;
}
.stat-meta-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-muted);
}
.stat-note {
  font-size: 0.8rem;
  color: var(--text-dim);
  font-style: italic;
  margin-top: 12px;
}
.action-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}
.btn-multiline {
  height: auto;
  min-height: 60px;
  flex-direction: column;
  line-height: 1.3;
  padding: 12px;
}
.btn-multiline span {
  display: block;
}
.btn-subtext {
  font-size: 0.75rem;
  opacity: 0.7;
  font-weight: 500;
  margin-top: 4px;
}
.panel-footer {
  display: flex;
  gap: 12px;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--border-dim);
}
.empty-state {
  text-align: center;
  padding: 60px 40px;
  border: 1px dashed rgba(130, 160, 220, 0.15);
  border-radius: 20px;
  background: rgba(21, 28, 53, 0.3);
}
.empty-icon {
  font-size: 3rem;
  color: var(--text-dim);
  margin-bottom: 20px;
  transform: rotate(-10deg);
}
.empty-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 8px;
}
.empty-desc {
  color: var(--text-muted);
}

/* â•â• CARD GRID â•â• */
.grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
}
.gallery-dots {
  display: none;
}

/* â•â• GLASSMORPHISM CARDS â•â• */
.card {
  position: relative;
  border-radius: 14px;
  border: 1px solid var(--border-dim);
  background: rgba(21, 28, 53, 0.45);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 20px;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}
.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.06),
    transparent
  );
  pointer-events: none;
}
.card:hover {
  transform: translateY(-4px);
  border-color: rgba(79, 143, 255, 0.2);
  background: rgba(21, 28, 53, 0.65);
  box-shadow:
    0 20px 50px -10px rgba(0, 0, 0, 0.4),
    0 0 30px rgba(79, 143, 255, 0.06);
}
.card h3 {
  font-size: 1rem;
  line-height: 1.3;
  font-weight: 800;
  color: var(--text-main);
}
.card p {
  color: var(--text-muted);
  font-size: 0.84rem;
  line-height: 1.6;
}

/* â•â• TAGS â•â• */
.tag {
  border-radius: 8px;
  border: 0;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.7rem;
  padding: 4px 10px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}
.tag.safe {
  color: var(--green);
  background: rgba(52, 211, 153, 0.12);
  border: 1px solid rgba(52, 211, 153, 0.2);
}
.tag.risk {
  color: var(--red);
  background: rgba(248, 113, 113, 0.12);
  border: 1px solid rgba(248, 113, 113, 0.2);
}

/* â•â• BUTTONS â€” PREMIUM â•â• */
.btn {
  width: 100%;
  padding: 12px 18px;
  border-radius: 10px;
  border: 1px solid var(--border-bright);
  background: rgba(21, 28, 53, 0.6);
  color: var(--text-main);
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 0.88rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}
.btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.05),
    transparent
  );
  transition: left 0.5s ease;
}
.btn:hover::before {
  left: 100%;
}
.btn:hover {
  transform: translateY(-2px);
  border-color: rgba(79, 143, 255, 0.3);
  background: rgba(21, 28, 53, 0.8);
  box-shadow:
    0 8px 25px rgba(0, 0, 0, 0.3),
    0 0 15px rgba(79, 143, 255, 0.08);
}
.btn:active {
  transform: translateY(1px);
  box-shadow: none;
}
.btn:disabled,
.btn[disabled] {
  opacity: 0.4;
  cursor: not-allowed;
  background: rgba(21, 28, 53, 0.3);
  border-color: var(--border-dim);
  box-shadow: none;
  transform: none;
}
.btn:disabled::before,
.btn[disabled]::before {
  display: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--blue), #6366f1);
  border: 1px solid rgba(79, 143, 255, 0.4);
  color: white;
  box-shadow: 0 4px 15px rgba(79, 143, 255, 0.2);
}
.btn-primary:hover {
  background: linear-gradient(135deg, #60a5fa, #818cf8);
  box-shadow: 0 8px 30px rgba(79, 143, 255, 0.35);
  border-color: rgba(96, 165, 250, 0.5);
}
.btn-outline {
  background: rgba(255, 255, 255, 0.02);
  border-color: var(--border-bright);
  color: var(--text-muted);
}
.btn-outline:hover {
  border-color: rgba(130, 160, 220, 0.3);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-main);
}
.btn-success {
  color: var(--green);
  border-color: rgba(52, 211, 153, 0.3);
  background: rgba(52, 211, 153, 0.08);
}
.btn-success:hover {
  background: rgba(52, 211, 153, 0.15);
  border-color: rgba(52, 211, 153, 0.5);
  box-shadow: 0 8px 25px rgba(52, 211, 153, 0.15);
}
.btn-danger {
  color: var(--red);
  border-color: rgba(248, 113, 113, 0.3);
  background: rgba(248, 113, 113, 0.08);
}
.btn-danger:hover {
  background: rgba(248, 113, 113, 0.15);
  border-color: rgba(248, 113, 113, 0.5);
  box-shadow: 0 8px 25px rgba(248, 113, 113, 0.15);
}
.btn-save {
  min-height: 34px;
  padding: 8px 12px;
  border-radius: 8px;
}
.btn-save:hover {
  border-color: rgba(79, 143, 255, 0.3);
  background: rgba(79, 143, 255, 0.08);
  color: var(--accent-blue);
}
.btn-save:hover i {
  transform: scale(1.15);
}
.btn-save i {
  transition: transform 0.2s ease;
}

.panel-current-job {
  border-left: 3px solid var(--blue);
  margin-bottom: 24px;
  box-shadow: inset 3px 0 10px rgba(79, 143, 255, 0.08);
}
.incubator-card {
  margin-bottom: 24px;
  background: linear-gradient(
    135deg,
    rgba(79, 143, 255, 0.06),
    rgba(167, 139, 250, 0.04)
  );
  border-color: rgba(79, 143, 255, 0.15);
}
.incubator-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
}
.incubator-cta {
  width: auto;
  padding: 12px 20px;
}
.inventory-block {
  margin-bottom: 24px;
}

/* â•â• MARKET CHART â•â• */
.chart-box {
  height: 320px;
  border-radius: 16px;
  border: 1px solid var(--border-dim);
  margin-bottom: 24px;
  background: rgba(21, 28, 53, 0.4);
  position: relative;
  overflow: hidden;
  backdrop-filter: blur(12px);
}
.chart-box::before {
  content: "MARKET OVERVIEW";
  position: absolute;
  top: 16px;
  right: 20px;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.7rem;
  letter-spacing: 2px;
  color: var(--text-dim);
  opacity: 0.4;
}
.chart-box::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40%;
  background: linear-gradient(180deg, transparent, rgba(8, 12, 22, 0.5));
  pointer-events: none;
}

/* â•â• CRIME â•â• */
.crime-dashboard {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 24px;
}
.crime-stat-card {
  margin: 0;
  text-align: center;
  background: rgba(21, 28, 53, 0.5);
}
.crime-stat-title {
  color: var(--text-dim);
  letter-spacing: 1.5px;
  font-size: 0.7rem;
  font-family: var(--font-mono);
}
.heat-meter {
  margin: 12px 0;
  height: 10px;
}
#meter-heat {
  width: 0;
  background: linear-gradient(90deg, #ef4444, #dc2626, #991b1b);
}
.heat-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
}
.heat-btn {
  width: auto;
  min-height: 24px;
  font-size: 0.68rem;
  padding: 2px 8px;
}
.rep-value {
  margin-top: 4px;
  font-size: 2rem;
  font-weight: 900;
  background: linear-gradient(135deg, var(--purple), var(--pink));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.rep-subtitle {
  color: var(--text-dim);
  font-size: 0.78rem;
}
.crime-warning {
  border-radius: 10px;
  border: 1px solid rgba(248, 113, 113, 0.2);
  background: rgba(239, 68, 68, 0.06);
  color: #fca5a5;
  padding: 14px 16px;
  margin-bottom: 20px;
  font-size: 0.85rem;
  backdrop-filter: blur(8px);
}
body.tension-high .crime-warning,
body.tension-critical .crime-warning {
  animation: heatPulse 1.1s ease-in-out infinite;
}

/* â•â• MODAL â€” GLASS â•â• */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(2, 4, 10, 0.8);
  backdrop-filter: blur(12px);
}
.modal-overlay.open {
  display: flex;
  animation: modalBgIn 0.3s ease;
}
@keyframes modalBgIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
.modal-content {
  width: min(480px, 90vw);
  border-radius: 20px;
  border: 1px solid var(--border-bright);
  background: var(--glass);
  backdrop-filter: blur(30px) saturate(1.4);
  -webkit-backdrop-filter: blur(30px) saturate(1.4);
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  padding: 32px;
  text-align: center;
  animation: modalSlideIn 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}
.modal-header h2 {
  font-family: var(--font-ui);
  font-weight: 800;
  font-size: 1.4rem;
  color: var(--text-main);
  padding-bottom: 14px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--border-dim);
}
.modal-desc {
  color: var(--text-muted);
  margin-bottom: 24px;
  font-size: 0.92rem;
  line-height: 1.6;
}
#modal-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* â•â• CARD ANIMATIONS â•â• */
#job-list > .card,
#startup-list > .card,
#market-list > .card,
#crime-list > .card,
#edu-list > .card,
#shop-list > .card,
#inventory-list > .card {
  animation: cardIn 250ms cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes cardIn {
  from {
    transform: translateY(10px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* â•â• SECTION CARD BORDERS â•â• */
#crime-list .card {
  border-color: var(--border-dim);
}
#crime-list .card:hover {
  border-color: rgba(248, 113, 113, 0.3);
  box-shadow:
    0 20px 50px -10px rgba(0, 0, 0, 0.4),
    0 0 20px rgba(248, 113, 113, 0.08);
}
#startup-list .card:hover {
  border-color: rgba(167, 139, 250, 0.3);
  box-shadow:
    0 20px 50px -10px rgba(0, 0, 0, 0.4),
    0 0 20px rgba(167, 139, 250, 0.08);
}
#market-list .card:hover {
  border-color: rgba(52, 211, 153, 0.3);
  box-shadow:
    0 20px 50px -10px rgba(0, 0, 0, 0.4),
    0 0 20px rgba(52, 211, 153, 0.08);
}
#edu-list .card:hover {
  border-color: rgba(79, 143, 255, 0.3);
}
#edu-list #skill-cloud {
  border: 1px solid var(--border-dim);
  border-radius: 12px;
  padding: 14px;
  background: rgba(21, 28, 53, 0.3);
}
#inventory-list > div[style*="grid-column: span 3"] {
  border: 1px dashed var(--line-strong);
  border-radius: 12px;
  background: rgba(21, 28, 53, 0.2);
}
[style*="font-family:'JetBrains Mono'"],
[style*='font-family:"JetBrains Mono"'] {
  font-family: var(--font-mono) !important;
}

/* â•â• SCROLLBAR â•â• */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(130, 160, 220, 0.15);
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(130, 160, 220, 0.25);
}
::-webkit-scrollbar-track {
  background: transparent;
}

/* â•â• RESPONSIVE â•â• */
@media (max-width: 1320px) {
  .app-container {
    grid-template-columns: 280px 1fr;
  }
}
@media (max-width: 1220px) {
  .app-container {
    grid-template-columns: 260px 1fr;
  }
  .grid-cards {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  }
}
/* Old 640px block cleaned  rules moved to new responsive block */

/* â•â• CASINO & POLITICS â•â• */
.bet-input-group {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}
.bet-input {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-dim);
  border-radius: 8px;
  color: #fff;
  padding: 8px 10px;
  width: 100px;
  font-family: var(--font-mono);
  transition: all 0.2s ease;
}
.bet-input:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 12px rgba(79, 143, 255, 0.15);
}
.bet-btn {
  flex: 1;
}
.politics-dash-card {
  background: linear-gradient(
    135deg,
    rgba(79, 143, 255, 0.08),
    rgba(99, 102, 241, 0.04)
  );
  border: 1px solid rgba(79, 143, 255, 0.2);
  border-radius: 14px;
  padding: 24px;
  margin-bottom: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  backdrop-filter: blur(12px);
}
.politics-stat {
  text-align: center;
}
.politics-stat-val {
  font-size: 1.4em;
  font-weight: 800;
  color: #fff;
  font-family: var(--font-mono);
}
.politics-stat-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1.5px;
}
.campaign-progress {
  height: 10px;
  background: rgba(0, 0, 0, 0.4);
  border-radius: 999px;
  overflow: hidden;
  margin: 10px 0;
  border: 1px solid var(--border-dim);
}
.campaign-bar {
  height: 100%;
  background: linear-gradient(90deg, #4f8fff, #ec4899);
  width: 0%;
  transition: width 0.5s ease;
}

/* â•â• CASINO â•â• */
#casino-active-table {
  background: rgba(10, 10, 20, 0.9);
  border: 1px solid var(--border-dim);
  border-radius: 14px;
  padding: 24px;
  min-height: 400px;
  display: flex;
  flex-direction: column;
  backdrop-filter: blur(12px);
}
.casino-table-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-dim);
}
.game-stage {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}
.card-row {
  display: flex;
  gap: 10px;
  min-height: 100px;
  justify-content: center;
  margin: 10px 0;
}
.playing-card {
  width: 60px;
  height: 90px;
  background: white;
  border-radius: 8px;
  color: black;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 24px;
  font-weight: bold;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
  position: relative;
  user-select: none;
}
.playing-card.red {
  color: #d00;
}
.playing-card.black {
  color: #111;
}
.playing-card .corner {
  position: absolute;
  font-size: 12px;
}
.playing-card .top-left {
  top: 4px;
  left: 4px;
}
.playing-card .bottom-right {
  bottom: 4px;
  right: 4px;
  transform: rotate(180deg);
}
.dealer-area,
.player-area {
  width: 100%;
  text-align: center;
  margin: 20px 0;
}
.table-center {
  height: 40px;
}

.slot-machine-frame {
  background: linear-gradient(180deg, #d97706, #78350f);
  padding: 20px;
  border-radius: 16px;
  border: 4px solid var(--amber);
  box-shadow:
    0 0 40px rgba(251, 191, 36, 0.2),
    inset 0 0 20px rgba(0, 0, 0, 0.3);
}
.reels-container {
  display: flex;
  gap: 10px;
  background: #fff;
  padding: 10px;
  border-radius: 8px;
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.3);
}
.reel {
  width: 80px;
  height: 80px;
  font-size: 48px;
  background: #f8fafc;
  display: flex;
  justify-content: center;
  align-items: center;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
}
.racing-track {
  width: 100%;
  background: #1a3d25;
  padding: 10px;
  border-radius: 8px;
  position: relative;
  border: 1px solid rgba(52, 211, 153, 0.2);
}

#view-casino {
  background:
    radial-gradient(
      760px 420px at 10% -10%,
      rgba(251, 191, 36, 0.08),
      transparent 65%
    ),
    radial-gradient(
      780px 500px at 105% -10%,
      rgba(167, 139, 250, 0.08),
      transparent 66%
    );
}
#view-casino .section-title {
  color: #fde68a;
}
#view-casino .section-title i {
  color: var(--amber);
  background: rgba(251, 191, 36, 0.1);
  border-color: rgba(251, 191, 36, 0.15);
}
#casino-stat-card {
  margin-bottom: 16px;
}
.casino-hero {
  border-color: rgba(251, 191, 36, 0.2);
  background:
    linear-gradient(
      180deg,
      rgba(251, 191, 36, 0.06),
      rgba(255, 255, 255, 0.01) 48%
    ),
    rgba(21, 28, 53, 0.6);
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(251, 191, 36, 0.1);
}
.casino-hero-head {
  margin-bottom: 14px;
}
.casino-hero h3 {
  color: #fef3c7;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-family: var(--font-mono);
}
.casino-hero-text {
  color: var(--text-muted);
  max-width: 580px;
  margin-top: 6px;
}
.casino-kpi-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.casino-kpi-card {
  border-radius: 10px;
  border: 1px solid var(--border-dim);
  background: rgba(8, 12, 22, 0.5);
  padding: 12px;
  transition: all 0.2s ease;
}
.casino-kpi-card:hover {
  border-color: var(--border-bright);
  background: rgba(21, 28, 53, 0.5);
}
.casino-kpi-label {
  display: block;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.65rem;
  font-family: var(--font-mono);
}
.casino-kpi-value {
  display: block;
  margin-top: 4px;
  font-family: var(--font-mono);
  color: #f8fafc;
  font-size: 1rem;
  font-weight: 700;
}
.casino-meta-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}
.casino-intel-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 2px;
}
.casino-intel-item {
  border: 1px solid var(--border-dim);
  background: rgba(8, 12, 22, 0.4);
  border-radius: 10px;
  padding: 10px;
  transition: all 0.2s ease;
}
.casino-intel-item:hover {
  border-color: var(--border-bright);
}
.casino-intel-item span {
  color: var(--text-dim);
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.casino-intel-item strong {
  display: block;
  margin-top: 4px;
  color: #e2e8f0;
  font-family: var(--font-mono);
}
.casino-intel-tip {
  margin-top: 12px;
  color: var(--text-muted);
  font-size: 0.82rem;
}
.casino-recent-list {
  margin-top: 2px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.casino-recent-empty {
  color: var(--text-muted);
  font-size: 0.85rem;
}
.casino-recent-row {
  border: 1px solid var(--border-dim);
  border-radius: 8px;
  background: rgba(8, 12, 22, 0.3);
  padding: 8px 10px;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr 1fr 1fr;
  gap: 8px;
  font-size: 0.75rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  transition: all 0.2s ease;
}
.casino-recent-row:hover {
  background: rgba(21, 28, 53, 0.4);
}
.casino-recent-row.up {
  border-color: rgba(52, 211, 153, 0.2);
}
.casino-recent-row.down {
  border-color: rgba(248, 113, 113, 0.2);
}
#casino-games-list {
  gap: 12px;
}
.casino-game-card {
  background: rgba(21, 28, 53, 0.5);
  border: 1px solid var(--border-dim);
  border-radius: 14px;
  overflow: hidden;
  position: relative;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  backdrop-filter: blur(12px);
}
.casino-game-card:hover {
  transform: translateY(-4px);
  box-shadow:
    0 24px 50px rgba(0, 0, 0, 0.4),
    0 0 30px rgba(251, 191, 36, 0.06);
  border-color: rgba(251, 191, 36, 0.3);
}
.casino-game-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  opacity: 0.9;
}
.game-slots::before {
  background: linear-gradient(90deg, #d946ef, #9333ea);
}
.game-blackjack::before {
  background: linear-gradient(90deg, #10b981, #14b8a6);
}
.game-horse::before {
  background: linear-gradient(90deg, #fbbf24, #f97316);
}
.casino-game-header {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.casino-game-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  border: 1px solid var(--border-dim);
  background: rgba(8, 12, 22, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.casino-game-icon i {
  color: #fde68a;
  font-size: 1.1rem;
}
.casino-game-title {
  color: #f8fafc;
  margin-bottom: 4px;
}
.casino-game-desc {
  color: var(--text-muted);
  font-size: 0.82rem;
  line-height: 1.55;
}
.casino-chip-row {
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.casino-action-btn {
  margin-top: 14px;
}

@media (max-width: 1100px) {
  .casino-meta-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 900px) {
  .casino-kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .casino-recent-row {
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-width: 560px) {
  .casino-kpi-grid,
  .casino-intel-grid {
    grid-template-columns: 1fr;
  }
}

#casino-active-table {
  background: rgba(8, 10, 18, 0.95);
  border: 1px solid var(--border-dim);
  border-radius: 14px;
  padding: 24px;
  min-height: 500px;
  display: flex;
  flex-direction: column;
  backdrop-filter: blur(16px);
}
.casino-table-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--border-dim);
}
#active-game-title {
  font-size: 1.6rem;
  color: #fbbf24;
  text-transform: uppercase;
  font-weight: 800;
  font-family: var(--font-mono);
  letter-spacing: 2px;
}

#game-stage-blackjack {
  background: radial-gradient(
    ellipse at center,
    #1a5c38 0%,
    #0f3d24 60%,
    #0a2a19 100%
  );
  border-radius: 80px;
  border: 12px solid #2a1810;
  padding: 40px;
  position: relative;
  box-shadow:
    inset 0 0 60px rgba(0, 0, 0, 0.5),
    0 0 40px rgba(0, 0, 0, 0.4);
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 400px;
}
.dealer-area,
.player-area {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.hand-label {
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  padding: 5px 15px;
  border-radius: 20px;
  margin-bottom: 10px;
  font-weight: bold;
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 1px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}
.card-row {
  display: flex;
  justify-content: center;
  gap: 0;
  height: 120px;
}
.playing-card {
  width: 80px;
  height: 112px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.4);
  position: relative;
  margin-right: -20px;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 5px;
}
.playing-card:hover {
  transform: translateY(-12px) rotate(2deg);
  z-index: 10;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
}
.playing-card.red {
  color: #dc2626;
}
.playing-card.black {
  color: #111;
}
.playing-card .corner {
  font-weight: bold;
  font-size: 1rem;
  line-height: 1;
  text-align: center;
  width: 20px;
}
.playing-card .corner.top-left {
  align-self: flex-start;
}
.playing-card .corner.bottom-right {
  align-self: flex-end;
  transform: rotate(180deg);
}
.playing-card .center-suit {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 2.5rem;
  opacity: 0.7;
}
.playing-card.back {
  background: linear-gradient(
    135deg,
    #b91c1c 25%,
    #991b1b 25%,
    #991b1b 50%,
    #b91c1c 50%,
    #b91c1c 75%,
    #991b1b 75%,
    #991b1b 100%
  );
  background-size: 10px 10px;
  border: 2px solid #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: rgba(255, 255, 255, 0.2) !important;
}
.table-center {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 60px;
}
.bj-controls {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-top: 20px;
}
.bj-controls .btn {
  border-radius: 12px;
  padding: 10px 28px;
  font-weight: 800;
  font-size: 1rem;
}

.slot-machine-frame {
  background: linear-gradient(to bottom, #d97706, #78350f);
  border: 8px solid #fbbf24;
  border-radius: 20px;
  padding: 20px;
  box-shadow:
    0 0 40px rgba(251, 191, 36, 0.3),
    inset 0 0 20px rgba(0, 0, 0, 0.3);
  max-width: 500px;
  margin: 0 auto;
}
.reels-container {
  display: flex;
  justify-content: space-around;
  background: #fff;
  border: 4px solid #333;
  border-radius: 12px;
  padding: 10px;
  height: 150px;
  overflow: hidden;
  box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.4);
}
.reel {
  font-size: 4rem;
  width: 33%;
  display: flex;
  align-items: center;
  justify-content: center;
  border-right: 2px solid #e2e8f0;
  animation: none;
}
.reel:last-child {
  border-right: none;
}
.slot-controls {
  margin-top: 30px;
  text-align: center;
}
.slot-controls .btn-accent {
  font-size: 1.5rem;
  padding: 15px 40px;
  background: linear-gradient(to bottom, #ef4444, #b91c1c);
  border: 4px solid #7f1d1d;
  box-shadow: 0 5px 0 #7f1d1d;
  text-transform: uppercase;
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.5);
  border-radius: 12px;
  color: #fff;
  cursor: pointer;
  font-weight: 800;
}
.slot-controls .btn-accent:active {
  transform: translateY(4px);
  box-shadow: 0 1px 0 #7f1d1d;
}
.betting-controls {
  background: rgba(8, 12, 22, 0.8);
  padding: 15px;
  border-top: 1px solid var(--border-dim);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 15px;
  border-radius: 0 0 12px 12px;
}
.betting-controls input {
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid var(--border-dim);
  color: #fbbf24;
  padding: 10px;
  font-size: 1.2rem;
  width: 120px;
  text-align: center;
  border-radius: 8px;
  font-family: var(--font-mono);
}
.betting-controls input:focus {
  outline: none;
  border-color: var(--amber);
  box-shadow: 0 0 12px rgba(251, 191, 36, 0.15);
}

#view-casino .msg-box {
  background: rgba(0, 0, 0, 0.5);
  padding: 10px 20px;
  border-radius: 10px;
  color: #fff;
  font-weight: 700;
  font-size: 1.1rem;
  min-height: 40px;
  min-width: 200px;
  text-align: center;
  margin: 10px 0;
  backdrop-filter: blur(8px);
}
#view-casino .msg-box.text-success {
  color: var(--green);
  border: 1px solid rgba(52, 211, 153, 0.3);
  box-shadow: 0 0 15px rgba(52, 211, 153, 0.15);
}
#view-casino .msg-box.text-danger {
  color: var(--red);
  border: 1px solid rgba(248, 113, 113, 0.3);
  box-shadow: 0 0 15px rgba(248, 113, 113, 0.15);
}
#view-casino .msg-box.text-warning {
  color: var(--amber);
  border: 1px solid rgba(251, 191, 36, 0.3);
  box-shadow: 0 0 15px rgba(251, 191, 36, 0.15);
}

/* â•â• REALISM FX â•â• */
.app-container::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(
      500px 250px at var(--realism-x) -5%,
      rgba(255, 255, 255, 0.04),
      transparent 62%
    ),
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.02),
      transparent 25%,
      transparent 75%,
      rgba(0, 0, 0, 0.1)
    );
  mix-blend-mode: screen;
  opacity: 0.6;
  border-radius: 20px;
}
.card,
.crime-warning,
.risk-hud,
.control-bar {
  backdrop-filter: blur(12px) saturate(1.2);
  -webkit-backdrop-filter: blur(12px) saturate(1.2);
}
body.tension-high .app-container {
  box-shadow:
    0 0 0 1px rgba(248, 113, 113, 0.25) inset,
    0 30px 80px rgba(0, 0, 0, 0.6),
    0 0 calc(26px + var(--risk-intensity) * 34px)
      rgba(248, 113, 113, calc(0.1 + var(--risk-intensity) * 0.2));
}
body.tension-critical {
  animation: heartbeatTint 2.2s ease-in-out infinite;
}
@keyframes heartbeatTint {
  0%,
  100% {
    filter: saturate(1.18) contrast(1.08);
  }
  50% {
    filter: saturate(1.28) contrast(1.14);
  }
}
@media (prefers-reduced-motion: reduce) {
  .progress-fill::after {
    animation: none;
  }
  .next-month-btn::before {
    animation: none;
  }
  body::before {
    animation: none;
  }
}

/* â•â• JOB CARDS â•â• */
.job-card {
  padding: 18px;
  border-radius: 14px;
  border: 1px solid var(--border-dim);
  background: rgba(21, 28, 53, 0.4);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}
.job-card:hover {
  transform: translateY(-3px);
  border-color: var(--border-bright);
  background: rgba(21, 28, 53, 0.6);
}
.job-card.current {
  border-color: rgba(52, 211, 153, 0.3);
  background: rgba(52, 211, 153, 0.04);
  box-shadow: 0 0 20px rgba(52, 211, 153, 0.06);
}
.job-card.locked {
  opacity: 0.4;
  background: rgba(0, 0, 0, 0.2);
  pointer-events: none;
  border-color: transparent;
}
.job-head {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  align-items: center;
}
.job-title {
  font-weight: 800;
  color: var(--text-main);
  font-size: 0.95rem;
}
.job-salary {
  color: var(--accent-blue);
  font-weight: 700;
  font-size: 0.85rem;
  font-family: var(--font-mono);
}
.job-reqs {
  font-size: 0.78rem;
  color: var(--text-dim);
  margin-bottom: 14px;
  line-height: 1.5;
  flex-grow: 1;
}
.job-reqs i {
  color: var(--blue);
  margin-right: 6px;
}
.job-card .btn {
  width: 100%;
  font-size: 0.82rem;
  padding: 10px;
}
.edu-active-card {
  grid-column: span 2;
  border-color: rgba(52, 211, 153, 0.2);
  background: rgba(52, 211, 153, 0.03);
  box-shadow: 0 0 20px rgba(52, 211, 153, 0.06);
}
.edu-label {
  font-size: 0.75rem;
  color: var(--green);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 4px;
  font-weight: 700;
  font-family: var(--font-mono);
}
.edu-title {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--text-main);
}
.edu-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--text-muted);
  padding: 0 4px;
}
.edu-actions {
  margin-top: 24px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
}

/* â•â• DATA GRIDS â•â• */
.data-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}
.data-grid-4 {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
  margin-bottom: 14px;
}
.data-box {
  background: rgba(8, 12, 22, 0.4);
  border: 1px solid var(--border-dim);
  border-radius: 10px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  transition: all 0.2s ease;
}
.data-box:hover {
  border-color: var(--border-bright);
  background: rgba(21, 28, 53, 0.4);
}
.data-box.highlight-green {
  background: rgba(52, 211, 153, 0.04);
  border-color: rgba(52, 211, 153, 0.15);
}
.data-box.highlight-red {
  background: rgba(248, 113, 113, 0.04);
  border-color: rgba(248, 113, 113, 0.15);
}
.data-label {
  font-size: 0.68rem;
  color: var(--text-dim);
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 4px;
  letter-spacing: 0.8px;
  font-family: var(--font-mono);
}
.data-value {
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--text-main);
  font-family: var(--font-mono);
}
.data-value.green {
  color: var(--green);
}
.data-value.red {
  color: var(--red);
}
.card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-dim);
}
.card-header h3 {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 0;
  line-height: 1.2;
}
.action-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 14px;
}
.data-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}
@media (max-width: 768px) {
  .data-grid-4,
  .data-grid-3 {
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-width: 480px) {
  .data-grid-4,
  .data-grid-3 {
    grid-template-columns: 1fr;
  }
  .action-grid-4 {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

/* â•â• BANK â•â• */
.bank-offer-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}
.bank-offer-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 14px;
  background: rgba(8, 12, 22, 0.4);
  padding: 12px;
  border-radius: 10px;
  border: 1px solid var(--border-dim);
}
.bank-offer-meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.action-grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-top: 12px;
}
.action-grid-4 .btn {
  padding: 8px 4px;
  font-size: 0.78rem;
  flex-direction: column;
  gap: 2px;
}

/* â•â• CREDIT CARD â•â• */
.cc-viz {
  background: linear-gradient(135deg, #1c2545 0%, #0d1225 60%, #0a0e1c 100%);
  border-radius: 16px;
  padding: 24px;
  position: relative;
  overflow: hidden;
  margin-bottom: 24px;
  box-shadow:
    0 15px 40px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-dim);
  color: white;
  min-height: 180px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.cc-viz::before {
  content: "";
  position: absolute;
  top: -20%;
  right: -10%;
  width: 200px;
  height: 200px;
  background: radial-gradient(
    circle,
    rgba(79, 143, 255, 0.08) 0%,
    transparent 70%
  );
  z-index: 0;
}
.cc-viz::after {
  content: "";
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 200px;
  height: 200px;
  background: radial-gradient(
    circle,
    rgba(167, 139, 250, 0.06) 0%,
    transparent 70%
  );
  z-index: 0;
}
.cc-chip {
  width: 40px;
  height: 30px;
  background: linear-gradient(135deg, #fbbf24, #d97706);
  border-radius: 6px;
  margin-bottom: 20px;
  position: relative;
  box-shadow: 0 2px 6px rgba(251, 191, 36, 0.3);
}
.cc-number {
  font-family: var(--font-mono);
  font-size: 1.2rem;
  letter-spacing: 3px;
  word-spacing: 8px;
  z-index: 1;
}
.cc-bottom {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  z-index: 1;
}
.cc-label {
  font-size: 0.6rem;
  text-transform: uppercase;
  opacity: 0.5;
  letter-spacing: 1.5px;
}
.cc-name {
  font-weight: 700;
  font-size: 0.9rem;
}
.cc-logo {
  font-style: italic;
  font-weight: 900;
  font-size: 1.2rem;
  opacity: 0.6;
}
.credit-card-panel {
  max-width: 500px;
  margin: 0 auto;
}
.bank-layout {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.5rem;
}
.bank-full-width {
  grid-column: 1 / -1;
}
.transfer-group {
  background: rgba(21, 28, 53, 0.4);
  border: 1px solid var(--border-dim);
  padding: 14px;
  border-radius: 12px;
}
.transfer-group h4 {
  margin: 0 0 10px 0;
  font-size: 0.85rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.8px;
}
@media (min-width: 1024px) {
  .credit-card-panel {
    max-width: 100%;
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 2rem;
    align-items: start;
  }
  .credit-card-panel .card-header {
    grid-column: 1 / -1;
  }
  .credit-card-panel .cc-viz {
    margin: 0;
  }
  .credit-card-panel .cc-stats-area {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
  }
  .credit-card-panel .data-grid-4 {
    grid-template-columns: 1fr 1fr;
  }
}
#bank-credit.grid-cards {
  display: block;
}
@media (min-width: 1024px) {
  .credit-card-panel {
    background: linear-gradient(
      135deg,
      rgba(21, 28, 53, 0.6),
      rgba(13, 18, 37, 0.6)
    );
    border-left: 3px solid var(--accent-blue);
  }
  .cc-viz {
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
  }
}

.legend-chip {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-dim);
  padding: 6px 12px;
  background: rgba(21, 28, 53, 0.4);
  border: 1px solid var(--border-dim);
  border-radius: 8px;
  letter-spacing: 0.5px;
}
.power-tools {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* â•â• VIEW-SPECIFIC GRADIENTS â•â• */
#view-crime {
  background:
    radial-gradient(
      600px 400px at 10% -5%,
      rgba(248, 113, 113, 0.05),
      transparent 65%
    ),
    radial-gradient(
      500px 350px at 90% 100%,
      rgba(167, 139, 250, 0.04),
      transparent 65%
    );
}
#view-crime .section-title i {
  color: var(--red);
  background: rgba(248, 113, 113, 0.1);
  border-color: rgba(248, 113, 113, 0.15);
}
#view-wealth {
  background: radial-gradient(
    700px 400px at 50% -10%,
    rgba(52, 211, 153, 0.04),
    transparent 65%
  );
}
#view-wealth .section-title i {
  color: var(--green);
  background: rgba(52, 211, 153, 0.1);
  border-color: rgba(52, 211, 153, 0.15);
}
#view-market {
  background: radial-gradient(
    700px 400px at 30% -10%,
    rgba(79, 143, 255, 0.04),
    transparent 65%
  );
}
#view-business {
  background: radial-gradient(
    600px 400px at 80% -5%,
    rgba(167, 139, 250, 0.04),
    transparent 65%
  );
}
#view-business .section-title i {
  color: var(--purple);
  background: rgba(167, 139, 250, 0.1);
  border-color: rgba(167, 139, 250, 0.15);
}
#view-politics {
  background: radial-gradient(
    600px 400px at 60% -5%,
    rgba(79, 143, 255, 0.04),
    transparent 65%
  );
}
#view-lifestyle .section-title i {
  color: var(--amber);
  background: rgba(251, 191, 36, 0.1);
  border-color: rgba(251, 191, 36, 0.15);
}
#view-bank .section-title i {
  color: var(--cyan);
  background: rgba(34, 211, 238, 0.1);
  border-color: rgba(34, 211, 238, 0.15);
}
#view-hustles .section-title i {
  color: var(--amber);
  background: rgba(251, 191, 36, 0.1);
  border-color: rgba(251, 191, 36, 0.15);
}

::selection {
  background: rgba(79, 143, 255, 0.3);
  color: #fff;
}
input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--blue) !important;
  box-shadow: 0 0 0 3px rgba(79, 143, 255, 0.1) !important;
}

/* ═══════════════════════════════════════════════════════════
   CINEMATIC TITLE SCREEN — Complete Redesign
   ═══════════════════════════════════════════════════════════ */
.hidden {
  display: none !important;
}

.title-screen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: radial-gradient(
    ellipse 120% 80% at 50% 40%,
    #0c1833 0%,
    #050a18 60%,
    #020510 100%
  );
  font-family: var(--font-ui);
}
.title-screen.fade-out {
  animation: titleScreenFadeOut 1.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}
@keyframes titleScreenFadeOut {
  0% {
    opacity: 1;
    filter: blur(0) brightness(1);
    transform: scale(1);
  }
  50% {
    opacity: 0.8;
    filter: blur(4px) brightness(1.6);
    transform: scale(1.02);
  }
  100% {
    opacity: 0;
    filter: blur(30px) brightness(2);
    transform: scale(1.08);
  }
}
#title-particles {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}
.title-vignette {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: radial-gradient(
    ellipse 75% 65% at 50% 50%,
    transparent 40%,
    rgba(2, 5, 16, 0.85) 100%
  );
}
.title-scanlines {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 0, 0, 0.04) 2px,
    rgba(0, 0, 0, 0.04) 4px
  );
  opacity: 0.3;
}

/* Ambient glow orbs */
.title-orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  z-index: 1;
  filter: blur(80px);
}
.orb-1 {
  width: 500px;
  height: 500px;
  top: -10%;
  left: -8%;
  background: radial-gradient(
    circle,
    rgba(79, 143, 255, 0.12),
    transparent 70%
  );
  animation: orbFloat1 12s ease-in-out infinite;
}
.orb-2 {
  width: 400px;
  height: 400px;
  bottom: -5%;
  right: -5%;
  background: radial-gradient(
    circle,
    rgba(167, 139, 250, 0.1),
    transparent 70%
  );
  animation: orbFloat2 15s ease-in-out infinite;
}
.orb-3 {
  width: 350px;
  height: 350px;
  top: 40%;
  left: 50%;
  background: radial-gradient(
    circle,
    rgba(52, 211, 153, 0.06),
    transparent 70%
  );
  animation: orbFloat3 18s ease-in-out infinite;
}
@keyframes orbFloat1 {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }
  50% {
    transform: translate(40px, 30px) scale(1.15);
  }
}
@keyframes orbFloat2 {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }
  50% {
    transform: translate(-30px, -20px) scale(1.1);
  }
}
@keyframes orbFloat3 {
  0%,
  100% {
    transform: translate(0, 0) scale(0.9);
  }
  50% {
    transform: translate(20px, -40px) scale(1.05);
  }
}

.title-content {
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px 24px;
  max-width: 680px;
  width: 100%;
  animation: titleContentReveal 1.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
@keyframes titleContentReveal {
  0% {
    opacity: 0;
    transform: translateY(30px) scale(0.96);
    filter: blur(8px);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

/* Logo */
.title-logo-wrap {
  margin-bottom: 16px;
  perspective: 600px;
}
.title-logo-container {
  position: relative;
  width: 120px;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: logoFloat 6s ease-in-out infinite;
}
@keyframes logoFloat {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}
.title-logo-img {
  width: 80px;
  height: 80px;
  object-fit: contain;
  position: relative;
  z-index: 2;
  filter: drop-shadow(0 0 30px rgba(79, 143, 255, 0.4));
  animation: logoPulse 4s ease-in-out infinite;
}
@keyframes logoPulse {
  0%,
  100% {
    filter: drop-shadow(0 0 30px rgba(79, 143, 255, 0.4));
    transform: scale(1);
  }
  50% {
    filter: drop-shadow(0 0 50px rgba(79, 143, 255, 0.7))
      drop-shadow(0 0 80px rgba(167, 139, 250, 0.35));
    transform: scale(1.04);
  }
}
.title-logo-glow {
  position: absolute;
  inset: -25%;
  border-radius: 50%;
  z-index: 0;
  background: radial-gradient(
    circle,
    rgba(79, 143, 255, 0.2) 0%,
    rgba(167, 139, 250, 0.08) 50%,
    transparent 70%
  );
  animation: glowPulse 5s ease-in-out infinite;
}
@keyframes glowPulse {
  0%,
  100% {
    opacity: 0.6;
    transform: scale(1);
  }
  50% {
    opacity: 1;
    transform: scale(1.15);
  }
}
.title-logo-ring {
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  border: 1.5px solid rgba(79, 143, 255, 0.12);
  animation: ringRotate 20s linear infinite;
}
.title-logo-ring.ring-2 {
  inset: -18px;
  border-color: rgba(167, 139, 250, 0.08);
  animation-duration: 30s;
  animation-direction: reverse;
}
@keyframes ringRotate {
  to {
    transform: rotate(360deg);
  }
}

/* Title text */
.title-main {
  font-family: var(--font-ui);
  font-weight: 900;
  font-size: clamp(2.8rem, 8vw, 5rem);
  letter-spacing: -2px;
  line-height: 0.95;
  text-align: center;
  margin-bottom: 12px;
  display: flex;
  gap: 14px;
}
.title-word {
  display: inline-block;
  animation: wordReveal 0.8s cubic-bezier(0.16, 1, 0.3, 1) backwards;
}
.title-word-1 {
  background: linear-gradient(135deg, #e2e8f0, #f8fafc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation-delay: 0.3s;
  filter: drop-shadow(0 2px 20px rgba(255, 255, 255, 0.12));
}
.title-word-2 {
  background: linear-gradient(135deg, #60a5fa, #818cf8, #a78bfa);
  background-size: 200% 200%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation:
    wordReveal 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.5s backwards,
    titleGradient 4s ease-in-out infinite;
  filter: drop-shadow(0 2px 30px rgba(96, 165, 250, 0.3));
}
@keyframes wordReveal {
  from {
    opacity: 0;
    transform: translateY(20px);
    filter: blur(8px);
  }
}
@keyframes titleGradient {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

/* Tagline */
.title-tagline-wrap {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
  width: 100%;
  max-width: 400px;
  animation: fadeInUp 0.8s 0.7s backwards;
}
.title-tagline-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(148, 163, 184, 0.3),
    transparent
  );
}
.title-tagline {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: rgba(148, 163, 184, 0.7);
  letter-spacing: 4px;
  text-transform: uppercase;
  text-align: center;
  min-height: 1.2em;
  white-space: nowrap;
}
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
}

/* ── Animated Feature Showcase ── */
.title-showcase {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  width: 100%;
  max-width: 520px;
  margin-bottom: 24px;
  animation: fadeInUp 0.8s 1s backwards;
}
.showcase-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 14px 8px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(12px);
  cursor: default;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}
.showcase-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at 50% 0%,
    var(--sc-color, rgba(79, 143, 255, 0.12)),
    transparent 70%
  );
  opacity: 0;
  transition: opacity 0.35s;
}
.showcase-card:hover::before {
  opacity: 1;
}
.showcase-card:hover {
  border-color: var(--sc-border, rgba(79, 143, 255, 0.2));
  transform: translateY(-4px) scale(1.03);
  box-shadow: 0 12px 32px var(--sc-glow, rgba(79, 143, 255, 0.12));
}
.showcase-card i {
  font-size: 1.2rem;
  color: var(--sc-icon, rgba(148, 163, 184, 0.6));
  transition: all 0.35s;
}
.showcase-card:hover i {
  color: var(--sc-hover, #93c5fd);
  transform: scale(1.15);
}
.showcase-card span {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  color: rgba(148, 163, 184, 0.65);
  transition: color 0.3s;
}
.showcase-card:hover span {
  color: #e2e8f0;
}

/* Color variants for each showcase card */
.sc-wealth {
  --sc-color: rgba(251, 191, 36, 0.12);
  --sc-border: rgba(251, 191, 36, 0.25);
  --sc-glow: rgba(251, 191, 36, 0.1);
  --sc-icon: #fbbf24;
  --sc-hover: #fcd34d;
}
.sc-crime {
  --sc-color: rgba(239, 68, 68, 0.12);
  --sc-border: rgba(239, 68, 68, 0.25);
  --sc-glow: rgba(239, 68, 68, 0.1);
  --sc-icon: #ef4444;
  --sc-hover: #f87171;
}
.sc-casino {
  --sc-color: rgba(167, 139, 250, 0.12);
  --sc-border: rgba(167, 139, 250, 0.25);
  --sc-glow: rgba(167, 139, 250, 0.1);
  --sc-icon: #a78bfa;
  --sc-hover: #c4b5fd;
}
.sc-bank {
  --sc-color: rgba(96, 165, 250, 0.12);
  --sc-border: rgba(96, 165, 250, 0.25);
  --sc-glow: rgba(96, 165, 250, 0.1);
  --sc-icon: #60a5fa;
  --sc-hover: #93c5fd;
}
.sc-career {
  --sc-color: rgba(52, 211, 153, 0.12);
  --sc-border: rgba(52, 211, 153, 0.25);
  --sc-glow: rgba(52, 211, 153, 0.1);
  --sc-icon: #34d399;
  --sc-hover: #6ee7b7;
}
.sc-market {
  --sc-color: rgba(34, 211, 238, 0.12);
  --sc-border: rgba(34, 211, 238, 0.25);
  --sc-glow: rgba(34, 211, 238, 0.1);
  --sc-icon: #22d3ee;
  --sc-hover: #67e8f9;
}
.sc-politics {
  --sc-color: rgba(244, 114, 182, 0.12);
  --sc-border: rgba(244, 114, 182, 0.25);
  --sc-glow: rgba(244, 114, 182, 0.1);
  --sc-icon: #f472b6;
  --sc-hover: #f9a8d4;
}
.sc-social {
  --sc-color: rgba(251, 113, 133, 0.12);
  --sc-border: rgba(251, 113, 133, 0.25);
  --sc-glow: rgba(251, 113, 133, 0.1);
  --sc-icon: #fb7185;
  --sc-hover: #fda4af;
}

/* Staggered entrance */
.showcase-card:nth-child(1) {
  animation: scCardIn 0.5s 1.1s backwards;
}
.showcase-card:nth-child(2) {
  animation: scCardIn 0.5s 1.2s backwards;
}
.showcase-card:nth-child(3) {
  animation: scCardIn 0.5s 1.3s backwards;
}
.showcase-card:nth-child(4) {
  animation: scCardIn 0.5s 1.4s backwards;
}
.showcase-card:nth-child(5) {
  animation: scCardIn 0.5s 1.5s backwards;
}
.showcase-card:nth-child(6) {
  animation: scCardIn 0.5s 1.6s backwards;
}
.showcase-card:nth-child(7) {
  animation: scCardIn 0.5s 1.7s backwards;
}
.showcase-card:nth-child(8) {
  animation: scCardIn 0.5s 1.8s backwards;
}
@keyframes scCardIn {
  0% {
    opacity: 0;
    transform: translateY(14px) scale(0.92);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Hook line (replaces old title-desc) */
.title-hook {
  color: rgba(148, 163, 184, 0.5);
  font-size: 0.9rem;
  line-height: 1.6;
  text-align: center;
  max-width: 460px;
  margin-bottom: 24px;
  animation: fadeInUp 0.8s 2s backwards;
}

/* Menu buttons */
.title-menu {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 100%;
  max-width: 320px;
  animation: fadeInUp 0.8s 2.2s backwards;
}
.btn-title-start {
  position: relative;
  overflow: hidden;
  width: 100%;
  padding: 16px 28px;
  border: none;
  border-radius: 14px;
  font-family: var(--font-ui);
  font-weight: 800;
  font-size: 1.1rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(135deg, #3b82f6, #6366f1, #8b5cf6);
  background-size: 200% 200%;
  box-shadow:
    0 8px 32px rgba(99, 102, 241, 0.35),
    0 2px 8px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  animation: btnShimmer 4s ease-in-out infinite;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  z-index: 1;
}
.btn-title-start .btn-title-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.12),
    transparent 50%
  );
  opacity: 0;
  transition: opacity 0.3s;
}
.btn-title-start:hover {
  transform: translateY(-3px) scale(1.01);
  box-shadow:
    0 12px 40px rgba(99, 102, 241, 0.5),
    0 4px 12px rgba(0, 0, 0, 0.3);
}
.btn-title-start:hover .btn-title-bg {
  opacity: 1;
}
.btn-title-start:active {
  transform: translateY(1px) scale(0.99);
}
@keyframes btnShimmer {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}
.btn-title-continue {
  width: 100%;
  padding: 13px 24px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(12px);
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.5px;
  color: rgba(148, 163, 184, 0.8);
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.btn-title-continue:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(148, 163, 184, 0.35);
  color: #e2e8f0;
}

/* Footer */
.title-footer-info {
  display: flex;
  gap: 20px;
  margin-top: 24px;
  animation: fadeInUp 0.8s 2.4s backwards;
}
.title-ver {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: rgba(100, 116, 139, 0.5);
  letter-spacing: 0.5px;
}
.title-ver i {
  font-size: 0.6rem;
}

/* Pseudo elements */
.title-screen::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  z-index: 0;
  background: conic-gradient(
    from 0deg at 50% 50%,
    transparent 0deg,
    rgba(79, 143, 255, 0.03) 60deg,
    transparent 120deg,
    rgba(167, 139, 250, 0.03) 180deg,
    transparent 240deg,
    rgba(251, 191, 36, 0.02) 300deg,
    transparent 360deg
  );
  animation: cosmicRotate 60s linear infinite;
}
@keyframes cosmicRotate {
  to {
    transform: rotate(360deg);
  }
}
.title-screen::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: radial-gradient(
    circle 400px at 50% 45%,
    rgba(79, 143, 255, 0.06),
    transparent 60%
  );
  pointer-events: none;
}

/* Title responsive */
@media (min-width: 1024px) {
  .title-logo-container {
    width: 150px;
    height: 150px;
  }
  .title-logo-img {
    width: 255px;
    height: 255px;
  }
  .title-main {
    font-size: 5rem;
    gap: 18px;
  }
  .title-showcase {
    gap: 12px;
    max-width: 560px;
  }
  .showcase-card {
    padding: 16px 10px;
  }
  .showcase-card i {
    font-size: 1.35rem;
  }
}
@media (max-width: 1024px) {
  .title-main {
    font-size: 2.6rem;
    letter-spacing: -1.5px;
    gap: 10px;
  }
  .title-logo-container {
    width: 90px;
    height: 90px;
  }
  .title-logo-img {
    width: 170px;
    height: 170px;
  }
  .title-showcase {
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
  }
  .showcase-card {
    padding: 10px 4px;
    gap: 4px;
  }
  .showcase-card i {
    font-size: 0.95rem;
  }
  .showcase-card span {
    font-size: 0.6rem;
  }
  .btn-title-start {
    padding: 14px 20px;
    font-size: 1rem;
  }
  .title-tagline {
    letter-spacing: 3px;
    font-size: 0.68rem;
  }
  .title-footer-info {
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
  }
}
@media (max-width: 380px) {
  .title-showcase {
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
  }
  .title-main {
    font-size: 2.2rem;
  }
}

/* ═══════════════════════════════════════════════════════════
   MOBILE NAV — Hamburger + Slide-out Sidebar
   ═══════════════════════════════════════════════════════════ */
.mobile-nav-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  opacity: 0;
  transition: opacity 0.3s;
}
.mobile-nav-overlay.active {
  display: block;
  opacity: 1;
}
.nav-close-btn {
  display: none; /* shown only inside mobile sidebar */
  padding: 12px 16px;
  color: var(--text-muted);
  font-size: 1.2rem;
  cursor: pointer;
  text-align: right;
}
.nav-close-btn:hover {
  color: #fff;
}

/* ═══════════════════════════════════════════════════════════
   MOBILE TOP BAR + STATS PANEL — Base (hidden on desktop)
   ═══════════════════════════════════════════════════════════ */
.mobile-top-bar {
  display: none;
  grid-column: 1;
}
.mobile-stats-panel {
  display: none;
  grid-column: 1;
}
.mobile-nav-overlay {
  grid-column: 1;
}

/* ═══════════════════════════════════════════════════════════
   REDESIGNED CONTROL BAR — Professional Layout
   ═══════════════════════════════════════════════════════════ */
.control-bar {
  grid-column: 1;
  grid-row: 2;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  background: linear-gradient(
    180deg,
    rgba(13, 18, 37, 0.9),
    rgba(8, 12, 22, 0.97)
  );
  backdrop-filter: blur(24px) saturate(1.4);
  -webkit-backdrop-filter: blur(24px) saturate(1.4);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  z-index: 50;
}
.control-left {
  flex: 1;
  min-width: 0;
}
.control-center {
  flex-shrink: 0;
}
.control-right {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}
.log-feed {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  background: rgba(21, 28, 53, 0.4);
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.04);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 0.7rem;
  max-width: 220px;
  overflow: hidden;
  flex-shrink: 1;
}
.terminal-icon {
  color: var(--green);
  font-size: 0.65rem;
  flex-shrink: 0;
}
.log-latest {
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.speed-controls {
  display: flex;
  gap: 3px;
}
.speed-btn {
  min-height: 32px;
  padding: 0 12px;
  font-size: 0.72rem;
  font-family: var(--font-mono);
  font-weight: 700;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(21, 28, 53, 0.4);
  color: var(--text-dim);
  cursor: pointer;
  transition: all 0.2s ease;
}
.speed-btn:hover {
  background: rgba(21, 28, 53, 0.7);
  color: var(--text-main);
  border-color: rgba(255, 255, 255, 0.12);
}
.speed-btn.active {
  border-color: rgba(79, 143, 255, 0.35);
  background: rgba(79, 143, 255, 0.12);
  color: var(--accent-blue);
  box-shadow: 0 0 8px rgba(79, 143, 255, 0.1);
}

.next-month-btn {
  border: none;
  border-radius: 10px;
  padding: 10px 20px;
  font-family: var(--font-ui);
  font-weight: 800;
  font-size: 0.88rem;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(135deg, #3b82f6, #6366f1);
  background-size: 200% 200%;
  box-shadow:
    0 4px 16px rgba(79, 143, 255, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  animation: btnShimmer 6s ease-in-out infinite;
  white-space: nowrap;
  flex-shrink: 0;
}
.next-month-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(79, 143, 255, 0.4);
}
.next-month-btn:active:not(:disabled) {
  transform: translateY(1px);
}
.next-month-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  filter: grayscale(0.5);
}

/* ═══════════════════════════════════════════════════════════
   REDESIGNED DEATH / ENDING SCENE
   ═══════════════════════════════════════════════════════════ */
.ending-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
  animation: endingReveal 1s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes endingReveal {
  0% {
    opacity: 0;
    transform: translateY(30px) scale(0.97);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}
.ending-hero {
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: 20px;
  padding: 40px 32px;
  text-align: center;
  position: relative;
  overflow: hidden;
  background: linear-gradient(
    180deg,
    rgba(13, 18, 37, 0.95),
    rgba(8, 12, 22, 0.97)
  );
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.ending-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle 300px at 50% 20%,
    rgba(79, 143, 255, 0.08),
    transparent 70%
  );
  pointer-events: none;
}
.ending-kicker {
  display: inline-flex;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  border: 1px solid rgba(79, 143, 255, 0.3);
  color: #93c5fd;
  background: rgba(79, 143, 255, 0.08);
  border-radius: 999px;
  padding: 5px 16px;
  margin-bottom: 16px;
  animation: kickerPulse 3s ease-in-out infinite;
}
@keyframes kickerPulse {
  0%,
  100% {
    box-shadow: 0 0 0 rgba(79, 143, 255, 0);
  }
  50% {
    box-shadow: 0 0 20px rgba(79, 143, 255, 0.15);
  }
}
.ending-hero h2 {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 900;
  line-height: 1.1;
  margin-bottom: 12px;
  background: linear-gradient(135deg, #f8fafc, #94a3b8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.ending-hero p {
  color: var(--text-muted);
  max-width: 50ch;
  margin: 0 auto 20px;
  line-height: 1.6;
}
.ending-networth {
  font-family: var(--font-mono);
  font-size: clamp(2.2rem, 4vw, 3.5rem);
  font-weight: 900;
  letter-spacing: 0.5px;
  color: #f8fafc;
  text-shadow: 0 0 40px rgba(79, 143, 255, 0.3);
  animation: networthPulse 2s ease-in-out infinite alternate;
}
@keyframes networthPulse {
  0% {
    text-shadow: 0 0 30px rgba(79, 143, 255, 0.2);
  }
  100% {
    text-shadow:
      0 0 60px rgba(79, 143, 255, 0.5),
      0 0 100px rgba(79, 143, 255, 0.15);
  }
}
.ending-networth-label {
  margin-top: 4px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 0.7rem;
}
.ending-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
}
.ending-stat {
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(21, 28, 53, 0.4);
  border-radius: 12px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  transition: all 0.3s ease;
  backdrop-filter: blur(8px);
}
.ending-stat:hover {
  border-color: rgba(79, 143, 255, 0.15);
  background: rgba(21, 28, 53, 0.6);
  transform: translateY(-2px);
}
.ending-stat span {
  color: var(--text-muted);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 1.2px;
}
.ending-stat strong {
  font-family: var(--font-mono);
  font-size: 1.05rem;
  color: #f8fafc;
}
.ending-foot {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: stretch;
}
.ending-telemetry {
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  background: rgba(21, 28, 53, 0.35);
  padding: 14px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.ending-telemetry div {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.ending-telemetry span {
  color: var(--text-muted);
  font-size: 0.68rem;
  letter-spacing: 0.8px;
  text-transform: uppercase;
}
.ending-telemetry strong {
  font-family: var(--font-mono);
  color: #e2e8f0;
}
.ending-actions {
  width: 260px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Death variant */
.ending-panel.ending-death .ending-hero {
  border-color: rgba(248, 113, 113, 0.25);
  background: linear-gradient(
    180deg,
    rgba(34, 11, 16, 0.96),
    rgba(15, 7, 11, 0.98)
  );
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.65),
    inset 0 0 120px rgba(239, 68, 68, 0.05);
}
.ending-panel.ending-death .ending-hero::before {
  background: radial-gradient(
    circle 350px at 50% 15%,
    rgba(248, 113, 113, 0.12),
    transparent 70%
  );
}
.ending-panel.ending-death .ending-kicker {
  color: #fecaca;
  border-color: rgba(248, 113, 113, 0.35);
  background: rgba(239, 68, 68, 0.1);
  animation: deathKickerPulse 2s ease-in-out infinite;
}
@keyframes deathKickerPulse {
  0%,
  100% {
    box-shadow: 0 0 0 rgba(239, 68, 68, 0);
  }
  50% {
    box-shadow: 0 0 25px rgba(239, 68, 68, 0.2);
  }
}
.ending-panel.ending-death .ending-hero h2 {
  background: linear-gradient(135deg, #fecaca, #ef4444, #fca5a5);
  -webkit-background-clip: text;
  background-clip: text;
}
.ending-panel.ending-death .ending-networth {
  color: #fee2e2;
  text-shadow: 0 0 30px rgba(239, 68, 68, 0.4);
}
.ending-panel.ending-death .ending-stats-grid .ending-stat {
  border-color: rgba(239, 68, 68, 0.1);
}

/* Retired variant */
.ending-panel.ending-retired .ending-hero {
  border-color: rgba(52, 211, 153, 0.2);
  background: linear-gradient(
    180deg,
    rgba(8, 28, 22, 0.96),
    rgba(5, 15, 10, 0.98)
  );
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.55),
    inset 0 0 120px rgba(52, 211, 153, 0.04);
}
.ending-panel.ending-retired .ending-hero::before {
  background: radial-gradient(
    circle 350px at 50% 15%,
    rgba(52, 211, 153, 0.1),
    transparent 70%
  );
}
.ending-panel.ending-retired .ending-kicker {
  color: #a7f3d0;
  border-color: rgba(52, 211, 153, 0.35);
  background: rgba(52, 211, 153, 0.1);
}
.ending-panel.ending-retired .ending-hero h2 {
  background: linear-gradient(135deg, #a7f3d0, #34d399, #6ee7b7);
  -webkit-background-clip: text;
  background-clip: text;
}
.ending-panel.ending-retired .ending-networth {
  color: #d1fae5;
  text-shadow: 0 0 30px rgba(52, 211, 153, 0.4);
}

/* ═══════════════════════════════════════════════════════════
   POLITICS — Mini stat boxes
   ═══════════════════════════════════════════════════════════ */
.mini-stat-box {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 10px 12px;
  background: rgba(21, 28, 53, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 10px;
  text-align: center;
}
.mini-stat-box span {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
}
.mini-stat-box strong {
  font-family: var(--font-mono);
  font-size: 1rem;
  color: #f8fafc;
}
#view-politics .section-title i {
  color: var(--accent-purple);
}

/* ═══════════════════════════════════════════════════════════
   RELATIONSHIP ACTIONS
   ═══════════════════════════════════════════════════════════ */
.relationship-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}
.rel-actions-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.rel-actions-row .btn {
  font-size: 0.78rem;
  padding: 6px 12px;
}

/* ═══════════════════════════════════════════════════════════
   SIMPLIFIED BANK SECTION
   ═══════════════════════════════════════════════════════════ */
#view-bank .section-title i {
  color: var(--accent-blue);
}
.bank-offer-card {
  position: relative;
  overflow: hidden;
}
.bank-offer-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 0.78rem;
  color: var(--text-muted);
}
.bank-offer-meta .tag {
  font-size: 0.68rem;
}

/* ═══════════════════════════════════════════════════════════
   COMPREHENSIVE MOBILE RESPONSIVENESS
   ═══════════════════════════════════════════════════════════ */

/* Tablet */
@media (max-width: 980px) {
  /* ── Gallery Scroll: horizontal swipe cards on mobile/tablet ── */
  .grid-cards {
    display: flex !important;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    gap: 12px;
    padding-bottom: 6px;
    scrollbar-width: none;
  }
  .grid-cards::-webkit-scrollbar {
    display: none;
  }
  .grid-cards > .card,
  .grid-cards > div {
    flex: 0 0 78%;
    max-width: 78%;
    min-width: 0;
    scroll-snap-align: start;
    grid-column: unset !important;
  }
  /* Single-card grids stay block — no scroll needed */
  #bank-credit.grid-cards,
  #bond-list.grid-cards {
    display: block !important;
    overflow: visible;
  }

  /* Gallery scroll dot indicators */
  .gallery-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    padding: 8px 0 2px;
  }
  .gallery-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    transition: all 0.25s ease;
  }
  .gallery-dot.active {
    background: var(--accent, #3b82f6);
    width: 18px;
    border-radius: 3px;
    box-shadow: 0 0 8px rgba(59, 130, 246, 0.4);
  }

  .app-shell {
    padding: 0;
  }
  .app-container {
    height: 100vh;
    height: 100dvh;
    border-radius: 0;
    grid-template-columns: 1fr;
    padding: 0;
    gap: 0;
  }
  .sidebar {
    display: none;
  }
  .main-area {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto 1fr auto;
    border-radius: 0;
    height: 100vh;
    height: 100dvh;
  }
  /* mobile-nav-toggle and mobile-stats-strip are now handled by the mobile top bar section */
  .nav-tabs {
    grid-column: 1;
    grid-row: auto;
    position: fixed;
    top: 0;
    left: -280px;
    bottom: 0;
    width: 260px;
    z-index: 100;
    flex-direction: column;
    flex-wrap: nowrap;
    padding: 0;
    gap: 0;
    background: linear-gradient(
      180deg,
      rgba(8, 12, 24, 0.98),
      rgba(5, 8, 18, 0.99)
    );
    backdrop-filter: blur(20px);
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    border-bottom: none;
    overflow-y: auto;
    overflow-x: hidden;
    transition: left 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: none;
  }
  .nav-tabs.nav-open {
    left: 0;
    box-shadow: 8px 0 40px rgba(0, 0, 0, 0.5);
  }
  .nav-close-btn {
    display: block;
  }
  .nav-item {
    white-space: nowrap;
    padding: 14px 20px;
    font-size: 0.88rem;
    border-radius: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    justify-content: flex-start;
    gap: 12px;
  }
  .nav-item i {
    width: 20px;
    text-align: center;
    font-size: 0.95rem;
  }
  .nav-item.active {
    background: rgba(79, 143, 255, 0.1);
    border-left: 3px solid rgba(79, 143, 255, 0.6);
  }
  .nav-save-item {
    display: flex;
    margin-top: auto;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    border-bottom: none;
    color: var(--accent-blue);
    font-weight: 700;
  }
  .nav-save-item i {
    color: var(--accent-blue);
  }
  .view-container {
    padding: 14px;
  }
  .section-title {
    font-size: 1.1rem;
  }
  .section-subtitle {
    font-size: 0.85rem;
  }
  .crime-dashboard {
    grid-template-columns: 1fr;
  }
  .incubator-head {
    flex-direction: column;
    align-items: flex-start;
  }
  .casino-kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .casino-meta-grid {
    grid-template-columns: 1fr;
  }
  .ending-foot {
    grid-template-columns: 1fr;
  }
  .ending-actions {
    width: 100%;
  }
  .ending-telemetry {
    grid-template-columns: 1fr;
  }
  .control-bar {
    grid-column: 1;
    grid-row: 4;
    flex-wrap: wrap;
    padding: 6px 10px;
    gap: 6px;
    position: sticky;
    bottom: 0;
  }
  .control-left {
    display: none;
  }
  .control-center {
    order: 1;
    flex: 1;
  }
  .control-right {
    order: 2;
    width: auto;
  }
}

/* Phone */
@media (max-width: 640px) {
  .grid-cards {
    gap: 8px;
  }
  .grid-cards > .card,
  .grid-cards > div {
    flex: 0 0 85%;
    max-width: 85%;
  }
  .nav-tabs {
    width: 240px;
    left: -250px;
  }
  .control-bar {
    flex-wrap: wrap;
    padding: 6px 8px;
    gap: 5px;
  }
  .control-center {
    order: 1;
    width: 100%;
  }
  .speed-controls {
    justify-content: center;
    width: 100%;
  }
  .control-right {
    order: 2;
    width: 100%;
  }
  .next-month-btn {
    flex: 1;
    padding: 12px;
    font-size: 0.88rem;
    border-radius: 10px;
  }
  .card {
    padding: 14px;
  }
  .card-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }
  .card-header h3 {
    font-size: 0.95rem;
  }
  .btn {
    padding: 8px 14px;
    font-size: 0.78rem;
  }
  .section-title {
    font-size: 1rem;
    margin-bottom: 12px;
  }
  .ending-hero {
    padding: 28px 18px;
  }
  .ending-stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .ending-hero h2 {
    font-size: 1.6rem;
  }
  .ending-networth {
    font-size: 2rem;
  }
  .casino-kpi-grid {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  .casino-kpi-card {
    padding: 10px;
  }
  .casino-kpi-value {
    font-size: 1rem;
  }
  .casino-hero-head {
    flex-direction: column;
    gap: 8px;
  }
  .bet-input-group {
    flex-direction: column;
  }
  .bet-input-group input,
  .bet-input-group button {
    width: 100%;
  }
  .mini-stat-box {
    padding: 8px;
  }
  .mini-stat-box strong {
    font-size: 0.88rem;
  }
  .rel-actions-row {
    flex-direction: column;
  }
  .rel-actions-row .btn {
    width: 100%;
    justify-content: center;
  }
  .modal-content {
    margin: 10px;
    padding: 18px;
    border-radius: 14px;
    max-height: 85vh;
    overflow-y: auto;
  }
  .modal-desc {
    font-size: 0.85rem;
  }
  .modal-header h2 {
    font-size: 1.2rem;
  }
}

/* Small phone */
@media (max-width: 380px) {
  .nav-item {
    padding: 12px 16px;
    font-size: 0.82rem;
  }
  .view-container {
    padding: 10px;
    padding-top: 52px;
  }
  .grid-cards {
    gap: 6px;
  }
  .card {
    padding: 12px;
    border-radius: 10px;
  }
  .section-title {
    font-size: 0.9rem;
  }
  .control-bar {
    padding: 5px 6px;
  }
  .speed-btn {
    padding: 0 8px;
    min-height: 28px;
    font-size: 0.68rem;
  }
  .next-month-btn {
    padding: 10px;
    font-size: 0.82rem;
  }
  .ending-hero {
    padding: 20px 14px;
    border-radius: 14px;
  }
  .ending-stats-grid {
    grid-template-columns: 1fr;
  }
}

/* Landscape phone */
@media (max-height: 500px) and (orientation: landscape) {
  .control-bar {
    padding: 4px 10px;
  }
  .next-month-btn {
    padding: 8px 16px;
    font-size: 0.8rem;
  }
  .view-container {
    padding: 10px;
    padding-top: 50px;
  }
  .section-title {
    margin-bottom: 8px;
  }
}

/* Touch devices */
@media (hover: none) and (pointer: coarse) {
  .btn {
    min-height: 42px;
  }
  .speed-btn {
    min-height: 36px;
  }
  .nav-item {
    min-height: 44px;
  }
  .next-month-btn {
    min-height: 48px;
  }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ═══════════════════════════════════════════════════════════
   MOBILE TOP BAR + STATS PANEL — Layout
   ═══════════════════════════════════════════════════════════ */
@media (max-width: 980px) {
  /* ── Top Bar ── */
  .mobile-top-bar {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
    height: 50px;
    padding: 0 8px;
    background: linear-gradient(
      180deg,
      rgba(8, 12, 24, 0.97),
      rgba(10, 14, 28, 0.94)
    );
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    z-index: 80;
    position: relative;
  }
  .mtb-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(21, 28, 53, 0.5);
    color: #cbd5e1;
    font-size: 1.05rem;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
  }
  .mtb-btn:hover,
  .mtb-btn:active {
    background: rgba(79, 143, 255, 0.12);
    border-color: rgba(79, 143, 255, 0.25);
    color: #fff;
  }
  .mtb-btn.mtb-active {
    background: rgba(79, 143, 255, 0.15);
    border-color: rgba(79, 143, 255, 0.35);
    color: var(--accent-blue);
  }
  .mtb-info {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-mono);
    font-weight: 700;
  }
  .mtb-age {
    color: var(--text-main);
    background: rgba(79, 143, 255, 0.08);
    border: 1px solid rgba(79, 143, 255, 0.2);
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 0.72rem;
    letter-spacing: 0.5px;
  }
  .mtb-dot {
    color: var(--text-dim);
    font-size: 0.6rem;
  }
  .mtb-nw {
    color: var(--green);
    font-size: 0.82rem;
  }
  .mtb-nw.mtb-neg {
    color: var(--red);
  }

  /* ── Stats Panel (collapsible) ── */
  .mobile-stats-panel {
    display: block !important;
    max-height: 0;
    overflow: hidden;
    flex-shrink: 0;
    background: linear-gradient(
      180deg,
      rgba(10, 14, 28, 0.96),
      rgba(8, 12, 24, 0.98)
    );
    border-bottom: 1px solid transparent;
    transition:
      max-height 0.35s cubic-bezier(0.16, 1, 0.3, 1),
      border-color 0.35s ease;
  }
  .mobile-stats-panel.msp-open {
    max-height: 260px;
    border-bottom-color: rgba(255, 255, 255, 0.08);
  }
  .msp-inner {
    padding: 12px 14px 10px;
  }
  .msp-bars {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 16px;
    margin-bottom: 10px;
  }
  .msp-bar-group {
    display: flex;
    flex-direction: column;
    gap: 3px;
  }
  .msp-bar-head {
    display: flex;
    justify-content: space-between;
    font-family: var(--font-mono);
    font-size: 0.65rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
  }
  .msp-bar-head span:last-child {
    color: var(--text-main);
  }
  .msp-track {
    height: 6px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 99px;
    overflow: hidden;
  }
  .msp-fill {
    height: 100%;
    border-radius: 99px;
    transition: width 0.4s ease;
  }
  .msp-fill.msp-hp {
    background: linear-gradient(90deg, #ef4444, #f87171);
  }
  .msp-fill.msp-nrg {
    background: linear-gradient(90deg, #f59e0b, #fbbf24);
  }
  .msp-fill.msp-joy {
    background: linear-gradient(90deg, #3b82f6, #60a5fa);
  }
  .msp-fill.msp-iq {
    background: linear-gradient(90deg, #a855f7, #c084fc);
  }

  .msp-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 10px;
  }
  .msp-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    background: rgba(21, 28, 53, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 8px;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--text-muted);
  }
  .msp-chip b {
    color: var(--text-main);
    font-weight: 700;
  }
  .msp-chip i {
    font-size: 0.6rem;
  }
  .msp-chip.msp-warn i {
    color: var(--red);
  }
  .msp-chip.msp-warn b {
    color: var(--red);
  }

  .msp-foot {
    display: flex;
    justify-content: flex-end;
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    padding-top: 8px;
  }
  .msp-save {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 16px;
    border-radius: 8px;
    border: 1px solid rgba(79, 143, 255, 0.25);
    background: rgba(79, 143, 255, 0.08);
    color: var(--accent-blue);
    font-family: var(--font-ui);
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
  }
  .msp-save:hover {
    background: rgba(79, 143, 255, 0.15);
    border-color: rgba(79, 143, 255, 0.4);
  }
  .msp-save:active {
    transform: scale(0.96);
  }
}

/* phone adjustments for top bar */
@media (max-width: 640px) {
  .mobile-top-bar {
    height: 46px;
    padding: 0 6px;
  }
  .mtb-btn {
    width: 36px;
    height: 36px;
    font-size: 0.95rem;
    border-radius: 8px;
  }
  .mtb-info {
    gap: 6px;
  }
  .mtb-age {
    font-size: 0.66rem;
    padding: 2px 8px;
  }
  .mtb-nw {
    font-size: 0.75rem;
  }
  .msp-bars {
    gap: 6px 12px;
  }
  .msp-chip {
    padding: 3px 8px;
    font-size: 0.64rem;
  }
  .msp-save {
    font-size: 0.7rem;
    padding: 5px 12px;
  }
}

/* small phone */
@media (max-width: 380px) {
  .mobile-top-bar {
    height: 42px;
    padding: 0 4px;
  }
  .mtb-btn {
    width: 34px;
    height: 34px;
    font-size: 0.88rem;
  }
  .mtb-age {
    font-size: 0.6rem;
    padding: 2px 6px;
  }
  .mtb-nw {
    font-size: 0.68rem;
  }
  .msp-inner {
    padding: 10px 10px 8px;
  }
  .msp-bars {
    gap: 5px 8px;
  }
  .msp-bar-head {
    font-size: 0.58rem;
  }
  .msp-track {
    height: 5px;
  }
  .msp-chip {
    font-size: 0.58rem;
    padding: 2px 6px;
  }
  .msp-save {
    font-size: 0.65rem;
  }
}

/* =======================================================
   JUICE FX -- Screen Shake, Flash, Confetti, Toast, etc.
   ======================================================= */

/* == SCREEN SHAKE == */
@keyframes shake-sm {
  0%,
  100% {
    transform: translate(0);
  }
  10% {
    transform: translate(-2px, 1px);
  }
  30% {
    transform: translate(3px, -1px);
  }
  50% {
    transform: translate(-1px, 2px);
  }
  70% {
    transform: translate(2px, -2px);
  }
  90% {
    transform: translate(-3px, 1px);
  }
}
@keyframes shake-lg {
  0%,
  100% {
    transform: translate(0);
  }
  10% {
    transform: translate(-6px, 3px) rotate(-0.5deg);
  }
  20% {
    transform: translate(5px, -4px) rotate(0.3deg);
  }
  30% {
    transform: translate(-4px, 5px) rotate(-0.4deg);
  }
  40% {
    transform: translate(6px, -2px) rotate(0.5deg);
  }
  50% {
    transform: translate(-3px, 4px) rotate(-0.2deg);
  }
  60% {
    transform: translate(4px, -5px) rotate(0.3deg);
  }
  70% {
    transform: translate(-5px, 2px) rotate(-0.5deg);
  }
  80% {
    transform: translate(3px, -3px) rotate(0.4deg);
  }
  90% {
    transform: translate(-2px, 4px) rotate(-0.3deg);
  }
}
.fx-shake-sm {
  animation: shake-sm 0.4s ease-in-out;
}
.fx-shake-lg {
  animation: shake-lg 0.6s ease-in-out;
}

/* == SCREEN FLASH == */
.fx-flash-overlay {
  position: fixed;
  inset: 0;
  z-index: 9998;
  pointer-events: none;
  opacity: 0;
  animation: flashPop 0.5s ease-out forwards;
}
@keyframes flashPop {
  0% {
    opacity: 0.7;
  }
  100% {
    opacity: 0;
  }
}
.fx-flash-gain {
  background: radial-gradient(
    ellipse at center,
    rgba(52, 211, 153, 0.4),
    transparent 70%
  );
}
.fx-flash-loss {
  background: radial-gradient(
    ellipse at center,
    rgba(248, 113, 113, 0.35),
    transparent 70%
  );
}
.fx-flash-epic {
  background: radial-gradient(
    ellipse at center,
    rgba(251, 191, 36, 0.5),
    rgba(167, 139, 250, 0.2) 50%,
    transparent 80%
  );
}
.fx-flash-jail {
  background: radial-gradient(
    ellipse at center,
    rgba(239, 68, 68, 0.5),
    rgba(0, 0, 0, 0.3) 60%,
    transparent 85%
  );
}

/* == ENHANCED FLOATING TEXT == */
.floating-text {
  position: fixed;
  z-index: 9999;
  pointer-events: none;
  font-family: var(--font-mono);
  font-weight: 800;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
  white-space: nowrap;
}
.floating-text.text-gain {
  color: var(--green);
}
.floating-text.text-loss {
  color: var(--red);
}
.float-sm {
  font-size: 0.9rem;
  animation: floatUp 1s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}
.float-md {
  font-size: 1.3rem;
  animation: floatUpMd 1.3s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}
.float-lg {
  font-size: 1.8rem;
  text-shadow:
    0 0 20px currentColor,
    0 4px 12px rgba(0, 0, 0, 0.6);
  animation: floatUpLg 1.6s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}
.float-xl {
  font-size: 2.6rem;
  text-shadow:
    0 0 30px currentColor,
    0 0 60px currentColor;
  animation: floatUpXl 2s cubic-bezier(0.19, 1, 0.22, 1) forwards;
  letter-spacing: 1px;
}
@keyframes floatUp {
  0% {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
  100% {
    transform: translateY(-50px) scale(0.8);
    opacity: 0;
  }
}
@keyframes floatUpMd {
  0% {
    transform: translateY(0) scale(0.5);
    opacity: 0;
  }
  15% {
    transform: translateY(-10px) scale(1.15);
    opacity: 1;
  }
  100% {
    transform: translateY(-70px) scale(0.85);
    opacity: 0;
  }
}
@keyframes floatUpLg {
  0% {
    transform: translateY(0) scale(0.3);
    opacity: 0;
  }
  12% {
    transform: translateY(-8px) scale(1.25);
    opacity: 1;
  }
  100% {
    transform: translateY(-90px) scale(0.9);
    opacity: 0;
  }
}
@keyframes floatUpXl {
  0% {
    transform: translateY(0) scale(0.2) rotate(-5deg);
    opacity: 0;
  }
  10% {
    transform: translateY(-5px) scale(1.4) rotate(2deg);
    opacity: 1;
  }
  20% {
    transform: translateY(-15px) scale(1.1) rotate(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(-120px) scale(0.7);
    opacity: 0;
  }
}

/* == TOAST NOTIFICATIONS == */
.toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
  max-width: 360px;
}
.toast-notification {
  padding: 12px 18px;
  border-radius: 12px;
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 0.85rem;
  backdrop-filter: blur(20px) saturate(1.3);
  border: 1px solid;
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow:
    0 8px 30px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  animation: toastIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  pointer-events: auto;
  cursor: default;
  line-height: 1.4;
}
.toast-notification.toast-out {
  animation: toastOut 0.3s ease-in forwards;
}
.toast-notification i {
  font-size: 1rem;
  flex-shrink: 0;
}
.toast-success {
  background: rgba(16, 185, 129, 0.15);
  border-color: rgba(52, 211, 153, 0.3);
  color: #6ee7b7;
}
.toast-success i {
  color: var(--green);
}
.toast-error {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(248, 113, 113, 0.3);
  color: #fca5a5;
}
.toast-error i {
  color: var(--red);
}
.toast-info {
  background: rgba(79, 143, 255, 0.12);
  border-color: rgba(96, 165, 250, 0.3);
  color: #93c5fd;
}
.toast-info i {
  color: var(--blue);
}
.toast-warning {
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(251, 191, 36, 0.3);
  color: #fde68a;
}
.toast-warning i {
  color: var(--amber);
}
.toast-epic {
  background: linear-gradient(
    135deg,
    rgba(251, 191, 36, 0.18),
    rgba(167, 139, 250, 0.15)
  );
  border-color: rgba(251, 191, 36, 0.4);
  color: #fef3c7;
  box-shadow:
    0 8px 30px rgba(251, 191, 36, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}
.toast-epic i {
  color: var(--amber);
}
@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateX(80px) scale(0.8);
  }
  to {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
}
@keyframes toastOut {
  from {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
  to {
    opacity: 0;
    transform: translateX(80px) scale(0.8);
  }
}

/* == CONFETTI CANVAS == */
.confetti-canvas {
  position: fixed;
  inset: 0;
  z-index: 9997;
  pointer-events: none;
  width: 100%;
  height: 100%;
}

/* == MILESTONE OVERLAY == */
.milestone-overlay {
  position: fixed;
  inset: 0;
  z-index: 9996;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  animation: milestoneIn 2.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.milestone-badge {
  font-family: var(--font-ui);
  font-weight: 900;
  font-size: clamp(2rem, 5vw, 4rem);
  text-align: center;
  background: linear-gradient(135deg, #fbbf24, #f59e0b, #fde68a, #fbbf24);
  background-size: 300% 300%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: milestoneGradient 2s ease-in-out infinite;
  filter: drop-shadow(0 0 40px rgba(251, 191, 36, 0.6))
    drop-shadow(0 0 80px rgba(251, 191, 36, 0.3));
  letter-spacing: 2px;
}
.milestone-sub {
  font-family: var(--font-mono);
  font-size: 1rem;
  color: rgba(253, 230, 138, 0.7);
  margin-top: 10px;
  letter-spacing: 3px;
  text-transform: uppercase;
}
@keyframes milestoneIn {
  0% {
    opacity: 0;
  }
  10% {
    opacity: 1;
    backdrop-filter: blur(8px);
    background: rgba(0, 0, 0, 0.4);
  }
  80% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}
@keyframes milestoneGradient {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

/* == STREAK FIRE == */
.legend-chip.streak-warm {
  border-color: rgba(251, 191, 36, 0.3) !important;
  color: var(--amber) !important;
  background: rgba(251, 191, 36, 0.08) !important;
}
.legend-chip.streak-hot {
  border-color: rgba(249, 115, 22, 0.4) !important;
  color: #fb923c !important;
  background: rgba(249, 115, 22, 0.1) !important;
  box-shadow: 0 0 15px rgba(249, 115, 22, 0.15);
  animation: streakGlow 1.5s ease-in-out infinite;
}
.legend-chip.streak-fire {
  border-color: rgba(239, 68, 68, 0.5) !important;
  color: #fca5a5 !important;
  background: linear-gradient(
    135deg,
    rgba(239, 68, 68, 0.12),
    rgba(249, 115, 22, 0.08)
  ) !important;
  box-shadow:
    0 0 20px rgba(239, 68, 68, 0.2),
    0 0 40px rgba(249, 115, 22, 0.1);
  animation: streakGlow 0.8s ease-in-out infinite;
}
@keyframes streakGlow {
  0%,
  100% {
    box-shadow: 0 0 15px rgba(249, 115, 22, 0.15);
  }
  50% {
    box-shadow:
      0 0 25px rgba(249, 115, 22, 0.35),
      0 0 50px rgba(239, 68, 68, 0.15);
  }
}

/* == NEXT MONTH PULSE == */
.next-month-btn.pulse-ready {
  animation:
    btnShimmer 3s ease-in-out infinite,
    pulseReady 1.5s ease-in-out infinite;
}
@keyframes pulseReady {
  0%,
  100% {
    box-shadow: 0 4px 20px rgba(79, 143, 255, 0.25);
  }
  50% {
    box-shadow:
      0 4px 30px rgba(79, 143, 255, 0.5),
      0 0 50px rgba(79, 143, 255, 0.15);
  }
}

/* == EVENT CARD == */
.modal-content.event-modal {
  border-color: rgba(167, 139, 250, 0.3);
  background: linear-gradient(
    135deg,
    rgba(13, 18, 37, 0.92),
    rgba(21, 28, 53, 0.92)
  );
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.7),
    0 0 60px rgba(167, 139, 250, 0.1);
}
.event-emoji {
  font-size: 3rem;
  margin-bottom: 12px;
  display: block;
  animation: eventEmojiBounce 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
@keyframes eventEmojiBounce {
  0% {
    transform: scale(0) rotate(-30deg);
    opacity: 0;
  }
  50% {
    transform: scale(1.3) rotate(5deg);
  }
  100% {
    transform: scale(1) rotate(0);
  }
}
.event-choice-btn {
  width: 100%;
  padding: 14px 18px;
  border-radius: 12px;
  border: 1px solid var(--border-bright);
  background: rgba(21, 28, 53, 0.6);
  color: var(--text-main);
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 0.88rem;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  text-align: left;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.event-choice-btn:hover {
  transform: translateY(-2px);
  border-color: rgba(79, 143, 255, 0.3);
  background: rgba(21, 28, 53, 0.8);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}
.event-choice-btn .choice-hint {
  font-size: 0.72rem;
  color: var(--text-dim);
  font-family: var(--font-mono);
}

/* == HEARTBEAT LOW HEALTH == */
@keyframes heartbeat {
  0%,
  100% {
    transform: scale(1);
  }
  14% {
    transform: scale(1.04);
  }
  28% {
    transform: scale(1);
  }
  42% {
    transform: scale(1.06);
  }
  56% {
    transform: scale(1);
  }
}
body.health-critical .sidebar {
  animation: heartbeat 1.5s ease-in-out infinite;
  border-color: rgba(239, 68, 68, 0.25);
}
body.health-critical .fill-health {
  animation:
    shimmer 2.5s ease-in-out infinite,
    dangerPulse 1.45s ease-in-out infinite;
}

/* 
   NEW SECTIONS: Life Snapshot, Relationships, Pets, Prison
    */

/* Life Snapshot sidebar widget */
.life-snapshot {
  margin-top: 12px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 12px;
}
.life-snapshot .hud-title {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  opacity: 0.5;
  margin-bottom: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}
.life-snapshot .hud-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 4px 0;
  font-size: 0.78rem;
}
.life-snapshot .hud-row span:first-child {
  display: flex;
  align-items: center;
  gap: 6px;
  opacity: 0.7;
}
.life-snapshot .hud-row span:last-child {
  font-weight: 700;
  font-family: var(--font-mono);
  font-size: 0.75rem;
}

/* Card active state for prison job selection */
.card-active {
  border-color: rgba(59, 130, 246, 0.5) !important;
  background: rgba(59, 130, 246, 0.08) !important;
  box-shadow: 0 0 15px rgba(59, 130, 246, 0.15);
}

/* Danger tag for prison */
.tag.danger {
  background: rgba(239, 68, 68, 0.15);
  color: #fca5a5;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

/* Prison view styling */
#view-prison .card {
  border-color: rgba(239, 68, 68, 0.15);
}
#view-prison .section-title {
  color: #fca5a5;
}
#view-prison .section-title i {
  color: var(--red);
}

/* Relationships view */
#view-relationships .card-header h3 {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Love/trust progress bars */
#view-relationships .progress-bg {
  height: 6px;
  border-radius: 3px;
}
#view-relationships .progress-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.4s ease;
}

/* Simplified Risk HUD */
.risk-hud .hud-title {
  display: flex;
  align-items: center;
  gap: 6px;
}
.risk-hud .hud-title i {
  color: var(--red);
  font-size: 0.8rem;
}
.risk-hud .hud-row i {
  font-size: 0.7rem;
  width: 14px;
  text-align: center;
  opacity: 0.6;
}

/* Hide "hidden" HUD elements that no longer exist */
#hud-win-rate,
#hud-median-life,
#hud-bankruptcy-rate,
#hud-onboarding {
  display: none;
}

/* --- Smarts highlight --- */
.smarts-highlight {
  background: rgba(139, 92, 246, 0.12);
  border: 1px solid rgba(139, 92, 246, 0.25);
  border-radius: 10px;
  padding: 8px 10px 6px;
}
.smarts-highlight .bar-label span:first-child {
  color: #a78bfa;
  font-weight: 700;
}
.smarts-iq {
  font-size: 0.72rem;
  color: #c4b5fd;
  margin-top: 2px;
  letter-spacing: 0.3px;
}

/* ═══════════════════════════════════════════════════════════
   CHARACTER CREATION SCREEN
   ═══════════════════════════════════════════════════════════ */
.char-creation-screen {
  position: fixed;
  inset: 0;
  z-index: 9998;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(
    ellipse 120% 80% at 50% 40%,
    #0c1833 0%,
    #060a14 60%,
    #000 100%
  );
  animation: charFadeIn 0.6s ease;
  overflow-y: auto;
  padding: 20px;
}
@keyframes charFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
.char-fade-out {
  animation: charFadeOut 0.6s ease forwards !important;
}
@keyframes charFadeOut {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}

.char-creation-container {
  width: min(600px, 100%);
  max-height: 90vh;
  overflow-y: auto;
  padding: 0 4px;
}
.char-header {
  text-align: center;
  margin-bottom: 32px;
}
.char-logo {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  margin-bottom: 16px;
  box-shadow: 0 0 40px rgba(79, 143, 255, 0.2);
}
.char-header h1 {
  font-family: var(--font-ui);
  font-weight: 800;
  font-size: 1.8rem;
  color: #fff;
  margin: 0 0 8px;
}
.char-header p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.5;
  max-width: 400px;
  margin: 0 auto;
}
.char-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.char-field label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 8px;
  letter-spacing: 0.5px;
}
.char-field label i {
  color: var(--blue);
}
.char-field input[type="text"] {
  width: 100%;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-dim);
  border-radius: 12px;
  color: #fff;
  font-size: 1rem;
  font-family: var(--font-ui);
  transition: all 0.2s;
}
.char-field input[type="text"]:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(79, 143, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
}
.country-search-wrap {
  position: relative;
  margin-bottom: 12px;
}
.country-search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-dim);
  font-size: 0.85rem;
}
.country-search-wrap input {
  width: 100%;
  padding: 10px 14px 10px 38px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-dim);
  border-radius: 10px;
  color: #fff;
  font-size: 0.9rem;
  font-family: var(--font-ui);
}
.country-list-container {
  max-height: 260px;
  overflow-y: auto;
  border: 1px solid var(--border-dim);
  border-radius: 12px;
  background: rgba(21, 28, 53, 0.6);
  backdrop-filter: blur(12px);
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.1) transparent;
}
.country-list-container::-webkit-scrollbar {
  width: 6px;
}
.country-list-container::-webkit-scrollbar-track {
  background: transparent;
}
.country-list-container::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
}

@media (max-height: 600px) {
  .country-list-container {
    max-height: 180px;
  }
}

.country-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  cursor: pointer;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  transition: all 0.15s;
}
.country-item:hover {
  background: rgba(79, 143, 255, 0.08);
}
.country-item-selected {
  background: rgba(79, 143, 255, 0.15) !important;
  border-color: rgba(79, 143, 255, 0.3);
}
.country-flag {
  font-size: 1.4rem;
}
.country-name {
  flex: 1;
  font-size: 0.9rem;
  color: #fff;
  font-weight: 500;
}
.country-rating {
  font-size: 0.75rem;
  letter-spacing: 1px;
}

/* Country Details Panel */
.country-details {
  background: rgba(21, 28, 53, 0.8);
  border: 1px solid rgba(79, 143, 255, 0.2);
  border-radius: 16px;
  padding: 20px;
  backdrop-filter: blur(12px);
  animation: cardIn 250ms cubic-bezier(0.16, 1, 0.3, 1);
}
.cd-header {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 16px;
}
.cd-flag {
  font-size: 2.5rem;
  flex-shrink: 0;
}
.cd-header > div {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}
.cd-header h3 {
  font-size: 1.2rem;
  color: #fff;
  margin: 0 0 8px;
  font-weight: 700;
}
.cd-bars {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
}
.cd-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
}
.cd-bar span {
  color: var(--text-muted);
  min-width: 70px;
  font-weight: 600;
}
.cd-bar-track {
  flex: 1;
  min-width: 0;
  height: 6px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 3px;
  overflow: hidden;
}
.cd-bar-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.4s ease;
}
.cd-traits {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
}
.cd-pros,
.cd-cons {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.cd-pro,
.cd-con {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
}
.cd-pro {
  background: rgba(52, 211, 153, 0.1);
  color: #34d399;
  border: 1px solid rgba(52, 211, 153, 0.2);
}
.cd-con {
  background: rgba(239, 68, 68, 0.1);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.2);
}
.cd-effects {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.cd-eff {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.cd-eff span:first-child {
  color: var(--text-muted);
}
.cd-eff span:last-child {
  font-family: var(--font-mono);
  font-weight: 700;
}

.char-begin-btn {
  width: 100%;
  padding: 16px;
  font-size: 1.1rem;
  font-weight: 800;
  margin-top: 24px;
  border-radius: 14px;
  letter-spacing: 1px;
}
.char-begin-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ═══════════════════════════════════════════════════════════
   PLAYER IDENTITY IN SIDEBAR
   ═══════════════════════════════════════════════════════════ */
.player-identity {
  padding: 14px 16px;
  margin: 0 -16px 10px;
  border-bottom: 1px solid var(--border-dim);
  background: rgba(255, 255, 255, 0.02);
}
.player-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.3;
}
.player-name-row i {
  color: var(--blue);
  font-size: 0.9rem;
  flex-shrink: 0;
}
.player-country-row {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 4px;
  padding-left: 24px;
}
.player-traits {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 6px;
  padding-left: 24px;
}
.trait-pro,
.trait-con {
  font-size: 0.68rem;
  padding: 2px 6px;
  border-radius: 8px;
  font-weight: 600;
}
.trait-pro {
  color: #34d399;
  background: rgba(52, 211, 153, 0.08);
}
.trait-con {
  color: #f87171;
  background: rgba(239, 68, 68, 0.08);
}

/* ═══════════════════════════════════════════════════════════
   BUSINESS SECTION REDESIGN
   ═══════════════════════════════════════════════════════════ */
.biz-overview {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}
.biz-overview-stat {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: rgba(21, 28, 53, 0.6);
  border: 1px solid var(--border-dim);
  border-radius: 14px;
  backdrop-filter: blur(8px);
}
.biz-overview-stat i {
  font-size: 1.3rem;
  color: var(--purple);
  background: rgba(167, 139, 250, 0.1);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
}
.biz-ov-value {
  display: block;
  font-size: 1.2rem;
  font-weight: 800;
  color: #fff;
  font-family: var(--font-mono);
}
.biz-ov-label {
  display: block;
  font-size: 0.72rem;
  color: var(--text-dim);
  letter-spacing: 0.5px;
  text-transform: uppercase;
}
.biz-launch-section {
  margin-bottom: 32px;
}
.biz-launch-desc {
  color: var(--text-muted);
  font-size: 0.88rem;
  margin-bottom: 16px;
  line-height: 1.5;
}
.biz-type-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 10px;
}
.biz-type-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: rgba(21, 28, 53, 0.5);
  border: 1px solid var(--border-dim);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.biz-type-card:hover {
  border-color: rgba(167, 139, 250, 0.4);
  background: rgba(167, 139, 250, 0.05);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}
.biz-type-locked {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
}
.biz-type-icon {
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  font-size: 1.1rem;
  flex-shrink: 0;
}
.biz-type-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.biz-type-name {
  font-weight: 700;
  color: #fff;
  font-size: 0.9rem;
}
.biz-type-cost {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
}
.biz-type-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  font-size: 0.72rem;
  color: var(--text-dim);
  font-family: var(--font-mono);
}

/* Startup Cards */
.biz-startup-card {
  border-radius: 16px !important;
  overflow: hidden;
}
.biz-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-dim);
  margin-bottom: 16px;
}
.biz-card-title {
  display: flex;
  align-items: center;
  gap: 12px;
}
.biz-card-icon {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  font-size: 1.2rem;
  flex-shrink: 0;
}
.biz-card-title h3 {
  font-size: 1.1rem;
  color: #fff;
  margin: 0 0 4px;
  font-weight: 700;
}
.biz-card-profit {
  text-align: right;
}
.biz-card-profit small {
  font-size: 0.7rem;
  opacity: 0.7;
}
.biz-card-users {
  display: block;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 2px;
}
.biz-metrics-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 16px;
}
.biz-metric {
  padding: 10px;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 10px;
  text-align: center;
}
.biz-metric-label {
  display: block;
  font-size: 0.65rem;
  letter-spacing: 1px;
  color: var(--text-dim);
  margin-bottom: 4px;
  font-family: var(--font-mono);
}
.biz-metric-value {
  font-size: 1rem;
  font-weight: 800;
  color: #fff;
  font-family: var(--font-mono);
}
.biz-section-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 16px;
}
.biz-section-title {
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}
.biz-section-title i {
  font-size: 0.7rem;
}
.biz-morale-tag {
  margin-left: auto;
  font-weight: 700;
  font-size: 0.75rem;
}
.biz-pmf-bar {
  margin-bottom: 12px;
}
.biz-pmf-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  margin-bottom: 4px;
  color: var(--text-muted);
}
.biz-product-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.biz-pstat {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
}
.biz-pstat i {
  color: var(--text-muted);
  font-size: 0.8rem;
}
.biz-pstat span {
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
}
.biz-pstat small {
  font-size: 0.7rem;
  color: var(--text-dim);
}
.biz-pstat-bad {
  background: rgba(239, 68, 68, 0.06);
}
.biz-pstat-bad i {
  color: #f87171;
}
.biz-pstat-bad span {
  color: #ef4444;
}

/* Team Roles */
.biz-role-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}
.biz-role-info {
  display: flex;
  align-items: center;
  gap: 8px;
}
.biz-role-icon {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(167, 139, 250, 0.1);
  border-radius: 6px;
  color: var(--purple);
  font-size: 0.7rem;
}
.biz-role-name {
  display: block;
  font-weight: 700;
  color: #fff;
  font-size: 0.82rem;
}
.biz-role-desc {
  display: block;
  font-size: 0.7rem;
  color: var(--text-dim);
}
.biz-role-controls {
  display: flex;
  align-items: center;
  gap: 6px;
}
.biz-role-btn {
  width: 24px;
  height: 24px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  border: 1px solid var(--border-dim);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s;
  font-size: 0.65rem;
}
.biz-role-btn:hover {
  border-color: var(--purple);
  color: #fff;
  background: rgba(167, 139, 250, 0.15);
}
.biz-role-hire {
  border-color: rgba(52, 211, 153, 0.3);
  color: #34d399;
}
.biz-role-hire:hover {
  border-color: #34d399;
  background: rgba(52, 211, 153, 0.15);
}
.biz-role-count {
  font-family: var(--font-mono);
  font-weight: 800;
  font-size: 0.9rem;
  color: #fff;
  width: 20px;
  text-align: center;
}
.biz-role-salary {
  font-size: 0.68rem;
  color: var(--text-dim);
  font-family: var(--font-mono);
  min-width: 52px;
  text-align: right;
}

/* Action Buttons */
.biz-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--border-dim);
}
.biz-action-btn {
  flex: 1;
  min-width: 100px;
  padding: 8px 12px !important;
  font-size: 0.78rem !important;
  font-weight: 700;
  border-radius: 8px !important;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s;
}
.biz-action-btn small {
  opacity: 0.7;
  font-size: 0.68rem;
}
.biz-act-campaign {
  background: rgba(251, 191, 36, 0.12) !important;
  color: #fbbf24 !important;
  border: 1px solid rgba(251, 191, 36, 0.25) !important;
}
.biz-act-campaign:hover {
  background: rgba(251, 191, 36, 0.2) !important;
}
.biz-act-funding {
  background: rgba(52, 211, 153, 0.12) !important;
  color: #34d399 !important;
  border: 1px solid rgba(52, 211, 153, 0.25) !important;
}
.biz-act-funding:hover {
  background: rgba(52, 211, 153, 0.2) !important;
}
.biz-act-pivot {
  background: rgba(167, 139, 250, 0.12) !important;
  color: #a78bfa !important;
  border: 1px solid rgba(167, 139, 250, 0.25) !important;
}
.biz-act-pivot:hover {
  background: rgba(167, 139, 250, 0.2) !important;
}
.biz-act-exit {
  background: rgba(79, 143, 255, 0.12) !important;
  color: #60a5fa !important;
  border: 1px solid rgba(79, 143, 255, 0.25) !important;
}
.biz-act-exit:hover {
  background: rgba(79, 143, 255, 0.2) !important;
}
.biz-act-advisor {
  background: rgba(244, 114, 182, 0.12) !important;
  color: #f472b6 !important;
  border: 1px solid rgba(244, 114, 182, 0.25) !important;
}
.biz-act-advisor:hover {
  background: rgba(244, 114, 182, 0.2) !important;
}

/* Responsive */
@media (max-width: 768px) {
  .biz-overview {
    grid-template-columns: repeat(2, 1fr);
  }
  .biz-section-grid {
    grid-template-columns: 1fr;
  }
  .biz-metrics-row {
    grid-template-columns: repeat(2, 1fr);
  }
  .biz-type-grid {
    grid-template-columns: 1fr;
  }
  .biz-actions {
    flex-direction: column;
  }
  .biz-action-btn {
    min-width: auto;
  }
  .cd-effects {
    grid-template-columns: 1fr;
  }
  .char-creation-container {
    padding: 0;
  }
  .country-details {
    padding: 14px;
  }
  .cd-header {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .cd-bars {
    width: 100%;
    max-width: 100%;
  }
  .cd-bar {
    gap: 6px;
  }
  .cd-bar span {
    min-width: 55px;
    font-size: 0.68rem;
  }
  .cd-bar-track {
    min-width: 0;
    flex: 1;
    height: 8px;
  }
}

/* Mobile player identity in stats panel */
.msp-identity {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 0 8px;
  margin-bottom: 6px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.msp-player-name {
  font-weight: 700;
  font-size: 0.95rem;
  color: #fff;
}
.msp-player-country {
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* Mobile top bar name */
.mtb-name {
  font-weight: 700;
  color: #fff;
  font-size: 0.82rem;
  max-width: 80px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ═══════════════════════════════════════════════════════════
   BUSINESS GUIDE
   ═══════════════════════════════════════════════════════════ */
.biz-guide {
  background: linear-gradient(
    135deg,
    rgba(59, 130, 246, 0.08),
    rgba(139, 92, 246, 0.06)
  );
  border: 1px solid rgba(59, 130, 246, 0.18);
  border-radius: 14px;
  padding: 18px 20px;
  margin-bottom: 16px;
}
.biz-guide-title {
  font-size: 1rem;
  font-weight: 700;
  color: #60a5fa;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.biz-guide-title i {
  font-size: 1.1rem;
}
.biz-guide-steps {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.biz-guide-step {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
}
.biz-step-num {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(59, 130, 246, 0.15);
  color: #60a5fa;
  font-weight: 800;
  font-size: 0.78rem;
  flex-shrink: 0;
}
.biz-guide-tips .biz-guide-title {
  color: #fbbf24;
}
.biz-guide-tip-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.biz-guide-tip {
  font-size: 0.84rem;
  color: var(--text-muted);
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
  border-left: 3px solid #fbbf24;
  line-height: 1.5;
}
.biz-guide-tip b {
  color: #fff;
}

/* ═══════════════════════════════════════════════════════════
   TRAVEL & MIGRATION SECTION
   ═══════════════════════════════════════════════════════════ */
.travel-current {
  background: linear-gradient(
    135deg,
    rgba(15, 23, 42, 0.8),
    rgba(30, 41, 59, 0.6)
  );
  border: 1px solid var(--border-dim);
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 16px;
}
.travel-current-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 10px;
}
.travel-current-flag {
  font-size: 2.5rem;
}
.travel-current-header h3 {
  margin: 0;
  font-size: 1.15rem;
  color: #fff;
  font-weight: 700;
}
.travel-danger-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: 20px;
  border: 1px solid;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 4px;
}
.travel-danger-desc {
  font-size: 0.84rem;
  color: var(--text-muted);
  margin: 8px 0 14px;
  line-height: 1.5;
}
.travel-stats-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.78rem;
  color: var(--text-muted);
}
.travel-stats-row span {
  white-space: nowrap;
}

/* Migration in progress */
.travel-migration-active {
  background: linear-gradient(
    135deg,
    rgba(59, 130, 246, 0.12),
    rgba(139, 92, 246, 0.08)
  );
  border: 1px solid rgba(59, 130, 246, 0.25);
  border-radius: 14px;
  padding: 18px 20px;
  margin-bottom: 16px;
  animation: cardIn 300ms ease-out;
}
.travel-mig-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}
.travel-mig-header i {
  font-size: 1.5rem;
  color: #60a5fa;
}
.travel-mig-header h3 {
  margin: 0;
  font-size: 1rem;
  color: #fff;
  font-weight: 700;
}
.travel-mig-method {
  font-size: 0.78rem;
  color: var(--text-muted);
  display: block;
  margin-top: 2px;
}
.travel-mig-progress {
  display: flex;
  align-items: center;
  gap: 12px;
}
.travel-mig-bar-track {
  flex: 1;
  height: 8px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 4px;
  overflow: hidden;
}
.travel-mig-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #3b82f6, #8b5cf6);
  border-radius: 4px;
  transition: width 0.4s ease;
}
.travel-mig-progress span {
  font-size: 0.78rem;
  color: var(--text-muted);
  white-space: nowrap;
}

/* Country search */
.travel-search-wrap {
  position: relative;
  margin-bottom: 16px;
}
.travel-search-wrap i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 0.85rem;
}
.travel-search-wrap input {
  width: 100%;
  padding: 10px 14px 10px 38px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-dim);
  border-radius: 10px;
  color: #fff;
  font-size: 0.88rem;
  outline: none;
  transition: border-color 0.2s;
}
.travel-search-wrap input:focus {
  border-color: rgba(59, 130, 246, 0.5);
}

/* Country cards in travel list */
.travel-country-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 500px;
  overflow-y: auto;
  padding-right: 4px;
}
.travel-country-card {
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid var(--border-dim);
  border-radius: 12px;
  padding: 14px 16px;
  transition:
    border-color 0.2s,
    transform 0.15s;
}
.travel-country-card:hover {
  border-color: rgba(59, 130, 246, 0.3);
  transform: translateY(-1px);
}
.travel-cc-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}
.travel-cc-flag {
  font-size: 1.6rem;
}
.travel-cc-info {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.travel-cc-name {
  font-weight: 700;
  color: #fff;
  font-size: 0.92rem;
}
.travel-cc-rating {
  font-size: 0.78rem;
}
.travel-tag {
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 10px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.travel-tag-danger {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.1);
}
.travel-tag-safe {
  color: #34d399;
  background: rgba(52, 211, 153, 0.1);
}

.travel-cc-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.travel-option {
  padding: 10px 12px;
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.travel-option-legal {
  background: rgba(52, 211, 153, 0.06);
  border: 1px solid rgba(52, 211, 153, 0.15);
}
.travel-option-illegal {
  background: rgba(239, 68, 68, 0.06);
  border: 1px solid rgba(239, 68, 68, 0.15);
}
.travel-opt-head {
  font-weight: 700;
  font-size: 0.82rem;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
}
.travel-opt-detail {
  font-size: 0.72rem;
  color: var(--text-muted);
}
.travel-option .btn {
  margin-top: 6px;
  font-size: 0.72rem !important;
  padding: 5px 10px !important;
}
.btn-sm {
  font-size: 0.72rem !important;
  padding: 5px 10px !important;
}

@media (max-width: 768px) {
  .travel-cc-options {
    grid-template-columns: 1fr;
  }
  .travel-stats-row {
    flex-direction: column;
    gap: 4px;
  }
}

/* ═══════════════════════════════════════════════════════════
   PAST LIVES
   ═══════════════════════════════════════════════════════════ */
.past-life-card {
  padding: 16px 18px !important;
}
.past-life-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}
.past-life-icon {
  font-size: 1.3rem;
  flex-shrink: 0;
}
.past-life-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.past-life-name {
  font-weight: 700;
  font-size: 1rem;
  color: #fff;
}
.past-life-status {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.past-life-date {
  font-size: 0.72rem;
  color: var(--text-muted);
  flex-shrink: 0;
}
.past-life-details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.past-life-detail {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
}
.past-life-detail span {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.past-life-detail strong {
  font-size: 0.85rem;
  color: #fff;
}

@media (max-width: 768px) {
  .past-life-details {
    grid-template-columns: 1fr;
  }
}

/* ═══════════════════════════════════════════════════════════
   BUSINESS ACTION BUTTONS (new)
   ═══════════════════════════════════════════════════════════ */
.biz-act-invest {
  background: rgba(251, 191, 36, 0.12) !important;
  color: #fbbf24 !important;
  border: 1px solid rgba(251, 191, 36, 0.25) !important;
}
.biz-act-invest:hover {
  background: rgba(251, 191, 36, 0.2) !important;
}
.biz-act-morale {
  background: rgba(56, 189, 248, 0.12) !important;
  color: #38bdf8 !important;
  border: 1px solid rgba(56, 189, 248, 0.25) !important;
}
.biz-act-morale:hover {
  background: rgba(56, 189, 248, 0.2) !important;
}
