/**
 * GRENKE Adviser v2.0 - Design Tokens
 * Dark Finance Theme
 */

@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=Fira+Sans:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  /* ═══════════════════════════════════════════════════════════
     TYPOGRAPHIE
     ═══════════════════════════════════════════════════════════ */
  --font-primary: 'Fira Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-heading: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'Courier New', monospace;

  /* ═══════════════════════════════════════════════════════════
     COULEURS - BACKGROUNDS
     ═══════════════════════════════════════════════════════════ */
  --bg-primary: #0a0e1a;           /* Bleu nuit profond */
  --bg-secondary: #12182b;         /* Bleu nuit moyen */
  --bg-card: #1a2332;              /* Cards */
  --bg-hover: #232d42;             /* Hover states */
  --bg-input: #0f1521;             /* Input fields */

  /* ═══════════════════════════════════════════════════════════
     COULEURS - ACCENTS
     ═══════════════════════════════════════════════════════════ */
  --accent-cyan: #00d4ff;          /* Cyan électrique (primary) */
  --accent-green: #00ff88;         /* Vert success */
  --accent-red: #ff3366;           /* Rouge error */
  --accent-orange: #ffaa00;        /* Orange warning */
  --accent-purple: #b84eff;        /* Purple (alt) */

  /* ═══════════════════════════════════════════════════════════
     COULEURS - TEXTE
     ═══════════════════════════════════════════════════════════ */
  --text-primary: #e8edf5;         /* Blanc cassé */
  --text-secondary: #8b9bb3;       /* Gris bleu */
  --text-muted: #5a6b84;           /* Gris foncé */
  --text-disabled: #3a4a64;        /* Gris très foncé */

  /* ═══════════════════════════════════════════════════════════
     COULEURS - BORDURES
     ═══════════════════════════════════════════════════════════ */
  --border-default: #2a3a52;
  --border-focus: var(--accent-cyan);
  --border-error: var(--accent-red);

  /* ═══════════════════════════════════════════════════════════
     SHADOWS & GLOWS
     ═══════════════════════════════════════════════════════════ */
  --shadow-sm: 0 2px 8px rgba(0, 212, 255, 0.1);
  --shadow-md: 0 4px 16px rgba(0, 212, 255, 0.15);
  --shadow-lg: 0 8px 24px rgba(0, 212, 255, 0.2);
  --shadow-glow: 0 0 20px rgba(0, 212, 255, 0.3);
  --shadow-glow-green: 0 0 20px rgba(0, 255, 136, 0.3);
  --shadow-glow-red: 0 0 20px rgba(255, 51, 102, 0.3);

  /* ═══════════════════════════════════════════════════════════
     SPACING
     ═══════════════════════════════════════════════════════════ */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-2xl: 48px;
  --space-3xl: 64px;

  /* ═══════════════════════════════════════════════════════════
     BORDER RADIUS
     ═══════════════════════════════════════════════════════════ */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-full: 9999px;

  /* ═══════════════════════════════════════════════════════════
     TRANSITIONS
     ═══════════════════════════════════════════════════════════ */
  --transition-fast: 0.15s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.6s ease;

  /* ═══════════════════════════════════════════════════════════
     Z-INDEX LAYERS
     ═══════════════════════════════════════════════════════════ */
  --z-base: 1;
  --z-dropdown: 10;
  --z-sticky: 100;
  --z-navbar: 1000;
  --z-modal: 2000;
  --z-toast: 3000;
}

/* ═══════════════════════════════════════════════════════════
   GLOBAL RESET & BASE
   ═══════════════════════════════════════════════════════════ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 14px;
}

body {
  font-family: var(--font-primary);
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--bg-primary);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  /* Mesh Gradient Background */
  background-image:
    radial-gradient(circle at 20% 30%, rgba(0, 212, 255, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(0, 255, 136, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 40% 80%, rgba(255, 170, 0, 0.05) 0%, transparent 50%);

  /* Subtle Grid Pattern */
  background-attachment: fixed;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image:
    linear-gradient(rgba(42, 58, 82, 0.15) 1px, transparent 1px),
    linear-gradient(90deg, rgba(42, 58, 82, 0.15) 1px, transparent 1px);
  background-size: 50px 50px;
  pointer-events: none;
  z-index: 0;
}

/* ═══════════════════════════════════════════════════════════
   TYPOGRAPHY
   ═══════════════════════════════════════════════════════════ */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--text-primary);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }
h5 { font-size: 1.125rem; }
h6 { font-size: 1rem; }

p {
  margin-bottom: var(--space-md);
}

a {
  color: var(--accent-cyan);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--accent-green);
}

/* ═══════════════════════════════════════════════════════════
   UTILITY CLASSES
   ═══════════════════════════════════════════════════════════ */
.hidden {
  display: none !important;
}

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

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

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

/* ═══════════════════════════════════════════════════════════
   ANIMATIONS
   ═══════════════════════════════════════════════════════════ */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

@keyframes shimmer {
  0% {
    background-position: -1000px 0;
  }
  100% {
    background-position: 1000px 0;
  }
}

.fade-in-up {
  animation: fadeInUp 0.6s ease-out forwards;
}

.fade-in-up-delay-1 { animation-delay: 0.1s; }
.fade-in-up-delay-2 { animation-delay: 0.2s; }
.fade-in-up-delay-3 { animation-delay: 0.3s; }
.fade-in-up-delay-4 { animation-delay: 0.4s; }
