/* 🎮 BACKLOG RADAR • OBSIDIAN BENTO & AURORA GLASS DESIGN SYSTEM (2026) */

/* --- 1. INVARIANT & FUNCTIONAL TOKENS --- */
:root {
  --status-success: #10B981;
  --status-success-bg: rgba(16, 185, 129, 0.14);
  --status-success-border: rgba(16, 185, 129, 0.35);

  --status-alert: #EF4444;
  --status-alert-bg: rgba(239, 68, 68, 0.14);
  --status-alert-border: rgba(239, 68, 68, 0.35);

  --status-warning: #F59E0B;
  --status-warning-bg: rgba(245, 158, 11, 0.14);
  --status-warning-border: rgba(245, 158, 11, 0.35);

  --status-neutral: #64748B;
  --status-neutral-bg: rgba(100, 116, 139, 0.14);
  --status-neutral-border: rgba(100, 116, 139, 0.3);

  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-card: rgba(255, 255, 255, 0.09);
  --header-height: 60px;

  /* Default Obsidian Bento & Aurora Glass Tokens */
  --bg-app: #06070A;
  --bg-card: #0C0F17;
  --bg-surface: #06070A;
  --bg-surface-glass: rgba(13, 17, 26, 0.78);
  --bg-surface-elevated: rgba(20, 26, 40, 0.88);
  --bg-surface-subtle: rgba(255, 255, 255, 0.035);
  --card-border: rgba(255, 255, 255, 0.085);
  --card-hover-border: rgba(16, 185, 129, 0.55);
  --accent-primary: #10B981;
  --accent-primary-rgb: 16, 185, 129;
  --accent-rgb: 16, 185, 129;
  --accent-secondary: #06B6D4;
  --accent-tertiary: #8B5CF6;
  --accent-glow: rgba(16, 185, 129, 0.22);
  --radius-card: 20px;
  --radius-badge: 10px;
  --status-bar-bg: rgba(10, 13, 20, 0.88);
  --status-bar-border: rgba(16, 185, 129, 0.28);
  --chip-active: #10B981;
  --btn-active: linear-gradient(135deg, #10B981 0%, #06B6D4 100%);
  --text-accent: #34D399;
  --hero-badge-bg: linear-gradient(135deg, #10B981, #06B6D4);
  --font-display: 'Space Grotesk', 'Inter', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

@media (min-width: 640px) {
  :root {
    --header-height: 64px;
  }
}

/* --- 2. THÈMES --- */
/* Les jetons des 3 thèmes (Aurora Prism, Radar HUD, Spatial Glass) sont dans themes.css,
   chargé après ce fichier. Les valeurs de :root ci-dessus servent de repli. */

/* --- 3. BASE & TYPOGRAPHY --- */
html {
  scroll-behavior: smooth;
}

body {
  max-width: 100vw;
  width: 100%;
  position: relative;
  font-family: var(--font-body);
  color: #F8FAFC;
  background-color: var(--bg-app, #06070A);
  min-height: 100vh;
  letter-spacing: -0.011em;
}

h1, h2, h3, .font-display, .app-logo {
  font-family: var(--font-display);
  letter-spacing: -0.025em;
}

* {
  box-sizing: border-box;
}

.font-mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

/* --- 4. AURORA GLASS MESH & VIGNETTE SYSTEM --- */
#bg-wallpaper {
  position: fixed;
  inset: -24px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  transition: opacity 0.6s ease;
  z-index: -20;
  filter: blur(26px) brightness(0.32) saturate(1.35);
  transform: translateZ(0);
  will-change: opacity;
}

#bg-overlay {
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 14% 8%, rgba(var(--accent-primary-rgb), 0.14) 0%, transparent 38%),
    radial-gradient(circle at 86% 12%, rgba(139, 92, 246, 0.12) 0%, transparent 40%),
    radial-gradient(circle at 50% 92%, rgba(6, 182, 212, 0.09) 0%, transparent 45%),
    radial-gradient(circle at 50% 20%, rgba(6, 7, 10, 0.78) 0%, rgba(6, 7, 10, 0.95) 85%);
  z-index: -10;
  pointer-events: none;
}

/* --- 5. OBSIDIAN BENTO CARDS & SPECULAR 1PX GLASS SURFACES --- */
.glass-card {
  background: var(--bg-surface-glass);
  backdrop-filter: blur(22px) saturate(175%);
  -webkit-backdrop-filter: blur(22px) saturate(175%);
  border: 1px solid var(--card-border);
  border-radius: var(--radius-card);
  box-shadow:
    inset 0 1px 0 0 rgba(255, 255, 255, 0.13),
    0 12px 32px -8px rgba(0, 0, 0, 0.68);
  transition: transform 220ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 220ms cubic-bezier(0.16, 1, 0.3, 1), border-color 220ms ease;
}

/* Guarantee modal width constraints are never overridden when paired with .w-full */
.glass-card.max-w-sm { max-width: 24rem !important; }
.glass-card.max-w-md { max-width: 28rem !important; }
.glass-card.max-w-lg { max-width: 32rem !important; }
.glass-card.max-w-xl { max-width: 36rem !important; }
.glass-card.max-w-2xl { max-width: 42rem !important; }
.glass-card.max-w-3xl { max-width: 48rem !important; }
.glass-card.max-w-4xl { max-width: 56rem !important; }

.glass-card:hover {
  border-color: var(--card-hover-border);
  box-shadow:
    inset 0 1px 0 0 rgba(255, 255, 255, 0.22),
    0 16px 38px -8px rgba(0, 0, 0, 0.78),
    0 0 22px -2px var(--accent-glow);
  transform: translateY(-2px);
}

.bento-kpi-card {
  position: relative;
  overflow: hidden;
  background: linear-gradient(165deg, rgba(22, 28, 44, 0.78) 0%, rgba(10, 13, 21, 0.88) 100%);
}

.bento-kpi-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 12%;
  right: 12%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.28), transparent);
  pointer-events: none;
}

/* --- 6. GAME POSTER CARD (2:3 COLLECTOR RATIO + SPECULAR GLASS) --- */
.game-poster-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-card);
  background: linear-gradient(170deg, rgba(18, 23, 36, 0.86) 0%, rgba(9, 12, 19, 0.94) 100%);
  border: 1px solid var(--card-border);
  box-shadow:
    inset 0 1px 0 0 rgba(255, 255, 255, 0.12),
    0 10px 26px -6px rgba(0, 0, 0, 0.65);
  contain: layout style paint;
  transform: translateZ(0);
  transition: transform 240ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 240ms cubic-bezier(0.16, 1, 0.3, 1), border-color 240ms ease;
}

.game-poster-card:hover {
  transform: translateY(-5px) scale(1.008);
  border-color: var(--card-hover-border);
  box-shadow:
    inset 0 1px 0 0 rgba(255, 255, 255, 0.25),
    0 20px 42px -10px rgba(0, 0, 0, 0.85),
    0 0 26px -4px var(--accent-glow);
}

.game-poster-img {
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.game-poster-card:hover .game-poster-img {
  transform: scale(1.05);
}

/* Card Bottom Controls (Permanently Visible) */
.card-resting-meta {
  transition: opacity 200ms ease;
}

.card-hover-reveal {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  transition: opacity 220ms ease, transform 220ms cubic-bezier(0.16, 1, 0.3, 1);
}

/* --- 7. OBSIDIAN FLOATING DOCK & STICKY TOOLBARS --- */
.app-header,
#main-header {
  position: -webkit-sticky !important;
  position: sticky !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
  z-index: 40 !important;
  background: rgba(6, 7, 10, 0.82) !important;
  backdrop-filter: blur(24px) saturate(180%) !important;
  -webkit-backdrop-filter: blur(24px) saturate(180%) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.75) !important;
}

.nav-pill-dock {
  background: rgba(12, 15, 23, 0.85) !important;
  border: 1px solid rgba(255, 255, 255, 0.09) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.10), 0 6px 20px rgba(0, 0, 0, 0.45) !important;
  border-radius: 14px !important;
  padding: 4px !important;
}

.nav-tab {
  white-space: nowrap !important;
  flex-shrink: 0 !important;
}

.nav-tab svg,
.nav-tab i {
  width: 16px !important;
  height: 16px !important;
  min-width: 16px !important;
  min-height: 16px !important;
  flex-shrink: 0 !important;
}

.calendar-controls-sticky,
.sticky-toolbar {
  position: -webkit-sticky !important;
  position: sticky !important;
  top: 52px !important;
  z-index: 30 !important;
  background: rgba(9, 12, 19, 0.88) !important;
  backdrop-filter: blur(20px) saturate(175%) !important;
  -webkit-backdrop-filter: blur(20px) saturate(175%) !important;
  border: 1px solid rgba(255, 255, 255, 0.09) !important;
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.12), 0 14px 34px -8px rgba(0, 0, 0, 0.75) !important;
}

@media (min-width: 640px) {
  .calendar-controls-sticky,
  .sticky-toolbar {
    top: 56px !important;
  }
}

.cal-day-header {
  position: -webkit-sticky !important;
  position: sticky !important;
  top: 48px !important;
  z-index: 20 !important;
  background: rgba(15, 17, 23, 0.95) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
}

@media (min-width: 640px) {
  .cal-day-header {
    top: 56px !important;
  }
}

/* Modals ALWAYS above everything */
#release-detail-modal,
#game-detail-modal,
#news-reader-modal,
#alerts-modal,
#roulette-modal,
.app-modal {
  z-index: 9999 !important;
}

.status-strip {
  background: var(--status-bar-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--status-bar-border);
  border-radius: var(--radius-card);
}

/* --- 8. STANDARDIZED FILTERS & CHIPS (Phase 4) --- */
/* Ghost style by default */
.chip, .steam-chip, .cal-chip, .cal-plat, .sagas-filter-btn, .news-chip {
  background: var(--bg-surface-subtle, rgba(255, 255, 255, 0.04)) !important;
  color: #94A3B8 !important;
  border: 1px solid var(--border-subtle) !important;
  border-radius: var(--radius-badge, 8px) !important;
  transition: all 180ms ease !important;
}

.chip:hover, .steam-chip:hover, .cal-chip:hover, .cal-plat:hover, .sagas-filter-btn:hover, .news-chip:hover {
  background: rgba(255, 255, 255, 0.09) !important;
  color: #F8FAFC !important;
  border-color: rgba(255, 255, 255, 0.18) !important;
}

/* Active illuminated style */
.chip.active, .steam-chip.active, .cal-chip.active, .sagas-filter-btn.active, .news-chip.active {
  background: rgba(var(--accent-primary-rgb), 0.18) !important;
  color: var(--accent-primary) !important;
  border-color: var(--accent-primary) !important;
  box-shadow: 0 2px 12px var(--accent-glow) !important;
  font-weight: 700 !important;
}

.cal-plat.active {
  background-color: rgba(var(--accent-primary-rgb), 0.22) !important;
  color: var(--text-accent) !important;
  border-color: var(--accent-primary) !important;
  box-shadow: 0 2px 10px var(--accent-glow) !important;
  font-weight: 700 !important;
}

/* Sagas Episode Cards Normalization */
.saga-episode-card {
  background: var(--bg-card) !important;
  border: 1px solid var(--border-subtle) !important;
  border-radius: var(--radius-card);
  transition: all 180ms ease;
}

.saga-episode-card:hover {
  border-color: var(--card-hover-border) !important;
}

.saga-episode-card.is-owned {
  border-color: rgba(16, 185, 129, 0.25) !important;
}
.saga-episode-card.is-owned:hover {
  border-color: rgba(16, 185, 129, 0.55) !important;
}

.saga-episode-card.is-wishlist {
  border-color: rgba(var(--accent-primary-rgb), 0.25) !important;
}
.saga-episode-card.is-wishlist:hover {
  border-color: var(--accent-primary) !important;
}

.saga-episode-card.is-missing {
  border-color: var(--border-subtle) !important;
}
.saga-episode-card.is-missing:hover {
  border-color: rgba(255, 255, 255, 0.18) !important;
}

/* Navigation Tabs */
.nav-tab {
  border: 1px solid transparent;
  border-radius: var(--radius-badge, 8px);
  transition: all 180ms ease;
  color: #94A3B8;
}

.nav-tab:hover {
  color: #F8FAFC;
  background: rgba(255, 255, 255, 0.06);
}

.nav-tab.active {
  background: rgba(var(--accent-primary-rgb), 0.12) !important;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.35) !important;
  color: var(--accent-primary) !important;
  box-shadow: inset 0 -2px 0 var(--accent-primary) !important;
  font-weight: 700 !important;
}

.mobile-tab.active {
  color: var(--accent-primary) !important;
}

/* Theme Utilities */
.theme-text { color: var(--accent-primary) !important; }
.theme-text-accent { color: var(--text-accent) !important; }

.theme-btn-active {
  background: var(--btn-active) !important;
  color: #FFFFFF !important;
  box-shadow: 0 4px 15px var(--accent-glow) !important;
}

.theme-badge-solid {
  background: var(--hero-badge-bg) !important;
  color: #FFFFFF !important;
  box-shadow: 0 2px 10px var(--accent-glow) !important;
}

.theme-card-border {
  border-color: var(--card-border) !important;
}

.theme-card-border:hover {
  border-color: var(--card-hover-border) !important;
}

/* Calendar Days (Phase 4 - Clean Borders) */
.theme-day-box {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-card);
  transition: all 180ms ease;
}

.theme-day-box:hover {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.03);
}

.theme-day-box.is-today {
  background: rgba(var(--accent-primary-rgb), 0.04) !important;
  border: 1px solid var(--accent-primary) !important;
  box-shadow: 0 0 14px var(--accent-glow) !important;
  position: relative;
}

.cal-day-header.is-today {
  border: 1px solid var(--accent-primary) !important;
  box-shadow: 0 0 12px var(--accent-glow) !important;
}

.theme-day-divider {
  border-color: var(--border-subtle) !important;
}

.theme-indicator-dot {
  background-color: var(--accent-primary) !important;
}

.theme-user-pill {
  background: rgba(var(--accent-primary-rgb), 0.1) !important;
  border-color: rgba(var(--accent-primary-rgb), 0.35) !important;
}

.theme-user-pill:hover {
  background: rgba(var(--accent-primary-rgb), 0.22) !important;
  border-color: var(--accent-primary) !important;
  box-shadow: 0 0 15px var(--accent-glow) !important;
}

.theme-dropdown {
  background: rgba(10, 14, 24, 0.98) !important;
  border-color: var(--card-border) !important;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.8), 0 0 25px var(--accent-glow) !important;
}

.theme-input-focus:focus {
  border-color: var(--accent-primary) !important;
  box-shadow: 0 0 12px var(--accent-glow) !important;
}

/* --- 9. MICRO-INTERACTIONS & ANIMATIONS (Phase 5) --- */

/* Shimmer Dark Skeleton */
@keyframes shimmerPulse {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.skeleton-shimmer {
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.02) 25%, rgba(255, 255, 255, 0.07) 37%, rgba(255, 255, 255, 0.02) 63%);
  background-size: 400% 100%;
  animation: shimmerPulse 1.8s ease-in-out infinite;
  border-radius: var(--radius-card);
}

/* Stagger List Animation */
@keyframes fadeInUpStagger {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.stagger-item {
  animation: fadeInUpStagger 250ms cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* User Dropdown Pill */
#user-profile-badge {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  padding: 6px 12px !important;
  border-radius: 14px !important;
  cursor: pointer !important;
  user-select: none !important;
  white-space: nowrap !important;
  transition: all 0.2s ease-in-out !important;
}

#user-dropdown-menu {
  position: absolute !important;
  right: 0 !important;
  top: calc(100% + 10px) !important;
  width: 310px !important;
  min-width: 310px !important;
  max-width: 330px !important;
  max-height: calc(100vh - 80px) !important;
  overflow-y: auto !important;
  border-radius: var(--radius-card, 16px) !important;
  padding: 12px !important;
  z-index: 1000 !important;
  backdrop-filter: blur(24px) !important;
  -webkit-backdrop-filter: blur(24px) !important;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.8), 0 0 25px var(--accent-glow) !important;
  border: 1px solid var(--card-border) !important;
  background: rgba(11, 15, 25, 0.98) !important;
  box-sizing: border-box !important;
}

.user-dropdown-header {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  padding: 10px 12px !important;
  background: rgba(0, 0, 0, 0.6) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  border-radius: 12px !important;
  margin-bottom: 8px !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

.user-dropdown-link {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  padding: 9px 12px !important;
  border-radius: 10px !important;
  color: #E2E8F0 !important;
  font-size: 12px !important;
  font-weight: 600 !important;
  width: 100% !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  box-sizing: border-box !important;
  cursor: pointer !important;
  transition: all 0.15s ease-in-out !important;
  background: transparent !important;
  border: none !important;
}

.user-dropdown-link:hover {
  background: rgba(255, 255, 255, 0.09) !important;
  color: #FFFFFF !important;
  transform: translateX(2px) !important;
}

.user-dropdown-link-danger {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  padding: 9px 12px !important;
  border-radius: 10px !important;
  color: #F87171 !important;
  font-size: 12px !important;
  font-weight: 700 !important;
  width: 100% !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  box-sizing: border-box !important;
  cursor: pointer !important;
  transition: all 0.15s ease-in-out !important;
  background: rgba(239, 68, 68, 0.1) !important;
  border: 1px solid rgba(239, 68, 68, 0.25) !important;
  margin-top: 6px !important;
}

.user-dropdown-link-danger:hover {
  background: rgba(239, 68, 68, 0.22) !important;
  border-color: rgba(239, 68, 68, 0.5) !important;
  color: #FCA5A5 !important;
}

.user-dropdown-icon-box {
  width: 28px !important;
  height: 28px !important;
  border-radius: 8px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-shrink: 0 !important;
}

/* Scrollbar and input tweaks */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: #07090E;
}
::-webkit-scrollbar-thumb {
  background: #1E293B;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #334155;
}

.no-scrollbar::-webkit-scrollbar {
  display: none;
}
.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
input[type="number"] {
  -moz-appearance: textfield;
  appearance: textfield;
}

/* Calendar Day Box Scroll Margin */
.theme-day-box {
  scroll-margin-top: calc(var(--header-height, 62px) + 130px);
}

/* FLIP & Keyed Basket Card Transitions */
.basket-card-item {
  will-change: transform, opacity;
  transform-origin: center center;
  transition: box-shadow 200ms ease, border-color 200ms ease;
}

.basket-card-item.is-entering {
  opacity: 0;
  transform: scale(0.95);
}

.basket-card-item.is-exiting {
  opacity: 0 !important;
  transform: scale(0.92) !important;
  pointer-events: none !important;
  transition: opacity 150ms ease-out, transform 150ms ease-out !important;
}

/* --- MOBILE NAVIGATION & ERGONOMICS --- */
@media (max-width: 1023px) {
  body {
    padding-bottom: calc(5.5rem + env(safe-area-inset-bottom, 0px)) !important;
  }
}

.mobile-bottom-nav {
  padding-bottom: calc(0.6rem + env(safe-area-inset-bottom, 0px)) !important;
  background: rgba(8, 10, 15, 0.94) !important;
  backdrop-filter: blur(20px) !important;
  -webkit-backdrop-filter: blur(20px) !important;
}

.mobile-tab {
  min-height: 44px;
  min-width: 0;
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  color: #64748B !important;
  transition: all 180ms ease;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  padding: 4px 2px !important;
}

.mobile-tab:hover {
  color: #94A3B8 !important;
}

.mobile-tab.active {
  color: var(--accent-primary, #06B6D4) !important;
  font-weight: 800 !important;
}

.mobile-tab.active i,
.mobile-tab.active svg {
  color: var(--accent-primary, #06B6D4) !important;
  transform: scale(1.12);
  transition: transform 180ms ease;
}

/* Mobile 2-Column Grid Adjustments */
@media (max-width: 640px) {
  .game-poster-card {
    padding: 0.5rem !important;
    gap: 0.35rem !important;
    border-radius: 0.875rem !important;
  }
  
  .game-poster-card .h-56,
  .game-poster-card .h-60,
  .game-poster-card .h-44 {
    height: 165px !important;
  }

  .touch-target-44 {
    min-height: 44px !important;
    min-width: 44px !important;
  }
}

/* Partner Banner iframe containment */
.ig-partner-banner-frame {
  min-height: auto !important;
  overflow: visible !important;
}

.ig-partner-banner-frame iframe {
  max-width: 100% !important;
  min-height: 250px !important;
  border-radius: 12px !important;
  margin: 0 auto !important;
  display: block !important;
  overflow: visible !important;
}

/* ═══════════════════════════════════════════════════════════════════════
   THEME-AWARE UTILITY CLASSES — Remplace les couleurs statiques Tailwind
   par des variables CSS du thème actif (RPG=Ambre, Steam=Bleu, Cyber=Cyan)
   ═══════════════════════════════════════════════════════════════════════ */

.theme-badge-rank {
  background: var(--accent-primary) !important;
  color: #0a0c10 !important;
  box-shadow: 0 2px 8px rgba(var(--accent-primary-rgb), 0.35) !important;
}

.theme-badge-playtime {
  background: rgba(var(--accent-primary-rgb), 0.80) !important;
  color: #0a0c10 !important;
}

.theme-icon-box {
  background: rgba(var(--accent-primary-rgb), 0.20) !important;
  color: var(--accent-primary) !important;
}

.theme-icon-color {
  color: var(--accent-primary) !important;
}

.theme-border-accent {
  border-color: rgba(var(--accent-primary-rgb), 0.30) !important;
}

.theme-bg-accent-subtle {
  background: rgba(var(--accent-primary-rgb), 0.15) !important;
}

.theme-text-metric {
  color: var(--accent-primary) !important;
}

.theme-text-secondary {
  color: var(--text-accent, var(--accent-primary)) !important;
}

.theme-border-avatar {
  border-color: rgba(var(--accent-primary-rgb), 0.60) !important;
}

.theme-border-avatar-lg {
  border-color: rgba(var(--accent-primary-rgb), 0.80) !important;
}

.theme-modal-border {
  border-color: rgba(var(--accent-primary-rgb), 0.30) !important;
}

.theme-focus-ring:focus {
  border-color: var(--accent-primary) !important;
  box-shadow: 0 0 12px var(--accent-glow) !important;
  outline: none !important;
}

.theme-btn-sync {
  background: rgba(var(--accent-primary-rgb), 0.15) !important;
  border-color: rgba(var(--accent-primary-rgb), 0.40) !important;
  color: var(--text-accent, var(--accent-primary)) !important;
}

.theme-btn-sync:hover {
  background: rgba(var(--accent-primary-rgb), 0.25) !important;
  border-color: rgba(var(--accent-primary-rgb), 0.60) !important;
}

/* ═══════════════════════════════════════════════════════════════════════
   SCROLL CONFORT PWA — Anti-overscroll bounce + touch smoothing
   ═══════════════════════════════════════════════════════════════════════ */

html, body {
  overscroll-behavior-y: contain;
  -webkit-overflow-scrolling: touch;
}

/* ═══════════════════════════════════════════════════════════════════════
   ULTRA-PERFORMANCE & CHROMIUM/EDGE SMOOTHNESS ENGINE
   - Désactive backdrop-filter sur les éléments répétés (Cartes, Tags, Boutons)
   - Conserve blur UNIQUEMENT sur Header + Bottom Nav + Modales
   - Active content-visibility pour le rendu hors-écran sur Desktop et Mobile
   - Accélération GPU ciblée sans fuite mémoire
   ═══════════════════════════════════════════════════════════════════════ */

/* 1. Désactivation universelle du backdrop-filter sur cartes et composants répétés */
.glass-card,
.game-poster-card,
.saga-episode-card,
.theme-day-box,
.status-strip,
.chip, .steam-chip, .cal-chip, .sagas-filter-btn, .news-chip,
.cart-corner-btn,
.fav-star-btn,
.card-tag-container span,
.cal-day-header {
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

/* 2. Content-visibility ciblé uniquement sur les conteneurs secondaires hors-écran (jamais sur .game-poster-card pour éviter tout pop d'images) */
.saga-card-mobile,
.saga-episode-card {
  content-visibility: auto;
  contain-intrinsic-size: 260px 380px;
  contain: layout style paint;
}

/* 3. Exceptions préservées : Header et Modales conservent le blur luxueux */
.app-header, #main-header {
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
}

@media (max-width: 767px) {
  .mobile-bottom-nav {
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
  }

  .glass-card, .game-poster-card {
    box-shadow: none !important;
  }
  .glass-card:hover, .game-poster-card:hover {
    box-shadow: none !important;
    border-color: var(--card-hover-border) !important;
    transform: none !important;
  }

  /* Keep accurate height on day containers for exact scrolling */
  .theme-day-box {
    content-visibility: visible !important;
    scroll-margin-top: 155px !important;
  }

  /* Supprime l'accélération GPU globale sur les cartes panier */
  .basket-card-item {
    will-change: auto !important;
  }
}

  /* ─── CALENDRIER MOBILE : Bordures harmonieuses et complètes ─── */
  .theme-day-box {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid var(--card-border) !important;
    border-radius: 16px !important;
    padding: 10px !important;
  }
  .theme-day-box.is-today {
    background: rgba(var(--accent-primary-rgb), 0.04) !important;
    border: 1px solid var(--accent-primary) !important;
    box-shadow: 0 0 16px -2px var(--accent-glow) !important;
    border-radius: 16px !important;
  }
  .cal-day-header {
    border-radius: 12px !important;
    background: rgba(10, 12, 16, 0.95) !important;
  }

  /* ─── SAGAS MOBILE ACCORDION ─── */
  .saga-card-mobile {
    background: var(--bg-card) !important;
    border: 1px solid var(--border-subtle) !important;
    border-radius: var(--radius-card) !important;
    transition: border-color 200ms ease !important;
  }
  .saga-card-mobile:active {
    border-color: rgba(var(--accent-primary-rgb), 0.40) !important;
  }

  .saga-accordion-header {
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    min-height: 44px;
  }

  .saga-accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 400ms cubic-bezier(0.16, 1, 0.3, 1), opacity 250ms ease;
    opacity: 0;
  }
  .saga-card-mobile.is-expanded .saga-accordion-content {
    max-height: 3000px;
    opacity: 1;
  }

  .saga-accordion-chevron {
    transition: transform 300ms cubic-bezier(0.16, 1, 0.3, 1);
  }
  .saga-card-mobile.is-expanded .saga-accordion-chevron {
    transform: rotate(180deg);
  }

  .saga-episode-mobile {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.625rem 0.75rem;
    border-top: 1px solid var(--border-subtle);
    min-height: 44px;
  }
  .saga-episode-mobile img {
    width: 40px;
    height: 56px;
    object-fit: cover;
    border-radius: 6px;
    flex-shrink: 0;
    border: 1px solid var(--border-subtle);
  }
  .saga-episode-mobile-info {
    flex: 1;
    min-width: 0;
  }

.theme-badge-rank,
.basket-card-rank {
  background: var(--accent-primary) !important;
  color: #0a0c10 !important;
  font-weight: 800 !important;
  box-shadow: 0 2px 8px var(--accent-glow) !important;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.4) !important;
}

.theme-badge-playtime {
  background: rgba(var(--accent-primary-rgb), 0.85) !important;
  color: #0a0c10 !important;
  font-weight: 800 !important;
  border: 1px solid rgba(var(--accent-primary-rgb), 0.5) !important;
}

/* ═══════════════════════════════════════════════════════════════════════
   THEME-AWARE PROFILE & MOBILE DRAWER MENU STYLING
   ═══════════════════════════════════════════════════════════════════════ */

.user-dropdown-icon-box {
  width: 28px !important;
  height: 28px !important;
  border-radius: 8px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-shrink: 0 !important;
  background: rgba(var(--accent-primary-rgb), 0.14) !important;
  color: var(--accent-primary) !important;
}

.user-dropdown-icon-box i,
.user-dropdown-icon-box svg {
  color: var(--accent-primary) !important;
}

.mob-menu-action-btn {
  width: 100%;
  min-height: 44px;
  padding: 10px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  color: #E2E8F0;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  font-weight: 600;
  transition: all 0.18s ease;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.mob-menu-action-btn:hover,
.mob-menu-action-btn:active {
  background: rgba(var(--accent-primary-rgb), 0.12);
  border-color: rgba(var(--accent-primary-rgb), 0.35);
  color: #FFFFFF;
  transform: translateX(2px);
}

.mob-menu-icon-box {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: rgba(var(--accent-primary-rgb), 0.15);
  color: var(--accent-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.2s ease, background 0.2s ease;
}

.mob-menu-action-btn:hover .mob-menu-icon-box,
.mob-menu-action-btn:active .mob-menu-icon-box {
  transform: scale(1.08);
  background: rgba(var(--accent-primary-rgb), 0.25);
}

.mob-menu-icon-box i,
.mob-menu-icon-box svg {
  color: var(--accent-primary) !important;
}

/* Hero Release Card Glowing Hover */
.hero-release-card {
  border: 1px solid var(--card-border) !important;
  transition: transform 250ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 250ms cubic-bezier(0.16, 1, 0.3, 1), border-color 250ms ease !important;
}

.hero-release-card:hover {
  border-color: var(--card-hover-border) !important;
  box-shadow: 0 14px 35px -6px rgba(0, 0, 0, 0.85), 0 0 25px 2px var(--accent-glow) !important;
  transform: translateY(-4px) !important;
}

/* ─── STEAM GAME DETAILS & JOURNAL MODAL ─── */
.sg-star {
  color: #475569;
  cursor: pointer;
  transition: color 0.15s ease, transform 0.15s ease, text-shadow 0.15s ease;
  position: relative;
  display: inline-block;
  user-select: none;
}
.sg-star.active {
  color: #f59e0b;
  text-shadow: 0 0 10px rgba(245, 158, 11, 0.5);
}
.sg-star.half {
  background: linear-gradient(90deg, #f59e0b 50%, #475569 50%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 0 10px rgba(245, 158, 11, 0.35);
}
.sg-star.hovered {
  color: #fbbf24;
  text-shadow: 0 0 14px rgba(251, 191, 36, 0.7);
  transform: scale(1.18);
}
.sg-star.hover-half {
  background: linear-gradient(90deg, #fbbf24 50%, #475569 50%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 0 14px rgba(251, 191, 36, 0.5);
  transform: scale(1.18);
}
.sg-status-chip {
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.sg-status-chip:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-1px);
}
.sg-status-chip.active {
  background: linear-gradient(135deg, rgba(147, 51, 234, 0.35), rgba(79, 70, 229, 0.35)) !important;
  border-color: rgba(168, 85, 247, 0.6) !important;
  color: #ffffff !important;
  box-shadow: 0 0 14px rgba(168, 85, 247, 0.35) !important;
  transform: scale(1.02);
}

/* ─── BOUTON DE RECHERCHE RAPIDE (⌘K) ─── */
.cmdk-pill-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.10);
  box-shadow: inset 0 1px 0 0 rgba(255, 255, 255, 0.08);
  transition: all 180ms ease;
}

.cmdk-pill-btn:hover {
  background: rgba(16, 185, 129, 0.10);
  border-color: rgba(16, 185, 129, 0.40);
  color: #FFFFFF;
}

/* ─── ANTI-SURLIGNAGE & CURSEUR DE BUDGET ─── */
::selection {
  background: rgba(16, 185, 129, 0.22);
  color: #A7F3D0;
}

button,
label,
select,
.nav-tab,
.mobile-tab,
.chip,
.steam-chip,
.cal-chip,
.cal-plat,
.sagas-filter-btn,
.news-chip,
#auto-basket-view,
#manual-cart-view .glass-card {
  -webkit-user-select: none;
  user-select: none;
}

.sim-budget-slider {
  -webkit-appearance: none;
  appearance: none;
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.10);
  outline: none;
}

.sim-budget-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: linear-gradient(135deg, #34D399, #06B6D4);
  border: 2px solid #06070A;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.65);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.sim-budget-slider::-webkit-slider-thumb:hover {
  transform: scale(1.12);
  box-shadow: 0 0 18px rgba(16, 185, 129, 0.9);
}

.sim-budget-slider::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: linear-gradient(135deg, #34D399, #06B6D4);
  border: 2px solid #06070A;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.65);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}



/* =========================================================================
   ACTUALITES : badges lisibles + lecteur d'article (v2)
   ========================================================================= */
.news-badge {
  --nb-color: #94A3B8;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px 3px 7px;
  border-radius: 7px;
  font-family: var(--font-mono, ui-monospace, SFMono-Regular, Menlo, monospace);
  font-size: 10px;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: .02em;
  color: #F8FAFC;
  background: rgba(5, 7, 12, .9);
  border: 1px solid rgba(255, 255, 255, .14);
  border-left: 3px solid var(--nb-color);
  box-shadow: 0 2px 10px rgba(0, 0, 0, .55);
  text-shadow: none;
  white-space: nowrap;
}
.news-badge svg, .news-badge i { width: 12px; height: 12px; color: var(--nb-color); flex-shrink: 0; }
.news-badge--lg { font-size: 11px; padding: 4px 10px 4px 8px; text-transform: uppercase; letter-spacing: .06em; }
.news-badge--releases { --nb-color: #34D399; }
.news-badge--industry { --nb-color: #22D3EE; }
.news-badge--hardware { --nb-color: #C084FC; }
.news-badge--updates  { --nb-color: #FBBF24; }
.news-badge--general  { --nb-color: #94A3B8; }

.news-date-pill {
  padding: 2px 8px;
  border-radius: 6px;
  font-family: var(--font-mono, ui-monospace, monospace);
  font-size: 10px;
  color: #E2E8F0;
  background: rgba(5, 7, 12, .85);
  border: 1px solid rgba(255, 255, 255, .12);
}

/* --- Lecteur d'article --- */
#news-reader-modal .news-reader-panel {
  position: relative;
  width: 100%;
  max-width: 820px !important;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 22px;
  background: #0A0D14;
  border: 1px solid rgba(255, 255, 255, .1);
  box-shadow: 0 30px 90px rgba(0, 0, 0, .8);
}
#news-reader-modal .news-reader-scroll {
  flex: 1 1 auto;
  overflow-y: auto;
  overscroll-behavior: contain;
}
#news-reader-modal .news-reader-hero {
  position: relative;
  margin: 0;
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: 46vh;
  overflow: hidden;
  background: #05070B;
}
#news-reader-modal .news-reader-hero-bg {
  position: absolute;
  inset: -24px;
  background-size: cover;
  background-position: center;
  filter: blur(22px) brightness(.45) saturate(1.2);
  transform: scale(1.08);
}
#news-reader-modal .news-reader-hero-img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: contain;   /* jamais etiree ni rognee */
  display: block;
}
#news-reader-modal .news-reader-hero::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 30%;
  z-index: 2;
  background: linear-gradient(to top, #0A0D14, transparent);
  pointer-events: none;
}
#news-reader-modal .news-reader-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 5;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #E2E8F0;
  background: rgba(5, 7, 12, .78);
  border: 1px solid rgba(255, 255, 255, .16);
  cursor: pointer;
  transition: background .15s ease, color .15s ease;
}
#news-reader-modal .news-reader-close:hover { background: rgba(5, 7, 12, .95); color: #fff; }
#news-reader-modal .news-reader-article {
  max-width: 680px;
  margin: 0 auto;
  padding: 22px 28px 34px;
}
#news-reader-modal .news-reader-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono, ui-monospace, monospace);
  font-size: 12px;
  color: #94A3B8;
}
#news-reader-modal .news-reader-title {
  margin-top: 12px;
  font-size: clamp(1.35rem, 1.1rem + 1.2vw, 2rem);
  line-height: 1.2;
  font-weight: 900;
  color: #fff;
  letter-spacing: -.01em;
}
#news-reader-modal .news-reader-lede {
  margin-top: 14px;
  font-size: 1.06rem;
  line-height: 1.65;
  font-weight: 600;
  color: #E2E8F0;
}
#news-reader-modal .news-reader-body {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, .08);
  font-size: 1rem;
  line-height: 1.78;
  color: #CBD5E1;
}
#news-reader-modal .news-reader-body p { margin: 0 0 1.05em; }
#news-reader-modal .news-reader-body h4 {
  margin: 1.6em 0 .6em;
  font-size: 1.12rem;
  font-weight: 800;
  color: #fff;
  line-height: 1.35;
}
#news-reader-modal .news-reader-footer {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 20px;
  border-top: 1px solid rgba(255, 255, 255, .08);
  background: rgba(0, 0, 0, .35);
}
@media (max-width: 640px) {
  #news-reader-modal { padding: 0 !important; }
  #news-reader-modal .news-reader-panel { max-height: 100vh; height: 100%; border-radius: 0; }
  #news-reader-modal .news-reader-hero { max-height: 34vh; }
  #news-reader-modal .news-reader-article { padding: 18px 18px 28px; }
  #news-reader-modal .news-reader-body { font-size: .97rem; }
}

/* =========================================================================
   ACTUALITES v3 : redactions JV / Tech, rubriques, "Mes jeux"
   ========================================================================= */
.news-badge--pc       { --nb-color: #C084FC; }
.news-badge--mobile   { --nb-color: #38BDF8; }
.news-badge--ai       { --nb-color: #F472B6; }
.news-badge--software { --nb-color: #FBBF24; }
.news-badge--major    { --nb-color: #F97316; padding: 3px 6px; }
.news-badge--major svg { color: #FB923C; }

.news-toolbar { position: relative; z-index: 2; }
.news-desk-switch {
  display: inline-flex;
  padding: 4px;
  gap: 4px;
  border-radius: 14px;
  background: rgba(0, 0, 0, .45);
  border: 1px solid rgba(255, 255, 255, .08);
}
.news-desk-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 800;
  color: #94A3B8;
  background: transparent;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.news-desk-btn:hover { color: #E2E8F0; background: rgba(255, 255, 255, .04); }
.news-desk-btn.active {
  color: #ECFDF5;
  background: linear-gradient(135deg, rgba(16, 185, 129, .28), rgba(6, 182, 212, .22));
  border-color: rgba(52, 211, 153, .45);
  box-shadow: 0 4px 16px -6px rgba(16, 185, 129, .55);
}
#news-desk-tech.active {
  background: linear-gradient(135deg, rgba(139, 92, 246, .3), rgba(56, 189, 248, .22));
  border-color: rgba(167, 139, 250, .5);
  box-shadow: 0 4px 16px -6px rgba(139, 92, 246, .55);
}
.news-search-input {
  width: 100%;
  height: 38px;
  padding: 0 12px 0 34px;
  border-radius: 11px;
  font-size: 13px;
  color: #E2E8F0;
  background: rgba(0, 0, 0, .4);
  border: 1px solid rgba(255, 255, 255, .1);
  outline: none;
}
.news-search-input:focus { border-color: rgba(52, 211, 153, .5); }
#pi-alert-target.news-search-input { padding-left: 12px; }
.news-icon-btn {
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #CBD5E1;
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .1);
  cursor: pointer;
}
.news-icon-btn:hover { background: rgba(255, 255, 255, .1); color: #fff; }
.news-chip--mine.active, .news-chip--mine:hover { border-color: rgba(251, 146, 60, .6) !important; color: #FDBA74 !important; }

.news-mine-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: 62%;
  padding: 2px 8px;
  border-radius: 6px;
  font-size: 10px;
  font-weight: 700;
  color: #FFEDD5;
  background: rgba(124, 45, 18, .9);
  border: 1px solid rgba(251, 146, 60, .55);
}
.news-mine-pill span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.news-mine-pill svg { width: 11px; height: 11px; flex-shrink: 0; color: #FDBA74; }
.news-card--mine { box-shadow: inset 0 0 0 1px rgba(251, 146, 60, .35); }

#news-reader-modal .news-reader-match {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  padding: 5px 10px;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 700;
  color: #FFEDD5;
  background: rgba(124, 45, 18, .55);
  border: 1px solid rgba(251, 146, 60, .45);
}
#news-reader-modal .news-reader-match.hidden { display: none; }

/* =========================================================================
   FICHE PRIX (courbe, verdict, alerte)
   ========================================================================= */
#price-insights-modal { z-index: 9998 !important; }
#price-insights-modal .pi-panel {
  position: relative;
  width: 100%;
  max-width: 760px;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 22px;
  background: #0A0D14;
  border: 1px solid rgba(255, 255, 255, .1);
  box-shadow: 0 30px 90px rgba(0, 0, 0, .8);
}
#price-insights-modal .news-reader-close { position: absolute; top: 12px; right: 12px; z-index: 5; width: 38px; height: 38px; border-radius: 12px; display: flex; align-items: center; justify-content: center; color: #E2E8F0; background: rgba(5, 7, 12, .78); border: 1px solid rgba(255, 255, 255, .16); cursor: pointer; }
#price-insights-modal .pi-scroll { overflow-y: auto; overscroll-behavior: contain; }
#price-insights-modal .pi-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 60px 16px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  background: linear-gradient(180deg, rgba(16, 185, 129, .08), transparent);
}
#price-insights-modal .pi-cover { width: 120px; aspect-ratio: 460 / 215; object-fit: cover; border-radius: 10px; border: 1px solid rgba(255, 255, 255, .1); flex-shrink: 0; }
#price-insights-modal .pi-verdict {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, .12);
  background: rgba(255, 255, 255, .04);
  color: #E2E8F0;
}
#price-insights-modal .pi-verdict--buy  { background: rgba(16, 185, 129, .14); border-color: rgba(52, 211, 153, .45); color: #D1FAE5; }
#price-insights-modal .pi-verdict--good { background: rgba(56, 189, 248, .12); border-color: rgba(56, 189, 248, .4); color: #E0F2FE; }
#price-insights-modal .pi-verdict--wait { background: rgba(251, 191, 36, .1); border-color: rgba(251, 191, 36, .4); color: #FEF3C7; }
#price-insights-modal .pi-stat { padding: 10px 12px; border-radius: 12px; background: rgba(0, 0, 0, .35); border: 1px solid rgba(255, 255, 255, .07); }
#price-insights-modal .pi-stat-label { font-size: 10px; text-transform: uppercase; letter-spacing: .06em; color: #94A3B8; font-weight: 700; }
#price-insights-modal .pi-stat-value { font-size: 17px; font-weight: 900; color: #fff; margin-top: 2px; font-family: var(--font-mono, ui-monospace, monospace); }
#price-insights-modal .pi-stat-hint { font-size: 10px; color: #64748B; margin-top: 2px; }
#price-insights-modal .pi-chart-box { position: relative; height: 240px; padding: 10px; border-radius: 14px; background: rgba(0, 0, 0, .3); border: 1px solid rgba(255, 255, 255, .07); }
#price-insights-modal .pi-alert-box { padding: 14px; border-radius: 14px; background: rgba(251, 191, 36, .05); border: 1px solid rgba(251, 191, 36, .2); }
#price-insights-modal #pi-alert-enabled { accent-color: #10B981; }
@media (max-width: 640px) {
  #price-insights-modal { padding: 0 !important; }
  #price-insights-modal .pi-panel { max-height: 100vh; height: 100%; border-radius: 0; }
  #price-insights-modal .pi-cover { width: 88px; }
}
.game-news-item img { aspect-ratio: 16 / 9; }

/* Carte "À la une" (Actualités) & Barre de saut mensuel rapide (Calendrier) */
.news-badge--hero {
  --nb-color: #34D399;
  background: rgba(6, 78, 59, 0.92);
  border-color: rgba(52, 211, 153, 0.65);
  color: #ECFDF5;
}
.news-hero-card {
  border-color: rgba(52, 211, 153, 0.32);
  background: linear-gradient(165deg, rgba(16, 30, 38, 0.92) 0%, rgba(9, 12, 19, 0.96) 100%);
}
.cal-month-pill {
  flex-shrink: 0;
  padding: 4px 10px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 700;
  color: #94A3B8;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition: all 150ms ease;
}
.cal-month-pill:hover {
  color: #F8FAFC;
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
}
.cal-month-pill.active {
  color: #ECFDF5;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.28), rgba(6, 182, 212, 0.22));
  border-color: rgba(52, 211, 153, 0.5);
  box-shadow: 0 2px 10px -2px rgba(16, 185, 129, 0.45);
}

/* =========================================================================
   MODULE YOUTUBE (THE SHARE PLAYERS OFFICIAL CHANNEL)
   ========================================================================= */
.yt-filter-pill {
  color: #94A3B8;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.09);
}
.yt-filter-pill:hover {
  color: #F8FAFC;
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.18);
}
.yt-filter-pill.active {
  color: #F8FAFC;
  background: linear-gradient(135deg, rgba(var(--accent-primary-rgb), 0.28), rgba(6, 182, 212, 0.22));
  border-color: rgba(var(--accent-primary-rgb), 0.55);
  box-shadow: 0 6px 20px -4px rgba(var(--accent-primary-rgb), 0.35);
}
.yt-card {
  transition: transform 200ms cubic-bezier(0.22, 1, 0.36, 1), border-color 200ms ease, box-shadow 200ms ease;
}
.yt-card:hover {
  transform: translateY(-3px);
  border-color: rgba(var(--accent-primary-rgb), 0.45);
  box-shadow: 0 18px 40px -12px rgba(0, 0, 0, 0.85), 0 0 25px -6px rgba(var(--accent-primary-rgb), 0.25);
}
.yt-play-overlay {
  background: radial-gradient(circle, rgba(220, 38, 38, 0.92) 0%, rgba(185, 28, 28, 0.96) 100%);
  box-shadow: 0 8px 25px rgba(220, 38, 38, 0.55);
  transition: transform 200ms ease, box-shadow 200ms ease;
}
.yt-card:hover .yt-play-overlay {
  transform: scale(1.1);
  box-shadow: 0 10px 30px rgba(244, 63, 94, 0.75);
}

/* Badges haute lisibilité sur les miniatures YouTube (fond sombre opaque + liseré coloré) */
.yt-cat-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.01em;
  line-height: 1.2;
  background: rgba(6, 9, 15, 0.92) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-left-width: 3px !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.88), 0 1px 3px rgba(0, 0, 0, 0.95);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.9);
}
.yt-cat-emissions {
  color: #E9D5FF !important;
  border-color: rgba(192, 132, 252, 0.45) !important;
  border-left-color: #C084FC !important;
}
.yt-cat-tests {
  color: #A7F3D0 !important;
  border-color: rgba(52, 211, 153, 0.45) !important;
  border-left-color: #34D399 !important;
}
.yt-cat-quotidienne {
  color: #FDE68A !important;
  border-color: rgba(251, 191, 36, 0.45) !important;
  border-left-color: #FBBF24 !important;
}
.yt-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  font-family: var(--font-mono);
  background: rgba(185, 28, 28, 0.95) !important;
  color: #FFFFFF !important;
  border: 1px solid rgba(252, 165, 165, 0.45);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.88);
}

/* =========================================================================
   LOGO DE MARQUE ADAPTÉ AUX 3 THÈMES (1024.PNG RETRAVAILLÉ) & BADGE ON AIR
   ========================================================================= */
.brand-logo-box {
  background: transparent;
  padding: 1px;
}
.brand-logo-img {
  display: none;
  filter: drop-shadow(0 3px 10px rgba(0, 0, 0, 0.72));
}
.brand-header-logo {
  height: 46px;
  width: auto;
  object-fit: contain;
}
@media (min-width: 640px) {
  .brand-header-logo {
    height: 52px;
  }
}
.brand-yt-logo {
  height: 56px;
  width: auto;
  object-fit: contain;
}
@media (min-width: 640px) {
  .brand-yt-logo {
    height: 66px;
  }
}
.brand-footer-logo {
  height: 44px;
  width: auto;
  object-fit: contain;
}
html.theme-aurora .brand-logo-aurora,
html[data-theme="aurora"] .brand-logo-aurora,
html:not(.theme-radar):not(.theme-spatial) .brand-logo-aurora {
  display: block;
}
html.theme-radar .brand-logo-radar,
html[data-theme="radar"] .brand-logo-radar {
  display: block;
}
html.theme-spatial .brand-logo-spatial,
html[data-theme="spatial"] .brand-logo-spatial {
  display: block;
}

/* Badge ON AIR (identique à FloatingOnAirBadge.kt de l'application Android SharePlayers) */
@keyframes onAirPulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(229, 57, 53, 0.65), 0 6px 18px -2px rgba(183, 28, 28, 0.85);
  }
  50% {
    transform: scale(1.05);
    box-shadow: 0 0 0 6px rgba(229, 57, 53, 0), 0 8px 24px 0 rgba(229, 57, 53, 0.95);
  }
}
@keyframes onAirDotBlink {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.35; transform: scale(0.82); }
}
.on-air-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 11px;
  border-radius: 999px;
  background: linear-gradient(90deg, #E53935 0%, #B71C1C 100%);
  border: 1px solid rgba(255, 255, 255, 0.32);
  color: #FFFFFF;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  animation: onAirPulse 1.6s infinite ease-in-out;
  white-space: nowrap;
  flex-shrink: 0;
}
.on-air-badge.hidden {
  display: none !important;
}
.on-air-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #FFFFFF;
  box-shadow: 0 0 8px #FFFFFF;
  animation: onAirDotBlink 1s infinite ease-in-out;
}
.on-air-text {
  line-height: 1;
}

.brand-logo-accent {
  background: linear-gradient(90deg, #34D399 0%, #22D3EE 55%, #A78BFA 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
html.theme-radar .brand-logo-accent,
html[data-theme="radar"] .brand-logo-accent {
  background: linear-gradient(90deg, #22D3EE 0%, #34D399 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
html.theme-spatial .brand-logo-accent,
html[data-theme="spatial"] .brand-logo-accent {
  background: linear-gradient(90deg, #A5F3FC 0%, #C4B5FD 55%, #F9A8D4 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Compaction chirurgicale de la barre de navigation pour éviter tout débordement */
#main-header > div {
  max-width: 1280px;
  width: 100%;
}
.nav-pill-dock {
  padding: 4px !important;
  gap: 2px !important;
  max-width: 100%;
  overflow-x: auto;
  scrollbar-width: none;
}
.nav-pill-dock::-webkit-scrollbar {
  display: none;
}
.nav-pill-dock .nav-tab {
  padding: 6px 8px !important;
  font-size: 11.5px !important;
  gap: 5px !important;
}
@media (min-width: 1280px) {
  .nav-pill-dock .nav-tab {
    padding: 6px 9.5px !important;
    font-size: 12px !important;
  }
}

/* =========================================================================
   MODULE MÉTHODOLOGIE D'ANALYSE TECHNIQUE (THE SHARE PLAYERS LAB)
   ========================================================================= */
#tab-methodology:not(.hidden) {
  display: flex;
  flex-direction: column;
  gap: 36px !important;
  padding-bottom: 32px;
}
.meth-hero {
  background: linear-gradient(145deg, rgba(11, 22, 34, 0.95) 0%, rgba(8, 12, 20, 0.98) 60%, rgba(16, 28, 26, 0.95) 100%);
  padding: 28px !important;
}
@media (min-width: 640px) {
  .meth-hero {
    padding: 40px !important;
  }
}
.meth-hero-glow {
  position: absolute;
  inset: -40% -10% auto auto;
  width: 480px;
  height: 480px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.16) 0%, rgba(6, 182, 212, 0.08) 45%, transparent 70%);
  pointer-events: none;
}
.meth-toc-pill {
  color: #94A3B8;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.meth-toc-pill:hover {
  color: #F8FAFC;
  background: rgba(255, 255, 255, 0.1);
}
.meth-toc-pill.active {
  color: #ECFDF5;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.28), rgba(6, 182, 212, 0.22));
  border-color: rgba(52, 211, 153, 0.55);
  box-shadow: 0 4px 14px -2px rgba(16, 185, 129, 0.4);
}
.meth-section {
  scroll-margin-top: 132px;
  display: flex;
  flex-direction: column;
  gap: 24px !important;
  padding: 24px !important;
}
@media (min-width: 640px) {
  .meth-section {
    padding: 34px !important;
    gap: 28px !important;
  }
}
.meth-section > .grid {
  gap: 20px !important;
}
.meth-media-card {
  box-shadow: 0 14px 34px -10px rgba(0, 0, 0, 0.8);
}
.meth-figure {
  position: relative;
  cursor: zoom-in;
  overflow: hidden;
  border-radius: 16px;
}
.meth-figure img {
  transition: transform 250ms ease;
}
.meth-figure:hover img {
  transform: scale(1.012);
}
.meth-figure-zoom-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 11px;
  border-radius: 10px;
  background: rgba(6, 10, 18, 0.85);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(52, 211, 153, 0.45);
  color: #6EE7B7;
  font-size: 11px;
  font-weight: 800;
  pointer-events: none;
}
/* Encadré Vert Émeraude (#10b981) : Pourquoi notre mesure est fiable */
.meth-trust-panel {
  background: linear-gradient(160deg, rgba(16, 185, 129, 0.11) 0%, rgba(6, 78, 59, 0.18) 100%);
  border: 1px solid rgba(16, 185, 129, 0.42);
  box-shadow: inset 0 1px 0 0 rgba(52, 211, 153, 0.18);
  padding: 22px !important;
}
/* Encadré Ambre (#f59e0b) : Les limites honnêtes de cette analyse */
.meth-limit-panel {
  background: linear-gradient(160deg, rgba(245, 158, 11, 0.10) 0%, rgba(120, 53, 15, 0.18) 100%);
  border: 1px solid rgba(245, 158, 11, 0.42);
  box-shadow: inset 0 1px 0 0 rgba(251, 191, 36, 0.16);
  padding: 22px !important;
}


