/* ═══════════════════════════════════════════════════════════════
   TERRAFORM — Planetary Bio-Restoration & Environmental Intelligence
   Cyber-Organic Bio-Emerald & Luminescent Jade Theme
   Design System: Transparent Glassmorphism + Electric Green Accents: rgba(90, 225, 76, 0.89)
   ═══════════════════════════════════════════════════════════════ */

:root {
  /* ── Canvas & Surface Hierarchy (Transparent Glassmorphic Surfaces) ── */
  --bg-void: #020906;
  --bg-deep: rgba(4, 18, 10, 0.45);
  --bg-surface: rgba(7, 24, 15, 0.38);
  --bg-surface-elevated: rgba(12, 34, 22, 0.48);
  --bg-surface-card: rgba(8, 26, 17, 0.38);
  --bg-surface-hover: rgba(14, 42, 27, 0.55);
  --bg-glass: rgba(90, 225, 76, 0.05);

  /* ── Precision Accents (Connected to rgba(90, 225, 76, 0.89) / #5ae14c) ── */
  --accent-primary: rgba(90, 225, 76, 0.89);
  --accent-primary-hex: #5ae14c;
  --accent-primary-light: #7cf56e;
  --accent-primary-dark: #3cb82f;
  --accent-primary-glow: rgba(90, 225, 76, 0.45);
  --accent-primary-subtle: rgba(90, 225, 76, 0.15);

  --accent-emerald: rgba(90, 225, 76, 0.89);
  --accent-emerald-light: #7cf56e;
  --accent-emerald-dark: #3cb82f;
  --accent-emerald-glow: rgba(90, 225, 76, 0.45);
  --accent-emerald-subtle: rgba(90, 225, 76, 0.15);

  --accent-cyan: #06b6d4;
  --accent-cyan-light: #22d3ee;
  --accent-teal: #14b8a6;
  --accent-coral: #5ae14c;

  /* Legacy variable mapping for compatibility */
  --neon-magenta: #5ae14c;
  --neon-pink: #7cf56e;
  --neon-violet: #3cb82f;
  --neon-purple: #2f9425;
  --neon-cyan: #22d3ee;
  --neon-emerald: #5ae14c;

  --glow-magenta: rgba(90, 225, 76, 0.42);
  --glow-magenta-soft: rgba(90, 225, 76, 0.18);
  --glow-violet: rgba(60, 184, 47, 0.28);
  --glow-pink: rgba(124, 245, 110, 0.28);

  /* ── Glass Borders ── */
  --border-subtle: rgba(90, 225, 76, 0.16);
  --border-medium: rgba(90, 225, 76, 0.26);
  --border-accent: rgba(90, 225, 76, 0.55);
  --border-glass: rgba(255, 255, 255, 0.1);
  --border-glass-bright: rgba(90, 225, 76, 0.65);
  --border-violet: rgba(90, 225, 76, 0.3);

  /* ── Semantic Status Colors ── */
  --status-success: #5ae14c;
  --status-success-dim: rgba(90, 225, 76, 0.16);
  --status-warning: #f59e0b;
  --status-warning-dim: rgba(245, 158, 11, 0.15);
  --status-danger: #f43f5e;
  --status-danger-dim: rgba(244, 63, 94, 0.15);
  --status-info: #22d3ee;
  --status-info-dim: rgba(34, 211, 238, 0.15);

  /* ── Typography & Scaling ── */
  --font-display: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'Plus Jakarta Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', Consolas, monospace;

  /* ── Text Contrast ── */
  --text-bright: #ffffff;
  --text-main: #e2e8f0;
  --text-muted: #94a3b8;
  --text-dim: #64748b;

  /* ── Geometry & Corners ── */
  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 18px;
  --radius-xl: 24px;
  --radius-pill: 9999px;

  /* ── Transitions ── */
  --ease-spring: cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: 0.18s var(--ease-spring);
  --transition-smooth: 0.3s var(--ease-spring);
}

/* ── Reset & Baseline ── */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  background-color: var(--bg-void);
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: transparent !important;
  background-image: none !important;
  color: var(--text-main);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ═══════════════════════════════════════════════════════════════
   CINEMATIC VIDEO BACKGROUND SYSTEM (From req.md)
   ═══════════════════════════════════════════════════════════════ */
.video-bg-container {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
  background-color: #020906;
}

.video-wrapper {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.8s;
}

.video-wrapper.active {
  opacity: 1;
  visibility: visible;
}

.bg-video {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  object-fit: cover;
  opacity: 1 !important;
  display: block;
}

.video-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.login-overlay {
  background: linear-gradient(180deg, rgba(2, 9, 6, 0.15) 0%, rgba(2, 9, 6, 0.45) 100%);
}

.dashboard-overlay {
  background: linear-gradient(180deg, rgba(2, 9, 6, 0.25) 0%, rgba(2, 9, 6, 0.6) 100%);
}

.tech-ambient {
  display: none !important;
}

/* ── Universal Screen Container ── */
.screen {
  display: none;
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

.screen.active {
  display: flex;
  flex-direction: column;
}

/* ═══════════════════════════════════════════════════════════════
   1. LOGIN / SYSTEM INITIALIZATION SCREEN
   ═══════════════════════════════════════════════════════════════ */
#login-screen {
  align-items: center;
  justify-content: center;
  padding: 3rem 1.5rem;
  min-height: 100vh;
  position: relative;
}

.login-wrapper {
  width: 100%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  animation: loginAppear 0.6s var(--ease-spring);
  position: relative;
  z-index: 2;
}

@keyframes loginAppear {
  from { opacity: 0; transform: translateY(20px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.brand-hero {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ── Top Corner Institutional Branding ── */
.login-brand-bar {
  position: absolute;
  top: 1.5rem;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 2.5rem;
  z-index: 10;
  pointer-events: auto;
}

.login-brand-left,
.login-brand-right {
  display: flex;
  align-items: center;
}

.brand-top-logo {
  display: block;
  object-fit: contain;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), filter 0.25s ease;
}

.ruas-logo {
  height: 60px;
  max-width: 250px;
  filter: drop-shadow(0 3px 14px rgba(0, 0, 0, 0.5));
}

.ruas-logo:hover {
  transform: translateY(-2px) scale(1.03);
  filter: drop-shadow(0 6px 20px rgba(0, 0, 0, 0.65));
}

.aiclub-logo {
  height: 68px;
  max-width: 110px;
  filter: drop-shadow(0 3px 14px rgba(0, 0, 0, 0.5));
}

.aiclub-logo:hover {
  transform: translateY(-2px) scale(1.04);
  filter: drop-shadow(0 6px 20px rgba(147, 51, 234, 0.4));
}

/* ── Pravrutti 2.0 Hero Emblem (Centered in Brand Hero) ── */
.pravrutti-hero-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  width: 100%;
}

.pravrutti-hero-logo {
  max-width: 340px;
  height: auto;
  max-height: 98px;
  object-fit: contain;
  filter: drop-shadow(0 4px 22px rgba(236, 72, 153, 0.45)) drop-shadow(0 2px 8px rgba(0, 0, 0, 0.65));
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), filter 0.25s ease;
}

.pravrutti-hero-logo:hover {
  transform: scale(1.03);
  filter: drop-shadow(0 6px 28px rgba(236, 72, 153, 0.65)) drop-shadow(0 3px 12px rgba(0, 0, 0, 0.75));
}

@media (max-width: 768px) {
  .login-brand-bar {
    position: relative;
    top: 0;
    padding: 1rem 1.25rem 0.5rem;
    width: 100%;
    margin-bottom: 0.5rem;
  }
  .ruas-logo {
    height: 46px;
    max-width: 190px;
  }
  .aiclub-logo {
    height: 52px;
    max-width: 85px;
  }
  .pravrutti-hero-logo {
    max-width: 250px;
    max-height: 72px;
  }
}

.brand-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.35rem 1rem;
  border-radius: var(--radius-pill);
  background: var(--accent-emerald-subtle);
  border: 1px solid rgba(16, 185, 129, 0.28);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--accent-emerald-light);
  letter-spacing: 0.08em;
  margin-bottom: 1.25rem;
}

.pulsing-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-emerald);
  box-shadow: 0 0 8px var(--accent-emerald);
  animation: pulseDot 2s infinite;
}

@keyframes pulseDot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.3); opacity: 0.6; }
}

.brand-logo-container {
  width: 76px;
  height: 76px;
  margin-bottom: 0.9rem;
  filter: drop-shadow(0 0 20px rgba(16, 185, 129, 0.3));
}

.brand-svg {
  width: 100%;
  height: 100%;
}

.brand-title {
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 900;
  letter-spacing: -0.04em;
  color: #ffffff;
  line-height: 1.05;
  margin-bottom: 0.4rem;
}

.brand-subtitle {
  font-size: 0.94rem;
  color: var(--text-muted);
  max-width: 380px;
  line-height: 1.5;
}

/* Glassmorphic Login Card */
.glass-card {
  background: var(--bg-surface-card);
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  position: relative;
  overflow: visible;
  transition: all var(--transition-smooth);
}

.glass-card:hover {
  border-color: rgba(255, 255, 255, 0.12);
}

.login-card {
  width: 100%;
  padding: 2.25rem 2.25rem 2rem;
  position: relative;
}

/* Hide tacky corner brackets */
.hud-corner {
  display: none !important;
}

.card-status-strip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-subtle);
}

.strip-left {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.pulsing-chip {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-emerald);
  box-shadow: 0 0 8px var(--accent-emerald);
}

.strip-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-dim);
  letter-spacing: 0.08em;
  font-weight: 700;
}

.strip-right-telemetry {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.telemetry-ping {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--accent-emerald-light);
  letter-spacing: 0.05em;
  background: var(--accent-emerald-subtle);
  padding: 0.18rem 0.55rem;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(16, 185, 129, 0.25);
  font-weight: 600;
}

.strip-code {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--accent-cyan-light);
  background: var(--status-info-dim);
  border: 1px solid rgba(14, 165, 233, 0.25);
  padding: 0.18rem 0.55rem;
  border-radius: var(--radius-pill);
  letter-spacing: 0.05em;
}

.login-form-inner {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
  width: 100%;
}

.field-label-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.field-label {
  font-family: var(--font-display);
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-bright);
}

.field-hint {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-dim);
}

.input-wrapper {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 1.25rem;
  color: var(--text-muted);
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 4;
}

.input-clear-btn {
  position: absolute;
  right: 1.15rem;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  z-index: 5;
}

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

.text-input,
input#team-name-input {
  -webkit-appearance: none !important;
  appearance: none !important;
  width: 100% !important;
  height: 52px !important;
  padding: 0 3.2rem 0 3.2rem !important;
  background: var(--bg-deep) !important;
  border: 1.5px solid var(--border-medium) !important;
  border-radius: var(--radius-pill) !important;
  font-family: var(--font-body) !important;
  font-size: 0.98rem !important;
  font-weight: 500 !important;
  color: #ffffff !important;
  outline: none !important;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.4) !important;
  transition: all var(--transition-fast) !important;
}

.text-input:focus,
input#team-name-input:focus {
  border-color: var(--accent-emerald) !important;
  background: var(--bg-surface) !important;
  box-shadow: 0 0 0 3px var(--accent-emerald-subtle), inset 0 2px 6px rgba(0, 0, 0, 0.4) !important;
}

.text-input::placeholder,
input#team-name-input::placeholder {
  color: var(--text-dim) !important;
  font-size: 0.92rem !important;
}

/* Chrome autofill background override */
.text-input:-webkit-autofill,
.text-input:-webkit-autofill:hover, 
.text-input:-webkit-autofill:focus {
  -webkit-text-fill-color: #ffffff !important;
  -webkit-box-shadow: 0 0 0px 1000px var(--bg-deep) inset !important;
  transition: background-color 5000s ease-in-out 0s !important;
}

/* Autocomplete Dropdown */
.autocomplete-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: var(--bg-surface-elevated);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-md);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6);
  z-index: 100;
  overflow: hidden;
  max-height: 230px;
  overflow-y: auto;
  animation: dropdownFade 0.2s var(--ease-spring);
}

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

.autocomplete-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.15rem;
  cursor: pointer;
  border-bottom: 1px solid var(--border-subtle);
  transition: all 0.15s ease;
}

.autocomplete-item:last-child {
  border-bottom: none;
}

.autocomplete-item:hover {
  background: rgba(16, 185, 129, 0.12);
  padding-left: 1.35rem;
}

.item-left {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.team-badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-emerald);
}

.item-name {
  font-family: var(--font-body);
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-main);
}

.item-name mark {
  background: transparent;
  color: var(--accent-emerald-light);
  font-weight: 800;
  text-decoration: underline;
  text-decoration-color: rgba(16, 185, 129, 0.5);
  text-underline-offset: 2px;
}

.item-select-hint {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--text-dim);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-pill);
  letter-spacing: 0.05em;
  transition: all 0.15s ease;
}

.autocomplete-item:hover .item-select-hint {
  background: var(--accent-emerald);
  color: #032014;
  border-color: var(--accent-emerald);
}

.autocomplete-empty {
  padding: 1.25rem 1rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.autocomplete-more-hint {
  padding: 0.45rem 1rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-dim);
  text-align: center;
  background: rgba(0, 0, 0, 0.2);
}

/* Roster Quick-Select Drawer */
.roster-helper-row {
  display: flex;
  justify-content: flex-start;
}

.roster-toggle-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-pill);
  color: var(--text-muted);
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0.4rem 1rem;
  transition: all var(--transition-fast);
}

.roster-toggle-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

.chevron-badge {
  font-size: 0.65rem;
  opacity: 0.7;
  margin-left: 0.2rem;
}

.roster-preview-drawer {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.5);
  animation: drawerSlideDown 0.25s var(--ease-spring);
}

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

.roster-preview-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--border-subtle);
  gap: 0.5rem;
}

.roster-preview-title {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  white-space: nowrap;
}

.roster-filter-box {
  flex: 1;
  max-width: 170px;
}

.roster-filter-box input {
  width: 100%;
  height: 28px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-pill);
  padding: 0 0.75rem;
  font-size: 0.74rem;
  color: #ffffff;
  outline: none;
  font-family: var(--font-body);
}

.roster-filter-box input:focus {
  border-color: var(--accent-emerald);
}

.roster-close-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  color: var(--text-muted);
  font-size: 0.72rem;
  padding: 0.25rem 0.65rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.roster-close-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
}

.roster-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  max-height: 160px;
  overflow-y: auto;
  padding-right: 0.3rem;
}

.team-pill {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  padding: 0.35rem 0.75rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.team-pill:hover {
  background: var(--accent-emerald-subtle);
  color: var(--accent-emerald-light);
  border-color: rgba(16, 185, 129, 0.35);
  transform: translateY(-1px);
}

/* Primary Submit CTA */
.login-submit-btn {
  width: 100%;
  height: 52px;
  border-radius: var(--radius-pill);
  background: rgba(90, 225, 76, 0.89) !important;
  color: #031806 !important;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  border: none;
  box-shadow: 0 8px 24px rgba(90, 225, 76, 0.45) !important;
  transition: all var(--transition-smooth);
  margin-top: 0.25rem;
  position: relative;
  overflow: hidden;
}

.login-submit-btn:hover {
  transform: translateY(-2px);
  background: rgba(105, 245, 90, 0.96) !important;
  box-shadow: 0 12px 30px rgba(90, 225, 76, 0.6) !important;
  filter: brightness(1.06);
}

.login-submit-btn:active {
  transform: translateY(0);
}

.btn-arrow-icon {
  transition: transform var(--transition-fast);
}

.login-submit-btn:hover .btn-arrow-icon {
  transform: translateX(4px);
}

.btn-glow-bar {
  display: none;
}

.btn-text {
  position: relative;
  z-index: 2;
}

/* Error Banner */
.error-banner {
  background: var(--status-danger-dim);
  border: 1px solid rgba(244, 63, 94, 0.35);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.15rem;
  font-size: 0.86rem;
  color: #fecdd3;
  line-height: 1.45;
  animation: shakeError 0.4s ease;
}

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

.login-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border-subtle);
  width: 100%;
}

.fest-tag {
  font-size: 0.76rem;
  color: var(--text-dim);
  font-family: var(--font-mono);
}

.admin-auth-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-pill);
  color: var(--text-muted);
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0.35rem 0.85rem;
  transition: all var(--transition-fast);
}

.admin-auth-btn:hover {
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.08);
}

/* ═══════════════════════════════════════════════════════════════
   2. TOP NAVIGATION COMMAND DECK
   ═══════════════════════════════════════════════════════════════ */
.top-nav {
  position: sticky;
  top: 1rem;
  margin: 1rem 1.75rem 0;
  z-index: 50;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1.5rem;
  background: rgba(15, 22, 35, 0.82);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-pill);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.45);
}

.nav-left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.logo-mark {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-emerald);
}

.logo-mark svg {
  width: 100%;
  height: 100%;
}

.brand-text-group {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.nav-brand {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 900;
  color: #ffffff;
  letter-spacing: -0.02em;
}

.nav-status-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--accent-emerald-light);
  background: var(--accent-emerald-subtle);
  border: 1px solid rgba(16, 185, 129, 0.25);
  padding: 0.15rem 0.55rem;
  border-radius: var(--radius-pill);
  letter-spacing: 0.05em;
}

.live-pulse {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-emerald);
  box-shadow: 0 0 6px var(--accent-emerald);
}

.nav-center {
  display: flex;
  align-items: center;
}

.team-meta-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.4rem 1.1rem;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-size: 0.8rem;
}

.meta-label {
  color: var(--text-dim);
  font-weight: 600;
}

.meta-value {
  color: #ffffff;
  font-weight: 700;
}

.meta-divider {
  color: var(--border-medium);
}

.meta-scenario-chip {
  color: var(--text-muted);
  font-weight: 700;
  background: rgba(255, 255, 255, 0.06);
  padding: 0.15rem 0.55rem;
  border-radius: var(--radius-pill);
}

.meta-scenario-chip.claimed {
  background: var(--accent-emerald-subtle);
  color: var(--accent-emerald-light);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 1rem;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-medium);
  color: var(--text-muted);
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.nav-btn:hover {
  background: rgba(255, 255, 255, 0.09);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.2);
}

.logout-btn:hover {
  border-color: rgba(244, 63, 94, 0.4);
  color: #fecdd3;
}

/* ═══════════════════════════════════════════════════════════════
   3. MAIN WORKSPACE & SCENARIO SELECTION (01–05)
   ═══════════════════════════════════════════════════════════════ */
.main-container {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 2.25rem 2rem 5rem;
  display: flex;
  flex-direction: column;
  gap: 2.25rem;
  position: relative;
  z-index: 1;
}

.scenario-selector-section {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.selector-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  gap: 1rem;
}

.section-title {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #ffffff;
}

.section-subtitle {
  font-size: 0.94rem;
  color: var(--text-muted);
  max-width: 650px;
  line-height: 1.55;
  margin-top: 0.25rem;
}

.quota-legend {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  font-family: var(--font-mono);
  font-size: 0.76rem;
  color: var(--text-dim);
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.legend-dot.available {
  background: var(--accent-emerald);
  box-shadow: 0 0 6px var(--accent-emerald);
}

.legend-dot.full {
  background: var(--status-danger);
}

/* 5-Card Scenario Grid */
.scenarios-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1.15rem;
}

@media (max-width: 1200px) {
  .scenarios-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
  .scenarios-grid { grid-template-columns: 1fr; }
}

/* Professional Scenario Card */
.scenario-card {
  position: relative;
  background: var(--bg-surface-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  cursor: pointer;
  transition: all var(--transition-smooth);
  overflow: hidden;
}

.scenario-card:hover:not(.disabled):not(.selected) {
  transform: translateY(-4px);
  border-color: rgba(16, 185, 129, 0.4);
  background: var(--bg-surface-hover);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.45), 0 0 20px var(--accent-emerald-subtle);
}

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

/* Clean Monospace Number Badge */
.scenario-number-badge {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--accent-emerald-light);
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  background: var(--accent-emerald-subtle);
  border: 1px solid rgba(16, 185, 129, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
}

.quota-indicator {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 700;
  padding: 0.22rem 0.6rem;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-muted);
  border: 1px solid var(--border-subtle);
}

.quota-indicator.full {
  background: var(--status-danger-dim);
  color: var(--status-danger);
  border-color: rgba(244, 63, 94, 0.3);
}

.scenario-info-block {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.scenario-card-title {
  font-family: var(--font-display);
  font-size: 1.08rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.scenario-card-sub {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Quota Progress Bar */
.quota-progress-track {
  width: 100%;
  height: 5px;
  background: rgba(255, 255, 255, 0.07);
  border-radius: var(--radius-pill);
  overflow: hidden;
  margin-top: auto;
}

.quota-progress-fill {
  height: 100%;
  background: var(--accent-emerald);
  border-radius: var(--radius-pill);
  transition: width 0.4s ease;
}

.quota-progress-fill.full {
  background: var(--status-danger);
}

.card-select-btn {
  width: 100%;
  padding: 0.65rem;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-medium);
  color: var(--text-main);
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.card-select-btn:hover {
  background: var(--accent-emerald);
  border-color: var(--accent-emerald);
  color: #042013;
  box-shadow: 0 4px 14px var(--accent-emerald-glow);
}

/* Selected State */
.scenario-card.selected {
  background: var(--bg-surface-elevated);
  border: 1.5px solid var(--accent-emerald);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5), 0 0 25px var(--accent-emerald-glow);
  transform: translateY(-2px);
}

.scenario-card.selected .card-select-btn {
  background: var(--accent-emerald);
  color: #032014;
  border: none;
  font-weight: 800;
  cursor: default;
}

.scenario-card.disabled {
  opacity: 0.38;
  cursor: not-allowed;
  pointer-events: none;
}

/* Locked Callout Banner */
.locked-status-banner {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1.25rem 1.75rem;
  border-radius: var(--radius-lg);
  background: var(--accent-emerald-subtle);
  border: 1px solid rgba(16, 185, 129, 0.3);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  animation: fadeIn 0.4s ease;
}

.locked-badge-icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.2);
  color: var(--accent-emerald-light);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.locked-text-group {
  display: flex;
  flex-direction: column;
}

.locked-title {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent-emerald-light);
  letter-spacing: 0.08em;
}

.locked-desc {
  font-size: 0.95rem;
  color: #ffffff;
}

/* ═══════════════════════════════════════════════════════════════
   4. UNIVERSAL GROUND RULE CALLOUT CARD
   ═══════════════════════════════════════════════════════════════ */
.ground-rule-banner {
  position: relative;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-medium);
  border-left: 4px solid var(--accent-emerald);
  border-radius: var(--radius-lg);
  padding: 1.4rem 1.75rem;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
  margin: 1.5rem 0 2rem;
}

.ground-rule-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}

.ground-rule-icon {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-xs);
  background: var(--accent-emerald-subtle);
  color: var(--accent-emerald-light);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ground-rule-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.01em;
}

.ground-rule-text {
  font-size: 0.94rem;
  line-height: 1.65;
  color: var(--text-main);
}

/* ═══════════════════════════════════════════════════════════════
   5. WORKSPACE TABS & PANELS
   ═══════════════════════════════════════════════════════════════ */
.workspace-tabs-section {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* Segmented Pill Tabs Dock */
.custom-tabs-nav {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-pill);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  width: fit-content;
  max-width: 100%;
  overflow-x: auto;
}

.custom-tab {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.75rem 1.4rem;
  border-radius: var(--radius-pill);
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-family: var(--font-display);
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.custom-tab:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.05);
}

.custom-tab.active {
  background: var(--accent-emerald);
  color: #032014;
  box-shadow: 0 4px 16px var(--accent-emerald-glow);
}

.tab-icon {
  display: flex;
  align-items: center;
}

.tab-pill-badge {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  padding: 0.18rem 0.55rem;
  border-radius: var(--radius-pill);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 700;
}

.badge-locked {
  background: rgba(244, 63, 94, 0.15);
  color: var(--status-danger);
  border: 1px solid rgba(244, 63, 94, 0.3);
}

.custom-tab.active .badge-locked {
  background: rgba(0, 0, 0, 0.25);
  color: #991b1b;
  border-color: rgba(0, 0, 0, 0.3);
}

.badge-available {
  background: rgba(16, 185, 129, 0.2);
  color: var(--accent-emerald-light);
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.custom-tab.active .badge-available {
  background: rgba(0, 0, 0, 0.25);
  color: #042e1d;
  border-color: rgba(0, 0, 0, 0.3);
}

/* Tab Panels */
.custom-panel {
  display: none;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.35s var(--ease-spring), transform 0.35s var(--ease-spring);
}

.custom-panel.active {
  display: block;
  opacity: 1;
  transform: translateY(0);
  animation: panelSlideUp 0.35s var(--ease-spring) forwards;
}

@keyframes panelSlideUp {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

.content-box {
  background: var(--bg-surface-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2.25rem;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
}

/* ═══════════════════════════════════════════════════════════════
   6. PART A: CASE STUDY DOSSIER & PROFILE CARDS
   ═══════════════════════════════════════════════════════════════ */
.cs-header-banner {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-subtle);
}

.cs-meta-tag {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent-emerald-light);
  letter-spacing: 0.08em;
  display: block;
  margin-bottom: 0.4rem;
}

.cs-title {
  font-family: var(--font-display);
  font-size: 2.25rem;
  font-weight: 900;
  letter-spacing: -0.03em;
  color: #ffffff;
  line-height: 1.15;
}

.cs-subtitle {
  font-size: 1.05rem;
  color: var(--accent-cyan-light);
  font-weight: 600;
  margin-top: 0.35rem;
  display: block;
}

.cs-block {
  margin-bottom: 2rem;
}

.cs-block-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff;
  margin-bottom: 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.cs-text-content {
  font-size: 0.98rem;
  line-height: 1.7;
  color: #cbd5e1;
}

/* Environmental Profile Diagnostic Deck */
.profile-deck-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.15rem;
  margin-top: 0.75rem;
}

@media (max-width: 900px) {
  .profile-deck-grid { grid-template-columns: 1fr; }
}

.profile-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-md);
  padding: 1.35rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  transition: all var(--transition-fast);
}

.profile-card:hover {
  transform: translateY(-3px);
  border-color: rgba(16, 185, 129, 0.4);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.35);
}

.profile-prop-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--accent-emerald-light);
  letter-spacing: 0.06em;
}

.profile-prop-body {
  font-size: 0.92rem;
  line-height: 1.6;
  color: var(--text-main);
}

/* Range of Conditions Stack */
.conditions-stack {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 0.75rem;
}

.condition-pill-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem 1.35rem;
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  transition: all var(--transition-fast);
}

.condition-pill-item:hover {
  border-color: var(--border-medium);
  background: var(--bg-surface-hover);
}

.condition-check-icon {
  color: var(--accent-emerald);
  flex-shrink: 0;
  margin-top: 0.15rem;
}

/* Challenge Callout Box */
.challenge-callout-box {
  display: flex;
  align-items: flex-start;
  gap: 1.25rem;
  padding: 1.5rem 1.75rem;
  border-radius: var(--radius-lg);
  background: rgba(14, 165, 233, 0.08);
  border: 1px solid rgba(14, 165, 233, 0.28);
  margin-top: 1rem;
}

.challenge-badge-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-xs);
  background: rgba(14, 165, 233, 0.2);
  color: var(--accent-cyan-light);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.challenge-title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 0.35rem;
}

.challenge-body {
  font-size: 0.95rem;
  line-height: 1.6;
  color: #e2e8f0;
}

/* Mandatory Evaluator Note */
.mandatory-note-box {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  border-radius: var(--radius-lg);
  background: var(--status-warning-dim);
  border: 1px solid rgba(245, 158, 11, 0.3);
  margin-top: 1.75rem;
  font-size: 0.92rem;
  line-height: 1.6;
  color: #fef3c7;
}

.mandatory-note-box strong {
  color: #fde68a;
}

/* ═══════════════════════════════════════════════════════════════
   7. UI RULES TAB & 9-STAGE EVALUATION GRID
   ═══════════════════════════════════════════════════════════════ */
.rules-dossier {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.dossier-header-banner {
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 1.5rem;
}

.dossier-tag {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--accent-emerald-light);
  letter-spacing: 0.08em;
  display: block;
  margin-bottom: 0.4rem;
}

.dossier-title-group h3 {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 900;
  color: #ffffff;
  letter-spacing: -0.03em;
}

.dossier-title-group p {
  font-size: 0.95rem;
  color: var(--text-muted);
  max-width: 650px;
  margin-top: 0.35rem;
}

.steps-nine-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.15rem;
}

@media (max-width: 1024px) {
  .steps-nine-grid { grid-template-columns: repeat(2, 1fr); }
}

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

.step-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: all var(--transition-fast);
}

.step-card:hover {
  transform: translateY(-3px);
  border-color: rgba(16, 185, 129, 0.35);
  background: var(--bg-surface-hover);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}

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

.step-pill {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--accent-emerald-light);
}

.step-tag-pill {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.18rem 0.55rem;
  border-radius: var(--radius-pill);
  background: var(--accent-emerald-subtle);
  color: var(--accent-emerald-light);
  border: 1px solid rgba(16, 185, 129, 0.25);
}

.step-card h4 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 800;
  color: #ffffff;
}

.step-card p {
  font-size: 0.88rem;
  line-height: 1.6;
  color: var(--text-muted);
}

.core-rules-container {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  border-top: 1px solid var(--border-subtle);
  padding-top: 1.75rem;
}

.rules-block-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 800;
  color: #ffffff;
}

.rules-block-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.15rem;
}

@media (max-width: 900px) {
  .rules-block-grid { grid-template-columns: 1fr; }
}

.rule-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.35rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  transition: all var(--transition-fast);
}

.rule-box:hover {
  transform: translateY(-2px);
  border-color: rgba(14, 165, 233, 0.35);
}

.rule-box h5 {
  font-family: var(--font-display);
  font-size: 0.98rem;
  font-weight: 800;
  color: #ffffff;
}

.rule-box p {
  font-size: 0.88rem;
  line-height: 1.6;
  color: var(--text-muted);
}

/* ═══════════════════════════════════════════════════════════════
   8. PART B: UNSEEN TESTING & GATED CONTENT
   ═══════════════════════════════════════════════════════════════ */
.state-empty-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3.5rem 2rem;
}

.empty-icon-ring {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-medium);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}

.state-empty-card h3 {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 0.45rem;
}

.state-empty-card p {
  font-size: 0.95rem;
  color: var(--text-muted);
  max-width: 480px;
}

.locked-placeholder {
  border-radius: var(--radius-xl);
  background: rgba(16, 24, 38, 0.5);
  border: 1px dashed var(--border-medium);
}

.shield-pulse-ring {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(244, 63, 94, 0.12);
  border: 1px solid rgba(244, 63, 94, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--status-danger);
  margin-bottom: 1.25rem;
}

.polling-indicator {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.45rem 1.15rem;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-dim);
  margin-top: 1.5rem;
}

.indicator-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-emerald);
  box-shadow: 0 0 6px var(--accent-emerald);
  animation: pulseDot 1.5s infinite;
}

/* Unseen Testing Card with Field Viewfinder */
.unseen-dossier-card {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.unseen-header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 1rem;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 1.5rem;
}

.unseen-title {
  font-family: var(--font-display);
  font-size: 1.85rem;
  font-weight: 900;
  color: #ffffff;
  letter-spacing: -0.02em;
}

.unseen-subtitle {
  font-size: 0.95rem;
  color: var(--accent-cyan-light);
  font-weight: 600;
  margin-top: 0.25rem;
}

.unseen-grid-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

@media (max-width: 900px) {
  .unseen-grid-layout { grid-template-columns: 1fr; }
}

.image-viewfinder {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-medium);
  background: #000000;
  cursor: zoom-in;
  max-height: 420px;
}

.scenario-inspect-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.image-viewfinder:hover .scenario-inspect-img {
  transform: scale(1.03);
}

.viewfinder-reticle {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(8, 12, 20, 0.4);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.image-viewfinder:hover .viewfinder-reticle {
  opacity: 1;
}

.viewfinder-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-pill);
  background: rgba(16, 24, 38, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
}

.unseen-text-pane {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.unseen-desc-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-md);
  padding: 1.4rem;
  font-size: 0.95rem;
  line-height: 1.7;
  color: #e2e8f0;
}

/* ═══════════════════════════════════════════════════════════════
   9. MODAL SYSTEM (CONFIRMATION, ADMIN CONSOLE, LIGHTBOX)
   ═══════════════════════════════════════════════════════════════ */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(6, 10, 16, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 1.5rem;
  animation: modalFadeIn 0.2s var(--ease-spring);
}

@keyframes modalFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes modalPopIn {
  from { opacity: 0; transform: scale(0.95) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-card {
  position: relative;
  z-index: 1001;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-xl);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.75);
  animation: modalPopIn 0.25s var(--ease-spring);
}

/* ═══════════════════════════════════════════════════════════════
   CONFIRMATION BOTTOM DOCK (Reference Mockup 1)
   ═══════════════════════════════════════════════════════════════ */
.confirm-bottom-dock {
  position: fixed;
  bottom: 24px;
  left: 24px;
  right: 24px;
  max-width: 1400px;
  margin: 0 auto;
  z-index: 1000;
  animation: slideUpDock 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

.confirm-bottom-dock.hidden {
  display: none !important;
}

@keyframes slideUpDock {
  from {
    transform: translateY(100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.confirm-dock-bar {
  position: relative;
  background: rgba(4, 18, 12, 0.95);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(16, 185, 129, 0.35);
  border-radius: 18px;
  padding: 1.25rem 2rem;
  box-shadow: 0 16px 50px rgba(0, 0, 0, 0.85), 0 0 35px rgba(16, 185, 129, 0.22);
  overflow: hidden;
}

/* Glowing top edge line matching mockups */
.confirm-dock-bar::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, #10b981 0%, #34d399 45%, #22d3ee 80%, rgba(16, 185, 129, 0.3) 100%);
}

.confirm-dock-icon {
  font-size: 1.25rem;
  line-height: 1;
  margin-bottom: 0.35rem;
}

.confirm-dock-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.01em;
  margin-bottom: 0.35rem;
}

.confirm-dock-message {
  font-size: 0.92rem;
  color: #94a3b8;
  line-height: 1.5;
  margin-bottom: 1.15rem;
}

.confirm-dock-actions {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.btn-dock-cancel {
  background: transparent;
  border: none;
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0.5rem 0.75rem;
  transition: opacity 0.2s ease;
}

.btn-dock-cancel:hover {
  opacity: 0.75;
  text-decoration: underline;
}

.btn-dock-lock {
  background: rgba(90, 225, 76, 0.89) !important;
  color: #031806 !important;
  border: none;
  border-radius: 9999px;
  padding: 0.75rem 2rem;
  font-size: 0.95rem;
  font-weight: 800;
  font-family: var(--font-display);
  cursor: pointer;
  box-shadow: 0 4px 18px rgba(90, 225, 76, 0.45) !important;
  transition: all 0.2s ease;
}

.btn-dock-lock:hover {
  transform: translateY(-2px);
  background: rgba(105, 245, 90, 0.96) !important;
  box-shadow: 0 8px 26px rgba(90, 225, 76, 0.65) !important;
  filter: brightness(1.08);
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSE RUBRIC STYLING (Bio-Cyber Emerald)
   ═══════════════════════════════════════════════════════════════ */
.cs-rubric-block {
  margin-top: 2rem;
}

.rubric-section-title {
  color: #34d399 !important;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 0.35rem;
  letter-spacing: -0.01em;
}

.rubric-section-sub {
  color: #94a3b8 !important;
  font-size: 0.88rem;
  margin-bottom: 1.25rem;
  line-height: 1.5;
}

.scenario-rubric-grid {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.rubric-step-row {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  background: rgba(6, 24, 16, 0.68);
  border: 1px solid rgba(16, 185, 129, 0.22);
  border-radius: 14px;
  padding: 1.1rem 1.4rem;
  transition: all 0.2s ease;
}

.rubric-step-row:hover {
  background: rgba(10, 36, 24, 0.82);
  border-color: rgba(16, 185, 129, 0.45);
  box-shadow: 0 4px 20px rgba(16, 185, 129, 0.15);
  transform: translateX(3px);
}

.rubric-step-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.45rem 1.15rem;
  border-radius: 9999px;
  border: 1px solid rgba(16, 185, 129, 0.5);
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
  flex-shrink: 0;
}

.rubric-step-content {
  color: #e2e8f0;
  font-size: 0.92rem;
  line-height: 1.55;
  flex: 1;
}

/* ═══════════════════════════════════════════════════════════════
   ORGANIZER ADMIN MODAL (Bio-Cyber Emerald)
   ═══════════════════════════════════════════════════════════════ */
.admin-modal-card {
  max-width: 1050px;
  width: 100%;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  padding: 2rem 2.25rem;
  overflow: hidden;
  background: rgba(4, 18, 12, 0.96);
  border: 1px solid rgba(16, 185, 129, 0.32);
  border-radius: 18px;
  position: relative;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.9), 0 0 35px rgba(16, 185, 129, 0.2);
}

.admin-modal-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, #10b981, #22d3ee 50%, #10b981);
}

.admin-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 1.15rem;
  margin-bottom: 1.5rem;
  flex-shrink: 0;
}

.admin-header-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: #ffffff;
}

.admin-header-title svg {
  stroke: #ffffff;
}

.admin-header-title h3 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.01em;
}

.modal-close {
  cursor: pointer;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-medium);
  color: var(--text-muted);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
}

.admin-auth-pane {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 480px;
  margin: 2.25rem auto;
  width: 100%;
}

.auth-hint {
  font-size: 0.92rem;
  color: var(--text-muted);
}

.admin-pill-input {
  border-radius: 9999px !important;
  background: rgba(4, 18, 10, 0.45) !important;
  backdrop-filter: blur(16px) !important;
  -webkit-backdrop-filter: blur(16px) !important;
  border: 1px solid rgba(90, 225, 76, 0.22) !important;
  color: #ffffff !important;
  padding: 0.85rem 1.4rem !important;
  font-size: 0.95rem !important;
  width: 100%;
  box-sizing: border-box;
  text-align: center;
}

.admin-pill-input:focus {
  border-color: rgba(90, 225, 76, 0.89) !important;
  box-shadow: 0 0 16px rgba(90, 225, 76, 0.45) !important;
  outline: none;
}

.btn-admin-unlock {
  margin-top: 1.25rem;
  width: 100%;
  border-radius: 9999px;
  padding: 0.85rem 1.5rem;
  background: rgba(90, 225, 76, 0.89) !important;
  color: #031806 !important;
  font-family: var(--font-display);
  font-size: 0.98rem;
  font-weight: 800;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(90, 225, 76, 0.45) !important;
  transition: all 0.2s ease;
}

.btn-admin-unlock:hover {
  transform: translateY(-2px);
  background: rgba(105, 245, 90, 0.96) !important;
  box-shadow: 0 8px 28px rgba(90, 225, 76, 0.65) !important;
  filter: brightness(1.08);
}

.input-group {
  width: 100%;
}

.error-text {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--status-danger);
  margin-top: 0.75rem;
}

.admin-dashboard-pane {
  display: flex;
  flex-direction: column;
  flex: 1;
  overflow-y: auto;
  padding-right: 0.5rem;
}

.admin-tab-bar {
  display: flex;
  gap: 0.5rem;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 0.85rem;
  margin-bottom: 1.35rem;
  flex-wrap: wrap;
  flex-shrink: 0;
}

.admin-tab {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  padding: 0.5rem 1.15rem;
  border-radius: var(--radius-pill);
  cursor: pointer;
  font-family: var(--font-display);
  font-size: 0.84rem;
  font-weight: 700;
  transition: all var(--transition-fast);
}

.admin-tab:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.admin-tab.active {
  background: var(--accent-emerald);
  color: #032014;
  border-color: transparent;
  box-shadow: 0 4px 14px var(--accent-emerald-glow);
}

.admin-panel {
  display: none;
}

.admin-panel.active {
  display: block;
}

.admin-toolbar-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.admin-section-heading {
  font-family: var(--font-display);
  font-size: 1.12rem;
  font-weight: 800;
  color: #ffffff;
  display: block;
}

.admin-section-sub {
  font-size: 0.82rem;
  color: var(--text-dim);
  margin-top: 0.2rem;
}

.bulk-btn-group {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.btn-accent {
  background: var(--accent-emerald);
  color: #032014;
  border: none;
  font-weight: 700;
}

.btn-accent:hover {
  background: var(--accent-emerald-light);
}

.admin-table-container {
  overflow-x: auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
}

.admin-table th {
  text-align: left;
  padding: 0.85rem 1rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-dim);
  text-transform: uppercase;
  border-bottom: 1px solid var(--border-subtle);
}

.admin-table td {
  padding: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  font-size: 0.9rem;
}

.team-id-badge {
  font-family: var(--font-mono);
  font-weight: 700;
  color: #ffffff;
}

.scenario-pill {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-pill);
  background: var(--accent-emerald-subtle);
  color: var(--accent-emerald-light);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.scenario-pill.unassigned {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-dim);
  border-color: var(--border-subtle);
}

/* Switch Control */
.switch-control {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  cursor: pointer;
}

.switch-control input {
  display: none;
}

.switch-slider {
  width: 40px;
  height: 22px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.15);
  position: relative;
  transition: background var(--transition-fast);
}

.switch-slider::before {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #ffffff;
  transition: transform var(--transition-fast);
}

.switch-control input:checked + .switch-slider {
  background: var(--accent-emerald);
}

.switch-control input:checked + .switch-slider::before {
  transform: translateX(18px);
}

.switch-label-text {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
}

.switch-label-text.unlocked { color: var(--accent-emerald-light); }
.switch-label-text.locked { color: var(--status-danger); }

/* Quota Cells */
.admin-quota-deck {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1rem;
  margin-top: 1.15rem;
}

@media (max-width: 900px) {
  .admin-quota-deck { grid-template-columns: repeat(2, 1fr); }
}

.admin-quota-cell {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  text-align: center;
}

.admin-quota-num {
  font-family: var(--font-display);
  font-size: 1.85rem;
  font-weight: 900;
  color: var(--accent-emerald);
}

.admin-quota-num.full {
  color: var(--status-danger);
}

/* Whitelist Manager */
.whitelist-mgr {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.admin-textarea {
  width: 100%;
  background: var(--bg-surface);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-md);
  padding: 0.95rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: #ffffff;
  resize: vertical;
}

.admin-textarea:focus {
  outline: none;
  border-color: var(--accent-emerald);
}

.whitelist-action-row {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.save-indicator {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent-emerald-light);
}

.danger-zone-box {
  background: var(--status-danger-dim);
  border: 1px solid rgba(244, 63, 94, 0.35);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.danger-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--status-danger);
}

.whitelist-toggle-box {
  display: flex;
  align-items: center;
}

.switch-label {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-main);
  cursor: pointer;
}

.switch-label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--accent-emerald);
  cursor: pointer;
}

/* Image Lightbox Dialog */
.lightbox-container {
  max-width: 1050px;
  width: 100%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-xl);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.85);
  overflow: hidden;
  animation: modalPopIn 0.25s var(--ease-spring);
}

.lightbox-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.5rem;
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
}

.lightbox-caption {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: #ffffff;
}

.lightbox-img-wrapper {
  overflow: auto;
  padding: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000000;
  max-height: 75vh;
}

.lightbox-img-wrapper img {
  max-width: 100%;
  max-height: 70vh;
  object-fit: contain;
  border-radius: var(--radius-md);
}

/* ═══════════════════════════════════════════════════════════════
   10. BUTTON UTILITIES & GENERAL COMPONENTS
   ═══════════════════════════════════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  font-family: var(--font-display);
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  border: none;
  border-radius: var(--radius-pill);
  padding: 0.75rem 1.6rem;
  transition: all var(--transition-fast);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-emerald) 0%, var(--accent-emerald-dark) 100%);
  color: #ffffff;
  box-shadow: 0 4px 16px var(--accent-emerald-glow);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(16, 185, 129, 0.35);
  filter: brightness(1.06);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-medium);
  color: #ffffff;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

.btn-ghost {
  background: transparent;
  border: 1px solid var(--border-medium);
  color: var(--text-main);
}

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

.btn-danger {
  background: var(--status-danger);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(244, 63, 94, 0.25);
}

.btn-danger:hover {
  filter: brightness(1.1);
  transform: translateY(-2px);
}

.btn-sm {
  padding: 0.45rem 1rem;
  font-size: 0.82rem;
}

.btn-tiny {
  padding: 0.28rem 0.7rem;
  font-size: 0.72rem;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-medium);
  color: var(--text-main);
  cursor: pointer;
  transition: all var(--transition-fast);
}

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

.btn-icon {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.45rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

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

.btn-glow {
  box-shadow: 0 4px 18px var(--accent-emerald-glow);
}

.btn-glow:hover {
  box-shadow: 0 8px 25px rgba(16, 185, 129, 0.35);
}

.hidden {
  display: none !important;
}

@media (max-width: 768px) {
  .top-nav {
    margin: 0.75rem 0.75rem 0;
    padding: 0.65rem 1rem;
    flex-wrap: wrap;
    gap: 0.65rem;
    border-radius: var(--radius-lg);
  }
  .nav-center { order: 3; width: 100%; justify-content: center; }
  .main-container { padding: 1.5rem 1rem 4rem; }
  .content-box { padding: 1.5rem; }
  .brand-title { font-size: 2.2rem; }
}

.admin-quick-btn {
  /* Inherits from .nav-btn */
}

.dashboard-ground-rule {
  /* Inherits from .ground-rule-banner */
}

.tab-gated.locked {
  opacity: 0.8;
}

.panels-deck {
  width: 100%;
}

.rule-icon {
  font-size: 1.4rem;
  display: inline-block;
}

/* ═══════════════════════════════════════════════════════════════
   11. PROFESSIONAL FLOATING TOAST SYSTEM
   ═══════════════════════════════════════════════════════════════ */
.toast-container {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  pointer-events: none;
}

.toast-item {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-pill);
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-medium);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
  font-family: var(--font-body);
  font-size: 0.88rem;
  font-weight: 600;
  color: #ffffff;
  pointer-events: auto;
  animation: toastSlideUp 0.25s var(--ease-spring);
}

.toast-error {
  border-color: rgba(244, 63, 94, 0.45);
  background: rgba(30, 10, 16, 0.95);
  color: #fecdd3;
}

.toast-success {
  border-color: rgba(16, 185, 129, 0.45);
  background: rgba(10, 26, 20, 0.95);
  color: #a7f3d0;
}

.toast-info {
  border-color: rgba(14, 165, 233, 0.45);
  background: rgba(8, 22, 38, 0.95);
  color: #bae6fd;
}

.toast-fade-out {
  opacity: 0;
  transform: translateY(8px);
  transition: all 0.3s ease;
}

@keyframes toastSlideUp {
  from { opacity: 0; transform: translateY(12px) scale(0.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* ── Bottom Blur Overlay (CSS mask + backdrop-filter) ── */
.bottom-blur-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  -webkit-backdrop-filter: blur(24px);
  backdrop-filter: blur(24px);
  -webkit-mask-image: linear-gradient(to top, black 0%, transparent 45%);
  mask-image: linear-gradient(to top, black 0%, transparent 45%);
}

/* ═══════════════════════════════════════════════════════════════
   CINEMATIC COLOR HARMONIZATION
   1. Login Page: Lush Bio-Emerald / Jade (#5ae14c) matches video-dashboard.mp4
   2. Dashboard Page: Sunset Solar Amber (#f59e0b) & Terracotta (#e07a5f) matches hero-cinematic.mp4
   ═══════════════════════════════════════════════════════════════ */

body.page-dashboard,
#selection-screen {
  --bg-void: #0b0706;
  --bg-deep: rgba(22, 12, 10, 0.52);
  --bg-surface: rgba(30, 16, 14, 0.42);
  --bg-surface-elevated: rgba(45, 24, 20, 0.52);
  --bg-surface-card: rgba(32, 18, 16, 0.42);
  --bg-surface-hover: rgba(55, 30, 25, 0.65);
  --bg-glass: rgba(245, 158, 11, 0.05);

  --accent-primary: #f59e0b;
  --accent-primary-hex: #f59e0b;
  --accent-primary-light: #fbbf24;
  --accent-primary-dark: #d97706;
  --accent-primary-glow: rgba(245, 158, 11, 0.45);
  --accent-primary-subtle: rgba(245, 158, 11, 0.15);

  --accent-emerald: #f59e0b;
  --accent-emerald-light: #fbbf24;
  --accent-emerald-dark: #d97706;
  --accent-emerald-glow: rgba(245, 158, 11, 0.45);
  --accent-emerald-subtle: rgba(245, 158, 11, 0.15);

  --accent-coral: #db7566;
  --accent-terracotta: #e07a5f;
  --accent-cyan: #f97316;
  --accent-cyan-light: #fb923c;
  --accent-teal: #f59e0b;

  --neon-magenta: #f97316;
  --neon-pink: #db7566;
  --neon-violet: #e07a5f;
  --neon-purple: #c2410c;
  --neon-cyan: #f59e0b;
  --neon-emerald: #f59e0b;

  --glow-magenta: rgba(249, 115, 22, 0.42);
  --glow-magenta-soft: rgba(249, 115, 22, 0.18);
  --glow-violet: rgba(219, 117, 102, 0.28);
  --glow-pink: rgba(224, 122, 95, 0.28);

  --border-subtle: rgba(219, 117, 102, 0.22);
  --border-medium: rgba(245, 158, 11, 0.32);
  --border-accent: rgba(249, 115, 22, 0.65);
  --border-glass: rgba(255, 255, 255, 0.12);
  --border-glass-bright: rgba(245, 158, 11, 0.75);

  --status-success: #f59e0b;
  --status-success-dim: rgba(245, 158, 11, 0.18);
}

/* Dashboard Top Navigation & Status */
body.page-dashboard .top-nav {
  background: rgba(18, 10, 8, 0.75);
  border-bottom: 1px solid rgba(219, 117, 102, 0.25);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4), 0 0 40px rgba(245, 158, 11, 0.08);
}

body.page-dashboard .nav-brand {
  background: linear-gradient(135deg, #ffffff 20%, #f59e0b 60%, #db7566 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

body.page-dashboard .nav-status-chip {
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.35);
  color: #fbbf24;
}

body.page-dashboard .live-pulse {
  background: #f59e0b;
  box-shadow: 0 0 10px #f59e0b;
}

body.page-dashboard .scenario-chip.claimed {
  background: rgba(249, 115, 22, 0.15);
  border-color: rgba(249, 115, 22, 0.5);
  color: #f59e0b;
}

/* Scenario Selector Buttons on Dashboard */
body.page-dashboard .num-btn.active {
  border-color: #f59e0b;
  background: rgba(245, 158, 11, 0.22);
  box-shadow: 0 0 25px rgba(245, 158, 11, 0.45);
}

body.page-dashboard .num-btn:hover:not(:disabled) {
  border-color: rgba(245, 158, 11, 0.55);
  background: rgba(245, 158, 11, 0.14);
}

body.page-dashboard .nav-tab-btn.active {
  color: #fbbf24;
  border-bottom-color: #f59e0b;
}

/* Ground Rule Banner with Terracotta / Amber Warmth */
body.page-dashboard .ground-rule-card {
  border-left: 4px solid #f59e0b;
  background: rgba(35, 18, 15, 0.65);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.35), 0 0 25px rgba(245, 158, 11, 0.08);
}

body.page-dashboard .ground-rule-icon {
  background: rgba(245, 158, 11, 0.18);
  color: #f59e0b;
}

/* Bottom HUD Dock Lock-in Button */
body.page-dashboard .confirm-lock-btn {
  background: linear-gradient(135deg, #f97316 0%, #db7566 100%);
  border-color: rgba(251, 191, 36, 0.6);
  box-shadow: 0 0 24px rgba(249, 115, 22, 0.5);
}

body.page-dashboard .confirm-lock-btn:hover {
  background: linear-gradient(135deg, #ea580c 0%, #c55748 100%);
  box-shadow: 0 0 32px rgba(249, 115, 22, 0.7);
}

/* Roster Quick View Pill Enhancements */
.team-pill {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 8px 12px;
  background: rgba(10, 28, 18, 0.6);
  border: 1px solid rgba(90, 225, 76, 0.22);
  border-radius: var(--radius-sm);
  color: #e2e8f0;
  cursor: pointer;
  transition: all 0.2s var(--ease-spring);
  font-family: var(--font-body);
  text-align: left;
}

.team-pill:hover {
  background: rgba(90, 225, 76, 0.2);
  border-color: rgba(90, 225, 76, 0.55);
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(90, 225, 76, 0.25);
}

.pill-team-name {
  font-weight: 700;
  font-size: 0.88rem;
  color: #ffffff;
  letter-spacing: -0.01em;
}

.pill-lead-tag {
  font-size: 0.74rem;
  color: #a7f3d0;
  font-family: var(--font-mono);
  margin-top: 3px;
}

.item-lead-sub {
  font-size: 0.74rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  margin-top: 2px;
}

/* ── Download Image Button ──────────────────────── */
.download-img-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: rgba(90, 225, 76, 0.12);
  border: 1px solid rgba(90, 225, 76, 0.35);
  border-radius: 8px;
  color: #7cf56e;
  font-size: 0.78rem;
  font-weight: 600;
  font-family: var(--font-mono, 'JetBrains Mono', monospace);
  cursor: pointer;
  transition: all 0.22s ease;
  white-space: nowrap;
}

.download-img-btn:hover {
  background: rgba(90, 225, 76, 0.25);
  border-color: rgba(90, 225, 76, 0.7);
  box-shadow: 0 0 16px rgba(90, 225, 76, 0.3);
  transform: translateY(-1px);
  color: #ffffff;
}

.download-img-btn:active {
  transform: translateY(0);
  background: rgba(90, 225, 76, 0.35);
}

.download-img-btn svg {
  flex-shrink: 0;
}

/* ── Case Study & Rules Sealed Gate Styles ──────────────── */
.awaiting-card {
  padding: 3rem 2rem;
  text-align: center;
  max-width: 760px;
  margin: 0 auto;
}

.claim-lock-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 9999px;
  font-family: var(--font-mono, monospace);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #fbbf24;
  margin-top: 1rem;
}

.claim-progress-box {
  width: 100%;
  max-width: 520px;
  margin: 1.5rem auto 0;
  background: rgba(5, 20, 14, 0.85);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: 12px;
  padding: 1rem 1.25rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.claim-progress-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono, monospace);
  font-size: 0.74rem;
  letter-spacing: 0.05em;
  color: var(--text-dim, #94a3b8);
  margin-bottom: 0.65rem;
}

.claim-progress-stat {
  color: #34d399;
  font-weight: 700;
}

.claim-progress-track {
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 9999px;
  overflow: hidden;
  position: relative;
}

.claim-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #10b981, #06b6d4);
  border-radius: 9999px;
  transition: width 0.4s ease;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.5);
}

.tab-pill-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 7px;
  border-radius: 9999px;
  font-family: var(--font-mono, monospace);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  margin-left: 6px;
  line-height: 1;
}

.tab-pill-badge.badge-locked {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #f87171;
}

.tab-pill-badge.badge-available {
  background: rgba(16, 185, 129, 0.18);
  border: 1px solid rgba(16, 185, 129, 0.5);
  color: #34d399;
}
