:root { color-scheme: light; font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; color: #16212b; background: #f2f5f7; }
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; }
.guest-only { display: grid; place-items: center; background: #f2f5f7; }
.guest-only main { width: auto; margin: 0; }
.guest-login { display: grid; justify-items: center; gap: 1rem; }
.guest-login-button { min-width: 10rem; text-align: center; }
.guest-login-error { color: #7b310e; }
header { background: #123c4a; color: #fff; padding: 1rem max(1rem, calc((100vw - 72rem) / 2)); display: flex; justify-content: space-between; align-items: baseline; }
header a { color: #fff; text-decoration: none; font-weight: 700; }
header .brand { font-size: 1.2rem; font-weight: 750; }
header span { color: #c7dce3; font-size: .9rem; }
.header-context { display: flex; align-items: center; gap: .6rem; }
.environment-badge { display: inline-flex; padding: .28rem .5rem; border-radius: .35rem; font-size: .7rem; font-weight: 850; letter-spacing: .06em; }
.environment-badge.test { background: #fff0d9; color: #7b4300; }
.environment-badge.production { background: #dff5eb; color: #105f43; }
.environment-badge.mfa-bypass { background: #ffe0e0; color: #921515; border: 1px solid #ff9b9b; }
nav { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem 1rem; margin-inline: auto; }
nav a { color: #c7dce3; }
nav a:hover { color: #fff; }
main { width: min(72rem, calc(100% - 2rem)); margin: 2.5rem auto; flex: 1; }
h1 { margin: 0 0 .5rem; font-size: clamp(2rem, 5vw, 3.4rem); line-height: 1.05; }
h2 { margin-top: 0; }
.lead { color: #52626c; font-size: 1.2rem; margin-bottom: 2rem; }
.card, .metric { background: #fff; border: 1px solid #dce5e8; border-radius: .8rem; box-shadow: 0 8px 28px rgba(31, 55, 65, .06); padding: 1.4rem; }
dl { display: grid; grid-template-columns: minmax(8rem, 1fr) 2fr; gap: .8rem 1rem; }
dt { color: #5b6b74; }
dd { margin: 0; font-weight: 650; }
.status { display: inline-flex; align-items: center; gap: .4rem; }
.status::before { content: ""; width: .65rem; height: .65rem; border-radius: 50%; background: currentColor; }
.ok { color: #16744d; }
.warning { color: #a65d00; }
.hint, .alert, .notice { border-left: .25rem solid #e39a29; background: #fff6e7; padding: .8rem 1rem; }
.alert { color: #7b310e; margin-bottom: 1rem; }
.notice { border-color: #16815a; background: #ecfbf4; color: #105f43; margin-bottom: 1rem; }
.button, button { display: inline-block; border: 0; border-radius: .45rem; padding: .75rem 1rem; background: #14728c; color: #fff; font: inherit; font-weight: 700; text-decoration: none; cursor: pointer; }
.button.secondary, button.secondary { background: #e5ecef; color: #23343c; }
button:disabled { cursor: wait; opacity: .7; }
.form { max-width: 34rem; display: grid; gap: 1rem; }
label { display: grid; gap: .4rem; font-weight: 700; }
input { min-height: 2.8rem; border: 1px solid #aab9c0; border-radius: .4rem; padding: .6rem .7rem; font: inherit; }
select { min-height: 2.8rem; border: 1px solid #aab9c0; border-radius: .4rem; padding: .6rem .7rem; font: inherit; background: #fff; }
input:focus { outline: .18rem solid rgba(20, 114, 140, .25); border-color: #14728c; }
.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 2rem; }
.toolbar h1, .toolbar p { margin-bottom: .25rem; }
.metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.metric { display: grid; gap: .25rem; }
.metric strong { font-size: 2rem; color: #123c4a; }
.metric span { color: #5b6b74; }
.metric-link { color: inherit; text-decoration: none; transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease; }
.metric-link:hover { transform: translateY(-2px); border-color: #a9cbd5; box-shadow: 0 12px 32px rgba(31, 55, 65, .12); }
.metric-link small { color: #14728c; font-weight: 750; }
.actions { display: flex; flex-wrap: wrap; gap: .65rem; align-items: center; }
.form.wide { max-width: 54rem; }
.form-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.table-wrap { overflow-x: auto; background: #fff; border: 1px solid #dce5e8; border-radius: .8rem; margin-top: 1rem; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: .9rem 1rem; border-bottom: 1px solid #e5ecef; vertical-align: top; }
th { color: #52626c; font-size: .82rem; text-transform: uppercase; letter-spacing: .04em; }
tr:last-child td { border-bottom: 0; }
td small { display: block; color: #70818a; margin-top: .2rem; }
.empty { color: #70818a; text-align: center; padding: 2rem; }
.muted { color: #70818a; }
.badge { display: inline-block; padding: .15rem .45rem; border-radius: 1rem; background: #dff5eb; color: #146444; font-size: .75rem; font-weight: 750; }
.badge.urgent { background: #ffe4df; color: #9a281e; }
.stack { display: grid; gap: 1rem; margin-top: 2rem; }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.section-heading h2, .section-heading p { margin-bottom: .25rem; }
.section-heading p { color: #70818a; }
.check { display: flex; grid-template-columns: none; flex-direction: row; align-items: center; gap: .65rem; }
.check.compact { font-size: .9rem; font-weight: 600; }
.check input { min-height: auto; width: 1.1rem; height: 1.1rem; }
fieldset { border: 1px solid #dce5e8; border-radius: .5rem; padding: .8rem 1rem; }
legend { padding: 0 .35rem; font-weight: 700; color: #52626c; }
.danger-zone { max-width: 54rem; margin-top: 1.5rem; padding: 1.2rem; border: 1px solid #e3b9b1; background: #fff7f5; border-radius: .8rem; }
button.danger { background: #a52e24; }
button.link { padding: 0; background: transparent; color: #14728c; }
button.danger-text { color: #a52e24; }
.command-help { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .8rem; }
.command-help p { display: grid; gap: .25rem; margin: 0; padding: .85rem; border-radius: .55rem; background: #f4f8f9; }
.command-help span { color: #5b6b74; font-size: .9rem; line-height: 1.45; }
.command-history { margin-top: 0; }
.command-status { display: inline-flex; align-items: center; gap: .4rem; white-space: nowrap; font-weight: 700; font-size: .86rem; }
.command-status::before { content: ""; width: .55rem; height: .55rem; border-radius: 50%; background: currentColor; }
.command-status.queued, .command-status.leased { color: #a65d00; }
.command-status.succeeded { color: #16744d; }
.command-status.failed { color: #a52e24; }
.command-status.expired, .command-status.cancelled { color: #70818a; }
.confirm-dialog { width: min(34rem, calc(100% - 2rem)); padding: 0; border: 0; border-radius: 1rem; box-shadow: 0 24px 70px rgba(14, 31, 39, .3); color: #16212b; }
.confirm-dialog::backdrop { background: rgba(14, 31, 39, .62); backdrop-filter: blur(2px); }
.confirm-card { display: grid; grid-template-columns: auto 1fr; gap: 1rem; padding: 1.5rem; }
.confirm-card h2 { margin-bottom: .5rem; }
.confirm-card p { margin: 0; line-height: 1.5; }
.confirm-card .hint { margin-top: 1rem; }
.confirm-icon { display: grid; place-items: center; width: 2.6rem; height: 2.6rem; border-radius: 50%; background: #fff0d9; color: #9b5700; font-size: 1.3rem; font-weight: 800; }
.confirm-actions { grid-column: 1 / -1; justify-content: flex-end; padding-top: .25rem; }
.form-dialog { width: min(48rem, calc(100% - 2rem)); max-height: calc(100vh - 2rem); padding: 0; border: 0; border-radius: 1rem; box-shadow: 0 24px 70px rgba(14, 31, 39, .32); color: #16212b; }
.form-dialog.wide-dialog { width: min(58rem, calc(100% - 2rem)); }
.form-dialog::backdrop { background: rgba(14, 31, 39, .68); backdrop-filter: blur(3px); }
.form-dialog-card { display: flex; flex-direction: column; max-height: calc(100vh - 2rem); }
.form-dialog-header { flex: none; display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding: 1.15rem 1.3rem; border-bottom: 1px solid #dce5e8; background: #123c4a; color: #fff; }
.form-dialog-header h2 { margin: 0; }
.form-dialog-header p { margin: .25rem 0 0; color: #c7dce3; line-height: 1.4; }
button.form-dialog-close { flex: none; display: grid; place-items: center; width: 2.5rem; height: 2.5rem; padding: 0; border-radius: 50%; background: #e5ecef; color: #23343c; font-size: 1.6rem; line-height: 1; }
.form-dialog-body { width: 100%; max-width: none; min-height: 0; overflow-y: auto; padding: 1.3rem; }
.form-dialog-actions { justify-content: flex-end; padding-top: .35rem; }
.dialog-danger { flex: none; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem 1.3rem; border-top: 1px solid #e3b9b1; background: #fff7f5; }
.dialog-danger p { margin: .25rem 0 0; color: #78534d; font-size: .9rem; }
.screen-group-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 24rem), 1fr)); gap: 1rem; }
.screen-group-card { min-width: 0; display: flex; flex-direction: column; overflow: hidden; background: #fff; border: 1px solid #dce5e8; border-radius: .85rem; box-shadow: 0 8px 28px rgba(31, 55, 65, .06); }
.screen-group-card.ungrouped { border-style: dashed; background: #fafcfc; }
.screen-group-card-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding: 1.15rem; border-bottom: 1px solid #e5ecef; }
.screen-group-card-header h2 { margin: 0; font-size: 1.15rem; }
.screen-group-card-header p { margin: .3rem 0 0; color: #5b6b74; line-height: 1.45; }
.screen-group-card-header .badge { flex: none; }
.group-screen-list { list-style: none; margin: 0; padding: 0; }
.group-screen-list li + li { border-top: 1px solid #edf1f2; }
.group-screen-list a { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .9rem 1.15rem; color: #16212b; text-decoration: none; }
.group-screen-list a:hover { background: #f3f8f9; }
.group-screen-list strong, .group-screen-list small { display: block; overflow-wrap: anywhere; }
.group-screen-list small { margin-top: .2rem; color: #70818a; }
.group-screen-list .status { flex: none; }
.group-empty { margin: 0; padding: 1.25rem 1.15rem; color: #70818a; }
.screen-group-card-footer { margin-top: auto; display: flex; justify-content: flex-end; padding: .8rem 1.15rem; border-top: 1px solid #e5ecef; background: #fafcfc; }
.quick-actions { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }
.quick-actions p { margin-bottom: 0; color: #5b6b74; }
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 21rem), 1fr)); gap: 1rem; }
.category-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 19rem), 1fr)); gap: 1rem; }
.category-card { min-width: 0; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 1rem; padding: 1.1rem; color: #16212b; text-decoration: none; background: #fff; border: 1px solid #dce5e8; border-radius: .8rem; box-shadow: 0 8px 28px rgba(31, 55, 65, .06); transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease; }
.category-card:hover { transform: translateY(-2px); border-color: #9dc6d1; box-shadow: 0 12px 32px rgba(31, 55, 65, .12); }
.category-card strong, .category-card small { display: block; overflow-wrap: anywhere; }
.category-card small { margin-top: .2rem; color: #70818a; }
.category-icon { display: grid; place-items: center; width: 3.4rem; height: 2.7rem; border-radius: .4rem; background: #e5f4f6; color: #12657b; font-size: .72rem; font-weight: 850; letter-spacing: .08em; }
.category-card.uncategorized .category-icon { background: #f1f3f4; color: #61717a; }
.category-arrow { color: #14728c; font-size: 1.25rem; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: .55rem; margin: 0 0 1rem; color: #70818a; font-size: .9rem; }
.breadcrumbs a { color: #14728c; }
.media-card { min-width: 0; overflow: hidden; background: #fff; border: 1px solid #dce5e8; border-radius: .8rem; box-shadow: 0 8px 28px rgba(31, 55, 65, .06); }
.media-thumbnail { aspect-ratio: 16 / 9; display: grid; place-items: center; align-content: center; gap: .5rem; overflow: hidden; background: linear-gradient(145deg, #e8f1f3, #f7fafb); color: #45616c; font-size: .78rem; font-weight: 800; letter-spacing: .08em; }
.media-thumbnail img { width: 100%; height: 100%; object-fit: cover; }
.media-type-icon { display: grid; place-items: center; min-width: 4.2rem; min-height: 3.2rem; padding: .5rem; border-radius: .55rem; background: #fff; color: #123c4a; box-shadow: 0 5px 18px rgba(31, 55, 65, .1); font-size: 1rem; }
.media-card-body { display: grid; gap: 1rem; padding: 1.1rem; }
.media-card-title { display: flex; justify-content: space-between; align-items: flex-start; gap: .8rem; }
.media-card-title h2 { margin: 0; overflow-wrap: anywhere; font-size: 1rem; line-height: 1.35; }
.media-card-title p { margin: .2rem 0 0; color: #70818a; font-size: .78rem; overflow-wrap: anywhere; }
.media-status { flex: none; padding: .25rem .5rem; border-radius: 999px; font-size: .72rem; font-weight: 800; }
.media-status.ready { background: #dff5eb; color: #146444; }
.media-status.uploaded, .media-status.processing { background: #fff0d9; color: #8a5108; }
.media-status.failed, .media-status.quarantined { background: #ffe4df; color: #9a281e; }
.media-meta { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; margin: 0; }
.media-meta div { min-width: 0; padding: .65rem; border-radius: .5rem; background: #f4f8f9; }
.media-meta dt { font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; }
.media-meta dd { margin-top: .2rem; font-size: .88rem; overflow-wrap: anywhere; }
.media-card-actions { min-height: 2.8rem; justify-content: space-between; }
.media-unavailable { font-size: .86rem; }
.media-empty { grid-column: 1 / -1; }
.media-empty p { color: #5b6b74; }
.media-dialog { width: min(68rem, calc(100% - 2rem)); max-height: calc(100vh - 2rem); padding: 0; border: 0; border-radius: 1rem; box-shadow: 0 24px 70px rgba(14, 31, 39, .35); color: #16212b; }
.media-dialog::backdrop { background: rgba(14, 31, 39, .72); backdrop-filter: blur(3px); }
.media-dialog-card { display: grid; grid-template-rows: auto minmax(12rem, 1fr) auto; max-height: calc(100vh - 2rem); }
.media-dialog-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; padding: 1.1rem 1.25rem; border-bottom: 1px solid #dce5e8; }
.media-dialog-header h2 { margin: 0; overflow-wrap: anywhere; }
.media-dialog-header p { margin: .25rem 0 0; color: #70818a; }
button.media-dialog-close { display: grid; place-items: center; width: 2.5rem; height: 2.5rem; padding: 0; border-radius: 50%; background: #e5ecef; color: #23343c; font-size: 1.6rem; line-height: 1; }
.media-dialog-stage { min-height: 12rem; display: grid; place-items: center; overflow: auto; background: #172127; }
.media-dialog-stage img, .media-dialog-stage video { display: block; max-width: 100%; max-height: calc(100vh - 13rem); object-fit: contain; }
.media-dialog-stage iframe { width: 100%; height: min(70vh, 50rem); border: 0; background: #fff; }
.media-dialog-actions { justify-content: flex-end; padding: 1rem 1.25rem; border-top: 1px solid #dce5e8; }
.upload-form { max-width: 46rem; }
.media-category-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.upload-dropzone { min-height: 12rem; place-items: center; align-content: center; padding: 1.5rem; border: 2px dashed #9bb6bf; border-radius: .75rem; background: #f7fafb; color: #123c4a; text-align: center; cursor: pointer; transition: border-color .15s ease, background .15s ease; }
.upload-dropzone:hover, .upload-dropzone:focus-within { border-color: #14728c; background: #edf7fa; }
.upload-dropzone input { position: absolute; width: 1px; height: 1px; min-height: 0; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.upload-dropzone span { max-width: 100%; color: #52626c; font-weight: 600; overflow-wrap: anywhere; }
.upload-progress { display: grid; gap: .5rem; padding: .85rem 1rem; border-radius: .6rem; background: #edf7fa; }
.upload-progress div { display: flex; justify-content: space-between; gap: 1rem; }
.upload-progress progress { width: 100%; height: .75rem; accent-color: #14728c; }
[hidden] { display: none !important; }
footer { color: #70818a; text-align: center; padding: 1rem; font-size: .85rem; }
@media (max-width: 44rem) { .metrics, .form-grid, .command-help, .media-category-fields { grid-template-columns: 1fr; } .toolbar, .quick-actions, .section-heading, .dialog-danger { align-items: flex-start; flex-direction: column; } .playlist-toolbar-actions { width: 100%; } .playlist-toolbar-actions > * { flex: 1; text-align: center; } .header-context > span:not(.environment-badge) { display: none; } .confirm-card { grid-template-columns: 1fr; } .confirm-actions { grid-column: auto; } .media-dialog-actions, .form-dialog-actions { justify-content: stretch; } .media-dialog-actions > *, .form-dialog-actions > * { flex: 1; text-align: center; } }
