/* 
========================================
   1. VARIABLES & TOKENS
========================================
*/
:root {
  /* Brand Colors: Graphite Black, Industrial Yellow, Navy Blue */
  --color-bg: #121214;
  --color-surface: #1c1c1f;
  --color-surface-hover: #27272a;
  
  --color-primary: #FFD60A; /* Industrial Yellow */
  --color-primary-hover: #E5C009;
  --color-primary-text: #121214;

  --color-secondary: #0F1C3F; /* Navy Blue */
  --color-secondary-hover: #16295A;
  --color-secondary-text: #FFFFFF;

  /* Typography Colors */
  --color-text: #F4F4F5;
  --color-text-muted: #A1A1AA;
  --color-border: #3F3F46;

  /* Functional Colors */
  --color-success: #10B981;
  --color-warning: #F59E0B;
  --color-danger: #EF4444;

  /* Typography */
  --font-family-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-family-mono: ui-monospace, SFMono-Regular, Consolas, monospace;
  
  --fs-xs: 0.75rem;
  --fs-sm: 0.875rem;
  --fs-base: 1rem;
  --fs-lg: 1.125rem;
  --fs-xl: 1.25rem;
  --fs-2xl: 1.5rem;
  --fs-3xl: 1.875rem;
  --fs-4xl: 2.25rem;

  --lh-tight: 1.1;
  --lh-normal: 1.5;
  --lh-relaxed: 1.625;

  /* Spacing Scale */
  --space-1: 0.25rem;  /* 4px */
  --space-2: 0.5rem;   /* 8px */
  --space-3: 0.75rem;  /* 12px */
  --space-4: 1rem;     /* 16px */
  --space-6: 1.5rem;   /* 24px */
  --space-8: 2rem;     /* 32px */
  --space-12: 3rem;    /* 48px */
  --space-16: 4rem;    /* 64px */
  --space-24: 6rem;    /* 96px */

  /* UI Elements */
  --radius-sm: 2px;    /* Industrial/Sharp feel */
  --radius-md: 4px;
  --radius-lg: 8px;
  --radius-full: 9999px;

  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.5);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.5), 0 2px 4px -2px rgb(0 0 0 / 0.5);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.5), 0 4px 6px -4px rgb(0 0 0 / 0.5);

  --transition-base: 0.2s ease-in-out;
}

/* 
========================================
   2. RESET & NORMALIZE
========================================
*/
*, *::before, *::after {
  box-sizing: border-box;
}

* {
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  line-height: var(--lh-normal);
  -webkit-font-smoothing: antialiased;
}

img, picture, video, canvas, svg {
  display: block;
  max-width: 100%;
}

input, button, textarea, select {
  font: inherit;
}

/* 
========================================
   3. BASE STYLES
========================================
*/
body {
  font-family: var(--font-family-sans);
  background-color: var(--color-bg);
  color: var(--color-text);
  font-size: var(--fs-base);
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: var(--lh-tight);
  margin-bottom: var(--space-4);
  color: #FFFFFF;
  letter-spacing: -0.025em;
}

h1 { font-size: var(--fs-4xl); }
h2 { font-size: var(--fs-3xl); }
h3 { font-size: var(--fs-2xl); }
h4 { font-size: var(--fs-xl); }

p {
  margin-bottom: var(--space-4);
  color: var(--color-text-muted);
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-base);
}

a:hover {
  color: var(--color-primary-hover);
  text-decoration: underline;
}

ul, ol {
  list-style-position: inside;
  margin-bottom: var(--space-4);
}

/* 
========================================
   4. UTILITIES
========================================
*/
.container {
  width: 100%;
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--space-4);
  padding-right: var(--space-4);
}

.flex {
  display: flex;
}

.grid {
  display: grid;
}

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

.justify-between {
  justify-content: space-between;
}

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

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

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

/* Screen Reader Only */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* 
========================================
   5. COMPONENTS
========================================
*/

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-3) var(--space-6);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: all var(--transition-base);
  text-decoration: none;
  font-size: var(--fs-sm);
}

.btn-primary {
  background-color: var(--color-primary);
  color: var(--color-primary-text)!important;
}

.btn-primary:hover {
  background-color: var(--color-primary-hover);
  transform: translateY(-1px);
}

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

.btn-secondary:hover {
  background-color: var(--color-secondary-hover);
  transform: translateY(-1px);
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* Form Inputs */
.form-control {
  display: block;
  width: 100%;
  padding: var(--space-3) var(--space-4);
  font-size: var(--fs-base);
  line-height: 1.5;
  color: var(--color-text);
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  transition: border-color var(--transition-base), box-shadow var(--transition-base);
}

.form-control:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 2px rgba(255, 214, 10, 0.2);
}

.form-label {
  display: block;
  margin-bottom: var(--space-2);
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--color-text-muted);
}

/* Cards */
.card {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-6);
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* 
========================================
   6. ACCESSIBILITY
========================================
*/
:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

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