:root {
  --bg-obsidian: #0b0e14;
  --bg-deep: #0f172a;
  --bg-card: #161b22;
  --bg-card-elevated: #1c232d;
  --emerald: #10b981;
  --neon-green: #22c55e;
  --text-main: #f9fafb;
  --text-muted: #9ca3af;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background-color: var(--bg-obsidian);
  color: var(--text-main);
}

body {
  background-color: var(--bg-obsidian);
  background-image:
    radial-gradient(circle at 15% 0%, rgba(16, 185, 129, 0.12), transparent 38%),
    radial-gradient(circle at 85% 12%, rgba(34, 197, 94, 0.08), transparent 34%),
    linear-gradient(180deg, #0b0e14 0%, #0d121b 55%, #0b0e14 100%);
  min-height: 100vh;
  overflow-x: hidden;
}

/* Grille cyber subtile en arrière-plan */
.cyber-grid-bg {
  background-size: 44px 44px;
  background-image:
    linear-gradient(to right, rgba(16, 185, 129, 0.035) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(16, 185, 129, 0.035) 1px, transparent 1px);
}

/* Masquer les éléments Alpine avant hydratation */
[x-cloak] {
  display: none !important;
}

/* Cartes Bento avec effet Glow néon émeraude au survol */
.bento-card {
  position: relative;
  background: linear-gradient(165deg, rgba(26, 33, 44, 0.92) 0%, rgba(22, 27, 34, 0.98) 100%);
  border: 1px solid rgba(255, 255, 255, 0.075);
  border-radius: 1rem;
  transition: transform 0.24s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.24s ease,
    box-shadow 0.24s ease;
}

.bento-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    135deg,
    rgba(16, 185, 129, 0.45),
    rgba(34, 197, 94, 0.05) 45%,
    rgba(16, 185, 129, 0.25)
  );
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}

.bento-card-interactive {
  cursor: pointer;
}

.bento-card-interactive:hover {
  transform: translateY(-3px);
  border-color: rgba(16, 185, 129, 0.55);
  box-shadow:
    0 14px 34px -10px rgba(0, 0, 0, 0.75),
    0 0 28px -6px rgba(16, 185, 129, 0.32);
}

.bento-card-interactive:hover::before {
  opacity: 1;
}

/* Halo pulsant pour le statut esport */
@keyframes pulseGlow {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.65);
  }
  50% {
    box-shadow: 0 0 0 7px rgba(34, 197, 94, 0);
  }
}

.pulse-dot {
  animation: pulseGlow 2.2s infinite;
}

/* Badges de rangs stylisés par palier compétitif */
.rank-crest {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.85rem;
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.tier-challenger, .tier-radiant {
  background: radial-gradient(circle at 30% 20%, rgba(250, 204, 21, 0.32), rgba(14, 165, 233, 0.22));
  border-color: rgba(250, 204, 21, 0.55);
  color: #fde047;
}

.tier-grandmaster, .tier-immortal {
  background: radial-gradient(circle at 30% 20%, rgba(244, 63, 94, 0.3), rgba(159, 18, 57, 0.2));
  border-color: rgba(244, 63, 94, 0.55);
  color: #fda4af;
}

.tier-master {
  background: radial-gradient(circle at 30% 20%, rgba(192, 132, 252, 0.3), rgba(107, 33, 168, 0.22));
  border-color: rgba(192, 132, 252, 0.55);
  color: #e9d5ff;
}

.tier-diamond {
  background: radial-gradient(circle at 30% 20%, rgba(56, 189, 248, 0.3), rgba(37, 99, 235, 0.2));
  border-color: rgba(56, 189, 248, 0.55);
  color: #bae6fd;
}

.tier-emerald, .tier-ascendant {
  background: radial-gradient(circle at 30% 20%, rgba(16, 185, 129, 0.34), rgba(5, 150, 105, 0.18));
  border-color: rgba(34, 197, 94, 0.6);
  color: #6ee7b7;
}

.tier-platinum {
  background: radial-gradient(circle at 30% 20%, rgba(45, 212, 191, 0.26), rgba(15, 118, 110, 0.18));
  border-color: rgba(45, 212, 191, 0.45);
  color: #99f6e4;
}

.tier-gold {
  background: radial-gradient(circle at 30% 20%, rgba(251, 191, 36, 0.26), rgba(180, 83, 9, 0.18));
  border-color: rgba(251, 191, 36, 0.45);
  color: #fde68a;
}

.tier-default {
  background: radial-gradient(circle at 30% 20%, rgba(148, 163, 184, 0.2), rgba(30, 41, 59, 0.4));
  border-color: rgba(148, 163, 184, 0.3);
  color: #cbd5e1;
}

/* Scrollbar sombre personnalisée */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #0b0e14;
}

::-webkit-scrollbar-thumb {
  background: #222b38;
  border-radius: 9999px;
}

::-webkit-scrollbar-thumb:hover {
  background: #10b981;
}

