/* =========================================================================
   3dshop.tj — futuristic marketing SPA, light theme.
   Distinct from the app's own indigo M3 chrome on purpose: this is the
   outward-facing brand surface. A clean, bright base lets the violet/cyan
   accent duo and the 3D "market dynamics" hero do the talking, instead of
   competing with a dark backdrop.
   ========================================================================= */

:root {
  /* Surfaces */
  --bg: #fafafd;
  --bg-alt: #f1f1f9;
  --surface: #ffffff;
  --surface-2: #eeeef8;

  /* Text */
  --ink: #14152b;
  --muted: #5b5f78;

  /* Brand accents (deepened vs. the dark-theme values for AA contrast on white) */
  --violet: #6c4cf0;
  --violet-strong: #5636d6;
  --violet-soft: rgba(108, 76, 240, 0.1);
  --cyan: #0ea5a5;
  --cyan-soft: rgba(14, 165, 165, 0.12);

  --line: rgba(20, 21, 43, 0.09);
  --shadow: 0 20px 50px rgba(20, 21, 43, 0.08);

  --radius-lg: 20px;
  --radius-md: 14px;

  --font-display: "Space Grotesk", -apple-system, sans-serif;
  --font-body: "Inter", -apple-system, sans-serif;
}

/* ---------- Reset & base ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  line-height: 1.6;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

#hero-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
}

/* ---------- Nav ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(250, 250, 253, 0.7);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s, background 0.3s, box-shadow 0.3s;
}
.nav.scrolled {
  border-bottom-color: var(--line);
  background: rgba(250, 250, 253, 0.92);
  box-shadow: 0 4px 20px rgba(20, 21, 43, 0.05);
}
.nav-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 16px 28px;
  display: flex;
  align-items: center;
  gap: 28px;
}
.brand {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.02em;
  margin-right: auto;
}
.brand span { background: linear-gradient(135deg, var(--violet), var(--cyan)); -webkit-background-clip: text; background-clip: text; color: transparent; }

.nav-links { display: flex; gap: 26px; }
.nav-links a { font-size: 14.5px; color: var(--muted); transition: color 0.2s; white-space: nowrap; }
.nav-links a:hover { color: var(--ink); }

.nav-actions { display: flex; align-items: center; gap: 14px; }
.lang-switch { display: flex; gap: 2px; background: var(--surface-2); border-radius: 999px; padding: 3px; }
.lang-switch button {
  border: none;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  padding: 6px 11px;
  border-radius: 999px;
  cursor: pointer;
  letter-spacing: 0.03em;
}
.lang-switch button.active { background: var(--violet); color: #fff; }

.burger { display: none; background: none; border: none; color: var(--ink); font-size: 22px; cursor: pointer; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 14.5px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s, background 0.2s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: linear-gradient(135deg, var(--violet), var(--violet-strong)); color: #fff; box-shadow: 0 8px 24px rgba(108, 76, 240, 0.3); }
.btn-primary:hover { box-shadow: 0 12px 32px rgba(108, 76, 240, 0.42); }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--violet); background: var(--violet-soft); }
.btn-outline { background: transparent; border-color: var(--cyan); color: var(--cyan); margin-top: 18px; }
.btn-outline:hover { background: var(--cyan-soft); }
.btn-lg { padding: 14px 30px; font-size: 16px; }
.nav-login { padding: 8px 18px; font-size: 13.5px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 120px 24px 60px;
}
.hero-content { max-width: 760px; }
.eyebrow {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.2em;
  color: var(--cyan);
  margin: 0 0 20px;
}
.hero-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.4rem, 6vw, 4.4rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 0 0 22px;
  background: linear-gradient(180deg, var(--ink) 35%, var(--violet) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-subtitle { font-size: clamp(1rem, 1.6vw, 1.25rem); color: var(--muted); max-width: 600px; margin: 0 auto 36px; }
.hero-cta { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

.scroll-cue { position: absolute; bottom: 32px; left: 50%; transform: translateX(-50%); }
.scroll-cue span { display: block; width: 26px; height: 42px; border: 2px solid var(--line); border-radius: 14px; position: relative; }
.scroll-cue span::after {
  content: "";
  position: absolute;
  top: 8px; left: 50%;
  width: 4px; height: 8px;
  margin-left: -2px;
  background: var(--cyan);
  border-radius: 2px;
  animation: scrollcue 1.6s infinite;
}
@keyframes scrollcue { 0% { opacity: 1; top: 8px; } 100% { opacity: 0; top: 22px; } }

/* ---------- Sections ---------- */
.section { position: relative; z-index: 1; max-width: 1180px; margin: 0 auto; padding: 110px 24px; }
.section-alt { background: linear-gradient(180deg, transparent, var(--bg-alt) 12%, var(--bg-alt) 88%, transparent); max-width: none; }
.section-alt > * { max-width: 1180px; margin-left: auto; margin-right: auto; }
.section-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.8rem, 3.4vw, 2.6rem);
  letter-spacing: -0.01em;
  text-align: center;
  margin: 0 0 56px;
}

.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in { opacity: 1; transform: translateY(0); }

/* Gamers section — dark "gaming" island in the middle of the light site,
   deliberately breaking theme to signal a different audience/mood. */
.gamers-section {
  max-width: none;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(34,224,224,0.10), transparent 60%),
    linear-gradient(180deg, #0b0d16, #06070d 60%, #0b0d16);
  color: #e8e9f5;
}
.gamers-section > * { max-width: 1180px; margin-left: auto; margin-right: auto; }
.gamers-section .eyebrow { color: #22e0e0; text-align: center; }
.gamers-section .section-title { color: #f4f5fb; }
.gamers-subtitle { text-align: center; color: #a3a7c2; max-width: 620px; margin: -30px auto 56px; font-size: 16px; }
.gamers-compare { display: grid; grid-template-columns: 1fr auto 1fr; gap: 28px; align-items: center; }
.gamer-vs {
  font-family: var(--font-display); font-weight: 700; font-size: 14px;
  color: #5b5f78; letter-spacing: 0.1em;
}
.gamer-panel {
  position: relative; aspect-ratio: 16/10; border-radius: 16px; overflow: hidden;
  border: 1px solid rgba(255,255,255,0.08); background: #10131c;
}
.gamer-panel img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gamer-panel-label {
  position: absolute; left: 14px; bottom: 12px; margin: 0; font-size: 13px;
  font-weight: 700; color: #fff; background: rgba(0,0,0,0.55); padding: 4px 10px;
  border-radius: 999px; backdrop-filter: blur(4px);
}
.gamer-panel-fps {
  background:
    repeating-linear-gradient(0deg, rgba(255,255,255,0.03) 0 1px, transparent 1px 34px),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.03) 0 1px, transparent 1px 34px),
    radial-gradient(ellipse at 50% 40%, #1c2130, #0a0c14 75%);
}
.hud-crosshair { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 30px; height: 30px; }
.hud-crosshair span { position: absolute; background: rgba(34,224,224,0.85); }
.hud-crosshair span:first-child { top: 50%; left: 0; width: 100%; height: 2px; transform: translateY(-1px); }
.hud-crosshair span:last-child { left: 50%; top: 0; height: 100%; width: 2px; transform: translateX(-1px); }
.hud-minimap {
  position: absolute; top: 14px; right: 14px; width: 64px; height: 64px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.25); background: rgba(10,15,15,0.7);
}
.hud-minimap i {
  position: absolute; top: 50%; left: 50%; width: 0; height: 0; transform: translate(-50%, -60%);
  border-left: 5px solid transparent; border-right: 5px solid transparent; border-bottom: 9px solid #4ade80;
}
.hud-healthbar { position: absolute; left: 14px; bottom: 14px; display: flex; align-items: center; gap: 8px; }
.hud-healthbar label { font-size: 10px; font-weight: 700; color: #a3a7c2; }
.hud-healthbar div { width: 90px; height: 8px; border-radius: 4px; background: rgba(255,255,255,0.12); overflow: hidden; }
.hud-healthbar span { display: block; width: 72%; height: 100%; background: #f87171; }
.hud-ammo { position: absolute; right: 14px; bottom: 12px; font-family: var(--font-display); font-weight: 700; font-size: 20px; color: #fff; }
.hud-ammo small { font-size: 12px; color: #a3a7c2; font-weight: 500; }
.gamer-panel-fps .gamer-panel-label { bottom: auto; top: 12px; }
.gamers-captions {
  display: grid; grid-template-columns: 1fr auto 1fr; gap: 28px; margin-top: 16px;
  font-size: 12.5px; color: #7a7f9c; text-align: center;
}
.gamers-captions span:first-child { grid-column: 1; }
.gamers-captions span:last-child { grid-column: 3; }
@media (max-width: 760px) {
  .gamers-compare, .gamers-captions { grid-template-columns: 1fr; }
  .gamer-vs { display: none; }
  .gamers-captions span { grid-column: 1 !important; }
}

/* Feature grid */
.feature-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 60px; }
.feature-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  box-shadow: var(--shadow);
  transition: border-color 0.2s, transform 0.2s;
}
.feature-card:hover { border-color: var(--violet); transform: translateY(-4px); }
.feature-icon { font-size: 30px; margin-bottom: 14px; }
.feature-card h3 { font-family: var(--font-display); font-size: 17px; margin: 0 0 8px; }
.feature-card p { font-size: 14px; color: var(--muted); margin: 0; }

.demo-shot { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); border: 1px solid var(--line); }
.demo-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 10px; }
.demo-row img, .demo-shot img { width: 100%; border-radius: var(--radius-lg); }

/* Flow (how it works) */
.flow { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; margin-bottom: 56px; }
.flow-step { text-align: center; padding: 0 10px; }
.flow-num {
  width: 52px; height: 52px;
  border-radius: 50%;
  margin: 0 auto 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--violet), var(--cyan));
  color: #fff;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
  box-shadow: 0 8px 20px rgba(108, 76, 240, 0.25);
}
.flow-step h3 { font-family: var(--font-display); font-size: 16.5px; margin: 0 0 8px; }
.flow-step p { font-size: 13.5px; color: var(--muted); margin: 0; }

/* Split (for shoppers) */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.split-text h2 { text-align: left; margin-bottom: 18px; }
.split-text p { color: var(--muted); font-size: 16px; }
.split-visual img { border-radius: var(--radius-lg); box-shadow: var(--shadow); border: 1px solid var(--line); }

/* Partner cards */
.partner-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 50px; }
.partner-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 40px 34px;
  text-align: center;
  box-shadow: var(--shadow);
}
.partner-card h3 { font-family: var(--font-display); font-size: 21px; margin: 14px 0 12px; }
.partner-card p { color: var(--muted); font-size: 14.5px; }

/* Stats */
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 56px; }
.stat-card { text-align: center; padding: 22px 12px; }
.stat-value {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 44px;
  background: linear-gradient(135deg, var(--violet), var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.stat-static { font-size: 34px; }
.stat-label { font-weight: 600; font-size: 14px; margin-top: 6px; }
.stat-text { color: var(--muted); font-size: 12.5px; margin-top: 4px; }
.chart-wrap { max-width: 480px; margin: 0 auto; }
.chart-caption { text-align: center; font-weight: 600; font-size: 14px; color: var(--ink); margin-bottom: 12px; }

/* Promo band */
.promo-band { text-align: center; }
.promo-text { color: var(--muted); max-width: 620px; margin: 0 auto; font-size: 16px; }

/* Final CTA — the "last section" market-dynamics polygon visual sits behind
   this content, scoped to the section (not viewport-fixed like the hero). */
.final-cta { position: relative; text-align: center; padding: 160px 24px; overflow: hidden; max-width: none; }
.final-cta h2 { font-family: var(--font-display); font-weight: 700; font-size: clamp(2rem, 5vw, 3.4rem); margin: 0 0 34px; line-height: 1.1; }
#market-canvas { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.final-cta-content { position: relative; z-index: 1; max-width: 900px; margin: 0 auto; }

/* Footer */
.footer { position: relative; z-index: 1; border-top: 1px solid var(--line); padding: 50px 24px; }
.footer-inner { max-width: 1180px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; gap: 22px; text-align: center; }
.footer-brand { font-family: var(--font-display); font-weight: 700; font-size: 18px; }
.footer-brand span { background: linear-gradient(135deg, var(--violet), var(--cyan)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 20px; }
.footer-links a { font-size: 13.5px; color: var(--muted); }
.footer-links a:hover { color: var(--ink); }
.footer-copy { font-size: 12.5px; color: var(--muted); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .nav-links { display: none; }
  .nav-links.nav-links-mobile-open {
    display: flex;
    position: fixed;
    top: 64px; left: 0; right: 0;
    flex-direction: column;
    gap: 16px;
    padding: 20px;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
  }
  .burger { display: block; }
  .feature-grid { grid-template-columns: 1fr 1fr; }
  .flow { grid-template-columns: 1fr 1fr; }
  .split { grid-template-columns: 1fr; }
  .partner-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .demo-row { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .feature-grid { grid-template-columns: 1fr; }
  .flow { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .section { padding: 80px 20px; }
  .hero-cta { flex-direction: column; align-items: stretch; }
}

@media (prefers-reduced-motion: reduce) {
  .reveal { transition: none; opacity: 1; transform: none; }
  .scroll-cue span::after { animation: none; }
}
