/* =============================================
   GDPR Request Handler — Global Styles
   Variables, Reset, Typography, Accessibility, Scrollbar
   ============================================= */

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

/* ----------- CSS Variables ----------- */
:root {
  --bg: #0d1117;
  --surface: #161b22;
  --surface2: #1c2128;
  --surface3: #262c34;
  --border: #30363d;
  --accent: #58a6ff;
  --accent-bright: #79c0ff;
  --accent2: #9d7ead;
  --warning: #f0883e;
  --danger: #f85149;
  --success: #3fb950;
  --text: #f0f6fc;
  --text-secondary: #c9d1d9;
  --muted: #8b949e;
  --stone-light: #30363d;
  --stone-mid: #21262d;
  --stone-dark: #0d1117;
  --mono: 'IBM Plex Mono', monospace;
  --sans: 'IBM Plex Sans', sans-serif;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.3);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.5);
  --shadow-xl: 0 12px 32px rgba(0,0,0,0.6);
  --glow-accent: 0 0 12px rgba(88,166,255,0.15);
  --accent-aaa: #79c0ff;
  --warning-aaa: #ffa94d;
  --danger-aaa: #ff8383;
  --success-aaa: #69db7c;
}

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

/* =============================================
   WCAG AAA ACCESSIBILITY
   ============================================= */

/* Skip to main content link (visible on focus) */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--accent);
  color: var(--bg);
  padding: 8px 16px;
  text-decoration: none;
  z-index: 100;
  font-weight: 600;
}

.skip-link:focus {
  top: 0;
}

/* Focus styles - visible outline for keyboard navigation */
*:focus-visible {
  outline: 3px solid var(--accent-bright);
  outline-offset: 2px;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--accent-bright);
  outline-offset: 2px;
  border-radius: 4px;
}

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

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
}

/* ----------- Grid Background ----------- */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(88,166,255,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(88,166,255,0.04) 1px, transparent 1px),
    linear-gradient(135deg, rgba(88,166,255,0.01) 1px, transparent 1px),
    linear-gradient(45deg, rgba(88,166,255,0.01) 1px, transparent 1px);
  background-size: 50px 50px, 50px 50px, 70px 70px, 70px 70px;
  pointer-events: none;
  z-index: 0;
}

/* =============================================
   SCROLLBAR
   ============================================= */
::-webkit-scrollbar        { width: 5px; height: 5px; }
::-webkit-scrollbar-track  { background: transparent; }
::-webkit-scrollbar-thumb  { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--muted); }

/* =============================================
   FORM ACCESSIBILITY
   ============================================= */
fieldset {
  border: none !important;
  padding: 0 !important;
  margin: 0 !important;
}

legend {
  display: block;
  width: 100%;
  padding: 0 !important;
  margin-bottom: 8px !important;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--accent-bright);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 600;
}

/* Required field indicator (text-only, not just asterisk) */
.form-required::after {
  content: ' (required)';
  color: var(--danger-aaa);
  font-weight: 600;
}
