/* precise.ai 2.0: the rules this build owns, on top of the Claude Design kit. site.css, tokens and components/ stay byte
   for byte as the design system ships them (check-site compares them), so everything new for the site lives here.
   Tokens only: no new colours, sizes or fonts. */

/* Hero chart: same budget, two results. The card is its own container, so its header lays out by the card's width:
   the Without / With Precise switch sits beside the title when there is room, and under the subhead when there is not. */
.pr-twin{container:pr-twin/inline-size}
.pr-twin__top{display:grid;gap:5px 16px}
.pr-twin__top .pr-plate__q{font-size:clamp(19px,1.5vw,21px);line-height:1.2}
.pr-twin__sub{margin:0;font-size:13px;line-height:1.45;color:var(--muted-deep);text-wrap:pretty}
.pr-twin__mode{display:inline-flex;justify-self:start;gap:2px;margin-top:5px;padding:2px;border:1px solid var(--rule);border-radius:3px;background:var(--sheet)}
.pr-twin__mode button{height:24px;padding:0 9px;border:0;border-radius:2px;background:transparent;color:var(--muted-deep);font:500 12px/1 var(--font-ui);white-space:nowrap;cursor:pointer}
.pr-twin__mode button:hover{color:var(--ink)}
.pr-twin__mode button[aria-checked="true"]{background:var(--ink);color:var(--ground)}
@media (pointer:coarse){.pr-twin__mode button{height:32px;padding:0 12px}}
/* Of each $1 of media: working media and fees in the chosen state, then its net ROAS. Two lines on a narrow card, one
   line on a wide card (where both wordings always fit), so the strip never changes height when the state changes. */
.pr-twin__media{margin:12px 0 10px}
.pr-twin__split{display:grid;gap:2px 16px;margin:0 0 6px;font:11.5px/1.4 var(--font-mono);color:var(--muted-deep);font-variant-numeric:tabular-nums}
.pr-twin__split b{color:var(--ink);font-weight:600}
.pr-twin__bar{display:flex;height:8px;border:1px solid var(--ink);border-radius:2px;overflow:hidden}
.pr-twin__bar i:first-child{background:var(--ink);transition:width 220ms ease}
.pr-twin__bar i:last-child{flex:1;border-left:1px solid var(--ink);background:var(--rule)}
@container pr-twin (min-width:480px){
  .pr-twin__top{grid-template-columns:minmax(0,1fr) auto}
  .pr-twin__top .pr-plate__q{grid-row:1;grid-column:1}
  .pr-twin__mode{grid-row:1;grid-column:2;align-self:start;margin-top:0}
  .pr-twin__sub{grid-column:1/-1}
  .pr-twin__split{display:flex;justify-content:space-between}
}
/* Without Precise: the unchanged twin becomes the measured line, and the Precise side steps back. Colour changes animate
   only once the visitor has switched (data-moved), so a saved dark theme applied at load never fades in. */
.pr-twin .pr-twin__p{transition:opacity 220ms ease}
.pr-twin[data-mode="without"] .pr-twin__p{opacity:.22}
.pr-twin[data-mode="without"] .pr-chart .pr-twin__base{stroke:var(--ink);stroke-width:var(--chart-challenger-width)}
.pr-twin[data-mode="without"] .pr-chart .pr-twin__ahead{stroke-width:var(--chart-said-width)}
.pr-twin[data-mode="without"] .pr-chart .pr-twin__base-l{fill:var(--ink)}
.pr-twin[data-moved] .pr-chart .pr-twin__base{transition:stroke 220ms ease,stroke-width 220ms ease}
.pr-twin[data-moved] .pr-chart .pr-twin__base-l{transition:fill 220ms ease}
@media (prefers-reduced-motion:reduce){.pr-twin .pr-twin__p,.pr-twin[data-moved] .pr-chart .pr-twin__base,.pr-twin[data-moved] .pr-chart .pr-twin__base-l,.pr-twin__bar i{transition:none}}
.pr-chart .pr-twin__with{stroke-width:var(--chart-challenger-width)}
.pr-chart .pr-twin__ahead{stroke-dasharray:3 4}
.pr-chart .pr-twin__gain{font-size:20px;letter-spacing:-.01em;stroke:none}
.pr-chart .pr-twin__gain-l{fill:var(--muted-deep);stroke:none}
.pr-chart .pr-twin__twin{fill:var(--axis)}
.pr-chart .pr-twin__edge{fill:none;stroke:var(--said-line);stroke-width:1}
.pr-ctip__k.is-twin::before{content:"";width:10px;border-top:1.25px solid var(--axis)}

/* Home headline: boot.js gives each visitor one of three, swapped in after hydration, so all three must break onto the
   same lines at every width or the swap would move the page. From 436px to 536px some fit two lines and some need
   three; capping the measure there gives all three the same three lines. check-site scans every width. */
@media (max-width:536px){#site-root[data-page="home"] .ws-hero .ws-h1{max-width:12.5em}}

/* One quiet line under every example chart. */
.ws-ex{margin:12px 0 0;font:12px/1.5 var(--font-mono);color:var(--muted)}
.ws-ex a{color:var(--muted-deep)}
.ws-ex a:hover{color:var(--ink)}

/* Hero slots: a one-line definition under the lead, and one quiet line of facts under the buttons. */
.ws-define{max-width:60ch;margin:14px 0 0;font-size:15.5px;line-height:1.5;color:var(--muted-deep);text-wrap:pretty}
.ws-factline{margin:22px 0 0;font:12px/1.6 var(--font-mono);color:var(--muted-deep)}

/* Code is set in JetBrains Mono like every other figure (the browser's own code font would otherwise win inside <pre>),
   and shows every character as typed: no ligature joins "--" into one long dash. */
pre code{font:inherit;font-variant-ligatures:none}

/* /trust: the two ways to connect, one per line. */
.ws-mode{display:block}
.ws-mode+.ws-mode{margin-top:8px}

/* /docs: one settled test walked back to its rows, then the doc list. */
.ws-walk{display:grid;gap:12px;margin-bottom:36px}
.ws-walk h2{margin:0}
.ws-walk .ws-explain{margin:0}
.ws-walk .ws-row{margin:0}
.ws-walk .ws-row a{font-weight:600}
.ws-walk .ws-mt24{margin-top:6px}

/* Home loop: no step ends on one stranded word. */
.ws-layer__top--loop .ws-cycle p{text-wrap:pretty}

/* Home loop below 560px: the text clears the dashed track and its arrow. */
@media (max-width:560px){
  .ws-layer__top--loop .ws-cycle li{padding-left:24px!important;padding-right:12px!important}
  .ws-layer__top--loop .ws-cycle li:first-child .ws-cycle__n{margin-left:-8px}
}

/* Header below 860px: one compact row and a menu. Applies only when the app script is on the page (html.ws-js is set
   before the first paint), so the header height is final from the start; without JavaScript the full nav wraps. */
.ws-mbar,.ws-mnav{display:none}
@media (max-width:860px){
  html.ws-js .ws-header__in{flex-wrap:nowrap;min-height:56px;padding-top:6px;padding-bottom:6px}
  html.ws-js .ws-nav{display:none}
  html.ws-js .ws-mbar{display:flex;align-items:center;gap:8px}
  .ws-mbar__menu{min-width:64px;border:1px solid var(--rule)}
  html.ws-js .ws-mnav:not([hidden]){display:block;position:absolute;top:100%;left:0;right:0;max-height:calc(100vh - 57px);overflow-y:auto;background:var(--ground);border-bottom:1px solid var(--rule)}
  .ws-mnav__in{display:grid;padding-top:4px;padding-bottom:18px}
  .ws-mnav__in>a{display:flex;align-items:center;min-height:44px;border-bottom:1px solid var(--hair);color:var(--ink);font-size:16.5px;text-decoration:none}
  .ws-mnav__in>a[aria-current="page"]{font-weight:600}
  .ws-mnav__row{display:flex;flex-wrap:wrap;gap:10px;padding-top:16px}
}
/* Below 360px the wordmark, Open Sandbox and Menu only fit on one row with tighter gaps (at 320px they overflowed by 20px). */
@media (max-width:359px){html.ws-js .ws-header__in{gap:8px}html.ws-js .ws-mbar{gap:6px}.ws-mbar__menu{min-width:0}}
