/* ============================================================
   ystack — landing page
   Warm-ember "workshop / forge" theme. Self-contained, static.
   ============================================================ */

:root {
  /* Surfaces — dark, warm */
  --bg:            #131210;
  --bg-2:          #1a1714;
  --surface:       rgba(255, 244, 230, 0.035);
  --surface-2:     rgba(255, 244, 230, 0.06);
  --border:        rgba(255, 236, 214, 0.10);
  --border-strong: rgba(255, 236, 214, 0.18);

  /* Text — parchment */
  --text:    #f4ede2;
  --muted:   #b6a995;
  --faint:   #8a7e6e;

  /* Ember accent (Claude / build side) */
  --ember:      #ff8a4c;
  --ember-soft: #ffb267;
  --ember-deep: #ef5f2b;

  /* Cool accent (Codex / review side — cross-vendor contrast) */
  --cool:      #7aa7ff;

  --grad: linear-gradient(135deg, var(--ember-soft) 0%, var(--ember) 45%, var(--ember-deep) 100%);

  --radius:    16px;
  --radius-sm: 11px;
  --maxw:      1080px;

  /* Vertical rhythm — generous, responsive section spacing. Each section pads
     by this token top and bottom, so the air *between* two stacked sections is
     two full --section-pad. This is the page's breathing room — the main lever
     of the polish pass, replacing the old hard <hr> dividers with open space. */
  --section-pad: clamp(80px, 12vh, 136px);

  --serif: "Fraunces", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --sans:  "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --shadow: 0 24px 60px -28px rgba(0, 0, 0, 0.7);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

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

/* Ambient forge-glow + faint grid, fixed behind everything */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(60% 50% at 50% -8%, rgba(255, 138, 76, 0.18), transparent 70%),
    radial-gradient(40% 40% at 88% 12%, rgba(122, 167, 255, 0.10), transparent 70%),
    radial-gradient(50% 60% at 8% 30%, rgba(239, 95, 43, 0.08), transparent 70%);
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(255, 236, 214, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 236, 214, 0.025) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(80% 60% at 50% 0%, #000 30%, transparent 85%);
  -webkit-mask-image: radial-gradient(80% 60% at 50% 0%, #000 30%, transparent 85%);
  pointer-events: none;
}

a { color: inherit; text-decoration: none; }

.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  background: linear-gradient(to bottom, rgba(19, 18, 16, 0.85), rgba(19, 18, 16, 0.35));
  border-bottom: 1px solid var(--border);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.28rem;
  letter-spacing: -0.01em;
}
.brand svg { width: 26px; height: 26px; display: block; }
.brand .sub {
  font-family: var(--sans);
  font-weight: 500;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--faint);
  border-left: 1px solid var(--border-strong);
  padding-left: 11px;
  margin-left: 3px;
}
@media (max-width: 540px) { .brand .sub { display: none; } }

/* ---------- Badge / chip ---------- */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--muted);
}
.chip .dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--ember);
  flex: 0 0 auto;
  /* Soft glow that breathes via opacity — it does NOT expand a ring outward,
     so it can never bleed into the label text beside it. */
  box-shadow: 0 0 7px 0 rgba(255, 138, 76, 0.7);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1;    box-shadow: 0 0 6px 0 rgba(255, 138, 76, 0.5); }
  50%      { opacity: 0.5;  box-shadow: 0 0 10px 0 rgba(255, 138, 76, 0.85); }
}
.chip--ember {
  color: var(--text);
  border-color: rgba(255, 138, 76, 0.4);
  background: linear-gradient(180deg, rgba(255, 138, 76, 0.16), rgba(255, 138, 76, 0.05));
}

/* ---------- Hero ---------- */
/* section.hero.wrap (0,2,1) so this wins over the generic section.wrap rhythm
   rule regardless of source order. padding-block keeps .wrap gutters intact. */
section.hero.wrap {
  text-align: center;
  /* Top: generous space below the sticky header. Bottom: a full --section-pad
     so the hero → first section gap matches the open inter-section rhythm. */
  padding-block: clamp(84px, 14vh, 148px) var(--section-pad);
}
.eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--ember-soft);
  margin: 26px 0 0;
}
.hero h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(2rem, 9vw, 4.6rem);
  line-height: 1.04;
  letter-spacing: -0.02em;
  margin: 18px auto 0;
  max-width: min(16ch, 100%);
  overflow-wrap: break-word;
}
.hero h1 .accent {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero p.lead {
  font-size: clamp(1.05rem, 2.1vw, 1.3rem);
  color: var(--muted);
  max-width: 60ch;
  margin: 24px auto 0;
}
.hero .cta {
  margin-top: 34px;
  display: flex;
  gap: 14px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}
.hero .cta .note {
  font-size: 0.92rem;
  color: var(--faint);
}

/* ---------- The build loop (hero centerpiece) ---------- */
/* A focal cycle: six nodes joined by connectors carrying a traveling ember
   pulse, closed by a return arc so it reads as one continuous loop. Decorative
   motion lives behind `aria-hidden`; the labels carry all meaning. */
.loop-stage {
  position: relative;
  margin: 54px auto 0;
  max-width: 1000px;
}

/* Ambient forge: a few rising ember sparks, drifting up behind the loop.
   Background-level, never competing with the headline. */
.embers {
  position: absolute;
  inset: -28px 0 -10px;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.ember-spark {
  position: absolute;
  bottom: -6px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--ember-soft);
  box-shadow: 0 0 6px 1px rgba(255, 138, 76, 0.6);
  opacity: 0;
  animation: ember-rise 7s ease-in infinite;
}
.ember-spark:nth-child(1) { left: 8%;  animation-delay: 0s;    animation-duration: 7.5s; }
.ember-spark:nth-child(2) { left: 22%; animation-delay: 2.4s;  animation-duration: 6.8s; }
.ember-spark:nth-child(3) { left: 35%; animation-delay: 4.1s;  animation-duration: 8.2s; }
.ember-spark:nth-child(4) { left: 49%; animation-delay: 1.3s;  animation-duration: 7.1s; width: 2px; height: 2px; }
.ember-spark:nth-child(5) { left: 63%; animation-delay: 5.2s;  animation-duration: 6.5s; }
.ember-spark:nth-child(6) { left: 77%; animation-delay: 3.0s;  animation-duration: 8.6s; }
.ember-spark:nth-child(7) { left: 88%; animation-delay: 0.9s;  animation-duration: 7.3s; width: 2px; height: 2px; }
.ember-spark:nth-child(8) { left: 95%; animation-delay: 6.0s;  animation-duration: 6.9s; }
@keyframes ember-rise {
  0%   { transform: translateY(0) translateX(0);    opacity: 0; }
  12%  { opacity: 0.8; }
  70%  { opacity: 0.5; }
  100% { transform: translateY(-118px) translateX(10px); opacity: 0; }
}

.loop {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 0;
  flex-wrap: nowrap;
}
.loop .node {
  flex: 1 1 0;
  min-width: 0;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, var(--surface-2), var(--surface));
  border-radius: var(--radius-sm);
  padding: 17px 12px;
  text-align: center;
  position: relative;
  transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}
/* A faint top hairline that lights up as the pulse passes through each node. */
.loop .node::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 2px;
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  background: linear-gradient(90deg, transparent, var(--ember), transparent);
  opacity: 0;
  transition: opacity 0.4s ease;
}
.loop .node .k {
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--faint);
  display: block;
  margin-bottom: 6px;
}
.loop .node .v {
  font-family: var(--serif);
  font-size: 1.06rem;
  font-weight: 600;
}
/* The two Codex steps keep the cool, cross-vendor accent. */
.loop .node--cool { border-color: rgba(122, 167, 255, 0.28); }
.loop .node--cool .k { color: var(--cool); opacity: 0.85; }
.loop .node--cool::before { background: linear-gradient(90deg, transparent, var(--cool), transparent); }
.loop .node--merge {
  border-color: rgba(255, 138, 76, 0.35);
  background: linear-gradient(180deg, rgba(255, 138, 76, 0.14), rgba(255, 138, 76, 0.04));
}

/* Connector: a thin track between nodes with a bright ember head that sweeps
   across left→right, lighting each link in cycle order (a "baton pass" of
   light). The chevron stays drawn as a static fallback. */
.loop .arrow {
  align-self: center;
  flex: 0 0 26px;
  height: 2px;
  position: relative;
  margin: 0 -1px;
  background: linear-gradient(90deg, var(--border-strong), var(--border));
  border-radius: 2px;
}
.loop .arrow::before {  /* static chevron — readable without motion */
  content: "";
  position: absolute;
  right: -1px;
  top: 50%;
  width: 6px;
  height: 6px;
  border-top: 2px solid var(--faint);
  border-right: 2px solid var(--faint);
  transform: translateY(-50%) rotate(45deg);
}
.loop .arrow::after {   /* traveling ember head */
  content: "";
  position: absolute;
  top: 50%;
  left: 0;
  width: 14px;
  height: 4px;
  border-radius: 4px;
  transform: translate(-6px, -50%);
  background: linear-gradient(90deg, transparent, var(--ember-soft), #fff);
  box-shadow: 0 0 10px 1px rgba(255, 178, 103, 0.85);
  opacity: 0;
}
.loop .arrow--cool::after {
  background: linear-gradient(90deg, transparent, #9bbcff, #eaf1ff);
  box-shadow: 0 0 10px 1px rgba(122, 167, 255, 0.85);
}

/* Sequenced "baton pass": each connector + the node after it light up in turn
   across a single shared cycle, then the return arc carries the pulse home. */
.loop .arrow:nth-of-type(1)::after { animation: pulse-run 9s linear infinite; animation-delay: 0.30s; }
.loop .arrow:nth-of-type(2)::after { animation: pulse-run 9s linear infinite; animation-delay: 1.65s; }
.loop .arrow:nth-of-type(3)::after { animation: pulse-run 9s linear infinite; animation-delay: 3.00s; }
.loop .arrow:nth-of-type(4)::after { animation: pulse-run 9s linear infinite; animation-delay: 4.35s; }
.loop .arrow:nth-of-type(5)::after { animation: pulse-run 9s linear infinite; animation-delay: 5.70s; }
.loop .node--step2::before { animation: node-lit 9s ease-in-out infinite; animation-delay: 0.95s; }
.loop .node--step3::before { animation: node-lit 9s ease-in-out infinite; animation-delay: 2.30s; }
.loop .node--step4::before { animation: node-lit 9s ease-in-out infinite; animation-delay: 3.65s; }
.loop .node--step5::before { animation: node-lit 9s ease-in-out infinite; animation-delay: 5.00s; }
.loop .node--step6::before { animation: node-lit 9s ease-in-out infinite; animation-delay: 6.35s; }
.loop .node--step1::before { animation: node-lit 9s ease-in-out infinite; animation-delay: 8.30s; } /* lit by the returning pulse */
@keyframes pulse-run {
  0%   { transform: translate(-6px, -50%);  opacity: 0; }
  3%   { opacity: 1; }
  /* the head crosses its own connector in ~10% of the cycle, then waits */
  11%  { transform: translate(20px, -50%);  opacity: 1; }
  14%  { opacity: 0; }
  100% { transform: translate(20px, -50%);  opacity: 0; }
}
@keyframes node-lit {
  0%, 6%   { opacity: 0; }
  9%       { opacity: 1; }
  16%      { opacity: 0; }
  100%     { opacity: 0; }
}

/* Return arc: closes the cycle (Merge → You). The track is static; a single
   ember dot travels it via SVG <animateMotion> (reversed: keyPoints 1→0). */
.loop-return {
  position: relative;
  z-index: 1;
  margin-top: 4px;
  height: 64px;
}
.loop-return svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}
.return-track {
  fill: none;
  stroke: var(--border-strong);
  stroke-width: 1.5;
  stroke-dasharray: 5 7;
  opacity: 0.7;
}
.return-pulse {
  fill: #fff;
  filter: drop-shadow(0 0 6px rgba(255, 178, 103, 0.95));
}
.loop-return-label {
  position: absolute;
  left: 50%;
  bottom: 6px;
  transform: translateX(-50%);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--faint);
  background: var(--bg);
  padding: 0 12px;
  white-space: nowrap;
}

.loop-caption {
  text-align: center;
  margin: 18px auto 0;
  font-size: 0.9rem;
  color: var(--faint);
}

/* Mobile: stack into a vertical cycle. Connectors rotate to point down; the
   return arc collapses to a simple "loops back" label so nothing overflows. */
@media (max-width: 720px) {
  .loop-stage { margin-top: 40px; }
  .loop { flex-direction: column; align-items: stretch; gap: 0; }
  .loop .node { padding: 14px 12px; }
  .loop .arrow {
    flex: 0 0 22px;
    width: 2px;
    height: 22px;
    align-self: center;
    margin: -1px 0;
    background: linear-gradient(180deg, var(--border-strong), var(--border));
  }
  .loop .arrow::before { right: 50%; top: auto; bottom: -1px; transform: translateX(50%) rotate(135deg); }
  .loop .arrow::after {  /* travel downward on mobile */
    top: 0; left: 50%;
    width: 4px; height: 14px;
    transform: translate(-50%, -6px);
    background: linear-gradient(180deg, transparent, var(--ember-soft), #fff);
  }
  .loop .arrow--cool::after { background: linear-gradient(180deg, transparent, #9bbcff, #eaf1ff); }
  @keyframes pulse-run {
    0%   { transform: translate(-50%, -6px);  opacity: 0; }
    3%   { opacity: 1; }
    11%  { transform: translate(-50%, 18px);  opacity: 1; }
    14%  { opacity: 0; }
    100% { transform: translate(-50%, 18px);  opacity: 0; }
  }
  .loop-return { height: auto; margin-top: 12px; }
  .loop-return svg { display: none; }
  .loop-return-label {
    position: static;
    display: block;
    transform: none;
    text-align: center;
    background: none;
    white-space: normal;
  }
}

/* ---------- Sections ---------- */
/* Open, even vertical rhythm. With the dividers gone, whitespace alone reads
   the section boundaries — so the inter-section air (two --section-pad) is
   deliberately generous. No hard rules, no tinted panels: just open space.
   NB: every section also carries `.wrap` (padding: 0 24px), so the vertical
   rhythm must be set with matching specificity — hence `section.wrap` and
   `padding-block` (which leaves .wrap's horizontal gutters intact). The hero
   and closing override this with their own `section.hero` / `section.closing`
   rules below, at equal specificity but later in the cascade. */
section.wrap { padding-block: var(--section-pad); }
.section-head { max-width: 60ch; margin-bottom: 44px; }
.section-head .kicker {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ember-soft);
}
.section-head h2 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(1.9rem, 4vw, 2.85rem);
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 12px 0 0;
}
.section-head p {
  color: var(--muted);
  font-size: 1.08rem;
  margin: 14px 0 0;
}

/* ---------- Team: two altitudes, four roles ---------- */
.lanes { display: grid; gap: 30px; }
.lane-head {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.lane-head .altitude {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.2rem;
}
.lane-head .bus {
  font-size: 0.74rem;
  letter-spacing: 0.04em;
  color: var(--faint);
  padding: 5px 11px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
}
.lane-head .bus b { color: var(--muted); font-weight: 600; }

.pair {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: stretch;
  gap: 16px;
}
.pair .connector {
  align-self: center;
  color: var(--ember-soft);
  font-size: 1.5rem;
  opacity: 0.8;
}
@media (max-width: 760px) {
  .pair { grid-template-columns: 1fr; gap: 12px; }
  .pair .connector { transform: rotate(90deg); justify-self: center; }
}

.card {
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius);
  padding: 26px 24px;
  position: relative;
  overflow: hidden;
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}
.card:hover {
  transform: translateY(-3px);
  border-color: var(--border-strong);
  background: var(--surface-2);
}
.card .role {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--faint);
}
.card .role .vendor {
  padding: 2px 9px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  font-size: 0.66rem;
  letter-spacing: 0.06em;
}
.card.is-claude .vendor { color: var(--ember-soft); border-color: rgba(255, 138, 76, 0.35); }
.card.is-codex  .vendor { color: var(--cool);       border-color: rgba(122, 167, 255, 0.35); }
.card h3 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.6rem;
  margin: 12px 0 8px;
}
.card p { color: var(--muted); font-size: 0.98rem; margin: 0; }
.card::after {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: var(--grad);
  opacity: 0;
  transition: opacity 0.25s ease;
}
.card.is-codex::after { background: linear-gradient(90deg, var(--cool), #9bbcff); }
.card:hover::after { opacity: 1; }

.bus-note {
  margin-top: 22px;
  text-align: center;
  font-family: var(--serif);
  font-size: 1.15rem;
  color: var(--muted);
}
.bus-note b { color: var(--text); font-weight: 600; }

/* ---------- Principles ---------- */
.principles {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}
@media (max-width: 720px) { .principles { grid-template-columns: 1fr; } }
.principle {
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius);
  padding: 28px 26px;
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}
.principle:hover {
  transform: translateY(-3px);
  border-color: var(--border-strong);
  background: var(--surface-2);
}
.principle .num {
  font-family: var(--serif);
  font-size: 0.95rem;
  color: var(--ember-soft);
  font-weight: 600;
}
.principle h3 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.42rem;
  margin: 6px 0 10px;
}
.principle p { color: var(--muted); margin: 0; font-size: 1rem; }

/* ---------- Outcomes / who it's for ---------- */
.outcomes {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}
@media (max-width: 720px) { .outcomes { grid-template-columns: 1fr; } }
.outcome { padding: 30px 28px; }
.outcome-icon {
  display: inline-grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: var(--radius-sm);
  color: var(--ember-soft);
  border: 1px solid rgba(255, 138, 76, 0.3);
  background: linear-gradient(180deg, rgba(255, 138, 76, 0.12), rgba(255, 138, 76, 0.03));
  margin-bottom: 18px;
}
.outcome-icon svg { width: 24px; height: 24px; display: block; }
.outcome h3 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.5rem;
  margin: 10px 0 10px;
}
.outcome code {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.86em;
  padding: 1px 6px;
  border-radius: 6px;
  border: 1px solid var(--border-strong);
  background: var(--surface-2);
  color: var(--text);
}

.audience {
  margin: 22px 0 0;
  padding: 22px 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--muted);
  font-size: 1.05rem;
}
.audience .audience-label {
  display: block;
  font-family: var(--sans);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ember-soft);
  margin-bottom: 8px;
}
.audience b { color: var(--text); font-weight: 600; }

/* ---------- In practice: vertical stepper ---------- */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  position: relative;
  display: grid;
  gap: 18px;
}
.step {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 20px;
  position: relative;
}
/* The connecting rail: a vertical line drawn down from each number to the next,
   so the steps read as a single timeline. The last step omits it. */
.step::before {
  content: "";
  position: absolute;
  left: 25px;            /* centre of the 52px-wide number badge (26 - 1) */
  top: 52px;
  bottom: -18px;         /* span the grid gap into the next step */
  width: 2px;
  background: linear-gradient(to bottom, var(--border-strong), var(--border));
}
.step:last-child::before { display: none; }

.step-num {
  flex: 0 0 auto;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.35rem;
  color: var(--ember-soft);
  background: var(--surface);
  border: 1px solid rgba(255, 138, 76, 0.35);
  position: relative;
  z-index: 1;
}
.step--cool .step-num {
  color: var(--cool);
  border-color: rgba(122, 167, 255, 0.4);
}
.step--merge .step-num {
  color: var(--text);
  background: linear-gradient(180deg, rgba(255, 138, 76, 0.18), rgba(255, 138, 76, 0.05));
  border-color: rgba(255, 138, 76, 0.5);
}

.step-body {
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius);
  padding: 20px 24px;
  transition: border-color 0.25s ease, background 0.25s ease;
}
.step-body:hover { border-color: var(--border-strong); background: var(--surface-2); }
.step--merge .step-body {
  border-color: rgba(255, 138, 76, 0.28);
  background: linear-gradient(180deg, rgba(255, 138, 76, 0.07), rgba(255, 138, 76, 0.02));
}

.step-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--faint);
}
.step-vendor {
  padding: 2px 9px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  font-size: 0.64rem;
  letter-spacing: 0.06em;
  text-transform: none;
}
.step-vendor--cool { color: var(--cool); border-color: rgba(122, 167, 255, 0.35); }
.step-body h3 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.36rem;
  margin: 10px 0 8px;
}
.step-body p { color: var(--muted); margin: 0; font-size: 1rem; }

.steps-meta {
  margin: 28px 0 0;
  text-align: center;
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.1rem;
  color: var(--muted);
}

@media (max-width: 600px) {
  .step { gap: 14px; }
  .step-num { width: 44px; height: 44px; font-size: 1.18rem; }
  .step::before { left: 21px; top: 44px; }
  .step-body { padding: 18px 18px; }
}

/* ---------- Closing ---------- */
/* section.closing.wrap (0,2,1) to win over the generic section.wrap rhythm. */
section.closing.wrap {
  text-align: center;
  /* padding-block keeps .wrap's horizontal gutters intact.
     A touch more than --section-pad up top so the final beat lands with air. */
  padding-block: clamp(96px, 14vh, 156px) clamp(88px, 13vh, 140px);
}
/* Eyebrow in place of the old (redundant) "Coming soon" chip — the header chip
   carries the status; here we just set the closing beat with a quiet kicker. */
.closing-eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ember-soft);
}
.closing h2 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(2rem, 5vw, 3.4rem);
  letter-spacing: -0.02em;
  margin: 22px auto 0;
  max-width: 18ch;
}
.closing h2 .accent {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.closing p { color: var(--muted); max-width: 52ch; margin: 18px auto 0; font-size: 1.1rem; }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 34px 0;
}
.site-footer .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  color: var(--faint);
  font-size: 0.9rem;
}
.site-footer .motto { font-family: var(--serif); font-style: italic; }
.site-footer .credit {
  color: var(--muted);
  border-bottom: 1px solid var(--border-strong);
  transition: color 0.2s ease, border-color 0.2s ease;
}
.site-footer .credit:hover {
  color: var(--ember-soft);
  border-color: var(--ember-soft);
}

/* ---------- Reveal animation ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
[data-reveal].in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  [data-reveal] { opacity: 1; transform: none; transition: none; }
  .chip .dot { animation: none; }

  /* Hero loop: all decorative motion off; the static cycle stays complete and
     legible. Connectors keep their chevrons; the return arc keeps its track and
     label; nodes keep their accents. No meaning is carried by motion alone.
     Selectors mirror the animated ones so these overrides win on specificity. */
  .embers { display: none; }
  .loop .arrow:nth-of-type(1)::after,
  .loop .arrow:nth-of-type(2)::after,
  .loop .arrow:nth-of-type(3)::after,
  .loop .arrow:nth-of-type(4)::after,
  .loop .arrow:nth-of-type(5)::after { animation: none; opacity: 0; }
  .loop .node--step1::before,
  .loop .node--step2::before,
  .loop .node--step3::before,
  .loop .node--step4::before,
  .loop .node--step5::before,
  .loop .node--step6::before { animation: none; opacity: 0; }
  .return-pulse { display: none; }
}

/* Focus visibility for keyboard users */
:focus-visible {
  outline: 2px solid var(--ember);
  outline-offset: 3px;
  border-radius: 4px;
}
