/* COO explainer — black-dot, one section per viewport on desktop */

.coo-page {
  --coo-head: 3.7rem;
}

html:has(.coo-page) {
  scroll-padding-top: var(--coo-head, 3.7rem);
}

.coo-page header {
  height: var(--coo-head);
  padding: 0;
  display: flex;
  align-items: center;
  overflow: visible;
}

.coo-page header nav {
  width: 100%;
}

.coo-page .nav-drop {
  position: relative;
}

.coo-page .nav-drop > a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.coo-page .nav-drop > a::after {
  content: "";
  width: 0;
  height: 0;
  border-left: 3.5px solid transparent;
  border-right: 3.5px solid transparent;
  border-top: 4px solid currentColor;
  opacity: 0.5;
}

.coo-page .nav-drop-menu {
  display: none;
  position: absolute;
  top: calc(100% + 0.5rem);
  left: 0;
  min-width: 11rem;
  margin: 0;
  padding: 0.4rem 0;
  list-style: none;
  background: var(--black);
  border: 1px solid var(--hairline);
  z-index: 200;
}

.coo-page .nav-drop-menu::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -0.55rem;
  height: 0.55rem;
}

.coo-page .nav-drop:hover .nav-drop-menu,
.coo-page .nav-drop:focus-within .nav-drop-menu {
  display: block;
}

.coo-page .nav-drop-label {
  display: block;
  padding: 0.2rem 0.85rem 0.35rem;
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--white-40);
}

.coo-page .nav-drop-menu a {
  display: block;
  padding: 0.4rem 0.85rem;
  white-space: nowrap;
}

.coo-page .nav-drop-menu a:hover,
.coo-page .nav-drop-menu a:focus {
  color: var(--white);
  background: rgba(255, 255, 255, 0.06);
}

/* Sections grow with content. No clip — that was painting borders through cards. */

.coo-page .hero,
.coo-page .section,
.coo-page .cta {
  box-sizing: border-box;
  min-height: calc(100svh - var(--coo-head));
}

.coo-page .hero {
  padding: 0;
  display: grid;
  grid-template-rows: 1fr auto;
  align-items: stretch;
  overflow: visible;
}

.coo-page .hero-content {
  grid-template-columns: minmax(0, 1.1fr) minmax(18rem, 0.9fr);
  min-height: 0;
  padding-top: clamp(1.25rem, 3vh, 2.25rem);
  padding-bottom: clamp(0.75rem, 2vh, 1.25rem);
  align-items: start;
  gap: 1.25rem clamp(1.25rem, 3vw, 2.5rem);
}

.loop {
  grid-area: terminal;
}

.kicker {
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--white-40);
  margin: 0 0 0.55rem;
}

.hero-copy h1 {
  font-size: clamp(1.45rem, 3.4vw, 2.25rem);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin: 0 0 0.65rem;
}

.hero-copy p {
  color: var(--white-70);
  max-width: 36rem;
  margin: 0 0 0.65rem;
  font-size: clamp(0.84rem, 1.35vw, 0.95rem);
}

.hero-copy p:last-child {
  margin-bottom: 0;
}

.truth-strip {
  width: min(100%, var(--max));
  margin: 0 auto;
  padding: 0.75rem var(--pad-x) 1rem;
  border-top: 1px solid var(--white-10);
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
  flex-shrink: 0;
}

.truth-strip article {
  border-left: 1px solid var(--hairline);
  padding-left: 0.75rem;
}

.truth-strip h3 {
  margin: 0 0 0.25rem;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--white-40);
}

.truth-strip p {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.4;
  color: var(--white-70);
}

.section {
  width: min(100%, var(--max));
  margin: 0 auto;
  padding: clamp(1.5rem, 3.5vh, 2.5rem) var(--pad-x) clamp(1.75rem, 4vh, 2.75rem);
  border-bottom: 1px solid var(--white-10);
  display: flex;
  flex-direction: column;
}

.section-title {
  font-size: clamp(1.05rem, 2vw, 1.28rem);
  font-weight: 500;
  letter-spacing: -0.02em;
  margin: 0 0 0.35rem;
  flex-shrink: 0;
}

.section-lede {
  color: var(--white-70);
  max-width: 42rem;
  margin: 0 0 clamp(0.55rem, 1.6vh, 1rem);
  font-size: 0.88rem;
  flex-shrink: 0;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
}

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

.why-grid {
  flex: 0 0 auto;
}

.why-surfaces {
  margin-top: 1.15rem;
  padding-top: 1.15rem;
  border-top: 1px solid var(--white-10);
  flex: 0 0 auto;
}

.card {
  border: 1px solid var(--hairline);
  padding: 0.65rem 0.75rem;
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.card h3 {
  margin: 0 0 0.3rem;
  font-size: 0.88rem;
  font-weight: 500;
}

.card p,
.card li {
  color: var(--white-70);
  font-size: 0.78rem;
  line-height: 1.4;
  margin: 0;
}

.card ul {
  margin: 0;
  padding-left: 1.05rem;
}

.card .need {
  margin-top: auto;
  padding-top: 0.4rem;
  border-top: 1px solid var(--white-10);
  color: var(--white-92);
  font-size: 0.74rem;
}

.mono {
  font-family: "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;
  font-size: 0.75rem;
  letter-spacing: 0.02em;
}

/* Loop demo */
.loop {
  border: 1px solid var(--hairline);
  background: var(--ink);
  overflow: hidden;
  align-self: stretch;
}

.loop-chrome {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.4rem 0.75rem;
  border-bottom: 1px solid var(--white-10);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--white-40);
}

.loop-body {
  padding: 0.55rem 0.65rem;
  display: grid;
  gap: 0.28rem;
}

.loop-row {
  display: grid;
  grid-template-columns: 5.2rem 1fr auto;
  gap: 0.5rem;
  align-items: center;
  padding: 0.32rem 0.45rem;
  border: 1px solid transparent;
  color: var(--white-40);
  font-size: 0.76rem;
  transition: border-color 0.35s, color 0.35s, background 0.35s;
}

.loop-row.is-active {
  border-color: var(--white);
  color: var(--white);
  background: rgba(255, 255, 255, 0.04);
}

.loop-row.is-done {
  color: var(--white-70);
}

.loop-row .tag {
  font-size: 0.64rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: inherit;
}

.pulse-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--white-18);
  justify-self: end;
}

.loop-row.is-active .pulse-dot {
  background: var(--white);
  animation: blink 1s steps(2) infinite;
}

@keyframes blink {
  50% { opacity: 0.25; }
}

/* Hub */
#hub.section .hub {
  flex: 1;
  min-height: 0;
}

.hub {
  position: relative;
  border: 1px solid var(--hairline);
}

.hub-core-slot {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
}

.hub-core {
  width: 6.4rem;
  height: 6.4rem;
  border: 1px solid var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--black);
  animation: hub-breathe-static 4.2s ease-in-out infinite;
}

.hub-core::before,
.hub-core::after {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.4);
  pointer-events: none;
  animation: hub-ring 4.2s ease-out infinite;
}

.hub-core::after {
  animation-delay: 2.1s;
}

@keyframes hub-ring {
  0% {
    transform: scale(1);
    opacity: 0.45;
  }
  100% {
    transform: scale(1.55);
    opacity: 0;
  }
}

.hub-core.is-lit {
  animation-name: hub-breathe-lit-static;
  animation-duration: 2.6s;
}

.hub-core.is-lit::before,
.hub-core.is-lit::after {
  border-color: rgba(255, 255, 255, 0.85);
  animation-name: hub-ring-lit;
  animation-duration: 2.6s;
}

.hub-core.is-lit::after {
  animation-delay: 1.3s;
}

@keyframes hub-ring-lit {
  0% {
    transform: scale(1);
    opacity: 0.8;
  }
  100% {
    transform: scale(1.7);
    opacity: 0;
  }
}

@keyframes hub-breathe-static {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.12);
  }
  50% {
    transform: scale(1.045);
    box-shadow: 0 0 18px 2px rgba(255, 255, 255, 0.08);
  }
}

@keyframes hub-breathe-lit-static {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 10px 1px rgba(255, 255, 255, 0.22);
  }
  50% {
    transform: scale(1.07);
    box-shadow: 0 0 28px 6px rgba(255, 255, 255, 0.28);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hub-core,
  .hub-core::before,
  .hub-core::after {
    animation: none;
  }
}

.hub-node {
  position: absolute;
  width: 7.4rem;
  padding: 0.4rem 0.5rem;
  border: 1px solid var(--hairline);
  background: var(--black);
  font-size: 0.74rem;
  cursor: pointer;
  text-align: left;
  color: var(--white-70);
  transition: border-color 0.2s, color 0.2s;
}

.hub-node:hover,
.hub-node.is-on {
  border-color: var(--white);
  color: var(--white);
}

.hub-node strong {
  display: block;
  font-weight: 500;
  color: inherit;
  margin-bottom: 0.1rem;
}

.hub-node[data-slot="0"] { left: 4%; top: 8%; }
.hub-node[data-slot="1"] { right: 4%; top: 8%; }
.hub-node[data-slot="2"] { left: 2%; top: 42%; }
.hub-node[data-slot="3"] { right: 2%; top: 42%; }
.hub-node[data-slot="4"] { left: 18%; bottom: 8%; }
.hub-node[data-slot="5"] { right: 18%; bottom: 8%; }

.hub-note {
  margin-top: 0.55rem;
  min-height: 2.6rem;
  max-height: 3.4rem;
  overflow: hidden;
  color: var(--white-70);
  font-size: 0.82rem;
  flex-shrink: 0;
}

/* Review demo */
#review.section .review-demo {
  flex: 1;
  min-height: 0;
}

.review-demo {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 1rem;
  align-items: center;
}

.review-col h4 {
  margin: 0 0 0.45rem;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--white-40);
  font-weight: 500;
}

.mail-card {
  border: 1px dashed var(--hairline);
  padding: 0.85rem 1rem;
  font-size: 0.85rem;
  color: var(--white-70);
}

.mail-card.is-held {
  animation: holdPulse 2.4s ease-in-out infinite;
}

.mail-card.is-sent {
  border-style: solid;
  border-color: var(--white);
  color: var(--white);
}

@keyframes holdPulse {
  0%, 100% { opacity: 0.7; }
  50% { opacity: 1; }
}

.review-arrow {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--white-40);
  text-align: center;
}

.review-actions {
  margin: 0.75rem 0 0;
  flex-shrink: 0;
}

/* Surfaces */
.surfaces {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  flex-shrink: 0;
}

.surfaces button {
  background: transparent;
  border: 1px solid var(--hairline);
  color: var(--white-70);
  padding: 0.35rem 0.6rem;
  font: inherit;
  font-size: 0.8rem;
  cursor: pointer;
}

.surfaces button.is-on,
.surfaces button:hover {
  border-color: var(--white);
  color: var(--white);
}

.surface-out {
  margin-top: 0.65rem;
  border: 1px solid var(--hairline);
  padding: 0.85rem 1rem;
  min-height: 5.5rem;
}

.surface-out h3 {
  margin: 0 0 0.4rem;
  font-size: 1rem;
  font-weight: 500;
}

.surface-out p {
  margin: 0;
  color: var(--white-70);
  font-size: 0.9rem;
}

/* Kit */
#kit.section .grid-2 {
  flex: 1;
  min-height: 0;
}

#kit.section .kit-extra {
  flex: 0.85;
  margin-top: 0.55rem;
  min-height: 0;
}

/* Day one */
.day1-stage {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(12rem, 0.5fr);
  gap: 0;
  flex: 1;
  min-height: 0;
  padding: 0;
  overflow: hidden;
}

.day1-list {
  margin: 0;
  padding: 0.85rem 1.1rem 0.85rem 2.1rem;
  color: var(--white-70);
  columns: 1;
}

.day1-list li {
  margin: 0 0 0.45rem;
  font-size: 0.82rem;
}

.day1-bot {
  display: flex;
  align-items: center;
  justify-content: center;
  border-left: 1px solid var(--white-10);
  padding: 0.75rem 1rem;
  min-width: 0;
}

.day1-cmd {
  margin: 0.65rem 0 0;
  color: var(--white-40);
  flex-shrink: 0;
}

/* P2A unit — same SVG + paired mood as COO operator UI */
.p2a-bot {
  --p2a-bot-ink: var(--white);
  --p2a-bot-panel: transparent;
  --p2a-bot-glow: var(--white);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  pointer-events: none;
  user-select: none;
}
.p2a-bot-meta {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 11.5rem;
  text-align: center;
}
.p2a-bot-meta .p2a-card-text {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--white-92);
  line-height: 1.25;
}
.p2a-bot-svg {
  display: block;
  width: 88px;
  height: 104px;
  overflow: visible;
}
.p2a-bot-svg line,
.p2a-bot-svg rect,
.p2a-bot-svg circle {
  fill: var(--p2a-bot-panel);
  stroke: var(--p2a-bot-ink);
  stroke-width: 1.4;
  stroke-linejoin: round;
}
.p2a-bot-antenna line {
  fill: none;
}
.p2a-bot-antenna-tip,
.p2a-bot-eye,
.p2a-bot-chest,
.p2a-bot-gear {
  fill: var(--p2a-bot-glow);
  stroke: none;
}
.p2a-bot-mouth {
  fill: var(--p2a-bot-ink);
  stroke: none;
  opacity: 0.55;
}
.p2a-bot-body {
  transform-origin: 24px 40px;
}
.p2a-bot-eyes {
  transform-origin: 24px 20px;
  animation: p2a-bot-blink 4.2s steps(1, end) infinite;
}
.p2a-bot-antenna-tip {
  transform-origin: 24px 2px;
}
.p2a-bot[data-mood="paired"] .p2a-bot-body {
  animation: p2a-bot-idle 2.8s ease-in-out infinite;
}
.p2a-bot[data-mood="paired"] .p2a-bot-antenna-tip {
  animation: p2a-bot-tip 2.4s ease-in-out infinite;
}

@keyframes p2a-bot-idle {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-1.5px); }
}
@keyframes p2a-bot-blink {
  0%, 46%, 54%, 100% { transform: scaleY(1); }
  48%, 52% { transform: scaleY(0.12); }
}
@keyframes p2a-bot-tip {
  0%, 100% { opacity: 0.55; transform: scale(0.9); }
  50% { opacity: 1; transform: scale(1.15); }
}

#not.section .grid-2 {
  flex: 1;
  min-height: 0;
  align-items: stretch;
}

#not .card {
  position: relative;
  overflow: hidden;
  border-color: var(--hairline);
  transition: border-color 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
}

#not .card.is-live {
  background: rgba(255, 255, 255, 0.015);
}

#not .card.is-focus {
  border-color: var(--white);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35);
  z-index: 1;
}

#not .card.is-bump {
  box-shadow: inset 0 0 0 1px var(--white), 0 0 18px rgba(255, 255, 255, 0.12);
}

#not .pen {
  flex: 1;
  min-height: 7.5rem;
  position: relative;
  overflow: hidden;
  margin-top: 0.65rem;
  border-top: 1px solid var(--white-10);
}

#not .card.is-think {
  border-color: rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.025);
}

#not .pen-glow {
  position: absolute;
  left: 0;
  top: 0;
  width: 7.5rem;
  height: 7.5rem;
  margin: -3.75rem 0 0 -3.75rem;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0.06) 38%, transparent 70%);
  pointer-events: none;
  z-index: 0;
  will-change: transform;
}

#not .card.is-focus .pen-glow {
  background: radial-gradient(circle, rgba(255, 255, 255, 0.32) 0%, rgba(255, 255, 255, 0.1) 40%, transparent 72%);
}

#not .bit {
  position: absolute;
  width: 48px;
  height: 48px;
  transform-origin: center bottom;
  will-change: transform;
  z-index: 1;
}

/* CTA + footer as last screen */
.coo-page .cta {
  width: min(100%, var(--max));
  margin: 0 auto;
  padding: clamp(0.85rem, 2.2vh, 1.5rem) var(--pad-x) 0.75rem;
  border-bottom: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: left;
}

.coo-page .cta h2 {
  max-width: none;
}

.price-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: baseline;
  margin-bottom: 0.65rem;
}

.price-row .now {
  font-size: 1.75rem;
  font-weight: 500;
  letter-spacing: -0.03em;
}

.price-row .was {
  color: var(--white-40);
  text-decoration: line-through;
}

.fine {
  font-size: 0.8rem;
  color: var(--white-40);
  max-width: 40rem;
  margin: 0.65rem 0 1rem;
}

.coo-page .cta footer {
  margin-top: auto;
  padding: 1rem 0 0.85rem;
  width: 100%;
}

@media (max-height: 760px) {
  .card .need {
    display: none;
  }
  .hero-copy p:nth-of-type(3) {
    display: none;
  }
}

@media (max-width: 860px) {
  .coo-page .hero-content {
    grid-template-columns: 1fr;
  }
  .truth-strip,
  .grid-2,
  .grid-3,
  .review-demo,
  .day1-stage {
    grid-template-columns: 1fr;
    columns: 1;
  }
  .day1-bot {
    border-left: 0;
    border-top: 1px solid var(--white-10);
    min-height: 10rem;
  }
  .hub {
    min-height: 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-rows: auto auto auto;
    gap: 0.4rem 0.35rem;
    padding: 0.7rem 0.55rem 0.85rem;
    align-items: stretch;
  }
  .hub-node {
    position: relative;
    left: auto !important;
    right: auto !important;
    top: auto !important;
    bottom: auto !important;
    width: auto;
    margin: 0;
    min-width: 0;
    padding: 0.35rem 0.4rem;
    font-size: 0.68rem;
  }
  .hub-node[data-slot="0"] { grid-column: 1; grid-row: 1; }
  .hub-node[data-slot="1"] { grid-column: 2; grid-row: 1; }
  .hub-node[data-slot="2"] { grid-column: 3; grid-row: 1; }
  .hub-node[data-slot="3"] { grid-column: 1; grid-row: 3; }
  .hub-node[data-slot="4"] { grid-column: 2; grid-row: 3; }
  .hub-node[data-slot="5"] { grid-column: 3; grid-row: 3; }
  .hub-core-slot {
    grid-column: 1 / -1;
    grid-row: 2;
    justify-self: center;
    align-self: center;
    position: relative;
    left: auto;
    top: auto;
    transform: none;
    margin: 0.35rem 0;
  }
  .hub-core {
    width: 5.5rem;
    height: 5.5rem;
  }
}
