/*
 * tcna-solutions.com — the TCNA Guide in the browser (agent.js; AGENT.md §4). Loaded only while the Guide is switched on.
 *
 * The Guide is R-0, the robot that carries every request through the machine on the home page, and this is its service
 * port (31's "trip" dock, in the site's tokens): a small screwed-on plate in the lower right with R-0's red eye and its
 * name; spoken to, it opens into a terminal plate under a red strip (2.3: docked above the port on every page, at a size
 * that never changes with the scroll), the conversation in mono with "YOU ›" and the
 * Guide's name as prefixes, the chips as "›" lines. The eye's slit scans while R-0 thinks; on the home page R-0 itself
 * also turns, thinks and points in the film (agent.js sends tcna:guide events, home-film.js plays them). The intro on
 * the home gathers out of the plate as points and is scanned in by the red line; it dissolves back when you walk on.
 * Square corners, the plate's 1px steel line, mono labels at the site's condensed width (--mono-w).
 *
 *   html.gd-on          agent.js is running
 *   html.guide-open     the full panel (a phone: the sheet) is open
 *   html.gd-sheet       a phone's sheet is open: the page behind is still (agent.js locks it)
 *   html.gd-leaving     the Guide is taking the visitor to another page: nothing of it may be in the transition
 *   html.gd-dock        2.3: a desktop — the plate docks above the port (html.gd-log: LOG is open)
 *   html[data-gd]       what the Guide is doing (open · thinking · speaking · pointing · closed): the eye scans while thinking
 *   html[data-gd-status] its line to the gateway (wait · idle · busy · off): the eye goes dark while it is offline
 */

/* the Guide's surface: text always stands on a calm, uniform ground, whatever is behind (a plate, the film) */
:root {
  --gd-ground: var(--plate);
  --gd-line: rgba(143, 151, 156, .28);
  --gd-drop: 0 24px 50px -20px rgba(0, 0, 0, .9);
  --gd-pt: var(--laser);       /* the points agent.js draws (the intro's flow, the thinking line), read once at start */
  --gd-pt-hi: var(--red);
  --gd-port: "R-0 · SERVICE PORT · TTY 115200 8N1";
}

/* ---------------------------------------------------------------- the service port (the launcher) */
.gd-launch {
  position: fixed; z-index: 28; right: var(--gd-r, var(--gut)); bottom: 24px; display: flex; align-items: center; gap: 12px;
  height: 52px; padding: 0 16px 0 12px; margin: 0; border: 0; border-radius: 0; color: var(--laser); text-align: left;
  /* four screw heads in the corners of a steel-lined plate */
  background:
    radial-gradient(circle at 6px 6px, #3d4a4d 0 1.6px, transparent 2.2px),
    radial-gradient(circle at calc(100% - 6px) 6px, #3d4a4d 0 1.6px, transparent 2.2px),
    radial-gradient(circle at 6px calc(100% - 6px), #3d4a4d 0 1.6px, transparent 2.2px),
    radial-gradient(circle at calc(100% - 6px) calc(100% - 6px), #3d4a4d 0 1.6px, transparent 2.2px),
    #061416;
  box-shadow: inset 0 0 0 1px var(--gd-line), 0 18px 34px -16px rgba(0, 0, 0, .9);
  cursor: pointer; opacity: 0; visibility: hidden; transform: translate3d(0, calc(var(--gd-lift, 0px) * -1), 0);
  transition: opacity .7s var(--ease), visibility 0s linear .7s, box-shadow .3s ease, transform .5s var(--ease);
  -webkit-tap-highlight-color: transparent;
}
.gd-launch.is-in { opacity: 1; visibility: visible; transition: opacity .7s var(--ease), visibility 0s, box-shadow .3s ease, transform .5s var(--ease); }
.gd-launch:hover, .gd-launch:focus-visible { box-shadow: inset 0 0 0 1.5px var(--laser), 0 18px 34px -16px rgba(0, 0, 0, .9); }
.gd-launch:active { transform: translate3d(0, calc(var(--gd-lift, 0px) * -1), 0) scale(.97); transition-duration: .7s, 0s, .3s, .12s; }
.gd-launch[aria-expanded="true"] { box-shadow: inset 0 0 0 1px var(--red), 0 18px 34px -16px rgba(0, 0, 0, .9); }
/* the skin draws its own mark: the points' canvas stays out (agent.js then runs no frames for it) */
.gd-launch__mark { display: none; }
/* R-0's eye: a red visor with a laser slit; the slit scans while R-0 thinks */
.gd-launch::before { content: ''; flex: none; width: 30px; height: 20px; border-radius: 2px; background: var(--red); box-shadow: inset 0 -2px 0 rgba(0, 0, 0, .25); }
.gd-launch::after {
  content: ''; position: absolute; left: 22px; top: 50%; width: 10px; height: 6px; margin-top: -3px; border-radius: 1px; background: var(--laser);
  box-shadow: 0 0 0 2px #2a0d08, 0 0 8px rgba(255, 241, 214, .6); pointer-events: none;
}
/* what it is, always told (the button's own name is agent.js's aria-label) */
.gd-launch__label { display: block; font: 600 16px/1.05 var(--display); letter-spacing: 0; color: var(--laser); white-space: nowrap; pointer-events: none; }
.gd-launch__label::after {
  content: "AI agent · on"; display: block; margin-top: 3px; font: 500 10.5px/1.3 var(--mono); font-stretch: var(--mono-w);
  letter-spacing: .08em; text-transform: uppercase; color: var(--mute);
}
html[data-gd-status="off"] .gd-launch__label::after { content: "AI agent · offline"; }
html[data-gd-status="off"] .gd-launch::after { background: var(--mute-2); box-shadow: 0 0 0 2px #2a0d08; }
/* an answer arrived while the panel was closed */
.gd-launch__dot { position: absolute; top: -4px; right: -4px; width: 10px; height: 10px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 2px var(--ground); transform: scale(0); transition: transform .4s var(--ease); pointer-events: none; }
.gd-launch.has-unread .gd-launch__dot { transform: scale(1); }

/* ---------------------------------------------------------------- the terminal plate (panel, home intro card, phone sheet) */
.gd {
  position: fixed; z-index: 33; right: var(--gut); bottom: 88px; left: auto; top: auto;
  width: min(400px, calc(100vw - 2 * var(--gut)));
  max-height: min(640px, calc(100vh - var(--nav-h) - 108px));
  display: flex; flex-direction: column; margin: 0; padding: 22px 0 0;
  background: var(--gd-ground); box-shadow: inset 0 0 0 1px var(--gd-line), var(--gd-drop); color: var(--ink);
  font: 400 14.5px/1.55 var(--sans); text-align: left; transform-origin: 100% 100%;
  /* its motion is all agent.js's (Web Animations); none from CSS — not even the site's reduced-motion .01ms ones,
     which would make every measurement of it read the value before */
  transition: none;
}
.gd[hidden] { display: none !important; }
.gd:focus { outline: none; }
/* the port's strip across the top */
.gd::before {
  content: var(--gd-port); position: absolute; z-index: 3; left: 0; right: 0; top: 0; height: 22px; padding: 7px 12px 0;
  background: var(--red-fill); color: var(--laser); font: 500 8.5px/1 var(--mono); font-stretch: var(--mono-w); letter-spacing: .14em;
  white-space: nowrap; overflow: hidden; pointer-events: none;
}
/* the scan line that cuts it in and out (agent.js moves it) */
.gd__scan { position: absolute; z-index: 4; left: -6px; right: -6px; top: 0; height: 1px; background: var(--red); opacity: 0; pointer-events: none; will-change: transform, opacity; }
.gd__scan::before { content: ''; position: absolute; left: 0; right: 0; top: -14px; height: 28px; background: rgba(208, 58, 42, .08); }
.gd__scan::after { content: ''; position: absolute; left: 0; right: 0; top: -5px; height: 11px; border-left: 1px solid var(--red); border-right: 1px solid var(--red); }

/* head: R-0's eye, who, how it is, a new chat, close */
.gd__head { position: relative; flex: none; display: flex; align-items: center; gap: 6px; min-height: 52px; padding: 4px 6px 4px 14px; background: var(--plate); border-bottom: 1px solid var(--line); }
.gd__who { position: relative; display: flex; flex-direction: column; justify-content: center; gap: 6px; margin-right: auto; min-width: 0; padding-left: 42px; }
.gd__who::before { content: ''; position: absolute; left: 0; top: 50%; width: 30px; height: 20px; margin-top: -10px; border-radius: 2px; background: var(--red); box-shadow: inset 0 -2px 0 rgba(0, 0, 0, .25); }
.gd__who::after { content: ''; position: absolute; left: 10px; top: 50%; width: 10px; height: 6px; margin-top: -3px; border-radius: 1px; background: var(--laser); box-shadow: 0 0 0 2px #2a0d08, 0 0 8px rgba(255, 241, 214, .6); }
html[data-gd-status="off"] .gd__who::after { background: var(--mute-2); box-shadow: 0 0 0 2px #2a0d08; }
.gd__name { font: 600 18px/1 var(--display); letter-spacing: 0; color: var(--laser); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gd__status { display: inline-flex; align-items: center; gap: 7px; font: 500 9.5px/1 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; color: var(--mute); white-space: nowrap; }
.gd__status::before { content: ''; flex: none; width: 6px; height: 6px; border-radius: 50%; background: var(--red); }
.gd[data-status="busy"] .gd__status { color: var(--ink-2); }
.gd[data-status="busy"] .gd__status::before { animation: gd-pulse 1.3s ease-in-out infinite; }
.gd[data-status="off"] .gd__status::before { background: transparent; box-shadow: inset 0 0 0 1px var(--mute); }
.gd[data-status="wait"] .gd__status::before { background: var(--mute-2); }
@keyframes gd-pulse { 0%, 100% { opacity: 1; } 50% { opacity: .25; } }
@keyframes gd-scan { from { transform: translateX(-6px); } to { transform: translateX(6px); } }
html[data-gd="thinking"] :is(.gd-launch, .gd__who)::after { animation: gd-scan .6s ease-in-out infinite alternate; }
.gd__tool { height: 32px; padding: 0 10px; border: 0; background: none; font: 500 9.5px/1 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; color: var(--mute); cursor: pointer; white-space: nowrap; transition: color .3s; }
.gd__tool:hover { color: var(--laser); }
.gd__tool[disabled] { opacity: .35; cursor: default; color: var(--mute); }
.gd__close { position: relative; flex: none; width: 36px; height: 36px; padding: 0; border: 0; background: none; cursor: pointer; color: var(--ink-2); }
.gd__close::before, .gd__close::after { content: ''; position: absolute; left: 11px; top: 17.5px; width: 14px; height: 1.5px; background: currentColor; transform: rotate(45deg); transition: background-color .3s; }
.gd__close::after { transform: rotate(-45deg); }
.gd__close:hover { color: var(--laser); }
.gd__grab { display: none; }

/* the conversation: a terminal log */
.gd__body { position: relative; flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 16px 14px 8px; background: var(--ground); scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
.gd__body::-webkit-scrollbar { width: 6px; }
.gd__body::-webkit-scrollbar-thumb { background: var(--line-2); }
.gd__log { display: grid; gap: 18px; align-content: start; }
.gd-msg { min-width: 0; }
.gd-msg__meta { display: flex; align-items: baseline; gap: 9px; margin-bottom: 6px; font: 500 8.5px/1 var(--mono); font-stretch: var(--mono-w); letter-spacing: .14em; text-transform: uppercase; color: var(--mute); }
.gd-msg__meta b { font-weight: 500; color: var(--mute); }
.gd-msg__meta b::after { content: " ›"; }
.gd-msg__meta span { color: var(--mute-2); }
.gd-msg__body { min-width: 0; }
.gd-msg--guide .gd-msg__body { padding-left: 12px; border-left: 1px solid var(--line-2); transition: border-color .8s ease; }
.gd-msg--guide.is-live .gd-msg__body { border-left-color: var(--red); }
.gd-msg__text { font: 400 12.5px/1.6 var(--mono); font-stretch: var(--mono-w); color: var(--ink); overflow-wrap: anywhere; }
.gd-msg__text > * + * { margin-top: .62em; }
.gd-msg__text strong { color: var(--laser); font-weight: 600; }
.gd-msg__text a { color: var(--laser); text-decoration: underline; text-decoration-color: var(--red); text-decoration-thickness: 1px; text-underline-offset: 3px; transition: color .3s; }
.gd-msg__text a:hover { color: var(--red-ink); }
.gd-msg__text ul li { position: relative; padding-left: 17px; }
.gd-msg__text ul li + li, .gd-msg__text ol li + li { margin-top: .3em; }
.gd-msg__text ul li::before { content: ''; position: absolute; left: 0; top: .8em; width: 8px; height: 1px; background: var(--red); }
.gd-msg__text ol { padding-left: 0; counter-reset: gd; }
.gd-msg__text ol li { position: relative; padding-left: 26px; counter-increment: gd; }
.gd-msg__text ol li::before { content: counter(gd, decimal-leading-zero); position: absolute; left: 0; top: .3em; font: 500 10px/1 var(--mono); font-stretch: var(--mono-w); letter-spacing: .06em; color: var(--red-ink); }
/* the end of an answer still arriving: a block cursor */
.gd-msg.is-live .gd-msg__text > :last-child::after { content: ''; display: inline-block; width: 6px; height: 11px; margin-left: 4px; background: var(--red); vertical-align: -.1em; }
.gd-msg__stopped { margin-top: 8px; font: 500 9.5px/1.3 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; color: var(--mute); }
/* the visitor: a line typed into the port */
.gd-msg--you { justify-self: end; max-width: 88%; }
.gd-msg--you .gd-msg__meta b { color: var(--red-ink); }
.gd-msg--you .gd-msg__body { padding: 8px 12px; background: var(--plate-2); border-left: 3px solid var(--red); }
.gd-msg--you .gd-msg__text { color: var(--laser); white-space: pre-wrap; }
/* the Guide's lines about what it does, and the page's own notes */
.gd-act { display: flex; align-items: baseline; gap: 9px; margin-top: 11px; font: 500 10px/1.5 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-2); }
.gd-act i { flex: none; font-style: normal; color: var(--red-ink); }
.gd-act.is-off { color: var(--mute); }
.gd-msg--note { display: flex; align-items: baseline; gap: 10px; padding-left: 1px; font: 500 10px/1.5 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; color: var(--mute); }
.gd-msg--note::before { content: ''; flex: none; width: 6px; height: 6px; border-radius: 50%; background: var(--red); transform: translateY(-1px); }
.gd-msg--note.is-err { color: var(--ink-2); }
.gd-msg--note.is-err::before { background: transparent; box-shadow: inset 0 0 0 1px var(--red-ink); }
.gd-msg--note .gd-note__go { margin-left: 4px; padding: 0; border: 0; background: none; font: inherit; letter-spacing: inherit; text-transform: inherit; color: var(--laser); text-decoration: underline; text-decoration-color: var(--red); text-underline-offset: 3px; cursor: pointer; }
/* before the first words: a short river of points */
.gd-think { display: block; width: 132px; height: 16px; margin: 3px 0 2px; }

/* quick replies, close under the answer they belong to: › lines */
.gd-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: -6px; }
.gd-chip {
  display: inline-flex; align-items: baseline; gap: 7px; max-width: 100%; padding: 8px 10px 8px 9px; margin: 0; border: 0;
  background: transparent; box-shadow: inset 0 0 0 1px var(--gd-line); color: var(--ink);
  font: 400 11px/1.35 var(--mono); font-stretch: var(--mono-w); letter-spacing: .02em; text-align: left; cursor: pointer; transition: color .3s, box-shadow .3s;
}
.gd-chip::before { content: "›"; flex: none; color: var(--red-ink); }
.gd-chip b { display: none; }
.gd-chip:hover { color: var(--laser); box-shadow: inset 0 0 0 1px var(--red); }
.gd-chip:active { transform: scale(.98); }

/* thumbs */
.gd-fb { display: flex; align-items: center; gap: 2px; margin: 9px 0 0 -6px; }
.gd-fb button { display: grid; place-items: center; width: 28px; height: 24px; padding: 0; border: 0; background: none; color: var(--mute-2); cursor: pointer; transition: color .3s; }
.gd-fb button:hover { color: var(--ink-2); }
.gd-fb button[aria-pressed="true"] { color: var(--red-ink); }
.gd-fb svg { width: 13px; height: 13px; overflow: visible; }
.gd-fb span { margin-left: 6px; font: 500 9px/1 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; color: var(--mute); }

/* the composer */
.gd__form { position: relative; flex: none; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 10px; padding: 8px 8px 8px 14px; background: var(--plate); border-top: 1px solid var(--line); transition: border-color .4s ease; }
.gd__form:focus-within { border-top-color: var(--red); }
.gd__input {
  display: block; width: 100%; height: 40px; min-height: 40px; max-height: 102px; margin: 0; padding: 10px 0; border: 0; border-radius: 0;
  background: transparent; color: var(--laser); font: 400 12.5px/20px var(--mono); font-stretch: var(--mono-w); resize: none; overflow-y: hidden;
}
.gd__input::placeholder { color: var(--mute); opacity: 1; }
.gd__input:focus { outline: none; }
.gd__input[disabled] { color: var(--mute); cursor: progress; }
.gd__send {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 9px; height: 40px; min-width: 76px; padding: 0 14px; margin: 0;
  border: 0; border-radius: 0; background: var(--red-fill); color: var(--laser); font: 500 11px/1 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase;
  cursor: pointer; transition: background-color .3s, color .3s, box-shadow .3s;
}
.gd__send:hover { background: var(--red-press); }
.gd__send svg { width: 13px; height: 9px; overflow: visible; }
.gd__send[aria-disabled="true"] { background: rgba(201, 55, 42, .4); color: rgba(255, 241, 214, .7); cursor: default; }
.gd__send.is-stop { background: transparent; color: var(--laser); box-shadow: inset 0 0 0 1px var(--line-2); }
.gd__send.is-stop:hover { box-shadow: inset 0 0 0 1px var(--laser); }
.gd__send.is-stop i { width: 8px; height: 8px; background: currentColor; }
.gd__count { grid-column: 1 / -1; justify-self: end; margin: -4px 2px 0 0; font: 400 9.5px/1 var(--mono); font-stretch: var(--mono-w); letter-spacing: .08em; color: var(--mute); font-variant-numeric: tabular-nums; pointer-events: none; }
.gd__count.is-full { color: var(--red-ink); }
.gd__count[hidden] { display: none; }
.gd__note { flex: none; margin: 0; padding: 0 14px 12px; background: var(--plate); font: 400 9px/1.55 var(--mono); font-stretch: var(--mono-w); letter-spacing: .08em; text-transform: uppercase; color: var(--mute); }
.gd__note a { color: var(--ink-2); text-decoration: underline; text-decoration-color: var(--line-2); text-underline-offset: 3px; transition: color .3s; }
.gd__note a:hover { color: var(--laser); }

/* cards: a brief, a message to the studio */
.gd-card { position: relative; margin-top: 14px; padding: 14px 14px 16px; background: var(--plate); box-shadow: inset 0 0 0 1px var(--gd-line); }
.gd-card::before { content: ''; position: absolute; top: 0; left: 0; width: 22px; height: 2px; background: var(--red); }
.gd-card__top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 13px; font: 500 9.5px/1.3 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; color: var(--mute); }
.gd-card__top b { font-weight: 500; color: var(--red-ink); }
.gd-card__state { display: inline-flex; align-items: center; gap: 7px; color: var(--mute); }
.gd-card.is-sent .gd-card__state { color: var(--ink-2); }
.gd-card.is-sent .gd-card__state::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--red); }
.gd-card__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.gd-field { display: grid; gap: 5px; min-width: 0; align-content: start; }
.gd-field--wide { grid-column: 1 / -1; }
.gd-field > label { font: 500 9px/1.2 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; color: var(--mute); }
.gd-in {
  display: block; width: 100%; min-width: 0; margin: 0; padding: 8px 9px; background: var(--ground); border: 1px solid var(--line-2); border-radius: 0;
  color: var(--laser); font: 400 13.5px/1.35 var(--sans); transition: border-color .3s;
}
.gd-in:hover { border-color: var(--mute); }
.gd-in:focus { outline: none; border-color: var(--red); }
textarea.gd-in { min-height: 88px; resize: vertical; line-height: 1.45; }
select.gd-in { appearance: none; -webkit-appearance: none; padding-right: 30px; background-image: linear-gradient(45deg, transparent 50%, var(--ink-2) 50%), linear-gradient(-45deg, transparent 50%, var(--ink-2) 50%); background-position: calc(100% - 15px) 50%, calc(100% - 11px) 50%; background-size: 4px 4px; background-repeat: no-repeat; }
select.gd-in option { background: var(--plate); color: var(--ink); }
.gd-in[aria-invalid="true"] { border-color: var(--red-ink); }
.gd-in[disabled] { color: var(--mute); border-color: var(--line); cursor: default; }
.gd-field__err { font: 400 10.5px/1.35 var(--mono); font-stretch: var(--mono-w); color: var(--red-ink); }
.gd-card__err { margin-top: 10px; font: 400 11px/1.4 var(--mono); font-stretch: var(--mono-w); color: var(--red-ink); }
.gd-card__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; margin-top: 14px; }
.gd-card__actions .btn { padding: 11px 13px; font-size: 12px; }
.gd-card__actions .btn i { font-style: normal; }
.gd-card__actions .link { padding: 0 0 4px; border: 0; border-bottom: 1px solid var(--line-2); background: none; cursor: pointer; }
.gd-card__actions .link:hover { color: var(--laser); border-color: var(--laser); }
.gd-card.is-sent .gd-card__actions { display: none; }

/* 2.2.1 · a download: the card's top line (DOWNLOAD · its kind, its size), its title in the display face, what it is, the
   facts as the drive's plates print them (mono labels over values), one Download button in the port's red — the same
   control as Send. A file on another site says where it opens. Nothing downloads until the button is pressed. */
.gd-dl__t { font: 600 15px/1.25 var(--display); letter-spacing: 0; color: var(--laser); overflow-wrap: anywhere; }
.gd-dl__s { margin-top: 6px; font: 400 11.5px/1.55 var(--mono); font-stretch: var(--mono-w); color: var(--ink); overflow-wrap: anywhere; }
.gd-dl__f { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 12px 0 0; padding-top: 10px; border-top: 1px solid var(--line); }
.gd-dl__f div { display: grid; gap: 4px; min-width: 0; }
.gd-dl__f dt { font: 500 8.5px/1.2 var(--mono); font-stretch: var(--mono-w); letter-spacing: .14em; text-transform: uppercase; color: var(--mute); }
.gd-dl__f dd { margin: 0; font: 400 11.5px/1.3 var(--mono); font-stretch: var(--mono-w); color: var(--ink); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.gd-dl__acts { gap: 10px 14px; }
.gd-dl__go {
  display: inline-flex; align-items: center; gap: 10px; min-height: 40px; padding: 0 14px; background: var(--red-fill); color: var(--laser);
  font: 500 11px/1 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; text-decoration: none;
  transition: background-color .3s, box-shadow .3s;
}
.gd-dl__go:hover { background: var(--red-press); }
.gd-dl__go:focus-visible { outline: 1.5px solid var(--laser); outline-offset: 3px; }
.gd-dl__go svg { flex: none; width: 11px; height: 13px; overflow: visible; }
.gd-dl__from { font: 500 9px/1.3 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; color: var(--mute); }

/* 2.2.1 · examples: a gallery of the drive's files in two columns — each picture behind the plate's 1 px line with its
   number in the corner (the drive's way), the title in the display face, its one line; under it where it lives (↗).
   R-0 presents the card: on an inner page its lamp falls on it (.gd-hl, guide-body.js). */
.gd-ex__list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 10px; margin: 0; padding: 0; list-style: none; }
.gd-ex__i { display: grid; gap: 7px; min-width: 0; align-content: start; }
.gd-ex__a { display: grid; gap: 7px; min-width: 0; color: var(--ink); text-decoration: none; }
.gd-ex__a:focus-visible { outline: 1.5px solid var(--laser); outline-offset: 3px; }
.gd-ex__pic { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--ground); }
.gd-ex__pic img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; }
.gd-ex__pic::after { content: ''; position: absolute; inset: 0; box-shadow: inset 0 0 0 1px var(--gd-line); pointer-events: none; transition: box-shadow .3s; }
.gd-ex__a:hover .gd-ex__pic::after, .gd-ex__a:focus-visible .gd-ex__pic::after { box-shadow: inset 0 0 0 1px var(--red); }
.gd-ex__ph { position: absolute; inset: 0; display: grid; place-items: center; font: 500 8.5px/1 var(--mono); font-stretch: var(--mono-w); letter-spacing: .14em; text-transform: uppercase; color: var(--mute-2); }
.gd-ex__n { position: absolute; z-index: 1; left: 0; top: 0; padding: 4px 6px 3px; background: var(--plate); font: 500 8.5px/1 var(--mono); font-style: normal; font-stretch: var(--mono-w); letter-spacing: .1em; color: var(--red-ink); font-variant-numeric: tabular-nums; }
.gd-ex__t { font: 600 13px/1.25 var(--display); letter-spacing: 0; color: var(--laser); overflow-wrap: anywhere; transition: color .3s; }
.gd-ex__a:hover .gd-ex__t { color: var(--red-ink); }
.gd-ex__l { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; margin-top: -3px; font: 400 10.5px/1.45 var(--mono); font-stretch: var(--mono-w); color: var(--ink-2); }
.gd-ex__live { justify-self: start; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 500 9px/1.4 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-2); text-decoration: underline; text-decoration-color: var(--red); text-underline-offset: 3px; transition: color .3s; }
.gd-ex__live:hover { color: var(--laser); }
.gd-ex__live:focus-visible { outline: 1.5px solid var(--laser); outline-offset: 2px; }

/* 2.2.1 · a support request: the brief card's fields and controls, the setup on one row (system, version, host), the
   reason an email matters; sent, a line with its reference and the studio's reply time under a red dot */
.gd-sup__env { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .8fr) minmax(0, 1fr); gap: 10px; }
.gd-sup__hint { margin-top: 10px; font: 400 10.5px/1.45 var(--mono); font-stretch: var(--mono-w); color: var(--mute); }
.gd-sup__done { display: flex; gap: 9px; margin-top: 12px; font: 500 11.5px/1.5 var(--mono); font-stretch: var(--mono-w); color: var(--laser); }
.gd-sup__done::before { content: ''; flex: none; width: 6px; height: 6px; margin-top: .55em; border-radius: 50%; background: var(--red); }
.gd-sup__done:empty { display: none; }
.gd-card.is-sent .gd-sup__hint { display: none; }

/* 2.3 · a field the Guide filled in on the page's own form (/brief, /support): a quiet line under it in the plates' mono
   — "Filled in by the Guide", read with the field (aria-describedby) — and a red edge on the field; both go as soon as
   the visitor changes it. Only while the Guide is on (this file): without it the forms are as they always were. */
.gd-filled { display: flex; align-items: center; gap: 8px; margin: 0; font: 500 9.5px/1.4 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-2); }
.gd-filled i { flex: none; width: 6px; height: 6px; background: var(--red); }
.opts .gd-filled { margin-top: 10px; }
.field__input[data-gd-filled] { box-shadow: inset 3px 0 0 var(--red), inset 0 0 0 1px var(--line-2); }
.field__input[data-gd-filled]:focus { box-shadow: inset 3px 0 0 var(--red), inset 0 0 0 1px var(--laser), 0 0 0 1px var(--laser); }

/* 2.2.1 · a page tour's own chips: "Next ›" carries its arrow itself (no › before it), "Stop the tour" is the quiet one */
.gd-chip--next::before { content: none; }
.gd-chip--next { color: var(--laser); box-shadow: inset 0 0 0 1px var(--red); }
.gd-chip--stop { color: var(--ink-2); }
.gd-chip--stop::before { content: "×"; content: "×" / ""; color: var(--mute); }   /* (the mark is not read out) */

/* the home intro: the same plate, compact — the greeting, the chips, the field; its close in the corner under the strip */
.gd[data-mode="intro"] { left: var(--gd-ix, auto); top: var(--gd-iy, auto); right: auto; bottom: auto; width: var(--gd-iw, min(400px, calc(100vw - 2 * var(--gut)))); max-height: none; }
.gd[data-mode="intro"] .gd__head { position: absolute; z-index: 2; top: 22px; right: 0; min-height: 0; padding: 0; border: 0; background: none; }
.gd[data-mode="intro"] .gd__who, .gd[data-mode="intro"] .gd__new { display: none; }
.gd[data-mode="intro"] .gd__close { width: 40px; height: 40px; }
.gd[data-mode="intro"] .gd__close::before, .gd[data-mode="intro"] .gd__close::after { left: 13px; top: 19.5px; }
.gd[data-mode="intro"] .gd__body { overflow: visible; padding: 14px 44px 6px 14px; background: var(--plate); }
.gd[data-mode="intro"] .gd__log { gap: 0; }
.gd[data-mode="intro"] .gd-msg:not(.gd-msg--greet) { display: none; }
.gd[data-mode="intro"] .gd-msg--greet .gd-msg__meta { display: none; }
.gd[data-mode="intro"] .gd-msg--greet .gd-msg__text { color: var(--laser); font-size: 13px; line-height: 1.55; }
.gd.is-short[data-mode="intro"] .gd-greet__b { display: none; }   /* a short screen: the first sentence only */
.gd[data-mode="intro"] .gd-chips { margin: 11px -28px 0 0; gap: 5px; }
.gd[data-mode="intro"] .gd-chip { padding: 6px 9px 7px 8px; gap: 6px; font-size: 10.5px; }
.gd[data-mode="intro"] .gd__note { letter-spacing: .05em; padding-bottom: 11px; }

/* ---------------------------------------------------------------- 2.3 · the dock: the plate docked above the port
   On a desktop the plate opens out of the service port and stays there — at the gutter, 12 px above the port — on every
   page and at every scroll position, through tours, highlights, journeys and streaming. It is the bubble's compact plate
   (2.2): the exchange under way (the visitor's last line, the answer arriving), the chips as › lines, the field; LOG opens
   the whole conversation and grows the plate upward in place. Its size is fixed per page and window (agent.js
   dockMeasure(): --gd-r its right edge, --gd-dw its width, --gd-dh its height, --gd-dhl LOG's): nothing in it moves it.
   A short exchange sits on the field, as a terminal's last lines do. On an inner page R-0 stands on its top edge. */
.gd[data-mode="dock"] {
  left: auto; top: auto; right: var(--gd-r, var(--gut)); bottom: 88px;
  width: var(--gd-dw, min(372px, calc(100vw - 2 * var(--gut)))); height: var(--gd-dh, 420px); max-height: none; transform-origin: 100% 100%;
}
.gd[data-mode="dock"].is-log { height: var(--gd-dhl, 600px); }
.gd[data-mode="dock"]:not(.is-log) .gd__log.has-now > .gd-msg:not(.is-now),
.gd[data-mode="dock"]:not(.is-log) .gd__log.has-now > .gd-msg--greet { display: none; }
.gd[data-mode="dock"] .gd__head { min-height: 46px; }
.gd[data-mode="dock"] .gd__body { display: flex; flex-direction: column; padding: 14px 14px 8px; }
.gd[data-mode="dock"] .gd__log { margin-top: auto; }
.gd[data-mode="dock"] .gd-msg__text { font-size: 12.5px; }
.gd[data-mode="dock"] .gd__note { padding-bottom: 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gd__logbtn b { margin-left: 7px; font-weight: 500; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.gd__logbtn[aria-expanded="true"] { color: var(--laser); }
.gd__logbtn[aria-expanded="true"] b { color: var(--red-ink); }
.gd:not([data-mode="dock"]) .gd__logbtn, .gd__logbtn[hidden] { display: none; }
/* the home's locators beside the docked plate: the parts list ends above it (--gd-bom); the map and the list step aside
   while LOG is open, or when the map would leave the plate too little room (gd-loc-away). 2.2.1's room at the first
   stop (home-film.js hides the locators while the Guide is open there, for the bubble beside R-0) no longer applies:
   the plate is docked, so they stay. */
@media (min-width: 768px) {
  html.guide-open.gd-dock .trip .bom { max-height: var(--gd-bom, calc(100vh - 24px)); }
  html.guide-open.gd-log .trip :is(.rt, .bom), html.guide-open.gd-dock.gd-loc-away .trip :is(.rt, .bom) { opacity: 0; visibility: hidden; transition: opacity .25s, visibility 0s linear .25s; }
  html[data-loc="map"] .trip.gd-room .rt[hidden], html[data-loc="cable"] .trip.gd-room .cbl[hidden], html[data-loc="parts"] .trip.gd-room .bom[hidden] { display: block !important; }
}
/* 2.3 · while the Guide fills in a form with the visitor: one quiet line above the field — "BRIEF · 04 OF 06" */
.gd-fp { flex: none; display: flex; align-items: center; gap: 9px; margin: 0; padding: 7px 14px; background: var(--plate-2); border-top: 1px solid var(--line); font: 500 9.5px/1.3 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.gd-fp::before { content: ''; flex: none; width: 14px; height: 2px; background: var(--red); }
.gd-fp[hidden] { display: none; }
.gd-act--form i { color: var(--red-ink); }
/* a tour: its stop of how many and the stop's name, back, on, end */
.gd-tour { flex: none; display: flex; align-items: center; gap: 8px; padding: 7px 8px 7px 14px; background: var(--plate-2); border-top: 1px solid var(--line); font: 500 9.5px/1.3 var(--mono); font-stretch: var(--mono-w); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-2); }
.gd-tour[hidden] { display: none; }
.gd-tour__k { color: var(--red-ink); white-space: nowrap; }
.gd-tour__n { font-weight: 500; color: var(--laser); font-variant-numeric: tabular-nums; }
.gd-tour__t { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 400 11px/1.3 var(--mono); font-stretch: var(--mono-w); letter-spacing: .02em; text-transform: none; color: var(--ink); }
.gd-tour__b { flex: none; min-width: 30px; height: 28px; padding: 0 9px; margin: 0; border: 0; background: none; box-shadow: inset 0 0 0 1px var(--gd-line); color: var(--ink); font: inherit; letter-spacing: inherit; text-transform: inherit; cursor: pointer; transition: box-shadow .3s, color .3s; }
.gd-tour__b:hover { box-shadow: inset 0 0 0 1px var(--red); color: var(--laser); }
.gd-tour__b[disabled] { opacity: .35; cursor: default; box-shadow: inset 0 0 0 1px var(--gd-line); color: var(--ink); }

/* the points between the port and the plate while it gathers or dissolves */
.gd-flow { position: fixed; z-index: 32; left: 0; top: 0; pointer-events: none; }
.gd-live { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.gd-scrim { display: none; }

/* never in a page transition: neither photographed nor floating over it; never over the open menu; never printed */
html.transit-in :is(.gd-launch, .gd, .gd-flow, .gd-scrim), html.transit-out :is(.gd-launch, .gd, .gd-flow, .gd-scrim),
html.gd-leaving :is(.gd-launch, .gd, .gd-flow, .gd-scrim) { visibility: hidden !important; opacity: 0 !important; transition: none !important; }
html.menu-open :is(.gd-launch, .gd, .gd-flow) { visibility: hidden !important; }
@media print { .gd-launch, .gd, .gd-scrim, .gd-flow, .gd-filled { display: none !important; } }

/* ---------------------------------------------------------------- a phone */
@media (max-width: 767.98px) {
  /* the port in the lower right corner, the eye alone (the header's right end is the menu's) */
  .gd-launch { right: 12px; bottom: calc(env(safe-area-inset-bottom, 0px) + 10px); height: 40px; padding: 0 9px; gap: 0; box-shadow: inset 0 0 0 1px var(--gd-line), 0 12px 26px -12px rgba(0, 0, 0, .9); }
  .gd-launch::before { width: 26px; height: 18px; }
  .gd-launch::after { left: 17px; }
  .gd-launch__label { display: none; }
  .gd { width: auto; left: 12px; right: 12px; bottom: calc(env(safe-area-inset-bottom, 0px) + 60px); max-height: calc(100vh - var(--nav-h) - 84px); }
  /* the phone's intro: across the screen, one sentence, a row of chips that scrolls sideways, the field */
  .gd[data-mode="intro"] { left: 12px; right: 12px; top: var(--gd-iy, auto); width: auto; }
  .gd[data-mode="intro"] .gd__body { padding: 11px 44px 4px 14px; }
  .gd[data-mode="intro"] .gd-msg--greet .gd-msg__text { font-size: 13px; line-height: 1.55; }
  .gd[data-mode="intro"] .gd-greet__b { display: none; }   /* its first sentence; the rest is in the sheet */
  .gd[data-mode="intro"] .gd-chips { flex-wrap: nowrap; overflow-x: auto; margin: 10px -44px 0 -14px; padding: 0 14px 2px; scrollbar-width: none; overscroll-behavior-x: contain; }
  .gd[data-mode="intro"] .gd-chips::-webkit-scrollbar { display: none; }
  .gd[data-mode="intro"] .gd-chip { flex: none; white-space: nowrap; }
  .gd[data-mode="intro"] .gd__note { display: none; }
  /* the sheet: most of the screen, above the safe area and the keyboard */
  .gd.is-sheet {
    z-index: 35; left: 0; right: 0; top: auto; bottom: var(--gd-kb, 0px); width: auto;
    height: 66vh; height: min(66dvh, calc(var(--gd-vh, 100dvh) - 8px)); max-height: none;
    padding-bottom: env(safe-area-inset-bottom, 0px); box-shadow: inset 0 1px 0 var(--line-2); background: var(--gd-ground);
  }
  .gd.is-sheet .gd__head { min-height: 58px; padding-top: 10px; touch-action: none; }
  .gd.is-sheet .gd__grab { display: block; position: absolute; left: 50%; top: 5px; width: 36px; height: 3px; margin-left: -18px; background: var(--line-2); }
  .gd.is-sheet .gd__body { padding: 16px 14px 8px; }
  .gd.is-sheet .gd__input { font-size: 16px; }   /* 16px: the phone does not zoom into the field */
  /* fingers: the sheet's controls are at least 40px */
  .gd.is-sheet .gd-chip { min-height: 40px; align-items: center; font-size: 12px; }
  .gd.is-sheet .gd-fb button { width: 40px; height: 36px; }
  .gd.is-sheet .gd__tool { height: 44px; }
  .gd.is-sheet .gd__close { width: 44px; height: 44px; }
  .gd.is-sheet .gd__close::before, .gd.is-sheet .gd__close::after { left: 15px; top: 21.5px; }
  .gd.is-sheet .gd-in { font-size: 16px; }
  .gd.is-sheet .gd-dl__go { min-height: 44px; }
  .gd.is-sheet .gd-ex__live { padding: 6px 0; }
  .gd-sup__env { grid-template-columns: minmax(0, 1fr); }
  .gd-scrim { display: block; position: fixed; inset: 0; z-index: 33; background: rgba(4, 16, 18, .72); touch-action: none; -webkit-tap-highlight-color: transparent; }
  .gd-scrim[hidden] { display: none; }
  .gd-card__grid { grid-template-columns: minmax(0, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
  .gd[data-status="busy"] .gd__status::before { animation: none; opacity: .6; }
  html[data-gd="thinking"] :is(.gd-launch, .gd__who)::after { animation: none; }
}

/* ---------------------------------------------------------------- 2.2 · R-0 on the page: the companion (guide-body.js)
   2.3: R-0 lives on the surface it stands on. On the page its box is part of the page: the layer spans the document
   (guide-body.js sets its height; it clips R-0 to the document, so R-0 never makes the page longer or wider) and a scroll
   carries R-0 with the page, in the same frame. On the chat panel's top edge and a phone's sheet the box is fixed to the
   window (.is-fixed; .is-over: above the panel — never under it — its hit area off, so it never takes the panel's
   clicks). No fades: it leaps on and off. Its lamp's beam is an SVG cone of laser cream at plain alpha (no blending over
   anything), lying on the page with it; .gd-r0__shade is its shadow on the page while it leaps; what it shows gets a
   laser-cream outline. */
/* (under the sticky header like the rest of the page — a scroll can carry R-0 there for a frame, it never walks there — and
   over the service port; the panel and the sheet stay above it) */
.gd-r0-layer { position: absolute; z-index: 29; left: 0; top: 0; width: 100%; height: 100vh; overflow: clip; pointer-events: none; }
.gd-r0 { position: absolute; left: 0; top: 0; width: 260px; height: 232px; pointer-events: none; visibility: hidden; will-change: transform; }
.gd-r0.is-fixed { position: fixed; z-index: 31; }
.gd-r0.is-over { z-index: 34; }
.gd-r0.is-shown.is-on { visibility: visible; }
.gd-r0__cv, .gd-r0__img { position: absolute; left: 0; top: 0; width: 100%; height: 100%; display: block; }
.gd-r0__img { object-fit: contain; }
.gd-r0__hit { position: absolute; left: 31%; top: 30%; width: 38%; height: 42%; pointer-events: auto; cursor: pointer; }
.gd-r0.is-over .gd-r0__hit { pointer-events: none; }
.gd-r0__shade { position: absolute; left: 0; top: 0; width: 132px; height: 46px; margin: -23px 0 0 -66px; border-radius: 50%; background: radial-gradient(closest-side, rgba(2, 9, 10, .5), rgba(2, 9, 10, .22) 55%, rgba(2, 9, 10, 0)); opacity: 0; pointer-events: none; will-change: transform, opacity; }
.gd-beam { position: absolute; left: 0; top: 0; pointer-events: none; opacity: 0; overflow: visible; }
.gd-beam__axis { stroke: rgba(255, 241, 214, .32); stroke-width: 1; stroke-dasharray: 2 5; }
.gd-hl { outline: 1.5px solid var(--laser) !important; outline-offset: 6px; box-shadow: 0 0 0 6px rgba(255, 241, 214, .05); transition: outline-color .3s, box-shadow .3s; }
/* QA (?r0dock=panel, ?qa=slide): where a docked chat panel would be, before agent.js docks it */
.gd-r0-demo { position: fixed; z-index: 32; box-shadow: inset 0 0 0 1px rgba(255, 241, 214, .55); background: rgba(16, 26, 28, .55); pointer-events: none; }
html.transit-in :is(.gd-r0-layer, .gd-r0, .gd-beam), html.transit-out :is(.gd-r0-layer, .gd-r0, .gd-beam), html.menu-open :is(.gd-r0-layer, .gd-r0, .gd-beam) { visibility: hidden !important; opacity: 0 !important; }
@media print { .gd-r0-layer, .gd-r0, .gd-beam, .gd-r0-demo { display: none !important; } }
/* a phone's sheet as a strip while R-0 shows things on the page (agent.js peek()): the page above scrolls again */
@media (max-width: 767.98px) {
  .gd.is-sheet.is-peek { height: min(42dvh, calc(var(--gd-vh, 100dvh) - 8px)); box-shadow: inset 0 1px 0 var(--line-2), 0 -18px 40px -24px rgba(0, 0, 0, .9); }
  .gd.is-sheet.is-peek .gd__grab { background: var(--red); }
  .gd.is-sheet.is-peek .gd__log.has-now > .gd-msg:not(.is-now), .gd.is-sheet.is-peek .gd__log.has-now > .gd-msg--greet { display: none; }
}
/* a phone's sheet: R-0 stands on its top edge, in front of the page's veil and behind the sheet (it peeks over it) */
.gd-r0.is-sheet { z-index: 34; }
html.gd-sheet .gd-beam { display: none; }
