/* ── landing-only styles ─────────────────────────────────── */

/* hero */
.hero {
  position: relative;
  padding: 96px 0 110px;
  overflow: hidden;
}
.hero-iris {
  position: absolute;
  top: -340px;
  right: -260px;
  width: 820px;
  height: 820px;
  border-radius: 50%;
  background:
    radial-gradient(circle at center,
      rgba(226, 59, 59, 0.16) 0%,
      rgba(226, 59, 59, 0.07) 32%,
      transparent 62%);
  pointer-events: none;
}
.hero-iris::after {
  content: "";
  position: absolute;
  inset: 26%;
  border-radius: 50%;
  border: 1px solid rgba(226, 59, 59, 0.18);
  animation: iris 9s ease-in-out infinite;
}
@keyframes iris {
  0%, 100% { transform: scale(1); opacity: 0.6; }
  50% { transform: scale(1.12); opacity: 0.25; }
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 56px;
  align-items: center;
  position: relative;
}
.hero h1 {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(40px, 5.6vw, 62px);
  line-height: 1.06;
  letter-spacing: -0.015em;
  margin: 16px 0 22px;
}
.hero h1 em { color: var(--crimson-bright); }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 30px; }
.hero-meta { font-family: var(--mono); margin-top: 26px; font-size: 12px; color: var(--ink-faint); letter-spacing: 0.03em; }

/* capture panel */
.capture {
  font-family: var(--mono);
  background: var(--bg-panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow:
    0 30px 80px -30px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(226, 59, 59, 0.05),
    0 0 90px -40px rgba(226, 59, 59, 0.35);
  font-size: 12.5px;
  transform: rotate(0.6deg);
}
.capture-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--line-soft);
  color: var(--ink-faint);
  font-size: 11px;
  letter-spacing: 0.1em;
}
.rec { color: var(--crimson-bright); display: flex; align-items: center; gap: 6px; font-weight: 600; }
.rec i {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--crimson-bright);
  animation: blink 1.4s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0.2; } }
.capture-count { margin-left: auto; }

.capture-body { padding: 10px 0; }
.row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 6px 16px;
  opacity: 0;
  animation: logrow 0.45s ease-out forwards;
  white-space: nowrap;
}
.row:nth-child(1) { animation-delay: 0.7s; }
.row:nth-child(2) { animation-delay: 1.3s; }
.row:nth-child(3) { animation-delay: 1.9s; }
.row:nth-child(4) { animation-delay: 2.5s; }
.row:nth-child(5) { animation-delay: 3.1s; }
.row:nth-child(6) { animation-delay: 3.8s; }
.row:nth-child(7) { animation-delay: 4.5s; }
.row:nth-child(8) { animation-delay: 5.1s; }
@keyframes logrow {
  from { opacity: 0; transform: translateX(-8px); }
  to { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .row { animation: none; opacity: 1; }
  .rec i { animation: none; }
}
.row.err { background: rgba(226, 59, 59, 0.06); box-shadow: inset 2px 0 0 var(--crimson); }
.badge {
  font-size: 10.5px;
  font-weight: 600;
  padding: 1px 7px;
  border-radius: 3px;
  letter-spacing: 0.05em;
}
.badge.ok   { color: var(--ok); background: rgba(76, 195, 138, 0.12); }
.badge.warn { color: var(--warn); background: rgba(229, 161, 59, 0.12); }
.badge.bad  { color: var(--crimson-bright); background: rgba(226, 59, 59, 0.14); }
.badge.proto { color: var(--warn); background: rgba(229, 161, 59, 0.1); }
.badge.proto.blue { color: var(--info); background: rgba(98, 160, 234, 0.12); }
.verb { color: var(--ink); font-weight: 600; min-width: 38px; }
.path { color: var(--ink-dim); overflow: hidden; text-overflow: ellipsis; flex: 1; }
.ms { color: var(--ink-faint); font-size: 11px; }

.capture-foot {
  display: flex;
  justify-content: space-between;
  padding: 9px 16px;
  border-top: 1px solid var(--line-soft);
  color: var(--ink-faint);
  font-size: 11px;
  letter-spacing: 0.06em;
}
.capture-foot b { color: var(--crimson-bright); font-weight: 600; }
.caret { animation: blink 1.1s steps(1) infinite; color: var(--crimson-bright); }

/* sections */
.section { padding: 96px 0 0; }

/* protocol cards */
.proto-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 44px;
}
.proto-card {
  background: var(--bg-raised);
  border: 1px solid var(--line-soft);
  border-radius: 9px;
  padding: 26px 24px 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: border-color 0.2s, transform 0.2s;
}
.proto-card:hover { border-color: var(--crimson-dim); transform: translateY(-3px); }
.proto-card h3 {
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.12em;
  display: flex; gap: 9px; align-items: center;
}
.tick { font-size: 10px; }
.ok-t { color: var(--ok); } .warn-t { color: var(--warn); } .info-t { color: var(--info); }
.proto-card p { color: var(--ink-dim); font-size: 13.5px; flex: 1; }
.proto-card p em { color: var(--ink); font-style: normal; }
.proto-snippet {
  font-family: var(--mono);
  display: block;
  font-size: 12px;
  color: var(--crimson-bright);
  background: var(--bg);
  border: 1px solid var(--line-soft);
  border-radius: 5px;
  padding: 8px 12px;
  overflow-x: auto;
  white-space: nowrap;
}

/* agent section */
.agent-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 40px;
  margin-top: 44px;
  align-items: start;
}
.agent-points {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 18px;
  font-size: 13.5px;
  color: var(--ink-dim);
}
.agent-points li { padding-left: 20px; position: relative; }
.agent-points li::before {
  content: "▸";
  position: absolute; left: 0;
  color: var(--crimson-bright);
}
.agent-points b { color: var(--ink); }

/* noop */
.noop-block { margin-top: 40px; max-width: 640px; }
.noop-note { margin-top: 16px; font-size: 13px; color: var(--ink-faint); max-width: 640px; }
.noop-note a { color: var(--crimson-bright); border-bottom: 1px solid var(--crimson-dim); }

/* gallery */
.gallery-section { background: linear-gradient(var(--bg), var(--bg-raised) 30%, var(--bg)); }
.gallery {
  display: flex;
  gap: 22px;
  overflow-x: auto;
  padding: 48px 24px 18px;
  max-width: calc(var(--maxw) + 48px);
  margin: 0 auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}
.gallery figure { scroll-snap-align: start; flex: 0 0 232px; }
.gallery img {
  width: 100%;
  border-radius: 14px;
  border: 1px solid var(--line);
  box-shadow: 0 18px 50px -18px rgba(0, 0, 0, 0.7);
  transition: transform 0.25s, box-shadow 0.25s;
}
.gallery figure:nth-child(odd) img { transform: rotate(-0.7deg); }
.gallery figure:nth-child(even) img { transform: rotate(0.7deg); }
.gallery img:hover {
  transform: rotate(0deg) translateY(-6px);
  box-shadow: 0 24px 60px -16px rgba(226, 59, 59, 0.25);
}
.gallery figcaption {
  font-family: var(--mono);
  text-align: center;
  margin-top: 12px;
  font-size: 11.5px;
  letter-spacing: 0.08em;
  color: var(--ink-faint);
}

/* quickstart */
.qs-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin: 44px 0 40px;
}
.qs-step {
  border-top: 1px solid var(--line);
  padding-top: 18px;
  font-size: 13.5px;
  color: var(--ink-dim);
}
.qs-n {
  font-family: var(--display);
  font-style: italic;
  font-size: 30px;
  color: var(--crimson-bright);
  display: block;
  margin-bottom: 10px;
}

@media (max-width: 880px) {
  .hero { padding: 64px 0 70px; }
  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 44px; }
  /* Let the capture panel shrink below its nowrap min-content instead of
     inflating the grid track (which stretched — and clipped — the hero text). */
  .capture { transform: none; min-width: 0; }
  .proto-grid, .qs-steps { grid-template-columns: 1fr; }
  .agent-grid { grid-template-columns: 1fr; }
  /* Same fix for the protocol cards: the nowrap .proto-snippet was inflating
     the card's min-content and pushing card text off-screen. Let the card
     shrink so the snippet scrolls inside it (it already has overflow-x: auto). */
  .proto-card { min-width: 0; }
  /* Break long inline identifiers/paths so they wrap instead of overflowing. */
  .qs-step code, .agent-points code, .noop-note code { overflow-wrap: anywhere; }
}
