/* SoGood homepage — uses tokens from styles.css */

.skip-link {
  position: absolute;
  left: -9999px;
}
.skip-link:focus {
  position: fixed;
  top: 8px; left: 8px;
  background: var(--ink);
  color: white;
  padding: 8px 14px;
  border-radius: 8px;
  z-index: 100;
}

/* ─────────── HOME HERO ───────────
   Single consolidated declaration. Older versions had 3 .home-hero rules
   competing across breakpoints — one of them snuck a 40px top margin in at
   ≤900px which kept the alpha eyebrow pinned ~40px below the nav. */
.home-hero {
  max-width: none;
  margin: 0;
  padding: 0 max(env(safe-area-inset-right), 24px) 96px max(env(safe-area-inset-left), 24px);
  text-align: center;
  position: relative;
}
.home-hero::before {
  content: "";
  position: absolute;
  top: 40px;
  left: 50%;
  transform: translateX(-50%);
  width: 720px;
  height: 405px;
  /* WebP first (51KB) with PNG fallback (724KB) for older clients */
  background: url("header-image.png") center / contain no-repeat;
  background: image-set(
    url("header-image.webp") type("image/webp") 1x,
    url("header-image.png") type("image/png") 1x
  ) center / contain no-repeat;
  pointer-events: none;
  z-index: 0;
  /* Radial vignette: center 50% fully visible, fades to transparent at edges */
  mask-image: radial-gradient(ellipse 55% 60% at center, rgba(0,0,0,1) 0%, rgba(0,0,0,1) 50%, rgba(0,0,0,0.5) 78%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 55% 60% at center, rgba(0,0,0,1) 0%, rgba(0,0,0,1) 50%, rgba(0,0,0,0.5) 78%, transparent 100%);
}
.home-hero > * {
  position: relative;
  z-index: 1;
  max-width: 920px;
  margin-left: auto;
  margin-right: auto;
}

.alpha-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.22em;
  color: var(--ink-3);
  margin: 12px 0 0;
  text-transform: uppercase;
}
.alpha-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--brand);
}

.hero-h1 {
  font-size: clamp(40px, 6.8vw, 84px);
  line-height: 1.02;
  letter-spacing: -0.03em;
  margin: 460px auto 28px; /* tucked just under the image */
  font-weight: 600;
  color: var(--ink);
}
@media (max-width: 768px) {
  .hero-h1 { margin-top: 220px; }
}
.hero-rotate {
  display: inline-block;
  color: var(--brand);
  position: relative;
  font-family: var(--serif);
  font-weight: 400;
  font-style: italic;
  letter-spacing: -0.01em;
}
.rotate-text {
  display: inline-block;
  transition: opacity .25s var(--ease-soft), transform .25s var(--ease-soft);
}
.rotate-text.swap {
  opacity: 0;
  transform: translateY(-6px);
}
.rotate-cursor {
  display: inline-block;
  width: 0.06em;
  height: 0.85em;
  background: currentColor;
  vertical-align: text-bottom;
  margin-left: 0.04em;
  margin-bottom: 0.08em;
  animation: blink 1s steps(2, end) infinite;
}
@keyframes blink {
  to { opacity: 0; }
}

.hero-lede {
  font-size: clamp(17px, 1.4vw, 20px);
  color: var(--ink-3);
  max-width: 64ch;
  margin: 0 auto 40px;
  line-height: 1.6;
}

/* ── CATEGORY TABS (replit pattern) ── */
/* hide examples not matching active category */
.example-card.hidden { display: none; }

/* ── HERO CHATBOT ── */
.hero-chat {
  position: relative;
  max-width: 720px;
  margin: 0 auto 40px;
  background: var(--bg-mute);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  transition: border-color .14s, box-shadow .14s, background .14s;
}
.hero-chat:focus-within {
  border-color: var(--accent);
  background: white;
  box-shadow: var(--shadow-md);
}
.hero-chat textarea {
  display: block;
  width: 100%;
  border: 0;
  outline: 0;
  resize: none;
  background: transparent;
  font: inherit;
  font-size: 16px;
  color: var(--ink);
  padding: 18px 22px 56px;
  border-radius: var(--radius-lg);
  line-height: 1.5;
}
.hero-chat textarea::placeholder {
  color: var(--ink-3);
  opacity: .6;
}
.chat-send {
  position: absolute;
  bottom: 12px; right: 12px;
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--accent);
  color: white;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background .14s, transform .14s;
  cursor: pointer;
  border: 0;
}
.chat-send:hover {
  background: var(--accent-hover);
  transform: scale(1.05);
}
.chat-send svg {
  width: 16px; height: 16px;
}

/* ── EXAMPLES as 2x2 cards ── */
.hero-examples {
  max-width: 720px;
  margin: 0 auto 48px;
  text-align: left;
}
.example-label {
  font-size: 11px;
  letter-spacing: 0.18em;
  font-weight: 700;
  color: var(--ink-3);
  margin: 0 0 14px;
  text-transform: uppercase;
}
.example-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.example-card {
  text-align: left;
  background: var(--bg-mute);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink-3);
  font-weight: 500;
  cursor: pointer;
  min-height: 96px;
  box-shadow: var(--shadow-md);
  transition: all .2s var(--ease-soft);
}
.example-card:hover {
  background: white;
  border-color: var(--accent);
  color: var(--ink);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}
.example-card.flash {
  border-color: var(--brand);
  background: var(--brand-muted);
  color: var(--ink);
}

/* ── TRUST LINE with check icons ── */
.trust-line {
  list-style: none;
  padding: 0;
  margin: 0;
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px 18px;
  font-size: 14px;
  color: var(--ink-3);
}
.trust-line li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.trust-line li svg {
  width: 16px; height: 16px;
  color: var(--brand);
  flex-shrink: 0;
}
.dot-sep { color: var(--line-strong); }

/* ─────────── SECTION HEADS ─────────── */
.section-head {
  text-align: center;
  margin-bottom: 64px;
}
.section-h2 {
  font-size: clamp(34px, 4.8vw, 60px);
  line-height: 1.05;
  letter-spacing: -0.025em;
  font-weight: 600;
  margin: 8px 0 0;
  color: var(--ink);
}
.section-h2 em {
  font-family: var(--serif);
  font-weight: 400;
  font-style: italic;
  letter-spacing: -0.02em;
  position: relative;
  display: inline-block;
}
/* ─────────── CONTROL ROOM ─────────── */
.control-room {
  max-width: 1180px;
  margin: 100px auto;
  padding: 0 24px;
}

.feature {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
  margin-bottom: 96px;
}
.feature.reverse .feature-copy { order: 2; }
.feature.reverse .feature-mock { order: 1; }

.feature-copy {
  max-width: 460px;
}
.feature-num {
  display: inline-block;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--brand-deep);
  background: var(--brand-muted);
  padding: 3px 10px;
  border-radius: 999px;
  font-weight: 700;
  letter-spacing: 0.04em;
  margin-bottom: 14px;
}
.feature-copy h3 {
  font-size: clamp(26px, 2.8vw, 36px);
  line-height: 1.1;
  letter-spacing: -0.02em;
  font-weight: 800;
  margin: 0 0 14px;
  color: var(--ink);
}
.feature-copy p {
  font-size: 17px;
  color: var(--ink-3);
  line-height: 1.6;
  margin: 0;
}

/* ── shared mock card ── */
.mock-card {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  padding: 22px;
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: relative;
  overflow: hidden;
  transition: box-shadow .25s, transform .25s;
}
/* removed decorative ::before radial — keep cards clean */
.feature:hover .mock-card {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.mock-card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}
.mock-card-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
  margin: 0;
  letter-spacing: -0.01em;
}
.mock-card-sub {
  font-size: 12px;
  color: var(--muted);
  margin: 2px 0 0;
}

/* ── TEAM card ── */
.team-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.team-row {
  display: grid;
  grid-template-columns: 30px 80px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 13px;
  transition: background .15s;
}
.team-row:hover { background: var(--brand-muted); }
.team-row.faded {
  background: transparent;
  border-style: dashed;
  border-color: var(--line-2);
  opacity: .85;
  /* keep 4-col grid (30 / 80 / 1fr / auto), span the stack across cols 1-2 */
}
.team-row.faded .agent-stack-mini {
  grid-column: 1 / 3;
  flex-wrap: nowrap;
  flex-shrink: 0;
}
.team-row.faded .team-status {
  grid-column: 3 / 5;
}
.team-row .team-name {
  font-weight: 700;
  color: var(--ink);
}
.team-row .team-status {
  color: var(--ink-3);
  font-size: 12px;
}
.team-spinner {
  width: 14px; height: 14px;
  border: 2px solid var(--brand-muted);
  border-top-color: var(--brand);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.team-bar {
  width: 60px;
  height: 4px;
  background: var(--bg-mute);
  border-radius: 999px;
  overflow: hidden;
}
.team-bar i {
  display: block;
  height: 100%;
  background: var(--brand);
  border-radius: 999px;
}
.team-bar.idle i { background: var(--line-2); }
.team-tag.yours {
  background: var(--gold);
  color: var(--gold-fg);
  font-size: 9px;
  padding: 4px 8px;
  border-radius: 999px;
  font-weight: 700;
  letter-spacing: 0.14em;
}
.agent-stack-mini {
  display: flex;
  align-items: center;
}
.agent-stack-mini .agent {
  width: 22px; height: 22px;
  font-size: 9px;
  margin-right: -6px;
  border-width: 2px;
}
.agent-extra {
  display: inline-flex;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--bg-mute);
  color: var(--ink-3);
  font-size: 9px;
  font-weight: 700;
  align-items: center;
  justify-content: center;
  border: 2px solid white;
  margin-left: -2px;
}

/* ── FEED card ── */
.feed-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
}
.feed-list::before {
  content: "";
  position: absolute;
  left: 14px;
  top: 24px;
  bottom: 24px;
  width: 2px;
  background: var(--line);
}
.feed-row {
  display: grid;
  grid-template-columns: 30px 1fr auto;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 12px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 13px;
  position: relative;
  z-index: 1;
}
.feed-row.active {
  background: var(--brand-muted);
  border-color: var(--brand);
}
.feed-row.faded { opacity: .55; }
.feed-body p {
  margin: 0;
  color: var(--ink-2);
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 4px;
}
.feed-body p b { color: var(--ink); font-weight: 700; }
.feed-time {
  color: var(--muted);
  font-size: 11px;
  font-family: var(--mono);
}
.feed-icon {
  font-size: 14px;
  color: var(--muted);
}
.feed-icon.ok {
  color: var(--green);
  font-weight: 700;
}
.dots {
  display: inline-flex;
  gap: 2px;
  margin-left: 4px;
}
.dots i {
  width: 4px; height: 4px;
  background: var(--brand);
  border-radius: 50%;
  animation: typing 1.4s ease-in-out infinite;
}
.dots i:nth-child(2) { animation-delay: .2s; }
.dots i:nth-child(3) { animation-delay: .4s; }
@keyframes typing {
  0%, 60%, 100% { opacity: .25; transform: scale(.8); }
  30% { opacity: 1; transform: scale(1); }
}

/* ── MEMORY card ── */
.mem-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.mem-row {
  display: grid;
  grid-template-columns: 24px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-size: 13px;
}
.mem-row.faded { opacity: .65; }
.mem-icon {
  width: 24px; height: 24px;
  border-radius: 8px;
  background: var(--brand-muted);
  display: inline-block;
  position: relative;
}
.mem-icon::after {
  content: "";
  position: absolute;
  inset: 6px;
  background: var(--brand);
  border-radius: 3px;
  opacity: .55;
}
.mem-icon.voice::after { border-radius: 50%; }
.mem-icon.date { background: var(--gold-muted); }
.mem-icon.date::after { background: var(--gold); }
.mem-icon.target { background: var(--green-soft); }
.mem-icon.target::after { background: var(--green); border-radius: 50%; }
.mem-icon.brand { background: #fbe1e4; }
.mem-icon.brand::after { background: var(--red); }

.mem-text {
  color: var(--ink-2);
  font-size: 13px;
}
.mem-text b {
  color: var(--ink);
  font-weight: 700;
}
.mem-time {
  color: var(--muted);
  font-size: 11px;
  font-family: var(--mono);
}
.mem-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 14px;
  background: var(--brand-muted);
  border-radius: 10px;
  font-size: 12px;
  color: var(--brand-deep);
  margin-top: 4px;
}
.mem-foot b { font-weight: 700; }

/* ── BUDGET card ── */
.budget-display {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-top: 4px;
}
.budget-spent {
  font-size: 48px;
  font-weight: 800;
  font-family: var(--display);
  color: var(--ink);
  letter-spacing: -0.04em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.budget-spent small {
  font-size: 28px;
  color: var(--ink-3);
  font-weight: 700;
}
.budget-cap {
  font-size: 18px;
  color: var(--muted);
  font-weight: 600;
}

.budget-bar {
  position: relative;
  height: 12px;
  background: var(--bg-mute);
  border-radius: 999px;
  overflow: hidden;
}
.budget-bar-fill {
  position: absolute;
  inset: 0 auto 0 0;
  background: var(--green);
  border-radius: 999px;
  transition: width .8s var(--ease-soft);
  z-index: 2;
}
.budget-bar-zones {
  position: absolute;
  inset: 0;
  display: flex;
  border-radius: 999px;
  overflow: hidden;
  z-index: 1;
}
.budget-bar-zones i {
  display: block;
  height: 100%;
  opacity: .12;
}
.zone-green { flex: 0 0 60%; background: var(--green); }
.zone-amber { flex: 0 0 25%; background: var(--gold); }
.zone-red   { flex: 1; background: var(--red); }

.budget-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.budget-reset {
  font-size: 12px;
  color: var(--muted);
  font-family: var(--mono);
}
/* visual mock label, not a real button — opacity hints non-interactivity */
.budget-raise {
  display: inline-block;
  font-size: 12px;
  color: var(--brand-deep);
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 8px;
  background: var(--brand-muted);
  opacity: .7;
  cursor: default;
  user-select: none;
}

/* ─────────── HOW IT WORKS ─────────── */
.how-section {
  max-width: 1180px;
  margin: 120px auto;
  padding: 0 24px;
}
.how-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.how-step {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: all .25s;
}
.how-step:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
  border-color: var(--brand);
}
.how-num {
  font-family: var(--display);
  font-size: 36px;
  font-weight: 900;
  color: var(--brand);
  letter-spacing: -0.04em;
  line-height: 1;
}
.how-step h4 {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 4px 0 6px;
  color: var(--ink);
}
.how-step p {
  font-size: 15px;
  color: var(--ink-3);
  line-height: 1.6;
  margin: 0 0 14px;
  flex: 1;
}
.how-mock {
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.how-bubble {
  font-style: italic;
  color: var(--ink-2);
  line-height: 1.5;
}
.how-mock-team {
  justify-content: flex-start;
}
.how-mock-team .agent {
  width: 28px; height: 28px;
  font-size: 10px;
  margin-right: -4px;
}
.how-active-pulse {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--green-soft);
  color: var(--green);
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}
.how-active-pulse i {
  width: 6px; height: 6px;
  background: var(--green);
  border-radius: 50%;
  animation: pulse 2s ease-out infinite;
}
.how-mock-approve {
  justify-content: flex-start;
}
.how-yes, .how-no {
  font-size: 12px;
  font-weight: 700;
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid var(--line-2);
  background: white;
  transition: all .15s;
  cursor: pointer;
}
.how-yes {
  background: var(--ink);
  color: white;
  border-color: var(--ink);
}
.how-yes:hover { background: var(--accent-hover); }
.how-no:hover { border-color: var(--brand); color: var(--brand-deep); }

/* ─────────── MEET YOUR TEAM (replit-style 4x2 grid of agents) ─────────── */
.meet-team {
  max-width: 1180px;
  margin: 100px auto;
  padding: 0 24px;
}
.agent-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.agent-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  padding: 22px 20px;
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  text-align: left;
  cursor: pointer;
  transition: all .2s var(--ease-soft);
}
.agent-card:hover {
  border-color: var(--ink);
  background: var(--bg-soft);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.agent-card .agent {
  width: 36px; height: 36px;
  font-size: 12px;
  margin-right: 0;
  border-width: 0;
  flex-shrink: 0;
}
.agent-card .agent svg {
  width: 18px;
  height: 18px;
}
.agent-card-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: -0.015em;
  margin-top: 4px;
}
.agent-card-role {
  font-size: 12px;
  color: var(--ink-3);
  line-height: 1.45;
  letter-spacing: -0.005em;
}
@media (max-width: 900px) {
  .agent-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 540px) {
  .agent-grid { grid-template-columns: 1fr; }
}

/* ─────────── INLINE PRICING (compact, replit pattern) ─────────── */
.home-pricing {
  max-width: 1180px;
  margin: 100px auto;
  padding: 0 24px;
}
.hp-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  align-items: stretch;
}

.hp-card {
  position: relative;
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow .25s, transform .25s;
}
.hp-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.hp-card.featured {
  border-color: var(--ink);
  box-shadow: var(--shadow-lg);
}
.hp-card.featured:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}
.hp-flag {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--ink);
  color: white;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.16em;
  padding: 5px 12px;
  border-radius: 999px;
  white-space: nowrap;
}

.hp-head { display: flex; flex-direction: column; gap: 4px; }
.hp-tier {
  font-size: 11px;
  letter-spacing: 0.22em;
  font-weight: 700;
  color: var(--muted);
  margin: 0;
}
.hp-name {
  font-size: 26px;
  font-family: var(--serif);
  font-weight: 400;
  font-style: italic;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 2px 0 4px;
}
.hp-tagline {
  font-size: 13px;
  color: var(--ink-3);
  margin: 0;
  line-height: 1.5;
  min-height: 38px;
}

.hp-price {
  display: flex;
  align-items: baseline;
  gap: 6px;
  padding: 12px 0;
  border-top: 1px dashed var(--line);
  border-bottom: 1px dashed var(--line);
}
.hp-amount {
  font-size: 38px;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--ink);
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.hp-per {
  font-size: 13px;
  color: var(--muted);
}

.hp-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}
.hp-list li {
  font-size: 13px;
  color: var(--ink-2);
  padding-left: 22px;
  position: relative;
  line-height: 1.5;
}
.hp-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 5px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--green-soft);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'><path d='M3 7.5l2.5 2.5L11 4.5' stroke='%233f9d70' stroke-width='2' fill='none' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-position: center;
  background-repeat: no-repeat;
}
.hp-list li b { color: var(--ink); font-weight: 600; }

.hp-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid var(--line-2);
  background: white;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  transition: all var(--motion-fast);
}
.hp-cta:hover { background: var(--bg-soft); border-color: var(--ink-3); }
.hp-cta.primary {
  background: var(--ink);
  color: white;
  border-color: var(--ink);
}
.hp-cta.primary:hover { background: var(--accent-hover); }
.hp-cta .arr { transition: transform var(--motion-fast); display: inline-block; }
.hp-cta:hover .arr { transform: translateX(2px); }

.hp-foot {
  text-align: center;
  margin: 28px 0 0;
  font-size: 14px;
  color: var(--ink-3);
}
.hp-foot a {
  color: var(--brand-deep);
  font-weight: 600;
  text-decoration: none;
}
.hp-foot a:hover { color: var(--accent); text-decoration: underline; }

@media (max-width: 900px) {
  .hp-cards { grid-template-columns: 1fr; max-width: 460px; margin: 0 auto; }
  .hp-card.featured:hover { transform: translateY(-2px); }
}

/* ─────────── BY THE NUMBERS strip ─────────── */
.numbers-strip {
  max-width: 1100px;
  margin: 80px auto 60px;
  padding: 36px 32px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  display: flex;
  align-items: center;
  justify-content: space-around;
  gap: 24px;
}
.num-stat {
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.num-stat b {
  font-size: 40px;
  font-weight: 700;
  font-family: var(--font);
  font-style: normal;
  color: var(--ink);
  letter-spacing: -0.035em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.num-stat b small {
  font-size: 22px;
  color: var(--muted);
  font-weight: 500;
  font-family: var(--font);
  font-style: normal;
  letter-spacing: -0.02em;
}
.num-stat span {
  font-size: 13px;
  color: var(--muted);
  font-family: var(--font);
  font-style: normal;
  letter-spacing: -0.005em;
}
.num-divide {
  width: 1px;
  height: 44px;
  background: var(--line-2);
}
@media (max-width: 768px) {
  .numbers-strip { flex-direction: column; gap: 24px; padding: 28px 24px; }
  .num-divide { display: none; }
}

/* ─────────── HOMEPAGE BOTTOM CTA (clean) ─────────── */
.home-bottom-cta {
  position: relative;
  text-align: center;
  max-width: 720px;
  margin: 0 auto 100px;
  padding: 72px 32px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
}
.home-bottom-cta .cta-orb { display: none; }
.home-bottom-cta .eyebrow { position: relative; }
.cta-h2 {
  font-size: clamp(36px, 5.2vw, 60px);
  line-height: 1.05;
  letter-spacing: -0.025em;
  font-weight: 600;
  margin: 8px 0 14px;
  color: var(--ink);
  position: relative;
}
.cta-h2 em {
  font-family: var(--serif);
  font-weight: 400;
  font-style: italic;
  position: relative;
  display: inline-block;
}
.home-bottom-cta .cta-sub {
  color: var(--ink-3);
  font-size: 16px;
  margin: 0 0 28px;
  position: relative;
}
.home-bottom-cta .cta.primary.big {
  position: relative;
}
/* When the lede sub-text is absent, the heading needs more breathing room above the CTA */
.home-bottom-cta:not(:has(.cta-sub)) .cta-h2 { margin-bottom: 32px; }

/* ─────────── FAQ tweaks for homepage ─────────── */
.faq .faq-sub {
  text-align: center;
  color: var(--ink-3);
  font-size: 15px;
  margin: 0 auto 32px;
  max-width: 480px;
}

/* ─────────── RESPONSIVE ─────────── */
@media (max-width: 900px) {
  .feature {
    grid-template-columns: 1fr;
    gap: 32px;
    margin-bottom: 64px;
  }
  .feature.reverse .feature-copy { order: 0; }
  .feature.reverse .feature-mock { order: 0; }
  .feature-copy { max-width: none; }
  .how-grid { grid-template-columns: 1fr; }
  /* .home-hero margin handled by the @media(≤768) consolidated block below */
  .control-room, .how-section { margin: 64px auto; }
  .home-bottom-cta { padding: 56px 24px; }
}

@media (max-width: 540px) {
  .example-cards { grid-template-columns: 1fr; }
  .trust-line { font-size: 13px; gap: 8px 14px; }
  .trust-line .dot-sep { display: none; }
  /* iOS prevents zoom-on-focus only at >=16px — bumped from 15 */
  .hero-chat textarea { padding: 16px 18px 56px; font-size: 16px; }
}

/* ───────────────────────────────────────────────────────────────
   HOME 2026 MOBILE POLISH (override prior rules)
   ─────────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  /* Hero image scaled down so headline isn't pushed off-screen.
     Image starts BELOW the alpha eyebrow with a real visible gap.
     margin: 0 forces override of the older @media(≤900) rule that adds 40px
     margin-top — that was the real blocker keeping ALPHA anchored ~40px down. */
  .home-hero { margin: 0; padding: 0 max(env(safe-area-inset-right), 18px) 48px max(env(safe-area-inset-left), 18px); }
  .home-hero::before {
    top: 22px;
    width: min(78vw, 420px);
    height: min(42vw, 230px);
    opacity: 0.85;
  }
  .alpha-eyebrow {
    margin-top: 4px;
    position: relative;
    z-index: 2;
  }
  .hero-h1 {
    margin-top: clamp(180px, 48vw, 256px);
    font-size: clamp(32px, 8.4vw, 52px);
    letter-spacing: -0.025em;
  }
  .hero-lede {
    margin-bottom: 28px;
  }

  .hero-chat { margin-bottom: 28px; }
  .hero-examples { margin-bottom: 36px; }
  .example-card {
    padding: 16px 18px;
    font-size: 14px;
    min-height: 80px;
    border-radius: var(--radius);
  }

  .control-room, .how-section, .meet-team, .home-pricing { margin: 64px auto; }
  .section-head { margin-bottom: 40px; }
  .section-h2 { font-size: clamp(28px, 8vw, 44px); }
  .feature-copy h3 { font-size: clamp(24px, 6.5vw, 30px); }

  .mock-card { padding: 16px; border-radius: var(--radius-lg); gap: 12px; }
  .mock-card-head { gap: 8px; }
  .mock-card-title { font-size: 13px; }
  .mock-card-sub { font-size: 11.5px; }

  /* Team mock card: avatar + name/status stacked + indicator (3 cols, no overflow) */
  .team-row, .feed-row, .mem-row { padding: 9px 10px; gap: 10px; }
  .team-row {
    grid-template-columns: 28px minmax(0, 1fr) auto;
    align-items: center;
  }
  .team-row .team-name {
    font-size: 12.5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .team-row .team-status {
    grid-column: 2;
    grid-row: 2;
    font-size: 11.5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: -2px;
  }
  .team-row > .agent { grid-row: 1 / span 2; }
  .team-row > .team-spinner,
  .team-row > .team-bar,
  .team-row > .team-tag { grid-column: 3; grid-row: 1 / span 2; align-self: center; }
  .team-row.faded { grid-template-columns: auto 1fr; }
  .team-row.faded .agent-stack-mini { grid-column: 1; grid-row: 1; }
  .team-row.faded .team-status { grid-column: 2; grid-row: 1; margin-top: 0; align-self: center; }

  /* Feed mock card: avatar + body stacked + icon */
  .feed-row {
    grid-template-columns: 28px minmax(0, 1fr) auto;
    align-items: center;
  }
  .feed-body p {
    font-size: 12.5px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .feed-time { font-size: 10.5px; }

  /* Memory mock card: keep 3 cols but allow text truncation */
  .mem-row {
    grid-template-columns: 22px minmax(0, 1fr) auto;
  }
  .mem-text {
    font-size: 12.5px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  /* Budget mock card: smaller display, full-width bar */
  .budget-spent { font-size: 36px; }
  .budget-cap { font-size: 16px; }
  .budget-bar { height: 10px; }
  .budget-foot { font-size: 11.5px; gap: 8px; }
  .budget-raise { padding: 5px 10px; font-size: 11px; }

  /* How-it-works steps tighter on mobile */
  .how-step { padding: 26px 22px; border-radius: var(--radius-lg); }
  .how-num { font-size: 30px; }
  .how-step h4 { font-size: 19px; }

  /* Bottom CTA reads cleaner on small screens */
  .home-bottom-cta { margin: 0 16px 64px; padding: 56px 24px; border-radius: var(--radius-lg); }
  .cta-h2 { font-size: clamp(30px, 8vw, 44px); }

  /* Numbers strip becomes a 2x2 grid instead of vertical list (less scroll) */
  .numbers-strip {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    padding: 24px 20px;
    margin: 56px 16px 48px;
    border-radius: var(--radius-lg);
  }
  .num-stat b { font-size: 30px; }
  .num-stat span { font-size: 12px; }
}

@media (max-width: 540px) {
  .home-hero::before {
    top: 28px;
    width: min(76vw, 340px);
    height: min(40vw, 184px);
  }
  .hero-h1 {
    margin-top: clamp(160px, 46vw, 220px);
    font-size: clamp(30px, 9vw, 44px);
  }
  .alpha-eyebrow { font-size: 10px; }
  .agent-card { padding: 18px 16px; }
  .agent-card .agent { width: 32px; height: 32px; font-size: 11px; }
  .agent-card-name { font-size: 15px; }
  .agent-card-role { font-size: 11.5px; }
  .numbers-strip { padding: 20px 16px; }
}

/* (safe-area-inset padding folded into the consolidated .home-hero rule above) */

/* ───────────────────────────────────────────────────────────────
   CAT GRID — Lucide icon tiles, adaptive across desktop + mobile
   Replaces the old .cat-tabs pill row (now removed).
   ─────────────────────────────────────────────────────────────── */
.cat-grid {
  display: flex;
  flex-wrap: nowrap;
  justify-content: center;
  gap: 10px;
  margin: 18px auto 36px;
  max-width: 720px;
  width: 100%;
}
.cat-card {
  flex: 1 1 0;
  min-width: 0;
  min-height: 92px;
  padding: 16px 12px;
  border-radius: 14px;
  background: white;
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: pointer;
  transition: background .2s var(--ease-soft), border-color .2s var(--ease-soft), color .2s var(--ease-soft), transform .15s var(--ease-soft), box-shadow .2s var(--ease-soft);
  -webkit-tap-highlight-color: transparent;
  color: var(--ink-2);
  box-shadow: var(--shadow-xs);
}
.cat-card-icon {
  width: 26px;
  height: 26px;
  color: var(--brand-deep);
  transition: color .2s var(--ease-soft), transform .2s var(--ease-soft);
  flex-shrink: 0;
  stroke-width: 2;
  /* Safari: SVG children intercept click events — bubble them to the button */
  pointer-events: none;
}
.cat-card-label {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-align: center;
  color: var(--ink-2);
  line-height: 1.15;
  white-space: nowrap;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  pointer-events: none;
}
@media (hover: hover) {
  .cat-card:hover {
    border-color: var(--ink-3);
    background: var(--bg-soft);
    transform: translateY(-1px);
  }
}
.cat-card.active {
  background: var(--ink);
  border-color: var(--ink);
  color: white;
  box-shadow: var(--shadow-md);
}
.cat-card.active .cat-card-icon { color: var(--gold); transform: scale(1.08); }
.cat-card.active .cat-card-label { color: white; }
.cat-card:active { transform: scale(.97); }

/* Mobile: 5 rounded boxes on a single row, abbreviated labels via data-short */
@media (max-width: 768px) {
  .cat-grid {
    flex-wrap: nowrap;
    gap: 6px;
    max-width: 100%;
    margin: 14px auto 30px;
  }
  .cat-card {
    flex: 1 1 0;
    min-width: 0;
    min-height: 72px;
    padding: 10px 6px;
    border-radius: 14px;
    gap: 5px;
  }
  .cat-card-icon {
    width: 20px;
    height: 20px;
    stroke-width: 2.1;
  }
  .cat-card-label {
    /* Hide full label on mobile, show data-short via ::before for clean fit on 5-in-row */
    font-size: 0;
    line-height: 0;
  }
  .cat-card-label::before {
    content: attr(data-short);
    font-size: 11px;
    line-height: 1.15;
    letter-spacing: -0.02em;
    font-weight: 600;
    color: inherit;
  }
}

/* ───────────────────────────────────────────────────────────────
   ADAPTIVE: agent grid compact on mobile (no role copy, 2-col)
   ─────────────────────────────────────────────────────────────── */
@media (max-width: 540px) {
  .agent-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
  .agent-card {
    flex-direction: row;
    align-items: center;
    padding: 12px 14px;
    gap: 10px;
    min-height: 60px;
    border-radius: var(--radius);
  }
  .agent-card .agent {
    width: 32px; height: 32px;
    font-size: 11px;
    flex-shrink: 0;
  }
  .agent-card .agent svg { width: 16px; height: 16px; }
  .agent-card-name {
    font-size: 14px;
    margin-top: 0;
    letter-spacing: -0.01em;
  }
  /* Role copy is desktop-only — hide on small phones */
  .agent-card-role { display: none; }
}

/* hp-foot stacks question + link on mobile so it never crashes into one wide line */
@media (max-width: 540px) {
  .hp-foot {
    line-height: 1.6;
  }
  .hp-foot a {
    display: block;
    margin-top: 6px;
  }
}

/* ───────────────────────────────────────────────────────────────
   ADAPTIVE: mobile-distinct feature blocks (replace dense mock cards)
   ─────────────────────────────────────────────────────────────── */
.feature-mock-mobile { display: none; }

@media (max-width: 768px) {
  /* Hide dense desktop mock card on mobile, show big-stat hero instead */
  .feature .feature-mock { display: none; }
  .feature-mock-mobile {
    display: flex;
    flex-direction: column;
    gap: 16px;
    background: white;
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    padding: 28px 24px;
    box-shadow: var(--shadow-md);
    text-align: center;
    align-items: center;
    position: relative;
    overflow: hidden;
  }
  .fmm-stat {
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
  }
  .fmm-stat b {
    font-family: var(--display);
    font-size: 64px;
    font-weight: 800;
    color: var(--ink);
    letter-spacing: -0.04em;
    line-height: 1;
    font-variant-numeric: tabular-nums;
  }
  .fmm-stat b small {
    font-size: 22px;
    color: var(--muted);
    font-weight: 600;
    margin-left: 2px;
  }
  .fmm-stat span {
    font-size: 14px;
    color: var(--ink-3);
    line-height: 1.4;
    max-width: 28ch;
  }
  .fmm-stat.gold b { color: var(--gold); }
  .fmm-stat.green b { color: var(--ink); }

  /* Team: big 8 + 8 avatars in a tight cluster */
  .fmm-team .fmm-row {
    display: inline-flex;
    align-items: center;
  }
  .fmm-team .fmm-row .agent {
    width: 30px; height: 30px;
    font-size: 10px;
    margin-right: -5px;
    border: 2px solid white;
  }

  /* Live tag with pulsing dot */
  .fmm-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 999px;
    background: var(--green-soft);
    color: #1f5d3e;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.02em;
  }
  .fmm-tag i {
    width: 7px; height: 7px;
    background: var(--green);
    border-radius: 50%;
    position: relative;
  }
  .fmm-tag.pulse i::after {
    content: "";
    position: absolute; inset: -3px;
    border-radius: 50%;
    background: var(--green);
    opacity: .35;
    animation: ring-pulse 2s ease-out infinite;
  }
  .fmm-line {
    margin: 0;
    font-size: 13px;
    color: var(--ink-3);
    background: var(--bg-soft);
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid var(--line);
  }
  .fmm-line b { color: var(--ink); font-weight: 700; }
  .fmm-line em { font-family: var(--mono); font-style: normal; color: var(--muted); }

  /* Memory: chip cluster */
  .fmm-mem .fmm-stat b { color: var(--gold); }
  .fmm-chips {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
  }
  .fmm-chip {
    font-size: 12px;
    color: var(--ink-2);
    background: var(--gold-muted);
    padding: 5px 10px;
    border-radius: 999px;
    font-weight: 600;
  }

  /* Budget: big number + bar */
  .fmm-budget .fmm-bar {
    width: 80%;
    max-width: 240px;
    height: 10px;
    background: var(--bg-mute);
    border-radius: 999px;
    overflow: hidden;
    position: relative;
  }
  .fmm-budget .fmm-bar i {
    display: block;
    height: 100%;
    background: var(--green);
    border-radius: 999px;
  }
}
