/* ============================================================
   ClipToZero landing page · Option A — Stages.
   Generated from the Claude Design handoff bundle (the "Stages"
   direction): page IS the workflow, three numbered chapters
   alternating sides, dark/lime palette continuous with the
   plugin's Theme.h.
   ============================================================ */

:root {
  --bg: #0c0d0c;
  --bg-card: #15171a;
  --bg-hi: #1d1f1c;
  --line: #1d1f1c;
  --line-hi: #2a2d2a;
  --ink: #e6f0c2;
  --ink-2: #9ea692;
  --ink-3: #7d8674;
  --ink-4: #5d6457;
  --accent: #a8d860;
  --accent-2: #c3e87d;
  --warn: #ffaa50;
  --danger: #ff7068;

  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --sans:
    "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui,
    sans-serif;
}

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

html,
body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

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

.mono {
  font-family: var(--mono);
}
.eyebrow {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-3);
}

::selection {
  background: var(--accent);
  color: var(--bg);
}

/* ─── Layout ─── */
.wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 32px;
}
@media (max-width: 600px) {
  .wrap {
    padding: 0 20px;
  }
}

/* ─── Top bar ─── */
.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(12, 13, 12, 0.86);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 32px;
  max-width: 1080px;
  margin: 0 auto;
}
.brand {
  font-family: var(--mono);
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.08em;
  color: var(--ink);
}
.brand .dot {
  color: var(--accent);
}
.topbar-cta {
  display: flex;
  align-items: center;
  gap: 18px;
}
.topbar-cta .price {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--ink-3);
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 9px 16px;
  border-radius: 2px;
  cursor: pointer;
  border: 1px solid transparent;
  transition:
    background 0.12s,
    color 0.12s,
    border-color 0.12s,
    transform 0.08s;
}
.btn-primary {
  background: var(--accent);
  color: var(--bg);
  border-color: var(--accent);
}
.btn-primary:hover {
  background: var(--accent-2);
  border-color: var(--accent-2);
  transform: translateY(-1px);
}
.btn-ghost {
  background: transparent;
  color: var(--ink-2);
  border-color: var(--line-hi);
}
.btn-ghost:hover {
  border-color: var(--ink-2);
  color: var(--ink);
}

@media (max-width: 600px) {
  .topbar-inner {
    padding: 12px 20px;
  }
  .topbar-cta .price {
    display: none;
  }
  .topbar-cta .btn-ghost {
    display: none;
  }
}

/* ─── Hero ─── */
.hero {
  padding: 96px 0 60px;
  position: relative;
}
.hero-eyebrow {
  margin-bottom: 18px;
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}
.hero-eyebrow .sep {
  color: var(--line-hi);
}
.hero h1 {
  font-family: var(--sans);
  font-weight: 600;
  font-size: clamp(36px, 5.5vw, 64px);
  line-height: 1.04;
  letter-spacing: -0.02em;
  margin: 0 0 22px;
  max-width: 920px;
  text-wrap: balance;
  color: var(--ink);
}
.hero h1 em {
  color: var(--accent);
  font-style: normal;
}
.hero p.sub {
  max-width: 680px;
  font-size: 17px;
  color: var(--ink-2);
  line-height: 1.55;
  margin: 0 0 32px;
  text-wrap: pretty;
}
.hero-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}
.hero-meta {
  margin-left: 8px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-4);
}
.hero-curl {
  margin: 22px 0 0;
  padding: 10px 14px;
  background: #0a0a0a;
  border: 1px solid var(--line);
  border-radius: 3px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-3);
  overflow-x: auto;
  max-width: 760px;
  white-space: nowrap;
}
.hero-curl .prompt {
  color: var(--ink-4);
  user-select: none;
}

@media (max-width: 600px) {
  .hero {
    padding: 56px 0 36px;
  }
  .hero-meta {
    display: block;
    margin: 12px 0 0;
  }
  .hero-curl {
    font-size: 11px;
  }
}

/* ─── Plugin screenshot frame ─── */
.pluginframe {
  margin: 56px auto 0;
  max-width: 920px;
  position: relative;
  border-radius: 4px;
  box-shadow:
    0 0 0 1px var(--line-hi),
    0 24px 60px rgba(0, 0, 0, 0.5),
    0 60px 120px -40px rgba(168, 216, 96, 0.08);
  overflow: hidden;
  background: var(--bg);
}
.pluginframe::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.04),
    transparent 30%
  );
  z-index: 1;
}
.pluginframe img {
  display: block;
  width: 100%;
  height: auto;
}
.pluginframe .crop {
  position: relative;
}
.pluginframe .caption {
  position: absolute;
  bottom: 14px;
  left: 20px;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--ink-4);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  z-index: 2;
}

/* ─── Chapter sections (the three stages) ─── */
.chapters {
  padding: 120px 0 60px;
}
@media (max-width: 700px) {
  .chapters {
    padding: 64px 0 24px;
  }
}

.chapter {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
  padding: 72px 0;
  border-top: 1px solid var(--line);
}
@media (max-width: 880px) {
  .chapter {
    grid-template-columns: 1fr;
    gap: 36px;
    padding: 48px 0;
  }
  .chapter.flip > .chap-text {
    order: -1;
  }
}

.chap-num {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.25em;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.chap-num::before {
  content: "";
  display: inline-block;
  width: 24px;
  height: 1px;
  background: var(--accent);
}
.chap-text h2 {
  font-size: clamp(28px, 3.5vw, 38px);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.1;
  margin: 0 0 22px;
  text-wrap: balance;
  color: var(--ink);
}
.chap-text h2 em {
  color: var(--accent);
  font-style: normal;
}
.chap-text p {
  color: var(--ink-2);
  font-size: 16px;
  line-height: 1.6;
  margin: 0 0 14px;
  text-wrap: pretty;
}
.chap-text p b {
  color: var(--ink);
  font-weight: 600;
}
.chap-text p code {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--accent);
  background: rgba(168, 216, 96, 0.08);
  padding: 1px 6px;
  border-radius: 2px;
}
.chap-text ul {
  list-style: none;
  padding: 0;
  margin: 18px 0 0;
  border-top: 1px dashed var(--line-hi);
  padding-top: 18px;
}
.chap-text li {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--ink-3);
  padding: 4px 0;
  display: flex;
  gap: 14px;
}
.chap-text li span:first-child {
  color: var(--ink-4);
  width: 90px;
  flex-shrink: 0;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 10px;
  padding-top: 3px;
}
.chap-text li span:last-child {
  color: var(--ink-2);
}

/* Chapter visual: small label + focused crop of the plugin screenshot.
   `.chap-visual` is now just a layout container holding the label
   above the framed image. The frame's bordered/shadowed look lives
   on `.chap-frame`, so the label sits cleanly above and never overlays
   the plugin card content the way the old top-left badge did. */
.chap-visual {
  position: relative;
}
.chap-label {
  display: inline-block;
  margin-bottom: 12px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  padding: 3px 8px;
  background: rgba(12, 13, 12, 0.85);
  border: 1px solid var(--line-hi);
  border-radius: 2px;
}
.chap-frame {
  position: relative;
  border-radius: 3px;
  overflow: hidden;
  box-shadow:
    0 0 0 1px var(--line-hi),
    0 18px 40px rgba(0, 0, 0, 0.45);
  background: var(--bg);
  aspect-ratio: 4 / 3;
}
.chap-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    radial-gradient(
      ellipse at center,
      transparent 50%,
      rgba(0, 0, 0, 0.5) 100%
    ),
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent 30%);
}
.chap-visual .crop {
  position: absolute;
  inset: 0;
  background: url("plugin.png") no-repeat;
  background-size: 300% 300%;
}
/* Per-chapter background-position to focus on each stage card.
   The three stage cards live across the bottom row of plugin.png,
   so we slice the bottom edge into thirds (left / centre / right). */
.chap-visual.stage1 .crop {
  background-position: 1% 100%;
}
.chap-visual.stage2 .crop {
  background-position: 50% 100%;
}
.chap-visual.stage3 .crop {
  background-position: 99% 100%;
}

/* ─── Detail strip ─── */
.details {
  padding: 88px 0;
  border-top: 1px solid var(--line);
}
.details h3 {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 0 0 28px;
}
.detail-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px 40px;
}
@media (max-width: 880px) {
  .detail-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 480px) {
  .detail-grid {
    grid-template-columns: 1fr;
  }
}
.detail h4 {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin: 0 0 8px;
}
.detail h4 .link-glyph {
  /* Mirrors the in-plugin chain-link icon next to BYPASS so the
     reader sees the same glyph in the docs and the plugin chrome. */
  width: 14px;
  height: 10px;
  display: inline-block;
  vertical-align: -1px;
  margin-right: 6px;
}
.detail p {
  margin: 0;
  font-size: 14px;
  color: var(--ink-2);
  line-height: 1.5;
}

/* ─── Buy / get-it panel ─── */
.buy {
  padding: 96px 0;
  border-top: 1px solid var(--line);
}
.buy-inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 60px;
  align-items: center;
}
@media (max-width: 760px) {
  .buy-inner {
    grid-template-columns: 1fr;
    gap: 36px;
  }
}
.buy h2 {
  font-size: clamp(28px, 3vw, 36px);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.1;
  margin: 0 0 18px;
  text-wrap: balance;
  color: var(--ink);
}
.buy p {
  color: var(--ink-2);
  margin: 0 0 12px;
  font-size: 15px;
}
.buy-card {
  background: var(--bg-card);
  border: 1px solid var(--line-hi);
  border-radius: 4px;
  padding: 28px;
}
.buy-price {
  font-family: var(--mono);
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 6px;
}
.buy-price .num {
  font-size: 48px;
  font-weight: 600;
  color: var(--ink);
}
.buy-price .sub {
  font-size: 12px;
  color: var(--ink-3);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.buy-tag {
  display: inline-block;
  margin-bottom: 22px;
  padding: 3px 8px;
  background: rgba(255, 170, 80, 0.12);
  border: 1px solid rgba(255, 170, 80, 0.35);
  border-radius: 2px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--warn);
}
.buy-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.buy-actions .btn {
  justify-content: center;
  padding: 14px 16px;
  font-size: 13px;
}
.buy-fineprint {
  margin-top: 18px;
  font-family: var(--mono);
  font-size: 11px;
  line-height: 1.7;
  color: var(--ink-3);
}
.buy-fineprint .row {
  display: flex;
  gap: 10px;
}
.buy-fineprint .row > span:first-child {
  color: var(--ink-4);
  width: 90px;
  flex-shrink: 0;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 10px;
  padding-top: 2px;
}

/* ─── Footer ─── */
footer {
  border-top: 1px solid var(--line);
  padding: 36px 0 56px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--ink-4);
  letter-spacing: 0.05em;
}
footer .footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}
footer a:hover {
  color: var(--ink-2);
}
