/* "Choose from Media Studio" (Media Studio MP-02; formerly "From Video Studio") — choose a video or photo (skia-video-backgrounds MP-03; frozen screen 13, clip sets 13b), owned and served
   by Video Studio for both apps (animated-videos MP-04, moved from SKIA's public/css/video-picker.css unchanged).
   SKIA's colour, spacing and type settings only (SKIA Rule 10): SKIA has them; Video Studio's pages set them from its
   own colours in video-windows-studio.css.
   The frame and header are SKIA's window frame (ai-design-modal.css); the error cards are Find a photo's
   (photo-picker-modal.css). */

.ai-design-modal.video-picker-modal {
    max-width: 1200px;
    height: 85vh;
}

.video-picker-header {
    align-items: flex-start;
    padding: var(--space-lg) calc(var(--space-lg) + var(--space-xs)) calc(var(--space-sm) + var(--space-xs) * 1.5); /* frozen 13: 24 / 28, 14 above the tabs */
    border-bottom: none; /* frozen 13: no line under the title */
}

.video-picker-modal .ai-design-close,
.ai-video-modal .ai-design-close,
.video-upload-modal .ai-design-close {
    width: 44px; /* frozen 13, 14 and 15: a 44 × 44 close button */
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: calc(var(--font-2xl) - var(--space-xs) / 2); /* frozen 13: 22px */
}

.video-picker-titles {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
}

.video-picker-modal .video-picker-title,
.ai-video-modal .video-picker-title,
.video-upload-modal .video-picker-title { /* frozen 13, 14 and 15 */
    font-size: var(--font-2xl);
    font-weight: var(--font-bold);
}

.video-picker-subtitle {
    font-size: var(--font-sm);
    color: color-mix(in srgb, var(--color-text-primary) 78%, transparent); /* frozen 13: white at 0.78 */
}

.video-picker-body {
    flex: 1;
    min-height: 0;
    display: flex;
    gap: var(--space-lg);
    padding: 0 calc(var(--space-lg) + var(--space-xs)) var(--space-lg); /* frozen 13: 28 at the sides */
}

.video-picker-list {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: calc(var(--space-sm) + var(--space-xs)); /* frozen 13: 12 */
    overflow-y: auto;
}

/* Tabs: All · Briefs · Explainers · Shorts · Clips (frozen 13: 36px pills; the chosen one bold with a primary ring) */
.video-picker-tabs {
    display: flex;
    gap: var(--space-sm);
}

.video-picker-tab {
    height: 36px;
    padding: 0 var(--space-md);
    border-radius: var(--radius-3xl);
    border: 1px solid color-mix(in srgb, var(--color-text-primary) 25%, transparent); /* frozen 13: white at 0.25 */
    background: transparent;
    color: var(--color-text-primary);
    font-size: calc(var(--font-sm) - var(--space-xs) / 4); /* frozen 13: 13px */
    cursor: pointer;
}

.video-picker-tab.on {
    border: 2px solid var(--color-primary);
    background: color-mix(in srgb, var(--color-primary) 25%, transparent); /* frozen 13: primary at 0.25 */
    font-weight: var(--font-semibold);
}

/* Five across (frozen 13), each card its picture's height, packed into columns as SKIA's Templates list (Masonry; owner
   2026-10-18: "the videos and images in the right proportions") */
.video-picker-grid {
    --picker-gap: calc(var(--space-sm) + var(--space-xs));
    display: block;
    position: relative;
    /* Masonry gives the grid its height; in the scrolling list it must not shrink below it, or the note below sits on the cards */
    flex-shrink: 0;
}

.video-picker-sizer,
.video-picker-card {
    width: calc((100% - 4 * var(--picker-gap)) / 5);
    box-sizing: border-box;
}

.video-picker-gutter {
    width: var(--picker-gap);
}

.video-picker-card {
    margin-bottom: var(--picker-gap);
}

/* A tab with none of its type: one line across the grid (owner 2026-10-04: "A one-line note") */
.video-picker-empty {
    grid-column: 1 / -1;
}

.video-picker-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: calc(var(--space-xs) * 1.5);
    padding: var(--space-sm);
    border-radius: var(--radius-lg);
    border: 1px solid color-mix(in srgb, var(--color-text-primary) 18%, transparent); /* frozen 13: white at 0.18 */
    background: color-mix(in srgb, var(--color-text-primary) 4%, transparent); /* frozen 13: white at 0.04 */
    color: var(--color-text-primary);
    text-align: left;
    cursor: pointer;
}

.video-picker-card.picked {
    border: 3px solid var(--color-primary);
}

.video-picker-card:disabled {
    cursor: not-allowed;
    opacity: 0.55; /* frozen 13: a video longer than 60 seconds */
}

.video-picker-thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 10;
    border-radius: calc(var(--radius-sm) * 1.5);
    overflow: hidden;
}

/* A video without a picture: a grey card (owner 2026-10-04: "Keep grey card") */
.video-picker-thumb.no-picture {
    background: var(--color-border-medium); /* grey in every theme (the glass tokens are near white in the light theme) */
}

.video-picker-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.video-picker-length {
    position: absolute;
    right: calc(var(--space-xs) * 1.5);
    bottom: calc(var(--space-xs) * 1.5);
    height: 22px;
    padding: 0 var(--space-sm);
    border-radius: var(--radius-3xl);
    background: var(--color-mark); /* frozen 13 */
    color: var(--color-white);
    font-size: calc(var(--font-xs) - var(--space-xs) / 4); /* frozen 13: 11px */
    font-weight: var(--font-semibold);
    display: flex;
    align-items: center;
}

.video-picker-name {
    font-size: calc(var(--font-sm) - var(--space-xs) / 4); /* frozen 13: 13px */
    font-weight: var(--font-semibold);
}

.video-picker-type,
.video-picker-flag {
    padding: calc(var(--space-xs) / 2) var(--space-sm);
    border-radius: var(--radius-3xl);
    font-size: calc(var(--font-xs) - var(--space-xs) / 4); /* frozen 13: 11px */
}

.video-picker-type {
    background: var(--color-primary-light);
    border: 1px solid var(--color-primary);
    font-weight: var(--font-semibold);
}

.video-picker-flag {
    background: color-mix(in srgb, var(--color-warning) 18%, transparent); /* frozen 13: amber at 0.18, its edge at 0.55 */
    border: 1px solid color-mix(in srgb, var(--color-warning) 55%, transparent);
}

.video-picker-flag.too-long {
    background: color-mix(in srgb, var(--color-error) 15%, transparent); /* frozen 13: red at 0.15, its edge at 0.6 */
    border: 1px solid color-mix(in srgb, var(--color-error) 60%, transparent);
}

.video-picker-shape {
    font-size: calc(var(--font-xs) - var(--space-xs) / 4); /* frozen 13: 11px */
    color: color-mix(in srgb, var(--color-text-primary) 75%, transparent); /* frozen 13: white at 0.75 */
}

.video-picker-note {
    font-size: var(--font-xs);
    color: color-mix(in srgb, var(--color-text-primary) 75%, transparent);
}

/* The chosen video, cropped to the template's shape (frozen 13: 300 wide) */
.video-picker-side {
    width: 300px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: calc(var(--space-sm) + var(--space-xs) * 1.5);
}

.video-picker-preview {
    position: relative;
    /* The picked item at its own shape, 300 wide or 50vh tall at most (owner 2026-10-18: "not the Preview") */
    aspect-ratio: var(--picked-w) / var(--picked-h);
    width: min(300px, calc(50vh * var(--picked-w) / var(--picked-h)));
    max-height: 50vh;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.video-picker-player {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    background: var(--color-border-medium);
}

.video-picker-picked-name {
    font-size: var(--font-base);
    font-weight: var(--font-semibold);
}

.video-picker-picked-type {
    font-size: calc(var(--font-sm) - var(--space-xs) / 4); /* frozen 13: 13px */
    font-weight: var(--font-semibold);
    color: var(--color-primary-pale); /* frozen 13 */
}

.video-picker-picked-detail {
    font-size: calc(var(--font-sm) - var(--space-xs) / 4); /* frozen 13: 13px */
    color: color-mix(in srgb, var(--color-text-primary) 78%, transparent); /* frozen 13: white at 0.78 */
}

.video-picker-picked-note {
    font-size: var(--font-xs);
    line-height: 1.5;
    color: color-mix(in srgb, var(--color-text-primary) 78%, transparent);
}

.video-picker-use {
    margin-top: auto;
    height: 48px;
    border-radius: var(--radius-md);
    font-size: calc(var(--font-base) - var(--space-xs) / 4); /* frozen 13: 15px */
    font-weight: var(--font-semibold);
}

/* A clip set (frozen 13b): one card, its clips stacked behind the front picture — Video Studio's dashboard set card */
.video-picker-thumb.video-picker-stack {
    background: color-mix(in srgb, var(--color-text-primary) 4%, transparent); /* frozen 13b: white at 0.04 */
}

.video-picker-sheet {
    position: absolute;
    border-radius: calc(var(--radius-sm) * 1.5); /* frozen 13b: 6px */
    border: 1px solid color-mix(in srgb, var(--color-text-primary) 30%, transparent); /* frozen 13b: white at 0.3 */
    overflow: hidden;
}

.video-picker-sheet.back { /* frozen 13b: 8 / 12 / 26 / 40 */
    inset: var(--space-sm) calc(var(--space-sm) + var(--space-xs)) calc(var(--space-lg) + var(--space-xs) / 2) calc(var(--space-xl) + var(--space-sm));
    background: color-mix(in srgb, var(--color-text-primary) 10%, transparent);
}

.video-picker-sheet.middle { /* frozen 13b: 15 / 22 / 19 / 30 */
    inset: calc(var(--space-md) - var(--space-xs) / 4) calc(var(--space-lg) - var(--space-xs) / 2) calc(var(--space-md) + var(--space-xs) * 0.75) calc(var(--space-xl) - var(--space-xs) / 2);
    background: color-mix(in srgb, var(--color-text-primary) 16%, transparent);
}

.video-picker-sheet.front { /* frozen 13b: 22 / 32 / 12 / 20, its shadow 0 2 8 at 0.55 */
    inset: calc(var(--space-lg) - var(--space-xs) / 2) var(--space-xl) calc(var(--space-sm) + var(--space-xs)) calc(var(--space-md) + var(--space-xs));
    box-shadow: 0 calc(var(--space-xs) / 2) var(--space-sm) color-mix(in srgb, var(--color-black) 55%, transparent);
}

.video-picker-sheet.front img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* The opened set: "← [tab]", then the set's name and "5 clips · [shape]" (frozen 13b) */
.video-picker-tabs.video-picker-set-head {
    align-items: center;
    gap: var(--space-md);
}

.video-picker-set-titles {
    display: flex;
    flex-direction: column;
    gap: calc(var(--space-xs) / 2);
}

.video-picker-set-name {
    margin: 0;
    font-size: var(--font-lg); /* frozen 13b: 18px */
    font-weight: var(--font-bold);
}

.video-picker-set-detail {
    font-size: var(--font-xs);
    color: color-mix(in srgb, var(--color-text-primary) 75%, transparent); /* frozen 13b: white at 0.75 */
}

/* Eight tabs (Media Studio MP-02, Photos after Animations): they keep their size and scroll sideways when the list is
   narrower than they are (frozen media-studio ChoosePhone.dc.html) */
.video-picker-tabs:not(.video-picker-set-head) {
    flex-shrink: 0; /* scrolling sideways, the row would otherwise shrink to nothing in the list's column */
    overflow-x: auto;
}

.video-picker-tab {
    flex-shrink: 0;
}

/* The photo preview popup (Media Studio MP-02, photo-preview.js): the photo full size and a close button */
.ai-design-modal.photo-preview-modal {
    position: relative;
    width: auto;
    max-width: 90vw;
    max-height: 90vh;
    padding: var(--space-md);
}

.photo-preview-modal .photo-preview-close {
    position: absolute;
    top: var(--space-md);
    right: var(--space-md);
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-3xl);
    background: var(--color-mark);
    color: var(--color-white);
    font-size: calc(var(--font-2xl) - var(--space-xs) / 2);
    opacity: 1;
}

.photo-preview-img {
    display: block;
    max-width: calc(90vw - var(--space-md) * 2);
    max-height: calc(90vh - var(--space-md) * 2);
    object-fit: contain;
    border-radius: var(--radius-lg);
}

/* Phone width (frozen media-studio ChoosePhone.dc.html): one column — the cards two across, then the chosen one as a row
   (its picture 96 × 54, its words) above the notes and the button */
@media (max-width: 600px) {
    .ai-design-modal.video-picker-modal {
        height: 90vh;
    }

    .video-picker-header {
        padding: var(--space-md) var(--space-md) var(--space-sm); /* frozen: 16 / 16 / 8 */
    }

    .video-picker-body {
        flex-direction: column;
        gap: 0;
        padding: 0;
    }

    .video-picker-list {
        padding: 0 var(--space-md);
    }

    .video-picker-grid {
        --picker-gap: calc(var(--space-sm) + var(--space-xs) / 2); /* frozen: 10 */
    }

    .video-picker-sizer,
    .video-picker-card {
        width: calc((100% - var(--picker-gap)) / 2);
    }

    .video-picker-side {
        width: auto;
        display: grid;
        grid-template-columns: 96px minmax(0, 1fr);
        column-gap: calc(var(--space-sm) + var(--space-xs)); /* frozen: 12 */
        row-gap: calc(var(--space-xs) / 2);
        padding: calc(var(--space-sm) + var(--space-xs)) var(--space-md) var(--space-md); /* frozen: 12 / 16 / 16 */
        border-top: 1px solid var(--color-border-subtle);
    }

    .video-picker-side:empty {
        display: none;
    }

    .video-picker-preview {
        width: auto;
        height: 54px;
        grid-row: span 3;
        border-radius: calc(var(--radius-sm) * 1.5); /* frozen: 6 */
    }

    .video-picker-picked-note,
    .video-picker-use {
        grid-column: 1 / -1;
        margin-top: calc(var(--space-sm) + var(--space-xs) / 2);
    }
}

/* A website's picker (Media Studio MP-03, frozen ChooseSite.dc.html): "Upload a video" and "Make an AI Video" beside the close
   button */
.video-picker-actions {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.video-picker-action {
    height: 36px;
    padding: 0 var(--space-md);
    border-radius: var(--radius-md);
    font-size: calc(var(--font-sm) - var(--space-xs) / 4); /* 13px */
}

@media (max-width: 600px) {
    .video-picker-header {
        flex-wrap: wrap;
    }

    .video-picker-actions {
        order: 3;
        width: 100%;
        margin-left: 0;
    }

    .video-picker-action {
        flex: 1;
    }
}

/* A Workshop's documents: one step over the chat (frozen biq-docs slide-decks-v2 board 06a ChooseUseAs; light, dark and phone).
   Tokens only: the windows' settings, each opener's; the --ms-* sizes, each app's theme file's; and the accent the frozen board draws. A same-line om-allow says why where no token fits. */
.ai-design-overlay.video-docs-overlay {
    align-items: flex-start; /* frozen: the window from the top, the page scrolling behind it if it is taller */
    overflow-y: auto;
    padding: var(--space-lg) var(--space-md); /* frozen: 24 / 16 */
    box-sizing: border-box;
}

.ai-design-overlay .ai-design-modal.video-docs-modal {
    width: 100%;
    max-width: 1200px; /* om-allow: frozen 06a, the window's width; used once */
    max-height: none;
    overflow: visible;
    box-sizing: border-box;
    padding: var(--space-lg) calc(var(--space-lg) + var(--space-xs)); /* frozen: 24 / 28 */
    gap: calc(var(--space-sm) + var(--space-xs) * 1.5); /* frozen: 14 */
    outline: none;
}

.video-docs-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: calc(var(--space-sm) + var(--space-xs)); /* frozen: 12 */
}

.video-docs-head .video-picker-titles {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
    min-width: 0;
}

.video-docs-head-actions {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    flex-shrink: 0;
}

.video-docs-upload {
    min-height: var(--ms-control); /* frozen: 38 */
    box-sizing: border-box;
    padding: 0 var(--ms-14);
    border: 0;
    border-radius: var(--radius-md);
    background: var(--th-accent-primary);
    color: var(--th-accent-on-primary);
    font: inherit;
    font-size: var(--font-sm);
    font-weight: var(--font-semibold);
    white-space: nowrap;
    cursor: pointer;
}

.video-docs-modal .ai-design-close {
    width: var(--ms-touch); /* frozen: 44 × 44 */
    height: var(--ms-touch);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
}

.video-docs-guide-name {
    font-size: calc(var(--font-sm) - var(--space-xs) / 4); /* frozen: 13 */
    font-weight: var(--font-semibold);
    color: var(--th-on-surface-muted);
}

.video-docs-title {
    margin: 0;
    font-size: var(--font-2xl);
    font-weight: var(--font-bold);
}

.video-docs-line {
    font-size: var(--font-sm);
    color: var(--th-on-surface-muted);
}

/* The row: the one shared toolbar (cards or list first, as the board draws it) and the All | Uploads | Links switch on the right */
.video-docs-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: nowrap;
    gap: calc(var(--space-sm) + var(--space-xs)); /* frozen: 12 */
}

.video-docs-row .tab-row,
.video-docs-types .type-filter {
    margin: 0;
}

.video-docs-row .tab-row {
    flex: 1 1 auto;
    min-width: 0;
}

.video-docs-row .tab-row-actions {
    flex: 1 1 auto;
    gap: calc(var(--space-sm) + var(--space-xs) / 2); /* frozen: 10 */
    flex-wrap: nowrap;
}

.video-docs-row .view-switch {
    order: -1; /* frozen 06a: cards or list before the search */
}

.video-docs-row .search-input {
    flex: 0 1 240px; /* om-allow: frozen 06a, the search's width; used once */
    width: auto;
    min-width: 0;
}

.video-docs-body {
    display: flex;
    gap: var(--space-lg);
    flex-wrap: nowrap;
    align-items: stretch;
    height: 560px; /* om-allow: frozen 06a, the two panes' height; used once */
}

.video-docs-list {
    flex: 999 1 560px; /* om-allow: frozen 06a, the list's least width; used once */
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: calc(var(--space-sm) + var(--space-xs)); /* frozen: 12 */
}

.video-docs-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-auto-rows: max-content; /* every card keeps its full height (its name and lines); more cards than fit scroll, never shrink */
    gap: calc(var(--space-sm) + var(--space-xs)); /* frozen: 12 */
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    align-content: start;
    padding: calc(var(--space-xs) / 2) var(--space-xs) calc(var(--space-xs) / 2) calc(var(--space-xs) / 2); /* frozen: 2 / 4 / 2 / 2 */
}

.video-docs-grid.is-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.video-docs-card {
    display: flex;
    flex-direction: column;
    padding: 0;
    overflow: hidden;
    box-sizing: border-box;
    text-align: left;
    border-radius: var(--radius-xl);
    border: var(--ms-2) solid var(--th-edge);
    background: var(--th-surface);
    color: var(--th-on-surface);
    font: inherit;
    cursor: pointer;
}

.video-docs-card:hover:not(:disabled) {
    background: var(--th-surface-hover);
}

.video-docs-card.on {
    border-color: var(--th-accent-primary);
}

.video-docs-card:disabled {
    cursor: default;
    opacity: 1; /* frozen: a refused card is drawn at full strength, so its sentence reads */
}

/* The card's face: its kind, the badge top left, the tick top right; a list shows none (board 06a's faceShow) */
.video-docs-face {
    position: relative;
    display: flex;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: var(--th-surface-chip); /* board 06a's surface-dim (#f3f4f6 light, #374151 dark): AI Slide Decks' chip surface, the only opener of this mode */
    color: var(--th-on-surface-faint);
    align-items: center;
    justify-content: center;
    font-size: calc(var(--font-2xl) - var(--space-xs) / 2); /* frozen: 22 */
    font-weight: 800; /* om-allow: frozen 06a, the kind's weight; used once */
    letter-spacing: 0.04em; /* om-allow: frozen 06a, the kind's spacing; used once */
}

.video-docs-grid.is-list .video-docs-face {
    display: none;
}

.video-docs-badge {
    position: absolute;
    left: var(--space-sm);
    top: var(--space-sm);
    padding: calc(var(--space-xs) / 2) var(--space-sm); /* frozen: 2 / 8 */
    border-radius: var(--radius-3xl);
    font-size: var(--font-xs);
    font-weight: var(--font-semibold);
    letter-spacing: 0;
}

.video-docs-badge.ready {
    background: var(--th-ok-bg);
    color: var(--th-ok-text);
}

.video-docs-badge.reading {
    background: var(--th-blue-soft);
    color: var(--th-blue-text);
}

.video-docs-badge.refused {
    background: var(--th-bad-bg);
    color: var(--th-bad-text);
}

.video-docs-badge.archived {
    background: var(--th-surface);
    color: var(--th-on-surface-muted);
}

.video-docs-box {
    position: absolute;
    right: var(--space-sm);
    top: var(--space-sm);
    width: calc(var(--ms-tick) + var(--space-xs)); /* frozen 06a: 26 */
    height: calc(var(--ms-tick) + var(--space-xs));
    box-sizing: border-box;
    border-radius: calc(var(--radius-sm) * 1.5); /* frozen: 6 */
    border: var(--ms-2) solid var(--th-edge-strong);
    background: var(--th-surface);
    color: var(--th-accent-on-primary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.video-docs-card.on .video-docs-box {
    border-color: var(--th-accent-primary);
    background: var(--th-accent-primary);
}

.video-docs-text {
    padding: calc(var(--space-sm) + var(--space-xs)) var(--ms-14); /* frozen: 12 / 14 */
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
}

.video-docs-name {
    font-size: calc(var(--font-sm) + var(--space-xs) / 4); /* frozen: 15 */
    font-weight: var(--font-bold);
}

.video-docs-meta {
    font-size: calc(var(--font-sm) - var(--space-xs) / 4); /* frozen: 13 */
    color: var(--th-on-surface-muted);
}

.video-docs-reason {
    font-size: calc(var(--font-sm) - var(--space-xs) / 4); /* frozen: 13 */
    line-height: 1.4;
    color: var(--th-on-surface-faint);
}

.video-docs-reason.is-reason {
    color: var(--th-on-surface);
}

/* A chosen document's use (board 06a): on its card, and on the person's answer (on-blue) */
.video-docs-tag {
    align-self: flex-start;
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    padding: calc(var(--space-xs) / 2) var(--space-sm); /* frozen: 2 / 8 */
    border-radius: var(--radius-3xl);
    background: var(--th-blue-soft);
    color: var(--th-blue-text);
    font-size: var(--font-xs);
    font-weight: var(--font-semibold);
}

.video-docs-tag.on-blue {
    background: var(--th-surface);
}

.video-docs-empty {
    font-size: var(--font-sm);
    color: var(--th-on-surface-muted);
}

/* No documents yet (board 06a's noDocs) */
.video-docs-guide {
    box-sizing: border-box;
    padding: var(--space-lg);
    border-radius: var(--radius-xl);
    border: var(--ms-2) dashed var(--th-edge-strong);
    display: flex;
    flex-direction: column;
    gap: calc(var(--space-sm) + var(--space-xs) * 1.5); /* frozen: 14 */
}

.video-docs-guide.over {
    border-color: var(--th-accent-primary);
}

.video-docs-guide-title {
    margin: 0;
    font-size: var(--font-lg);
    font-weight: var(--font-bold);
}

.video-docs-guide-part {
    display: flex;
    flex-direction: column;
    gap: calc(var(--space-xs) / 2); /* frozen: 2 */
}

.video-docs-guide-value {
    font-size: calc(var(--font-sm) + var(--space-xs) / 4); /* frozen: 15 */
    line-height: 1.45;
}

.video-docs-guide-drop {
    font-size: calc(var(--font-sm) - var(--space-xs) / 4); /* frozen: 13 */
    color: var(--th-on-surface-muted);
}

/* The side: "Your documents (N)", each chosen one with its Use as, then the line, the note and Use these, full height */
.video-docs-chosen {
    flex: 1 1 280px; /* om-allow: frozen 06a, the side's least width; used once */
    min-width: 0;
    min-height: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-sizing: border-box;
    border-radius: var(--radius-xl);
    background: var(--th-surface-alt);
    border: var(--ms-1) solid var(--th-edge);
}

.video-docs-chosen[hidden] {
    display: none;
}

.video-docs-chosen-title {
    padding: var(--ms-14) var(--space-md) var(--space-sm); /* frozen: 14 / 16 / 8 */
    font-size: calc(var(--font-sm) + var(--space-xs) / 4); /* frozen: 15 */
    font-weight: var(--font-bold);
}

.video-docs-picks {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 0 var(--space-md) var(--ms-10); /* frozen: 0 / 16 / 10 */
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

.video-docs-pick {
    display: flex;
    flex-direction: column;
    gap: var(--ms-6);
    padding: var(--ms-10) calc(var(--space-sm) + var(--space-xs)); /* frozen: 10 / 12 */
    border-radius: var(--radius-lg);
    background: var(--th-surface);
    border: var(--ms-1) solid var(--th-edge);
    cursor: pointer;
}

.video-docs-pick.open {
    border-color: var(--th-accent-primary);
}

.video-docs-pick-name {
    font-size: var(--font-sm);
    font-weight: var(--font-semibold);
}

.video-docs-pick-use {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.video-docs-pick-use svg {
    flex-shrink: 0;
    color: var(--th-blue-text);
}

.video-docs-use,
.video-docs-other {
    min-width: 0;
    min-height: var(--ms-control); /* frozen: 38 */
    box-sizing: border-box;
    border: var(--ms-1) solid var(--th-edge-strong);
    border-radius: var(--radius-md);
    background: var(--th-surface);
    color: var(--th-on-surface);
    font: inherit;
    font-size: calc(var(--font-sm) - var(--space-xs) / 4); /* frozen: 13 */
}

.video-docs-use {
    flex: 1;
    padding: 0 var(--space-sm);
}

.video-docs-other {
    padding: var(--space-sm) var(--ms-10); /* frozen: 8 / 10 */
}

.video-docs-pick-more {
    display: flex;
    flex-direction: column;
    gap: var(--ms-6);
}

.video-docs-pick-more[hidden] {
    display: none;
}

.video-docs-use-line {
    font-size: calc(var(--font-sm) - var(--space-xs) / 4); /* frozen: 13 */
    line-height: 1.4;
    color: var(--th-on-surface-muted);
}

.video-docs-chosen-foot {
    padding: calc(var(--space-sm) + var(--space-xs)) var(--space-md) var(--ms-14); /* frozen: 12 / 16 / 14 */
    border-top: var(--ms-1) solid var(--th-edge);
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    background: var(--th-surface-alt);
}

.video-docs-chosen-none,
.video-docs-mix,
.video-docs-chosen-note {
    font-size: calc(var(--font-sm) - var(--space-xs) / 4); /* frozen: 13 */
    line-height: 1.45;
    color: var(--th-on-surface-muted);
}

.video-docs-go {
    min-height: var(--ms-tall); /* frozen: 48 */
    border: 0;
    border-radius: var(--radius-md);
    background: var(--th-accent-primary);
    color: var(--th-accent-on-primary);
    font: inherit;
    font-size: calc(var(--font-sm) + var(--space-xs) / 4); /* frozen: 15 */
    font-weight: var(--font-semibold);
    cursor: pointer;
}

.video-docs-go:disabled {
    cursor: default;
    opacity: 0.5; /* om-allow: board 06a draws an off button (Add link) at half strength; used once */
}

/* "+ Add link" beside + Upload (board 06a): the accent's edge, the window's surface */
.video-docs-add-link {
    min-height: var(--ms-control); /* frozen: 38 */
    box-sizing: border-box;
    padding: 0 var(--ms-14);
    border: var(--ms-1) solid var(--th-accent-primary);
    border-radius: var(--radius-md);
    background: var(--th-surface);
    color: var(--th-on-surface);
    font: inherit;
    font-size: var(--font-sm);
    font-weight: var(--font-semibold);
    white-space: nowrap;
    cursor: pointer;
}

.video-docs-add-link:hover {
    background: var(--th-surface-hover);
}

/* "Add a reference link" (frozen biq-docs slide-decks-v2 board 03 ReferenceAddLink; board 06a): one window for Reference material and
   the Choose window, over everything, from the top. Tokens only, as above. */
.ai-design-overlay.video-link-overlay {
    align-items: flex-start;
    overflow-y: auto;
    padding: var(--ms-tall) var(--ms-16); /* frozen: 48 / 16 */
    box-sizing: border-box;
    z-index: 60; /* om-allow: above the Choose window it may be opened from; used once */
}

.ai-design-overlay .ai-design-modal.video-link-modal {
    width: 100%;
    max-width: 560px; /* om-allow: frozen board 03, the window's width; used once */
    max-height: none;
    overflow: visible;
    padding: 0;
    gap: 0;
    border-radius: var(--radius-xl); /* frozen: 12 */
    outline: none;
}

.video-link-head {
    padding: calc(var(--ms-16) + var(--ms-2)) var(--space-lg); /* frozen: 18 / 24 */
    border-bottom: var(--ms-1) solid var(--th-edge);
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: var(--ms-12);
}

.video-link-titles {
    display: flex;
    flex-direction: column;
    gap: var(--ms-4);
    min-width: 0;
}

.video-link-title {
    margin: 0;
    font-size: var(--font-lg); /* frozen: 18 */
    font-weight: var(--font-semibold);
}

.video-link-line {
    margin: 0;
    font-size: var(--font-sm);
    color: var(--th-on-surface-muted);
}

.video-link-modal .ai-design-close {
    width: var(--ms-touch); /* frozen: 44 × 44 */
    height: var(--ms-touch);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    color: var(--th-on-surface-muted);
}

.video-link-body {
    padding: calc(var(--ms-16) + var(--ms-2)) var(--space-lg); /* frozen: 18 / 24 */
    display: flex;
    flex-direction: column;
    gap: calc(var(--ms-16) + var(--ms-2)); /* frozen: 18 */
}

.video-link-said:empty {
    display: none;
}

.video-link-alert {
    padding: var(--ms-10) var(--ms-12);
    border-radius: var(--radius-md);
    background: var(--th-bad-bg);
    color: var(--th-bad-text);
    font-size: var(--font-sm);
    line-height: 1.45; /* om-allow: frozen board 03, the alert's line height; used once */
}

.video-link-label {
    display: flex;
    flex-direction: column;
    gap: var(--ms-4);
    font-size: var(--ms-text-13);
    font-weight: var(--font-semibold);
    color: var(--th-on-surface);
}

.video-link-input {
    min-height: calc(var(--ms-control) + var(--ms-2)); /* frozen: 40 */
    box-sizing: border-box;
    padding: var(--ms-8) var(--ms-10);
    border: var(--ms-1) solid var(--th-edge-strong);
    border-radius: var(--radius-md);
    background: var(--th-surface);
    color: var(--th-on-surface);
    font: inherit;
    font-size: var(--font-sm);
    font-weight: normal;
}

.video-link-look {
    padding: var(--ms-10) var(--ms-12);
    resize: vertical;
}

.video-link-foot {
    padding: var(--ms-16) var(--space-lg); /* frozen: 16 / 24 */
    background: var(--th-surface-alt);
    border-top: var(--ms-1) solid var(--th-edge);
    border-radius: 0 0 var(--radius-xl) var(--radius-xl);
    display: flex;
    justify-content: flex-end;
    gap: var(--ms-12);
    flex-wrap: wrap;
}

.video-link-cancel,
.video-link-add {
    min-height: var(--ms-touch); /* frozen: 44 */
    padding: var(--ms-8) var(--ms-16);
    border-radius: var(--radius-md);
    font: inherit;
    font-size: var(--font-sm);
    cursor: pointer;
}

.video-link-cancel {
    border: var(--ms-1) solid var(--th-edge-strong);
    background: transparent;
    color: var(--th-on-surface-dim);
}

.video-link-cancel:hover {
    background: var(--th-surface-hover);
}

.video-link-add {
    border: 0;
    background: var(--th-accent-primary);
    color: var(--th-accent-on-primary);
    font-weight: var(--font-semibold);
}

.video-link-add:disabled {
    cursor: default;
    opacity: 0.5; /* om-allow: board 03 draws the off Add link at half strength; used once */
}

/* Board 06a's phone: the window fills the screen, the cards one column, the side under them, the controls 44 high */
@media (max-width: 600px) { /* om-allow: a media query can't read a token */
    .ai-design-overlay.video-docs-overlay {
        padding: 0;
    }

    .ai-design-overlay .ai-design-modal.video-docs-modal {
        padding: var(--space-md);
        border-radius: 0;
        min-height: 100%;
    }

    .video-docs-body {
        flex-wrap: wrap;
        height: auto;
    }

    .video-docs-row,
    .video-docs-row .tab-row-actions {
        flex-wrap: wrap;
    }

    .video-docs-grid,
    .video-docs-grid.is-list {
        grid-template-columns: repeat(1, minmax(0, 1fr));
    }

    .video-docs-upload,
    .video-docs-add-link,
    .video-docs-use,
    .video-docs-other {
        min-height: var(--ms-touch);
    }
}
