/* English home page (design pass, Nov 27-28 2026). Loaded last, after receipt.css, receipt-system.css, home-page.css and
   motion.css. Only index.html loads it: /es and /pt-br keep their markup and the shared sheets, unchanged.
   A. The recorded run: its last frame drawn as page elements (.rr); the one control in its own bar (.rr-bar), driven by
      recorded-run.js; the test's two facts as text above the still (.rr-facts).
   B. The first-screen sample (.pa-*): retimed to the motion system by pov-sample.js; here, its layout fixes.
   C. The AgentGuard terminal (.agt-*), written against the terminal's own markup.
   D. Tap targets on this page that were under 44px.
   E. No scroll reveal: every section is visible from the first paint. */

/* ---- A. the recorded run ------------------------------------------------------------------------------------- */
/* The stage is no longer a 16:9 box holding a picture. It is a bar, then a frame that holds the still and, on press,
   the video in the same box. The still never leaves the layout (it turns invisible while the video plays), so the
   frame's height never changes. */
.ag-receipt .pov-proof .hero-stage.rr-stage{display:block;aspect-ratio:auto;overflow:visible;background:transparent;border:0;border-top:1px dashed var(--ag-ink)}
.ag-receipt .rr-bar{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px;min-height:44px;padding:10px 0}
.ag-receipt .rr-bar-label{margin:0;font:500 10.5px/1.4 var(--ag-mono);letter-spacing:.08em;text-transform:uppercase;color:var(--ag-ink-2)}
.ag-receipt .rr-play{display:inline-flex;align-items:center;justify-content:center;gap:9px;flex:none;min-height:44px;padding:0 16px;background:var(--ag-ink);border:1px solid var(--ag-ink);color:var(--ag-slip);font:500 14px/1 var(--ag-sans);text-decoration:none;white-space:nowrap}
.ag-receipt .rr-play svg{width:13px;height:13px;fill:var(--ag-slip);flex:none}
.ag-receipt .rr-play:focus-visible{outline:2px solid var(--ag-ink);outline-offset:2px}
.ag-receipt .rr-play .rr-i-pause,.ag-receipt .rr-play.is-pause .rr-i-play{display:none}
.ag-receipt .rr-play.is-pause .rr-i-pause{display:block}
/* the test's two facts, as text above the still: a phone visitor reads them without opening anything */
.ag-receipt .rr-facts{display:grid;gap:6px;margin:0;padding:2px 0 14px;list-style:none}
.ag-receipt .rr-facts li{display:flex;align-items:baseline;gap:10px;margin:0;font:500 15px/1.35 var(--ag-sans);color:var(--ag-ink);text-wrap:pretty}
.ag-receipt .rr-facts strong{flex:none;min-width:2ch;font:600 22px/1 var(--ag-mono);font-variant-numeric:tabular-nums}
.ag-receipt .rr-facts li+li strong{color:var(--ag-stamp)}
@media (min-width:900px){.ag-receipt .rr-facts{display:flex;flex-wrap:wrap;gap:6px 36px}}
.ag-receipt .rr-frame{position:relative}
.ag-receipt .pov-proof .rr-frame .hero-video{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;object-position:center top;background:var(--ag-paper)}
.ag-receipt .rr-stage.is-playing .rr{visibility:hidden}

/* the still: the film's last frame, as text. Paper ground, slip cards with a hairline, one ink, red for the refusals. */
.ag-receipt .rr{display:grid;gap:14px;padding:6px 0 4px;color:var(--ag-ink)}
.ag-receipt .rr p,.ag-receipt .rr dl,.ag-receipt .rr dd,.ag-receipt .rr ol{margin:0;padding:0}
.ag-receipt .rr-head{display:flex;flex-wrap:wrap;align-items:baseline;gap:2px 12px}
.ag-receipt .rr-brand{font:700 clamp(17px,1.9vw,22px)/1.2 var(--ag-display);letter-spacing:-.01em}
.ag-receipt .rr-head span,.ag-receipt .rr-k{font:600 10.5px/1.4 var(--ag-sans);letter-spacing:.05em;text-transform:uppercase;color:var(--ag-ink-2)}
.ag-receipt .rr-head span{text-transform:none}
.ag-receipt .rr-title{font:700 clamp(23px,3.4vw,40px)/1.12 var(--ag-display);letter-spacing:-.02em;text-wrap:balance}
.ag-receipt .rr-refused{margin-top:-8px;font:600 clamp(15px,1.9vw,22px)/1.3 var(--ag-sans);color:var(--ag-stamp);text-wrap:pretty}
.ag-receipt .rr-stats{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:8px}
.ag-receipt .rr-stats>div{grid-column:span 2;min-width:0;padding:10px 12px;background:var(--ag-slip);border:1px solid var(--ag-rule)}
.ag-receipt .rr-stats>div:nth-child(n+4){grid-column:span 3}
.ag-receipt .rr-stats dt{font:600 10px/1.3 var(--ag-sans);letter-spacing:.05em;text-transform:uppercase;color:var(--ag-ink-2)}
.ag-receipt .rr-stats dd{font:600 clamp(20px,2.3vw,28px)/1.15 var(--ag-mono);overflow-wrap:anywhere}
.ag-receipt .rr-stats dd.rr-sub{font:400 12px/1.35 var(--ag-sans);color:var(--ag-ink-2)}
.ag-receipt .rr-stats .is-refused dd:not(.rr-sub){color:var(--ag-stamp)}
.ag-receipt .rr-main{display:grid;gap:14px}
.ag-receipt .rr-left,.ag-receipt .rr-right{display:grid;gap:8px;min-width:0;align-content:start}
.ag-receipt .rr-copies{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:4px;list-style:none}
.ag-receipt .rr-copies li{display:flex;align-items:center;justify-content:center;min-height:26px;background:var(--ag-ink);color:var(--ag-slip);font:600 11.5px/1 var(--ag-mono);white-space:nowrap}
.ag-receipt .rr-cells{display:block;width:100%;height:auto}
.ag-receipt .rr-cells--wide{display:none}
.ag-receipt .rr-card{min-width:0;padding:11px 12px 12px;background:var(--ag-slip);border:1px solid var(--ag-rule)}
.ag-receipt .rr-card .rr-k{display:flex;justify-content:space-between;gap:10px;margin-bottom:6px}
.ag-receipt .rr-clock{font:400 10.5px/1.4 var(--ag-mono);letter-spacing:0;text-transform:none;white-space:nowrap}
.ag-receipt .rr-copy{display:none}
.ag-receipt .rr-copy-name{display:flex;align-items:baseline;gap:8px;font:600 15px/1.35 var(--ag-sans)}
.ag-receipt .rr-chip{flex:none;width:9px;height:9px;background:var(--ag-ink)}
.ag-receipt .rr-mono{font:400 12.5px/1.6 var(--ag-mono);color:var(--ag-ink-2)}
.ag-receipt .rr-meter{display:block;height:4px;margin-top:8px;background:var(--ag-ink)}
.ag-receipt .rr-dec{display:grid;grid-template-columns:5ch minmax(0,1fr) 3ch;align-items:center;gap:10px;font:700 11.5px/1.9 var(--ag-mono)}
.ag-receipt .rr-dec b{font-weight:700;font-size:14px;text-align:right}
.ag-receipt .rr-dec i{display:block;height:8px;background:var(--ag-rule)}
.ag-receipt .rr-dec i::after{content:"";display:block;height:100%;width:var(--w);background:var(--ag-ink)}
/* bar lengths: 2, 13 and 8 of the 13 warnings, the longest row (kept here so the hero carries no inline style) */
.ag-receipt .rr-dec{--w:100%}.ag-receipt .rr-dec.is-ok{--w:15.4%}.ag-receipt .rr-dec.is-stop{--w:61.5%}
.ag-receipt .rr-dec.is-ok{color:var(--ag-ink-2)}.ag-receipt .rr-dec.is-ok i::after{background:var(--ag-ink-2)}
.ag-receipt .rr-dec.is-stop{color:var(--ag-stamp)}.ag-receipt .rr-dec.is-stop i::after{background:var(--ag-stamp)}
.ag-receipt .rr-ledger-rows{list-style:none;font:400 12px/1.75 var(--ag-mono);font-variant-numeric:tabular-nums}
.ag-receipt .rr-ledger-rows li{display:flex;flex-wrap:wrap;gap:0 2ch}
.ag-receipt .rr-foot{font:400 11.5px/1.5 var(--ag-sans);color:var(--ag-ink-2)}
@media (min-width:520px){
  .ag-receipt .rr-copies{grid-template-columns:repeat(8,minmax(0,1fr))}
}
@media (min-width:900px){
  .ag-receipt .rr{gap:16px;padding-top:10px}
  .ag-receipt .rr-stats{grid-template-columns:repeat(5,minmax(0,1fr));gap:10px}
  .ag-receipt .rr-stats>div,.ag-receipt .rr-stats>div:nth-child(n+4){grid-column:auto}
  .ag-receipt .rr-main{grid-template-columns:minmax(0,1.75fr) minmax(0,1fr);gap:24px}
  .ag-receipt .rr-copies{grid-template-columns:repeat(15,minmax(0,1fr));gap:5px}
  .ag-receipt .rr-copies li{min-height:30px;font-size:12px}
  .ag-receipt .rr-cells--wide{display:block}.ag-receipt .rr-cells--phone{display:none}
  .ag-receipt .rr-copy{display:block}
  .ag-receipt .rr-right{gap:12px}
  .ag-receipt .rr-ledger-rows{font-size:12.5px}
}

/* ---- B. the first-screen sample ------------------------------------------------------------------------------ */
/* the request: a hollow square until the limit answers; ink when allowed; red, and stopped short, when refused */
.ag-receipt .pa-tr{left:0;top:0;box-sizing:border-box;width:9px;height:9px;margin:-4.5px 0 0 -4.5px;border:1px solid var(--ag-ink);border-radius:0;background:var(--ag-slip);box-shadow:none;will-change:transform}
.ag-receipt .pa-tr.ok{background:var(--ag-ink)}
.ag-receipt .pa-tr.no{width:10px;height:10px;margin:-5px 0 0 -5px;border-color:var(--ag-stamp);background:var(--ag-stamp)}
/* the limit's label sits at the foot of the line, off the request's path; the stamp has the top corner to itself */
.ag-receipt .pa-stage{grid-template-columns:minmax(0,1fr) 30px minmax(0,1fr)}
.ag-receipt .pa-line-label{left:50%;top:auto;bottom:5px;writing-mode:horizontal-tb;transform:translateX(-50%);padding:1px 5px;background:var(--ag-slip);z-index:1}
.ag-receipt .pa-stamp{top:9px;bottom:auto;right:calc(50% + 8px)}
.ag-receipt .pa-stamp.on{opacity:1;animation:none}
.ag-receipt .pa-stamp.on.is-landing{animation:ag-m-stamp var(--ag-t-tick) var(--ag-ease-out) both}
/* the prompt's line stays on one line; the copy cells shrink before they overflow at 320px */
.ag-receipt .pa-prompt{padding-right:0}
.ag-receipt .pa-ask{white-space:nowrap;font-size:clamp(9.5px,2.9vw,11px)}
.ag-receipt .pa-grid{grid-template-columns:repeat(5,minmax(0,24px))}
.ag-receipt .pa-slot,.ag-receipt .pa-cell{transition:background-color var(--ag-t-tick) linear,color var(--ag-t-tick) linear,border-color var(--ag-t-tick) linear}
.ag-receipt .pa-bar{transition:background-color var(--ag-t-tick) linear}
.ag-receipt .pa-line{transition:border-color var(--ag-t-tick) linear}
/* the ledger keeps room for its four rows at every width, so printing a row never moves the page */
.ag-receipt .pa-ledger{position:relative}
.ag-receipt .pov-anim .pa-log{min-height:6em}
.ag-receipt .pov-anim .pa-log>div:nth-last-child(-n+4){display:flex}
.ag-receipt .pov-anim .pa-log>div:not(:nth-last-child(-n+4)){display:none}
@media (min-width:900px){
  .ag-receipt .pa-stage{grid-template-columns:minmax(0,1fr) 64px minmax(0,1.12fr)}
  /* fluid: between about 900 and 1100px the copies column is narrower than five 32px slots and their gaps */
  .ag-receipt .pa-grid{grid-template-columns:repeat(5,minmax(0,32px))}
  /* fluid until the prompt's column fits the line at 12.5px (about 1030px wide): between 900 and 1030 the column is
     narrower than "start another copy" at 12.5px, and the requests started on the words */
  .ag-receipt .pa-ask{font-size:clamp(9.5px,calc(2.18vw - 10px),12.5px)}
  .ag-receipt .pa-line-label{bottom:8px}
  .ag-receipt .pa-stamp{top:14px;right:calc(50% + 12px)}
  .ag-receipt .pov-anim .pa-log{min-height:6.4em}
}
@media (prefers-reduced-motion:reduce){
  .ag-receipt .pa-stamp.on.is-landing{animation:none}
  .ag-receipt .pa-slot,.ag-receipt .pa-cell,.ag-receipt .pa-bar,.ag-receipt .pa-line{transition:none}
}

/* ---- C. the AgentGuard terminal -------------------------------------------------------------------------------- */
/* Written against the terminal's own markup (terminal/agentguard-terminal.js builds it): .agt > .agt-bar (.agt-lights,
   .agt-title, .agt-progress), .agt-body (one .agt-view per scene), .agt-foot (.agt-foot-group: the key hints, Skip,
   Replay, Back to menu). The terminal's script and sheet are unchanged, so the private prototype page that loads them
   without a Receipt sheet keeps its own look. receipt.css already maps the terminal's colours to ink on slip; these rules
   add what makes it read as a terminal in the Receipt look: an ink window edge, a title bar on paper with three square
   window marks, menu lines (not boxed fields) with the script's own pointer at the end, a still cursor, the held mark
   half filled, the STOP badge as an outlined red tag, 44px controls, and key hints only where there is a keyboard. */
.ag-receipt .home-terminal .agt{border:1px solid var(--ag-ink)}
/* no reserved height at rest (it left an empty slip under the three choices): terminal-room.js gives the window the
   scene's full height the moment a replay starts */
.ag-receipt .home-terminal .agt-body{min-height:0}
.ag-receipt .home-terminal .agt-bar{height:auto;min-height:36px;gap:12px;padding:0 12px;background:var(--ag-paper);border-bottom:1px solid var(--ag-ink)}
.ag-receipt .home-terminal .agt-lights{display:flex;gap:5px}
.ag-receipt .home-terminal .agt-lights span{width:8px;height:8px;border:1px solid var(--ag-ink);border-radius:0;background:transparent}
.ag-receipt .home-terminal .agt-title{font:500 10.5px/1 var(--ag-mono);letter-spacing:.12em;color:var(--ag-ink)}
.ag-receipt .home-terminal .agt-progress{height:2px;background:var(--ag-ink);box-shadow:none;transition:width var(--ag-t-tick) linear,opacity var(--ag-t-step) linear}
.ag-receipt .home-terminal .agt-menu{gap:0;border-top:1px dashed var(--ag-ink)}
.ag-receipt .home-terminal .agt-item{position:relative;min-height:44px;padding:10px 12px;border:0;border-bottom:1px dashed var(--ag-ink);border-radius:0;background:transparent;transition:background-color var(--ag-t-tick) linear}
.ag-receipt .home-terminal .agt-item::after{content:"";position:absolute;left:0;right:0;bottom:-1px;height:3px;background:var(--ag-ink);opacity:0;transition:opacity var(--ag-t-tick) linear}
.ag-receipt .home-terminal .agt-item:hover,.ag-receipt .home-terminal .agt-item:focus-visible{transform:none;background:var(--ag-paper);border-color:var(--ag-ink);box-shadow:none}
.ag-receipt .home-terminal .agt-item:hover::after,.ag-receipt .home-terminal .agt-item:focus-visible::after{opacity:1}
.ag-receipt .home-terminal .agt-item:focus-visible{outline:2px solid var(--ag-ink);outline-offset:-2px}
.ag-receipt .home-terminal .agt-item:active{transform:none}
.ag-receipt .home-terminal .agt-item-n{font-weight:600}
.ag-receipt .home-terminal .agt-item-hint{font-size:1em;color:var(--ag-ink)}
.ag-receipt .home-terminal .agt-scroll:focus-visible,.ag-receipt .home-terminal .agt-link:focus-visible{border-radius:0}
/* a still block cursor: nothing loops */
.ag-receipt .home-terminal .agt-cursor{animation:none;background:var(--ag-ink)}
/* a printed line arrives in one step on the arrive curve (it was 180 to 220ms ease-out); the script's pacing is unchanged */
.ag-receipt .home-terminal .agt-in,.ag-receipt .home-terminal .agt-ask,.ag-receipt .home-terminal .agt-stop{animation-duration:var(--ag-t-step);animation-timing-function:var(--ag-ease-out)}
/* the 16th launch waiting for a person: the held mark, half filled */
.ag-receipt .home-terminal .agt-dot.agt-dot-held{position:relative;border:1px solid var(--ag-ink);background:transparent}
.ag-receipt .home-terminal .agt-dot.agt-dot-held::after{content:"";position:absolute;left:0;top:0;bottom:0;width:50%;background:var(--ag-ink)}
.ag-receipt .home-terminal .agt-badge{padding:2px 8px;border:1px solid var(--ag-stamp);background:transparent;color:var(--ag-stamp)}
.ag-receipt .home-terminal .agt-foot{min-height:0;padding:8px 12px;background:var(--ag-paper);border-top:1px solid var(--ag-ink);font:400 12px/1.5 var(--ag-mono);color:var(--ag-ink-2)}
.ag-receipt .home-terminal .agt-btn{min-height:44px;padding:0 14px}
/* the key hints are for a keyboard: on a touch screen they go, and the buttons stay */
@media (hover:none),(pointer:coarse){
  .ag-receipt .home-terminal .agt-foot-group>span:not([class]){display:none}
  .ag-receipt .home-terminal .agt-foot:has(>.agt-foot-group:first-child:not([hidden])){display:none}
}

/* ---- D. tap targets -------------------------------------------------------------------------------------------- */
.ag-receipt .watch-card button{min-height:44px}
.ag-receipt .hero-langs a{display:inline-block;padding:14px 2px;margin:-14px -2px}

/* ---- E. no scroll reveal ---------------------------------------------------------------------------------------- */
/* visual-pass.js hides each section until an observer fires (.vp-r). On this page every section is visible from the
   first paint, with or without script. */
.vp-js .vp-r{opacity:1!important;transform:none!important;transition:none!important}
