/* ══════════════════════════════════════════════════════
   Space Quizzed — Landing Page
   Standalone styles (no imports from game CSS)
   ══════════════════════════════════════════════════════ */

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

/* ── Variables ── */
:root {
  --sp-cyan: #00ffff;
  --sp-magenta: #ff00ff;
  --sp-yellow: #ffff00;
  --sp-green: #00ff00;
  --sp-pink: #ff0080;
  --sp-gold: #ffcc00;
  --sp-bg-deep: #000000;
  --sp-bg-dark: #0a0020;
  --sp-bg-mid: #1a0033;
  --sp-bg-light: #2d004d;
  --sp-text-body: #e0e0e0;
  --sp-text-muted: #aaccff;
  --sp-glow-cyan: rgba(0, 255, 255, 0.5);
  --sp-glow-magenta: rgba(255, 0, 255, 0.5);
  --sp-font: 'Rajdhani', sans-serif;
}

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--sp-font);
  background: var(--sp-bg-dark);
  color: var(--sp-text-body);
  overflow-x: hidden;
  line-height: 1.5;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--sp-cyan); text-decoration: none; }

/* ── Fade-in animations ── */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ══════════════════════════════════════════════════════
   HERO SECTION
   ══════════════════════════════════════════════════════ */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  max-width: none;
  padding: 0;
}

#starfield {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 1;
  padding: 2rem;
  max-width: 800px;
}

.hero-logo {
  width: min(80vw, 600px);
  margin: 0 auto 1.5rem;
  filter: drop-shadow(0 0 30px var(--sp-glow-cyan)) drop-shadow(0 0 60px var(--sp-glow-magenta));
}

.hero-tagline {
  font-size: clamp(1.1rem, 3vw, 1.6rem);
  font-weight: 500;
  color: var(--sp-text-muted);
  margin-bottom: 2.5rem;
  text-shadow: 0 0 20px rgba(0, 255, 255, 0.3);
}

.hero-cta {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* Hero bottom gradient fade into next section */
.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 200px;
  background: linear-gradient(to bottom, transparent, var(--sp-bg-dark));
  z-index: 1;
  pointer-events: none;
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.9rem 2rem;
  font-family: var(--sp-font);
  font-size: 1.1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border: 2px solid;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, rgba(0, 255, 255, 0.15), rgba(255, 0, 255, 0.15));
  border-color: var(--sp-cyan);
  color: var(--sp-cyan);
  box-shadow: 0 0 15px var(--sp-glow-cyan), inset 0 0 15px rgba(0, 255, 255, 0.1);
}
.btn-primary:hover {
  background: linear-gradient(135deg, rgba(0, 255, 255, 0.3), rgba(255, 0, 255, 0.3));
  box-shadow: 0 0 30px var(--sp-glow-cyan), inset 0 0 30px rgba(0, 255, 255, 0.15);
  transform: translateY(-2px);
}

.btn-secondary {
  background: transparent;
  border-color: var(--sp-magenta);
  color: var(--sp-magenta);
  box-shadow: 0 0 10px var(--sp-glow-magenta);
}
.btn-secondary:hover {
  background: rgba(255, 0, 255, 0.1);
  box-shadow: 0 0 20px var(--sp-glow-magenta);
  transform: translateY(-2px);
}

/* ══════════════════════════════════════════════════════
   SECTIONS (shared)
   ══════════════════════════════════════════════════════ */
section {
  position: relative;
  padding: 5rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.section-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 700;
  text-align: center;
  margin-bottom: 1rem;
  color: var(--sp-cyan);
  text-shadow: 0 0 20px var(--sp-glow-cyan);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.section-subtitle {
  text-align: center;
  font-size: 1.15rem;
  color: var(--sp-text-muted);
  margin-bottom: 3rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* ══════════════════════════════════════════════════════
   HORST SECTION
   ══════════════════════════════════════════════════════ */
.horst-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  padding-top: 3rem;
}

.horst-image-wrapper {
  position: relative;
  display: flex;
  justify-content: center;
}

.horst-image {
  width: min(100%, 380px);
  border-radius: 16px;
  border: 2px solid var(--sp-magenta);
  box-shadow:
    0 0 20px var(--sp-glow-magenta),
    0 0 60px rgba(255, 0, 255, 0.2),
    0 0 100px rgba(0, 255, 255, 0.1);
}

.horst-text h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.4rem);
  font-weight: 700;
  color: var(--sp-cyan);
  text-shadow: 0 0 15px var(--sp-glow-cyan);
  margin-bottom: 0.5rem;
}

.horst-text .horst-role {
  font-size: 1.1rem;
  color: var(--sp-magenta);
  font-weight: 600;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.horst-text p {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--sp-text-body);
  margin-bottom: 1rem;
}

.horst-quote {
  position: relative;
  background: linear-gradient(135deg, rgba(255, 0, 255, 0.08), rgba(0, 255, 255, 0.08));
  border: 1px solid rgba(255, 0, 255, 0.3);
  border-radius: 12px;
  padding: 1.2rem 1.5rem;
  margin-top: 1.5rem;
  font-style: italic;
  color: var(--sp-gold);
  font-size: 1.05rem;
  line-height: 1.6;
}

.horst-quote::before {
  content: '\201E';
  position: absolute;
  top: -0.3rem;
  left: 0.8rem;
  font-size: 3rem;
  color: var(--sp-magenta);
  opacity: 0.6;
  font-style: normal;
  line-height: 1;
}

/* ══════════════════════════════════════════════════════
   FEATURES / SPIELMODI
   ══════════════════════════════════════════════════════ */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 2rem;
}

.feature-card {
  background: linear-gradient(180deg, rgba(26, 0, 51, 0.8), rgba(10, 0, 32, 0.9));
  border: 1px solid rgba(255, 0, 255, 0.25);
  border-radius: 16px;
  padding: 2rem 1.5rem;
  transition: all 0.3s ease;
}

.feature-card:hover {
  border-color: var(--sp-cyan);
  box-shadow: 0 0 25px rgba(0, 255, 255, 0.15), 0 0 50px rgba(255, 0, 255, 0.1);
  transform: translateY(-4px);
}

.feature-card h3 {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--sp-cyan);
  margin-bottom: 0.8rem;
  text-shadow: 0 0 10px var(--sp-glow-cyan);
}

.feature-card p {
  font-size: 0.95rem;
  color: var(--sp-text-muted);
  line-height: 1.6;
  margin-bottom: 0.8rem;
}

.feature-planets {
  display: flex;
  gap: 0.6rem;
  margin-top: 1rem;
  flex-wrap: wrap;
  justify-content: center;
}

.feature-planets img {
  width: 60px;
  height: 60px;
  object-fit: contain;
  filter: drop-shadow(0 0 8px rgba(0, 255, 255, 0.3));
  transition: transform 0.3s ease;
}
.feature-planets img:hover {
  transform: scale(1.15);
}

.feature-list {
  list-style: none;
  padding: 0;
}

.feature-list li {
  font-size: 0.95rem;
  color: var(--sp-text-muted);
  padding: 0.3rem 0;
  padding-left: 1.5rem;
  position: relative;
}

.feature-list li::before {
  content: '>';
  position: absolute;
  left: 0;
  color: var(--sp-cyan);
  font-weight: 700;
}

/* ══════════════════════════════════════════════════════
   PLATFORMS
   ══════════════════════════════════════════════════════ */
.platforms-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
}

.platform-card {
  text-align: center;
  padding: 2rem 1.5rem;
  background: linear-gradient(180deg, rgba(26, 0, 51, 0.6), rgba(10, 0, 32, 0.8));
  border: 1px solid rgba(0, 255, 255, 0.15);
  border-radius: 16px;
  transition: all 0.3s ease;
}

.platform-card:hover {
  border-color: var(--sp-cyan);
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.15);
  transform: translateY(-4px);
}

.platform-icon {
  color: var(--sp-cyan);
  margin-bottom: 1rem;
  filter: drop-shadow(0 0 8px var(--sp-glow-cyan));
}

.platform-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--sp-cyan);
  margin-bottom: 0.5rem;
  text-shadow: 0 0 10px var(--sp-glow-cyan);
}

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

.sync-banner,
.gc-banner {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 1.5rem;
  padding: 1.2rem 1.5rem;
  background: linear-gradient(135deg, rgba(0, 255, 255, 0.06), rgba(255, 0, 255, 0.06));
  border: 1px solid rgba(0, 255, 255, 0.2);
  border-radius: 12px;
  font-size: 0.95rem;
  color: var(--sp-text-muted);
  line-height: 1.5;
}

.sync-banner strong,
.gc-banner strong {
  color: var(--sp-cyan);
}

.sync-icon {
  flex-shrink: 0;
  color: var(--sp-cyan);
  filter: drop-shadow(0 0 6px var(--sp-glow-cyan));
}

/* ══════════════════════════════════════════════════════
   SCREENSHOTS
   ══════════════════════════════════════════════════════ */
.screenshots-section {
  max-width: 100%;
  padding-left: 0;
  padding-right: 0;
}

.screenshots-section .section-title,
.screenshots-section .section-subtitle {
  padding: 0 2rem;
}

.screenshots-track {
  display: flex;
  gap: 2rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding: 1rem 2rem 2rem;
  scrollbar-width: none;
}
.screenshots-track::-webkit-scrollbar { display: none; }
.screenshots-track.dragging { cursor: grabbing; }

.screenshot-frame {
  flex: 0 0 auto;
  scroll-snap-align: center;
  width: 260px;
  position: relative;
}

.phone-mockup {
  background: #111;
  border: 3px solid #333;
  border-radius: 28px;
  padding: 12px 8px;
  box-shadow: 0 0 30px rgba(0, 0, 0, 0.5), 0 0 15px var(--sp-glow-magenta);
}

.phone-mockup img {
  border-radius: 18px;
  width: 100%;
  aspect-ratio: 9 / 19.5;
  object-fit: cover;
  background: var(--sp-bg-mid);
}

.screenshot-label {
  text-align: center;
  margin-top: 0.8rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--sp-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Placeholder for missing screenshots */
.screenshot-placeholder {
  border-radius: 18px;
  width: 100%;
  aspect-ratio: 9 / 19.5;
  background: linear-gradient(135deg, var(--sp-bg-mid), var(--sp-bg-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  opacity: 0.4;
}

/* ══════════════════════════════════════════════════════
   FOOTER
   ══════════════════════════════════════════════════════ */
.landing-footer {
  text-align: center;
  padding: 4rem 2rem 3rem;
  border-top: 1px solid rgba(255, 0, 255, 0.15);
  max-width: 800px;
  margin: 0 auto;
}

.footer-cta {
  margin-bottom: 2rem;
}

.footer-tagline {
  font-size: 0.95rem;
  color: var(--sp-text-muted);
  margin-bottom: 1.5rem;
}

.footer-links {
  display: flex;
  gap: 2rem;
  justify-content: center;
  font-size: 0.85rem;
}
.footer-links a {
  color: var(--sp-text-muted);
  opacity: 0.6;
  transition: opacity 0.2s;
}
.footer-links a:hover { opacity: 1; }

/* ══════════════════════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════════════════════ */

/* ── Tablet (< 1024px): 2-column features, tighter spacing ── */
@media (max-width: 1024px) {
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
  /* 3rd card spans full width centered */
  .feature-card:last-child {
    grid-column: 1 / -1;
    max-width: 500px;
    justify-self: center;
  }

  .platforms-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }
  .platform-card:last-child {
    grid-column: 1 / -1;
    max-width: 400px;
    justify-self: center;
  }

  section { padding: 4rem 1.5rem; }
}

/* ── Mobile (< 768px): single column everything ── */
@media (max-width: 768px) {
  section { padding: 3rem 1rem; }

  .hero-content { padding: 1.5rem 1rem; }
  .hero-logo { width: min(90vw, 400px); }
  .hero-tagline { margin-bottom: 2rem; }

  .btn {
    padding: 0.8rem 1.5rem;
    font-size: 1rem;
    width: 100%;
    justify-content: center;
  }
  .hero-cta {
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
  }

  .horst-section {
    grid-template-columns: 1fr;
    gap: 2rem;
    text-align: center;
  }
  .horst-image { width: min(70%, 280px); margin: 0 auto; }
  .horst-text h2 { font-size: 1.5rem; }
  .horst-text .horst-role { font-size: 0.95rem; }
  .horst-text p { font-size: 0.95rem; }
  .horst-quote { font-size: 0.95rem; padding: 1rem 1.2rem; }

  .features-grid {
    grid-template-columns: 1fr;
    gap: 1.2rem;
  }
  .feature-card {
    padding: 1.5rem 1.2rem;
  }
  .feature-card:last-child {
    max-width: none;
  }

  .platforms-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .platform-card { padding: 1.5rem 1.2rem; }

  .sync-banner,
  .gc-banner {
    flex-direction: column;
    text-align: center;
    gap: 0.5rem;
  }
  .feature-planets img {
    width: 48px;
    height: 48px;
  }

  .section-title { margin-bottom: 0.5rem; }
  .section-subtitle { font-size: 1rem; margin-bottom: 2rem; }

  .screenshot-frame { width: 200px; }
  .screenshots-track { gap: 1rem; padding: 1rem 1rem 1.5rem; }

  .landing-footer { padding: 3rem 1rem 2rem; }
}

/* ── Small phones (< 400px) ── */
@media (max-width: 400px) {
  .hero-logo { width: 92vw; }
  .hero-tagline { font-size: 1rem; }
  .btn { font-size: 0.9rem; padding: 0.7rem 1.2rem; }
  .screenshot-frame { width: 180px; }
  .feature-card h3 { font-size: 1.15rem; }
  .horst-image { width: min(80%, 240px); }
}

/* ── Desktop wide (>= 1200px): screenshots as grid ── */
@media (min-width: 1200px) {
  .screenshots-track {
    justify-content: center;
    overflow-x: visible;
    flex-wrap: wrap;
  }
}
