/* Wind Cycling Router - Phase 1: Foundation + Color System */
/* Based on Visual Design Spec v1.0 & UX Spec v1.0 */

/* ========================================
   1. IMPORTS & CSS VARIABLES
   ======================================== */

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

:root {
  /* Brand Colors */
  --brand-orange: #FF6B35;
  --brand-orange-light: #FF8C61;
  --brand-orange-dark: #E85A24;
  --brand-orange-muted: rgba(255, 107, 53, 0.1);
  --brand-slate: #475569;
  --brand-slate-light: #64748B;
  --brand-slate-dark: #334155;
  --brand-gold: #F59E0B;
  --brand-gold-light: #FBBF24;
  --brand-gold-dark: #D97706;

  /* Wind Colors (Colorblind-Safe) */
  --wind-tailwind: #059669;
  --wind-tailwind-light: #34D399;
  --wind-tailwind-bg: #D1FAE5;
  --wind-tailwind-gradient: linear-gradient(90deg, #059669 0%, #10B981 100%);
  --wind-headwind: #DC2626;
  --wind-headwind-light: #F87171;
  --wind-headwind-bg: #FEE2E2;
  --wind-headwind-gradient: linear-gradient(90deg, #DC2626 0%, #EF4444 100%);
  --wind-crosswind: #D97706;
  --wind-crosswind-light: #FBBF24;
  --wind-crosswind-bg: #FEF3C7;
  --wind-crosswind-gradient: linear-gradient(90deg, #D97706 0%, #F59E0B 100%);

  /* Backgrounds */
  --bg-primary: #FAFAF9;
  --bg-secondary: #F5F5F4;
  --bg-tertiary: #E7E5E4;
  --bg-gradient-subtle: linear-gradient(180deg, #FAFAF9 0%, #F5F5F4 100%);
  --bg-gradient-warm: linear-gradient(135deg, #FAFAF9 0%, #FEF3C7 50%, #FAFAF9 100%);

  /* Surfaces */
  --surface-primary: #FFFFFF;
  --surface-secondary: #F9FAFB;
  --surface-elevated: #FFFFFF;

  /* Text */
  --text-primary: #0F172A;
  --text-secondary: #475569;
  --text-muted: #64748B;
  --text-inverse: #F8FAFC;

  /* Borders */
  --border-subtle: #E2E8F0;
  --border-default: #CBD5E1;

  /* Typography */
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', Monaco, monospace;

  /* Spacing Scale (8px base) */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-16: 64px;
  --space-20: 80px;
  --space-24: 96px;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1), 0 2px 4px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1), 0 4px 6px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.1), 0 10px 10px rgba(0, 0, 0, 0.04);

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

  /* Container */
  --container-sm: 640px;
  --container-md: 768px;
  --container-lg: 1024px;
  --container-xl: 1280px;
}

/* ========================================
   DARK MODE VARIABLES
   ======================================== */

[data-theme="dark"] {
  --brand-orange: #FF8C61;
  --brand-orange-light: #FFA885;
  --brand-orange-dark: #FF6B35;
  --brand-orange-muted: rgba(255, 107, 53, 0.15);

  --wind-tailwind: #34D399;
  --wind-tailwind-light: #6EE7B7;
  --wind-tailwind-bg: rgba(5, 150, 105, 0.2);
  --wind-headwind: #F87171;
  --wind-headwind-light: #FCA5A5;
  --wind-headwind-bg: rgba(220, 38, 38, 0.2);
  --wind-crosswind: #FBBF24;
  --wind-crosswind-light: #FCD34D;
  --wind-crosswind-bg: rgba(217, 119, 6, 0.2);

  --bg-primary: #0F172A;
  --bg-secondary: #1E293B;
  --bg-tertiary: #334155;
  --bg-gradient-subtle: linear-gradient(180deg, #0F172A 0%, #1E293B 100%);
  --bg-gradient-warm: linear-gradient(135deg, #0F172A 0%, #1C1917 50%, #0F172A 100%);

  --surface-primary: #1E293B;
  --surface-secondary: #334155;
  --surface-elevated: #334155;

  --text-primary: #F8FAFC;
  --text-secondary: #94A3B8;
  --text-muted: #64748B;
  --text-inverse: #0F172A;

  --border-subtle: #334155;
  --border-default: #475569;
}

/* ========================================
   2. BASE STYLES
   ======================================== */

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-primary);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--bg-gradient-subtle);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ========================================
   3. TYPOGRAPHY
   ======================================== */

h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  line-height: 1.2;
  color: var(--text-primary);
}

h1 {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

h2 {
  font-size: 1.5rem;
  letter-spacing: -0.01em;
}

h3 {
  font-size: 1.25rem;
}

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

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

.font-mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

.label {
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}

/* ========================================
   4. LAYOUT
   ======================================== */

.container {
  width: 100%;
  max-width: var(--container-md);
  margin: 0 auto;
  padding: 0 var(--space-6);
}

@media (min-width: 640px) {
  .container {
    padding: 0 var(--space-8);
  }
}

.page-wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

@media (min-width: 768px) {
  .page-section {
    padding: var(--space-16) 0;
  }
}

/* ========================================
   5. HERO SECTION
   ======================================== */

.hero {
  text-align: center;
  padding: var(--space-12) 0 var(--space-8);
}

.hero-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto var(--space-6);
  background: var(--brand-orange-muted);
  border-radius: var(--radius-xl);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-orange);
}

.hero-title {
  margin-bottom: var(--space-3);
  background: linear-gradient(135deg, var(--text-primary) 0%, var(--brand-slate) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.125rem;
  color: var(--text-secondary);
  max-width: 480px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ========================================
   6. UPLOAD ZONE
   ======================================== */

.upload-zone {
  position: relative;
  padding: var(--space-12) var(--space-8);
  background: var(--surface-primary);
  border: 2px dashed var(--border-default);
  border-radius: var(--radius-lg);
  text-align: center;
  transition: all 0.2s ease;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
}

.upload-zone:hover {
  border-color: var(--brand-orange-light);
  background: var(--brand-orange-muted);
}

.upload-zone--dragover {
  border-color: var(--brand-orange);
  background: var(--brand-orange-muted);
  transform: scale(1.02);
}

.upload-zone--error {
  border-color: var(--wind-headwind);
  background: var(--wind-headwind-bg);
}

.upload-zone--success {
  border-color: var(--wind-tailwind);
  background: var(--wind-tailwind-bg);
}

.upload-zone-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto var(--space-4);
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-slate);
  transition: transform 0.3s ease;
}

.upload-zone:hover .upload-zone-icon {
  transform: translateY(-4px);
}

.upload-zone-text-primary {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-1);
}

.upload-zone-text-secondary {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.upload-zone-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.upload-zone-constraints {
  margin-top: var(--space-4);
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* ========================================
   7. FORM ELEMENTS
   ======================================== */

.form-group {
  margin-bottom: var(--space-6);
}

.form-label {
  display: block;
  margin-bottom: var(--space-2);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-primary);
}

input[type="datetime-local"],
input[type="file"] {
  width: 100%;
  padding: var(--space-3) var(--space-4);
  border: 1.5px solid var(--border-default);
  border-radius: var(--radius-md);
  font-family: var(--font-primary);
  font-size: 0.9375rem;
  color: var(--text-primary);
  background: var(--surface-primary);
  transition: all 0.2s ease;
}

input[type="datetime-local"]:focus,
input[type="file"]:focus {
  outline: none;
  border-color: var(--brand-orange);
  box-shadow: 0 0 0 3px var(--brand-orange-muted);
}

/* Dark mode fix for datetime input */
[data-theme="dark"] input[type="datetime-local"] {
  color-scheme: dark;
}

/* ========================================
   8. BUTTONS
   ======================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  font-family: var(--font-primary);
  font-size: 0.9375rem;
  font-weight: 600;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-primary {
  background: var(--brand-orange);
  color: white;
  box-shadow: 0 1px 2px rgba(255, 107, 53, 0.3), 0 4px 8px rgba(255, 107, 53, 0.2);
}

.btn-primary:hover {
  background: var(--brand-orange-dark);
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(255, 107, 53, 0.3), 0 8px 16px rgba(255, 107, 53, 0.2);
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 1px 2px rgba(255, 107, 53, 0.3);
}

.btn-secondary {
  background: var(--surface-primary);
  color: var(--text-primary);
  border: 1.5px solid var(--border-subtle);
}

.btn-secondary:hover {
  background: var(--bg-secondary);
  border-color: var(--brand-slate-light);
}

.btn-full {
  width: 100%;
}

.btn-lg {
  padding: var(--space-4) var(--space-8);
  font-size: 1rem;
}

.btn-icon {
  padding: var(--space-3);
  background: var(--surface-primary);
  color: var(--text-secondary);
  border: 1.5px solid var(--border-subtle);
  border-radius: var(--radius);
}

.btn-icon:hover {
  background: var(--bg-secondary);
  color: var(--text-primary);
  border-color: var(--brand-orange-light);
}

.btn-link {
  padding: var(--space-2) var(--space-3);
  background: transparent;
  color: var(--brand-orange);
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: var(--radius);
}

.btn-link:hover {
  background: var(--brand-orange-muted);
  color: var(--brand-orange-dark);
}

/* ========================================
   HERO ACTIONS & DEMO ROUTE
   ======================================== */

.hero-actions {
  display: flex;
  justify-content: center;
  margin-top: var(--space-6);
}

.demo-route-container {
  text-align: center;
  margin-top: var(--space-4);
}

/* ========================================
   9. ROUTE PREVIEW
   ======================================== */

.preview-section {
  background: var(--surface-primary);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  box-shadow: var(--shadow-md);
  margin-bottom: 0;
}

.preview-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-6);
}

.preview-title {
  font-size: 1.125rem;
  font-weight: 600;
}

.map-container {
  height: 200px;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-6);
}

.map-placeholder {
  text-align: center;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--space-6);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-4);
  margin-bottom: var(--space-6);
}

@media (max-width: 640px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }
}

.stat-card {
  background: var(--bg-secondary);
  padding: var(--space-4);
  border-radius: var(--radius-md);
  text-align: center;
}

.stat-label {
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: var(--space-1);
}

.stat-value {
  font-family: var(--font-mono);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
}

/* ========================================
   10. PROGRESS STEPPER
   ======================================== */

.progress-section {
  background: var(--surface-primary);
  border-radius: var(--radius-lg);
  padding: var(--space-8) var(--space-6);
  box-shadow: var(--shadow-md);
}

.progress-header {
  text-align: center;
  margin-bottom: var(--space-8);
}

.progress-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: var(--space-2);
}

.progress-subtitle {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.progress-bar-container {
  margin-bottom: var(--space-8);
}

.progress-bar-bg {
  height: 8px;
  background: var(--bg-secondary);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  background: var(--brand-orange-gradient);
  border-radius: var(--radius-full);
  transition: width 0.5s ease;
}

.progress-steps {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  position: relative;
}

.progress-steps::before {
  content: '';
  position: absolute;
  top: 16px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--bg-tertiary);
  z-index: 0;
}

.progress-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  z-index: 1;
  flex: 1;
}

.progress-step-circle {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  background: var(--surface-primary);
  border: 2px solid var(--border-default);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
  transition: all 0.3s ease;
}

.progress-step--active .progress-step-circle {
  border-color: var(--brand-orange);
  background: var(--brand-orange);
  color: white;
  box-shadow: 0 0 0 4px var(--brand-orange-muted);
}

.progress-step--complete .progress-step-circle {
  border-color: var(--wind-tailwind);
  background: var(--wind-tailwind);
  color: white;
}

.progress-step-label {
  margin-top: var(--space-2);
  font-size: 0.75rem;
  font-weight: 500;
  text-align: center;
  color: var(--text-muted);
}

.progress-step--active .progress-step-label {
  color: var(--text-primary);
  font-weight: 600;
}

/* ========================================
   11. RESULTS SECTION
   ======================================== */

.results-section {
  margin: 0;
  padding: 0 !important;
}

.wind-summary {
  background: linear-gradient(135deg, #DBEAFE 0%, #BFDBFE 100%);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  margin: 0 0 var(--space-5) 0;
  text-align: center;
}

.wind-summary-title {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: var(--space-2);
}

.wind-summary-subtitle {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.route-grid {
  display: grid;
  gap: var(--space-5);
}

@media (min-width: 900px) {
  .route-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  }
}

/* ========================================
   12. ROUTE CARDS
   ======================================== */

.route-card {
  background: var(--surface-primary);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  box-shadow: var(--shadow-sm), var(--shadow);
  border: 1px solid var(--border-subtle);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.route-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md), var(--shadow-lg);
}

.route-card--best {
  background: linear-gradient(135deg, var(--surface-primary) 0%, var(--brand-orange-muted) 100%);
  box-shadow: 0 0 0 2px var(--brand-orange), var(--shadow-md), var(--shadow-lg);
}

.route-card-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-3);
  background: var(--brand-orange);
  color: white;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.025em;
  border-radius: var(--radius-full);
}

.route-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: var(--space-4);
  gap: var(--space-4);
}

.route-card-title {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-2);
  flex: 1;
}

.route-card-distance {
  font-family: var(--font-mono);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-secondary);
  white-space: nowrap;
  flex-shrink: 0;
}

.route-card-compass {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-4);
}

.compass-icon {
  width: 40px;
  height: 40px;
  position: relative;
  flex-shrink: 0;
}

.compass-arrow {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 3px;
  height: 16px;
  background: var(--brand-slate);
  transform-origin: center bottom;
  border-radius: 2px;
  transform: translate(-50%, -100%) rotate(var(--wind-degrees, 0deg));
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.compass-arrow::after {
  content: '';
  position: absolute;
  top: -6px;
  left: 50%;
  transform: translateX(-50%);
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-bottom: 8px solid var(--brand-orange);
}

.compass-label {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.compass-direction {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1rem;
  color: var(--text-primary);
}

/* ========================================
   13. WIND BARS
   ======================================== */

.wind-bars {
  margin-bottom: var(--space-6);
}

.wind-bar-container {
  margin-bottom: var(--space-4);
}

.wind-bar-container:last-child {
  margin-bottom: 0;
}

.wind-bar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-2);
}

.wind-bar-label {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: 0.875rem;
  font-weight: 500;
}

.wind-bar-value {
  font-family: var(--font-mono);
  font-weight: 600;
  color: var(--text-secondary);
}

.wind-bar {
  height: 32px;
  background: var(--bg-secondary);
  border-radius: var(--radius-full);
  overflow: hidden;
  position: relative;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.05);
}

.wind-bar-fill {
  height: 100%;
  border-radius: var(--radius-full);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: var(--space-3);
  transition: width 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
  background-size: 200% 100%;
  animation: shimmer 2s ease-in-out infinite;
}

.wind-bar-fill--tailwind {
  background: var(--wind-tailwind-gradient);
  box-shadow: 0 2px 8px rgba(5, 150, 105, 0.3);
}

.wind-bar-fill--headwind {
  background: var(--wind-headwind-gradient);
  box-shadow: 0 2px 8px rgba(220, 38, 38, 0.3);
}

.wind-bar-fill--crosswind {
  background: var(--wind-crosswind-gradient);
  box-shadow: 0 2px 8px rgba(217, 119, 6, 0.3);
}

/* Wind Bar Icons - flat colored squares matching bars */
.wind-icon {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 2px;
  flex-shrink: 0;
}

.wind-icon--tailwind {
  background: var(--wind-tailwind);
}

.wind-icon--headwind {
  background: var(--wind-headwind);
}

.wind-icon--crosswind {
  background: var(--wind-crosswind);
}

.wind-bar-percentage {
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 0.875rem;
  color: white;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

@keyframes shimmer {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

/* ========================================
   14. UTILITIES
   ======================================== */

.hidden {
  display: none !important;
}

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

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

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

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

/* ========================================
   15. ANIMATIONS
   ======================================== */

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

@keyframes cardSlideIn {
  from {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes pulse-ring {
  0%, 100% { box-shadow: 0 0 0 4px var(--brand-orange-muted); }
  50% { box-shadow: 0 0 0 8px rgba(255, 107, 53, 0.05); }
}

@keyframes dropBounce {
  0% { transform: scale(1); }
  40% { transform: scale(1.02); }
  60% { transform: scale(0.98); }
  80% { transform: scale(1.01); }
  100% { transform: scale(1); }
}

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

.animate-card-slide-in {
  animation: cardSlideIn 0.5s ease-out forwards;
}

.animate-drop-bounce {
  animation: dropBounce 0.5s ease-out;
}

/* Staggered delays */
.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }

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

/* ========================================
   16. ERROR STATES
   ======================================== */

.error-banner {
  background: var(--wind-headwind-bg);
  border: 1px solid var(--wind-headwind);
  border-radius: var(--radius-md);
  padding: var(--space-4) var(--space-6);
  margin-bottom: var(--space-6);
}

.error-title {
  font-weight: 600;
  color: var(--wind-headwind);
  margin-bottom: var(--space-2);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.error-message {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

/* ========================================
   17. FOCUS STATES (Accessibility)
   ======================================== */

:focus-visible {
  outline: 3px solid var(--brand-orange-light);
  outline-offset: 2px;
}

button:focus-visible,
.upload-zone:focus {
  transform: translateY(-2px);
  box-shadow: 0 0 0 3px var(--brand-orange-muted);
}
