/* ============================================
   Wynncraft Dashboard - Main Styles
   Dark Fantasy Theme with Gold Accents
   ============================================ */

/* ============================================
   CSS Custom Properties (Design Tokens)
   ============================================ */
:root {
  /* Background Colors - Dark Fantasy */
  --bg-primary: #0a0e1a;
  --bg-secondary: #1a1f2e;
  --bg-card: rgba(26, 31, 46, 0.8);
  --bg-card-hover: rgba(26, 31, 46, 0.95);

  /* Gold/Amber Accents - Wynncraft Signature */
  --gold-primary: #d4af37;
  --gold-accent: #fbbf24;
  --gold-dark: #b8941f;

  /* Text Colors */
  --text-primary: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;

  /* Game Element Colors */
  --success-green: #22c55e;
  --danger-red: #ef4444;
  --info-blue: #3b82f6;
  --legendary-purple: #a855f7;
  --mythic-pink: #ec4899;

  /* Glow Effects */
  --glow-gold: 0 0 20px rgba(212, 175, 55, 0.5);
  --glow-purple: 0 0 20px rgba(168, 85, 247, 0.5);
  --glow-blue: 0 0 20px rgba(59, 130, 246, 0.5);

  /* Font Sizes */
  --font-xs: 0.75rem;
  --font-sm: 0.875rem;
  --font-base: 1rem;
  --font-lg: 1.125rem;
  --font-xl: 1.25rem;
  --font-2xl: 1.5rem;
  --font-3xl: 1.875rem;
  --font-4xl: 2.25rem;
  --font-5xl: 3rem;

  /* Font Weights */
  --font-normal: 400;
  --font-medium: 500;
  --font-semibold: 600;
  --font-bold: 700;
  --font-extrabold: 800;

  /* Spacing */
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 32px;
  --space-6: 48px;
  --space-8: 64px;
  --space-12: 96px;

  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.6);
  --shadow-gold: 0 0 30px rgba(212, 175, 55, 0.3);

  /* Transitions */
  --duration-fast: 150ms;
  --duration-normal: 300ms;
  --duration-slow: 500ms;
  --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================
   Reset & Base Styles
   ============================================ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
}

/* Background gradient */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg,
      var(--bg-primary) 0%,
      var(--bg-secondary) 50%,
      #1e293b 100%);
  z-index: -1;
}

/* ============================================
   Typography
   ============================================ */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Cinzel', serif;
  font-weight: var(--font-bold);
  line-height: 1.2;
  color: var(--text-primary);
}

h1 {
  font-size: var(--font-5xl);
  margin-bottom: var(--space-4);
}

h2 {
  font-size: var(--font-4xl);
  margin-bottom: var(--space-3);
}

h3 {
  font-size: var(--font-3xl);
  margin-bottom: var(--space-3);
}

h4 {
  font-size: var(--font-2xl);
  margin-bottom: var(--space-2);
}

p {
  margin-bottom: var(--space-2);
  color: var(--text-secondary);
}

a {
  color: var(--gold-accent);
  text-decoration: none;
  transition: color var(--duration-normal) var(--ease-in-out);
}

a:hover {
  color: var(--gold-primary);
}

/* ============================================
   Layout
   ============================================ */
.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--space-4);
}

.section {
  padding: var(--space-8) 0;
}

/* Grid System */
.grid {
  display: grid;
  gap: var(--space-4);
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.grid-4 {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

/* Flex Utilities */
.flex {
  display: flex;
}

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

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

.flex-col {
  display: flex;
  flex-direction: column;
}

.gap-1 {
  gap: var(--space-1);
}

.gap-2 {
  gap: var(--space-2);
}

.gap-3 {
  gap: var(--space-3);
}

.gap-4 {
  gap: var(--space-4);
}

/* ============================================
   Header & Navigation
   ============================================ */
.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid rgba(212, 175, 55, 0.2);
  box-shadow: var(--shadow-md);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-2) 0;
}

.logo {
  font-family: 'Cinzel', serif;
  font-size: var(--font-2xl);
  font-weight: var(--font-extrabold);
  background: linear-gradient(135deg, var(--gold-primary), var(--gold-accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: var(--glow-gold);
}

.nav-links {
  display: flex;
  gap: var(--space-4);
  list-style: none;
}

.nav-links a {
  color: var(--text-secondary);
  font-weight: var(--font-medium);
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-sm);
  transition: all var(--duration-normal) var(--ease-in-out);
}

.nav-links a:hover {
  color: var(--gold-accent);
  background: rgba(212, 175, 55, 0.1);
}

/* Language Switcher */
header .nav .language-switcher {
  margin-left: auto;
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
}

header .nav .language-switcher select.lang-select {
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  background: rgba(26, 31, 46, 0.95) !important;
  color: #d4af37 !important;
  border: 1px solid #d4af37 !important;
  border-radius: 4px !important;
  padding: 8px 32px 8px 12px !important;
  font-family: 'Cinzel', serif !important;
  font-size: 0.85rem !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  transition: all 0.3s ease !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23d4af37' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 10px center !important;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5) !important;
}

header .nav .language-switcher select.lang-select:hover {
  background-color: rgba(34, 40, 58, 1) !important;
  box-shadow: 0 0 20px rgba(212, 175, 55, 0.4) !important;
  border-color: #f1c40f !important;
}

header .nav .language-switcher select.lang-select:focus {
  outline: none !important;
  border-color: #f1c40f !important;
}

header .nav .language-switcher .lang-label {
  font-size: 0.8rem !important;
  color: rgba(255, 255, 255, 0.6) !important;
  text-transform: uppercase !important;
  letter-spacing: 1px !important;
  font-family: 'Inter', sans-serif !important;
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
  position: relative;
  padding: var(--space-12) 0;
  text-align: center;
  overflow: hidden;
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero h1 {
  font-size: clamp(2rem, 5vw, var(--font-5xl));
  background: linear-gradient(135deg, var(--gold-primary), var(--gold-accent), var(--text-primary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: var(--space-3);
}

.hero p {
  font-size: var(--font-xl);
  color: var(--text-secondary);
  margin-bottom: var(--space-6);
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* Particle canvas background */
#particles-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  opacity: 0.6;
}

/* ============================================
   Stats Display
   ============================================ */
.stats-container {
  display: flex;
  justify-content: center;
  gap: var(--space-6);
  margin-top: var(--space-6);
  flex-wrap: wrap;
}

.stat-item {
  text-align: center;
}

.stat-value {
  font-family: 'Orbitron', monospace;
  font-size: var(--font-4xl);
  font-weight: var(--font-bold);
  color: var(--gold-accent);
  text-shadow: var(--glow-gold);
  display: block;
  margin-bottom: var(--space-1);
}

.stat-label {
  font-size: var(--font-sm);
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 768px) {
  .nav-links {
    gap: var(--space-2);
  }

  .hero {
    padding: var(--space-8) 0;
  }

  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }

  .stats-container {
    gap: var(--space-3);
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 var(--space-2);
  }

  .logo {
    font-size: var(--font-xl);
  }

  .nav-links {
    font-size: var(--font-sm);
  }
}

/* ============================================
   Utility Classes
   ============================================ */
.text-center {
  text-align: center;
}

.text-left {
  text-align: left;
}

.text-right {
  text-align: right;
}

.text-gold {
  color: var(--gold-accent);
}

.text-muted {
  color: var(--text-muted);
}

.text-success {
  color: var(--success-green);
}

.text-danger {
  color: var(--danger-red);
}

.mt-1 {
  margin-top: var(--space-1);
}

.mt-2 {
  margin-top: var(--space-2);
}

.mt-3 {
  margin-top: var(--space-3);
}

.mt-4 {
  margin-top: var(--space-4);
}

.mb-1 {
  margin-bottom: var(--space-1);
}

.mb-2 {
  margin-bottom: var(--space-2);
}

.mb-3 {
  margin-bottom: var(--space-3);
}

.mb-4 {
  margin-bottom: var(--space-4);
}

.text-xs {
  font-size: var(--font-xs);
}

.text-sm {
  font-size: var(--font-sm);
}

.text-lg {
  font-size: var(--font-lg);
}

.text-xl {
  font-size: var(--font-xl);
}

.text-2xl {
  font-size: var(--font-2xl);
}

.text-3xl {
  font-size: var(--font-3xl);
}

.font-bold {
  font-weight: var(--font-bold);
}

.font-semibold {
  font-weight: var(--font-semibold);
}

.items-center {
  align-items: center;
}

.flex-1 {
  flex: 1;
}

.space-y-3>*+* {
  margin-top: var(--space-3);
}

.btn-sm {
  padding: 8px 16px;
  font-size: var(--font-sm);
}

.hidden {
  display: none;
}