:root {
  --bg: #020202;
  --text: #fafafa;
  --muted: #52525b;
  --accent: #3b82f6;
  --accent-glow: rgba(59, 130, 246, 0.45);
  --glass: rgba(255, 255, 255, 0.04);
  --border: rgba(255, 255, 255, 0.07);
  --font-sans: "Inter", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  height: 100%;
  scroll-behavior: smooth;
}

body {
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

code, pre, kbd, .code-block pre {
  font-family: var(--font-mono);
}

#bg {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.vignette {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: radial-gradient(ellipse 80% 70% at 50% 45%, transparent 0%, var(--bg) 78%);
}

.grid-floor {
  position: fixed;
  left: -50%;
  right: -50%;
  bottom: -30%;
  height: 55vh;
  z-index: 1;
  pointer-events: none;
  opacity: 0.22;
  background:
    linear-gradient(transparent 0%, var(--bg) 85%),
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 79px,
      rgba(59, 130, 246, 0.08) 79px,
      rgba(59, 130, 246, 0.08) 80px
    ),
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 79px,
      rgba(59, 130, 246, 0.06) 79px,
      rgba(59, 130, 246, 0.06) 80px
    );
  transform: perspective(500px) rotateX(68deg);
  transform-origin: center bottom;
  mask-image: linear-gradient(to top, black 20%, transparent 100%);
}

/* ── Nav ── */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.35rem clamp(1.25rem, 4vw, 3rem);
  animation: fadeDown 1s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.brand-logo {
  border-radius: 8px;
  filter: drop-shadow(0 0 12px var(--accent-glow));
}

.nav-dl {
  display: flex;
  gap: 0.6rem;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.52rem 1.05rem;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 600;
  font-family: var(--font-sans);
  letter-spacing: 0;
  line-height: 1.35;
  text-decoration: none;
  color: rgba(255, 255, 255, 0.85);
  background: var(--glass);
  border: 1px solid var(--border);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: transform 0.2s, border-color 0.25s, box-shadow 0.25s, background 0.25s;
}

.pill-icon {
  width: 14px;
  height: 14px;
  opacity: 0.9;
}

.pill:hover {
  transform: translateY(-2px);
  border-color: rgba(59, 130, 246, 0.35);
  box-shadow: 0 8px 32px rgba(59, 130, 246, 0.12);
  background: rgba(59, 130, 246, 0.08);
}

.pill-dl {
  font-size: 0.9375rem;
  padding: 0.62rem 1.2rem;
  font-weight: 600;
  color: #fff;
}

.pill-dl .pill-text {
  letter-spacing: 0;
}

.pill-dl-group {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
}

.pill-soon-caption {
  display: none;
  font-size: 0.625rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1;
  color: #71717a;
  text-transform: lowercase;
}

.pill-soon .pill,
.pill.pill-soon {
  pointer-events: none;
  cursor: default;
  opacity: 0.62;
}

.pill-soon .pill:hover,
.pill.pill-soon:hover {
  transform: none;
  box-shadow: none;
  border-color: var(--border);
  background: var(--glass);
}

.pill-accent.pill-dl {
  background: linear-gradient(145deg, rgba(29,78,216,0.35), rgba(59,130,246,0.2));
  border-color: rgba(96, 165, 250, 0.45);
  box-shadow: 0 0 24px rgba(59, 130, 246, 0.15);
}

.pill-tutorial {
  font-size: 0.95rem !important;
  font-weight: 700 !important;
  padding: 0.65rem 1.35rem !important;
  color: #fff !important;
  background: linear-gradient(145deg, #7c3aed, #a855f7) !important;
  border-color: rgba(168, 85, 247, 0.5) !important;
  box-shadow: 0 0 28px rgba(168, 85, 247, 0.25);
}

.pill-tutorial:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 8px 32px rgba(168, 85, 247, 0.35) !important;
}

.hero-tutorial {
  display: inline-block;
  padding: 1rem 2.5rem;
  border-radius: 999px;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.35;
  text-decoration: none;
  color: #fff;
  background: linear-gradient(145deg, #6d28d9 0%, #a855f7 50%, #7c3aed 100%);
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.1) inset,
    0 12px 40px rgba(124, 58, 237, 0.4),
    0 0 60px rgba(168, 85, 247, 0.2);
  transition: transform 0.2s, box-shadow 0.3s;
}

.hero-actions {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  margin-top: 2rem;
  animation: fadeUp 1s cubic-bezier(0.16, 1, 0.3, 1) 0.75s both;
}

.hero-actions .hero-tutorial {
  margin-top: 0;
  animation: none;
}

.hero-actions .hero-tutorial:first-child {
  animation: fadeUp 1s cubic-bezier(0.16, 1, 0.3, 1) 0.75s both;
}

.hero-actions .hero-tutorial:last-child {
  animation: fadeUp 1s cubic-bezier(0.16, 1, 0.3, 1) 0.85s both;
}

.hero-tutorial:hover {
  transform: translateY(-4px) scale(1.04);
  box-shadow:
    0 16px 48px rgba(124, 58, 237, 0.5),
    0 0 80px rgba(168, 85, 247, 0.3);
}

.pill-try {
  font-size: 0.95rem !important;
  font-weight: 700 !important;
  padding: 0.65rem 1.35rem !important;
  color: #fff !important;
  background: linear-gradient(145deg, #059669, #10b981) !important;
  border-color: rgba(16, 185, 129, 0.5) !important;
  box-shadow: 0 0 28px rgba(16, 185, 129, 0.25);
}

.pill-try:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 8px 32px rgba(16, 185, 129, 0.35) !important;
}

.hero-try {
  display: inline-block;
  margin-top: 1rem;
  margin-left: 0.75rem;
  padding: 1rem 2.5rem;
  border-radius: 999px;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.35;
  text-decoration: none;
  color: #fff;
  background: linear-gradient(145deg, #047857 0%, #10b981 50%, #059669 100%);
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.1) inset,
    0 12px 40px rgba(5, 150, 105, 0.4),
    0 0 60px rgba(16, 185, 129, 0.2);
  transition: transform 0.2s, box-shadow 0.3s;
  animation: fadeUp 1s cubic-bezier(0.16, 1, 0.3, 1) 0.85s both;
}

.hero-try:hover {
  transform: translateY(-4px) scale(1.04);
  box-shadow:
    0 16px 48px rgba(5, 150, 105, 0.5),
    0 0 80px rgba(16, 185, 129, 0.3);
}

/* ── Hero ── */
.hero {
  position: relative;
  z-index: 2;
  min-height: 92vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 5rem 1.5rem 4rem;
}

.hero-orbit {
  position: absolute;
  width: min(420px, 90vw);
  height: min(420px, 90vw);
  pointer-events: none;
}

.ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid rgba(59, 130, 246, 0.12);
}

.ring-1 {
  animation: spin 28s linear infinite;
  border-style: dashed;
  opacity: 0.5;
}

.ring-2 {
  inset: 12%;
  animation: spin 20s linear infinite reverse;
  border-color: rgba(96, 165, 250, 0.15);
}

.ring-3 {
  inset: 24%;
  animation: spin 14s linear infinite;
  border-color: rgba(59, 130, 246, 0.08);
  box-shadow: 0 0 60px rgba(59, 130, 246, 0.06) inset;
}

.hero-logo {
  position: relative;
  z-index: 1;
  margin-bottom: 1.75rem;
  animation: float 6s ease-in-out infinite, fadeUp 1.1s cubic-bezier(0.16, 1, 0.3, 1) 0.15s both;
}

.hero-logo img {
  filter: drop-shadow(0 0 48px var(--accent-glow)) drop-shadow(0 0 120px rgba(59, 130, 246, 0.15));
  border-radius: 24px;
}

.hero-title {
  position: relative;
  z-index: 1;
  display: inline-block;
  font-size: clamp(3rem, 10vw, 5.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  padding-bottom: 0.08em;
  background: linear-gradient(165deg, #fff 30%, #94a3b8 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: fadeUp 1s cubic-bezier(0.16, 1, 0.3, 1) 0.25s both;
}

.hero-line {
  position: relative;
  z-index: 1;
  margin-top: 0.85rem;
  font-family: var(--font-sans);
  font-size: clamp(0.8125rem, 2vw, 0.9375rem);
  font-weight: 500;
  letter-spacing: 0.12em;
  line-height: 1.5;
  text-transform: uppercase;
  color: var(--muted);
  animation: fadeUp 1s cubic-bezier(0.16, 1, 0.3, 1) 0.38s both;
}

.hero-cta {
  position: relative;
  z-index: 1;
  margin-top: 2.75rem;
  animation: fadeUp 1s cubic-bezier(0.16, 1, 0.3, 1) 0.52s both;
}

.cta-main {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  padding: 1rem 2.75rem;
  border-radius: 999px;
  text-decoration: none;
  color: #fff;
  background: linear-gradient(145deg, #1d4ed8 0%, #3b82f6 50%, #2563eb 100%);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.1) inset,
    0 1px 0 rgba(255, 255, 255, 0.15) inset,
    0 12px 40px rgba(37, 99, 235, 0.35),
    0 0 80px rgba(59, 130, 246, 0.15);
  transition: transform 0.2s, box-shadow 0.3s;
}

.cta-main:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.12) inset,
    0 16px 48px rgba(37, 99, 235, 0.45),
    0 0 100px rgba(59, 130, 246, 0.22);
}

.cta-label {
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.35;
}

.cta-sub {
  font-family: var(--font-sans);
  font-size: 0.8125rem;
  font-weight: 500;
  opacity: 0.8;
  letter-spacing: 0;
  line-height: 1.4;
}

.hero-chips {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 0.65rem;
  margin-top: 2.25rem;
  list-style: none;
  animation: fadeUp 1s cubic-bezier(0.16, 1, 0.3, 1) 0.65s both;
}

.hero-chips li {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1.35;
  text-transform: uppercase;
  color: #71717a;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
}

.foot {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 2;
  padding: 1.25rem;
  text-align: center;
  font-family: var(--font-sans);
  font-size: 0.8125rem;
  font-weight: 500;
  color: #3f3f46;
  letter-spacing: 0;
  line-height: 1.5;
}

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

@keyframes fadeDown {
  from { opacity: 0; transform: translateY(-16px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@media (max-width: 520px) {
  .nav-dl .pill span:not(.pill-icon),
  .nav-dl .pill {
    font-size: 0;
    padding: 0.55rem 0.65rem;
  }
  .pill-soon-caption {
    font-size: 0.5625rem;
  }
  .pill-icon { width: 16px; height: 16px; }
  .hero-chips { flex-wrap: wrap; justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  #bg, #helix { display: none; }
}

/* ── Features ── */
.features {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  max-width: 960px;
  margin: -2rem auto 0;
  padding: 0 1.5rem 4rem;
}

.feat-card {
  padding: 1.75rem 1.5rem;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(12px);
  text-align: center;
  transition: border-color 0.25s, transform 0.25s;
}

.feat-card:hover {
  border-color: rgba(59, 130, 246, 0.3);
  transform: translateY(-4px);
}

.feat-glyph {
  width: 72px;
  height: 72px;
  margin: 0 auto 1rem;
  opacity: 0.85;
}

.feat-glyph svg {
  width: 100%;
  height: 100%;
}

.feat-card h2 {
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.35;
  margin-bottom: 0.5rem;
}

.feat-card p {
  font-family: var(--font-sans);
  font-size: 0.875rem;
  line-height: 1.65;
  color: #71717a;
}

.helix-canvas {
  position: absolute;
  inset: 10%;
  width: 80%;
  height: 80%;
  opacity: 0.5;
}

/* ── Download / Linux ── */
.download, .linux {
  position: relative;
  z-index: 2;
  max-width: 720px;
  margin: 0 auto;
  padding: 3rem 1.5rem 4rem;
  text-align: center;
}

.section-title {
  display: inline-block;
  font-size: clamp(1.75rem, 5vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
  padding-bottom: 0.08em;
  background: linear-gradient(165deg, #fff 20%, #64748b 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.section-sub {
  margin-top: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0.04em;
  line-height: 1.5;
  text-transform: uppercase;
}

.dl-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 2rem;
}

.dl-card {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 1.5rem 1.25rem;
  border-radius: 16px;
  text-decoration: none;
  border: 1px solid rgba(59, 130, 246, 0.25);
  background: linear-gradient(160deg, rgba(29,78,216,0.2), rgba(2,2,2,0.6));
  transition: transform 0.2s, box-shadow 0.3s;
}

.dl-card:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 16px 48px rgba(37, 99, 235, 0.25);
}

.dl-os {
  font-size: 0.8125rem;
  font-family: var(--font-sans);
  font-weight: 600;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  line-height: 1.35;
}

.dl-action {
  font-size: 1.35rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0;
  line-height: 1.35;
}

.dl-hint {
  font-size: 0.8125rem;
  font-family: var(--font-sans);
  font-weight: 500;
  color: #52525b;
  line-height: 1.45;
}

.code-block {
  margin-top: 1.25rem;
  text-align: left;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.5);
  overflow: hidden;
}

.code-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 1rem;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: #71717a;
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
}

.copy-btn {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  padding: 0.25rem 0.65rem;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: transparent;
  color: #a1a1aa;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}

.copy-btn:hover {
  color: #fff;
  border-color: rgba(59, 130, 246, 0.4);
}

.code-block pre {
  margin: 0;
  padding: 1rem 1.15rem;
  overflow-x: auto;
}

.code-block code {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.65;
  color: #e4e4e7;
}

@media (max-width: 720px) {
  .features { grid-template-columns: 1fr; }
  .dl-grid { grid-template-columns: 1fr; }
}
