/* ============================================
   FitForgeFlow — Design System
   "Less Tapping. More Training."
   ============================================ */

:root {
  /* Brand colors */
  --color-primary: #00a8ff;
  --color-accent: #00c8b4;
  --color-bg: #0a0e1a;
  --color-surface: #0f1525;
  --color-surface-raised: #141b2e;
  --color-border: #1f2940;
  --color-text: #e8ecf4;
  --color-text-dim: #8b95a8;
  --color-text-faint: #5a6478;

  /* Gradients */
  --gradient-brand: linear-gradient(135deg, var(--color-primary), var(--color-accent));

  /* Type */
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --display-weight: 900;

  /* Spacing scale */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2.5rem;
  --space-xl: 4rem;
  --space-2xl: 6rem;
  --space-3xl: 9rem;

  /* Layout */
  --max-width: 1180px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 24px;
}

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

html {
  scroll-behavior: smooth;
}

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

body {
  font-family: var(--font-body);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

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

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

/* ============ Typography ============ */

h1, h2, h3, h4 {
  font-weight: var(--display-weight);
  letter-spacing: -0.02em;
  line-height: 1.1;
}

h1 { font-size: clamp(2.5rem, 6vw, 3.5rem); }
h2 { font-size: clamp(2rem, 4vw, 2.75rem); }
h3 { font-size: clamp(1.25rem, 2.5vw, 1.5rem); }

.eyebrow {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-accent);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.eyebrow::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--color-accent);
}

p.lede {
  font-size: 1.15rem;
  color: var(--color-text-dim);
  max-width: 560px;
}

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

/* ============ Buttons ============ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.75rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  white-space: nowrap;
}

.btn:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
}

.btn-primary {
  background: var(--gradient-brand);
  color: #051018;
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(0, 168, 255, 0.35);
}

.btn-ghost {
  background: transparent;
  color: var(--color-text);
  border: 1px solid var(--color-border);
}

.btn-ghost:hover {
  border-color: var(--color-primary);
  background: rgba(0, 168, 255, 0.06);
}

.btn-block { width: 100%; }

/* ============ Header / Nav ============ */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 14, 26, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem var(--space-md);
  max-width: var(--max-width);
  margin: 0 auto;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 900;
  font-size: 1.15rem;
}

.nav-logo img { height: 28px; }

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  list-style: none;
}

.nav-links a {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--color-text-dim);
  transition: color 0.15s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--color-text);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--color-text);
  cursor: pointer;
}

@media (max-width: 860px) {
  .nav-links { display: none; }
  .nav-toggle { display: block; }
  .nav-actions .btn-ghost { display: none; }
}

/* Mobile menu */
.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 0;
  border-top: 1px solid var(--color-border);
  background: var(--color-surface);
}

.mobile-menu.open { display: flex; }

.mobile-menu a {
  padding: 1rem var(--space-md);
  border-bottom: 1px solid var(--color-border);
  font-weight: 600;
  color: var(--color-text-dim);
}

/* ============ Sections ============ */

section {
  padding: var(--space-2xl) 0;
}

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

.section-head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto var(--space-xl);
}

.section-head p.lede { margin: var(--space-sm) auto 0; }

/* ============ Cards ============ */

.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
}

.card-grid {
  display: grid;
  gap: var(--space-md);
}

/* ============ Footer ============ */

.site-footer {
  border-top: 1px solid var(--color-border);
  padding: var(--space-xl) 0 var(--space-lg);
  margin-top: var(--space-2xl);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
}

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

.footer-brand .nav-logo { margin-bottom: var(--space-sm); }

.footer-brand p {
  color: var(--color-text-dim);
  font-size: 0.9rem;
  max-width: 280px;
}

.footer-col h4 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-faint);
  margin-bottom: var(--space-sm);
  font-weight: 700;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.footer-col a {
  color: var(--color-text-dim);
  font-size: 0.92rem;
  transition: color 0.15s ease;
}

.footer-col a:hover { color: var(--color-accent); }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--space-lg);
  border-top: 1px solid var(--color-border);
  color: var(--color-text-faint);
  font-size: 0.85rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-bottom a:hover { color: var(--color-text-dim); }

/* ============ Utilities ============ */

.text-center { text-align: center; }
.mt-lg { margin-top: var(--space-lg); }
.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}
.cta-row {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

@media (max-width: 600px) {
  .cta-row { flex-direction: column; }
  .cta-row .btn { width: 100%; }
}

/* Visible focus ring everywhere */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
  border-radius: 4px;
}
