/* ============================================================================
 * GamePanel V3 HUD Pack — Direction γ : Tower Vanguard
 *
 * Refs : Destiny 2 character menu, Star Citizen menus, Mass Effect Andromeda
 * Palette : crème os + bleu acier + or muted sur noir profond
 *
 * Activé par : body.ui-v3.theme-direction-vanguard
 * ============================================================================ */

/* ===== TOKENS DIRECTION VANGUARD ===== */
body.ui-v3.theme-direction-vanguard {
  --primary:        #4a9eff;
  --primary-dim:    rgba(74, 158, 255, 0.30);
  --primary-bg:     rgba(74, 158, 255, 0.10);
  --primary-glow:   rgba(74, 158, 255, 0.40);

  --secondary:      #c89a3a;
  --secondary-dim:  rgba(200, 154, 58, 0.35);
  --secondary-bg:   rgba(200, 154, 58, 0.10);
  --secondary-glow: rgba(200, 154, 58, 0.40);

  --accent-alert:   #d23a3a;
  --accent-alert-bg: rgba(210, 58, 58, 0.10);

  /* Backgrounds noir profond luxe */
  --bg-0: #0a0c14;
  --bg-1: #11151f;
  --bg-2: #171c29;
  --bg-3: #1d2333;

  --border:        rgba(200, 154, 58, 0.18);
  --border-strong: rgba(200, 154, 58, 0.35);
  --border-subtle: rgba(200, 154, 58, 0.07);

  --text-0: #f5f0e8;
  --text-1: #9ba3b4;
  --text-2: #5a647a;
  --text-3: #38404e;

  --btn-text: #f5f0e8;

  /* Fonts sobres DIN-like */
  --font-hud: 'Inter', system-ui, sans-serif;

  /* Nav */
  --nav-hover-bg:  rgba(200, 154, 58, 0.06);
  --nav-active-bg: rgba(74, 158, 255, 0.10);

  --sidebar-bg: #0d1019;

  --hero-bg: linear-gradient(135deg, #0e1220 0%, #111826 100%);
  --login-glow-a: rgba(74, 158, 255, 0.10);
  --login-glow-b: rgba(200, 154, 58, 0.08);
}

/* ============================================================================
   COMPOSANTS SIGNATURE VANGUARD
   ============================================================================ */

/* ---- Typo : Inter sobre et premium ---- */
body.ui-v3.theme-direction-vanguard .section-title,
body.ui-v3.theme-direction-vanguard .page-title,
body.ui-v3.theme-direction-vanguard .modal-title {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: none; /* Pas de CAPS ici — on reste sobre */
}

body.ui-v3.theme-direction-vanguard .sidebar-logo-text {
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 700;
  letter-spacing: 0.08em;
}

/* ---- Grandes surfaces avec radial + linear mix ---- */
body.ui-v3.theme-direction-vanguard .server-card {
  background:
    radial-gradient(ellipse 80% 50% at 0% 0%, rgba(74, 158, 255, 0.03) 0%, transparent 60%),
    var(--bg-1);
  border-color: rgba(200, 154, 58, 0.15);
  border-radius: 8px;
  transition: transform 400ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
              border-color 400ms ease,
              box-shadow 400ms ease;
}

body.ui-v3.theme-direction-vanguard .server-card.online {
  border-color: rgba(200, 154, 58, 0.35);
}

/* ---- Hover lift Y -4px + glow doré ---- */
body.ui-v3.theme-direction-vanguard .server-card:hover {
  transform: translateY(-4px);
  border-color: var(--secondary-dim);
  box-shadow: 0 12px 36px rgba(200, 154, 58, 0.12), 0 4px 12px rgba(0,0,0,0.4);
}

/* ---- Séparateurs fins or ---- */
body.ui-v3.theme-direction-vanguard .sidebar-section {
  border-bottom: 1px solid rgba(200, 154, 58, 0.10);
}

body.ui-v3.theme-direction-vanguard .sidebar-section:last-of-type {
  border-bottom: none;
}

/* ---- Section label : or muted ---- */
body.ui-v3.theme-direction-vanguard .sidebar-section-label {
  color: rgba(200, 154, 58, 0.55);
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 10px;
  letter-spacing: 0.14em;
}

/* ---- Nav item actif : bleu acier ---- */
body.ui-v3.theme-direction-vanguard .nav-item.active {
  color: var(--primary);
  background: rgba(74, 158, 255, 0.08);
  border-left-color: var(--primary);
}

/* ---- Hover nav : or subtle ---- */
body.ui-v3.theme-direction-vanguard .nav-item:hover {
  color: var(--text-0);
  background: rgba(200, 154, 58, 0.05);
  border-left-color: rgba(200, 154, 58, 0.3);
}

/* ---- Sidebar logo : crème + or ---- */
body.ui-v3.theme-direction-vanguard .sidebar-logo-text {
  color: var(--text-0);
}

body.ui-v3.theme-direction-vanguard .sidebar-logo-text span {
  color: var(--secondary);
}

/* ---- Sidebar logo mark : bleu acier ---- */
body.ui-v3.theme-direction-vanguard .sidebar-logo-mark {
  color: var(--primary);
  filter: drop-shadow(0 0 6px rgba(74, 158, 255, 0.35));
}

/* ---- Topbar : sobre + séparateur or ---- */
body.ui-v3.theme-direction-vanguard #topbar {
  background: var(--bg-1);
  border-bottom: 1px solid rgba(200, 154, 58, 0.12);
}

body.ui-v3.theme-direction-vanguard #topbar::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(200, 154, 58, 0.2), transparent);
}

body.ui-v3.theme-direction-vanguard #topbar {
  position: relative;
}

/* ---- Bouton primaire : cyan acier Vanguard fixe ---- */
/* Note : on hardcode #4a9eff plutôt que var(--primary) car vg-ambient-dark
 * (actif la nuit) écrase --primary en #7b6fcf (violet). Le btn-primary
 * doit toujours afficher le cyan signature Vanguard, indépendamment de
 * l'ambiance. */
body.ui-v3.theme-direction-vanguard .btn-primary {
  background: #4a9eff;
  color: #f5f0e8;
  border-radius: 6px;
  border-color: #4a9eff;
  overflow: hidden;
}

body.ui-v3.theme-direction-vanguard .btn-primary::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(200, 154, 58, 0.25) 40%,
    rgba(255, 220, 120, 0.15) 60%,
    transparent 100%
  );
  transform: translateX(-100%);
  transition: transform 700ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
  pointer-events: none;
  border-radius: 0;
}

body.ui-v3.theme-direction-vanguard .btn-primary:hover::after {
  transform: translateX(100%);
}

body.ui-v3.theme-direction-vanguard .btn-primary:hover {
  opacity: 1;
  background: #3a8ae0;
  border-color: #3a8ae0;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(74, 158, 255, 0.35), 0 2px 8px rgba(74, 158, 255, 0.15);
}

/* ---- Status badge : sobre + or ---- */
body.ui-v3.theme-direction-vanguard .status-badge {
  border-radius: 4px;
}

body.ui-v3.theme-direction-vanguard .status-badge.online {
  border: 1px solid rgba(16, 201, 124, 0.25);
}

/* ---- Hero banner : radial glow bleu ---- */
body.ui-v3.theme-direction-vanguard #dashboard-hero {
  background:
    radial-gradient(ellipse 60% 80% at 20% 50%, rgba(74, 158, 255, 0.05) 0%, transparent 60%),
    radial-gradient(ellipse 40% 60% at 80% 50%, rgba(200, 154, 58, 0.04) 0%, transparent 50%),
    var(--bg-1);
  border: 1px solid rgba(200, 154, 58, 0.15);
  border-radius: 8px;
}

body.ui-v3.theme-direction-vanguard #dashboard-hero::before {
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  opacity: 0.7;
}

/* ---- Hero title : couleur crème riche ---- */
body.ui-v3.theme-direction-vanguard .hero-title {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  color: var(--text-0);
  letter-spacing: 0.02em;
  text-transform: none;
}

/* ---- Page title : gradient cyan → or (Traveler + Vanguard crest) ---- */
body.ui-v3.theme-direction-vanguard .page-title {
  background: linear-gradient(135deg, var(--secondary) 0%, var(--primary) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  font-size: 22px;
  text-shadow: none;
}

/* ---- Hero title (SAISON · ... · ÉTAT DE LA FLOTTE) : accent cyan ---- */
body.ui-v3.theme-direction-vanguard .v2-hero-title {
  color: var(--secondary);
  text-shadow: 0 0 12px rgba(108, 240, 255, 0.35);
}

/* ---- Modales : premium + largeur étendue ---- */
body.ui-v3.theme-direction-vanguard .modal-box {
  border-color: rgba(200, 154, 58, 0.25);
  border-radius: 10px;
}

body.ui-v3.theme-direction-vanguard .modal-box::before {
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  opacity: 0.8;
}

body.ui-v3.theme-direction-vanguard .modal-title {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  color: var(--text-0);
  text-transform: none;
  letter-spacing: 0.02em;
}

/* ---- Login card : premium + glow radial ---- */
body.ui-v3.theme-direction-vanguard .login-card {
  border-color: rgba(200, 154, 58, 0.20);
  border-radius: 10px;
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(74, 158, 255, 0.04) 0%, transparent 50%),
    var(--bg-1);
}

body.ui-v3.theme-direction-vanguard .login-card::before {
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  opacity: 0.8;
}

body.ui-v3.theme-direction-vanguard .login-logo-title {
  font-family: 'Inter', sans-serif;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-0);
}

body.ui-v3.theme-direction-vanguard .login-logo-title span {
  color: var(--secondary);
}

/* ---- Logo mark : bleu acier ---- */
body.ui-v3.theme-direction-vanguard .login-logo-mark {
  color: var(--primary);
  filter: drop-shadow(0 0 14px rgba(74, 158, 255, 0.45));
}

/* ---- Btn login : gradient bleu → or ---- */
body.ui-v3.theme-direction-vanguard .btn-login {
  background: linear-gradient(90deg, var(--primary) 0%, #3a8ae0 100%);
  color: #f5f0e8;
  overflow: hidden;
}

body.ui-v3.theme-direction-vanguard .btn-login::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(200, 154, 58, 0.2), transparent);
  transform: translateX(-100%);
  transition: transform 700ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
  pointer-events: none;
}

body.ui-v3.theme-direction-vanguard .btn-login:hover::after {
  transform: translateX(100%);
}

/* ---- System stats : or ---- */
body.ui-v3.theme-direction-vanguard .sys-stat-item strong {
  color: var(--secondary);
}

/* ---- Table : séparateurs or ---- */
body.ui-v3.theme-direction-vanguard th {
  color: rgba(200, 154, 58, 0.6);
  border-bottom-color: rgba(200, 154, 58, 0.15);
}

body.ui-v3.theme-direction-vanguard td {
  border-bottom-color: rgba(200, 154, 58, 0.07);
}

body.ui-v3.theme-direction-vanguard tr:hover td {
  background: rgba(74, 158, 255, 0.04);
}

/* ---- Scrollbar or ---- */
body.ui-v3.theme-direction-vanguard ::-webkit-scrollbar-thumb {
  background: rgba(200, 154, 58, 0.20);
}

body.ui-v3.theme-direction-vanguard ::-webkit-scrollbar-thumb:hover {
  background: rgba(200, 154, 58, 0.40);
}

/* ---- Formulaire : bleu au focus ---- */
body.ui-v3.theme-direction-vanguard .form-input:focus,
body.ui-v3.theme-direction-vanguard input:focus,
body.ui-v3.theme-direction-vanguard select:focus,
body.ui-v3.theme-direction-vanguard textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(74, 158, 255, 0.15);
}

/* ---- Card offline hover : lift réduit ---- */
body.ui-v3.theme-direction-vanguard .offline-mini-tile:hover {
  transform: translateY(-2px);
  border-color: rgba(200, 154, 58, 0.25);
  transition: transform 400ms cubic-bezier(0.25, 0.46, 0.45, 0.94), border-color 400ms ease;
}

/* ---- Badge primary : or ---- */
body.ui-v3.theme-direction-vanguard .badge-primary {
  background: rgba(200, 154, 58, 0.12);
  color: var(--secondary);
  border-color: rgba(200, 154, 58, 0.30);
}

/* ---- Section header separateur or ---- */
body.ui-v3.theme-direction-vanguard .section-header {
  border-bottom-color: rgba(200, 154, 58, 0.15);
}
