/* ==========================================================================
   Hook IT — Designsysteem
   Donker, glas, aurora-achtergrond
   Fonts: Space Grotesk (headings), Inter (body), JetBrains Mono (code)
   ========================================================================== */

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

:root {
  /* Kleuren */
  --bg:        #0a0a0f;
  --surface:   #12121a;
  --border:    rgba(255, 255, 255, 0.08);
  --text:      #e4e4e7;
  --text-muted:#9ca3af;
  --text-dim:  #6b7280;

  /* Merk & accent */
  --brand:     #6366f1;
  --brand-light:#818cf8;
  --brand-dim: rgba(99, 102, 241, 0.15);

  /* Statuskleuren */
  --pass:      #22c55e;
  --pass-dim:  rgba(34, 197, 94, 0.15);
  --warn:      #f59e0b;
  --warn-dim:  rgba(245, 158, 11, 0.15);
  --fail:      #ef4444;
  --fail-dim:  rgba(239, 68, 68, 0.15);

  /* Glas */
  --glass-bg:  rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.08);
  --glass-blur: 16px;

  /* Typografie */
  --font-heading: 'Space Grotesk', system-ui, sans-serif;
  --font-body:    'Inter', system-ui, sans-serif;
  --font-mono:    'JetBrains Mono', monospace;

  /* Spacing */
  --space-xs:  0.25rem;
  --space-sm:  0.5rem;
  --space-md:  1rem;
  --space-lg:  1.5rem;
  --space-xl:  2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;

  /* Radii */
  --radius-sm: 0.375rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;

  /* Schaduwen */
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.5);

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
}

/* Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  font-family: var(--font-body);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

/* Aurora achtergrond */
.aurora {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.aurora::before,
.aurora::after {
  content: '';
  position: absolute;
  width: 60vw;
  height: 60vw;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.3;
  animation: aurora-drift 20s ease-in-out infinite alternate;
}

.aurora::before {
  background: radial-gradient(circle, #6366f1 0%, transparent 70%);
  top: -20%;
  left: -10%;
}

.aurora::after {
  background: radial-gradient(circle, #8b5cf6 0%, transparent 70%);
  bottom: -20%;
  right: -10%;
  animation-delay: -10s;
}

@keyframes aurora-drift {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(5vw, 3vh) scale(1.1); }
}

/* Glasmorfisme */
.glass {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  box-shadow: var(--shadow-md);
}

/* Typografie helpers */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.2;
}

a {
  color: var(--brand-light);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover { color: var(--brand); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-lg);
  border: none;
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-decoration: none;
}

.btn-primary {
  background: var(--brand);
  color: #fff;
}

.btn-primary:hover {
  background: var(--brand-light);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.3);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  background: rgba(255,255,255,0.05);
  border-color: var(--brand);
}

/* Focus zichtbaar */
:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

/* ==========================================================================
   Light mode
   Geactiveerd via data-theme="light" op <html>, of via prefers-color-scheme
   als de gebruiker geen expliciete keuze heeft gemaakt.
   ========================================================================== */

[data-theme="light"] {
  --bg:        #f8f9fb;
  --surface:   #ffffff;
  --border:    rgba(0, 0, 0, 0.08);
  --text:      #1a1a2e;
  --text-muted:#4b5563;
  --text-dim:  #6b7280;

  --brand:     #4f46e5;
  --brand-light:#6366f1;
  --brand-dim: rgba(79, 70, 229, 0.1);

  --pass:      #16a34a;
  --pass-dim:  rgba(22, 163, 74, 0.1);
  --warn:      #d97706;
  --warn-dim:  rgba(217, 119, 6, 0.1);
  --fail:      #dc2626;
  --fail-dim:  rgba(220, 38, 38, 0.1);

  --glass-bg:  rgba(255, 255, 255, 0.7);
  --glass-border: rgba(0, 0, 0, 0.08);
  --glass-blur: 12px;

  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.12);
}

/* Auto light mode als gebruiker geen keuze heeft gemaakt */
@media (prefers-color-scheme: light) {
  html:not([data-theme]) {
    --bg:        #f8f9fb;
    --surface:   #ffffff;
    --border:    rgba(0, 0, 0, 0.08);
    --text:      #1a1a2e;
    --text-muted:#4b5563;
    --text-dim:  #6b7280;

    --brand:     #4f46e5;
    --brand-light:#6366f1;
    --brand-dim: rgba(79, 70, 229, 0.1);

    --pass:      #16a34a;
    --pass-dim:  rgba(22, 163, 74, 0.1);
    --warn:      #d97706;
    --warn-dim:  rgba(217, 119, 6, 0.1);
    --fail:      #dc2626;
    --fail-dim:  rgba(220, 38, 38, 0.1);

    --glass-bg:  rgba(255, 255, 255, 0.7);
    --glass-border: rgba(0, 0, 0, 0.08);
    --glass-blur: 12px;

    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
    --shadow-lg: 0 8px 32px rgba(0,0,0,0.12);
  }
}

/* Aurora onzichtbaar in light mode */
[data-theme="light"] .aurora::before,
[data-theme="light"] .aurora::after {
  opacity: 0.06;
}

@media (prefers-color-scheme: light) {
  html:not([data-theme]) .aurora::before,
  html:not([data-theme]) .aurora::after {
    opacity: 0.06;
  }
}

/* Ghost button kleuraanpassing voor light */
[data-theme="light"] .btn-ghost:hover {
  background: rgba(0, 0, 0, 0.04);
}

@media (prefers-color-scheme: light) {
  html:not([data-theme]) .btn-ghost:hover {
    background: rgba(0, 0, 0, 0.04);
  }
}

/* Thema-toggle knop */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
  font-size: 1.1rem;
  line-height: 1;
}

.theme-toggle:hover {
  background: var(--brand-dim);
  color: var(--brand-light);
  border-color: var(--brand);
}

/* Icoon wisselen op basis van thema */
.theme-toggle__icon--light { display: none; }
.theme-toggle__icon--dark  { display: inline; }

[data-theme="light"] .theme-toggle__icon--light { display: inline; }
[data-theme="light"] .theme-toggle__icon--dark  { display: none; }

@media (prefers-color-scheme: light) {
  html:not([data-theme]) .theme-toggle__icon--light { display: inline; }
  html:not([data-theme]) .theme-toggle__icon--dark  { display: none; }
}

/* Prefers reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
