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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'Satoshi', sans-serif;
  font-weight: 400;
  background-color: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

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

input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
  cursor: pointer;
}

ul, ol {
  list-style: none;
}

/* ===== DESIGN TOKENS ===== */
:root {
  --bg: #050505;
  --bg-elevated: #0D0D0D;
  --bg-card: #0A0A0A;
  --accent: #E8151B;
  --accent-hover: #FF2D33;
  --accent-dim: rgba(232, 21, 27, 0.12);
  --text: #FFFFFF;
  --text-secondary: #CCCCCC;
  --text-muted: #888888;
  --text-dim: #555555;
  --border: rgba(255, 255, 255, 0.08);
  --border-hover: rgba(255, 255, 255, 0.16);
  --border-accent: rgba(232, 21, 27, 0.4);
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
  --transition: all 0.2s ease;
  --transition-slow: all 0.35s ease;
  --max-width: 720px;
  --nav-height: 56px;

  /* Font families */
  --font-body: 'Satoshi', sans-serif;
  --font-heading: 'Playfair Display', serif;
  --font-brand: 'Anton', sans-serif;
}

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

.font-brand {
  font-family: var(--font-brand);
  font-weight: 400;
  text-transform: uppercase;
}

/* ===== LAYOUT ===== */
#app {
  flex: 1;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  padding-top: var(--nav-height);
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
  width: 4px;
}

::-webkit-scrollbar-track {
  background: var(--bg);
}

::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 2px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 255, 255, 0.14);
}

/* ===== SELECTION ===== */
::selection {
  background: var(--accent);
  color: var(--text);
}

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

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.96);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

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

.animate-fade-in {
  animation: fadeIn 0.4s ease forwards;
}

/* Stagger children */
.stagger-children > * {
  opacity: 0;
  animation: fadeInUp 0.4s ease forwards;
}
.stagger-children > *:nth-child(1) { animation-delay: 0.05s; }
.stagger-children > *:nth-child(2) { animation-delay: 0.10s; }
.stagger-children > *:nth-child(3) { animation-delay: 0.15s; }
.stagger-children > *:nth-child(4) { animation-delay: 0.20s; }
.stagger-children > *:nth-child(5) { animation-delay: 0.25s; }
.stagger-children > *:nth-child(6) { animation-delay: 0.30s; }
.stagger-children > *:nth-child(7) { animation-delay: 0.35s; }
.stagger-children > *:nth-child(8) { animation-delay: 0.40s; }
.stagger-children > *:nth-child(9) { animation-delay: 0.45s; }
.stagger-children > *:nth-child(10) { animation-delay: 0.50s; }

/* ===== LOADING & ERROR STATES ===== */
.loading {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 40vh;
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--text-muted);
  letter-spacing: 0.03em;
}

.error-state {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 40vh;
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--accent);
  letter-spacing: 0.03em;
}

/* ===== RESPONSIVE UTILS ===== */
@media (max-width: 600px) {
  #app {
    padding: 0 16px;
    padding-top: var(--nav-height);
  }
}
