/* AGENT-FIRST PRODUCT HOME
   Three full-viewport scenes: Lens workspace, live intelligence, evidence routes. */

.hub-shell:has(.home-product) {
  width: 100%;
  max-width: none;
  padding: 0;
  overflow: clip;
}

body:has(.home-product) { background: var(--bg-page); }

.home-product {
  --home-max: 1512px;
  --home-pad: clamp(22px, 3.4vw, 58px);
  --home-line: color-mix(in srgb, var(--border2) 76%, transparent);
  --home-line-strong: color-mix(in srgb, var(--text-lo) 34%, var(--border2));
  --home-soft: color-mix(in srgb, var(--bg-card2) 76%, var(--bg-page));
  --home-accent-soft: color-mix(in srgb, var(--accent) 8%, var(--bg-page));
  color: var(--text-md);
  background: var(--bg-page);
}

.home-product *,
.home-product *::before,
.home-product *::after { box-sizing: border-box; }
.home-product button,
.home-product textarea { color: inherit; font: inherit; }
.home-product :is(h1, h2, h3) { text-wrap: balance; }
.home-product button,
.home-product a {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
.home-product svg { width: 15px; height: 15px; flex: none; }

.home-screen {
  min-height: 100svh;
  position: relative;
  display: grid;
  padding: 0 var(--home-pad);
  border-bottom: 1px solid var(--home-line-strong);
  overflow: hidden;
  scroll-snap-align: start;
  scroll-snap-stop: normal;
}

.home-screen > * {
  width: min(100%, var(--home-max));
  margin-inline: auto;
}

.home-screen-bar {
  min-height: 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid var(--home-line);
}

.home-live-mark,
.home-live-mark > span,
.home-screen-links,
.home-screen-links a,
.home-agent-shelf > header > div:last-child,
.home-agent-shelf > header a,
.home-feed-lane > header,
.home-feed-lane > header > div,
.home-feed-lane > header a,
.home-products-footer,
.home-products-footer button { display: flex; align-items: center; }

.home-live-mark { gap: 8px; }
.home-live-mark > i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--green) 11%, transparent);
  animation: home-live-pulse 2.4s ease-in-out infinite;
}
.home-live-mark > span {
  gap: 7px;
  color: var(--text-hi);
  font: 730 8px/1 var(--mono);
  letter-spacing: .1em;
}
.home-live-mark > b {
  color: var(--text-lo);
  font: 590 7.5px/1 var(--mono);
  letter-spacing: .04em;
}

.home-screen-links { gap: 18px; }
.home-screen-links a,
.home-agent-shelf > header a,
.home-feed-lane > header a {
  min-height: 34px;
  gap: 7px;
  color: var(--text-md);
  font-size: 9.5px;
  font-weight: 650;
  text-decoration: none;
  transition: color .16s ease;
}
.home-screen-links a:hover,
.home-agent-shelf > header a:hover,
.home-feed-lane > header a:hover { color: var(--text-hi); }

/* Scene 1: the working prompt is the visual anchor. */
.home-ai-screen {
  grid-template-rows: minmax(390px, 1fr) auto;
  background:
    radial-gradient(circle at 50% 32%, color-mix(in srgb, var(--accent) 8%, transparent), transparent 29%),
    var(--bg-page);
}

.home-agent-stage {
  align-self: center;
  display: grid;
  justify-items: center;
  gap: 19px;
  padding: 28px 0 24px;
}

.home-agent-intro {
  display: flex;
  align-items: center;
  gap: 19px;
  max-width: 850px;
}
.home-lens-mark {
  width: 80px;
  height: 84px;
  display: grid;
  place-items: center;
  position: relative;
  flex: none;
}
.home-lens-mark::after {
  width: 58px;
  height: 10px;
  position: absolute;
  bottom: 2px;
  content: "";
  border-radius: 50%;
  background: color-mix(in srgb, var(--accent) 25%, transparent);
  filter: blur(8px);
}
.home-lens-mark img { width: 76px; height: 82px; position: relative; z-index: 1; object-fit: contain; }
.home-agent-intro p,
.home-agent-shelf > header p,
.home-screen-heading > p {
  margin: 0;
  color: var(--accent-2);
  font: 730 8px/1 var(--mono);
  letter-spacing: .12em;
}
.home-agent-intro h1 {
  margin: 6px 0 2px;
  color: var(--text-hi);
  font-size: clamp(35px, 4vw, 58px);
  font-weight: 710;
  line-height: .98;
  letter-spacing: -.065em;
}
.home-agent-intro strong {
  display: block;
  margin-top: 9px;
  color: var(--text-hi);
  font-size: 13px;
  font-weight: 690;
}
.home-agent-intro > div:last-child > span {
  display: block;
  max-width: 690px;
  margin-top: 5px;
  color: var(--text-md);
  font-size: 10.5px;
  line-height: 1.45;
}

.home-composer {
  width: min(780px, 100%);
  position: relative;
  overflow: hidden;
  border: 1px solid var(--home-line-strong);
  border-radius: 19px;
  background: color-mix(in srgb, var(--bg-card) 96%, transparent);
  box-shadow: 0 22px 70px -48px rgba(0,0,0,.72), inset 0 1px 0 var(--hairline);
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.home-composer:focus-within {
  border-color: color-mix(in srgb, var(--accent) 56%, var(--home-line-strong));
  box-shadow: 0 26px 80px -45px color-mix(in srgb, var(--accent) 38%, transparent), inset 0 1px 0 var(--hairline);
  transform: translateY(-2px);
}
.home-composer > header {
  min-height: 52px;
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 12px;
  border-bottom: 1px solid var(--home-line);
}
.home-active-agent-avatar {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  flex: none;
  border-radius: 12px;
  overflow: hidden;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
}
.home-active-agent-avatar img { width: 38px; height: 42px; object-fit: contain; }
.home-composer > header > div:nth-child(2) { min-width: 0; }
.home-composer > header small {
  display: block;
  color: var(--text-lo);
  font: 650 6.5px/1 var(--mono);
  letter-spacing: .09em;
}
.home-composer > header b {
  display: block;
  overflow: hidden;
  margin-top: 5px;
  color: var(--text-hi);
  font-size: 10.5px;
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.home-composer > header > :is(a, .home-agent-switch) {
  margin-left: auto;
  padding: 8px;
  border: 0;
  color: var(--text-lo);
  background: transparent;
  font-size: 8.5px;
  font-weight: 620;
  text-decoration: none;
  cursor: pointer;
}
.home-composer > header > :is(a, .home-agent-switch):hover { color: var(--accent-2); }
.home-composer:has(.cp-agent-menu) { overflow: visible; }
.home-composer > header .cp-agent-menu {
  top: calc(100% + 8px);
  right: 8px;
  left: auto;
  width: min(560px, calc(100% - 16px));
  max-height: min(430px, 62vh);
}
.home-composer textarea {
  width: 100%;
  min-height: 78px;
  display: block;
  resize: none;
  padding: 15px 18px 9px;
  border: 0;
  outline: 0;
  color: var(--text-hi);
  background: transparent;
  font-size: 14px;
  line-height: 1.5;
}
.home-composer textarea::placeholder { color: var(--text-lo); opacity: .82; }
.home-composer > footer {
  min-height: 47px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 7px 10px 9px 17px;
}
.home-composer-sources { display: flex; align-items: center; gap: 13px; overflow: hidden; }
.home-composer-sources span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--text-lo);
  font: 650 6.5px/1 var(--mono);
  letter-spacing: .06em;
  white-space: nowrap;
}
.home-composer-sources i { width: 4px; height: 4px; border-radius: 50%; background: var(--green); }
.home-composer > footer > button {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  flex: none;
  border: 0;
  border-radius: 12px;
  color: #fff;
  background: var(--accent);
  cursor: pointer;
  transition: transform .16s ease, background .16s ease;
}
.home-composer > footer > button:hover { background: color-mix(in srgb, var(--accent) 86%, #fff); transform: scale(1.04); }
.home-composer > footer > button svg { width: 18px; height: 18px; }

.home-agent-examples {
  width: min(1040px, 100%);
  display: grid;
  grid-template-columns: minmax(0, .92fr) minmax(380px, 1.08fr);
  align-items: stretch;
  gap: 9px;
}
.home-prompt-row {
  display: grid;
  align-content: center;
  justify-items: start;
  gap: 9px;
  min-width: 0;
}
.home-prompt-row > small { color: var(--text-lo); font: 650 6.5px/1 var(--mono); letter-spacing: .1em; }
.home-prompt-row > div { display: flex; justify-content: start; gap: 7px; width: 100%; overflow-x: auto; scrollbar-width: none; }
.home-prompt-row > div::-webkit-scrollbar { display: none; }
.home-prompt-row button {
  min-height: 31px;
  padding: 0 11px;
  border: 1px solid var(--home-line);
  border-radius: 999px;
  color: var(--text-md);
  background: color-mix(in srgb, var(--bg-card) 68%, transparent);
  font-size: 8px;
  line-height: 1.2;
  white-space: nowrap;
  cursor: pointer;
  transition: color .16s ease, border-color .16s ease, background .16s ease;
}
.home-prompt-row button:hover { color: var(--text-hi); border-color: var(--home-line-strong); background: var(--bg-card); }

.home-answer-preview {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(140px, .82fr) minmax(0, 1.18fr);
  gap: 13px;
  padding: 12px 14px;
  border: 1px solid var(--home-line);
  border-radius: 13px;
  color: inherit;
  background: color-mix(in srgb, var(--bg-card) 78%, transparent);
  text-align: left;
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease, transform .16s ease;
}
.home-answer-preview:hover { border-color: color-mix(in srgb, var(--accent) 42%, var(--home-line)); background: var(--bg-card); transform: translateY(-2px); }
.home-answer-preview > span { min-width: 0; }
.home-answer-preview small { display: block; color: var(--accent-2); font: 720 6.5px/1 var(--mono); letter-spacing: .1em; }
.home-answer-preview b { display: block; margin-top: 7px; color: var(--text-hi); font-size: 9px; line-height: 1.3; }
.home-answer-preview strong { display: block; color: var(--text-md); font-size: 8px; font-weight: 540; line-height: 1.4; }
.home-answer-preview em { display: flex; align-items: center; gap: 5px; margin-top: 8px; color: var(--text-hi); font-size: 7.5px; font-style: normal; font-weight: 670; }
.home-answer-preview em svg { width: 10px; height: 10px; }

.home-agent-shelf {
  align-self: end;
  padding: 17px 0 20px;
  border-top: 1px solid var(--home-line);
}
.home-agent-shelf > header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 12px;
}
.home-agent-shelf > header h2 {
  display: inline;
  margin: 0 11px 0 0;
  color: var(--text-hi);
  font-size: 15px;
  font-weight: 690;
  letter-spacing: -.025em;
}
.home-agent-shelf > header > div:first-child > span { color: var(--text-lo); font-size: 8.5px; }
.home-agent-shelf > header > div:last-child { gap: 17px; }
.home-agent-list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.home-agent-card {
  min-width: 0;
  min-height: 128px;
  position: relative;
  display: grid;
  grid-template-rows: auto auto auto 1fr auto;
  padding: 12px 13px 10px;
  overflow: hidden;
  border: 1px solid var(--home-line);
  border-radius: 12px;
  color: inherit;
  background: color-mix(in srgb, var(--bg-card) 88%, transparent);
  text-decoration: none;
  transition: border-color .18s ease, transform .18s ease, background .18s ease;
}
.home-agent-card::before {
  width: 54px;
  height: 54px;
  position: absolute;
  top: -26px;
  right: -18px;
  content: "";
  border-radius: 50%;
  background: var(--agent-gradient);
  opacity: .22;
  filter: blur(14px);
}
.home-agent-card:hover,
.home-agent-card:focus-visible { border-color: color-mix(in srgb, var(--accent) 46%, var(--home-line)); background: var(--bg-card); transform: translateY(-3px); }
.home-agent-card > header { display: flex; align-items: center; gap: 8px; }
.home-agent-rank { color: var(--text-lo); font: 700 7px/1 var(--mono); }
.home-agent-avatar {
  width: 25px;
  height: 25px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: var(--agent-gradient);
  font-size: 8px;
  font-weight: 800;
}
.home-agent-card > header small { margin-left: auto; color: var(--text-lo); font: 650 6px/1 var(--mono); letter-spacing: .06em; }
.home-agent-card h3 { margin: 8px 0 4px; color: var(--text-hi); font-size: 12px; line-height: 1; }
.home-agent-card > p { margin: 0; color: var(--text-md); font-size: 8px; line-height: 1.35; }
.home-agent-tags { display: flex; align-items: end; gap: 5px; padding: 7px 0; overflow: hidden; }
.home-agent-tags span { color: var(--text-lo); font: 620 6.5px/1 var(--mono); white-space: nowrap; }
.home-agent-tags span + span::before { content: "/"; margin-right: 5px; color: var(--home-line-strong); }
.home-agent-card > footer { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-top: 8px; border-top: 1px solid var(--home-line); }
.home-agent-card > footer span { color: var(--text-lo); font-size: 7px; }
.home-agent-card > footer b { display: inline-flex; align-items: center; gap: 5px; color: var(--text-hi); font-size: 7.5px; }
.home-agent-card > footer svg { width: 10px; height: 10px; }

.home-inline-error { grid-column: 1 / -1; margin: 0; padding: 24px; color: var(--text-lo); font-size: 10px; text-align: center; }
.home-agent-card.is-skeleton { pointer-events: none; }
.home-agent-card.is-skeleton > * { display: block; border-radius: 4px; background: var(--home-soft); animation: home-shimmer 1.4s ease-in-out infinite; }
.home-agent-card.is-skeleton i { width: 26px; height: 26px; }
.home-agent-card.is-skeleton span { width: 62%; height: 10px; margin-top: 14px; }
.home-agent-card.is-skeleton b { width: 84%; height: 7px; margin-top: 9px; }

/* Shared scene headings stay editorial and calm. */
.home-feed-screen,
.home-products-screen { align-content: center; gap: clamp(30px, 5vh, 56px); padding-top: 48px; padding-bottom: 48px; }
.home-feed-screen {
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--bg-card) 72%, var(--bg-page)), var(--bg-page)),
    var(--bg-page);
}
.home-screen-heading { text-align: center; }
.home-screen-heading h2 {
  margin: 9px 0 10px;
  color: var(--text-hi);
  font-size: clamp(35px, 4vw, 58px);
  font-weight: 710;
  line-height: 1;
  letter-spacing: -.06em;
}
.home-screen-heading > span {
  display: block;
  max-width: 680px;
  margin-inline: auto;
  color: var(--text-md);
  font-size: 10.5px;
  line-height: 1.55;
}

.home-feed-lanes { display: grid; gap: clamp(24px, 4vh, 42px); }
.home-feed-lane { min-width: 0; }
.home-feed-lane > header { justify-content: space-between; gap: 24px; margin-bottom: 12px; }
.home-feed-lane > header > div { min-width: 0; gap: 10px; }
.home-feed-lane > header > div > i { width: 6px; height: 6px; flex: none; border-radius: 50%; background: var(--green); }
.home-feed-lane:nth-child(2) > header > div > i { background: var(--accent-2); }
.home-feed-lane h3 { margin: 0; color: var(--text-hi); font-size: 14px; }
.home-feed-lane > header span { color: var(--text-lo); font-size: 8.5px; }
.home-feed-track {
  min-height: 198px;
  position: relative;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 3%, #000 97%, transparent);
}
.home-feed-track::before,
.home-feed-track::after {
  width: 58px;
  position: absolute;
  inset-block: 0;
  z-index: 3;
  content: "";
  pointer-events: none;
}
.home-feed-track::before { left: 0; background: linear-gradient(90deg, var(--bg-page), transparent); }
.home-feed-track::after { right: 0; background: linear-gradient(270deg, var(--bg-page), transparent); }
.home-feed-marquee { width: max-content; display: flex; animation: home-feed-scroll 54s linear infinite; }
.home-feed-lane:nth-child(2) .home-feed-marquee { animation-duration: 62s; animation-direction: reverse; }
.home-feed-track:hover .home-feed-marquee,
.home-feed-track:focus-within .home-feed-marquee { animation-play-state: paused; }
.home-feed-set { display: flex; gap: 11px; padding-right: 11px; }
.home-feed-track .evt-card {
  width: clamp(300px, 27vw, 390px);
  height: 198px;
  flex: none;
  overflow: hidden;
  border-color: var(--home-line);
  border-radius: 13px;
  background: color-mix(in srgb, var(--bg-card) 92%, transparent);
  box-shadow: none;
}
.home-feed-track .evt-card:hover { transform: translateY(-2px); }
.home-feed-track .evt-summary { -webkit-line-clamp: 2; }
.home-feed-track .evt-chips { max-height: 25px; }
.home-feed-track .evt-card-actions { margin-top: 5px; }
.home-feed-skeleton { display: grid; grid-template-columns: repeat(3, minmax(280px, 1fr)); gap: 11px; }
.home-feed-skeleton i { height: 198px; border: 1px solid var(--home-line); border-radius: 13px; background: var(--home-soft); animation: home-shimmer 1.4s ease-in-out infinite; }
.home-feed-empty { min-height: 198px; display: grid; place-items: center; margin: 0; color: var(--text-lo); font-size: 10px; }

/* Scene 3: one dominant live fact and four compact paths. */
.home-products-screen {
  background:
    radial-gradient(circle at 25% 55%, color-mix(in srgb, var(--accent) 7%, transparent), transparent 30%),
    var(--bg-page);
}
.home-product-grid {
  min-height: min(520px, 58vh);
  display: grid;
  grid-template-columns: 1.35fr 1fr 1fr;
  grid-template-rows: repeat(2, minmax(190px, 1fr));
  gap: 12px;
}
.home-product-card {
  min-width: 0;
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-rows: auto 1fr;
  gap: 13px 14px;
  padding: clamp(18px, 2.1vw, 30px);
  overflow: hidden;
  border: 1px solid var(--home-line);
  border-radius: 18px;
  color: inherit;
  background: color-mix(in srgb, var(--bg-card) 90%, transparent);
  text-decoration: none;
  transition: border-color .2s ease, transform .2s ease, background .2s ease;
}
.home-product-card:hover { border-color: color-mix(in srgb, var(--accent) 47%, var(--home-line)); background: var(--bg-card); transform: translateY(-3px); }
.home-product-card.is-wide { grid-row: 1 / 3; }
.home-product-icon {
  width: 39px;
  height: 39px;
  display: grid;
  place-items: center;
  border: 1px solid var(--home-line);
  border-radius: 12px;
  color: var(--accent-2);
  background: var(--home-accent-soft);
}
.home-product-icon svg { width: 19px; height: 19px; }
.home-product-card > div { min-width: 0; }
.home-product-card small { color: var(--text-lo); font: 650 6.5px/1 var(--mono); letter-spacing: .09em; text-transform: uppercase; }
.home-product-card h3 { margin: 6px 0 5px; color: var(--text-hi); font-size: 17px; line-height: 1; letter-spacing: -.035em; }
.home-product-card p { margin: 0; color: var(--text-lo); font-size: 8.5px; line-height: 1.4; }
.home-product-card > strong {
  grid-column: 1 / -1;
  align-self: end;
  max-width: 93%;
  color: var(--text-hi);
  font-size: clamp(18px, 1.8vw, 27px);
  font-weight: 710;
  line-height: 1.08;
  letter-spacing: -.045em;
}
.home-product-card.is-wide > strong { font-size: clamp(31px, 3.7vw, 57px); line-height: .98; }
.home-product-card > strong.is-positive { color: var(--green); }
.home-product-card > strong.is-negative { color: var(--red); }
.home-product-go { align-self: start; color: var(--text-lo); transition: color .16s ease, transform .16s ease; }
.home-product-card:hover .home-product-go { color: var(--text-hi); transform: translateX(3px); }
.home-products-footer { justify-content: space-between; border-top: 1px solid var(--home-line); padding-top: 14px; }
.home-products-footer button {
  min-height: 41px;
  gap: 9px;
  padding: 0 13px 0 8px;
  border: 1px solid color-mix(in srgb, var(--accent) 45%, var(--home-line));
  border-radius: 12px;
  color: var(--text-hi);
  background: var(--home-accent-soft);
  font-size: 9.5px;
  font-weight: 660;
  cursor: pointer;
}
.home-products-footer button img { width: 28px; height: 30px; object-fit: contain; }

@keyframes home-live-pulse { 50% { opacity: .45; transform: scale(.78); } }
@keyframes home-shimmer { 50% { opacity: .42; } }
@keyframes home-feed-scroll { to { transform: translateX(-50%); } }

@media (prefers-reduced-motion: reduce) {
  .home-feed-marquee,
  .home-live-mark > i,
  .home-agent-card.is-skeleton > * { animation: none; }
}

@media (min-width: 861px) {
  body:has(.home-product) { scroll-snap-type: y proximity; }
  html.nav-rail-collapsed .home-product { --home-pad: clamp(28px, 4.2vw, 72px); }
}

@media (max-width: 1180px) {
  .home-agent-intro h1,
  .home-screen-heading h2 { font-size: 43px; }
  .home-product-grid { grid-template-columns: 1.16fr 1fr 1fr; }
  .home-product-card { padding: 17px; }
  .home-product-card.is-wide { grid-row: 1 / 3; }
}

@media (max-height: 820px) and (min-width: 861px) {
  .home-ai-screen { grid-template-rows: minmax(330px, 1fr) auto; }
  .home-agent-stage { gap: 12px; padding: 15px 0 12px; }
  .home-agent-intro h1 { font-size: 38px; }
  .home-lens-mark { width: 62px; height: 64px; }
  .home-lens-mark img { width: 60px; height: 65px; }
  .home-composer textarea { min-height: 60px; }
  .home-prompt-row button { min-height: 28px; }
  .home-answer-preview { padding-block: 9px; }
  .home-agent-shelf { padding: 11px 0 13px; }
  .home-agent-card { min-height: 111px; }
  .home-feed-screen,
  .home-products-screen { gap: 24px; padding-top: 34px; padding-bottom: 34px; }
  .home-feed-track,
  .home-feed-track .evt-card,
  .home-feed-skeleton i { height: 174px; min-height: 174px; }
  .home-product-grid { min-height: min(460px, 58vh); }
}

@media (max-width: 860px) {
  .home-product { --home-pad: 14px; }
  .home-screen { min-height: 0; display: block; padding-top: 0; padding-bottom: 54px; overflow: hidden; }
  .home-screen-links a:first-child { display: none; }
  .home-screen-links { gap: 9px; }
  .home-screen-links a { font-size: 8.5px; }
  .home-live-mark > b { display: none; }
  .home-agent-stage { min-height: 100svh; align-content: center; gap: 17px; padding: 27px 0 32px; }
  .home-agent-intro { width: 100%; gap: 12px; }
  .home-lens-mark { width: 65px; height: 68px; }
  .home-lens-mark img { width: 63px; height: 69px; }
  .home-agent-intro h1 { font-size: 37px; }
  .home-agent-intro strong { font-size: 11px; }
  .home-agent-intro > div:last-child > span { font-size: 9.5px; }
  .home-composer { border-radius: 16px; }
  .home-composer textarea { min-height: 92px; padding-inline: 14px; font-size: 16px; }
  .home-composer > header { padding-inline: 9px; }
  .home-composer-sources { max-width: calc(100vw - 100px); overflow-x: auto; scrollbar-width: none; }
  .home-composer-sources::-webkit-scrollbar { display: none; }
  .home-prompt-row { justify-items: start; }
  .home-prompt-row > div { width: 100%; justify-content: start; padding-bottom: 3px; }
  .home-prompt-row button { min-height: 35px; font-size: 8.5px; }
  .home-agent-shelf { padding-top: 34px; }
  .home-agent-shelf > header { align-items: start; flex-direction: column; gap: 11px; }
  .home-agent-shelf > header h2 { display: block; margin: 7px 0 5px; font-size: 22px; }
  .home-agent-shelf > header > div:first-child > span { display: block; font-size: 9.5px; line-height: 1.4; }
  .home-agent-list { display: flex; gap: 9px; margin-right: calc(var(--home-pad) * -1); padding-right: var(--home-pad); overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
  .home-agent-list::-webkit-scrollbar { display: none; }
  .home-agent-card { min-width: min(78vw, 300px); min-height: 146px; scroll-snap-align: start; }
  .home-agent-card h3 { font-size: 14px; }
  .home-agent-card > p { font-size: 9px; }
  .home-agent-examples { grid-template-columns: 1fr; }
  .home-answer-preview { grid-template-columns: 1fr; }
  .home-feed-screen,
  .home-products-screen { padding-top: 70px; }
  .home-screen-heading { text-align: left; }
  .home-screen-heading h2 { font-size: 38px; }
  .home-screen-heading > span { margin: 0; font-size: 10px; }
  .home-feed-lanes { margin-top: 38px; gap: 38px; }
  .home-feed-lane > header { align-items: start; }
  .home-feed-lane > header > div { display: grid; grid-template-columns: auto auto; }
  .home-feed-lane > header span { grid-column: 2; }
  .home-feed-lane > header a { min-width: 34px; justify-content: end; overflow: hidden; font-size: 0; }
  .home-feed-track { margin-inline: calc(var(--home-pad) * -1); mask-image: none; }
  .home-feed-track::before,
  .home-feed-track::after { display: none; }
  .home-feed-track .evt-card { width: min(84vw, 340px); }
  .home-feed-marquee { animation-duration: 64s; }
  .home-product-grid { min-height: 0; display: grid; grid-template-columns: 1fr; grid-template-rows: none; gap: 9px; margin-top: 38px; }
  .home-product-card,
  .home-product-card.is-wide { min-height: 155px; display: grid; grid-row: auto; padding: 17px; border-radius: 14px; }
  .home-product-card:nth-child(4),
  .home-product-card:nth-child(5) { display: grid; }
  .home-product-card > strong,
  .home-product-card.is-wide > strong { font-size: 22px; }
  .home-products-footer { margin-top: 32px; }
  .home-products-footer .home-live-mark { display: none; }
  .home-products-footer button { width: 100%; justify-content: center; min-height: 48px; }
}

@media (max-width: 520px) {
  .home-lens-mark { width: 52px; height: 58px; }
  .home-lens-mark img { width: 55px; height: 60px; }
  .home-agent-intro h1 { font-size: 33px; }
  .home-agent-intro > div:last-child > span { display: none; }
  .home-answer-preview { display: none; }
  .home-composer > header > :is(a, .home-agent-switch) { max-width: 112px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .home-agent-shelf > header > div:last-child a:first-child { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .home-product *,
  .home-product *::before,
  .home-product *::after { animation: none !important; scroll-behavior: auto !important; transition: none !important; }
  .home-feed-marquee { transform: none; }
  .home-feed-track { overflow-x: auto; scrollbar-width: thin; }
  .home-feed-set[aria-hidden="true"] { display: none; }
}

/* Functional workspace refinement: the working surface, not a landing hero. */
.home-ai-screen { grid-template-rows: minmax(560px, 1fr) auto; background: var(--bg-page); }
.home-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.home-agent-stage {
  align-self: stretch;
  align-content: center;
  justify-items: stretch;
  gap: 16px;
  padding: 20px 0 18px;
}
.home-capability-zone { width: 100%; }

.home-composer { width: 100%; border-radius: 16px; }
.home-composer textarea { min-height: 108px; padding: 20px 22px 12px; font-size: 17px; }
.home-composer > header { min-height: 49px; }
.home-composer > footer { min-height: 45px; }

.home-embedded-chat {
  width: 100%;
  height: clamp(390px, calc(100svh - 330px), 560px);
  min-height: 0;
}
.home-embedded-chat[hidden] { display: none; }
.home-ai-screen.is-chatting .home-agent-stage {
  align-content: center;
  padding-block: 18px;
}
.home-ai-screen.is-chatting :is(.home-composer, .home-capability-zone) { display: none; }
.home-embedded-chat .cp-panel.cp-docked {
  position: static !important;
  inset: auto !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  max-height: none !important;
  overflow: hidden;
  border: 1px solid var(--home-line-strong);
  border-radius: 16px;
  background: var(--bg-card);
  box-shadow: 0 28px 76px -52px color-mix(in srgb, var(--accent) 55%, transparent);
  animation: none !important;
}
.home-embedded-chat .cp-head { cursor: default !important; }
.home-embedded-chat :is(.cp-grip, .cp-min, .cp-resize) { display: none !important; }
.home-embedded-chat .cp-close { display: flex !important; }

.home-capability-zone > header {
  min-height: 52px;
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}
.home-capability-zone > header > div {
  width: 100%;
  display: grid;
  grid-template-columns: auto minmax(180px, 1fr) auto;
  align-items: center;
  gap: 18px;
}
.home-capability-zone > header > div small { display: block; color: var(--text-hi); font-size: 14px; font-weight: 740; letter-spacing: -.02em; }
.home-capability-zone > header > div span { display: block; color: var(--text-lo); font-size: 9px; }
.home-capability-zone > header > div a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 0;
  color: var(--accent-2);
  font-size: 8.5px;
  font-weight: 690;
  text-decoration: none;
}
.home-capability-zone > header > div a:hover { color: var(--text-hi); }
.home-capability-zone > header > div a svg { width: 11px; height: 11px; }
.home-answer-preview {
  min-height: 68px;
  display: grid;
  grid-template-columns: 105px minmax(150px, .75fr) minmax(230px, 1.25fr) auto;
  align-items: center;
  gap: 13px;
  padding: 10px 14px;
  border: 1px solid var(--home-line);
  border-radius: 12px;
  background: color-mix(in srgb, var(--bg-card) 76%, transparent);
}
.home-answer-preview small { margin: 0; }
.home-answer-preview b { margin: 0; font-size: 10.5px; }
.home-answer-preview > span { color: var(--text-md); font-size: 9px; line-height: 1.4; }
.home-answer-preview em { margin: 0; white-space: nowrap; }

.home-capability-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid var(--home-line-strong);
  border-radius: 14px;
  background: color-mix(in srgb, var(--bg-card) 64%, transparent);
}
.home-capability-grid button {
  min-width: 0;
  min-height: 92px;
  display: grid;
  grid-template-columns: 31px minmax(0, 1fr) 13px;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 0;
  border-right: 1px solid var(--home-line);
  border-bottom: 1px solid var(--home-line);
  color: inherit;
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: background .16s ease, color .16s ease, box-shadow .16s ease;
}
.home-capability-grid button:nth-child(4n) { border-right: 0; }
.home-capability-grid button:nth-child(n + 5) { border-bottom: 0; }
.home-capability-grid button:not(:disabled):hover {
  color: var(--text-hi);
  background: color-mix(in srgb, var(--accent) 7%, var(--bg-card));
  box-shadow: inset 0 2px 0 color-mix(in srgb, var(--accent-2) 72%, transparent);
}
.home-capability-grid button > span:first-child {
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  color: var(--accent-2);
  background: var(--home-accent-soft);
}
.home-capability-grid button > span:first-child svg { width: 15px; height: 15px; }
.home-capability-grid button > span:nth-child(2) { min-width: 0; }
.home-capability-grid button small { display: block; color: var(--accent-2); font: 700 6.5px/1 var(--mono); letter-spacing: .08em; }
.home-capability-grid button b { display: block; margin-top: 6px; overflow: hidden; color: var(--text-hi); font-size: 12.5px; line-height: 1.15; text-overflow: ellipsis; white-space: nowrap; }
.home-capability-grid button em { display: block; margin-top: 5px; overflow: hidden; color: var(--text-lo); font-size: 8.7px; line-height: 1.25; font-style: normal; text-overflow: ellipsis; white-space: nowrap; }
.home-capability-grid button > svg { width: 11px; height: 11px; color: var(--text-lo); }
.home-capability-grid button:not(:disabled):hover > svg { color: var(--accent-2); transform: translateX(2px); }
.home-capability-grid button:disabled {
  color: var(--text-lo);
  background: color-mix(in srgb, var(--bg-card2) 74%, transparent);
  cursor: not-allowed;
}
.home-capability-grid button:disabled > span:first-child {
  color: var(--text-lo);
  background: color-mix(in srgb, var(--bg-card2) 88%, var(--bg-page));
}
.home-capability-soon {
  min-width: 38px;
  padding: 5px 6px;
  border: 1px solid var(--home-line-strong);
  border-radius: 999px;
  color: var(--text-lo);
  font: 720 6.5px/1 var(--mono);
  letter-spacing: .08em;
  text-align: center;
}

/* Evidence index: one analytical instrument and four contiguous routes. */
.home-products-screen { align-content: center; gap: 24px; padding-top: 42px; padding-bottom: 42px; }
.home-products-screen .home-screen-heading { display: flex; align-items: end; justify-content: space-between; gap: 36px; text-align: left; }
.home-products-screen .home-screen-heading h2 { margin: 6px 0 0; font-size: clamp(25px, 2.5vw, 36px); letter-spacing: -.045em; }
.home-products-screen .home-screen-heading > span { max-width: none; margin: 0 0 4px auto; font: 650 8px/1.4 var(--mono); letter-spacing: .04em; }
.home-evidence-index {
  min-height: min(520px, 61vh);
  display: grid;
  grid-template-columns: minmax(350px, .88fr) minmax(570px, 1.42fr);
  overflow: hidden;
  border: 1px solid var(--home-line-strong);
  border-radius: 18px;
  background: color-mix(in srgb, var(--bg-card) 82%, transparent);
}
.home-evidence-primary {
  min-width: 0;
  display: grid;
  grid-template-rows: auto auto auto 1fr auto;
  gap: 20px;
  padding: 27px 29px 22px;
  border-right: 1px solid var(--home-line-strong);
  color: inherit;
  background: radial-gradient(circle at 14% 88%, color-mix(in srgb, var(--accent) 9%, transparent), transparent 36%);
  text-decoration: none;
}
.home-evidence-primary > header { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 13px; align-items: start; }
.home-evidence-primary small,
.home-evidence-label small,
.home-asset-pressure > small { color: var(--text-lo); font: 650 6.5px/1 var(--mono); letter-spacing: .09em; }
.home-evidence-primary h3,
.home-evidence-label h3 { margin: 5px 0 3px; color: var(--text-hi); font-size: 15px; line-height: 1; }
.home-evidence-primary p,
.home-evidence-label p { margin: 0; color: var(--text-lo); font-size: 8px; line-height: 1.35; }
.home-evidence-primary > strong { align-self: end; color: var(--text-hi); font-size: clamp(30px, 3vw, 46px); font-weight: 720; line-height: .98; letter-spacing: -.055em; }
.home-evidence-primary > strong.is-positive,
.home-evidence-reading > strong.is-positive { color: var(--green); }
.home-evidence-primary > strong.is-negative,
.home-evidence-reading > strong.is-negative { color: var(--red); }
.home-flow-compare { display: grid; grid-template-columns: minmax(80px, auto) minmax(120px, 1fr) minmax(80px, auto); align-items: center; gap: 12px; }
.home-flow-compare > div:last-child { text-align: right; }
.home-flow-compare span { display: block; color: var(--text-lo); font: 630 6px/1 var(--mono); letter-spacing: .06em; }
.home-flow-compare b { display: block; margin-top: 5px; color: var(--text-hi); font-size: 11px; }
.home-flow-compare > i { height: 7px; display: flex; overflow: hidden; border-radius: 999px; background: var(--home-soft); }
.home-flow-compare > i span { width: 50%; height: 100%; }
#home-flow-out-bar { background: var(--green); }
#home-flow-in-bar { background: var(--red); }
.home-asset-pressure { align-self: end; }
.home-asset-pressure > div { margin-top: 9px; border-top: 1px solid var(--home-line); }
.home-asset-pressure > div > i { height: 31px; display: block; border-bottom: 1px solid var(--home-line); background: var(--home-soft); animation: home-shimmer 1.4s ease-in-out infinite; }
.home-asset-row { min-height: 31px; display: grid; grid-template-columns: 42px minmax(80px, 1fr) auto; align-items: center; gap: 10px; border-bottom: 1px solid var(--home-line); }
.home-asset-row:last-child { border-bottom: 0; }
.home-asset-row b { color: var(--text-hi); font-size: 9px; }
.home-asset-row i { height: 3px; display: block; border-radius: 999px; background: var(--home-soft); }
.home-asset-row i span { height: 100%; display: block; border-radius: inherit; background: currentColor; }
.home-asset-row strong { color: var(--text-hi); font-size: 9px; }
.home-asset-row.is-positive { color: var(--green); }
.home-asset-row.is-negative { color: var(--red); }
.home-evidence-primary > footer { color: var(--text-lo); font: 630 7px/1.35 var(--mono); }

.home-evidence-list { min-width: 0; display: grid; grid-template-rows: repeat(4, minmax(0, 1fr)); }
.home-evidence-row {
  min-width: 0;
  display: grid;
  grid-template-columns: 42px minmax(130px, .65fr) minmax(220px, 1.35fr) 16px;
  align-items: center;
  gap: 14px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--home-line-strong);
  color: inherit;
  text-decoration: none;
  transition: background .16s ease;
}
.home-evidence-row:last-child { border-bottom: 0; }
.home-evidence-row:hover { background: var(--bg-card); }
.home-evidence-row .home-product-icon { width: 38px; height: 38px; }
.home-evidence-reading { min-width: 0; }
.home-evidence-reading > strong { display: block; color: var(--text-hi); font-size: clamp(17px, 1.55vw, 24px); font-weight: 710; line-height: 1.08; letter-spacing: -.035em; }
.home-evidence-reading > span { display: block; margin-top: 8px; overflow: hidden; color: var(--text-lo); font: 620 7.5px/1.35 var(--mono); text-overflow: ellipsis; white-space: nowrap; }
.home-evidence-row:hover .home-product-go { color: var(--text-hi); transform: translateX(3px); }

@media (max-width: 1180px) and (min-width: 861px) {
  .home-ai-screen { grid-template-rows: minmax(510px, 1fr) auto; }
  .home-workspace-id,
  .home-capability-zone,
  .home-composer { width: min(1040px, 100%); }
  .home-answer-preview { grid-template-columns: 90px minmax(130px, .8fr) minmax(180px, 1.2fr) auto; }
  .home-capability-grid button { padding-inline: 9px; }
  .home-capability-grid button em { display: none; }
  .home-evidence-index { grid-template-columns: minmax(320px, .82fr) minmax(520px, 1.48fr); }
  .home-evidence-row { grid-template-columns: 38px minmax(110px, .58fr) minmax(190px, 1.42fr) 14px; padding-inline: 15px; }
}

@media (max-height: 820px) and (min-width: 861px) {
  .home-ai-screen { grid-template-rows: minmax(455px, 1fr) auto; }
  .home-agent-stage { gap: 8px; padding-block: 10px; }
  .home-composer textarea { min-height: 68px; }
  .home-capability-zone > header,
  .home-answer-preview { min-height: 58px; }
  .home-capability-grid button { min-height: 68px; padding-block: 8px; }
  .home-agent-shelf { padding-block: 10px 12px; }
  .home-agent-card { min-height: 108px; }
  .home-evidence-index { min-height: min(450px, 60vh); }
  .home-evidence-primary { gap: 13px; padding-block: 21px 17px; }
  .home-evidence-row { padding-block: 11px; }
}

@media (max-width: 860px) {
  html.home-agent-workspace { --cp-bar-h: 0px !important; }
  html.home-agent-workspace .cp-launch,
  html.home-agent-workspace .cp-panel.cp-collapsed { display: none !important; }
  .home-agent-stage { min-height: 0; align-content: start; gap: 12px; padding: 24px 0 30px; }
  .home-ai-screen.is-chatting .home-agent-stage { padding-block: 18px 24px; }
  .home-embedded-chat { height: min(680px, 72svh); min-height: 440px; }
  .home-composer textarea { min-height: 105px; }
  .home-capability-zone > header > div { display: flex; align-items: flex-start; flex-direction: column; gap: 5px; }
  .home-capability-zone > header > div a { margin-top: 4px; }
  .home-answer-preview { grid-template-columns: minmax(95px, .75fr) minmax(0, 1.25fr) auto; }
  .home-answer-preview > span { display: none; }
  .home-capability-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-capability-grid button { min-height: 88px; border-right: 1px solid var(--home-line); border-bottom: 1px solid var(--home-line); }
  .home-capability-grid button:nth-child(2n) { border-right: 0; }
  .home-capability-grid button:nth-child(n + 7) { border-bottom: 0; }
  .home-capability-grid button em {
    display: -webkit-box;
    overflow: hidden;
    white-space: normal;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }
  .home-products-screen .home-screen-heading { display: block; }
  .home-products-screen .home-screen-heading h2 { font-size: 29px; }
  .home-products-screen .home-screen-heading > span { margin: 8px 0 0; }
  .home-evidence-index { min-height: 0; display: block; margin-top: 30px; border-radius: 14px; }
  .home-evidence-primary { min-height: 430px; border-right: 0; border-bottom: 1px solid var(--home-line-strong); padding: 22px 18px; }
  .home-evidence-primary > strong { font-size: 34px; }
  .home-evidence-row { min-height: 136px; grid-template-columns: 40px minmax(0, 1fr) 14px; gap: 11px; padding: 15px 16px; }
  .home-evidence-label { grid-column: 2; }
  .home-evidence-reading { grid-column: 2; }
  .home-evidence-reading > strong { font-size: 19px; }
  .home-evidence-row > .home-product-go { grid-column: 3; grid-row: 1 / 3; }
}

@media (max-width: 520px) {
  .home-capability-zone > header > div { align-items: flex-start; justify-content: flex-start; gap: 5px; }
  .home-capability-zone > header > div span { margin: 0; text-align: left; }
  .home-answer-preview { display: grid; grid-template-columns: 84px minmax(0, 1fr) 12px; padding-inline: 11px; }
  .home-answer-preview b { font-size: 8.5px; }
  .home-answer-preview em { overflow: hidden; width: 12px; font-size: 0; }
  .home-capability-grid button { grid-template-columns: 28px minmax(0, 1fr) auto; gap: 8px; padding-inline: 9px; }
  .home-capability-grid button > svg { display: none; }
  .home-capability-grid button b { font-size: 10px; white-space: normal; }
  .home-capability-grid button em { font-size: 7.5px; line-height: 1.25; }
  .home-flow-compare { grid-template-columns: auto minmax(80px, 1fr) auto; gap: 8px; }
}

/* Desktop hierarchy pass: calm input at rest, richer workspace on intent. */
@media (min-width: 861px) {
  .home-agent-stage { padding-top: clamp(28px, 4vh, 46px); }

  .home-composer textarea {
    height: 42px;
    min-height: 42px;
    padding: 11px 18px 7px;
    font-size: 16px;
    resize: none;
  }
  .home-composer:not(.is-active) > header { min-height: 40px; padding: 5px 10px; }
  .home-composer:not(.is-active) .home-active-agent-avatar { width: 30px; height: 30px; border-radius: 9px; }
  .home-composer:not(.is-active) .home-active-agent-avatar img { width: 30px; height: 33px; }
  .home-composer:not(.is-active) > header b { margin-top: 3px; }
  .home-composer:not(.is-active) > footer { min-height: 40px; padding: 4px 9px 5px 15px; }
  .home-composer:not(.is-active) > footer > button { width: 32px; height: 32px; border-radius: 10px; }
  .home-composer.is-active {
    border-color: color-mix(in srgb, var(--accent) 58%, var(--home-line-strong));
    box-shadow: 0 28px 84px -48px color-mix(in srgb, var(--accent) 52%, transparent), inset 0 1px 0 var(--hairline);
  }
  .home-composer.is-active textarea {
    height: 172px;
    min-height: 172px;
    padding-top: 22px;
    background: color-mix(in srgb, var(--accent) 2.5%, transparent);
  }
  .home-composer.is-active > header {
    background: color-mix(in srgb, var(--accent) 5%, var(--bg-card));
  }

  .home-capability-grid button { min-height: 102px; padding: 15px 17px; }
  .home-capability-grid button > span:first-child { width: 36px; height: 36px; border-radius: 11px; background: color-mix(in srgb, var(--accent) 14%, var(--bg-page)); }
  .home-capability-grid button > span:first-child svg { width: 17px; height: 17px; }
  .home-capability-grid button small { font-size: 7px; }
  .home-capability-grid button b { margin-top: 7px; font-size: 14px; }
  .home-capability-grid button em { margin-top: 6px; font-size: 9.5px; }

  .home-agent-card { min-height: 198px; padding: 14px 15px 12px; border-radius: 13px; }
  .home-agent-card::after {
    height: 2px;
    position: absolute;
    inset: 0 18px auto;
    content: "";
    border-radius: 0 0 999px 999px;
    background: var(--agent-gradient);
    opacity: .62;
  }
  .home-agent-avatar { width: 29px; height: 29px; }
  .home-agent-card > header small { font-size: 8px; }
  .home-agent-card h3 { margin-top: 12px; font-size: 14px; line-height: 1.38; }
  .home-agent-card > p { font-size: 11px; line-height: 1.45; }
  .home-agent-tags { padding-block: 11px; }
  .home-agent-tags span { font-size: 9px; }
  .home-agent-card > footer span { font-size: 10px; }
  .home-agent-card > footer b { min-height: 32px; font-size: 11px; }

  .home-products-screen { gap: 30px; }
  .home-products-screen .home-screen-heading h2 { font-size: clamp(30px, 2.8vw, 42px); }
  .home-products-screen .home-screen-heading > span { font-size: 9px; }
  .home-evidence-index { min-height: min(570px, 67vh); }
  .home-evidence-primary h3,
  .home-evidence-label h3 { font-size: 17px; }
  .home-evidence-primary p,
  .home-evidence-label p { font-size: 9px; }
  .home-evidence-row { padding-inline: 20px; }
  .home-evidence-reading > strong { font-size: 22px; }
  .home-evidence-reading > span { font-size: 8px; }
}
