/* Verity preview v1.2 (16 November 2026): the two short routes, the card beside (never on) its target, the compact phone
   card, toasts in the frame, results first on Anna's page, coverage behind a toggle. Tokens only from css/app.css. */

/* ---------- decision 8: «Aufnehmen» is a normal rail item (no big purple button) ---------- */
.rail .ri[data-rec] { margin-bottom:0 }

/* ---------- the card (desktop) ---------- */
.tour.wide:not(.dock) { width:360px }
.tour .hd { display:block }
.tour .hd .n { display:block }
.tour .hd .do { display:block; margin-top:5px; font-weight:650; font-size:15px; line-height:1.35 }
.tour .tx { display:block; margin-top:5px; font-weight:400 }
.tour .more { display:none }
.tour [hidden] { display:none !important }
.tour .ch { display:flex; flex-wrap:wrap; gap:8px; margin-top:12px }
.tour .ch button, .tour .me button { min-height:38px; padding:0 14px; border-radius:10px; background:var(--callink); color:var(--call); font-weight:650; font-size:13.5px }
.tour .ch button.q { background:transparent; color:var(--callink); text-decoration:underline; text-underline-offset:.2em; font-weight:500; padding:0 6px }
.tour .ch button:hover, .tour .me button:hover { filter:brightness(.94) }
.tour .me { display:flex; margin-top:12px }
.tour .ft { margin-top:10px }
.tour .ft #tourSkip { font-size:12px }

/* ---------- the card (phone): compact, docked, one or two lines plus one row of buttons; «Mehr» opens the text ---------- */
@media (max-width:760px) {
  .tour.dock { display:flex; flex-wrap:wrap; align-items:center; column-gap:6px; row-gap:4px; padding:8px 12px 6px; max-height:calc(100vh - var(--mhead-h) - var(--mbar-h) - 24px); overflow:auto }
  .tour.dock > .hd, .tour.dock > .tx, .tour.dock > .sub { flex:1 1 100% }
  .tour.dock .hd .n { display:inline; margin-right:6px; font-size:12.5px; color:var(--callmute) }
  .tour.dock .hd .do { display:inline; margin:0; font-size:15px; line-height:1.35 }
  .tour.dock > .tx { margin:2px 0 0; font-size:14px; line-height:1.4 }
  .tour.dock:not(.open) > .tx, .tour.dock:not(.open) > .sub, .tour.dock:not(.open) .back { display:none !important }
  .tour.dock .more { display:inline-flex; align-items:center; text-decoration:underline; text-underline-offset:.2em }
  .tour.dock > .ch { display:contents }
  .tour.dock > .ch button { min-height:44px; padding:0 12px; font-size:14px }
  .tour.dock > .ft { order:5; flex:1 1 auto; margin:0; gap:2px; font-size:13px }
  .tour.dock > .me { order:6; flex:0 0 auto; margin:0 }
  .tour.dock .me button { min-height:44px; padding:0 14px; font-size:14px }
  .tour.dock .ft .go { font-size:14px }
}

/* ---------- toasts: in the frame, never on the page (decision 3) ---------- */
.toast.inlist, .toast.instrip { transform:none; bottom:auto; max-width:none; display:flex; align-items:center; justify-content:center; text-align:center; font-size:13px; line-height:1.4; padding:6px 12px; box-shadow:0 8px 20px -10px rgb(0 0 0 / .45) }
.toast.instrip { padding:0 12px; border-radius:8px; white-space:nowrap; overflow:hidden }
@media (max-width:760px) {
  .toast.onbar { left:0; right:0; bottom:0; transform:none; width:auto; max-width:none; border-radius:16px 16px 0 0; min-height:calc(var(--mbar-h) + env(safe-area-inset-bottom)); display:flex; align-items:center; justify-content:center; padding:6px 16px env(safe-area-inset-bottom); font-size:13.5px; line-height:1.35 }
}

/* ---------- decision 6: Anna's page, results first ---------- */
@media (min-width:1061px) { .grid.prep { grid-template-columns:minmax(0,1.15fr) minmax(0,.85fr) } }
#rightCol .colhead .help { margin:6px 0 0; font-size:12.5px; color:var(--fg) }
details.cover { display:block; padding:0; background:none; border:0; margin:0 0 12px }
details.cover > summary { list-style:none; cursor:pointer; display:inline-flex; align-items:center; gap:6px; min-height:32px; padding:0 4px; border-radius:8px; font-size:13px; font-weight:500; color:var(--primary-ink) }
details.cover > summary::-webkit-details-marker { display:none }
details.cover > summary::before { content:"›"; font-size:16px; line-height:1; transition:transform .15s }
details.cover[open] > summary::before { transform:rotate(90deg) }
details.cover[open] { padding:6px 12px 12px; border-radius:12px; background:var(--fill); border:1px solid var(--hair) }
details.cover[open] > summary { margin:0 0 4px -4px }
.tlkey { flex-wrap:wrap; gap:4px 14px }
.tlkey span { display:inline-flex; align-items:center; gap:5px }
.tlkey i { background:var(--fill2) }
.tlkey i.hit { background:var(--primary) }
.tlkey i.bad { margin-left:0; background:transparent }
.pass .row .tob { margin-left:2px }
.side .dup { margin:2px 0 4px }

/* ---------- decision 7: the reason stands right next to a disabled «Übernehmen» ---------- */
.okwrap { display:inline-flex; align-items:center; gap:8px; flex-wrap:wrap; max-width:100% }
.okwrap .why { font-weight:600; max-width:260px; line-height:1.35 }
.fillbar #ivFormNow { margin-left:auto }

@media (max-width:760px) {
  details.cover > summary { min-height:44px }
  .okwrap { flex-basis:100% }
  .okwrap .why { max-width:none; flex:1 1 140px }
}

/* ---------- v1.2 fix pass ---------- */
@media (max-width:760px) {
  /* the dictation choice is compact on the phone: «▶ Anhören» beside the heading, so letter heading, letter and choice fit
     together above (or below) the docked card */
  #dkCard:has(.dkplay) { display:grid; grid-template-columns:minmax(0,1fr) auto; column-gap:10px; align-items:center }
  #dkCard:has(.dkplay) > .dkn { grid-column:1; grid-row:1 }
  #dkCard:has(.dkplay) > h2 { grid-column:1; grid-row:2; margin:0 }
  #dkCard:has(.dkplay) > .dkplay { grid-column:2; grid-row:1 / span 2; padding:0; margin:0 }
  #dkCard:has(.dkplay) > .csub, #dkCard:has(.dkplay) > .reads { grid-column:1 / -1 }
  #dkCard:has(.dkplay) > .reads { margin-top:8px }
  #dkLetter { padding-bottom:14px }
  #dkText .lt:last-child { margin-bottom:0 }
  /* forms report: the patient details use the full width; badge and «Mehr» stand below them */
  .fpage .phead { align-items:center }
  .fpage .phead .who { flex:1 1 100%; min-width:0 }
  .fpage .phead .local, .fpage .phead .rolepill { order:2 }
  .fpage .phead .mmenu { order:3; margin-left:auto }
}
