:root {
  --bg: #0a0a0c;
  --bg-raised: #111115;
  --bg-inset: #070709;
  --ink: #edede8;
  --ink-2: #c6c6bf;
  --ink-3: #8f8f89;
  --ink-4: #5f5f5a;
  --accent: #ff5c1f;
  --accent-dim: #d94a16;
  --accent-ink: #0a0a0c;
  --clean: #3ddc84;
  --line: rgba(237, 237, 232, 0.12);
  --line-soft: rgba(237, 237, 232, 0.065);
  --warn: #ff9f43;
  --danger: #ff5c1f;
  --radius: 5px;
  --sans: "Space Grotesk", system-ui, sans-serif;
  --body: "Inter", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
}

html {
  background: var(--bg);
  scroll-padding-top: 68px;
}

body {
  overflow-x: hidden;
  background:
    linear-gradient(rgba(237, 237, 232, 0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(237, 237, 232, 0.018) 1px, transparent 1px),
    var(--bg);
  background-size: 48px 48px;
  color: var(--ink);
  font-family: var(--body);
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  background: radial-gradient(circle at 80% 20%, rgba(255, 92, 31, 0.055), transparent 34%);
  content: "";
  pointer-events: none;
}

.container {
  width: min(100% - 48px, 1200px);
  max-width: 1200px;
  padding: 0;
}

h1,
h2,
h3 {
  font-family: var(--sans);
  font-weight: 500;
}

code {
  font-family: var(--mono);
}

.skip-link {
  z-index: 500;
  border-radius: 3px;
  background: var(--accent);
  color: var(--accent-ink);
  font-family: var(--mono);
}

:focus-visible {
  outline-color: var(--accent);
}

/* Navigation */
.nav {
  height: 68px;
  border-bottom: 1px solid var(--line-soft);
  background: rgba(10, 10, 12, 0.9);
  backdrop-filter: blur(18px);
}

.nav-inner {
  height: 68px;
}

.logo {
  font-family: var(--mono);
  font-size: 15px;
  letter-spacing: -0.02em;
  text-transform: lowercase;
}

.logo .slash {
  color: var(--accent);
}

.nav-links {
  gap: 24px;
}

.nav-links a {
  color: rgba(237, 237, 232, 0.56);
  font-family: var(--mono);
  font-size: 12px;
  text-transform: lowercase;
}

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

.nav-links .nav-github:hover {
  color: var(--clean);
}

.nav-buy {
  min-height: 44px;
  padding: 9px 16px;
  border: 1px solid var(--accent);
  border-radius: 3px;
  background: var(--accent);
  color: var(--accent-ink) !important;
}

/* Buttons */
.btn {
  min-height: 46px;
  border-radius: 4px;
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 500;
}

.btn-primary {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--accent-ink);
}

.btn-primary:hover {
  filter: brightness(1.1);
  box-shadow: 0 0 32px rgba(255, 92, 31, 0.18);
}

.btn-quiet {
  border-color: rgba(237, 237, 232, 0.24);
  color: var(--ink-2);
}

.btn-quiet:hover {
  border-color: rgba(237, 237, 232, 0.55);
  background: rgba(237, 237, 232, 0.035);
}

/* Kimi K3 cinematic hero, promoted to production */
.hero.hero-cinematic {
  position: relative;
  z-index: 3;
  display: flex;
  min-height: max(calc(100svh - 68px), 720px);
  padding: 24px 7vw 0;
  overflow: hidden;
  isolation: isolate;
}

.hero-cinematic #bg-log,
.hero-cinematic #bg-gl,
.hero-cinematic .scanlines {
  position: absolute;
  inset: 0;
}

.hero-cinematic #bg-log,
.hero-cinematic #bg-gl {
  width: 100%;
  height: 100%;
}

.hero-cinematic .hero-grid,
.hero-cinematic .trust-strip {
  position: relative;
  z-index: 3;
}

.hero-cinematic .hero-grid {
  width: 100%;
  max-width: 1600px;
  margin: 0 auto;
}

.hero-cinematic .hero-content {
  min-width: 0;
}

.hero-cinematic .headline {
  max-width: 880px;
}

.hero-cinematic .prompt-label {
  min-height: 44px;
}

.hero-cinematic .subtitle {
  margin-bottom: 0;
}

.hero-cinematic .ctas {
  align-items: center;
}

.hero-cinematic .cta-primary,
.hero-cinematic .cta-secondary {
  min-height: 46px;
}

.hero-cinematic .cta-primary {
  color: var(--accent-ink);
}

.hero-cinematic .cta-github {
  text-decoration-color: rgba(61, 220, 132, 0.45);
}

.hero-cinematic .cta-github:hover {
  color: var(--clean);
}

.hero-cinematic .es-badge {
  border-color: rgba(61, 220, 132, 0.25);
  color: rgba(61, 220, 132, 0.72);
}

.hero-cinematic .trust-strip {
  width: 100%;
  max-width: 1600px;
  margin: 0 auto;
  border-top: 1px solid var(--line-soft);
  letter-spacing: 0.01em;
}

/* Install conversion strip */
.install {
  position: relative;
  z-index: 4;
  padding: 70px 0 92px;
  border-top: 1px solid var(--line-soft);
  background: rgba(7, 7, 9, 0.78);
}

.install::before {
  display: block;
  margin-bottom: 20px;
  color: var(--accent);
  content: "00 / start free";
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-align: center;
  text-transform: uppercase;
}

.install-box {
  max-width: 760px;
  border-color: rgba(255, 92, 31, 0.28);
  border-radius: 4px;
  background: #0d0d10;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
}

.install-cmd {
  color: var(--ink-2);
}

.install-cmd .p {
  color: var(--accent);
}

.copy-btn {
  min-height: 44px;
  border-radius: 3px;
  font-family: var(--mono);
}

.copy-btn:hover {
  border-color: rgba(255, 92, 31, 0.45);
  background: rgba(255, 92, 31, 0.06);
}

.copy-btn.copied {
  border-color: rgba(61, 220, 132, 0.4);
  color: var(--clean);
}

.install-note {
  color: var(--ink-4);
  font-family: var(--mono);
  font-size: 11px;
}

/* Shared sections */
.section {
  position: relative;
  padding: 112px 0;
  border-top: 1px solid var(--line-soft);
  background: rgba(10, 10, 12, 0.78);
}

.section:nth-of-type(even) {
  background: rgba(7, 7, 9, 0.88);
}

.section::after {
  position: absolute;
  top: 0;
  right: 7vw;
  width: 60px;
  height: 1px;
  background: var(--accent);
  content: "";
  opacity: 0.5;
}

.section-head {
  max-width: 720px;
  margin-bottom: 52px;
}

.section-head::before {
  display: block;
  margin-bottom: 18px;
  color: var(--accent);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

#guards .section-head::before { content: "01 / guard layer"; }
#skills .section-head::before { content: "02 / command menu"; }
#aprendiz .aprendiz-copy::before {
  display: block;
  margin-bottom: 18px;
  color: var(--clean);
  content: "03 / modo aprendiz · Spanish explanations";
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}
#senior .section-head::before { content: "04 / senior mode"; }
#testimonials .section-head::before { content: "05 / field reports"; }
#pricing .section-head::before { content: "06 / choose your layer"; }
#faq .section-head::before { content: "07 / questions"; }

.section-head h2,
.aprendiz-copy h2 {
  margin-bottom: 16px;
  color: var(--ink);
  font-size: clamp(34px, 5vw, 64px);
  line-height: 0.98;
  letter-spacing: -0.045em;
}

.section-head p,
.aprendiz-copy p {
  max-width: 62ch;
  color: var(--ink-3);
  font-size: 16px;
  line-height: 1.7;
}

/* Guards */
.guards-grid {
  gap: 16px;
}

.guard-card {
  position: relative;
  min-height: 166px;
  padding: 28px;
  overflow: hidden;
  border-color: var(--line);
  border-radius: 4px;
  background: #0e0e11;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.guard-card::before {
  position: absolute;
  top: 10px;
  right: 18px;
  color: rgba(237, 237, 232, 0.045);
  content: "/";
  font-family: var(--mono);
  font-size: 64px;
  line-height: 1;
}

.guard-card:hover {
  border-color: rgba(255, 92, 31, 0.46);
  background: #121216;
  transform: translateY(-3px);
}

.guard-card.tinted {
  border-color: rgba(255, 92, 31, 0.38);
  background: linear-gradient(145deg, rgba(255, 92, 31, 0.11), #0e0e11 56%);
}

.guard-name {
  position: relative;
  color: var(--accent);
  font-size: 13px;
  letter-spacing: -0.02em;
}

.guard-name::before {
  margin-right: 8px;
  color: rgba(255, 92, 31, 0.5);
  content: ">";
}

.guard-card p {
  position: relative;
  max-width: 58ch;
  color: var(--ink-3);
  font-size: 14px;
  line-height: 1.65;
}

.guard-pattern {
  border: 1px solid rgba(255, 92, 31, 0.18);
  border-radius: 2px;
  background: rgba(255, 92, 31, 0.07);
  color: #ff8a5d;
}

/* Skills */
.skills-cols {
  gap: 18px;
}

.skills-panel {
  position: relative;
  padding: 30px;
  overflow: hidden;
  border-radius: 4px;
  background: #0d0d10;
}

.skills-panel::after {
  position: absolute;
  right: -18px;
  bottom: -58px;
  color: rgba(237, 237, 232, 0.025);
  content: "/";
  font-family: var(--mono);
  font-size: 220px;
  line-height: 1;
  pointer-events: none;
}

.skills-panel.pro {
  border-color: rgba(255, 92, 31, 0.42);
  background: linear-gradient(165deg, rgba(255, 92, 31, 0.085), #0d0d10 42%);
}

.skills-panel-head {
  position: relative;
  z-index: 1;
  padding-bottom: 18px;
  border-bottom-color: var(--line);
}

.skills-panel-head h3 {
  font-family: var(--mono);
  font-size: 14px;
  text-transform: lowercase;
}

.skills-panel-head span {
  color: var(--clean);
  font-family: var(--mono);
  font-size: 11px;
}

.skills-panel.pro .skills-panel-head span,
.skills-panel.pro .skill-row .cmd {
  color: var(--accent);
}

.skill-row {
  position: relative;
  z-index: 1;
  grid-template-columns: 118px 1fr;
  padding: 11px 0;
}

.skill-row + .skill-row {
  border-top-color: var(--line-soft);
}

.skill-row .cmd {
  color: var(--clean);
  font-size: 12px;
}

.skill-row .desc {
  color: var(--ink-3);
  font-size: 13px;
}

/* Aprendiz */
.aprendiz-grid {
  gap: 72px;
}

.risk-context {
  padding: 10px 16px;
  border-bottom: 1px solid rgba(237, 237, 232, 0.08);
  color: var(--ink-4);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.aprendiz-copy p strong {
  color: var(--ink-2);
}

.risk-card {
  position: relative;
  padding: 30px;
  overflow: hidden;
  border-color: rgba(61, 220, 132, 0.28);
  border-radius: 4px;
  background: #0b0b0e;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.3);
}

.risk-card::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 2px;
  background: var(--clean);
  content: "";
}

.risk-head {
  color: var(--warn);
  font-size: 11px;
}

.risk-head .sev {
  border-radius: 2px;
}

.risk-item .q {
  color: var(--clean);
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
}

.risk-item .a {
  color: var(--ink-2);
}

/* Senior mode */
#senior .skills-panel {
  min-height: 240px;
}

#senior .skills-panel p {
  position: relative;
  z-index: 1;
  color: var(--ink-3);
  font-size: 14px;
  line-height: 1.7;
}

#senior code {
  color: var(--ink-2);
  font-size: 0.9em;
}

/* Testimonials */
.quotes {
  gap: 18px;
}

.quote-card {
  position: relative;
  min-height: 260px;
  justify-content: space-between;
  padding: 36px;
  border-radius: 4px;
  background: #0e0e11;
}

.quote-card::before {
  color: var(--accent);
  content: "“";
  font-family: var(--sans);
  font-size: 64px;
  line-height: 0.6;
  opacity: 0.6;
}

.quote-card blockquote {
  color: var(--ink-2);
  font-size: 19px;
  line-height: 1.55;
}

.quote-avatar {
  border-radius: 3px;
  color: var(--accent);
  font-size: 11px;
}

.quote-who .role {
  color: var(--ink-4);
}

/* Pricing */
#pricing .section-head,
#faq .section-head {
  max-width: 860px !important;
  text-align: left !important;
}

.pricing-grid {
  max-width: 960px;
  gap: 18px;
}

.price-card {
  position: relative;
  padding: 38px 34px;
  border-radius: 4px;
  background: #0d0d10;
}

.price-card:first-child {
  border-color: rgba(61, 220, 132, 0.24);
}

.price-card.pro {
  border-color: rgba(255, 92, 31, 0.62);
  background: linear-gradient(160deg, rgba(255, 92, 31, 0.13), #0d0d10 44%);
  box-shadow: 0 32px 110px rgba(255, 92, 31, 0.09);
}

.price-card.pro::before {
  position: absolute;
  top: -13px;
  right: 20px;
  padding: 5px 9px;
  border: 1px solid var(--accent);
  border-radius: 2px;
  background: var(--bg);
  color: var(--accent);
  content: "FOUNDER / FIRST 20";
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 0.11em;
}

.price-card h3 {
  font-family: var(--mono);
  text-transform: lowercase;
}

.price-line .amount {
  font-family: var(--sans);
  font-size: 56px;
  font-weight: 500;
}

.price-line .per,
.price-line .was,
.price-note {
  font-family: var(--mono);
}

.price-note {
  color: var(--accent);
  font-size: 11px;
}

.price-note.plain {
  color: var(--clean);
}

.price-card li {
  color: var(--ink-2);
}

.price-card li svg {
  color: var(--clean);
}

.price-card.pro li svg {
  color: var(--accent);
}

/* FAQ */
.faq {
  max-width: 860px;
  border-top: 1px solid var(--line);
}

.faq details {
  border-bottom-color: var(--line);
}

.faq summary {
  min-height: 62px;
  padding: 20px 0;
  font-family: var(--mono);
  font-size: 13px;
}

.faq summary::after {
  color: var(--accent);
}

.faq .answer {
  padding-right: 32px;
  padding-left: 0;
  color: var(--ink-3);
  line-height: 1.75;
}

.faq .answer code {
  color: var(--clean);
}

/* Final CTA */
.final {
  position: relative;
  padding: 132px 0;
  overflow: hidden;
  background:
    repeating-linear-gradient(135deg, transparent 0 18px, rgba(255, 92, 31, 0.035) 18px 19px),
    #08080a;
}

.final::before,
.final::after {
  position: absolute;
  top: 50%;
  width: 18vw;
  height: 1px;
  background: var(--accent);
  content: "";
  opacity: 0.35;
}

.final::before { left: 0; }
.final::after { right: 0; }

.final h2 {
  margin-bottom: 18px;
  font-size: clamp(38px, 6vw, 72px);
  font-weight: 500;
  letter-spacing: -0.05em;
}

.final h2 span {
  color: var(--accent);
}

.final p {
  color: var(--ink-3);
}

/* Footer */
footer {
  padding: 36px 0;
  border-top-color: var(--line);
  background: #070709;
}

footer p,
footer a {
  color: var(--ink-4);
  font-family: var(--mono);
  font-size: 11px;
}

footer a:hover {
  color: var(--clean);
}

/* Visible-by-default motion enhancement: never gate content behind opacity 0. */
.reveal,
.js .reveal,
.js .reveal.in {
  opacity: 1;
  transform: none;
}

/* Responsive */
@media (max-width: 1100px) {
  .hero-cinematic .hero-content { grid-column: 1 / 8; }
  .hero-cinematic .hero-demo { grid-column: 8 / 13; }
  .hero-cinematic .headline { font-size: clamp(3rem, 6.1vw, 6rem); }
}

@media (max-width: 900px) {
  .hero.hero-cinematic {
    min-height: auto;
    padding: 72px 7vw 0;
  }

  .hero-cinematic .hero-grid {
    gap: 56px;
  }

  .hero-cinematic .hero-content,
  .hero-cinematic .hero-demo {
    grid-column: 1;
  }

  .hero-cinematic .trust-strip {
    margin-top: 56px;
  }

  .section {
    padding: 88px 0;
  }

  .guards-grid {
    grid-template-columns: 1fr 1fr;
  }

  .guard-card,
  .guard-card.wide {
    grid-column: span 1;
  }

  .aprendiz-grid {
    gap: 44px;
  }

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

@media (max-width: 760px) {
  .container {
    width: min(100% - 32px, 1200px);
  }

  .nav-links {
    gap: 12px;
  }

  .nav-section,
  .nav-github {
    display: none;
  }

  .nav-buy {
    min-height: 44px;
  }

  .hero.hero-cinematic {
    padding-right: 24px;
    padding-left: 24px;
  }

  .hero-cinematic .headline {
    font-size: clamp(2.7rem, 12vw, 4.2rem);
  }

  .hero-cinematic .subtitle {
    font-size: 1rem;
  }

  .hero-cinematic .ctas {
    gap: 14px;
  }

  .hero-cinematic .cta-primary-wrap,
  .hero-cinematic .cta-secondary-wrap {
    width: 100%;
  }

  .hero-cinematic .cta-primary,
  .hero-cinematic .cta-secondary {
    width: 100%;
    text-align: center;
  }

  .hero-cinematic .cta-github {
    width: 100%;
    align-self: flex-start;
  }

  .hero-cinematic .terminal-body {
    min-height: 230px;
    font-size: 0.72rem;
  }

  .install {
    padding: 56px 0 72px;
  }

  .install-box {
    gap: 14px;
  }

  .install-cmd {
    width: 100%;
    padding-bottom: 4px;
  }

  .section {
    padding: 72px 0;
  }

  .section-head h2,
  .aprendiz-copy h2 {
    font-size: clamp(34px, 11vw, 48px);
  }

  .skills-cols,
  .quotes,
  .guards-grid {
    grid-template-columns: 1fr;
  }

  .guard-card,
  .guard-card.wide {
    min-height: 0;
    grid-column: 1;
  }

  .skills-panel,
  .quote-card,
  .price-card,
  .risk-card {
    padding: 26px 22px;
  }

  .skills-panel-head {
    gap: 16px;
  }

  .skill-row {
    grid-template-columns: 94px 1fr;
    gap: 10px;
  }

  .quote-card {
    min-height: 0;
  }

  .price-card.pro::before {
    right: 12px;
  }

  .final {
    padding: 96px 0;
  }

  .final::before,
  .final::after {
    display: none;
  }

  .final .cta-row .btn {
    width: 100%;
    flex: none;
  }
}

@media (max-width: 420px) {
  .hero.hero-cinematic {
    padding-right: 18px;
    padding-left: 18px;
  }

  .hero-cinematic .headline {
    font-size: clamp(2.45rem, 11.8vw, 3.3rem);
  }

  .hero-cinematic .prompt-label {
    max-width: 100%;
    overflow: hidden;
    font-size: 0.67rem;
    white-space: nowrap;
  }

  .hero-cinematic .copy-toast {
    display: none;
  }

  .hero-cinematic .terminal-body {
    padding-right: 0.8rem;
    padding-left: 0.8rem;
    font-size: 0.66rem;
  }

  .skills-panel-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .skill-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .guard-card:hover {
    transform: none;
  }
}
