/* The fork's chat in DS1 track A "Full width" (decisions item 328; handoff/ds1/A1/full-width/note.md): the
   conversation, Coach's buttons, the vote row, the widget head, scene replies, the message box and Latest. Linked only
   while config fork.live is on, after fork-skin.css (whose tokens it uses); fork-skin-map.css follows it.
   Every rule starts with body[data-fork="1"], usually with #messages, so it outranks coach.css's layered bubble rules
   (some carry an ID, e.g. `#messages .char-bubble`). Rules do not set `display` on anything the app shows or hides
   with the hidden attribute or a class, so those switches keep working. */

/* ---- The conversation. A phone: the page margins are 14 px (--ui-gut), so Coach's text is 362 px wide at 390 and a
   formula, figure or widget can run from edge to edge; a wide screen: the 680 px column (fork-skin.css). ---- */
body[data-fork="1"] #messages {
  --gutter: 0px; gap: 14px; margin: 0; padding: var(--ui-s-3) var(--ui-gut) var(--ui-s-2); font-family: var(--ui-font);
  font-size: var(--ui-t-read); line-height: 1.45; color: var(--ui-ink);
}
@media (min-width: 700px) {
  /* coach.css keeps 14 px at the right for the scroll bar (margin -14px, padding 14px); the column keeps that. */
  body[data-fork="1"].shell-on #messages { margin-right: -14px; padding: var(--ui-s-6) 14px var(--ui-s-5) 0; }
}
body[data-fork="1"] #messages .history-status { min-height: 36px; padding: 8px; font-size: var(--ui-t-foot); color: var(--ui-ink-2); }
body[data-fork="1"] #messages .day-divider { gap: var(--ui-s-3); margin: 6px 0 0; color: var(--ui-ink-2); font-size: var(--ui-t-cap); font-weight: 600; }
body[data-fork="1"] #messages .day-divider::before, body[data-fork="1"] #messages .day-divider::after { border-top-color: var(--ui-line); }

/* Coach's reply: no box, padding, tail or gutter (A1 "No bubble"); text across the column. */
body[data-fork="1"] #messages .bubble.assistant:not(.char-bubble) {
  align-self: stretch; width: auto; max-width: none; min-width: 0; margin: 0; padding: 0; border: 0; border-radius: 0;
  background: none; box-shadow: none; color: var(--ui-ink); font-size: var(--ui-t-read); line-height: 1.45;
}
body[data-fork="1"] #messages .bubble.assistant::after { content: none; }
body[data-fork="1"] #messages .markdown-content p { margin: 0 0 var(--ui-s-2); }
body[data-fork="1"] #messages .markdown-content p:last-child { margin-bottom: 0; }
body[data-fork="1"] #messages .markdown-content a { color: var(--ui-accent); }
body[data-fork="1"] #messages .markdown-content code, body[data-fork="1"] #messages .markdown-content pre,
body[data-fork="1"] #messages .markdown-content th { background: var(--ui-bg-2); color: var(--ui-ink); }
body[data-fork="1"] #messages .markdown-content pre code { background: transparent; }
body[data-fork="1"] #messages .markdown-content pre { border-radius: var(--ui-r-2); }
body[data-fork="1"] #messages .markdown-content blockquote { border-left-color: var(--ui-line-2); color: var(--ui-ink-2); }
body[data-fork="1"] #messages .table-scroll { border-color: var(--ui-line); border-radius: var(--ui-r-2); }
body[data-fork="1"] #messages .markdown-content th, body[data-fork="1"] #messages .markdown-content td { border-color: var(--ui-line); }
/* Inline maths keeps the punctuation after it on its line (review 2 "A1 full-width" 8): fork-skin.js wraps the two. */
body[data-fork="1"] .fk-glue { white-space: nowrap; }
/* Only the join is unbreakable: a long formula inside still wraps where KaTeX lets it (critic, round 1). */
body[data-fork="1"] .fk-glue > span { white-space: normal; }

/* Coach's face: 20 px at the start of the reply's first line, costing no height (A1 "Who spoke"); out of the 44 px
   gutter (coach.css:187). Gate F = FIRST (planner, Nov 18): a run of Coach's bubbles shows it on the first, so it
   shows which persona speaks as the reply starts and never moves while rows arrive. The ID outranks coach.css:188,
   which hid it on all but the last; the run rules below hide it after the first. A block that cannot flow beside
   the face (a formula, a list, a figure) starts under it. */
body[data-fork="1"] #messages .bubble.assistant > .coach-avatar {
  display: block; float: left; position: static; width: 20px; height: 20px; margin: 1px var(--ui-s-2) 0 0;
  border-radius: 50%; object-fit: cover;
}
body[data-fork="1"] #messages .bubble.assistant > .coach-avatar ~ .markdown-content > :first-child:not(p),
body[data-fork="1"] #messages .bubble.assistant > .coach-avatar ~ :not(.markdown-content):not(.draft-content):not(.role):not(.sr-only) {
  clear: left;
}
body[data-fork="1"] #messages > .bubble.assistant + .bubble.assistant:not(.char-bubble) > .coach-avatar { display: none; }

/* The student's words: a light-tinted bubble at the right (owner, Nov 18 ~15:35Z; A1 plain-page .me), 7 px by 12 px
   of padding, 10 px corners, no tail; a run of them sits 6 px apart. */
body[data-fork="1"] #messages .bubble.user {
  align-self: flex-end; max-width: 86%; margin: 0; padding: 7px var(--ui-s-3); border: 0; border-radius: var(--ui-r-3);
  background: var(--ui-me-bg); color: var(--ui-ink); box-shadow: none; font-size: var(--ui-t-read); line-height: 1.35;
}
body[data-fork="1"] #messages .bubble.user::after { content: none; }
body[data-fork="1"] #messages .bubble.user + .bubble.user { margin-top: -8px; }
body[data-fork="1"] #messages .bubble.user a { color: var(--ui-accent); }
@media (min-width: 700px) {
  body[data-fork="1"] #messages .bubble.user { max-width: 76%; }
}

/* ---- Formulas, figures and widgets: from edge to edge on a phone between two hairlines, with no frame or corner;
   framed in the column on a wide screen (6 px corner, 1 px line, at most 640 px). A display formula has the
   screen's full width before it scrolls. Plates are --ui-fig (white; light grey in dark mode). ---- */
body[data-fork="1"] #messages .markdown-content .hscroll:has(> .katex-display) {
  max-width: none; margin-left: calc(-1 * var(--ui-gut)); margin-right: calc(-1 * var(--ui-gut));
}
body[data-fork="1"] #messages .markdown-content .katex-display { margin: var(--ui-s-2) 0; padding: 2px 0; }
body[data-fork="1"] #messages .bubble.assistant > .coach-widget:not(.widget-fullscreen) {
  width: auto; max-width: none; margin: var(--ui-s-3) calc(-1 * var(--ui-gut)) 0; border: solid var(--ui-line);
  border-width: 1px 0; border-radius: 0; background: var(--ui-bg); box-shadow: none;
}
/* The frame says it is light, as the library's pages and drawings are: a frame whose page has no ground of its own
   then shows the plate, where a dark page would have the browser paint the frame's canvas opaque white. */
body[data-fork="1"] #messages .coach-widget iframe { background: var(--ui-fig); color-scheme: light; }
body[data-fork="1"] #messages .bubble.assistant > img.diagram {
  display: block; width: calc(100% + 2 * var(--ui-gut)); max-width: none; height: auto;
  margin: var(--ui-s-3) calc(-1 * var(--ui-gut)) 0; border: solid var(--ui-line); border-width: 1px 0;
  border-radius: 0; background: var(--ui-fig);
}
@media (min-width: 700px) {
  body[data-fork="1"] #messages .bubble.assistant > .coach-widget:not(.widget-fullscreen),
  body[data-fork="1"] #messages .bubble.assistant > img.diagram {
    width: auto; max-width: 640px; margin-left: 0; margin-right: 0; border-width: 1px; border-radius: var(--ui-r-2);
  }
}

/* The widget's head: its kind on one line, its name under it, Full screen a text button at the right (A2's head,
   taken by A1; coach.js builds .widget-kind and .widget-name). */
body[data-fork="1"] #messages .coach-widget .widget-title {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: var(--ui-s-2);
  padding: 0 var(--ui-s-1) 0 max(var(--ui-gut), var(--ui-s-3)); border-bottom: 1px solid var(--ui-line);
  background: var(--ui-bg); color: var(--ui-ink); font-size: var(--ui-t-sub); font-weight: 600; line-height: 1.3;
}
body[data-fork="1"] #messages .coach-widget .widget-kind {
  grid-column: 1; grid-row: 1; padding: 7px 0; font-size: var(--ui-t-cap); font-weight: 400; letter-spacing: 0;
  text-transform: none; color: var(--ui-ink-2);
}
body[data-fork="1"] #messages .coach-widget .widget-kind:has(+ .widget-name) { padding-bottom: 0; }
body[data-fork="1"] #messages .coach-widget .widget-name {
  grid-column: 1; grid-row: 2; padding: 0 0 7px; font-weight: 600; color: var(--ui-ink); overflow-wrap: anywhere;
}
body[data-fork="1"] #messages .coach-widget .widget-fs {
  grid-column: 2; grid-row: 1 / span 2; min-width: var(--ui-hit); min-height: var(--ui-hit); margin: 0;
  padding: 0 var(--ui-s-2); border: 0; border-radius: var(--ui-r-2); background: none; color: var(--ui-accent);
  font: 400 var(--ui-t-foot)/1.2 var(--ui-font); white-space: nowrap;
}
body[data-fork="1"] #messages .coach-widget .widget-title:not(:has(.widget-name)) .widget-fs { grid-row: 1; }
body[data-fork="1"] #messages .coach-widget .widget-fs:active { opacity: .55; }

/* The row under a figure or widget: "Was this helpful?", Helpful, Not helpful, Feedback on one line, quiet text
   buttons with 44 px targets; the chosen one is accent at weight 600 (fork-skin.js drops the emoji). */
body[data-fork="1"] #messages .widget-vote {
  display: flex; flex-wrap: wrap; align-items: center; gap: 0 var(--ui-s-3); margin: 0 0 var(--ui-s-1); padding: 0;
  font-size: var(--ui-t-foot); color: var(--ui-ink-2);
}
body[data-fork="1"] #messages .widget-vote .vote-btn {
  display: inline-flex; align-items: center; min-height: var(--ui-hit); min-width: var(--ui-hit); margin: 0;
  padding: 0 2px; border: 0; border-radius: var(--ui-r-2); background: none; box-shadow: none;
  color: var(--ui-accent); font: 400 var(--ui-t-foot)/1.2 var(--ui-font); opacity: 1;
}
body[data-fork="1"] #messages .widget-vote .vote-btn[aria-pressed="true"],
body[data-fork="1"] #messages .widget-vote .vote-btn.wf-open[aria-expanded="true"] {
  background: none; color: var(--ui-accent); font-weight: 600;
}
body[data-fork="1"] #messages .widget-vote .vote-btn:active { opacity: .55; }
body[data-fork="1"] #messages .widget-vote .vote-thanks { color: var(--ui-ink-2); }
body[data-fork="1"] #messages .vote-note {
  gap: var(--ui-s-1); margin: 0 0 var(--ui-s-2); padding: 0 0 0 var(--ui-s-3); border: 0; border-radius: var(--ui-r-2);
  outline: 0; box-shadow: inset 0 0 0 1px var(--ui-line-2); background: var(--ui-bg); align-items: flex-end;
}
body[data-fork="1"] #messages .vote-note:focus-within { outline: 0; box-shadow: inset 0 0 0 2px var(--ui-accent); }
body[data-fork="1"] #messages .vote-note textarea {
  min-height: var(--ui-hit); padding: 10px 0; color: var(--ui-ink); font: 16px/24px var(--ui-font); background: none;
}
body[data-fork="1"] #messages .vote-note textarea::placeholder { color: var(--ui-ink-2); opacity: 1; }
body[data-fork="1"] #messages .vote-send {
  width: var(--ui-hit); height: var(--ui-hit); min-width: var(--ui-hit); padding: 0; border: 0;
  border-radius: var(--ui-r-2); background: var(--ui-accent-fill); color: var(--ui-on-accent); font-size: 20px;
}
body[data-fork="1"] #messages .vote-send:disabled { background: var(--ui-bg-3); color: var(--ui-ink-2); opacity: 1; }

/* ---- Coach's buttons: 44 px rows across the reply's column with hairlines, accent words and an accent › drawn as
   a picture (A1 .choice); pressed --ui-bg-2; a past option is --ui-ink-2 with no ›. Got it is the same row with
   its thumb. RB1 keeps the tapped option out of the list (coach.js settleControls). ---- */
body[data-fork="1"] #messages .reply-controls { margin: var(--ui-s-3) 0 0; border-top: 1px solid var(--ui-line); }
body[data-fork="1"] #messages .reply-group > .reply-controls { margin-left: 0; align-self: stretch; }
body[data-fork="1"] #messages .choice-controls { flex-direction: column; align-items: stretch; gap: 0; }
body[data-fork="1"] #messages .reply-controls .reply-choice, body[data-fork="1"] #messages .reply-controls .quick-ack {
  display: flex; align-items: center; justify-content: flex-start; gap: var(--ui-s-3); box-sizing: border-box;
  width: 100%; max-width: none; min-width: 0; height: auto; min-height: var(--ui-hit); margin: 0; padding: 9px 2px 9px 0;
  border: 0; border-bottom: 1px solid var(--ui-line); border-radius: 0; background: none; box-shadow: none;
  color: var(--ui-accent); opacity: 1; transform: none; font-family: var(--ui-font); font-size: var(--ui-t-body);
  font-weight: 400; line-height: 1.3; text-align: left; -webkit-tap-highlight-color: transparent;
}
body[data-fork="1"] #messages .reply-controls > :last-child { border-bottom: 0; }
body[data-fork="1"] #messages .reply-controls .reply-choice::after, body[data-fork="1"] #messages .reply-controls .quick-ack::after {
  content: ""; flex: none; width: 16px; height: 16px; margin-left: auto; background: var(--ui-accent);
  -webkit-mask: var(--ui-chev) center / 16px 16px no-repeat; mask: var(--ui-chev) center / 16px 16px no-repeat;
}
body[data-fork="1"] #messages .reply-controls .reply-choice:active:not(:disabled),
body[data-fork="1"] #messages .reply-controls .quick-ack:active:not(:disabled),
body[data-fork="1"] #messages .reply-controls .ack-pressed { background: var(--ui-bg-2); color: var(--ui-accent); transform: none; }
body[data-fork="1"] #messages .reply-controls .reply-choice:disabled, body[data-fork="1"] #messages .reply-controls .quick-ack:disabled {
  color: var(--ui-ink-2); cursor: default;
}
body[data-fork="1"] #messages .reply-controls .reply-choice:disabled::after,
body[data-fork="1"] #messages .reply-controls .quick-ack:disabled::after { content: none; }
body[data-fork="1"] #messages .reply-controls .quick-ack svg { width: 24px; height: 24px; flex: none; }
body[data-fork="1"] #messages .reply-controls .quick-ack .ack-label { line-height: 1.3; }
/* coach.css dims the rest of the list while one option is being sent or the student is typing; the rows above set
   opacity 1, so the dimming is restated here. */
body[data-fork="1"] #messages .reply-controls:has(.ack-pressed) button:not(.ack-pressed),
body[data-fork="1"] #messages .reply-controls.composing button { opacity: .45; }
body[data-fork="1"] #messages .reply-controls.composing button:focus-visible { opacity: 1; }
body[data-fork="1"] #messages .reply-controls .reply-choice:focus-visible, body[data-fork="1"] #messages .reply-controls .quick-ack:focus-visible {
  outline: 3px solid var(--ui-accent); outline-offset: -3px; border-radius: var(--ui-r-1);
}
@media (hover: hover) and (pointer: fine) {
  body[data-fork="1"] #messages .reply-controls .reply-choice:hover:not(:disabled),
  body[data-fork="1"] #messages .reply-controls .quick-ack:hover:not(:disabled) { background: var(--ui-bg-2); border-color: var(--ui-line); }
}

/* Coach is writing: the face and the dots, unboxed. While a drawing is written its dashed place sits above them. */
body[data-fork="1"] #messages .typing { align-items: center; gap: var(--ui-s-2); margin: 0; }
body[data-fork="1"] #messages .typing-avatar { width: 20px; height: 20px; }
body[data-fork="1"] #messages .typing-bubble { min-height: 24px; padding: 0; border-radius: 0; background: none; }
body[data-fork="1"] #messages .typing-bubble span { width: 7px; height: 7px; background: var(--ui-ink-2); }
body[data-fork="1"] #messages .typing .lookup-drawing {
  flex-basis: 100%; max-width: 330px; margin: 0 0 6px; border-color: var(--ui-line-2); border-radius: var(--ui-r-2);
  color: var(--ui-ink-2);
}

/* ---- Scene replies, gate S = BLOCKS (planner, Nov 18): characters keep their tinted blocks (--scene-light and
   --scene-dark), 10 px corners and no gutter; the 20 px portrait and the name once per run, on its first row
   (gate F); Coach's lines in a scene are unboxed like all of Coach's text; the play button stays beside its line;
   "Your turn" after the last row. ---- */
body[data-fork="1"] #messages .reply-group { gap: 10px; }
body[data-fork="1"] #messages .char-bubble {
  max-width: 100%; margin: 0; padding: 8px var(--ui-s-3); border: 0; border-radius: var(--ui-r-3);
  font-size: var(--ui-t-read); line-height: 1.4;
}
body[data-fork="1"] #messages .char-bubble.has-scene-audio { max-width: calc(100% - 48px); }
body[data-fork="1"] #messages .char-bubble.scene-coach {
  align-self: stretch; max-width: none; padding: 0; border-radius: 0; background: none; color: var(--ui-ink);
}
body[data-fork="1"] #messages .char-bubble.scene-coach.has-scene-audio { max-width: calc(100% - 48px); }
body[data-fork="1"] #messages .char-bubble > .char-avatar {
  float: left; position: static; width: 20px; height: 20px; margin: 0 var(--ui-s-2) 0 0; border-radius: 50%;
}
body[data-fork="1"] #messages .char-bubble > .char-name { margin: 0 0 2px; font-size: var(--ui-t-foot); font-weight: 600; line-height: 20px; }
body[data-fork="1"] #messages .char-bubble.scene-coach > .char-name { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
body[data-fork="1"] #messages .char-bubble > .scene-text { clear: none; }
body[data-fork="1"] #messages .char-bubble .scene-speaker { color: var(--ui-accent); border-radius: var(--ui-r-2); }
body[data-fork="1"] #messages .scene-gloss { color: var(--ui-ink-2); }
body[data-fork="1"] #messages .scene-gloss-reveal { color: var(--ui-ink-2); }
body[data-fork="1"] #messages .scene-intro { color: var(--ui-ink-2); }
body[data-fork="1"] #messages .your-turn { margin-top: var(--ui-s-2); color: var(--ui-ink-2); font-size: var(--ui-t-cap); font-weight: 600; }
/* On a character's tint, grey words fall under 4.5:1 in dark mode (#a1a1a6 on javi's #40451e is 3.9:1;
   scenariolib/cast); ink keeps 9:1 or more on every cast colour in both themes. */
body[data-fork="1"] #messages .char-bubble:not(.scene-coach) .your-turn,
body[data-fork="1"] #messages .char-bubble:not(.scene-coach) .scene-gloss,
body[data-fork="1"] #messages .char-bubble:not(.scene-coach) .scene-gloss-reveal { color: var(--ui-ink); }
/* One portrait and one name a run, on the first row (gate F; coach.js sceneRuns marks the later rows
   run-name-earlier). Restated here because the face rule above outranks fork.css's. */
body[data-fork="1"] #messages .reply-group .run-name-earlier > .coach-avatar,
body[data-fork="1"] #messages .reply-group .run-name-earlier > .char-avatar,
body[data-fork="1"] #messages .reply-group .run-name-earlier > .char-name { display: none; }

/* ---- Queued message: a "Queued" row between hairlines (A1 controls sheet). ---- */
body[data-fork="1"] .queue { gap: 0; margin: 0 0 6px; }
body[data-fork="1"] .queue-item {
  align-items: center; gap: var(--ui-s-2); padding: 0 0 0 2px; border: 0; border-top: 1px solid var(--ui-line);
  border-bottom: 1px solid var(--ui-line); border-radius: 0; background: none; color: var(--ui-ink);
  font-size: var(--ui-t-sub);
}
body[data-fork="1"] .queue-item + .queue-item, body[data-fork="1"] #dock > .queue > .queue-item:first-child { border-top: 0; }
body[data-fork="1"] .queue-label { padding: 0; font-size: var(--ui-t-cap); font-weight: 700; letter-spacing: .04em; color: var(--ui-ink-2); }
body[data-fork="1"] .queue-text { padding: 8px 0; }
body[data-fork="1"] .queue-cancel {
  min-width: var(--ui-hit); min-height: var(--ui-hit); padding: 0; border-radius: var(--ui-r-2); color: var(--ui-ink-2);
}

/* ---- The message box: flush, one hairline, no box (A1 "Message box"): 44 px with 6 px above and below. The field
   has a 1 px outline and 6 px corners; Send is a 44 x 44 accent square (--ui-bg-3 when it cannot send); attach and
   microphone are 44 px icon buttons. ---- */
body[data-fork="1"] #dock {
  margin: 0; padding: 6px max(var(--ui-s-2), env(safe-area-inset-right)) max(6px, env(safe-area-inset-bottom))
    max(var(--ui-s-2), env(safe-area-inset-left));
  border-top: 1px solid var(--ui-line);
  background: var(--ui-bg); min-width: 0;
}
body[data-fork="1"] #compose {
  margin: 0; padding: 0; border: 0; border-radius: 0; outline: 0; background: none; box-shadow: none; color: var(--ui-ink);
}
body[data-fork="1"] #compose:focus-within { outline: 0; border: 0; }
body[data-fork="1"] #compose .compose-row { gap: var(--ui-s-1); align-items: flex-end; }
body[data-fork="1"] #question {
  min-height: var(--ui-hit); margin: 0; padding: 10px var(--ui-s-3); border: 0; border-radius: var(--ui-r-2);
  box-shadow: inset 0 0 0 1px var(--ui-line-2); background: var(--ui-bg); color: var(--ui-ink);
  font: 17px/24px var(--ui-font);
}
body[data-fork="1"] #question:focus { outline: 0; box-shadow: inset 0 0 0 2px var(--ui-accent); }
body[data-fork="1"] #question::placeholder { color: var(--ui-ink-2); opacity: 1; }
body[data-fork="1"] #upload, body[data-fork="1"] #mic, body[data-fork="1"] #send {
  width: var(--ui-hit); min-width: var(--ui-hit); height: var(--ui-hit); margin: 0; padding: 0; border: 0;
  border-radius: var(--ui-r-2); box-shadow: none; opacity: 1;
}
body[data-fork="1"] #upload, body[data-fork="1"] #mic { background: transparent; color: var(--ui-ink-2); }
body[data-fork="1"] #upload:active:not(:disabled), body[data-fork="1"] #mic:active:not(:disabled) { background: var(--ui-bg-3); }
body[data-fork="1"] #upload:disabled, body[data-fork="1"] #mic:disabled { background: transparent; color: var(--ui-line-2); }
body[data-fork="1"] #mic.recording { background: var(--ui-danger); color: var(--ui-bg); }
body[data-fork="1"] .scene-open #mic { box-shadow: inset 0 0 0 2px var(--ui-accent); }
body[data-fork="1"] #send { background: var(--ui-accent-fill); color: var(--ui-on-accent); }
body[data-fork="1"] #send svg path { stroke: currentColor; }
body[data-fork="1"] #send:active:not(:disabled) { filter: brightness(.86); }
body[data-fork="1"] #send:disabled { background: var(--ui-bg-3); color: var(--ui-ink-2); cursor: default; }
body[data-fork="1"] #upload:focus-visible, body[data-fork="1"] #mic:focus-visible, body[data-fork="1"] #send:focus-visible {
  outline: 3px solid var(--ui-accent); outline-offset: 2px; border-radius: var(--ui-r-1);
}
body[data-fork="1"] #file-preview { border-radius: var(--ui-r-2); background: var(--ui-bg-2); }
body[data-fork="1"] #remove-file {
  min-height: var(--ui-hit); padding: 0 var(--ui-s-3); border-radius: var(--ui-r-2); background: none; color: var(--ui-accent);
}
body[data-fork="1"] .pick-bar { border: 0; border-radius: 0; border-bottom: 1px solid var(--ui-line); background: var(--ui-bg-2); color: var(--ui-ink); }
body[data-fork="1"] .pick-bar button { min-height: var(--ui-hit); border-radius: var(--ui-r-2); color: var(--ui-accent); }
@media (hover: hover) and (pointer: fine) {
  body[data-fork="1"] #upload:hover:not(:disabled), body[data-fork="1"] #mic:hover:not(:disabled):not(.recording) {
    background: var(--ui-bg-2); color: var(--ui-ink);
  }
}
@media (min-width: 700px) {
  /* A wide screen: no line, 20 px under the box, and a fade so the text ends softly above it (A1). */
  body[data-fork="1"] #dock { padding: 0 0 var(--ui-s-5); border-top: 0; }
  body[data-fork="1"] #dock::before {
    content: ""; position: absolute; left: 0; right: 0; top: -16px; height: 16px; pointer-events: none;
    background: linear-gradient(to top, var(--ui-bg), transparent);
  }
}

/* Latest: an ink-filled button with 6 px corners, 44 px high, centred above the message box. */
body[data-fork="1"] #latest {
  min-height: var(--ui-hit); margin: 0 0 var(--ui-s-2); padding: 0 var(--ui-s-4); border: 0; border-radius: var(--ui-r-2);
  background: var(--ui-ink); color: var(--ui-bg); box-shadow: var(--ui-shadow); font: 600 var(--ui-t-sub)/1.2 var(--ui-font);
}
body[data-fork="1"] #latest:active { filter: brightness(.8); }
@media (min-width: 700px) {
  body[data-fork="1"] #latest { margin-bottom: var(--ui-s-6); }
}
