@tailwind base;
@tailwind components;
@tailwind utilities;

@layer base {
  :root {
    --bg:      #0B1628;
    --surface: #112040;
    --surface2: #162850;
    --primary: #1A73E8;
    --accent:  #00D4AA;
    --gold:    #F5C518;
    --text:    #F0F4FF;
    --muted:   #8BA3C7;
    --border:  #1E3058;
    --red:     #FF4757;
  }

  html {
    @apply bg-[#0B1628] text-[#F0F4FF];
    font-family: 'Inter', system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
  }

  h1, h2, h3, h4, h5, h6 {
    font-family: 'Sora', system-ui, sans-serif;
    @apply font-bold text-[#F0F4FF];
  }

  a { @apply transition-colors duration-150; }
}

@layer components {
  /* === BUTTONS === */
  .btn-primary {
    @apply inline-flex items-center justify-center gap-2 px-6 py-3 font-bold rounded-lg transition-all duration-200 no-underline text-[#0B1628] whitespace-nowrap;
    font-family: 'Sora', sans-serif;
    background: linear-gradient(135deg, #00D4AA 0%, #00B896 100%);
    box-shadow: 0 4px 20px rgba(0, 212, 170, 0.35);
  }
  .btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 28px rgba(0, 212, 170, 0.5);
    background: linear-gradient(135deg, #00E0B4 0%, #00C8A0 100%);
  }

  .btn-secondary {
    @apply inline-flex items-center justify-center gap-2 px-5 py-2.5 font-semibold rounded-lg transition-all duration-200 no-underline;
    font-family: 'Sora', sans-serif;
    border: 1.5px solid #1E3058;
    color: #8BA3C7;
    background: transparent;
  }
  .btn-secondary:hover {
    border-color: #00D4AA;
    color: #00D4AA;
    background: rgba(0, 212, 170, 0.08);
  }

  /* === CARDS === */
  .card {
    background: #112040;
    border: 1px solid #1E3058;
    @apply rounded-xl transition-all duration-200;
  }
  .card:hover {
    border-color: rgba(0, 212, 170, 0.4);
    box-shadow: 0 4px 24px rgba(0, 212, 170, 0.1);
  }

  /* === RANK BADGE === */
  .rank-badge {
    @apply flex-shrink-0 flex items-center justify-center w-8 h-8 rounded-full font-bold text-sm;
  }
  .rank-1 { background: linear-gradient(135deg, #F5C518, #E8A800); color: #0B1628; }
  .rank-2 { background: linear-gradient(135deg, #C0C0C0, #9A9A9A); color: #0B1628; }
  .rank-3 { background: linear-gradient(135deg, #CD7F32, #B06A1F); color: #fff; }
  .rank-other { background: #1E3058; color: #8BA3C7; }

  /* === BADGE === */
  .badge { @apply inline-flex items-center px-2.5 py-0.5 rounded-full text-xs font-semibold; }
  .badge-sga { background: rgba(0,212,170,0.15); color: #00D4AA; border: 1px solid rgba(0,212,170,0.3); }
  .badge-mga { background: rgba(26,115,232,0.15); color: #5BA3F5; border: 1px solid rgba(26,115,232,0.3); }
  .badge-curacao { background: rgba(245,197,24,0.12); color: #F5C518; border: 1px solid rgba(245,197,24,0.3); }
  .badge-pnp { background: rgba(0,212,170,0.1); color: #00D4AA; border: 1px solid rgba(0,212,170,0.25); }
  .badge-hot { background: linear-gradient(135deg,#FF4757,#FF6B35); color: #fff; }

  /* === SECTION === */
  .section { @apply py-14 md:py-20; }
  .container { @apply max-w-[1200px] mx-auto px-4 md:px-6; }

  /* === PROSE === */
  .prose-sv h2 { @apply text-2xl font-bold text-[#F0F4FF] mt-10 mb-4; }
  .prose-sv h3 { @apply text-xl font-semibold text-[#F0F4FF] mt-8 mb-3; }
  .prose-sv p  { @apply text-[#8BA3C7] leading-relaxed mb-4; }
  .prose-sv ul { @apply list-disc list-inside mb-4 space-y-1 text-[#8BA3C7]; }
  .prose-sv strong { @apply text-[#F0F4FF] font-semibold; }
  .prose-sv a { @apply text-[#00D4AA] underline; }

  .prose-sv table { @apply w-full border-collapse mb-6 text-sm; }
  .prose-sv table th { background: #1E3058; @apply text-[#F0F4FF] px-4 py-2 text-left font-semibold; }
  .prose-sv table td { border: 1px solid #1E3058; @apply px-4 py-2 text-[#8BA3C7]; }
  .prose-sv table tr:nth-child(even) td { background: rgba(30,48,88,0.4); }

  /* === GLOW LINE === */
  .glow-divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, #00D4AA, transparent);
  }

  /* === HERO GRADIENT BG === */
  .hero-bg {
    background: radial-gradient(ellipse 80% 60% at 50% -10%, rgba(26,115,232,0.25) 0%, transparent 70%),
                radial-gradient(ellipse 60% 40% at 80% 50%, rgba(0,212,170,0.12) 0%, transparent 60%),
                #080F1E;
  }

  /* === STICKY TOP BAR === */
  .header-bg {
    background: rgba(8,15,30,0.92);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid #1E3058;
  }
}

/* Stars gold */
.star-gold { fill: #F5C518; }
.star-empty { fill: #1E3058; }

/* Details summary arrow */
details > summary { list-style: none; }
details > summary::-webkit-details-marker { display: none; }
