:root {
  --bg: #0a0406;
  --bg-card: #110810;
  --bg-elevated: #180c14;
  --cherry: #c8102e;
  --cherry-bright: #ff1a3a;
  --cherry-glow: rgba(200, 16, 46, 0.4);
  --cherry-dim: rgba(200, 16, 46, 0.08);
  --cherry-dark: #6b0a1a;
  --fg: #ede4e6;
  --fg-dim: #8a7478;
  --fg-muted: #5c4a4e;
  --border: rgba(200, 16, 46, 0.12);
  --border-hover: rgba(200, 16, 46, 0.3);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: "JetBrains Mono", monospace;
  font-size: 15px;
  line-height: 1.65;
  color: var(--fg);
  background: var(--bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

.scanlines {
  position: fixed;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 0, 0, 0.03) 2px,
    rgba(0, 0, 0, 0.03) 4px
  );
  pointer-events: none;
  z-index: 9999;
}

.noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9998;
  opacity: 0.035;
  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: 256px 256px;
}

.vignette {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9997;
  background: radial-gradient(ellipse at center, transparent 50%, rgba(0, 0, 0, 0.5) 100%);
}

nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 2.5rem;
  background: rgba(10, 4, 6, 0.85);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  text-decoration: none;
  font-family: "Syne", sans-serif;
  font-weight: 800;
  font-size: 1.3rem;
  letter-spacing: -0.03em;
}

.logo-cherry { color: var(--cherry-bright); }

.logo-dot {
  color: var(--fg-dim);
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  50% { opacity: 0; }
}

.nav-links {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.nav-links a {
  color: var(--fg-dim);
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: color 0.2s;
}

.nav-links a:hover {
  color: var(--cherry-bright);
}

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 6rem 2rem 4rem;
  position: relative;
  background:
    radial-gradient(ellipse 60% 40% at 50% 30%, rgba(200, 16, 46, 0.06), transparent),
    radial-gradient(ellipse 80% 60% at 20% 80%, rgba(107, 10, 26, 0.04), transparent),
    radial-gradient(ellipse 50% 50% at 80% 20%, rgba(255, 26, 58, 0.03), transparent);
}

.hero-inner { max-width: 780px; }

.hero-version {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--cherry);
  border: 1px solid var(--border-hover);
  padding: 0.3em 1em;
  margin-bottom: 2rem;
  background: var(--cherry-dim);
}

.hero-title {
  font-family: "Syne", sans-serif;
  font-size: clamp(4rem, 12vw, 9rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 0.9;
  color: var(--fg);
  position: relative;
  text-shadow:
    0 0 40px var(--cherry-glow),
    0 0 80px rgba(200, 16, 46, 0.2),
    0 0 120px rgba(200, 16, 46, 0.1);
  animation: flicker 4s ease-in-out infinite;
}

@keyframes flicker {
  0%, 100% { opacity: 1; }
  92% { opacity: 1; }
  93% { opacity: 0.8; }
  94% { opacity: 1; }
  96% { opacity: 0.9; }
  97% { opacity: 1; }
}

.hero-sub {
  font-size: 0.95rem;
  color: var(--fg-dim);
  margin: 2rem 0 2.5rem;
  min-height: 1.65em;
  line-height: 1.7;
}

.cursor {
  color: var(--cherry-bright);
  animation: blink 0.8s step-end infinite;
  font-weight: 700;
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 1.5rem;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
  transition: all 0.2s;
  letter-spacing: 0.02em;
}

.btn-primary {
  color: #fff;
  background: var(--cherry);
  border-color: var(--cherry);
  box-shadow: 0 0 20px var(--cherry-glow), inset 0 1px 0 rgba(255,255,255,0.1);
}

.btn-primary:hover {
  background: var(--cherry-bright);
  border-color: var(--cherry-bright);
  box-shadow: 0 0 40px var(--cherry-glow), 0 0 80px rgba(200, 16, 46, 0.2);
  transform: translateY(-1px);
}

.btn-ghost {
  color: var(--fg-dim);
  border-color: var(--border-hover);
  background: transparent;
}

.btn-ghost:hover {
  color: var(--fg);
  border-color: var(--cherry);
  background: var(--cherry-dim);
}

main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 2rem 6rem;
}

section {
  margin: 4rem 0;
  position: relative;
}

.section-title {
  font-family: "Syne", sans-serif;
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--fg);
  margin-bottom: 2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.section-num {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--cherry);
  letter-spacing: 0.08em;
  opacity: 0.7;
}

.demo-section {
  margin-top: -2rem;
}

.terminal-window {
  background: #0d070a;
  border: 1px solid var(--border-hover);
  overflow: hidden;
  box-shadow:
    0 4px 60px rgba(200, 16, 46, 0.08),
    0 0 1px rgba(200, 16, 46, 0.3),
    inset 0 0 80px rgba(200, 16, 46, 0.02);
}

.terminal-chrome {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0.7rem 1rem;
  background: #110810;
  border-bottom: 1px solid var(--border);
}

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

.dot-red { background: #c8102e; }
.dot-yellow { background: #e8a317; }
.dot-green { background: #2ea043; }

.terminal-title {
  flex: 1;
  text-align: center;
  font-size: 0.72rem;
  color: var(--fg-muted);
  letter-spacing: 0.04em;
}

.terminal-body {
  padding: 1.5rem 2rem;
  font-size: 0.82rem;
  line-height: 1.8;
  overflow-x: auto;
}

.terminal-body code {
  background: none;
  border: none;
  padding: 0;
  font-size: inherit;
  color: inherit;
}

.t-prompt { color: var(--cherry); font-weight: 700; }
.t-cmd { color: var(--fg); }
.t-out { color: var(--fg-dim); }

.install-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1rem;
}

.install-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 1.5rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.install-card:hover {
  border-color: var(--border-hover);
  box-shadow: 0 0 30px rgba(200, 16, 46, 0.05);
}

.install-os {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: "Syne", sans-serif;
  font-weight: 700;
  font-size: 1rem;
  color: var(--fg);
  margin-bottom: 0.75rem;
}

.install-os svg { color: var(--cherry); }

.install-desc {
  font-size: 0.82rem;
  color: var(--fg-dim);
  margin-bottom: 0.6rem;
}

.install-desc a {
  color: var(--cherry-bright);
  text-decoration: none;
  border-bottom: 1px solid var(--border-hover);
  transition: border-color 0.2s;
}

.install-desc a:hover { border-color: var(--cherry-bright); }

.install-desc code {
  font-size: 0.8em;
  background: var(--cherry-dim);
  color: var(--cherry-bright);
  padding: 0.15em 0.4em;
  border: 1px solid var(--border);
}

.code-block {
  background: #0d070a;
  border: 1px solid var(--border);
  padding: 0.75rem 1rem;
  overflow-x: auto;
  margin-top: 0.4rem;
}

.code-block code {
  background: none;
  border: none;
  padding: 0;
  font-size: 0.8rem;
  color: var(--cherry-bright);
  white-space: pre;
  text-shadow: 0 0 8px rgba(255, 26, 58, 0.3);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 1.5rem;
  transition: border-color 0.3s, box-shadow 0.3s, transform 0.3s;
}

.feature-card:hover {
  border-color: var(--border-hover);
  box-shadow: 0 0 40px rgba(200, 16, 46, 0.06);
  transform: translateY(-2px);
}

.feature-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.feature-icon {
  color: var(--cherry);
  flex-shrink: 0;
}

.feature-card h3 {
  font-family: "Syne", sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--fg);
  letter-spacing: -0.01em;
}

.feature-card p {
  font-size: 0.82rem;
  color: var(--fg-dim);
  line-height: 1.65;
}

.feature-card code {
  font-size: 0.78em;
  background: var(--cherry-dim);
  color: var(--cherry-bright);
  padding: 0.1em 0.35em;
  border: 1px solid var(--border);
}

.stack-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.stack-chip {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  padding: 0.45rem 1rem;
  border: 1px solid var(--border);
  color: var(--fg-dim);
  background: var(--bg-card);
  transition: all 0.2s;
}

.stack-chip:hover {
  color: var(--cherry-bright);
  border-color: var(--border-hover);
  background: var(--cherry-dim);
  box-shadow: 0 0 20px rgba(200, 16, 46, 0.08);
}

footer {
  text-align: center;
  padding: 3rem 2rem 4rem;
  border-top: 1px solid var(--border);
}

footer p {
  font-size: 0.78rem;
  color: var(--fg-muted);
}

footer a {
  color: var(--fg-dim);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  transition: color 0.2s, border-color 0.2s;
}

footer a:hover {
  color: var(--cherry-bright);
  border-color: var(--cherry);
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

.reveal:nth-child(2) { transition-delay: 0.08s; }
.reveal:nth-child(3) { transition-delay: 0.16s; }
.reveal:nth-child(4) { transition-delay: 0.24s; }
.reveal:nth-child(5) { transition-delay: 0.32s; }
.reveal:nth-child(6) { transition-delay: 0.40s; }
.reveal:nth-child(7) { transition-delay: 0.48s; }
.reveal:nth-child(8) { transition-delay: 0.56s; }
.reveal:nth-child(9) { transition-delay: 0.64s; }

@media (max-width: 768px) {
  nav { padding: 1rem 1.25rem; }
  .nav-links { gap: 1rem; }
  .nav-links a { font-size: 0.72rem; }
  .hero { padding: 5rem 1.25rem 3rem; min-height: auto; }
  .hero-title { font-size: clamp(3rem, 15vw, 5rem); }
  main { padding: 0 1.25rem 4rem; }
  section { margin: 2.5rem 0; }
  .install-grid { grid-template-columns: 1fr; }
  .features-grid { grid-template-columns: 1fr; }
  .terminal-body { padding: 1rem; font-size: 0.75rem; }
}

@media (max-width: 480px) {
  .nav-links a:not(.nav-gh) { display: none; }
  .hero-actions { flex-direction: column; align-items: center; }
  .btn { width: 100%; justify-content: center; }
}
