:root{--ink:#23231f;--ink-soft:#52534e;--muted:#83837d;--paper:#fffaf0;--white:#fff;--line:#eae6db;--red:#ec4939;--red-hover:#d9382c;--yellow:#ffde64;--sun:#fff1b9;--green:#218462;--shadow:0 18px 54px rgba(71,55,32,.065);--r-xl:22px;--r-md:14px}
*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;background:linear-gradient(180deg,#fff9ee 0%,#fffdfa 35%,#fffefa 100%);color:var(--ink);font-family:'Be Vietnam Pro',system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;font-size:14px;-webkit-font-smoothing:antialiased}button,input{font:inherit}button{cursor:pointer}a{color:inherit}svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}button:focus-visible,a:focus-visible,input:focus-visible{outline:3px solid rgba(236,73,57,.34);outline-offset:3px}[hidden]{display:none!important}.topline{height:5px;background:linear-gradient(90deg,#ef493a 0%,#f16036 42%,#ffe06a 100%)}.container{width:min(1180px,calc(100% - 64px));margin:0 auto}.site-header{background:rgba(255,252,244,.92);border-bottom:1px solid #eee9dc}.header-row{min-height:87px;display:flex;justify-content:space-between;align-items:center;gap:20px}.brand{display:inline-flex;align-items:center;gap:12px;text-decoration:none;min-width:0}.brand-mark{width:49px;height:49px;flex:0 0 49px;border-radius:13px;background:#ed4839;color:#fff;display:flex;flex-direction:column;justify-content:center;align-items:center;transform:rotate(-5deg);box-shadow:3px 4px 0 #ffdc65}.brand-mark span{font-size:26px;font-weight:900;line-height:.9;letter-spacing:-1px}.brand-mark small{font-size:7px;font-weight:900;letter-spacing:2px;margin-top:4px}.brand-name{display:flex;flex-direction:column;gap:4px}.brand-name strong{font-size:15px;font-weight:900;letter-spacing:.12px}.brand-name>span{color:#8c8c80;font-size:11px;font-weight:600}.header-actions{display:flex;gap:11px;align-items:center}.connection-badge{display:inline-flex;align-items:center;gap:7px;color:#466f51;background:#edf8ed;border:1px solid #d7ead9;border-radius:30px;padding:10px 13px;font-size:11px;font-weight:700;white-space:nowrap}.connection-badge.demo{background:#fff2d2;color:#8b682b;border-color:#f3dfab}.connection-badge.error{color:#b8342d;background:#fff1ee;border-color:#f5d4cd}.status-dot{height:7px;width:7px;background:currentColor;border-radius:50%;box-shadow:0 0 0 3px rgba(47,137,82,.10)}.btn{display:inline-flex;align-items:center;justify-content:center;gap:9px;min-height:41px;padding:10px 15px;border-radius:11px;border:1px solid transparent;font-size:12px;font-weight:800;text-decoration:none;transition:background .15s,transform .15s,border-color .15s;white-space:nowrap}.btn:active{transform:scale(.985)}.btn-primary{color:#fff;background:var(--red);box-shadow:0 4px 0 rgba(183,62,37,.10)}.btn-primary:hover{background:var(--red-hover)}.btn-secondary{background:#f7f5f1;color:#41403b;border-color:#e9e6dc}.btn-secondary:hover{background:#eeebe4}.btn-outline{background:#fff;color:#292923;border-color:#e7e2d6}.btn-outline:hover{border-color:var(--red);color:var(--red)}.btn-danger{background:#ca372a;color:#fff}.btn-danger:hover{background:#a62c22}.main-content{padding-top:30px}.hero{overflow:hidden;position:relative;border-radius:20px;box-shadow:0 14px 40px rgba(156,111,27,.13);border:1px solid rgba(236,162,67,.20);background:#ffd96d;aspect-ratio:1447/523}.hero img{width:100%;height:100%;display:block;object-fit:cover}.intro-section{display:flex;justify-content:space-between;align-items:center;gap:45px;padding:53px 0 51px}.intro-copy{max-width:650px}.eyebrow{display:flex;gap:10px;align-items:center;font-size:10px;font-weight:900;letter-spacing:2px;color:var(--red)}.eyebrow-line{width:28px;height:3px;background:var(--red);border-radius:2px}.intro-copy h1{font-weight:900;letter-spacing:-1.8px;font-size:clamp(30px,3.55vw,45px);line-height:1.26;margin:17px 0 17px}.intro-copy h1 span:not(.heading-dot){color:var(--red)}.heading-dot{color:#f5b91d}.intro-copy p{font-size:13px;color:#79766d;max-width:590px;line-height:1.95;margin:0}.stats-grid{display:grid;grid-template-columns:repeat(2,155px);gap:14px;flex-shrink:0}.stat-card{background:#fff;border:1px solid #eeeae0;border-radius:16px;padding:20px 18px 17px;box-shadow:var(--shadow);min-height:139px}.stat-symbol{color:var(--red);font-size:29px;font-weight:900;line-height:1}.stat-symbol.play-symbol{font-size:19px;margin:4px 0 6px}.stat-number{font-size:29px;font-weight:900;line-height:1.1;margin:7px 0}.stat-label{color:#8c877e;font-size:10px;font-weight:700}.demo-alert,.error-alert{border-radius:12px;padding:17px 18px;margin:0 0 29px;line-height:1.85;font-size:12px}.demo-alert{display:flex;align-items:flex-start;gap:12px;background:#fff7dd;border:1px solid #f6e2a9;color:#805c19}.demo-alert svg{flex:0 0 20px;margin-top:2px}.error-alert{background:#fff1ed;border:1px solid #f7cac1;color:#a32c27}.library{padding-bottom:38px}.section-heading{display:flex;align-items:flex-end;justify-content:space-between;gap:22px;margin-bottom:24px}.overline{font-size:10px;font-weight:900;letter-spacing:1.7px;color:var(--red)}.section-heading h2{font-size:26px;line-height:1.3;font-weight:900;letter-spacing:-.8px;margin:8px 0}.section-heading p{color:#89867e;font-size:12px;line-height:1.7;margin:0}.section-heading>.btn{margin-bottom:4px}.library-panel{background:white;border-radius:19px;border:1px solid #eeece5;box-shadow:0 10px 40px rgba(53,40,20,.035);overflow:hidden}.toolbar{padding:22px 24px;display:flex;justify-content:space-between;align-items:center;gap:18px}.search-field{height:46px;display:flex;align-items:center;gap:11px;background:#faf9f5;border:1px solid #e9e7e1;padding:0 14px;border-radius:11px;flex:1;max-width:450px}.search-field:focus-within{border-color:#f0b2a8;background:#fff}.search-field svg{color:#a9a59e;flex:0 0 19px}.search-field input{min-width:0;flex:1;width:100%;background:none;border:0;outline:none;font-size:11.5px;color:#34332e}.search-field input::placeholder{color:#aaa6a0}.search-field kbd{font-family:inherit;font-size:14px;color:#c9c6bd}.filter-tabs{display:flex;gap:4px;align-items:center;padding:4px;border-radius:12px;background:#f7f6f1;flex-shrink:0}.filter-tab{border:0;background:transparent;color:#8b877e;border-radius:9px;padding:10px 12px;font-size:10.5px;font-weight:800;white-space:nowrap}.filter-tab.is-active{background:#fff;color:var(--ink);box-shadow:0 2px 8px rgba(0,0,0,.04)}.filter-tab span{display:inline-flex;align-items:center;justify-content:center;min-width:19px;height:19px;padding:0 5px;border-radius:6px;background:#fff3d4;color:#946f1c;margin-left:5px;font-size:10px}.table-scroll{width:100%;overflow-x:auto}.content-table{border-collapse:collapse;width:100%;min-width:650px;table-layout:fixed}.content-table th{background:#faf8f4;color:#89867d;text-align:left;font-size:10px;font-weight:900;letter-spacing:1.1px;padding:16px 22px;border-top:1px solid #f0ede7;border-bottom:1px solid #f0ede7}.content-table .col-index{width:94px;text-align:center}.content-table th:nth-child(2){width:44%}.content-table th:nth-child(3){width:auto}.content-table th.col-manage{width:157px;text-align:center}.content-table td{border-bottom:1px solid #f1eee9;padding:18px 22px;vertical-align:middle;color:#45443e}.content-table tbody tr:last-child td{border-bottom:0}.content-table tbody tr:hover{background:#fffdf9}.content-table td:first-child{text-align:center}.index-number{display:inline-flex;width:33px;height:33px;border-radius:9px;align-items:center;justify-content:center;background:#fff3da;color:#9a6c16;font-size:11px;font-weight:900}.video-title{font-size:12px;font-weight:800;line-height:1.7;overflow-wrap:anywhere}.video-sub{display:flex;gap:6px;align-items:center;color:#a4a096;font-size:10px;margin-top:6px}.video-sub svg{width:13px;height:13px;color:#b9b3a6}.link-stack{display:flex;align-items:center;gap:12px;min-width:0}.video-link-button{border:1px solid #f8d4ce;color:#db3c30;background:#fff4f1;display:inline-flex;justify-content:center;align-items:center;gap:7px;border-radius:8px;padding:9px 12px;font-size:11px;font-weight:800;white-space:nowrap;flex-shrink:0}.video-link-button:hover{background:#fce6df}.video-link-button svg{width:15px;height:15px}.video-url{font-size:10px;color:#99958e;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;text-decoration:none;min-width:0}.video-url:hover{text-decoration:underline;color:var(--red)}.no-link{color:#a9a59d;font-size:11px;font-style:italic}.manage-cell{text-align:center}.manage-buttons{display:flex;justify-content:center;gap:7px}.small-icon-button{background:white;border:1px solid #eae6df;color:#77736c;border-radius:8px;width:33px;height:33px;display:inline-flex;align-items:center;justify-content:center;padding:0;transition:background .15s}.small-icon-button svg{width:16px;height:16px}.small-icon-button:hover{color:#d93f32;background:#fff3f0;border-color:#f6d1c8}.small-icon-button:disabled{opacity:.32;cursor:not-allowed}.small-icon-button.delete:hover{color:#b52926;background:#ffebe8}.empty-state{text-align:center;padding:60px 20px 65px}.empty-art{width:82px;height:82px;display:flex;justify-content:center;align-items:center;margin:0 auto 18px;border-radius:24px;background:#fff3d7;transform:rotate(-8deg)}.empty-art span{transform:rotate(8deg);color:#df8f16;font-size:45px}.empty-state h3{font-size:17px;font-weight:900;margin:0 0 8px}.empty-state p{color:#8e8981;font-size:12px;line-height:1.9;max-width:460px;margin:0 auto 20px}.table-footer{display:flex;justify-content:space-between;align-items:center;gap:14px;padding:17px 24px;border-top:1px solid #f0ede8;color:#949087;font-weight:600;font-size:11px}.update-hint{display:inline-flex;align-items:center;gap:8px}.pulse-dot{width:7px;height:7px;background:#44a87a;border-radius:50%}.footer{border-top:1px solid #eee9df;color:#a39e94;font-size:10px;padding:29px 0 35px;display:flex;align-items:center;justify-content:space-between;gap:14px;line-height:1.9}.footer strong{color:#676158;font-weight:900;letter-spacing:.5px}.app-dialog{width:min(100% - 36px,530px);max-height:min(90vh,780px);overflow-y:auto;padding:0;border:1px solid #eee6d9;border-radius:20px;box-shadow:0 25px 95px rgba(33,28,19,.22);background:white;color:var(--ink)}.app-dialog::backdrop{background:rgba(30,25,16,.63);backdrop-filter:blur(3px)}.small-dialog{width:min(100% - 36px,470px)}.player-dialog{width:min(100% - 36px,790px)}.dialog-form{padding:29px}.dialog-header{display:flex;justify-content:space-between;align-items:flex-start;gap:10px;margin-bottom:26px}.dialog-header h2{font-size:22px;font-weight:900;letter-spacing:-.6px;line-height:1.45;margin:7px 0 0;overflow-wrap:anywhere}.icon-button{border:0;background:#f5f2ed;width:32px;height:32px;flex-shrink:0;border-radius:9px;font-size:24px;display:flex;align-items:center;justify-content:center;color:#645e55}.icon-button:hover{background:#ffe9e3;color:var(--red)}.form-field{display:flex;flex-direction:column;gap:9px;margin:0 0 21px}.form-field label{font-weight:800;font-size:12px}.required{color:var(--red)}.form-field input{height:47px;border:1px solid #e7e1d8;background:#fffcf8;padding:0 14px;border-radius:10px;font-size:12px;outline:none}.form-field input:focus{border-color:#f0a299;box-shadow:0 0 0 3px #fce9e6}.form-field small{color:#98928a;font-size:10px;line-height:1.7}.form-intro{color:#777269;font-size:12px;line-height:1.85;margin:-10px 0 24px}.form-error{padding:10px;border-radius:8px;color:#b52d2b;background:#fff0ec;font-size:11px}.dialog-actions{display:flex;align-items:center;justify-content:flex-end;gap:10px;margin-top:27px}.dialog-actions .btn{min-width:92px}.player-embed{display:block;border:0;width:100%;aspect-ratio:16/9;border-radius:12px;background:#191919}.player-fallback{padding:36px 22px;border-radius:12px;text-align:center;background:#fff8e7;color:#74613f}.player-fallback svg{width:34px;height:34px;color:var(--red);display:block;margin:0 auto 13px}.player-fallback p{font-size:12px;line-height:1.8;margin:0}.toast{position:fixed;bottom:28px;right:28px;max-width:min(420px,calc(100% - 48px));background:#252b23;color:#fff;padding:15px 19px;font-size:12px;font-weight:600;border-radius:11px;box-shadow:0 12px 45px rgba(0,0,0,.16);opacity:0;pointer-events:none;transform:translateY(10px);transition:opacity .22s,transform .22s;z-index:20;line-height:1.7}.toast.visible{opacity:1;transform:translateY(0)}.toast.error{background:#bd312a}
@media(max-width:1050px){.stats-grid{grid-template-columns:repeat(2,130px)}.intro-section{gap:24px}.stat-card{padding:16px 14px}.filter-tab{padding:10px 8px}.toolbar{align-items:stretch;flex-wrap:wrap}.search-field{max-width:none;min-width:100%}.filter-tabs{width:max-content}}
@media(max-width:760px){.container{width:min(100% - 30px,1180px)}.header-row{min-height:74px}.brand-mark{width:43px;height:43px;flex-basis:43px}.brand-mark span{font-size:23px}.brand-name strong{font-size:12px}.brand-name>span{font-size:9px}.header-actions{gap:7px}.connection-badge,.header-share{display:none}.btn{font-size:11px;padding:9px 12px;min-height:38px}.header-actions .btn{padding:10px}.header-actions .btn svg{width:16px;height:16px}.main-content{padding-top:17px}.hero{border-radius:13px;aspect-ratio:2.2}.hero img{object-position:center}.intro-section{padding:32px 0 35px;display:block}.intro-copy h1{font-size:clamp(27px,6vw,39px);letter-spacing:-1.1px}.intro-copy p{font-size:12px}.stats-grid{margin-top:24px;grid-template-columns:1fr 1fr;gap:10px}.stat-card{min-height:113px;padding:15px}.stat-number{font-size:25px}.stat-symbol{font-size:23px}.stat-label{font-size:10px}.section-heading h2{font-size:23px}.section-heading p{font-size:11px}.section-heading{align-items:flex-start}.section-heading>.btn{align-self:flex-end}.toolbar{padding:16px}.filter-tabs{max-width:100%;overflow-x:auto}.filter-tab{font-size:10px}.content-table th{padding:15px}.content-table td{padding:15px}.table-footer{padding:15px;flex-wrap:wrap}.footer{display:block}.footer span{display:block;margin-bottom:6px}.dialog-form{padding:22px}.dialog-header h2{font-size:19px}}
@media(max-width:450px){.brand-name>span{display:none}.brand-name strong{max-width:125px;line-height:1.35}.header-actions .btn span{max-width:110px;overflow:hidden;text-overflow:ellipsis}.intro-copy h1{font-size:30px}.desktop-break{display:none}.section-heading{display:block}.section-heading>.btn{margin-top:18px}.content-table{min-width:600px}.update-hint{display:none}.filter-tabs{width:100%;justify-content:space-around}.filter-tab{padding:10px 6px}}


/* Tiến độ quay video — cột mới nằm ngay sau Link video */
.stats-grid{grid-template-columns:repeat(3,130px);gap:11px}
.stat-card{min-width:0;padding:18px 15px 15px}
.stat-symbol.filmed-symbol{color:var(--green);font-size:29px}
.content-table{min-width:880px}
.content-table th:nth-child(2){width:34%}
.content-table .col-filmed{width:174px;text-align:center}
.filming-cell{text-align:center}
.filming-toggle{display:inline-flex;align-items:center;gap:9px;padding:9px 12px;border:1px solid #e5e3d9;border-radius:11px;color:#7f7771;background:#fbfaf7;font-weight:800;font-size:11px;white-space:nowrap;cursor:pointer;transition:background .15s,border-color .15s}
.filming-toggle.is-filmed{background:#ecf9f0;border-color:#ccead6;color:#18754e}
.filming-toggle.is-unfilmed{background:#fff7e6;border-color:#f2e1b5;color:#956b28}
.filming-toggle:not(.is-readonly):hover{filter:brightness(.975)}
.filming-toggle.is-readonly{cursor:default;opacity:.85}
.filming-checkbox{width:17px;height:17px;accent-color:#218462;flex:none;cursor:pointer;margin:0}
.filming-checkbox:disabled{cursor:default}
.role-hint{padding:0 24px 16px;font-size:11px;color:#807b71;line-height:1.75}
@media(max-width:1140px){.stats-grid{grid-template-columns:repeat(3,minmax(0,120px))}}
@media(max-width:970px){.stats-grid{grid-template-columns:repeat(3,minmax(0,1fr));width:100%;margin-top:20px}.intro-section{display:block}.intro-copy{max-width:780px}.stat-card{min-height:105px}}
@media(max-width:760px){.stats-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.stat-card{padding:13px 11px;min-height:100px}.stat-label{font-size:10px}.role-hint{padding:0 16px 14px}.content-table{min-width:800px}.content-table .col-filmed{width:156px}}
@media(max-width:420px){.stats-grid{gap:6px}.stat-card{padding:12px 8px}.stat-number{font-size:21px}.stat-label{font-size:9px}.filming-toggle{padding:8px}}


/* Mobile: trình bày mỗi video thành thẻ để sếp nhìn thấy ô trạng thái mà không cần kéo bảng ngang. */
@media(max-width:760px){
  .table-scroll{overflow-x:visible}
  .content-table{display:block;width:100%;min-width:0;table-layout:auto}
  .content-table thead{display:none}
  .content-table tbody{display:block}
  .content-table tbody tr{display:grid;grid-template-columns:44px minmax(0,1fr);gap:11px 12px;padding:16px;border-bottom:1px solid #eee9dd}
  .content-table tbody tr td,.content-table tbody tr:last-child td{display:block;min-width:0;padding:0;border-bottom:0}
  .content-table tbody tr td:first-child{grid-column:1;grid-row:1;align-self:center}
  .content-table tbody tr td:nth-child(2){grid-column:2;grid-row:1;align-self:center}
  .content-table tbody tr td:nth-child(3){grid-column:1/-1;padding-top:12px;border-top:1px dashed #eee8da}
  .content-table tbody tr td:nth-child(3)::before{content:"LINK VIDEO";display:block;margin:0 0 7px;font-size:10px;letter-spacing:1px;font-weight:800;color:#8d887f}
  .content-table tbody tr td:nth-child(4){grid-column:1/-1;display:flex;justify-content:space-between;align-items:center;gap:8px;text-align:left}
  .content-table tbody tr td:nth-child(4)::before{content:"TRẠNG THÁI QUAY";font-size:10px;letter-spacing:1px;font-weight:800;color:#8d887f}
  .content-table tbody tr td:nth-child(5){grid-column:1/-1;padding-top:10px;border-top:1px dashed #eee8da}
  .content-table tbody tr td:nth-child(5)::before{content:"QUẢN LÝ";display:block;margin:0 0 8px;font-size:10px;letter-spacing:1px;font-weight:800;color:#8d887f}
  .content-table tbody tr td:nth-child(5) .manage-buttons{justify-content:flex-start}
  .content-table .link-stack{min-width:0;max-width:100%;flex-wrap:wrap}
  .content-table .video-url{max-width:100%}
}

/* Phóng to logo và tên cộng đồng trên header */
.site-header .brand {
    display: flex;
    align-items: center;
    gap: 18px;
    flex: 1;
    min-width: 0;
}

.site-header .brand-mark {
    width: 85px;
    height: 85px;
    flex-shrink: 0;
}

.site-header .brand-name {
    font-size: clamp(26px, 2.6vw, 44px);
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -1px;
}

.site-header .brand-subtitle {
    font-size: 17px;
    margin-top: 6px;
}

/* Giữ giao diện gọn trên điện thoại */
@media (max-width: 768px) {
    .site-header .brand-mark {
        width: 52px;
        height: 52px;
    }

    .site-header .brand-name {
        font-size: 20px;
    }

    .site-header .brand-subtitle {
        font-size: 12px;
    }
}
