﻿:root{--bg:#fff;--surface:#fff;--text:#151922;--muted:#687180;--line:#dfe4eb;--line-soft:#edf0f4;--blue:#0869f7;--blue-hover:#005be0;--blue-soft:#eaf2ff;--green:#10a957;--green-soft:#e8f8ef;--red:#ef3d45;--red-soft:#fff0f1;--radius:12px;--shadow:0 12px 34px rgba(25,42,70,.12);--font:-apple-system,BlinkMacSystemFont,"Segoe UI","PingFang SC","Microsoft YaHei",Arial,sans-serif}
*{box-sizing:border-box}html{color-scheme:light}body{margin:0;background:var(--bg);color:var(--text);font-family:var(--font);font-size:14px;line-height:1.5}button,input{font:inherit}button,a{touch-action:manipulation}button{cursor:pointer}svg{fill:none;stroke:currentColor;stroke-width:1.75;stroke-linecap:round;stroke-linejoin:round}.app-header{height:64px;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;padding:0 30px}.brand{display:inline-flex;align-items:center;gap:12px;text-decoration:none;color:var(--text);font-weight:700;font-size:19px;letter-spacing:.01em}.brand svg{width:31px;height:31px;color:var(--blue);stroke-width:2}.logout-form{display:flex;align-items:center;gap:18px;color:#303642}.divider{width:1px;height:18px;background:var(--line)}.text-button,.link-action{border:0;background:transparent;color:var(--blue);padding:3px;display:inline-flex;align-items:center;gap:5px;text-decoration:none;white-space:nowrap}.text-button{color:#303642}.text-button svg,.link-action svg{width:18px;height:18px}.page-shell{max-width:1500px;margin:0 auto;padding:27px 29px 60px}.page-heading{display:flex;justify-content:space-between;align-items:end;margin-bottom:18px}.page-heading h1{font-size:32px;line-height:1.18;margin:0;letter-spacing:-.025em}.page-heading p{margin:0;color:var(--muted)}.button{min-height:40px;border-radius:7px;border:1px solid var(--line);padding:0 17px;display:inline-flex;align-items:center;justify-content:center;gap:8px;font-weight:600;font-size:14px}.button svg{width:19px;height:19px}.button.primary{background:var(--blue);border-color:var(--blue);color:#fff;box-shadow:0 3px 8px rgba(8,105,247,.18)}.button.primary:hover{background:var(--blue-hover)}.button.secondary{background:#fff;color:var(--text)}.button.wide{width:100%}.media-table{border:1px solid var(--line);border-radius:var(--radius);overflow:visible;background:#fff}.disk-strip{padding:13px 18px 14px;border-bottom:1px solid var(--line);display:grid;grid-template-columns:minmax(130px,1fr) 3fr;gap:8px 22px;align-items:center}.disk-label{display:flex;justify-content:space-between;gap:20px;grid-column:1/-1}.disk-label span{font-weight:600}.disk-label strong{font-size:13px;font-weight:500;color:#4f5866}.disk-track{height:7px;background:#edf1f6;border-radius:999px;overflow:hidden;grid-column:1/-1}.disk-track span{display:block;height:100%;background:var(--blue);border-radius:inherit;min-width:2px}.disk-strip p{grid-column:1/-1;margin:0;color:var(--muted);font-size:12px}.table-scroll{overflow-x:auto}table{width:100%;border-collapse:collapse;table-layout:fixed}th{height:47px;text-align:left;font-weight:600;color:#2d3440;background:#fcfdff;border-bottom:1px solid var(--line);padding:0 18px}td{height:61px;border-bottom:1px solid var(--line-soft);padding:9px 18px;color:#353d49;vertical-align:middle}th:nth-child(1){width:23%}th:nth-child(2){width:21%}th:nth-child(3){width:11%}th:nth-child(4){width:16%}th:nth-child(5){width:29%}.video-name{display:flex;align-items:center;gap:12px;min-width:0}.video-name>svg{width:27px;height:31px;color:#78818f;flex:none}.video-name div{min-width:0}.video-name strong{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:500;color:#202630}.video-name small{display:block;color:var(--muted);font-size:12px}.status-line{display:flex;align-items:center;gap:7px;white-space:nowrap}.status-line b{font-weight:500;color:var(--muted)}.status-icon{width:18px;height:18px;border-radius:50%;display:inline-grid;place-items:center;border:1.5px solid currentColor;position:relative}.status-ready{color:var(--green)}.status-ready span:nth-child(2),.status-processing span:nth-child(2),.status-queued span:nth-child(2),.status-uploading span:nth-child(2){color:#303642}.status-ready .status-icon:after{content:"";width:7px;height:3px;border-left:1.5px solid;border-bottom:1.5px solid;transform:rotate(-45deg) translate(1px,-1px)}.status-failed{color:var(--red)}.status-failed .status-icon:after{content:"!";font-weight:700;font-size:11px;line-height:1}.status-processing,.status-queued,.status-uploading{color:var(--blue)}.row-progress{height:4px;background:#e9edf3;border-radius:99px;margin:7px 0 0 25px;max-width:260px;overflow:hidden}.row-progress span{display:block;height:100%;background:var(--blue);border-radius:inherit}.error-detail{display:block;color:var(--red);margin-top:4px;max-width:320px}.replace-note{display:block;color:var(--muted);margin-top:4px}.row-actions{display:flex;align-items:center;gap:8px}.row-actions form{margin:0}.more-menu{position:relative}.more-menu summary{list-style:none;color:var(--blue);cursor:pointer;display:flex;align-items:center;gap:2px;white-space:nowrap}.more-menu summary::-webkit-details-marker{display:none}.more-menu summary svg{width:17px;height:17px}.menu-popover{position:absolute;right:0;top:28px;z-index:5;width:132px;background:#fff;border:1px solid var(--line);border-radius:9px;box-shadow:var(--shadow);padding:6px}.menu-popover button{width:100%;border:0;background:transparent;text-align:left;padding:8px 10px;border-radius:5px;color:#303642}.menu-popover button:hover{background:#f5f7fa}.menu-popover button.danger{color:var(--red)}.table-footer{padding:12px 18px;color:#505966}.empty-state{min-height:360px;display:flex;align-items:center;justify-content:center;flex-direction:column;text-align:center;padding:50px 20px}.empty-state>svg{width:58px;height:58px;color:#a5adba}.empty-state h2{font-size:20px;margin:16px 0 5px}.empty-state p{color:var(--muted);margin:0 0 20px}.modal{border:0;background:transparent;padding:24px;max-width:none;max-height:none}.modal::backdrop{background:rgba(21,25,34,.33);backdrop-filter:blur(1px)}.modal-shell{width:min(470px,calc(100vw - 34px));background:#fff;border:1px solid #aeb6c2;border-radius:10px;box-shadow:var(--shadow);padding:18px}.small-modal .modal-shell{width:min(430px,calc(100vw - 34px))}.modal-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:18px}.modal-heading h2{margin:0;font-size:19px}.icon-button{border:0;background:transparent;color:#6c7480;font-size:28px;line-height:1;padding:0 3px}.field{display:block;font-weight:600;position:relative;margin-bottom:17px}.field input{width:100%;height:39px;border:1px solid #cfd5dd;border-radius:6px;padding:0 12px;margin-top:7px;outline:none;font-weight:400}.field input:focus{border-color:var(--blue);box-shadow:0 0 0 3px var(--blue-soft)}.title-count{position:absolute;right:11px;top:41px;color:#89919d;font-size:12px;font-weight:400}.drop-zone{height:130px;border:1px dashed #9da6b2;border-radius:6px;display:flex;align-items:center;justify-content:center;flex-direction:column;text-align:center;padding:13px;cursor:pointer}.drop-zone:hover,.drop-zone.dragging{border-color:var(--blue);background:#f7faff}.drop-zone svg{width:38px;height:38px;color:#687180;margin-bottom:6px}.drop-zone strong{font-size:14px}.drop-zone span{font-size:12px;color:#7b8490;margin-top:3px}.check-field{display:flex;gap:10px;align-items:flex-start;margin:15px 0}.check-field input{width:16px;height:16px;margin-top:2px;accent-color:var(--blue)}.check-field b,.check-field small{display:block}.check-field b{font-weight:600}.check-field small{color:var(--muted)}.upload-progress{margin-top:17px}.upload-progress>div:first-child{display:flex;justify-content:space-between}.progress-track{height:6px;background:#e8ecf2;border-radius:99px;margin:7px 0;overflow:hidden}.progress-track span{display:block;height:100%;width:0;background:var(--blue);border-radius:inherit}.upload-progress p{font-size:12px;color:var(--muted);margin:0}.modal-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:20px}.form-error{padding:9px 11px;border:1px solid #ffd4d7;background:var(--red-soft);color:#bb252d;border-radius:6px;margin:11px 0;font-size:13px}.toast{position:fixed;left:50%;bottom:30px;transform:translateX(-50%);background:#1d2430;color:#fff;padding:9px 15px;border-radius:7px;box-shadow:var(--shadow);z-index:20}.login-page{background:#f7f9fc;min-height:100vh}.login-shell{min-height:100vh;display:grid;place-content:center;gap:25px;padding:24px}.brand-large{justify-content:center;font-size:23px}.brand-large svg{width:38px;height:38px}.login-panel{width:min(390px,calc(100vw - 34px));background:#fff;border:1px solid var(--line);border-radius:14px;padding:30px;box-shadow:0 18px 55px rgba(25,42,70,.08)}.login-panel h1{font-size:25px;margin:0 0 4px}.login-panel>p{margin:0 0 22px;color:var(--muted)}.stack-form{display:grid;gap:16px}.stack-form label{font-weight:600}.stack-form input{display:block;width:100%;height:43px;margin-top:7px;border:1px solid #cfd5dd;border-radius:7px;padding:0 12px;outline:none;font-weight:400}.stack-form input:focus{border-color:var(--blue);box-shadow:0 0 0 3px var(--blue-soft)}.player-page{min-height:100vh;background:#0e1117;color:#fff}.player-shell{width:min(1180px,100%);margin:0 auto;padding:clamp(22px,5vw,58px) 18px}.player-shell h1{font-size:clamp(20px,3vw,31px);line-height:1.3;margin:0 0 18px;font-weight:650;overflow-wrap:anywhere}.video-frame{background:#000;border-radius:12px;overflow:hidden;box-shadow:0 20px 60px rgba(0,0,0,.35)}.video-frame video{display:block;width:100%;max-height:78vh;aspect-ratio:16/9;background:#000;object-fit:contain}.danger{color:var(--red)}
@media(max-width:900px){.app-header{padding:0 18px}.page-shell{padding:22px 16px 45px}.page-heading{align-items:center}.page-heading p{display:none}.page-heading h1{font-size:27px}.disk-strip{padding:12px 14px}table,tbody,tr,td{display:block}thead{display:none}tbody{display:grid}tr{padding:15px;border-bottom:1px solid var(--line);display:grid;grid-template-columns:1fr auto;gap:11px 18px}td{height:auto;border:0;padding:0}td:before{content:attr(data-label);display:block;color:var(--muted);font-size:11px;margin-bottom:3px}td:nth-child(1){grid-column:1/-1}td:nth-child(2){grid-column:1}td:nth-child(3),td:nth-child(4){display:none}td:nth-child(5){grid-column:1/-1}.row-actions{flex-wrap:wrap}.table-footer{border-top:0}.more-menu{margin-left:auto}.menu-popover{right:0}.link-action{padding:5px 3px}.video-name strong{white-space:normal}}
@media(max-width:520px){.app-header{height:58px}.brand{font-size:17px;gap:8px}.brand svg{width:27px;height:27px}.logout-form>span:first-child,.divider{display:none}.page-heading{margin-bottom:15px}.page-heading .button{min-width:42px;padding:0 12px}.page-heading .button svg{margin-right:0}.media-table{border-radius:9px}.disk-label{display:grid;gap:2px}.disk-label strong{font-size:12px}.row-actions{gap:8px}.link-action{font-size:13px}.modal{padding:8px}.modal-shell{padding:17px}.player-shell{padding-top:24px}.video-frame{border-radius:8px}}
@media(prefers-reduced-motion:no-preference){.button,.link-action,.drop-zone{transition:background-color .15s,border-color .15s,color .15s}.modal[open] .modal-shell{animation:modal-in .16s ease-out}@keyframes modal-in{from{opacity:0;transform:translateY(8px) scale(.99)}to{opacity:1;transform:none}}}

/* Keep row menus in the page flow instead of turning the table into a nested vertical scroller. */
.table-scroll{overflow:visible}
.media-table th:nth-child(1){width:22%}.media-table th:nth-child(2){width:16%}.media-table th:nth-child(3){width:10%}.media-table th:nth-child(4){width:15%}.media-table th:nth-child(5){width:37%}
.row-actions{flex-wrap:wrap;gap:4px}
.row-actions .link-action,.more-menu summary{min-height:34px;padding:6px 8px;border-radius:6px}
.row-actions .link-action:hover,.more-menu summary:hover{background:var(--blue-soft)}
.row-actions .link-action:focus-visible,.more-menu summary:focus-visible,.icon-button:focus-visible{outline:2px solid var(--blue);outline-offset:2px}
.menu-popover{top:36px;z-index:10}

.qr-modal .modal-shell{width:min(440px,calc(100vw - 34px))}
.qr-modal .modal-heading{align-items:flex-start;margin-bottom:14px}
.qr-modal .modal-heading p{margin:2px 0 0;color:var(--muted);font-size:13px}
.qr-preview{width:min(280px,100%);aspect-ratio:1;margin:0 auto;padding:12px;border:1px solid var(--line);border-radius:12px;background:#fff}
.qr-preview img{display:block;width:100%;height:100%;object-fit:contain}
.qr-details{text-align:center;margin-top:14px;min-width:0}
.qr-details strong{display:block;font-size:15px;overflow-wrap:anywhere}
.qr-details p{margin:4px 0 0;color:var(--muted);font-size:12px;overflow-wrap:anywhere}
.qr-actions{justify-content:stretch}
.qr-actions .button{flex:1;text-decoration:none}

@media(max-width:900px){.table-scroll{overflow:visible}.row-actions .link-action,.more-menu summary{min-height:40px;padding:8px 9px}.menu-popover{top:42px}}
@media(max-width:520px){.qr-modal .modal-shell{padding:16px}.qr-preview{width:min(250px,100%)}.qr-actions{display:grid;grid-template-columns:1fr 1fr}.qr-actions .button{padding:0 10px}}

/* Preserve comfortable physical sizing and useful page width on high-resolution displays. */
@media(min-width:1800px){
  body{font-size:16px}
  .app-header{height:76px;padding:0 48px}
  .brand{font-size:22px}.brand svg{width:36px;height:36px}
  .page-shell{max-width:2000px;padding:38px 46px 80px}
  .page-heading{margin-bottom:24px}.page-heading h1{font-size:40px}
  .button{min-height:46px;padding:0 21px;font-size:16px}.button svg{width:21px;height:21px}
  .disk-strip{padding:18px 24px 19px;gap:10px 24px}.disk-label strong{font-size:15px}.disk-track{height:8px}.disk-strip p{font-size:14px}
  th{height:56px;padding:0 24px}td{height:72px;padding:12px 24px}
  .video-name>svg{width:31px;height:36px}.status-icon{width:20px;height:20px}
  .row-actions .link-action,.more-menu summary{min-height:40px;padding:8px 10px}
  .menu-popover{top:42px;width:156px;padding:8px}.menu-popover button{padding:10px 12px;font-size:16px}
  .table-footer{padding:15px 24px}
  .login-shell{gap:30px;padding:32px}.brand-large{font-size:28px}.brand-large svg{width:46px;height:46px}
  .login-panel{width:min(480px,calc(100vw - 40px));padding:40px;border-radius:18px}
  .login-panel h1{font-size:32px;margin-bottom:6px}.login-panel>p{margin-bottom:28px}
  .stack-form{gap:20px}.stack-form input{height:52px;margin-top:9px;padding:0 15px;font-size:16px}
  .player-shell{width:min(1760px,100%);padding:64px 36px}
  .player-shell h1{font-size:clamp(30px,2.2vw,42px);margin-bottom:24px}.video-frame video{max-height:82vh}
}
