/* ============================================
   BANDFORGE — Global Design System
   ============================================ */

/* ---------- Google Fonts ---------- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Outfit:wght@300;400;500;600;700;800;900&family=Space+Grotesk:wght@300;400;500;600;700&display=swap');

/* ---------- CSS Custom Properties ---------- */
:root {
  /* Brand Colors */
  --brand-primary: #6C5CE7;
  --brand-primary-light: #A29BFE;
  --brand-primary-dark: #4834D4;
  --brand-accent: #FF6B6B;
  --brand-accent-light: #FF8E8E;
  --brand-accent-dark: #EE5A24;
  --brand-secondary: #00D2D3;
  --brand-secondary-light: #55E6C1;

  /* Neutrals */
  --neutral-50: #FAFBFF;
  --neutral-100: #F0F1F8;
  --neutral-200: #E2E4F0;
  --neutral-300: #C8CBD9;
  --neutral-400: #9CA0B3;
  --neutral-500: #6E7291;
  --neutral-600: #4A4E6A;
  --neutral-700: #2D3154;
  --neutral-800: #1A1D3B;
  --neutral-900: #0D0F24;
  --neutral-950: #070815;

  /* Backgrounds */
  --bg-primary: var(--neutral-950);
  --bg-secondary: var(--neutral-900);
  --bg-card: rgba(26, 29, 59, 0.6);
  --bg-card-hover: rgba(36, 39, 69, 0.8);
  --bg-glass: rgba(108, 92, 231, 0.08);
  --bg-glass-border: rgba(108, 92, 231, 0.15);

  /* Text */
  --text-primary: #F0F1F8;
  --text-secondary: #9CA0B3;
  --text-muted: #6E7291;
  --text-accent: var(--brand-primary-light);

  /* Gradients */
  --gradient-primary: linear-gradient(135deg, #6C5CE7 0%, #A29BFE 50%, #00D2D3 100%);
  --gradient-accent: linear-gradient(135deg, #FF6B6B 0%, #FF8E8E 50%, #FFD93D 100%);
  --gradient-dark: linear-gradient(180deg, #0D0F24 0%, #1A1D3B 100%);
  --gradient-hero: radial-gradient(ellipse at 30% 0%, rgba(108, 92, 231, 0.15) 0%, transparent 60%),
                   radial-gradient(ellipse at 70% 100%, rgba(0, 210, 211, 0.1) 0%, transparent 50%);
  --gradient-card: linear-gradient(145deg, rgba(108, 92, 231, 0.05) 0%, rgba(0, 210, 211, 0.03) 100%);

  /* Typography */
  --font-display: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'Space Grotesk', monospace;

  /* Font Sizes — Fluid */
  --text-xs: clamp(0.7rem, 0.65rem + 0.25vw, 0.8rem);
  --text-sm: clamp(0.8rem, 0.75rem + 0.25vw, 0.9rem);
  --text-base: clamp(0.95rem, 0.9rem + 0.25vw, 1.05rem);
  --text-lg: clamp(1.1rem, 1rem + 0.5vw, 1.25rem);
  --text-xl: clamp(1.25rem, 1.1rem + 0.75vw, 1.5rem);
  --text-2xl: clamp(1.5rem, 1.2rem + 1.5vw, 2rem);
  --text-3xl: clamp(1.8rem, 1.4rem + 2vw, 2.5rem);
  --text-4xl: clamp(2.2rem, 1.6rem + 3vw, 3.5rem);
  --text-5xl: clamp(2.8rem, 2rem + 4vw, 4.5rem);
  --text-6xl: clamp(3.5rem, 2.5rem + 5vw, 6rem);

  /* 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;
  --space-4xl: 6rem;
  --space-5xl: 8rem;

  /* Border Radius */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-2xl: 32px;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.15);
  --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.25);
  --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.35);
  --shadow-xl: 0 16px 60px rgba(0, 0, 0, 0.45);
  --shadow-glow: 0 0 30px rgba(108, 92, 231, 0.3);
  --shadow-glow-accent: 0 0 30px rgba(255, 107, 107, 0.25);

  /* Transitions */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --duration-fast: 150ms;
  --duration-normal: 300ms;
  --duration-slow: 500ms;

  /* Z-index */
  --z-behind: -1;
  --z-base: 0;
  --z-dropdown: 100;
  --z-sticky: 200;
  --z-fixed: 300;
  --z-modal: 400;
  --z-toast: 500;
}

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

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

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.7;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  overflow-x: hidden;
}

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

img, video {
  max-width: 100%;
  height: auto;
  display: block;
}

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

ul, ol {
  list-style: none;
}

input, textarea, select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
  background: none;
  border: none;
  outline: none;
}

/* ---------- Utility Classes ---------- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-xl);
}

.container--wide {
  max-width: 1400px;
}

.container--narrow {
  max-width: 800px;
}

.section {
  padding: var(--space-5xl) 0;
  position: relative;
}

.section--tight {
  padding: var(--space-4xl) 0;
}

/* ---------- Typography ---------- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.gradient-text {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.text-accent {
  color: var(--brand-accent);
}

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

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: 14px 32px;
  font-family: var(--font-display);
  font-size: var(--text-base);
  font-weight: 600;
  border-radius: var(--radius-full);
  transition: all var(--duration-normal) var(--ease-out);
  position: relative;
  overflow: hidden;
  white-space: nowrap;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  opacity: 0;
  transition: opacity var(--duration-normal) var(--ease-out);
}

.btn:hover::before {
  opacity: 1;
}

.btn--primary {
  background: var(--gradient-primary);
  color: white;
  box-shadow: var(--shadow-glow);
}

.btn--primary::before {
  background: linear-gradient(135deg, #7B6CF0 0%, #B0ABFE 50%, #1DE2E3 100%);
}

.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 40px rgba(108, 92, 231, 0.5);
}

.btn--secondary {
  background: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid var(--bg-glass-border);
  backdrop-filter: blur(10px);
}

.btn--secondary:hover {
  border-color: var(--brand-primary);
  background: var(--bg-card-hover);
  transform: translateY(-2px);
}

.btn--ghost {
  color: var(--text-secondary);
  padding: 10px 20px;
}

.btn--ghost:hover {
  color: var(--text-primary);
}

.btn--large {
  padding: 18px 42px;
  font-size: var(--text-lg);
}

.btn--small {
  padding: 10px 24px;
  font-size: var(--text-sm);
}

/* ---------- Cards ---------- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--bg-glass-border);
  border-radius: var(--radius-lg);
  padding: var(--space-2xl);
  backdrop-filter: blur(12px);
  transition: all var(--duration-normal) var(--ease-out);
}

.card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(108, 92, 231, 0.3);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

/* ---------- Badge ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: 6px 16px;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: var(--radius-full);
  background: var(--bg-glass);
  border: 1px solid var(--bg-glass-border);
  color: var(--text-accent);
}

/* ---------- Animations ---------- */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-40px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-12px); }
}

@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 20px rgba(108, 92, 231, 0.2); }
  50% { box-shadow: 0 0 40px rgba(108, 92, 231, 0.5); }
}

@keyframes gradient-shift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@keyframes rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

.animate-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out);
}

.animate-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Staggered children */
.stagger-children .animate-in:nth-child(1) { transition-delay: 0ms; }
.stagger-children .animate-in:nth-child(2) { transition-delay: 80ms; }
.stagger-children .animate-in:nth-child(3) { transition-delay: 160ms; }
.stagger-children .animate-in:nth-child(4) { transition-delay: 240ms; }
.stagger-children .animate-in:nth-child(5) { transition-delay: 320ms; }
.stagger-children .animate-in:nth-child(6) { transition-delay: 400ms; }

/* ---------- Scrollbar ---------- */
::-webkit-scrollbar {
  width: 8px;
}

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

::-webkit-scrollbar-thumb {
  background: var(--neutral-700);
  border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--neutral-600);
}

/* ---------- Selection ---------- */
::selection {
  background: rgba(108, 92, 231, 0.3);
  color: var(--text-primary);
}
