/* ========================================
   Steam Manifest Downloader — Landing Page
   Pure CSS, no frameworks
   ======================================== */

/* --- Custom Properties --- */
:root {
  --bg: #0d1117;
  --bg-card: rgba(22, 27, 34, 0.7);
  --bg-card-hover: rgba(30, 37, 48, 0.85);
  --border: rgba(88, 166, 255, 0.1);
  --border-hover: rgba(88, 166, 255, 0.25);
  --text: #e6edf3;
  --text-muted: #8b949e;
  --blue: #58a6ff;
  --green: #3fb950;
  --purple: #bc8cff;
  --gradient: linear-gradient(135deg, #58a6ff, #bc8cff);
  --gradient-bg: linear-gradient(135deg, rgba(88,166,255,0.08), rgba(188,140,255,0.08));
  --radius: 12px;
  --radius-lg: 20px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --max-width: 1140px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

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

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

a:hover {
  color: var(--purple);
}

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

/* --- Reveal Animations --- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* staggered children */
.features-grid .reveal:nth-child(2) { transition-delay: 0.07s; }
.features-grid .reveal:nth-child(3) { transition-delay: 0.14s; }
.features-grid .reveal:nth-child(4) { transition-delay: 0.21s; }
.features-grid .reveal:nth-child(5) { transition-delay: 0.28s; }
.features-grid .reveal:nth-child(6) { transition-delay: 0.35s; }
.features-grid .reveal:nth-child(7) { transition-delay: 0.42s; }
.features-grid .reveal:nth-child(8) { transition-delay: 0.49s; }
.features-grid .reveal:nth-child(9) { transition-delay: 0.56s; }
.features-grid .reveal:nth-child(10) { transition-delay: 0.63s; }

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 16px 0;
  transition: background var(--transition), box-shadow var(--transition);
}

.nav.scrolled {
  background: rgba(13, 17, 23, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 1px 0 var(--border);
}

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

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text);
}

.nav-logo:hover { color: var(--blue); }

.nav-logo-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  object-fit: contain;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-links a {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
  transition: color var(--transition);
}

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

.nav-github {
  color: var(--text-muted);
  display: flex;
  align-items: center;
  transition: color var(--transition);
}

.nav-github:hover { color: var(--text); }

/* --- Page-wide Background --- */
.page-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.hero-gradient {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 50% at 50% 0%, rgba(88,166,255,0.12) 0%, transparent 60%),
    radial-gradient(ellipse 60% 40% at 80% 30%, rgba(188,140,255,0.1) 0%, transparent 50%),
    radial-gradient(ellipse 50% 40% at 20% 70%, rgba(63,185,80,0.06) 0%, transparent 50%);
  animation: heroGradient 8s ease-in-out infinite alternate;
}

@keyframes heroGradient {
  0% { opacity: 0.8; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.05); }
  100% { opacity: 0.8; transform: scale(1); }
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(88,166,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(88,166,255,0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 30%, black 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse 80% 80% at 50% 30%, black 30%, transparent 80%);
}

/* --- Hero Section --- */
.hero {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 120px 24px 80px;
}

.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  animation: float 6s ease-in-out infinite;
}

.hero-orb-1 {
  width: 400px;
  height: 400px;
  background: rgba(88,166,255,0.08);
  top: -100px;
  right: -100px;
  animation-delay: 0s;
}

.hero-orb-2 {
  width: 300px;
  height: 300px;
  background: rgba(188,140,255,0.08);
  bottom: -50px;
  left: -50px;
  animation-delay: -2s;
}

.hero-orb-3 {
  width: 200px;
  height: 200px;
  background: rgba(63,185,80,0.06);
  top: 40%;
  left: 60%;
  animation-delay: -4s;
}

@keyframes float {
  0%, 100% { transform: translate(0, 0); }
  33% { transform: translate(10px, -15px); }
  66% { transform: translate(-8px, 10px); }
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: 100px;
  background: rgba(88,166,255,0.1);
  border: 1px solid rgba(88,166,255,0.2);
  color: var(--blue);
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 24px;
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}

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

.hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: var(--text-muted);
  max-width: 520px;
  margin: 0 auto 36px;
  line-height: 1.7;
}

.hero-buttons {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 60px;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 28px;
  border-radius: 10px;
  font-size: 0.95rem;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  transition: all var(--transition);
  border: none;
  text-decoration: none;
}

.btn-primary {
  background: var(--gradient);
  color: #fff;
  box-shadow: 0 4px 20px rgba(88,166,255,0.25);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(88,166,255,0.35);
  color: #fff;
}

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

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

.btn-large {
  padding: 16px 36px;
  font-size: 1.1rem;
  border-radius: 14px;
}

/* --- Hero Mockup --- */
.hero-mockup {
  perspective: 1000px;
}

.mockup-window {
  background: rgba(22, 27, 34, 0.8);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  backdrop-filter: blur(16px);
  max-width: 500px;
  margin: 0 auto;
  text-align: left;
  transform: rotateX(2deg);
  box-shadow: 0 20px 60px rgba(0,0,0,0.4);
  transition: transform var(--transition);
}

.mockup-window:hover {
  transform: rotateX(0deg);
}

.mockup-titlebar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: rgba(13, 17, 23, 0.6);
  border-bottom: 1px solid var(--border);
}

.mockup-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.mockup-title {
  margin-left: 8px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.mockup-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mockup-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.mockup-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  width: 60px;
  flex-shrink: 0;
}

.mockup-input {
  flex: 1;
  padding: 8px 12px;
  background: rgba(13, 17, 23, 0.5);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 0.8rem;
  color: var(--text);
  font-family: 'Consolas', 'Monaco', monospace;
}

.mockup-progress {
  height: 6px;
  background: rgba(88,166,255,0.1);
  border-radius: 3px;
  overflow: hidden;
  margin-top: 4px;
}

.mockup-progress-bar {
  height: 100%;
  width: 100%;
  background: var(--gradient);
  border-radius: 3px;
  animation: progressAnim 3s ease-in-out infinite;
}

@keyframes progressAnim {
  0% { width: 0; }
  70% { width: 100%; }
  100% { width: 100%; }
}

.mockup-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--green);
}

/* --- Section Shared --- */
section {
  position: relative;
  z-index: 1;
  padding: 100px 0;
}

.section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 60px;
}

.section-tag {
  display: inline-block;
  padding: 4px 14px;
  border-radius: 100px;
  background: var(--gradient-bg);
  border: 1px solid var(--border);
  color: var(--blue);
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 16px;
}

.section-header h2 {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

.section-header p {
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.7;
}

/* --- Features --- */
.features {
  position: relative;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
  backdrop-filter: blur(8px);
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  gap: 18px;
}

.feature-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 0%, rgba(88,166,255,0.08), transparent 70%);
  opacity: 0;
  transition: opacity var(--transition);
}

.feature-card:hover {
  transform: translateY(-4px) scale(1.01);
  border-color: var(--border-hover);
  box-shadow: 0 8px 40px rgba(88,166,255,0.1);
}

.feature-card:hover::before {
  opacity: 1;
}

.feature-icon {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: 10px;
  background: var(--gradient-bg);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--blue);
  flex-shrink: 0;
}

.feature-icon svg {
  width: 22px;
  height: 22px;
}

.feature-text h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.feature-text p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* --- How It Works --- */
.how-it-works {
  position: relative;
}

.steps {
  max-width: 650px;
  margin: 0 auto;
  position: relative;
  padding-left: 40px;
}

.steps-line {
  position: absolute;
  left: 23px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--blue), var(--purple));
  opacity: 0.3;
}

.step {
  display: flex;
  gap: 24px;
  padding: 24px 0;
  position: relative;
}

.step-number {
  width: 48px;
  height: 48px;
  min-width: 48px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--blue);
  position: relative;
  z-index: 2;
  margin-left: -40px;
  transition: all var(--transition);
}

.step:hover .step-number {
  background: var(--blue);
  color: #fff;
  box-shadow: 0 0 20px rgba(88,166,255,0.3);
}

.step-content h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.step-content p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* --- Tech Stack --- */
.tech-scroll {
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, black 15%, black 85%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, black 15%, black 85%, transparent);
}

.tech-track {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
  padding: 10px 0;
}

.tech-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(8px);
  font-weight: 600;
  font-size: 0.95rem;
  white-space: nowrap;
  transition: all var(--transition);
}

.tech-badge:hover {
  border-color: var(--border-hover);
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(88,166,255,0.1);
}

/* --- Download --- */
.download {
  padding: 100px 0 120px;
}

.download-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  backdrop-filter: blur(16px);
}

.download-glow {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 30% 0%, rgba(88,166,255,0.1), transparent 60%),
    radial-gradient(ellipse 60% 50% at 70% 100%, rgba(188,140,255,0.08), transparent 60%);
  pointer-events: none;
}

.download-content {
  position: relative;
  text-align: center;
  padding: 60px 40px;
}

.download-content h2 {
  font-size: clamp(1.5rem, 3.5vw, 2.2rem);
  font-weight: 800;
  margin-bottom: 12px;
}

.download-content > p {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 32px;
  max-width: 450px;
  margin-left: auto;
  margin-right: auto;
}

.download-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  margin-top: 32px;
  flex-wrap: wrap;
}

.download-info {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* --- Footer --- */
.footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--border);
  padding: 40px 0 32px;
}

.footer-inner {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.footer-logo:hover { color: var(--blue); }

.footer-logo-icon {
    width: 32px;
    height: 32px;
    border-radius: 6px;
}

.footer-left p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.footer-right {
  display: flex;
  gap: 24px;
}

.footer-right a {
  color: var(--text-muted);
  font-size: 0.9rem;
}

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

.footer-bottom {
  text-align: center;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.footer-bottom p {
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .nav-links {
    display: none;
  }

  .hero {
    padding: 100px 20px 60px;
    min-height: auto;
  }

  .hero-title {
    font-size: 2.2rem;
  }

  .hero-buttons {
    flex-direction: column;
    margin-bottom: 40px;
  }

  .btn {
    width: 100%;
    justify-content: center;
  }

  .mockup-window {
    max-width: 100%;
  }

  section {
    padding: 60px 0;
  }

  .features-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .steps {
    padding-left: 30px;
  }

  .step-number {
    width: 40px;
    height: 40px;
    min-width: 40px;
    margin-left: -30px;
    font-size: 0.95rem;
  }

  .steps-line {
    left: 18px;
  }

  .download-content {
    padding: 40px 24px;
  }

  .download-meta {
    gap: 16px;
    flex-direction: column;
  }

  .footer-inner {
    flex-direction: column;
    text-align: center;
    align-items: center;
  }

  .footer-right {
    flex-wrap: wrap;
    justify-content: center;
  }

  .tech-track {
    gap: 12px;
  }

  .tech-badge {
    padding: 10px 16px;
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 1.8rem;
  }

  .section-header h2 {
    font-size: 1.5rem;
  }
}
