:root {
  color-scheme: dark;
  --bg: #0b0715;
  --surface: #120b22;
  --surface-2: #1a1031;
  --line: #302047;
  --line-strong: #583593;
  --text: #f5f3ff;
  --muted: #aaa0be;
  --violet: #7c3aed;
  --violet-light: #a78bfa;
  --mint: #34d399;
  --max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background:
    radial-gradient(circle at 78% 8%, rgba(124, 58, 237, .14), transparent 32rem),
    radial-gradient(circle at 8% 55%, rgba(52, 211, 153, .05), transparent 28rem),
    var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img, video { display: block; max-width: 100%; }
code, pre { font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace; }

.skip-link {
  position: fixed;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  padding: .7rem 1rem;
  border-radius: .5rem;
  background: var(--mint);
  color: #07120f;
  font-weight: 700;
}
.skip-link:focus { top: 1rem; }

.nav {
  width: min(calc(100% - 40px), var(--max));
  height: 88px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.brand img { width: 112px; height: 56px; object-fit: contain; }
.nav nav { display: flex; align-items: center; gap: 2rem; }
.nav nav a { color: var(--muted); font-size: .88rem; font-weight: 650; }
.nav nav a:hover, .nav nav a:focus-visible { color: var(--text); }
.nav .nav-github { padding: .55rem .9rem; border: 1px solid var(--line-strong); border-radius: .55rem; color: var(--text); }

.hero {
  width: min(calc(100% - 40px), var(--max));
  min-height: 700px;
  margin: 0 auto;
  padding: 7.5rem 0 6rem;
  display: grid;
  grid-template-columns: .88fr 1.12fr;
  align-items: center;
  gap: 4.5rem;
}
.eyebrow {
  margin: 0 0 1.2rem;
  color: var(--violet-light);
  font-size: .75rem;
  font-weight: 760;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.eyebrow span { display: inline-block; width: 28px; height: 1px; margin: 0 .65rem .25rem 0; background: var(--mint); }
.hero h1, .section-heading h2, .start h2, .closing h2 {
  margin: 0;
  letter-spacing: -.045em;
  line-height: .98;
}
.hero h1 { max-width: 700px; font-size: clamp(3.4rem, 6.4vw, 6.4rem); }
.hero h1 em { color: var(--violet-light); font-style: normal; }
.hero-lede { max-width: 600px; margin: 1.8rem 0 0; color: var(--muted); font-size: 1.08rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2rem; }
.button {
  min-height: 48px;
  padding: .7rem 1.2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .6rem;
  border: 1px solid transparent;
  border-radius: .65rem;
  font-size: .9rem;
  font-weight: 760;
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}
.button:hover { transform: translateY(-2px); }
.button-primary { background: var(--violet); color: white; box-shadow: 0 14px 38px rgba(124, 58, 237, .24); }
.button-primary:hover { background: #8b5cf6; }
.button-secondary { border-color: var(--line-strong); background: rgba(20, 12, 37, .65); }
.button-secondary:hover { border-color: var(--violet-light); }
.install-line {
  width: fit-content;
  max-width: 100%;
  margin-top: 1.4rem;
  padding: .65rem .85rem;
  display: flex;
  gap: .65rem;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: .55rem;
  color: #c7bdd9;
  background: rgba(8, 5, 15, .72);
  font-size: .74rem;
  white-space: nowrap;
}
.prompt { color: var(--mint); }

.hero-demo {
  position: relative;
  overflow: hidden;
  border: 1px solid #382452;
  border-radius: 1rem;
  background: #09060f;
  box-shadow: 0 35px 100px rgba(0, 0, 0, .46), 0 0 0 1px rgba(167, 139, 250, .05) inset;
  transform: perspective(1200px) rotateY(-2deg) rotateX(1deg);
}
.hero-demo::after { content: ""; position: absolute; inset: 0; pointer-events: none; box-shadow: inset 0 0 70px rgba(124, 58, 237, .09); }
.window-bar {
  height: 44px;
  padding: 0 .9rem;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  border-bottom: 1px solid #30223f;
  color: #8f859e;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: .68rem;
}
.window-dots { display: flex; gap: .35rem; }
.window-dots i { width: 8px; height: 8px; border-radius: 50%; background: #4b3b57; }
.live { justify-self: end; display: flex; align-items: center; gap: .4rem; color: #9bdcc5; }
.live i { width: 6px; height: 6px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 10px var(--mint); }
.hero-demo video { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }

.facts {
  width: min(calc(100% - 40px), var(--max));
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-block: 1px solid var(--line);
}
.facts div { min-height: 122px; padding: 1.8rem 1.5rem; display: flex; align-items: baseline; gap: .8rem; border-right: 1px solid var(--line); }
.facts div:last-child { border-right: 0; }
.facts strong { color: var(--mint); font-family: "SFMono-Regular", Consolas, monospace; font-size: 1.8rem; font-weight: 500; }
.facts span { color: var(--muted); font-size: .77rem; text-transform: uppercase; letter-spacing: .08em; }

.section { width: min(calc(100% - 40px), var(--max)); margin: 0 auto; padding: 8rem 0; }
.section-heading { max-width: 780px; margin-bottom: 3rem; }
.section-heading.compact { max-width: 650px; }
.section-heading h2, .start h2, .closing h2 { font-size: clamp(2.6rem, 5vw, 5rem); }
.section-heading > p:last-child, .start > div > p { max-width: 650px; margin: 1.4rem 0 0; color: var(--muted); font-size: 1.04rem; }
.architecture-frame { padding: 1rem; overflow: hidden; border: 1px solid var(--line); border-radius: 1rem; background: #0d0818; box-shadow: 0 32px 100px rgba(0, 0, 0, .28); }
.architecture-frame img { width: 100%; }

.details { padding-top: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.details article {
  min-height: 300px;
  padding: 2rem;
  border: 1px solid var(--line);
  border-radius: .9rem;
  background: linear-gradient(145deg, rgba(28, 17, 51, .86), rgba(14, 9, 26, .9));
}
.card-index { color: var(--mint); font-family: "SFMono-Regular", Consolas, monospace; font-size: .7rem; letter-spacing: .1em; }
.details h3 { margin: 2.8rem 0 1rem; font-size: 1.35rem; line-height: 1.25; }
.details article > p:last-child { color: var(--muted); font-size: .92rem; }
.details code { color: var(--violet-light); }

.components { display: grid; grid-template-columns: .8fr 1.2fr; gap: 5rem; align-items: start; }
.component-list { border-top: 1px solid var(--line); }
.component-list article { padding: 1.55rem 0; display: grid; grid-template-columns: 42px 1fr auto; align-items: center; gap: 1rem; border-bottom: 1px solid var(--line); }
.component-list article > span { color: #695e7c; font-family: "SFMono-Regular", Consolas, monospace; font-size: .7rem; }
.component-list h3 { margin: 0; font-size: 1rem; }
.component-list p { margin: .25rem 0 0; color: var(--muted); font-size: .8rem; }
.component-list code { padding: .3rem .55rem; border: 1px solid #4d3074; border-radius: .4rem; color: #c4b5fd; font-size: .7rem; }

.interfaces { border-top: 1px solid var(--line); }
.interface-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.interface-grid figure { margin: 0; overflow: hidden; border: 1px solid var(--line); border-radius: .85rem; background: var(--surface); }
.interface-grid img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; object-position: top; }
.interface-grid figcaption { padding: 1rem 1.2rem 1.2rem; display: flex; justify-content: space-between; gap: 1rem; }
.interface-grid figcaption strong { font-size: .88rem; }
.interface-grid figcaption span { color: var(--muted); font-size: .74rem; text-align: right; }

.start { display: grid; grid-template-columns: .85fr 1.15fr; gap: 5rem; align-items: center; border-top: 1px solid var(--line); }
.text-link { display: inline-block; margin-top: 1.5rem; color: var(--mint); font-size: .9rem; font-weight: 700; }
.start pre { margin: 0; padding: 2rem; overflow: auto; border: 1px solid var(--line); border-radius: .9rem; background: #08050e; color: #d5ccdf; font-size: .82rem; line-height: 1.85; box-shadow: inset 3px 0 0 var(--violet); }
.comment { color: #6f647d; }
.accent { color: var(--mint); }
.string { color: #c4b5fd; }

.closing { padding: 9rem 20px; text-align: center; border-top: 1px solid var(--line); background: radial-gradient(circle at 50% 50%, rgba(124, 58, 237, .18), transparent 29rem); }
.closing img { width: 180px; height: 90px; margin: 0 auto 2rem; }
.closing h2 { margin-bottom: 2.5rem; }

footer {
  width: min(calc(100% - 40px), var(--max));
  min-height: 100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--line);
  color: #746a82;
  font-size: .75rem;
}
footer div { display: flex; gap: 1.5rem; }
footer a:hover { color: var(--text); }

:focus-visible { outline: 2px solid var(--mint); outline-offset: 4px; }

@media (max-width: 920px) {
  .nav nav a:not(.nav-github) { display: none; }
  .hero { min-height: auto; padding-top: 5rem; grid-template-columns: 1fr; gap: 3rem; }
  .hero-demo { transform: none; }
  .facts { grid-template-columns: 1fr 1fr; }
  .facts div:nth-child(2) { border-right: 0; }
  .facts div:nth-child(-n + 2) { border-bottom: 1px solid var(--line); }
  .details { grid-template-columns: 1fr; }
  .details article { min-height: 220px; }
  .details h3 { margin-top: 2rem; }
  .components, .start { grid-template-columns: 1fr; gap: 3rem; }
}

@media (max-width: 640px) {
  .nav { width: min(calc(100% - 28px), var(--max)); height: 74px; }
  .brand img { width: 94px; height: 47px; }
  .nav nav { gap: .7rem; }
  .hero, .section, .facts, footer { width: min(calc(100% - 28px), var(--max)); }
  .hero { padding: 4rem 0; }
  .hero h1 { font-size: clamp(3rem, 15vw, 4.4rem); }
  .hero-lede { font-size: 1rem; }
  .hero-actions { flex-direction: column; }
  .button { width: 100%; }
  .window-bar { grid-template-columns: 1fr 1fr; }
  .window-bar > span:nth-child(2) { display: none; }
  .facts div { min-height: 98px; padding: 1.2rem .9rem; flex-direction: column; gap: .1rem; }
  .facts strong { font-size: 1.35rem; }
  .facts span { font-size: .62rem; }
  .section { padding: 5.5rem 0; }
  .architecture-frame { padding: .35rem; border-radius: .65rem; }
  .details { padding-top: 0; }
  .component-list article { grid-template-columns: 28px 1fr; }
  .component-list article > code { display: none; }
  .interface-grid { grid-template-columns: 1fr; }
  .interface-grid figcaption { flex-direction: column; }
  .interface-grid figcaption span { text-align: left; }
  .start pre { padding: 1.2rem; font-size: .68rem; }
  .closing { padding: 6rem 20px; }
  footer { padding: 2rem 0; align-items: flex-start; flex-direction: column; gap: 1rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
