/* ========================================
   Spark Atlas — Official Website Styles
   Aesthetic: Deep Space Cartography
   ======================================== */

/* ---------- CSS VARIABLES ---------- */
:root {
  /* Dark theme (default) */
  --bg-primary: #06080f;
  --bg-secondary: #0c1019;
  --bg-tertiary: #111722;
  --bg-card: rgba(15, 22, 36, 0.7);
  --bg-card-hover: rgba(20, 30, 50, 0.85);
  --text-primary: #e8ecf4;
  --text-secondary: #8a94a8;
  --text-tertiary: #4f5a6e;
  --accent: #00d4aa;
  --accent-glow: rgba(0, 212, 170, 0.25);
  --accent-secondary: #f0a030;
  --accent-secondary-glow: rgba(240, 160, 48, 0.2);
  --border: rgba(255, 255, 255, 0.06);
  --border-hover: rgba(255, 255, 255, 0.12);
  --glass: rgba(10, 16, 28, 0.6);
  --glass-border: rgba(255, 255, 255, 0.08);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 32px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 16px 64px rgba(0, 0, 0, 0.5);
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 24px;
  --radius-xl: 36px;
  --font-display: 'Outfit', 'Noto Sans SC', system-ui, sans-serif;
  --font-body: 'Noto Sans SC', 'Outfit', system-ui, sans-serif;
  --font-mono: 'Space Mono', 'SF Mono', monospace;
  --nav-height: 72px;
}

[data-theme="light"] {
  --bg-primary: #f4f6fa;
  --bg-secondary: #eaeff6;
  --bg-tertiary: #dfe5ef;
  --bg-card: rgba(255, 255, 255, 0.75);
  --bg-card-hover: rgba(255, 255, 255, 0.9);
  --text-primary: #0f1520;
  --text-secondary: #4a5568;
  --text-tertiary: #8a94a8;
  --accent: #00a88a;
  --accent-glow: rgba(0, 168, 138, 0.15);
  --accent-secondary: #d48a20;
  --accent-secondary-glow: rgba(212, 138, 32, 0.12);
  --border: rgba(0, 0, 0, 0.06);
  --border-hover: rgba(0, 0, 0, 0.12);
  --glass: rgba(255, 255, 255, 0.6);
  --glass-border: rgba(0, 0, 0, 0.06);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 8px 32px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 16px 64px rgba(0, 0, 0, 0.1);
}

/* ---------- RESET & BASE ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }

html.fonts-loading .nav-glass,
html.fonts-loading .hero-content {
  opacity: 0;
}

.nav-glass,
.hero-content {
  transition: opacity 0.18s ease;
}

html {
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

html::-webkit-scrollbar {
  display: none;
}

body {
  font-family: var(--font-body);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background 0.5s ease, color 0.5s ease;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { border: none; background: none; cursor: pointer; font: inherit; color: inherit; }

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- NAVIGATION ---------- */
.nav {
  position: fixed;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  width: auto;
  max-width: calc(100% - 32px);
}

.nav-glass {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding: 0 28px;
  height: 56px;
  min-width: 680px;
  background: rgba(10, 16, 28, 0.45);
  backdrop-filter: blur(28px) saturate(1.6);
  -webkit-backdrop-filter: blur(28px) saturate(1.6);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 28px;
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.25),
    0 0 0 0.5px rgba(255, 255, 255, 0.06) inset,
    0 1px 0 rgba(255, 255, 255, 0.08) inset;
  transition: background 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}

/* Liquid Pane Style for liquidGL */
.liquid-pane {
  position: relative;
  /* Ensure backdrop-filter is disabled since WebGL handles the blur/glass */
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border: 1px solid var(--border-color); /* keep the border */
}

/* Ensure contents sit above the glass */
.liquid-pane > * {
  position: relative;
  z-index: 3;
}

[data-theme="light"] .nav-glass {
  background: rgba(255, 255, 255, 0.5);
  border-color: rgba(0, 0, 0, 0.08);
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.06),
    0 0 0 0.5px rgba(0, 0, 0, 0.04) inset,
    0 1px 0 rgba(255, 255, 255, 0.6) inset;
}

.nav-glass::before {
  content: '';
  position: absolute;
  top: 0;
  left: 12%;
  right: 12%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  pointer-events: none;
}

[data-theme="light"] .nav-glass::before {
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.8), transparent);
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

.nav-logo-icon {
  width: 34px; height: 34px;
  border-radius: 8px;
  transition: transform 0.3s ease;
}

.nav-logo:hover .nav-logo-icon { transform: rotate(-8deg) scale(1.08); }

.nav-links {
  display: flex;
  gap: 8px;
}

.nav-link {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  position: relative;
  padding: 6px 16px;
  border-radius: 12px;
  transition: color 0.25s ease, background 0.25s ease;
}

.nav-link:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.06);
}

[data-theme="light"] .nav-link:hover {
  background: rgba(0, 0, 0, 0.04);
}

.nav-actions { display: flex; align-items: center; gap: 12px; }

.theme-toggle {
  width: 40px; height: 40px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-secondary);
  transition: color 0.2s, background 0.2s;
}

.theme-toggle:hover {
  color: var(--accent);
  background: var(--accent-glow);
}

[data-theme="dark"] .icon-sun { display: block; }
[data-theme="dark"] .icon-moon { display: none; }
[data-theme="light"] .icon-sun { display: none; }
[data-theme="light"] .icon-moon { display: block; }

.theme-toggle svg { width: 20px; height: 20px; }

.nav-login-btn {
  padding: 7px 22px;
  background: var(--accent);
  color: var(--bg-primary);
  font-weight: 600;
  font-size: 0.875rem;
  border-radius: 16px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  text-decoration: none;
  white-space: nowrap;
}

.nav-login-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 20px var(--accent-glow);
}

.nav-mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 28px;
  padding: 4px 0;
}

.nav-mobile-toggle span {
  display: block;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}

.nav-mobile-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.nav-mobile-toggle.active span:nth-child(2) { opacity: 0; }
.nav-mobile-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ---------- BUTTONS ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  border-radius: 12px;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}

.btn svg { width: 18px; height: 18px; transition: transform 0.25s ease; }
.btn:hover svg { transform: translateX(3px); }

.btn-primary {
  background: var(--accent);
  color: var(--bg-primary);
  box-shadow: 0 4px 24px var(--accent-glow);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 36px var(--accent-glow);
}

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

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

/* ---------- HERO ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: calc(var(--nav-height) + 40px) 24px 60px;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: var(--bg-primary);
}

#asciiGlobe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  pointer-events: none;
}

#particleBg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: default;
  touch-action: none;
}

#heroSparkle {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}

.hero-orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  z-index: 1;
  will-change: transform;
}

.hero-orb-1 {
  width: 500px;
  height: 500px;
  top: -10%;
  right: -8%;
  background: radial-gradient(circle, rgba(0, 212, 170, 0.12) 0%, transparent 70%);
  animation: orb-drift-1 18s ease-in-out infinite alternate;
}

.hero-orb-2 {
  width: 400px;
  height: 400px;
  bottom: -5%;
  left: -5%;
  background: radial-gradient(circle, rgba(240, 160, 48, 0.08) 0%, transparent 70%);
  animation: orb-drift-2 22s ease-in-out infinite alternate;
}

.hero-orb-3 {
  width: 300px;
  height: 300px;
  top: 30%;
  left: 20%;
  background: radial-gradient(circle, rgba(100, 140, 255, 0.06) 0%, transparent 70%);
  animation: orb-drift-3 15s ease-in-out infinite alternate;
}

[data-theme="light"] .hero-orb-1 {
  background: radial-gradient(circle, rgba(0, 168, 138, 0.08) 0%, transparent 70%);
}

[data-theme="light"] .hero-orb-2 {
  background: radial-gradient(circle, rgba(212, 138, 32, 0.06) 0%, transparent 70%);
}

[data-theme="light"] .hero-orb-3 {
  background: radial-gradient(circle, rgba(80, 120, 220, 0.05) 0%, transparent 70%);
}

@keyframes orb-drift-1 {
  0% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(-60px, 40px) scale(1.1); }
  66% { transform: translate(30px, -30px) scale(0.95); }
  100% { transform: translate(-40px, 20px) scale(1.05); }
}

@keyframes orb-drift-2 {
  0% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(50px, -30px) scale(1.08); }
  66% { transform: translate(-20px, 50px) scale(0.92); }
  100% { transform: translate(30px, -20px) scale(1.03); }
}

@keyframes orb-drift-3 {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(40px, 30px) scale(1.15); }
  100% { transform: translate(-30px, -40px) scale(0.9); }
}

.hero-gradient-overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  background: transparent;
  pointer-events: none;
}

.hero-artwork-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  opacity: 1;
}

.hero-artwork-bg--next {
  z-index: 1;
  opacity: 0;
  pointer-events: none;
}

.hero-artwork-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center;
  opacity: 0;
  display: block;
  transform: none !important;
  animation: none !important;
  transition: opacity 1.5s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: opacity;
  backface-visibility: hidden;
}

.hero-artwork-img.is-active {
  opacity: var(--artwork-opacity, 0.18);
}

[data-theme="light"] .hero-artwork-bg {
  opacity: 1;
}

[data-theme="light"] .hero-artwork-img.is-active {
  opacity: var(--artwork-light-opacity, 0.12);
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 800px;
  color: #f4f7fb;
}

.hero-content--left {
  text-align: left;
  align-self: flex-start;
  margin-left: max(24px, calc((100vw - 1200px) / 2 + 24px));
}

.hero-content--left .hero-actions {
  justify-content: flex-start;
}

.hero-content--left .hero-stats {
  justify-content: flex-start;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px 6px 12px;
  background: rgba(8, 13, 24, 0.46);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 100px;
  font-size: 0.8rem;
  font-family: var(--font-mono);
  color: rgba(244, 247, 251, 0.78);
  margin-bottom: 28px;
  backdrop-filter: blur(12px);
  animation: fadeInUp 0.8s ease both;
}

.hero-badge-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent-glow);
  animation: pulse-dot 2s ease infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.8); }
}

.hero-title {
  font-family: var(--font-display);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.04em;
  margin-bottom: 16px;
}

.hero-title-line {
  display: block;
  font-size: clamp(3.5rem, 10vw, 7rem);
  min-height: 1em;
  color: #f4f7fb;
  text-shadow: 0 8px 28px rgba(0, 0, 0, 0.32);
}

.hero-title-accent {
  color: var(--accent);
  text-shadow: 0 0 60px var(--accent-glow), 0 0 120px var(--accent-glow);
}

.typing-cursor {
  display: inline-block;
  width: 3px;
  height: 0.85em;
  background: var(--accent);
  margin-left: 4px;
  vertical-align: baseline;
  animation: blink-cursor 0.8s step-end infinite;
  box-shadow: 0 0 8px var(--accent-glow);
}

@keyframes blink-cursor {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.hero-slogan {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 3vw, 1.8rem);
  font-weight: 300;
  color: rgba(244, 247, 251, 0.82);
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.32);
  margin-bottom: 12px;
  animation: fadeInUp 0.8s ease 0.3s both;
}

.hero-desc {
  font-size: 0.95rem;
  color: rgba(244, 247, 251, 0.7);
  line-height: 1.7;
  margin-bottom: 36px;
  animation: fadeInUp 0.8s ease 0.4s both;
}

.hero-desc--visible {
  color: rgba(244, 247, 251, 0.82);
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.34);
  font-size: 1rem;
  letter-spacing: 0.02em;
}

[data-theme="light"] .hero-desc--visible {
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.34);
}

/* Adaptive text colors based on background brightness */
.hero-content--light-bg .hero-title-line,
.hero-content--light-bg .hero-slogan,
.hero-content--light-bg .hero-desc,
.hero-content--light-bg .hero-desc--visible,
.hero-content--light-bg .hero-stat-num,
.hero-content--light-bg .hero-stat-label,
.hero-content--light-bg .hero-scroll-hint,
.hero-content--light-bg .hero-badge {
  color: #1a1a2e;
  text-shadow: 0 1px 4px rgba(255, 255, 255, 0.6);
}

.hero-content--light-bg .hero-title-accent {
  color: #007a5e;
  text-shadow: 0 0 40px rgba(0, 168, 138, 0.35), 0 0 80px rgba(0, 168, 138, 0.2);
}

.hero-content--light-bg .hero-stat-suffix {
  color: #007a5e;
}

.hero-content--light-bg .typing-cursor {
  background: #007a5e;
  box-shadow: 0 0 8px rgba(0, 168, 138, 0.4);
}

.hero-content--light-bg .hero-badge {
  background: rgba(255, 255, 255, 0.25);
  border-color: rgba(255, 255, 255, 0.35);
}

.hero-content--light-bg .hero-badge-dot {
  background: #007a5e;
}

.hero-content--light-bg .btn-ghost {
  border-color: rgba(26, 26, 46, 0.25);
  color: #1a1a2e;
}

.hero-content--light-bg .btn-ghost:hover {
  background: rgba(26, 26, 46, 0.08);
  border-color: rgba(26, 26, 46, 0.4);
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 56px;
  animation: fadeInUp 0.8s ease 0.5s both;
}

.hero-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 48px;
  animation: fadeInUp 0.8s ease 0.6s both;
}

.hero-stat { text-align: center; }

.hero-stat-num {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 800;
  color: #f4f7fb;
  text-shadow: 0 4px 18px rgba(0, 0, 0, 0.32);
  letter-spacing: -0.03em;
}

.hero-stat-suffix {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
}

.hero-stat-label {
  display: block;
  font-size: 0.78rem;
  color: rgba(244, 247, 251, 0.64);
  margin-top: 2px;
  font-weight: 500;
}

.hero-scroll-hint {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  color: rgba(244, 247, 251, 0.7);
  font-size: 0.75rem;
  font-family: var(--font-mono);
  animation: fadeInUp 0.8s ease 0.8s both;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.42);
}

.scroll-line {
  display: none;
}

.scroll-arrow {
  width: 18px;
  height: 18px;
  color: var(--accent);
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
  opacity: 0.82;
  filter: drop-shadow(0 0 6px rgba(0, 212, 170, 0.28));
  animation: scroll-arrow 1.8s ease-in-out infinite;
}

@keyframes scroll-line {
  0% { opacity: 0; transform: scaleY(0); transform-origin: top; }
  50% { opacity: 1; transform: scaleY(1); transform-origin: top; }
  100% { opacity: 0; transform: scaleY(1); transform-origin: bottom; }
}

@keyframes scroll-arrow {
  0%, 100% { opacity: 0.55; transform: translateY(-1px); }
  50% { opacity: 1; transform: translateY(2px); }
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ---------- SECTIONS (shared) ---------- */
.section {
  position: relative;
  padding: 120px 0;
}

.section-header {
  text-align: center;
  margin-bottom: 64px;
}

.section-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  padding: 4px 14px;
  border: 1px solid var(--accent);
  border-radius: 100px;
  margin-bottom: 16px;
  background: rgba(0, 212, 170, 0.06);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
}

.section-desc {
  font-size: 1rem;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto;
}

/* ---------- FEATURES ---------- */
.features {
  background: var(--bg-secondary);
  position: relative;
}

.features::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-glow), var(--accent), var(--accent-glow), transparent);
}

/* ---------- FEATURES (CURSOR STYLE) ---------- */
.cursor-features {
  padding: 120px 0;
  position: relative;
  background: var(--bg-primary);
}

.feature-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  margin-bottom: 160px;
}

.feature-hero.reverse {
  grid-template-columns: 1fr 1fr;
  direction: rtl;
}

.feature-hero.reverse > * {
  direction: ltr;
}

.feature-hero-text {
  max-width: 500px;
}

.feature-hero-tag {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--accent);
  margin-bottom: 16px;
  display: block;
}

.feature-hero-title {
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 24px;
  line-height: 1.1;
}

.feature-hero-desc {
  font-size: 1.1rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.feature-hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.feature-visual-mockup {
  width: 100%;
  background: transparent;
  border: none;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  box-shadow: none;
}

.feature-visual-mockup svg {
  width: 64px;
  height: 64px;
  color: var(--text-primary);
  opacity: 0.8;
  margin-bottom: 24px;
}

.mockup-code {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-secondary);
  background: rgba(0,0,0,0.5);
  padding: 12px 20px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.05);
  text-align: left;
}

.terminal-mockup {
  align-items: stretch;
  justify-content: flex-start;
  background: #111;
}

.terminal-header {
  height: 40px;
  background: #1a1a1a;
  border-bottom: 1px solid #333;
  display: flex;
  align-items: center;
  padding: 0 16px;
  gap: 8px;
}

.terminal-header .dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ff5f56;
}

.terminal-header .dot:nth-child(2) { background: #ffbd2e; }
.terminal-header .dot:nth-child(3) { background: #27c93f; }

.terminal-body {
  padding: 20px;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: #ddd;
  line-height: 1.5;
  text-align: left;
}

.terminal-body p { margin: 0 0 8px 0; }
.terminal-body p span { color: var(--accent); margin-right: 8px; }
.terminal-body .output { color: #888; margin-bottom: 16px; }
.terminal-body .output.success { color: var(--accent); }
.terminal-body .output.warning { color: #f0a030; }

.local-terminal .terminal-body p span { color: #f0a030; }

.features-matrix {
  margin-top: 80px;
  padding-top: 80px;
  border-top: 1px solid var(--border);
}

.matrix-header {
  text-align: center;
  margin-bottom: 60px;
}

.matrix-title {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 500;
  color: var(--text-primary);
}

/* Feature card styles for fallback / legacy */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.feature-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 28px;
  transition: all 0.35s ease;
  overflow: hidden;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transform-style: preserve-3d;
  perspective: 800px;
}

.feature-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(255,255,255,0.04) 0%, transparent 50%);
  pointer-events: none;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent);
  opacity: 0;
  transition: opacity 0.35s ease;
}

.feature-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow-md),
              0 0 40px rgba(0, 212, 170, 0.06);
}

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

.feature-card-glow {
  position: absolute;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle, var(--accent-glow), transparent 70%);
  opacity: 0;
  transition: opacity 0.3s ease;
  transform: translate(-50%, -50%);
  z-index: 0;
}

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

.feature-card-highlight {
  border-color: var(--accent);
  background: linear-gradient(135deg, var(--bg-card), var(--accent-glow));
}

.feature-card-highlight::before {
  opacity: 1;
  background: linear-gradient(90deg, var(--accent-secondary), var(--accent));
}

.feature-icon {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 12px;
  background: var(--accent-glow);
  color: var(--accent);
  margin-bottom: 18px;
  transition: transform 0.3s ease, background 0.3s ease;
}

.feature-card:hover .feature-icon {
  transform: scale(1.1) rotate(-4deg);
  background: var(--accent);
  color: var(--bg-primary);
}

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

.feature-name {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.feature-desc {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 14px;
}

.feature-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-tertiary);
  background: var(--bg-primary);
  padding: 3px 10px;
  border-radius: 6px;
  letter-spacing: 0.02em;
}

/* ---------- PLATFORMS ---------- */
.platform-showcase {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.platform-main {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: border-color 0.3s ease;
}

.platform-main:hover { border-color: var(--accent); }

.platform-img-wrap {
  position: relative;
  padding: 20px;
}

.platform-img-wrap img {
  width: 100%;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
}

.platform-img-glow {
  position: absolute;
  bottom: -40px;
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  height: 80px;
  background: var(--accent-glow);
  filter: blur(40px);
  pointer-events: none;
}

.platform-img-wrap-sm { padding: 12px; }

.platform-info {
  padding: 0 24px 24px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.platform-main .platform-info { padding: 0 28px 28px; }

.platform-name {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
}

.platform-main .platform-name { font-size: 1.25rem; }

.platform-desc {
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin-left: auto;
}

.platform-badge {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 6px;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.platform-badge-live {
  background: var(--accent);
  color: var(--bg-primary);
}

.platform-badge-dev {
  background: var(--accent-secondary);
  color: var(--bg-primary);
}

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

.platform-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all 0.35s ease;
}

.platform-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-hover);
  box-shadow: var(--shadow-md);
}

.platform-card .platform-info {
  padding: 0 16px 16px;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
}

.platform-card .platform-name { font-size: 0.95rem; }

.platform-extras {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-top: 24px;
}

.platform-extra-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  transition: all 0.3s ease;
}

.platform-extra-card:hover {
  border-color: var(--accent);
  background: var(--bg-card-hover);
  transform: translateY(-2px);
}

.platform-extra-icon {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 12px;
  background: var(--accent-glow);
  color: var(--accent);
  flex-shrink: 0;
}

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

.platform-extra-info { flex: 1; }
.platform-extra-info h4 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
}
.platform-extra-info p {
  font-size: 0.82rem;
  color: var(--text-tertiary);
}

/* ---------- BENTO GRID ---------- */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  grid-auto-rows: 340px;
  gap: 20px;
  max-width: 1100px;
  margin: 40px auto 0;
}

/* 6 Items varied Bento Layout */
.bento-item:nth-child(1) { grid-column: span 4; }
.bento-item:nth-child(2) { grid-column: span 2; }
.bento-item:nth-child(3) { grid-column: span 2; }
.bento-item:nth-child(4) { grid-column: span 4; }
.bento-item:nth-child(5) { grid-column: span 3; }
.bento-item:nth-child(6) { grid-column: span 3; }

.bento-item {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 24px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1),
              border-color 0.4s ease, box-shadow 0.4s ease;
  backdrop-filter: blur(20px) saturate(1.4);
  -webkit-backdrop-filter: blur(20px) saturate(1.4);
}

.bento-item::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.03) 0%, transparent 50%);
  pointer-events: none;
}

.bento-item:hover {
  transform: translateY(-6px);
  border-color: var(--accent);
  box-shadow: 0 20px 40px rgba(0,0,0,0.2), 0 0 0 1px rgba(0, 212, 170, 0.2) inset;
}

.bento-content {
  padding: 32px;
  z-index: 2;
  position: relative;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.bento-content h3 {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 12px;
}

.bento-content p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.5;
  margin-bottom: 20px;
  max-width: 100%;
}

.bento-status {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 700;
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: auto;
  align-self: flex-start;
}

/* Live and Dev tags removed as requested by user */
.bento-status.dev {
  background: var(--accent-secondary);
  color: var(--bg-primary);
}

.bento-action {
  margin-top: auto;
}

.bento-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 18px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.85rem;
  border-radius: 10px;
  background: var(--accent);
  color: var(--bg-primary);
  transition: all 0.25s ease;
  text-decoration: none;
  white-space: nowrap;
}
.bento-btn svg { width: 16px; height: 16px; }
.bento-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px var(--accent-glow);
}

.bento-large {
  grid-column: span 2;
  grid-row: span 2;
}

.bento-medium {
  grid-column: span 2;
  grid-row: span 1;
}

.bento-small {
  grid-column: span 1;
  grid-row: span 1;
}

.bento-visual {
  position: absolute;
  bottom: 0;
  right: 0;
  z-index: 1;
  transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  transform-origin: bottom right;
}

/* Wide bento items (span 4, span 3) */
.bento-item:nth-child(1) .bento-visual,
.bento-item:nth-child(4) .bento-visual,
.bento-item:nth-child(5) .bento-visual,
.bento-item:nth-child(6) .bento-visual {
  width: 55%;
  height: 85%;
  right: -2%;
  bottom: -5%;
}
.bento-item:nth-child(1) .bento-content,
.bento-item:nth-child(4) .bento-content,
.bento-item:nth-child(5) .bento-content,
.bento-item:nth-child(6) .bento-content {
  width: 50%; /* Prevent text from overlapping the 55% image */
}

/* Narrow bento items (span 2) */
.bento-item:nth-child(2) .bento-visual,
.bento-item:nth-child(3) .bento-visual {
  width: 90%;
  height: 45%;
  right: -5%;
  bottom: -5%;
}
.bento-item:nth-child(2) .bento-content,
.bento-item:nth-child(3) .bento-content {
  height: 55%;
  padding-bottom: 24px;
}

.bento-item:hover .bento-visual {
  transform: scale(1.05) translate(-2%, -2%);
}

.bento-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top left;
  border-top-left-radius: 12px;
  border-bottom-right-radius: 12px;
  box-shadow: -8px -8px 24px rgba(0,0,0,0.4);
}

.bento-icon {
  font-size: 3rem;
  color: var(--border-hover);
  position: absolute;
  bottom: 24px;
  right: 24px;
  transition: color 0.4s ease, transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  z-index: 1;
}

.bento-icon svg {
  width: 64px;
  height: 64px;
}

.bento-item:hover .bento-icon {
  color: var(--accent);
  transform: scale(1.1) rotate(-5deg);
}

@media (max-width: 1024px) {
  .bento-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: minmax(240px, auto);
  }
  .bento-large, .bento-medium {
    grid-column: span 2;
  }
  .bento-small {
    grid-column: span 1;
  }
  .bento-visual {
    position: relative;
    width: 100%;
    height: 200px;
    right: 0;
    bottom: -20px;
    margin-top: 20px;
  }
  .bento-large .bento-visual, .bento-medium .bento-visual {
    width: 90%;
    right: -5%;
  }
}

@media (max-width: 768px) {
  .bento-grid {
    grid-template-columns: 1fr;
  }
  .bento-large, .bento-medium, .bento-small {
    grid-column: span 1;
  }
}

.cflow-download--ghost {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
}
.cflow-download--ghost:hover {
  background: var(--accent-glow);
}

.cflow-soon {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--accent-secondary);
  padding: 8px 16px;
  border: 1px dashed var(--accent-secondary);
  border-radius: 10px;
  white-space: nowrap;
  opacity: 0.7;
}

/* ---------- ARCHITECTURE ---------- */
.architecture {
  background: var(--bg-secondary);
  position: relative;
}

.architecture::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-secondary-glow), var(--accent-secondary), var(--accent-secondary-glow), transparent);
}

.arch-canvas-wrap {
  position: relative;
  width: 100%;
  height: 420px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.arch-canvas-wrap::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.02) 0%, transparent 50%);
  pointer-events: none;
  border-radius: inherit;
  z-index: 1;
}

#archCanvas {
  width: 100%;
  height: 100%;
  display: block;
}

/* ---------- PRICING (CURSOR STYLE) ---------- */
.cursor-pricing {
  padding: 120px 0;
  position: relative;
  background: var(--bg-primary);
}

.cursor-header {
  text-align: center;
  margin-bottom: 60px;
}

.cursor-header .section-title {
  font-size: 3rem;
  font-weight: 500;
  margin-bottom: 30px;
  color: var(--text-primary);
}

.pricing-toggle {
  display: inline-flex;
  align-items: center;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 4px;
}

.toggle-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  padding: 8px 16px;
  border-radius: 16px;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.toggle-btn.active {
  background: var(--accent);
  color: var(--bg-primary);
  font-weight: 600;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  max-width: 1000px;
  margin: 0 auto;
}

.cursor-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 32px;
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.cursor-card:hover {
  border-color: var(--accent);
  box-shadow: 0 4px 20px rgba(0, 212, 170, 0.05);
}

.pricing-card-header {
  margin-bottom: 24px;
}

.pricing-name {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.pricing-subtitle {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.pricing-price {
  display: flex;
  align-items: baseline;
  gap: 2px;
}

.price-currency {
  font-size: 1.2rem;
  color: var(--text-primary);
  font-weight: 400;
}

.price-value {
  font-size: 2.5rem;
  font-weight: 400;
  color: var(--text-primary);
  line-height: 1;
}

.price-period {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.pricing-card-body {
  flex-grow: 1;
  margin-bottom: 32px;
  border-top: 1px solid var(--border);
  padding-top: 24px;
}

.pricing-includes {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.pricing-features {
  list-style: none;
  padding: 0;
  margin: 0;
}

.pricing-features:not(.expanded) li:nth-child(n+5) {
  display: none;
}

.pricing-more-btn {
  background: none;
  border: none;
  color: var(--accent);
  font-size: 0.85rem;
  cursor: pointer;
  padding: 0;
  margin-top: 12px;
  font-weight: 500;
}

.pricing-more-btn:hover {
  text-decoration: underline;
}

.pricing-features li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.4;
}

.pricing-features li strong {
  color: var(--text-primary);
  font-weight: 500;
}

.pricing-features li svg {
  width: 14px;
  height: 14px;
  color: var(--accent);
  flex-shrink: 0;
  margin-top: 4px;
}

.cursor-btn {
  width: 100%;
  justify-content: center;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  padding: 12px;
  border-radius: 6px;
  background: var(--accent);
  color: var(--bg-primary);
  border: none;
  transition: opacity 0.2s ease;
  font-weight: 600;
  cursor: pointer;
}

.cursor-btn:hover {
  opacity: 0.9;
}

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

.cursor-btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent);
}

/* ---------- CTA ---------- */
.cta { padding: 100px 0; }

.cta-inner {
  position: relative;
  text-align: center;
  padding: 72px 40px;
  border-radius: var(--radius-xl);
  background: var(--bg-card);
  border: 1px solid var(--border);
  overflow: hidden;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.cta-glow {
  position: absolute;
  top: -80px;
  left: 50%;
  transform: translateX(-50%);
  width: 400px; height: 200px;
  background: var(--accent);
  filter: blur(120px);
  opacity: 0.15;
  pointer-events: none;
  animation: cta-glow-pulse 6s ease-in-out infinite alternate;
}

.cta-glow-2 {
  top: auto;
  bottom: -60px;
  left: 10%;
  width: 300px;
  height: 150px;
  background: var(--accent-secondary);
  opacity: 0.1;
  animation-delay: -2s;
  animation-duration: 8s;
}

.cta-glow-3 {
  top: 20%;
  left: auto;
  right: 5%;
  width: 250px;
  height: 250px;
  background: rgba(100, 140, 255, 0.8);
  opacity: 0.06;
  animation-delay: -4s;
  animation-duration: 10s;
}

@keyframes cta-glow-pulse {
  0% { opacity: 0.1; transform: translateX(-50%) scale(1); }
  100% { opacity: 0.2; transform: translateX(-50%) scale(1.15); }
}

.cta-mesh {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
  mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, black 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, black 20%, transparent 70%);
}

.cta-title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4vw, 2.2rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
  position: relative;
}

.cta-desc {
  color: var(--text-secondary);
  margin-bottom: 32px;
  font-size: 1rem;
  position: relative;
}

.cta-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  position: relative;
}

/* ---------- FOOTER ---------- */
.footer {
  padding: 64px 0 32px;
  border-top: 1px solid var(--border);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 48px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 12px;
}

.footer-logo img {
  width: 30px; height: 30px;
  border-radius: 7px;
}

.footer-tagline {
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.footer-copy {
  font-size: 0.78rem;
  color: var(--text-tertiary);
}

.footer-col h4 {
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 14px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.footer-col a {
  display: block;
  font-size: 0.88rem;
  color: var(--text-tertiary);
  padding: 4px 0;
  transition: color 0.2s ease;
}

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

.footer-bottom {
  text-align: center;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  font-size: 0.78rem;
  color: var(--text-tertiary);
}

/* ---------- REVEAL ANIMATION ---------- */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1024px) {
  .platform-grid { grid-template-columns: repeat(2, 1fr); }
  .platform-grid .platform-card:last-child {
    grid-column: span 2;
    max-width: 50%;
    margin: 0 auto;
  }
  .footer-grid { grid-template-columns: 1.5fr 1fr 1fr; }
  .footer-grid .footer-col:last-child { grid-column: span 1; }
}

@media (max-width: 768px) {
  .nav {
    top: 10px;
    left: 12px;
    right: 12px;
    transform: none;
    max-width: none;
    width: auto;
    padding: 0;
  }

  .nav-glass {
    min-width: unset;
    gap: 0;
    padding: 0 14px;
    border-radius: 18px;
  }

  .nav-logo-text { display: none; }

  .nav-links { display: none; }
  .nav-mobile-toggle { display: flex; }
  
  .nav-links.mobile-open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: rgba(10, 16, 28, 0.92);
    backdrop-filter: blur(28px) saturate(1.6);
    -webkit-backdrop-filter: blur(28px) saturate(1.6);
    padding: 14px 18px;
    gap: 4px;
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  }

  [data-theme="light"] .nav-links.mobile-open {
    background: rgba(255, 255, 255, 0.92);
    border-color: rgba(0, 0, 0, 0.08);
  }

  .nav-links.mobile-open .nav-link {
    padding: 12px 16px;
    font-size: 1rem;
  }

  .hero {
    min-height: 100svh;
    padding: calc(var(--nav-height) + 20px) 16px 40px;
  }

  .hero-badge {
    font-size: 0.72rem;
    padding: 5px 12px 5px 10px;
    margin-bottom: 20px;
  }

  .hero-title {
    margin-bottom: 12px;
  }

  .hero-title-line {
    font-size: clamp(2.4rem, 11vw, 3.5rem);
  }

  .hero-slogan {
    font-size: clamp(1rem, 3.5vw, 1.3rem);
    margin-bottom: 8px;
  }

  .hero-desc,
  .hero-desc--visible {
    font-size: 0.88rem;
    line-height: 1.6;
    margin-bottom: 24px;
  }

  .hero-actions {
    flex-direction: column;
    gap: 10px;
    margin-bottom: 32px;
    width: 100%;
  }

  .hero-actions .btn {
    width: 100%;
    justify-content: center;
    padding: 12px 20px;
  }

  .hero-stats {
    gap: 24px;
    flex-wrap: wrap;
    justify-content: center;
  }

  .hero-stat-num { font-size: 1.4rem; }
  .hero-stat-suffix { font-size: 1.1rem; }
  .hero-stat-label { font-size: 0.72rem; }

  .hero-scroll-hint {
    bottom: 16px;
    font-size: 0.68rem;
  }

  .scroll-line { height: 28px; }

  .section {
    padding: 64px 0;
  }

  .section-header {
    margin-bottom: 36px;
  }

  .section-tag {
    font-size: 0.68rem;
    padding: 3px 10px;
  }

  .section-title {
    font-size: clamp(1.5rem, 5vw, 2rem);
  }

  .section-desc {
    font-size: 0.88rem;
  }

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

  .feature-card {
    padding: 20px;
  }

  .feature-icon {
    width: 36px;
    height: 36px;
    margin-bottom: 10px;
  }

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

  .feature-name {
    font-size: 1rem;
    margin-bottom: 4px;
  }

  .feature-desc {
    font-size: 0.82rem;
    line-height: 1.5;
    margin-bottom: 8px;
  }

  .feature-tag {
    font-size: 0.68rem;
  }

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

  .platform-grid .platform-card:last-child { max-width: 100%; }

  .platform-card {
    border-radius: var(--radius-md);
  }

  .platform-card:hover {
    transform: none;
  }

  .platform-extras {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .platform-extra-card {
    padding: 14px 16px;
    gap: 12px;
  }

  .platform-extra-card:hover {
    transform: none;
  }

  .platform-extra-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
  }

  .platform-extra-icon svg { width: 18px; height: 18px; }

  .platform-extra-info h4 { font-size: 0.92rem; }
  .platform-extra-info p { font-size: 0.78rem; }

  .coverflow-viewport {
    height: 280px;
    perspective: 900px;
  }

  .coverflow-slide {
    width: 300px;
    height: 260px;
  }

  .coverflow-slide[data-pos="0"] {
    transform: translateX(-50%) translateZ(20px) rotateY(0deg) scale(1);
    filter: brightness(1);
  }

  .coverflow-slide[data-pos="-1"] {
    transform: translateX(calc(-50% - 180px)) translateZ(-120px) rotateY(35deg) scale(0.82);
    filter: brightness(0.7);
  }

  .coverflow-slide[data-pos="1"] {
    transform: translateX(calc(-50% + 180px)) translateZ(-120px) rotateY(-35deg) scale(0.82);
    filter: brightness(0.7);
  }

  .coverflow-slide[data-pos="-2"],
  .coverflow-slide[data-pos="2"] {
    opacity: 0;
    pointer-events: none;
    filter: brightness(0.5);
  }

  .coverflow-card-screen {
    height: 210px;
    border-radius: 14px;
  }

  .coverflow-card-reflect {
    height: 30px;
    margin-top: 6px;
  }

  .coverflow-controls {
    gap: 14px;
    margin-top: 0;
  }

  .coverflow-btn {
    width: 38px;
    height: 38px;
  }

  .coverflow-btn svg { width: 16px; height: 16px; }

  .coverflow-info {
    margin-top: 12px;
    min-height: auto;
  }

  .coverflow-info-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding: 16px 18px;
  }

  .coverflow-info-name {
    font-size: 1.05rem;
  }

  .coverflow-info-desc {
    font-size: 0.82rem;
  }

  .coverflow-info-right {
    width: 100%;
    flex-wrap: wrap;
  }

  .cflow-download {
    padding: 8px 14px;
    font-size: 0.8rem;
  }

  .cflow-soon {
    font-size: 0.78rem;
    padding: 6px 12px;
  }

  .arch-canvas-wrap {
    height: 320px;
    border-radius: var(--radius-md);
  }

  .cta { padding: 64px 0; }

  .cta-inner {
    padding: 40px 20px;
    border-radius: var(--radius-lg);
  }

  .cta-glow {
    width: 250px;
    height: 120px;
    top: -50px;
  }

  .cta-title {
    font-size: clamp(1.3rem, 5vw, 1.8rem);
  }

  .cta-desc {
    font-size: 0.88rem;
    margin-bottom: 24px;
  }

  .cta-actions {
    flex-direction: column;
    gap: 10px;
  }

  .cta-actions .btn {
    width: 100%;
    justify-content: center;
    padding: 12px 20px;
  }

  .footer {
    padding: 40px 0 24px;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 32px;
  }

  .footer-brand { grid-column: span 2; }

  .footer-logo { font-size: 1rem; margin-bottom: 8px; }
  .footer-logo img { width: 26px; height: 26px; }
  .footer-tagline { font-size: 0.82rem; }
  .footer-col h4 { font-size: 0.78rem; margin-bottom: 10px; }
  .footer-col a { font-size: 0.82rem; padding: 3px 0; }
}

@media (max-width: 480px) {
  .nav {
    top: 6px;
    left: 8px;
    right: 8px;
  }

  .nav-glass {
    padding: 0 10px;
    border-radius: 14px;
  }

  .hero {
    padding: calc(var(--nav-height) + 12px) 12px 32px;
  }

  .hero-title-line {
    font-size: clamp(2rem, 12vw, 3rem);
  }

  .hero-slogan {
    font-size: clamp(0.9rem, 4vw, 1.1rem);
  }

  .hero-desc,
  .hero-desc--visible {
    font-size: 0.82rem;
  }

  .hero-stats {
    flex-direction: column;
    gap: 12px;
  }

  .hero-stat-num { font-size: 1.2rem; }
  .hero-stat-suffix { font-size: 1rem; }

  .section {
    padding: 48px 0;
  }

  .section-header {
    margin-bottom: 28px;
  }

  .feature-card {
    padding: 16px;
  }

  .coverflow-viewport {
    height: 230px;
  }

  .coverflow-slide {
    width: 250px;
    height: 220px;
  }

  .coverflow-slide[data-pos="0"] {
    transform: translateX(-50%) translateZ(10px) rotateY(0deg) scale(1);
    filter: brightness(1);
  }

  .coverflow-slide[data-pos="-1"] {
    transform: translateX(calc(-50% - 140px)) translateZ(-80px) rotateY(30deg) scale(0.8);
    filter: brightness(0.7);
  }

  .coverflow-slide[data-pos="1"] {
    transform: translateX(calc(-50% + 140px)) translateZ(-80px) rotateY(-30deg) scale(0.8);
    filter: brightness(0.7);
  }

  .coverflow-card-screen {
    height: 170px;
    border-radius: 12px;
  }

  .coverflow-card-reflect {
    height: 20px;
    margin-top: 4px;
  }

  .coverflow-info-inner {
    padding: 12px 14px;
  }

  .arch-canvas-wrap {
    height: 260px;
  }

  .cta-inner {
    padding: 32px 16px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .footer-brand { grid-column: span 1; }

  .platform-extra-card {
    padding: 12px 14px;
  }

  .platform-extra-icon {
    width: 32px;
    height: 32px;
  }

  .pricing-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .pricing-card-item {
    padding: 24px;
  }
}

@media (max-width: 768px) {
  .hero-content--light-bg .hero-title-line,
  .hero-content--light-bg .hero-slogan,
  .hero-content--light-bg .hero-desc,
  .hero-content--light-bg .hero-desc--visible,
  .hero-content--light-bg .hero-stat-num,
  .hero-content--light-bg .hero-stat-label,
  .hero-content--light-bg .hero-scroll-hint,
  .hero-content--light-bg .hero-badge {
    text-shadow: 0 1px 6px rgba(255, 255, 255, 0.8), 0 2px 12px rgba(255, 255, 255, 0.4);
  }
}

@media (max-width: 768px) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .platform-card,
  .feature-card,
  .platform-extra-card {
    transition: none;
  }

  .coverflow-slide[data-pos="0"] .coverflow-card {
    animation: none;
  }

  .hero-artwork-bg,
  .hero-artwork-bg--next {
    animation: none;
  }

  .hero-orb {
    display: none;
  }

  #heroSparkle {
    display: none;
  }

  .feature-card {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  .feature-card-glow {
    display: none;
  }

  .feature-hero,
  .feature-hero.reverse {
    grid-template-columns: 1fr;
    gap: 40px;
    margin-bottom: 80px;
    direction: ltr;
  }
  
  .feature-hero-title {
    font-size: 2.2rem;
  }
  
  .features-matrix {
    margin-top: 40px;
    padding-top: 40px;
  }

  body::after {
    display: none;
  }
}

/* ---------- NOISE TEXTURE OVERLAY ---------- */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.018;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 200px 200px;
}

[data-theme="light"] body::after { opacity: 0.012; }

/* ---------- SELECTION ---------- */
::selection {
  background: var(--accent);
  color: var(--bg-primary);
}

/* ---------- SCROLLBAR ---------- */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-primary); }
::-webkit-scrollbar-thumb {
  background: var(--text-tertiary);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover { background: var(--text-secondary); }

/* ---------- LLM MODELS SECTION ---------- */
.llm-models {
  background: var(--bg-primary);
  position: relative;
  overflow: hidden;
  min-height: 100vh;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.llm-models::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-glow), var(--accent), var(--accent-glow), transparent);
}

.llm-canvas-wrap {
  position: absolute;
  inset: 0;
  z-index: 1;
}

#llmCanvas {
  width: 100%;
  height: 100%;
  display: block;
}

.llm-content {
  position: relative;
  z-index: 2;
  width: 100%;
  pointer-events: none;
}

.llm-content .section-header {
  margin-bottom: 48px;
}

.llm-provider-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  flex-wrap: wrap;
  padding: 16px 28px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 100px;
  backdrop-filter: blur(16px) saturate(1.3);
  -webkit-backdrop-filter: blur(16px) saturate(1.3);
  pointer-events: auto;
  width: fit-content;
  margin: 0 auto;
  position: relative;
  overflow: hidden;
}

.llm-provider-bar::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0.6;
}

.llm-provider-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-secondary);
  transition: color 0.3s ease;
  white-space: nowrap;
}

.llm-provider-item:hover {
  color: var(--text-primary);
}

.llm-provider-logo {
  width: 22px;
  height: 22px;
  object-fit: contain;
}

.llm-search-icon {
  width: 18px;
  height: 18px;
  color: var(--accent);
}

.llm-provider-divider {
  width: 1px;
  height: 20px;
  background: var(--border);
  flex-shrink: 0;
}

/* Light mode adjustments for Cursor Features */
[data-theme="light"] .cursor-features {
  background: #fff;
}
[data-theme="light"] .feature-visual-mockup {
  background: #fff;
}
[data-theme="light"] .feature-hero-title {
  color: #111;
}
[data-theme="light"] .terminal-mockup {
  background: #f8f9fa;
  border-color: #eaeaea;
}
[data-theme="light"] .terminal-header {
  background: #eaeaea;
  border-bottom: 1px solid #ddd;
}
[data-theme="light"] .terminal-body {
  color: #333;
}
[data-theme="light"] .matrix-title {
  color: #111;
}

/* Responsive */
@media (max-width: 768px) {
  .llm-models {
    min-height: auto;
    padding: 80px 0;
  }

  .llm-provider-bar {
    padding: 12px 16px;
    border-radius: var(--radius-lg);
    width: 90%;
    margin: 0 auto;
    justify-content: center;
  }

  .llm-provider-item {
    font-size: 0.78rem;
    padding: 6px 10px;
  }

  .llm-provider-logo {
    width: 18px;
    height: 18px;
  }

  .llm-search-icon {
    width: 16px;
    height: 16px;
  }

  .llm-provider-divider {
    height: 16px;
  }
}


/* =========================================
   COMPREHENSIVE MOBILE FIXES
   ========================================= */
@media (max-width: 768px) {
  /* 1. Navbar Fixes */
  .nav {
    left: 16px !important;
    right: 16px !important;
    width: auto !important;
    padding: 0 !important;
    max-width: none !important;
  }
  .nav-glass {
    width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
  }

  /* 2. Products (Bento Grid) Fixes */
  .bento-grid {
    grid-template-columns: 1fr !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 16px !important;
  }
  .bento-item {
    display: flex !important;
    flex-direction: column !important;
    height: auto !important;
    grid-column: span 1 !important;
    grid-row: auto !important;
  }
  .bento-content {
    width: 100% !important;
    height: auto !important;
    padding-bottom: 0 !important;
  }
  .bento-visual {
    position: relative !important;
    width: 100% !important;
    height: 200px !important;
    right: 0 !important;
    bottom: 0 !important;
    margin-top: 16px !important;
    transform: none !important;
  }
  .bento-visual img {
    border-radius: 12px !important;
  }
  .bento-item:nth-child(n) .bento-visual {
    width: 100% !important;
    height: 200px !important;
    right: 0 !important;
    bottom: 0 !important;
  }
  .bento-item:nth-child(n) .bento-content {
    width: 100% !important;
    height: auto !important;
  }

  /* 3. Features Fixes */
  .features-grid {
    grid-template-columns: 1fr !important;
    display: flex !important;
    flex-direction: column !important;
  }
  .feature-hero {
    grid-template-columns: 1fr !important;
    display: flex !important;
    flex-direction: column !important;
  }
  .feature-visual-mockup {
    width: 100% !important;
    height: auto !important;
    min-height: 200px !important;
  }

  /* 4. Architecture (LLM Models) Fixes */
  .llm-provider-bar {
    width: 100% !important;
    max-width: 100% !important;
    border-radius: 16px !important;
    padding: 12px !important;
    justify-content: center !important;
  }
  .llm-provider-item {
    padding: 6px 8px !important;
    font-size: 0.75rem !important;
  }
  .llm-search-icon {
    display: none !important; /* Hide icon on mobile to save space */
  }
  .llm-provider-divider {
    display: none !important; /* Hide dividers to let flex-wrap work better */
  }
}

@media (max-width: 768px) {
  /* Fix Architecture canvas height so nodes don't overlap */
  .arch-canvas-wrap {
    height: 520px !important;
  }

  /* Fix Navbar login button size to align better with hamburger menu */
  .nav-login-btn {
    padding: 4px 12px !important;
    font-size: 0.8rem !important;
    border-radius: 12px !important;
  }
  .nav-actions {
    gap: 8px !important;
  }
}
