/* Portal setup walkthrough (/walkthrough). CSS only: the portal's CSP allows no scripts. The server appends the
   timing rules (.a<n> line delays, .sc<n> scene windows, .st<n> step highlights) from src/portal/walkthrough.js.
   Longhand animation properties only, so those delay classes are never reset by a shorthand. */
@keyframes wt-on { to { opacity: 1; } }
@keyframes wt-off { to { opacity: 0; } }
@keyframes wt-grow { to { width: 100%; } }
@keyframes wt-hl { to { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); } }
@keyframes wt-done { to { background: var(--accent-soft); border-color: var(--accent-soft); color: var(--cyan); } }

.wt { max-width: 900px; }
.wt-intro { font-size: 13px; margin: 0 0 4px; }
.wt-controls { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0; }
.wt-toggle { position: absolute; opacity: 0; width: 1px; height: 1px; }
.wt-toggle:focus-visible ~ .wt-controls label { outline: 2px solid var(--accent); outline-offset: 1px; }
.wt-when-paused { display: none; }
.wt-toggle:checked ~ .wt-controls .wt-when-playing { display: none; }
.wt-toggle:checked ~ .wt-controls .wt-when-paused { display: inline; }
.wt-toggle:checked ~ .wt-player, .wt-toggle:checked ~ .wt-player * { animation-play-state: paused; }

.wt-steps { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 0 0 12px; }
.wt-step { font-size: 12.5px; padding: 4px 10px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); color: var(--text-2);
  animation-name: wt-hl, wt-done; animation-duration: .3s, .3s; animation-fill-mode: forwards, forwards; }

/* The terminal looks like Cloud Shell. */
.wt-term { background: #05080d; border: 1px solid var(--border-strong); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.wt-titlebar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; background: var(--surface-2); color: var(--muted); font-size: 12px; }
.wt-titlebar i { width: 10px; height: 10px; border-radius: 50%; background: #4a4a4a; }
.wt-titlebar span { margin-left: 8px; }
.wt-screen { display: grid; padding: 14px 16px 18px; min-height: 300px; font-family: var(--mono); font-size: 13px; line-height: 1.55; color: #cccccc; }
.wt-scene { grid-area: 1 / 1; min-width: 0; }
.wt-line { white-space: pre-wrap; overflow-wrap: anywhere; min-height: 1.55em; }
.c-cyan { color: #3bc7e0; }
.c-green { color: #3fcf6b; }
.c-yellow { color: #e5d36a; }
.c-dim { color: #8b8b8b; }
.c-typed { color: #ffffff; }
.c-code { color: #ffffff; font-weight: 600; }
.wt-note { color: #9a9a9a; font-style: italic; }
.wt-phone { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; width: min(300px, 100%); margin: 28px auto; padding: 22px 18px;
  background: #f2f2f7; color: #111111; border-radius: 26px; font-family: system-ui, -apple-system, "Segoe UI", sans-serif; white-space: normal; }
.wt-phone-from { font-weight: 600; font-size: 13px; color: #555555; }
.wt-bubble { background: #e5e5ea; border-radius: 16px; padding: 8px 12px; font-size: 14px; line-height: 1.4; }

.wt-captions { display: grid; margin-top: 12px; }
.wt-caption { grid-area: 1 / 1; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 14px; font-size: 14px; line-height: 1.5; }
.wt-progress { height: 4px; margin-top: 12px; background: var(--grid); border-radius: 2px; overflow: hidden; }
.wt-progress > span { display: block; width: 0; height: 100%; background: var(--accent);
  animation-name: wt-grow; animation-timing-function: linear; animation-fill-mode: forwards; }

/* Timeline: everything starts hidden and appears at its delay; scenes and captions also leave at theirs. */
.wt-player .r { opacity: 0; animation-name: wt-on; animation-duration: .01s; animation-fill-mode: forwards; }
.wt-player .wt-scene, .wt-player .wt-caption { opacity: 0; animation-name: wt-on, wt-off; animation-duration: .25s, .25s; animation-fill-mode: forwards, forwards; }

/* Read as text: every scene, fully shown, one after another. */
.wt-text h2 { margin: 28px 0 4px; }
.wt-text h3 { margin: 16px 0 4px; font-size: 15px; }
.wt-text p { margin: 0 0 8px; }
.wt-static .wt-screen { min-height: 0; }
.wt-reduced { display: none; }

@media (prefers-reduced-motion: reduce) {
  .wt-player, .wt-controls, .wt-toggle { display: none; }
  .wt-reduced { display: block; }
  .wt-text .wt-controls { display: flex; }
}
@media (max-width: 640px) {
  .wt-screen { font-size: 11px; padding: 10px 10px 14px; }
}

.a13{animation-delay:1.3s}
.a19{animation-delay:1.9s}
.a24{animation-delay:2.4s}
.a83{animation-delay:8.3s}
.a88{animation-delay:8.8s}
.a89{animation-delay:8.9s}
.a90{animation-delay:9s}
.a91{animation-delay:9.1s}
.a92{animation-delay:9.2s}
.a93{animation-delay:9.3s}
.a94{animation-delay:9.4s}
.a95{animation-delay:9.5s}
.a96{animation-delay:9.6s}
.a97{animation-delay:9.7s}
.a98{animation-delay:9.8s}
.a99{animation-delay:9.9s}
.a100{animation-delay:10s}
.a101{animation-delay:10.1s}
.a102{animation-delay:10.2s}
.a103{animation-delay:10.3s}
.a104{animation-delay:10.4s}
.a105{animation-delay:10.5s}
.a106{animation-delay:10.6s}
.a107{animation-delay:10.7s}
.a108{animation-delay:10.8s}
.a109{animation-delay:10.9s}
.a110{animation-delay:11s}
.a111{animation-delay:11.1s}
.a112{animation-delay:11.2s}
.a113{animation-delay:11.3s}
.a114{animation-delay:11.4s}
.a115{animation-delay:11.5s}
.a116{animation-delay:11.6s}
.a117{animation-delay:11.7s}
.a118{animation-delay:11.8s}
.a119{animation-delay:11.9s}
.a128{animation-delay:12.8s}
.a133{animation-delay:13.3s}
.a145{animation-delay:14.5s}
.a151{animation-delay:15.1s}
.a156{animation-delay:15.6s}
.a162{animation-delay:16.2s}
.a174{animation-delay:17.4s}
.a232{animation-delay:23.2s}
.a238{animation-delay:23.8s}
.a243{animation-delay:24.3s}
.a249{animation-delay:24.9s}
.a254{animation-delay:25.4s}
.a260{animation-delay:26s}
.a318{animation-delay:31.8s}
.a324{animation-delay:32.4s}
.a329{animation-delay:32.9s}
.a351{animation-delay:35.1s}
.a410{animation-delay:41s}
.a415{animation-delay:41.5s}
.a421{animation-delay:42.1s}
.a426{animation-delay:42.6s}
.a484{animation-delay:48.4s}
.a559{animation-delay:55.9s}
.a564{animation-delay:56.4s}
.a565{animation-delay:56.5s}
.a566{animation-delay:56.6s}
.a567{animation-delay:56.7s}
.a568{animation-delay:56.8s}
.a569{animation-delay:56.9s}
.a570{animation-delay:57s}
.a571{animation-delay:57.1s}
.a572{animation-delay:57.2s}
.a573{animation-delay:57.3s}
.a574{animation-delay:57.4s}
.a575{animation-delay:57.5s}
.a576{animation-delay:57.6s}
.a577{animation-delay:57.7s}
.a578{animation-delay:57.8s}
.a579{animation-delay:57.9s}
.a580{animation-delay:58s}
.a581{animation-delay:58.1s}
.a582{animation-delay:58.2s}
.a583{animation-delay:58.3s}
.a584{animation-delay:58.4s}
.a585{animation-delay:58.5s}
.a586{animation-delay:58.6s}
.a587{animation-delay:58.7s}
.a588{animation-delay:58.8s}
.a589{animation-delay:58.9s}
.a590{animation-delay:59s}
.a591{animation-delay:59.1s}
.a592{animation-delay:59.2s}
.a593{animation-delay:59.3s}
.a594{animation-delay:59.4s}
.a602{animation-delay:60.2s}
.a614{animation-delay:61.4s}
.a620{animation-delay:62s}
.a625{animation-delay:62.5s}
.a631{animation-delay:63.1s}
.a636{animation-delay:63.6s}
.a642{animation-delay:64.2s}
.a647{animation-delay:64.7s}
.a653{animation-delay:65.3s}
.a665{animation-delay:66.5s}
.a723{animation-delay:72.3s}
.a729{animation-delay:72.9s}
.a734{animation-delay:73.4s}
.a740{animation-delay:74s}
.a745{animation-delay:74.5s}
.a751{animation-delay:75.1s}
.a756{animation-delay:75.6s}
.a762{animation-delay:76.2s}
.a820{animation-delay:82s}
.a893{animation-delay:89.3s}
.a898{animation-delay:89.8s}
.a899{animation-delay:89.9s}
.a900{animation-delay:90s}
.a901{animation-delay:90.1s}
.a902{animation-delay:90.2s}
.a903{animation-delay:90.3s}
.a904{animation-delay:90.4s}
.a905{animation-delay:90.5s}
.a906{animation-delay:90.6s}
.a907{animation-delay:90.7s}
.a908{animation-delay:90.8s}
.a909{animation-delay:90.9s}
.a910{animation-delay:91s}
.a911{animation-delay:91.1s}
.a912{animation-delay:91.2s}
.a913{animation-delay:91.3s}
.a914{animation-delay:91.4s}
.a915{animation-delay:91.5s}
.a916{animation-delay:91.6s}
.a917{animation-delay:91.7s}
.a925{animation-delay:92.5s}
.a937{animation-delay:93.7s}
.a943{animation-delay:94.3s}
.a948{animation-delay:94.8s}
.a954{animation-delay:95.4s}
.a959{animation-delay:95.9s}
.a965{animation-delay:96.5s}
.a970{animation-delay:97s}
.a1029{animation-delay:102.9s}
.a1034{animation-delay:103.4s}
.a1040{animation-delay:104s}
.a1045{animation-delay:104.5s}
.sc0{animation-delay:0.5s,7.5s}
.sc1{animation-delay:7.5s,22.4s}
.sc2{animation-delay:22.4s,31s}
.sc3{animation-delay:31s,40.2s}
.sc4{animation-delay:40.2s,47.6s}
.sc5{animation-delay:47.6s,55.1s}
.sc6{animation-delay:55.1s,71.5s}
.sc7{animation-delay:71.5s,81.2s}
.sc8{animation-delay:81.2s,88.5s}
.sc9{animation-delay:88.5s,102.1s}
.sc10{animation-delay:102.1s,100000s}
.st0{animation-delay:7.5s,40.2s}
.st1{animation-delay:40.2s,55.1s}
.st2{animation-delay:55.1s,88.5s}
.st3{animation-delay:88.5s,102.1s}
.st4{animation-delay:102.1s,109.6s}
.wt-progress>span{animation-duration:109.6s}
