/* Phase 3 A10–A12: the upload/check overlay (web/app/upload-overlay.js) and
   the ways to start (/new, home, dashboard; Phase 5 B). The modal
   frame itself (dialog.modal, steps, progress) is in site.css. */

/* ---- overlay body ---- */
.upload-overlay .upload-checks { margin-top: 14px; }
.upload-overlay .upload-checks > p { margin: 0 0 6px; }
.upload-checklist { margin: 0 0 8px; padding-left: 1.3em; display: grid; gap: 3px; font-size: 14px; }
.upload-checklist li::marker { color: var(--ok); }
.upload-ok { font-weight: 600; color: var(--ok); }
.upload-ok a { font-weight: 400; margin-left: 4px; }
.upload-bad { margin: 0 0 10px; color: var(--bad); }
.upload-failures { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; max-height: 45vh; overflow: auto; }
.upload-failures li { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; align-items: center; padding: 8px 10px; border: 1px solid var(--line); border-left: 3px solid var(--bad); border-radius: 0; }
.upload-failures li > * { min-width: 0; overflow-wrap: anywhere; }
.upload-failures li strong { grid-column: 1; }
.upload-failures li .reason { grid-column: 1; font-size: 14px; }
.upload-failures li button { grid-column: 2; grid-row: 1 / span 3; }

/* ---- ways to start: image comparisons, video comparisons, screenshots ---- */
.start-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 0 0 28px; border: 1px solid var(--line); background: var(--panel); }
.start-card { display: flex; flex-direction: column; gap: 6px; min-width: 0; padding: 16px 20px 20px; border-left: 1px solid var(--line); color: var(--fg); text-decoration: none; }
.start-card:first-child { border-left: 0; }
.start-card strong { font-size: 21px; line-height: 1.15; font-weight: 700; }
.start-card .start-text { color: var(--muted); font-size: 15px; max-width: 36em; }
.start-card:hover, .start-card:focus-visible { background: var(--panel-2); color: var(--fg); }
.start-card:hover strong { color: var(--accent); }
.start-card.images, .start-card.clips { box-shadow: inset 0 3px 0 var(--accent); }
.start-card.images .cap, .start-card.clips .cap { color: var(--accent); }
.start-card.current { box-shadow: inset 0 -3px 0 var(--fg); }
.start-card.current strong { color: var(--fg); }
.start-cards.compact { margin: 12px 0 20px; }
.start-cards.compact .start-card { padding: 10px 14px 12px; gap: 3px; }
.start-cards.compact strong { font-size: 17px; }
.start-cards.compact .start-text { font-size: 13px; }
.image-upload-modes { margin-bottom: 16px; }
.image-upload-modes a { display: flex; align-items: center; min-height: 44px; }
/* A longer upload method must not shift the page when its scrollbar appears. */
html:has(.image-upload-modes, #video-new) { scrollbar-gutter: stable; }

/* ---- /new: the image boxes (images-boxes.js), then the auto-grid under Advanced ---- */
.images-box-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.images-box-source { border-top: 3px solid var(--accent-line); }
.images-count { margin: 10px 0 6px; display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: baseline; }
.images-count code { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1 1 10em; }
.images-skipped { margin: 8px 0 0; overflow-wrap: anywhere; color: var(--warn); }
.images-review td .warn { color: var(--warn); }
.images-drop-row { margin-top: 6px; white-space: nowrap; }
.images-add { min-height: 64px; border: 1px dashed var(--control-line); background: transparent; font: 12px var(--ui); letter-spacing: .08em; text-transform: uppercase; }
.images-review .banner { margin: 0 0 8px; }

/* ---- /video/new (video/video-new.js) ---- */
.video-modes { margin: 4px 0 6px; }
.video-previews .video-preview { display: block; width: 100%; height: auto; margin-top: 6px; background: #000; }
.video-cut-list { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 4px; }
.video-cut-list li { min-width: 0; overflow-wrap: anywhere; }
.images-file { display: flex; gap: 6px; align-items: center; margin-top: 4px; max-width: 200px; }
.images-file code { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.advanced-create { margin: 28px 0 12px; border-top: 1px solid var(--line); padding-top: 12px; }
.advanced-create > summary { font: 12px/1.8 var(--ui); letter-spacing: .1em; text-transform: uppercase; cursor: pointer; }

@media (max-width: 720px) {
  .start-cards { grid-template-columns: 1fr; }
  .start-card { border-left: 0; border-top: 1px solid var(--line); }
  .start-card:first-child { border-top: 0; }
  .start-card strong, .start-cards.compact strong { font-size: 18px; }
  .start-cards.compact .start-text { display: none; }
  .upload-failures li { grid-template-columns: 1fr; }
  .upload-failures li button { grid-column: 1; grid-row: auto; justify-self: start; }
}
