/* css/activity.css
   Everything the assistant shows about its work: files to download, pictures
   made by code, and (added in the activity redesign) the step timeline and
   approval card. Uses only the tokens from shared.css. */

/* ── Files to download, under the answer ───────────────────────────── */
.deliv { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-top: var(--space-3); }
.deliv-file {
  display: inline-flex; align-items: center; gap: 8px; max-width: 100%;
  min-height: 44px; padding: 0 14px;
  background: var(--bg-elevated); border: 1px solid var(--border); border-radius: var(--radius-md);
  color: var(--text-1); font: inherit; font-size: 14px; cursor: pointer;
}
.deliv-file i { flex-shrink: 0; font-size: 16px; color: var(--text-2); }
.deliv-file-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.deliv-file-size { flex-shrink: 0; font-size: 12px; color: var(--text-2); font-variant-numeric: tabular-nums; }
.deliv-item { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; max-width: 100%; }
.deliv-save {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 12px;
  background: transparent; border: 1px solid var(--border); border-radius: var(--radius-md);
  color: var(--text-2); font: inherit; font-size: 13px; cursor: pointer;
}
.deliv-save:hover { border-color: var(--text-3); color: var(--text-1); }
.deliv-save:disabled { opacity: .6; cursor: default; }
.deliv-save:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.deliv-file:hover { border-color: var(--text-3); }
.deliv-file:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.message.is-streaming .deliv,
.message.is-streaming .fig-grid,
.message.is-streaming .gen-media-list { display: none; }

/* ── Pictures made by code ─────────────────────────────────────────── */
.figs, .fig-grid {
  display: grid; gap: var(--space-3); margin-top: var(--space-3);
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr));
}
.fig { margin: 0; min-width: 0; }
.fig-open { display: block; width: 100%; padding: 0; border: 0; background: none; border-radius: var(--radius-md); cursor: zoom-in; font: inherit; }
.fig-open:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
/* A light backing in both colour schemes, so a transparent PNG with dark lines stays readable. */
.fig-frame {
  display: grid; place-items: center; min-height: 120px; padding: 8px; overflow: hidden;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius-md);
}
.fig-img { display: block; max-width: 100%; height: auto; border-radius: var(--radius-sm); }
.fig-ph { font-size: 12px; color: #4b5563; text-align: center; padding: var(--space-3); }
.fig.is-gone .fig-open { cursor: default; }
.fig.is-gone .fig-frame { background: var(--bg-subtle); }
.fig.is-gone .fig-ph { color: var(--text-3); }
.fig-cap { margin-top: 6px; font-family: var(--font-mono); font-size: 12px; color: var(--text-3); overflow-wrap: anywhere; }

/* ── Enlarged picture ──────────────────────────────────────────────── */
.lb { position: fixed; inset: 0; z-index: 1200; display: flex; flex-direction: column; background: rgba(0, 0, 0, .86); }
.lb-bar {
  display: flex; align-items: center; gap: var(--space-2);
  padding: 10px 12px; padding-top: max(10px, env(safe-area-inset-top)); color: #fff;
}
.lb-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.lb-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-width: 44px; min-height: 44px; padding: 0 14px;
  background: transparent; color: #fff; border: 1px solid rgba(255, 255, 255, .4); border-radius: var(--radius-md);
  font: inherit; font-size: 14px; cursor: pointer;
}
.lb-btn:hover { background: rgba(255, 255, 255, .12); }
.lb-btn:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.lb-stage { flex: 1; min-height: 0; overflow: auto; display: grid; place-items: center; padding: 12px; overscroll-behavior: contain; touch-action: pan-x pan-y pinch-zoom; }
.lb-img { max-width: 100%; max-height: 100%; background: #fff; border-radius: var(--radius-sm); cursor: zoom-in; }
.lb-img.is-zoomed { max-width: none; max-height: none; cursor: zoom-out; }

/* ════════════════════════════════════════════════════════════════════
   ACTIVITY — one calm timeline per assistant message
   Closed it is a single quiet line. Open it is a thin rail with a small
   status node per step. Small secondary text uses --text-2 (not --text-3)
   so it stays readable in light mode.
════════════════════════════════════════════════════════════════════ */
.act { margin: 0 0 var(--space-3); max-width: 100%; }
.act-sr {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.act-head {
  display: inline-flex; align-items: center; gap: 6px;
  min-height: 44px; margin: -8px 0; padding: 8px 0;
  background: none; border: 0; color: var(--text-2);
  font: inherit; font-size: 13px; cursor: pointer; text-align: left;
}
.act-head:hover { color: var(--text-1); }
.act-head:focus-visible, .act-toggle:focus-visible, .appr-btn:focus-visible,
.appr-more:focus-visible, .sbx-stop:focus-visible, .sbx-download:focus-visible,
.sbx-save:focus-visible, .sbx-retry:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 2px; border-radius: var(--radius-sm);
}
.act-label { font-variant-numeric: tabular-nums; }
.act-time { color: var(--text-2); font-variant-numeric: tabular-nums; font-size: 12px; }
.act-caret, .act-chev { font-size: 12px; transition: transform var(--duration-fast) var(--ease); }
.act.is-open > .act-head .act-caret { transform: rotate(180deg); }
.act.has-fail > .act-head .act-label { color: var(--danger); }
.act.is-live > .act-head .act-label::before {
  content: ""; display: inline-block; width: 6px; height: 6px; margin-right: 8px; border-radius: var(--radius-full);
  background: var(--accent); vertical-align: 1px; animation: act-pulse 1.4s ease-in-out infinite;
}
@keyframes act-pulse { 0%, 100% { opacity: .35; transform: scale(.8); } 50% { opacity: 1; transform: scale(1); } }

/* open/close without measuring heights */
.act-body {
  display: grid; grid-template-rows: 0fr; visibility: hidden;
  transition: grid-template-rows 200ms var(--ease), visibility 0s linear 200ms;
}
.act.is-open > .act-body { grid-template-rows: 1fr; visibility: visible; transition-delay: 0s; }
.act-body > .act-rail { min-height: 0; overflow: hidden; }

.act-rail { list-style: none; margin: 0; padding: var(--space-2) 0 0; }
.act-item {
  position: relative; display: flex; gap: 12px; padding-bottom: var(--space-3);
}
.act-item::before { /* the rail */
  content: ""; position: absolute; left: 11px; top: 26px; bottom: 0; width: 1px;
  background: var(--border-strong);
}
.act-item:last-child { padding-bottom: 2px; }
.act-item:last-child::before { display: none; }
.act-node {
  position: relative; z-index: 1; flex-shrink: 0; width: 22px; height: 22px; margin-top: 1px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: var(--radius-full); border: 1px solid var(--border);
  background: var(--bg-subtle); color: var(--text-2); font-size: 12px;
  transition: background var(--duration-fast) var(--ease), border-color var(--duration-fast) var(--ease), color var(--duration-fast) var(--ease);
}
.act-item[data-state="done"] .act-node { color: var(--text-1); }
.act-item[data-state="fail"] .act-node { color: var(--danger); border-color: var(--danger); background: var(--danger-subtle); }
.act-item[data-state="wait"] .act-node { color: var(--warning); border-color: var(--warning); background: var(--warning-subtle); }
.act-item[data-state="stopped"] .act-node { color: var(--text-2); border-style: dashed; }
.act-item[data-state="running"] .act-node { color: var(--text-1); border-color: transparent; }
.act-item[data-state="running"] .act-node::after { /* spinning arc around the icon */
  content: ""; position: absolute; inset: -1px; border-radius: var(--radius-full);
  border: 1.5px solid var(--border-strong); border-top-color: var(--accent);
  animation: act-spin 0.9s linear infinite;
}
@keyframes act-spin { to { transform: rotate(360deg); } }
/* the title of a step that is still running breathes */
.act-item[data-state="running"] .act-title {
  background: linear-gradient(90deg, var(--text-2) 0%, var(--text-1) 45%, var(--text-2) 90%);
  background-size: 220% 100%; -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: act-shimmer 1.8s ease-in-out infinite;
}
@keyframes act-shimmer { 0% { background-position: 110% 0; } 100% { background-position: -110% 0; } }
/* a row sliding in while a turn is live */
.act-item--enter { animation: act-in 220ms var(--ease) both; }
@keyframes act-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.act-main { min-width: 0; flex: 1; }
.act-row { display: flex; align-items: flex-start; gap: var(--space-2); }
.act-toggle {
  flex: 1; min-width: 0; display: flex; align-items: flex-start; gap: var(--space-2);
  min-height: 24px; padding: 0; background: none; border: 0; text-align: left;
  font: inherit; color: var(--text-1); cursor: pointer;
}
button.act-toggle { min-height: 44px; margin: -10px 0; padding: 10px 0; }
.act-toggle--static { cursor: default; }
.act-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.act-title { font-size: 14px; line-height: 1.4; overflow-wrap: anywhere; }
.act-sub { font-size: 12px; color: var(--text-2); }
.act-sub:empty { display: none; }
.act-note { font-size: 12px; line-height: 1.4; color: var(--danger); overflow-wrap: anywhere; }
.act-item[data-state="fail"] .act-title { color: var(--text-1); }
.act-ms { flex-shrink: 0; font-size: 12px; color: var(--text-2); font-variant-numeric: tabular-nums; padding-top: 2px; }
.act-ms:empty { display: none; }
.act-chev { margin-top: 5px; color: var(--text-2); }
.act-toggle[aria-expanded="true"] .act-chev { transform: rotate(180deg); }
.act-item--quiet .act-title { color: var(--text-2); }
.act-detail { margin-top: var(--space-2); }
.act-detail[hidden] { display: none; }
.act-prose { font-size: 13px; color: var(--text-2); line-height: 1.55; }
.act-prose p { margin: 0 0 var(--space-2); }
.act-list { margin: 0; padding-left: 1.1em; font-size: 13px; color: var(--text-2); display: flex; flex-direction: column; gap: 2px; }
.act-list li { overflow-wrap: anywhere; }

/* ── web search: the sites a search found ── */
.act-sources { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.act-src {
  display: flex; align-items: center; gap: var(--space-2); min-height: 44px; padding: 4px 6px; margin: 0 -6px;
  border-radius: var(--radius-md); color: var(--text-1); text-decoration: none;
}
.act-src:hover { background: var(--bg-elevated); }
.act-src:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
/* The globe sits underneath; the site's own picture covers it once it has loaded. */
.act-src-ico { position: relative; flex-shrink: 0; width: 16px; height: 16px; display: inline-flex; align-items: center; justify-content: center; color: var(--text-2); font-size: 14px; }
.act-src-img { position: absolute; inset: 0; width: 16px; height: 16px; border-radius: 3px; background: var(--bg-elevated); }
.act-src-text { min-width: 0; display: flex; flex-direction: column; }
.act-src-title { font-size: 13px; line-height: 1.35; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.act-src-host { font-size: 12px; color: var(--text-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Several searches in one row: each question, then its sites. */
.act-search + .act-search { margin-top: var(--space-3); }
.act-search-q { font-size: 13px; color: var(--text-2); line-height: 1.4; overflow-wrap: anywhere; margin-bottom: 2px; }

/* ── code run detail ── */
.sbx-body { display: flex; flex-direction: column; gap: 8px; }
.sbx-cmd { font-family: var(--font-mono); font-size: 12px; color: var(--text-2); overflow-wrap: anywhere; }
.sbx-prompt { color: var(--accent); margin-right: 4px; user-select: none; }
.sbx-out {
  margin: 0; max-height: 280px; overflow: auto; padding: 10px 12px; tab-size: 4;
  background: var(--bg-subtle); border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-family: var(--font-mono); font-size: 12px; line-height: 1.5; color: var(--text-1);
  white-space: pre-wrap; overflow-wrap: anywhere;
}
.sbx-err { color: var(--danger); }
.sbx-muted, .sbx-note, .sbx-meta { color: var(--text-2); }
.sbx-note, .sbx-meta { font-size: 12px; }
.sbx-files { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--text-2); }
.sbx-files li { display: flex; align-items: center; gap: 6px; min-width: 0; }
.sbx-file-path { font-family: var(--font-mono); overflow-wrap: anywhere; min-width: 0; }
.sbx-actions { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.sbx-download, .sbx-retry, .sbx-save {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px;
  border: 1px solid var(--border-strong); border-radius: var(--radius-full);
  background: var(--bg-elevated); color: var(--text-1); font: inherit; font-size: 13px; cursor: pointer;
}
.sbx-download:hover, .sbx-retry:hover, .sbx-save:hover { border-color: var(--accent); }
.sbx-stop {
  flex-shrink: 0; min-height: 44px; margin: -10px 0; padding: 0 12px; background: none; border: 0;
  color: var(--text-1); font: inherit; font-size: 13px; text-decoration: underline; cursor: pointer;
}
.sbx-stop:disabled { color: var(--text-2); cursor: default; text-decoration: none; }

/* ── Approval card ── */
.appr {
  margin: 2px 0 2px; padding: var(--space-4);
  background: var(--bg-elevated); border: 1px solid var(--border-strong); border-radius: var(--radius-md);
  display: flex; flex-direction: column; gap: var(--space-3);
  transition: opacity 160ms var(--ease), transform 160ms var(--ease);
}
.appr.is-leaving { opacity: 0; transform: translateY(-4px); }
.appr-top { display: flex; align-items: center; gap: 10px; }
.appr-tile {
  width: 28px; height: 28px; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm); background: var(--bg-subtle); color: var(--text-1); font-size: 16px;
}
.appr-who { display: flex; flex-direction: column; min-width: 0; }
.appr-over { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-2); }
.appr-prov { font-size: 13px; color: var(--text-1); }
.appr-title { font-size: 16px; font-weight: 600; line-height: 1.35; overflow-wrap: anywhere; }
.appr-details { margin: 0; display: flex; flex-direction: column; gap: 6px; }
.appr-row { display: grid; grid-template-columns: minmax(70px, 28%) 1fr; gap: var(--space-3); font-size: 13px; }
.appr-row dt { color: var(--text-2); }
.appr-row dd { margin: 0; color: var(--text-1); overflow-wrap: anywhere; }
.appr-long-label { font-size: 12px; color: var(--text-2); margin-bottom: 4px; }
.appr-long-text {
  padding: 8px 10px; background: var(--bg-subtle); border-radius: var(--radius-sm);
  font-size: 13px; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere;
}
.appr-long-text.is-clamped { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.appr-more {
  min-height: 44px; padding: 0; background: none; border: 0; color: var(--text-1);
  font: inherit; font-size: 13px; text-decoration: underline; cursor: pointer;
}
.appr-conseq { margin: 0; font-size: 13px; color: var(--text-1); line-height: 1.5; }
.appr-actions { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.appr-btn {
  min-height: 44px; padding: 0 20px; border-radius: var(--radius-full); font: inherit; font-size: 14px;
  font-weight: 500; cursor: pointer; border: 1px solid transparent;
  transition: opacity var(--duration-fast) var(--ease);
}
.appr-btn--primary { background: var(--text-1); color: var(--bg-base); }
.appr--danger .appr-btn--primary { background: var(--danger); color: var(--bg-base); }
.appr-btn--ghost { background: transparent; border-color: var(--border-strong); color: var(--text-1); }
.appr-btn:hover:not(:disabled) { opacity: .88; }
.appr-btn:disabled { opacity: .5; cursor: default; }
.appr-note { margin: 0; font-size: 12px; color: var(--text-2); }

@media (max-width: 480px) {
  .appr-row { grid-template-columns: 1fr; gap: 0; }
  .appr-actions .appr-btn { flex: 1; }
  .sbx-out { max-height: 220px; }
}
@media (prefers-reduced-motion: reduce) {
  .act-body, .act-caret, .act-chev, .appr { transition: none; }
  .act-item[data-state="running"] .act-node::after { animation: none; }
  .act-item[data-state="running"] .act-title { animation: none; background: none; -webkit-text-fill-color: currentColor; color: var(--text-1); }
  .act-item--enter, .act.is-live > .act-head .act-label::before { animation: none; }
}

/* ── Pictures and designs the assistant made (see renderMediaHtml in js/app.js) ── */
.gen-media-list { display: flex; flex-direction: column; gap: 14px; margin: 10px 0 4px; }
.gen-media { margin: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; max-width: 100%; }
.gen-media img {
  display: block;
  max-width: min(100%, 520px);
  max-height: 70vh;
  width: auto;
  height: auto;
  border-radius: 12px;
  border: 1px solid var(--border, rgba(127, 127, 127, 0.25));
  background: rgba(127, 127, 127, 0.08);
}
.gen-media--design img { max-width: min(100%, 440px); }
.gen-media-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.gen-media-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px; min-height: 34px;
  font: inherit; font-size: 13px; line-height: 1;
  color: var(--text-1, inherit);
  background: transparent;
  border: 1px solid var(--border, rgba(127, 127, 127, 0.35));
  border-radius: 999px;
  cursor: pointer;
}
.gen-media-btn i { font-size: 15px; color: var(--text-2); }
.gen-media-btn:hover { border-color: var(--text-3); }
.gen-media-btn:disabled { opacity: 0.55; cursor: progress; }

/* Designed files from doc-studio: a preview of the first page or slide, then one button per file. */
.gen-media--doc img { max-width: min(100%, 360px); box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08), 0 8px 24px rgba(0, 0, 0, 0.10); }
.gen-media--slides img, .gen-media--poster img { max-width: min(100%, 520px); }
.gen-media--poster img { max-height: 60vh; }
button.gen-doc-open:not(.gen-media-btn) { display: block; padding: 0; margin: 0; border: 0; background: none; border-radius: 12px; cursor: zoom-in; max-width: 100%; }
button.gen-doc-open:not(.gen-media-btn):focus-visible { outline: 2px solid var(--text-3, currentColor); outline-offset: 3px; }
.gen-doc-size { color: var(--text-3, inherit); opacity: 0.8; font-size: 12px; }
.gen-doc-design { font-size: 12px; color: var(--text-3, inherit); }

/* ── Design requirements card (create_design) ──
   Asks only for what a design truly needs: text details and the person's own
   logo / photo. Reuses the approval card's buttons; separate from it. */
.dreq {
  margin: var(--space-3) 0 2px; padding: var(--space-5);
  max-width: 520px;
  background: var(--bg-elevated); border: 1px solid var(--border-strong); border-radius: var(--radius-lg);
  display: flex; flex-direction: column; gap: var(--space-4);
}
.dreq-top { display: flex; align-items: center; gap: 10px; }
.dreq-tile {
  width: 32px; height: 32px; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm); background: var(--accent-subtle); color: var(--accent); font-size: 18px;
}
.dreq-who { display: flex; flex-direction: column; min-width: 0; }
.dreq-over { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-2); }
.dreq-kind { font-size: 13px; color: var(--text-1); }
.dreq-title { font-size: 18px; font-weight: 600; line-height: 1.3; letter-spacing: -.01em; overflow-wrap: anywhere; }
.dreq-intro { margin: -6px 0 0; font-size: 14px; line-height: 1.5; color: var(--text-2); }
.dreq-fields { display: flex; flex-direction: column; gap: var(--space-4); }
.dreq-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.dreq-label-row { display: flex; align-items: baseline; justify-content: space-between; gap: var(--space-2); }
.dreq-label { font-size: 13px; font-weight: 600; color: var(--text-1); }
.dreq-opt { font-size: 11px; letter-spacing: .04em; text-transform: uppercase; color: var(--text-2); }
.dreq-hint { margin: 0; font-size: 12.5px; line-height: 1.45; color: var(--text-2); }
.dreq-input {
  width: 100%; min-height: 46px; padding: 0 14px; box-sizing: border-box;
  font: inherit; font-size: 15px; color: var(--text-1);
  background: var(--bg-base); border: 1px solid var(--border-strong); border-radius: var(--radius-md);
  transition: border-color var(--duration-fast) var(--ease), box-shadow var(--duration-fast) var(--ease);
}
.dreq-input::placeholder { color: var(--text-2); opacity: .75; }
.dreq-input:hover { border-color: var(--text-2); }
.dreq-input:focus-visible, .dreq-pick:focus-visible, .dreq-remove:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 2px; border-color: var(--accent);
}
.dreq-upload { display: block; }
.dreq-pick {
  width: 100%; min-height: 64px; padding: 12px 14px; box-sizing: border-box;
  display: flex; align-items: center; gap: 12px; text-align: left; cursor: pointer;
  font: inherit; color: var(--text-1);
  background: var(--bg-base); border: 1.5px dashed var(--border-strong); border-radius: var(--radius-md);
  transition: border-color var(--duration-fast) var(--ease), background var(--duration-fast) var(--ease);
}
.dreq-pick[hidden], .dreq-chosen[hidden] { display: none; }
.dreq-pick:hover { border-color: var(--accent); background: var(--accent-subtle); }
.dreq-pick .ph { font-size: 22px; color: var(--accent); flex-shrink: 0; }
.dreq-pick-text { display: flex; flex-direction: column; gap: 1px; }
.dreq-pick-text strong { font-size: 14px; font-weight: 600; }
.dreq-pick-text small { font-size: 12px; color: var(--text-2); }
.dreq-upload[data-state="busy"] .dreq-pick { opacity: .55; pointer-events: none; }
.dreq-chosen {
  display: flex; align-items: center; gap: 12px; padding: 8px 10px 8px 8px;
  background: var(--bg-base); border: 1px solid var(--border-strong); border-radius: var(--radius-md);
}
.dreq-thumb {
  width: 52px; height: 52px; flex-shrink: 0; object-fit: contain; border-radius: var(--radius-sm);
  background: repeating-conic-gradient(var(--bg-subtle) 0% 25%, var(--bg-base) 0% 50%) 50% / 12px 12px;
  border: 1px solid var(--border);
}
.dreq-fname { flex: 1; min-width: 0; font-size: 13px; color: var(--text-1); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dreq-remove {
  min-height: 44px; padding: 0 8px; background: none; border: 0; cursor: pointer;
  font: inherit; font-size: 13px; color: var(--text-2); text-decoration: underline;
}
.dreq-remove:hover { color: var(--text-1); }
.dreq-actions { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.dreq-note { margin: 0; font-size: 12px; color: var(--text-2); }
.dreq--done {
  max-width: none; flex-direction: row; align-items: center; gap: 8px;
  padding: 10px 14px; border-radius: var(--radius-full); width: fit-content;
  background: var(--bg-subtle); border-color: var(--border); font-size: 13px; color: var(--text-2);
}
.dreq--done .ph { font-size: 16px; color: var(--accent); flex-shrink: 0; }

@media (max-width: 480px) {
  .dreq { padding: var(--space-4); max-width: none; }
  .dreq-actions .appr-btn { flex: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .dreq-input, .dreq-pick { transition: none; }
}


/* Screenshot and live preview of a page the sandbox browser test ran */
.sbx-preview { display: flex; flex-direction: column; gap: 8px; }
.sbx-preview-stage { border: 1px solid var(--border, rgba(127,127,127,.3)); border-radius: 8px; overflow: hidden; background: #fff; max-width: 100%; }
.sbx-shot { display: block; width: 100%; height: auto; max-height: 420px; object-fit: contain; object-position: top left; }
.sbx-preview-stage.is-live .sbx-shot { display: none; }
.sbx-live { display: block; width: 100%; border: 0; background: #fff; resize: vertical; }
.sbx-preview-toggle { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; font: inherit; font-size: 13px; padding: 6px 12px; border-radius: 8px; border: 1px solid var(--border, rgba(127,127,127,.35)); background: transparent; color: inherit; }
.sbx-preview-toggle:focus-visible { outline: 2px solid var(--accent, #4c8dff); outline-offset: 2px; }
