/* Site pieces the design system bundle does not cover. Same tokens, same rules. */
body { padding: 0; display: flex; flex-direction: column; min-height: 100vh; }
a { color: inherit; }
.site { flex: 1; box-sizing: border-box; width: 100%; max-width: 1120px; margin: 0 auto; padding: var(--space-3) var(--space-4) var(--space-7); }
.dd-nav a { text-decoration: none; }
.dd-nav form.dd-search-form { flex: 1; min-width: 0; display: flex; }
.nav-actions { display: flex; align-items: center; gap: var(--space-2); }
.dd-btn { text-decoration: none; }
.inline { display: inline; margin: 0; }
.dd-chips a.dd-chip { display: inline-flex; align-items: center; text-decoration: none; }
.dd-chip[aria-current="true"] { background: var(--ink); color: var(--paper); }
.flash { margin: 0 0 var(--space-3); padding: var(--space-2) var(--space-3); font-size: 14px; line-height: 20px; background: var(--paper-raised); border-radius: var(--radius-md); }
.thumb-img, .dd-clip canvas { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; background: var(--stage); }
.thumb-tall { aspect-ratio: 9 / 16; }
a.dd-clip { text-decoration: none; }
.grid-tall { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: var(--space-5) var(--space-3); }
.pager { display: flex; gap: var(--space-2); justify-content: center; margin-top: var(--space-6); }
/* The footer sits on the stage colour in both themes, so it sets its own ink. */
.site-footer { --ink: var(--stage-ink); --accent-text: var(--accent); --footer-dim: color-mix(in srgb, var(--sky) 62%, var(--stage)); --footer-line: rgba(184, 206, 224, .08); border-top: 1px solid var(--footer-line); background: var(--stage); color: var(--footer-dim); }
.site-footer a, .site-footer__link-btn { color: var(--sky); text-decoration: none; }
.site-footer a:hover, .site-footer__link-btn:hover { color: var(--ink); }
.site-footer__main, .site-footer__bottom { max-width: 1120px; margin: 0 auto; padding-inline: var(--space-4); }
.site-footer__main { display: flex; flex-wrap: wrap; gap: 40px; padding-block: 56px var(--space-6); }
.site-footer__about { flex: 2 1 260px; }
.site-footer__tagline { max-width: 300px; margin: var(--space-4) 0 0; font-size: 14px; line-height: 22px; }
.site-footer__col { flex: 1 1 140px; }
.site-footer__title { font: 700 11px/16px var(--font-display); letter-spacing: .16em; text-transform: uppercase; }
.site-footer__links { display: flex; flex-direction: column; gap: var(--space-2); margin: 14px 0 0; padding: 0; list-style: none; font-size: 14px; line-height: 22px; }
.site-footer__link-btn { padding: 0; border: 0; background: none; font: inherit; cursor: pointer; }
.site-footer__inline { display: flex; flex-wrap: wrap; gap: var(--space-1) 20px; margin: 0; padding: 0; list-style: none; }
.prose ul { padding-left: var(--space-5); }
.prose li + li { margin-top: var(--space-1); }
.prose code { font-size: 13px; }
.site-footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-2) var(--space-5); padding-block: 20px 36px; border-top: 1px solid var(--footer-line); font-size: 12px; line-height: 20px; }
.narrow { max-width: 620px; margin: var(--space-5) auto 0; }
.field { display: flex; flex-direction: column; gap: var(--space-1); }
.field > span { font: 700 14px/20px var(--font-sans); }
.dd-input, select.dd-input { width: 100%; }
.check { display: flex; align-items: flex-start; gap: var(--space-2); font-size: 14px; line-height: 20px; }
.check input { width: 20px; height: 20px; flex: none; accent-color: var(--accent); }

/* Studio additions */
.dd-frame { width: 100%; aspect-ratio: 9 / 16; }
.studio-video { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.cue-row { display: grid; grid-template-columns: auto minmax(0, 1fr) 60px 60px 44px; gap: var(--space-2); align-items: center; }
.cue-row .dd-who { border: 0; min-height: 28px; min-width: 56px; cursor: pointer; }
.cue-row .dd-input { padding: 0 var(--space-2); }
.cue-x { width: 44px; height: 44px; padding: 0; font: 700 18px/1 var(--font-sans); color: var(--ink); background: var(--paper-raised); border: 0; border-radius: 50%; cursor: pointer; }
.progress { height: 8px; margin: var(--space-3) 0; overflow: hidden; background: var(--paper-raised); border-radius: var(--radius-pill); }
.progress > i { display: block; height: 100%; width: 0; background: var(--accent); }
@media (max-width: 520px) { .cue-row { grid-template-columns: auto minmax(0, 1fr) 44px; } .cue-row .cue-text { grid-column: 1 / -1; order: -1; } .cue-times { display: flex; gap: var(--space-2); } }

/* Share page */
.share { display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); gap: var(--space-5); max-width: 900px; margin: var(--space-4) auto 0; }
.share video { display: block; width: 100%; aspect-ratio: 9 / 16; background: var(--stage); border-radius: var(--radius-lg); }
details.report { margin-top: var(--space-5); font-size: 14px; color: var(--ink-muted); }
details.report summary { min-height: 44px; display: inline-flex; align-items: center; cursor: pointer; }
details.report form { display: flex; flex-direction: column; gap: var(--space-2); max-width: 420px; }
@media (max-width: 760px) { .share { grid-template-columns: minmax(0, 1fr); } }

/* Upload */
.upload { display: grid; grid-template-columns: minmax(0, 420px) minmax(0, 1fr); gap: var(--space-5); margin-top: var(--space-4); }
.crop { position: relative; aspect-ratio: 1; overflow: hidden; background: var(--stage); border-radius: var(--radius-lg); touch-action: none; }
.crop canvas { display: block; width: 100%; height: 100%; }
.crop.draggable { cursor: grab; }
.crop-hint { position: absolute; left: 0; right: 0; bottom: var(--space-3); text-align: center; font: 700 12px/18px var(--font-sans); color: var(--stage-ink); text-shadow: 0 1px 3px #000; pointer-events: none; }
.trim { position: relative; height: 56px; margin: var(--space-3) 0 var(--space-1); background: var(--paper-raised); border-radius: var(--radius-sm); touch-action: none; user-select: none; }
.trim-win { position: absolute; top: 0; bottom: 0; background: rgba(85, 212, 63, .28); border: 3px solid var(--accent); border-radius: var(--radius-sm); cursor: grab; }
.trim-h { position: absolute; top: 0; bottom: 0; width: 28px; padding: 0; background: var(--accent); border: 0; cursor: ew-resize; }
.trim-h::after { content: ""; position: absolute; left: 12px; top: 18px; bottom: 18px; width: 3px; background: var(--on-accent); border-radius: 2px; }
.trim-h-a { left: -3px; border-radius: 6px 0 0 6px; }
.trim-h-b { right: -3px; border-radius: 0 6px 6px 0; }
.trim-head { position: absolute; top: 0; bottom: 0; width: 2px; background: var(--ink); pointer-events: none; }
.trim-meta { display: flex; justify-content: space-between; font-size: 13px; line-height: 18px; color: var(--ink-muted); }
.drop { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--space-3); height: 100%; min-height: 240px; padding: var(--space-5); text-align: center; color: var(--stage-ink); }
.drop p { margin: 0; color: var(--stage-ink); }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
@media (max-width: 760px) { .upload { grid-template-columns: minmax(0, 1fr); } }
@media (prefers-reduced-motion: reduce) { .dd-btn { transition: none; } }
