/* ── The Robot Reviews — watching.therobot.is ───────────────────────────
   Hand-authored, no build step. Dark-committed: this is a monitoring tool,
   it should look like one. Tokens first, then layout, then sections.
   ──────────────────────────────────────────────────────────────────────── */

:root {
  /* surface */
  --bg:          #0a0c10;
  --bg-alt:      #0e1117;
  --bg-card:     #131720;
  --bg-card-hi:  #171c27;
  --line:        #222836;
  --line-soft:   #1a1f2b;

  /* ink */
  --ink:         #e8ecf3;
  --ink-dim:     #a3adc0;
  --ink-mute:    #6b7688;

  /* Lifecycle-state palette — reused as the brand accents, deliberately:
     the state machine IS the product, so the product's colors are its states. */
  --open:        #f59e0b;   /* amber   — found, unread */
  --ack:         #60a5fa;   /* blue    — seen, owned   */
  --defer:       #a78bfa;   /* violet  — ticking       */
  --waive:       #94a3b8;   /* slate   — signed off    */
  --fixed:       #34d399;   /* green   — actually done */

  --accent:      var(--open);
  --accent-ink:  #0a0c10;

  /* type */
  --sans: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI",
          Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas,
          "Liberation Mono", monospace;

  /* metrics */
  --wrap:   1080px;
  --narrow: 720px;
  --r:      10px;
}

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

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

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

img { max-width: 100%; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

:focus-visible {
  outline: 2px solid var(--ack);
  outline-offset: 3px;
  border-radius: 3px;
}

/* keyboard users get out of the header without tabbing the whole page */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  padding: 10px 18px;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
  border-radius: 0 0 var(--r) 0;
}
.skip-link:focus {
  left: 0;
  text-decoration: none;
}

/* ── Layout ─────────────────────────────────────────────────────────── */

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

.band {
  padding-block: clamp(64px, 9vw, 116px);
  border-top: 1px solid var(--line-soft);
}
.band-alt { background: var(--bg-alt); }

/* ── Type ───────────────────────────────────────────────────────────── */

h1, h2, h3 {
  margin: 0 0 0.5em;
  line-height: 1.12;
  letter-spacing: -0.022em;
  font-weight: 640;
}

h1 {
  font-size: clamp(2.6rem, 7vw, 4.6rem);
  letter-spacing: -0.035em;
  margin-bottom: 0.32em;
}

h2 {
  font-size: clamp(1.75rem, 3.6vw, 2.6rem);
  margin-bottom: 0.45em;
  max-width: 20ch;
}

h3 {
  font-size: 1.06rem;
  font-weight: 620;
  letter-spacing: -0.01em;
  margin-bottom: 0.5em;
}

p { margin: 0 0 1.05em; }
p:last-child { margin-bottom: 0; }

.lede {
  font-size: clamp(1.08rem, 1.9vw, 1.3rem);
  color: var(--ink-dim);
  max-width: 58ch;
  margin-bottom: 2.2em;
}

.section-lede {
  color: var(--ink-dim);
  max-width: 64ch;
  margin-bottom: 2.4em;
}

.muted { color: var(--ink-mute); }
.mono  { font-family: var(--mono); }

.fineprint {
  margin-top: 1.6em;
  font-size: 0.9rem;
  color: var(--ink-mute);
}

.kicker {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin-bottom: 1em;
}

/* ── Hero ───────────────────────────────────────────────────────────── */

.hero {
  padding-block: clamp(88px, 14vw, 168px) clamp(64px, 9vw, 112px);
  /* a faint amber wash from the top-left — "something is watching" */
  background:
    radial-gradient(900px 460px at 8% -8%, rgba(245, 158, 11, 0.10), transparent 62%),
    radial-gradient(700px 420px at 92% 4%, rgba(96, 165, 250, 0.06), transparent 60%);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-family: var(--mono);
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  color: var(--ink-dim);
  margin: 0 0 2.1em;
}

.pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--fixed);
  box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.55);
  animation: pulse 2.4s ease-out infinite;
}
@keyframes pulse {
  70%  { box-shadow: 0 0 0 9px rgba(52, 211, 153, 0); }
  100% { box-shadow: 0 0 0 0  rgba(52, 211, 153, 0); }
}

.badge {
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--open);
  border: 1px solid rgba(245, 158, 11, 0.38);
  background: rgba(245, 158, 11, 0.08);
  border-radius: 999px;
  padding: 3px 10px;
}

/* ── Buttons ────────────────────────────────────────────────────────── */

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 0.5em;
}

.btn {
  display: inline-block;
  padding: 13px 26px;
  border-radius: var(--r);
  font-weight: 580;
  font-size: 0.97rem;
  border: 1px solid transparent;
  transition: transform 0.12s ease, background 0.16s ease, border-color 0.16s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }

.btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
}
.btn-primary:hover { background: #fbbf24; }

.btn-ghost {
  border-color: var(--line);
  color: var(--ink);
  background: transparent;
}
.btn-ghost:hover {
  border-color: var(--ink-mute);
  background: rgba(255, 255, 255, 0.03);
}

/* ── Cards ──────────────────────────────────────────────────────────── */

.grid { display: grid; gap: 18px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.card {
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 26px 24px;
  transition: border-color 0.16s ease, background 0.16s ease;
}
.card:hover { border-color: #2c3446; background: var(--bg-card-hi); }
.card p { color: var(--ink-dim); font-size: 0.96rem; margin: 0; }
.card .kicker { margin-bottom: 0.7em; }

/* accent cards carry a top hairline, cycled through the lifecycle colors */
.card-accent { position: relative; overflow: hidden; }
.card-accent::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 2px;
  opacity: 0.75;
  background: var(--defer);
}
.card-accent:nth-child(2)::before { background: var(--waive); }
.card-accent:nth-child(3)::before { background: var(--ack); }
.card-accent:nth-child(4)::before { background: var(--fixed); }

/* ── Lifecycle diagram ──────────────────────────────────────────────── */

.lifecycle {
  margin: 0 0 44px;
  padding: 34px 28px 20px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--r);
}

.states {
  display: flex;
  align-items: stretch;
  gap: 10px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.state {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 14px 14px 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg-alt);
  position: relative;
}

/* the connector between states */
.state + .state::after {
  content: "";
  position: absolute;
  left: -10px;
  top: 50%;
  width: 10px;
  height: 1px;
  background: var(--line);
}

.state .dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  margin-bottom: 5px;
}
.state strong {
  font-family: var(--mono);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.state em {
  font-style: normal;
  font-size: 0.78rem;
  color: var(--ink-mute);
  line-height: 1.4;
}

.s-open  .dot { background: var(--open); }
.s-ack   .dot { background: var(--ack); }
.s-def   .dot { background: var(--defer); }
.s-waive .dot { background: var(--waive); }
.s-fixed .dot { background: var(--fixed); }

.s-open  strong { color: var(--open); }
.s-ack   strong { color: var(--ack); }
.s-def   strong { color: var(--defer); }
.s-waive strong { color: var(--waive); }
.s-fixed strong { color: var(--fixed); }

/* the auto-reopen arc looping back from deferred to open */
.reopen { position: relative; margin-top: 6px; }
.reopen svg {
  display: block;
  width: 100%;
  height: 44px;
  overflow: visible;
}
.reopen svg path {
  fill: none;
  stroke: var(--defer);
  stroke-width: 1.5;
  stroke-dasharray: 4 4;
  opacity: 0.8;
}
.reopen svg polygon { fill: var(--defer); opacity: 0.8; }

.reopen-label {
  position: absolute;
  left: 30%;   /* mid-point of the deferred→open arc (x=60..300 of 600) */
  bottom: -4px;
  transform: translateX(-50%);
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.06em;
  color: var(--defer);
  background: var(--bg-card);
  padding: 0 10px;
}

/* ── Feature list ───────────────────────────────────────────────────── */

.feature-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 34px 44px;
}
.feature-list > li {
  padding-left: 18px;
  border-left: 2px solid var(--line);
  transition: border-left-color 0.16s ease;
}
.feature-list > li:hover { border-left-color: var(--accent); }
.feature-list p {
  color: var(--ink-dim);
  font-size: 0.96rem;
  margin: 0;
}

/* ── CTA + footer ───────────────────────────────────────────────────── */

.band-cta {
  background:
    radial-gradient(760px 380px at 50% 110%, rgba(245, 158, 11, 0.09), transparent 62%),
    var(--bg-alt);
  text-align: center;
}
.band-cta h2 { max-width: none; }
.band-cta .section-lede { margin-inline: auto; }
.band-cta .cta-row { justify-content: center; margin-top: 1.6em; }

.site-footer {
  padding-block: 40px 56px;
  border-top: 1px solid var(--line-soft);
  font-size: 0.9rem;
}
.site-footer .mono { color: var(--ink-dim); margin-bottom: 0.3em; }
.site-footer p { margin: 0; }

/* ── Responsive ─────────────────────────────────────────────────────── */

@media (max-width: 900px) {
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .states { flex-wrap: wrap; }
  .state { flex: 1 1 44%; }
  .state + .state::after { display: none; }
  .reopen { display: none; }   /* the arc only reads correctly on a single row */
}

@media (max-width: 620px) {
  body { font-size: 16px; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .feature-list { grid-template-columns: 1fr; gap: 26px; }
  .state { flex: 1 1 100%; }
  .cta-row .btn { width: 100%; text-align: center; }
}

/* ── status chips (live / next) ─────────────────────────── */
.status-chip {
  display: inline-block;
  font-family: var(--mono, ui-monospace, monospace);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.2rem 0.6rem;
  border-radius: 3px;
  margin-bottom: 0.75rem;
}
.status-chip.live {
  color: #7ce38b;
  border: 1px solid rgba(124, 227, 139, 0.35);
  background: rgba(124, 227, 139, 0.06);
}
.status-chip.next {
  color: #9aa4b2;
  border: 1px solid rgba(154, 164, 178, 0.3);
  background: rgba(154, 164, 178, 0.05);
}
.card-coming {
  opacity: 0.88;
}

/* ── beta signup form ───────────────────────────────────── */
.signup-form {
  margin-top: 1.5rem;
}
.signup-row {
  display: flex;
  gap: 0.75rem;
  align-items: stretch;
}
.signup-row input[type="email"] {
  flex: 1 1 auto;
  min-width: 0;
  padding: 0.7rem 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.04);
  color: inherit;
  font: inherit;
}
.signup-row input[type="email"]:focus {
  outline: 2px solid rgba(124, 227, 139, 0.5);
  outline-offset: 0;
  border-color: transparent;
}
.hp-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}
