:root{--bg:#f5f7fb;--panel:#fff;--text:#182033;--muted:#6d7690;--line:#e7eaf1;--brand:#334f91;--brand2:#4666ad;--sidebar:#1f2d52;--danger:#c53b45;--green:#2e8b57;--amber:#b47900;--blue:#356bc4;--indigo:#5849b7;--shadow:0 8px 28px rgba(31,45,82,.08);--radius:14px}*{box-sizing:border-box}html,body{margin:0;min-height:100%;font-family:Inter,ui-sans-serif,system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif;color:var(--text);background:var(--bg)}a{color:var(--brand);text-decoration:none}button,input,select,textarea{font:inherit}input,select,textarea{width:100%;border:1px solid #d9dfeb;border-radius:9px;padding:10px 11px;background:#fff;color:var(--text);outline:none}input:focus,select:focus,textarea:focus{border-color:#7790c7;box-shadow:0 0 0 3px rgba(70,102,173,.1)}textarea{resize:vertical}.app-shell{display:flex;min-height:100vh}.sidebar{position:fixed;inset:0 auto 0 0;width:236px;background:var(--sidebar);color:#fff;padding:20px 14px;display:flex;flex-direction:column;z-index:50}.brand{display:flex;align-items:center;gap:12px}.brand-mark{width:42px;height:42px;border-radius:12px;background:#fff;color:var(--sidebar);font-weight:900;display:flex;align-items:center;justify-content:center;letter-spacing:-1px}.brand strong{display:block;font-size:15px;letter-spacing:1.2px}.brand small{display:block;opacity:.65;font-size:11px;margin-top:2px}.sidebar nav{margin-top:28px;display:flex;flex-direction:column;gap:5px}.nav-link{display:flex;align-items:center;gap:11px;color:#dbe3fb;padding:10px 12px;border-radius:9px;font-size:14px}.nav-link span{width:20px;text-align:center}.nav-link:hover,.nav-link.active{background:rgba(255,255,255,.12);color:#fff}.sidebar-bottom{margin-top:auto;border-top:1px solid rgba(255,255,255,.12);padding-top:14px}.user-mini{padding:7px 12px 12px}.user-mini strong,.user-mini small{display:block}.user-mini small{opacity:.65;margin-top:3px}.main{margin-left:236px;min-width:0;flex:1}.topbar{height:66px;position:sticky;top:0;z-index:40;background:rgba(255,255,255,.93);backdrop-filter:blur(12px);border-bottom:1px solid var(--line);display:flex;align-items:center;padding:0 28px;gap:18px}.global-search{display:flex;max-width:520px;flex:1}.global-search input{border-radius:9px 0 0 9px;border-right:0}.global-search button{border:1px solid #d9dfeb;border-left:0;background:#fff;border-radius:0 9px 9px 0;width:44px;cursor:pointer}.top-user{margin-left:auto;font-size:14px;font-weight:600}.menu-btn{display:none;border:0;background:none;font-size:22px}.content{padding:28px;max-width:1800px;margin:0 auto}.page-head{display:flex;align-items:flex-start;justify-content:space-between;gap:20px;margin-bottom:20px}.page-head h1{margin:0;font-size:25px;letter-spacing:-.4px}.page-head p{margin:5px 0 0;color:var(--muted);font-size:14px}.page-actions{display:flex;gap:8px;flex-wrap:wrap}.btn{display:inline-flex;align-items:center;justify-content:center;border:1px solid #d6dceb;background:#fff;color:#25314a;border-radius:9px;padding:9px 13px;font-weight:600;font-size:14px;cursor:pointer;white-space:nowrap}.btn:hover{background:#f8f9fc}.btn.primary{background:var(--brand);border-color:var(--brand);color:#fff}.btn.primary:hover{background:#293f77}.btn.ghost{background:transparent}.btn.large{padding:11px 17px}.btn.wide{width:100%}.panel{background:var(--panel);border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow);padding:18px;margin-bottom:18px}.panel-head{display:flex;justify-content:space-between;align-items:center;gap:14px;margin-bottom:14px}.panel-head h3,.panel h3{margin:0;font-size:16px}.panel-note{background:#f7f8fc;border:1px dashed #cfd6e5;padding:10px 12px;border-radius:9px;color:var(--muted);font-size:13px;margin-bottom:14px}.kpi-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}.kpi{background:#fff;border:1px solid var(--line);border-radius:13px;padding:16px;box-shadow:var(--shadow);border-top:3px solid #9aa5bd}.kpi span,.kpi small{display:block;color:var(--muted);font-size:12px}.kpi strong{display:block;font-size:22px;margin:7px 0 5px;letter-spacing:-.5px}.kpi.blue{border-top-color:var(--blue)}.kpi.indigo{border-top-color:var(--indigo)}.kpi.green{border-top-color:var(--green)}.kpi.red{border-top-color:var(--danger)}.kpi.amber{border-top-color:var(--amber)}.section-title{font-size:16px;margin:24px 0 12px}.alert-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.alert-card{padding:15px;border-radius:12px;border:1px solid var(--line);background:#fff;display:flex;flex-direction:column;box-shadow:var(--shadow)}.alert-card strong{font-size:24px}.alert-card span{font-size:13px;margin-top:4px}.alert-card.danger{border-left:4px solid var(--danger)}.alert-card.warning{border-left:4px solid #d99000}.alert-card.info{border-left:4px solid var(--blue)}.alert-card.muted{border-left:4px solid #8a94aa}.two-col{display:grid;grid-template-columns:1fr 1fr;gap:18px;margin-top:18px}.bar-list{display:flex;flex-direction:column;gap:12px}.bar-item>div:first-child{display:flex;justify-content:space-between;font-size:13px}.bar-track{height:8px;background:#edf0f6;border-radius:99px;overflow:hidden;margin-top:6px}.bar-track i{display:block;height:100%;background:var(--brand2);border-radius:99px}.status-summary{display:flex;flex-direction:column;gap:11px}.status-summary>div{display:grid;grid-template-columns:14px 1fr auto;align-items:center;gap:8px}.dot{width:10px;height:10px;border-radius:50%;display:inline-block}.badge-blue,.dot.badge-blue{background:#e5efff;color:#24559e}.badge-green,.dot.badge-green{background:#e7f5ed;color:#277149}.badge-red,.dot.badge-red{background:#fde9eb;color:#a12e38}.badge-amber,.dot.badge-amber{background:#fff3cf;color:#8a5f00}.badge-gray,.dot.badge-gray{background:#eef1f6;color:#687289}.badge{display:inline-flex;padding:5px 8px;border-radius:999px;font-size:12px;font-weight:700}.filter-bar{display:flex;gap:8px;align-items:end;flex-wrap:wrap;background:#fff;border:1px solid var(--line);border-radius:12px;padding:12px;margin-bottom:14px}.filter-bar input,.filter-bar select{width:auto;min-width:145px}.filter-bar input[name=q]{min-width:240px}.filter-bar label{font-size:12px;color:var(--muted)}.filter-bar label input{display:block;margin-top:4px}.table-wrap{overflow:auto}.data-table{width:100%;border-collapse:collapse;min-width:980px}.data-table th{position:sticky;top:0;background:#f7f8fc;color:#58617a;font-size:11px;text-transform:uppercase;letter-spacing:.4px;text-align:left;padding:10px 9px;border-bottom:1px solid var(--line);white-space:nowrap}.data-table td{padding:9px;border-bottom:1px solid #edf0f5;font-size:13px;vertical-align:middle}.data-table tr:hover td{background:#fafbfe}.data-table .num{text-align:right;white-space:nowrap}.data-table .strong{font-weight:700}.data-table.compact td,.data-table.compact th{padding:7px 8px;font-size:12px}.data-table small{display:block;color:var(--muted);margin-top:2px}.data-table .legacy{font-size:10px}.order-code{font-weight:800;white-space:nowrap}.empty{text-align:center;color:var(--muted);padding:28px!important}.inline-select{min-width:125px;padding:6px 27px 6px 8px;border-radius:8px;font-size:12px;font-weight:700;border:1px solid transparent}.inline-select.badge-green{background:#e7f5ed}.inline-select.badge-red{background:#fde9eb}.inline-select.badge-amber{background:#fff3cf}.inline-select.badge-blue{background:#e5efff}.icon-btn{width:28px;height:28px;border-radius:8px;background:#f0f3f9;display:flex;align-items:center;justify-content:center;font-size:20px}.form-panel{max-width:1100px}.form-section{padding:5px 0 20px;border-bottom:1px solid var(--line);margin-bottom:20px}.form-section h3{margin-bottom:14px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px}.form-grid.three{grid-template-columns:repeat(3,1fr)}.form-grid label,.stack-form label,.install-form label,.login-card label{font-size:12px;color:#5d667c;font-weight:600}.form-grid label input,.form-grid label select,.form-grid label textarea,.stack-form label input,.login-card label input,.install-form label input{display:block;margin-top:5px}.span-2{grid-column:span 2}.form-actions{display:flex;gap:10px;justify-content:flex-end;margin-top:18px}.upload-box{display:flex;align-items:center;justify-content:center;min-height:88px;border:2px dashed #cbd4e6;border-radius:12px;background:#fafbfe;cursor:pointer;color:var(--muted);text-align:center;padding:16px}.upload-box.large{min-height:130px}.upload-box input{display:none}.detail-grid{display:grid;grid-template-columns:1.2fr .8fr;gap:18px}.detail-list{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin:0}.detail-list>div{padding:10px;background:#fafbfe;border-radius:9px}.detail-list .full{grid-column:1/-1}.detail-list dt{font-size:11px;color:var(--muted);text-transform:uppercase}.detail-list dd{margin:5px 0 0;font-size:14px}.big-money{font-size:20px!important;font-weight:800}.gallery{display:grid;grid-template-columns:repeat(auto-fill,minmax(160px,1fr));gap:12px}.image-card{border:1px solid var(--line);border-radius:10px;overflow:hidden}.image-card img{width:100%;height:130px;object-fit:cover;display:block;background:#eee}.image-card>div{padding:8px;display:flex;justify-content:space-between;gap:8px;font-size:11px}.image-card form{margin:0}.link-danger,.link-btn{border:0;background:none;color:var(--danger);cursor:pointer;padding:0;font-size:12px}.link-btn{color:var(--brand)}.truncate{max-width:260px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mini-kpi-row,.carrier-cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:12px;margin-bottom:14px}.mini-kpi-row a,.carrier-cards a{background:#fff;border:1px solid var(--line);border-radius:11px;padding:13px;box-shadow:var(--shadow);display:flex;flex-direction:column}.mini-kpi-row span,.carrier-cards span,.carrier-cards small{color:var(--muted);font-size:12px}.mini-kpi-row strong,.carrier-cards strong{margin:4px 0}.bulk-bar{display:flex;gap:8px;margin-bottom:12px}.bulk-bar select{width:auto}.tabs{display:flex;gap:6px;margin-bottom:14px;flex-wrap:wrap}.tabs a{padding:8px 12px;border:1px solid var(--line);border-radius:9px;background:#fff;font-size:13px}.tabs a.active{background:var(--brand);color:#fff;border-color:var(--brand)}.severity{font-size:10px;font-weight:900;padding:4px 6px;border-radius:6px}.severity.red{background:#fde4e6;color:#a5202b}.severity.orange{background:#ffecd7;color:#a75800}.severity.yellow{background:#fff4c7;color:#826100}.severity.gray{background:#eef1f5;color:#687289}.simple-table{width:100%;border-collapse:collapse}.simple-table td{padding:9px 5px;border-bottom:1px solid var(--line);font-size:13px}.simple-table td:last-child{text-align:right}.settings-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px}.stack-form{display:flex;flex-direction:column;gap:11px;margin-top:14px}.check{display:flex!important;align-items:center;gap:8px}.check input{width:auto!important;margin:0!important}.inline-form,.user-create{display:flex;gap:8px;flex-wrap:wrap;margin:12px 0}.inline-form input{max-width:320px}.user-create input{max-width:220px}.user-create select{max-width:160px}.status-edit-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:18px}.status-row{display:flex;gap:8px;align-items:center;margin:8px 0}.status-row input{padding:7px 9px}.import-help ol{line-height:1.8}.import-help h3{margin-bottom:8px}.upload-form{max-width:700px}.report-kpis{grid-template-columns:repeat(5,1fr)}.flash{padding:11px 14px;border-radius:9px;margin-bottom:14px;font-size:13px}.flash.success{background:#e8f6ee;color:#266b46;border:1px solid #c6e8d3}.flash.error{background:#fdebed;color:#952b35;border:1px solid #f2c9cd}.toast{position:fixed;right:24px;bottom:24px;opacity:0;transform:translateY(10px);transition:.2s;background:#1f2d52;color:#fff;padding:10px 14px;border-radius:9px;box-shadow:var(--shadow);z-index:99;pointer-events:none}.toast.show{opacity:1;transform:none}.muted{color:var(--muted)}.login-page,.install-page{display:flex;align-items:center;justify-content:center;padding:30px;background:linear-gradient(135deg,#f2f5fb,#e8edf8);min-height:100vh}.login-card{width:100%;max-width:420px;background:#fff;border:1px solid var(--line);border-radius:18px;box-shadow:0 24px 70px rgba(31,45,82,.16);padding:30px}.login-brand .brand-mark{background:var(--sidebar);color:#fff}.login-card h1{margin:28px 0 4px}.login-card>p{color:var(--muted);margin:0 0 24px}.login-card form{display:flex;flex-direction:column;gap:14px}.install-wrap{width:100%;max-width:850px;background:#fff;border:1px solid var(--line);border-radius:18px;box-shadow:0 24px 70px rgba(31,45,82,.14);padding:30px}.install-wrap h1{margin-top:25px}.requirements{background:#f8f9fc;border:1px solid var(--line);border-radius:12px;padding:14px;margin:18px 0}.requirements>div{display:grid;grid-template-columns:24px 1fr auto;padding:6px 0;font-size:13px}.requirements em{font-style:normal;color:var(--muted)}.install-form h3{margin:24px 0 10px}.install-success{text-align:center;padding:30px 0}.install-success h1{color:var(--green)}code{background:#f0f2f7;padding:2px 5px;border-radius:5px}@media(max-width:1200px){.kpi-grid{grid-template-columns:repeat(2,1fr)}.report-kpis{grid-template-columns:repeat(3,1fr)}.alert-grid{grid-template-columns:repeat(2,1fr)}}@media(max-width:900px){.sidebar{transform:translateX(-100%);transition:.22s}.sidebar.open{transform:none}.main{margin-left:0}.menu-btn{display:block}.topbar{padding:0 14px}.content{padding:18px}.two-col,.detail-grid,.settings-grid{grid-template-columns:1fr}.form-grid.three,.status-edit-grid{grid-template-columns:1fr}.global-search{max-width:none}.top-user{display:none}.page-head{flex-direction:column}.page-actions{width:100%}.alert-grid{grid-template-columns:1fr 1fr}}@media(max-width:600px){.content{padding:12px}.kpi-grid,.alert-grid,.report-kpis{grid-template-columns:1fr 1fr}.kpi strong{font-size:18px}.form-grid{grid-template-columns:1fr}.span-2{grid-column:auto}.filter-bar{align-items:stretch}.filter-bar input,.filter-bar select,.filter-bar input[name=q]{width:100%;min-width:0}.page-actions .btn{flex:1}.panel{padding:12px;border-radius:11px}.login-page,.install-page{padding:12px}.login-card,.install-wrap{padding:20px}.form-actions{flex-direction:column}.form-actions .btn{width:100%}}@media print{.sidebar,.topbar,.page-actions,.print-hide,.filter-bar{display:none!important}.main{margin:0}.content{padding:0}.panel,.kpi{box-shadow:none}.kpi-grid{grid-template-columns:repeat(4,1fr)}body{background:#fff}}
.user-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.user-actions form{margin:0}.reset-pass{display:flex;align-items:center;gap:6px}.reset-pass input{width:130px;padding:5px 7px;font-size:11px}
.trend-chart{height:210px;display:grid;grid-template-columns:repeat(7,1fr);gap:8px;align-items:end;padding:18px 4px 0}.trend-col{height:100%;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;gap:5px;min-width:0}.trend-col i{width:min(38px,70%);min-height:3px;background:var(--brand2);border-radius:7px 7px 2px 2px;display:block}.trend-col small{font-size:10px;color:var(--muted)}.trend-value{font-size:10px;color:#4e5870;white-space:nowrap}
.backup-list{margin-top:16px;border-top:1px solid var(--line);padding-top:12px}.backup-list h4{margin:0 0 8px}.backup-list>div{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:8px 0;border-bottom:1px solid #edf0f5;font-size:12px}.backup-list span b,.backup-list span small{display:block}.backup-list span small{color:var(--muted);margin-top:2px}
.mobile-order-list{display:none}.mobile-order-card{background:#fff;border:1px solid var(--line);border-radius:12px;padding:13px;margin-bottom:10px}.mobile-order-top{display:flex;justify-content:space-between;align-items:flex-start;gap:12px}.mobile-order-top>div{display:flex;flex-direction:column;gap:3px;min-width:0}.mobile-order-top small{color:var(--muted);font-size:11px}.mobile-order-top>b{white-space:nowrap;font-size:16px}.mobile-status-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:12px}.mobile-status-grid label{font-size:10px;color:var(--muted)}.mobile-status-grid .inline-select{display:block;width:100%;margin-top:4px;min-width:0}.mobile-order-foot{display:flex;justify-content:space-between;align-items:center;border-top:1px solid var(--line);margin-top:11px;padding-top:9px;font-size:11px;color:var(--muted)}
@media(max-width:700px){.orders-desktop{display:none}.mobile-order-list{display:block}}

/* V1.0.3 - dynamic user permissions */
.permission-intro{display:flex;justify-content:space-between;align-items:center;gap:20px}.permission-intro p{margin:.35rem 0 0;color:var(--muted,#6b7280)}
.permission-role{display:flex;align-items:end;gap:16px;flex-wrap:wrap}.permission-role label{min-width:260px}.permission-role small{color:var(--muted,#6b7280);padding-bottom:10px}
.permission-form{display:grid;gap:16px}.permission-group{margin:0}.permission-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.permission-item{display:flex!important;align-items:flex-start!important;gap:10px;padding:12px;border:1px solid #e5e7eb;border-radius:10px;background:#fff;cursor:pointer}.permission-item:hover{background:#f9fafb}.permission-item input{width:18px;height:18px;margin-top:2px;flex:0 0 auto}.permission-item span{display:grid;gap:3px}.permission-item strong{font-size:14px}.permission-item small{font-size:12px;color:#6b7280;line-height:1.35}.permission-item em{font-size:11px;color:#94a3b8;font-style:normal}.permission-reset{margin-top:12px}
button[disabled],select[disabled],input[disabled],textarea[disabled]{opacity:.62;cursor:not-allowed}
@media(max-width:900px){.permission-grid{grid-template-columns:1fr}.permission-intro{align-items:flex-start;flex-direction:column}}

/* V1.0.4 - bộ lọc Đơn hàng gọn: bỏ khoảng ngày, tự lọc dropdown */
.order-filter-bar{align-items:center}
.order-filter-bar input[name=q]{min-width:260px;flex:1 1 260px;max-width:420px}
.order-filter-bar select{min-width:160px}
@media(max-width:600px){.order-filter-bar input[name=q],.order-filter-bar select,.order-filter-bar .btn{width:100%;max-width:none}}

/* V1.0.5 - Đơn hàng theo UI Mẫu 1: premium SaaS, chỉ đổi giao diện */
.page-orders{--orders-blue:#155eef;--orders-navy:#12213d;--orders-muted:#66758f;--orders-border:#e1e8f2;--orders-soft:#f7f9fc;--orders-shadow:0 10px 32px rgba(30,52,91,.075)}
.page-orders .topbar{height:58px;background:rgba(255,255,255,.96);border-bottom:1px solid #e9edf4;box-shadow:none}.page-orders .global-search-spacer{display:block;flex:1}.page-orders .content{padding:28px 30px 36px;background:#f7f9fc}.page-orders .orders-page-shell{max-width:1600px;margin:0 auto}.page-orders .page-head{align-items:center;margin-bottom:22px}.page-orders .page-head h1{font-size:30px;line-height:1.1;color:var(--orders-navy);font-weight:800;letter-spacing:-.7px}.page-orders .page-head p{font-size:14px;color:#71809a;margin-top:7px}.page-orders .page-actions{gap:10px}.page-orders .order-action-btn{height:44px;padding:0 16px;border-radius:10px;border-color:#dce3ee;background:#fff;color:#1b2942;box-shadow:0 2px 6px rgba(25,43,72,.025);gap:9px;font-weight:700}.page-orders .order-action-btn svg{width:18px;height:18px}.page-orders .order-action-btn:hover{border-color:#bfcbe0;background:#fbfcff;transform:translateY(-1px)}.page-orders .order-action-btn.primary{background:var(--orders-blue);border-color:var(--orders-blue);color:#fff;box-shadow:0 8px 20px rgba(21,94,239,.2)}.page-orders .order-action-btn.primary:hover{background:#0f52da;border-color:#0f52da}
.page-orders .order-filter-bar{display:grid;grid-template-columns:minmax(260px,1.45fr) repeat(4,minmax(165px,.8fr)) auto;gap:12px;align-items:center;padding:18px;background:#fff;border:1px solid var(--orders-border);border-radius:14px;box-shadow:var(--orders-shadow);margin-bottom:18px}.page-orders .order-search-control,.page-orders .order-filter-control{position:relative;display:flex;align-items:center;height:52px;min-width:0;border:1px solid #dbe3ee;border-radius:10px;background:#fff;transition:.18s}.page-orders .order-search-control:focus-within,.page-orders .order-filter-control:focus-within{border-color:#7aa3ff;box-shadow:0 0 0 3px rgba(21,94,239,.08)}.page-orders .order-search-control input,.page-orders .order-filter-control select{height:100%;width:100%;border:0!important;box-shadow:none!important;background:transparent!important;border-radius:10px;padding:0 38px 0 44px;color:#17233b;font-size:14px}.page-orders .order-search-control input::placeholder{color:#8b98ad}.page-orders .order-filter-control select{appearance:none;-webkit-appearance:none;cursor:pointer;padding-right:36px;font-weight:600}.page-orders .order-control-icon{position:absolute;left:15px;display:flex;color:#13274b;z-index:1;pointer-events:none}.page-orders .order-control-icon svg{width:19px;height:19px}.page-orders .order-control-chevron{position:absolute;right:12px;display:flex;color:#2f405c;pointer-events:none}.page-orders .order-control-chevron svg{width:17px;height:17px}.page-orders .order-reset-btn{height:52px;gap:8px;padding:0 15px;border-radius:10px;border-color:#dbe3ee;background:#fff;color:var(--orders-blue);font-weight:700}.page-orders .order-reset-btn svg{width:19px;height:19px}.page-orders .order-reset-btn:hover{background:#f6f9ff;border-color:#bdcdf0}
.page-orders .orders-table-panel{padding:0;border:1px solid var(--orders-border);border-radius:14px;overflow:hidden;box-shadow:var(--orders-shadow);background:#fff}.page-orders .orders-table-panel .table-wrap{overflow:auto}.page-orders .order-data-table{min-width:1120px;border-collapse:separate;border-spacing:0}.page-orders .order-data-table th{position:sticky;top:0;z-index:2;height:58px;padding:0 16px;background:#fbfcfe;color:#53637e;border-bottom:1px solid var(--orders-border);font-size:11px;font-weight:800;letter-spacing:.45px;text-transform:uppercase}.page-orders .order-data-table td{height:66px;padding:10px 16px;border-bottom:1px solid #edf1f6;font-size:13px;color:#24324b;background:#fff}.page-orders .order-data-table tbody tr:last-child td{border-bottom:0}.page-orders .order-data-table tbody tr:hover td{background:#fbfdff}.page-orders .order-data-table .order-code{color:#155eef;font-weight:800;letter-spacing:.1px}.page-orders .order-data-table td>strong{font-weight:750;color:#15213a}.page-orders .order-data-table small{color:#77869f;line-height:1.3}.page-orders .order-data-table .num.strong{font-size:14px;color:#13213e;font-weight:800}.page-orders .order-date{display:flex;align-items:flex-start;gap:8px;white-space:nowrap;color:#52647f}.page-orders .order-date-icon{display:flex;margin-top:1px;color:#60769b}.page-orders .order-date-icon svg{width:17px;height:17px}.page-orders .order-date small{display:flex;align-items:center;gap:4px;margin-top:3px;font-size:11px}.page-orders .clock-mini{display:flex}.page-orders .clock-mini svg{width:13px;height:13px}.page-orders .order-more-btn{width:34px;height:34px;border:1px solid #dde5f0;background:#fff;color:#253654;border-radius:9px}.page-orders .order-more-btn:hover{border-color:#b8c7dc;background:#f7faff}.page-orders .order-more-btn svg{width:18px;height:18px}
.page-orders .status-select-shell,.page-orders .order-status-pill{position:relative;display:inline-flex;align-items:center;min-height:32px;border-radius:8px;border:1px solid transparent;font-weight:700;white-space:nowrap}.page-orders .status-select-shell{min-width:132px;padding-left:30px}.page-orders .status-select-shell.badge-green,.page-orders .order-status-pill.badge-green{background:#ecfbf2;color:#16864a;border-color:#ccefd9}.page-orders .status-select-shell.badge-blue,.page-orders .order-status-pill.badge-blue{background:#edf4ff;color:#155eef;border-color:#cfddff}.page-orders .status-select-shell.badge-amber,.page-orders .order-status-pill.badge-amber{background:#fff8e7;color:#d47b05;border-color:#ffe1aa}.page-orders .status-select-shell.badge-red,.page-orders .order-status-pill.badge-red{background:#fff0f1;color:#e0454f;border-color:#ffcfd3}.page-orders .status-select-shell.badge-gray,.page-orders .order-status-pill.badge-gray{background:#f1f4f8;color:#66758f;border-color:#dde4ed}.page-orders .status-select-icon{position:absolute;left:9px;display:flex;pointer-events:none}.page-orders .status-select-icon svg{width:16px;height:16px}.page-orders .status-select-shell .order-inline-select{min-width:130px;height:30px;border:0!important;box-shadow:none!important;background:transparent!important;color:inherit!important;font-size:12px;font-weight:800;padding:0 28px 0 0;appearance:none;-webkit-appearance:none;cursor:pointer}.page-orders .status-select-shell .status-select-chevron{position:absolute;right:7px;display:flex;pointer-events:none}.page-orders .status-select-shell .status-select-chevron svg{width:14px;height:14px}.page-orders .order-status-pill{gap:6px;padding:6px 9px;font-size:12px}.page-orders .order-status-pill>span{display:flex}.page-orders .order-status-pill svg{width:15px;height:15px}
.page-orders .carrier-select-shell,.page-orders .carrier-label{display:inline-flex;align-items:center;gap:8px;min-width:122px;position:relative}.page-orders .carrier-select-shell{padding-right:18px}.page-orders .carrier-icon{width:28px;height:28px;border-radius:7px;display:inline-flex;align-items:center;justify-content:center;flex:0 0 28px;border:1px solid currentColor}.page-orders .carrier-icon svg{width:16px;height:16px}.page-orders .carrier-orange{background:#fff6ea;color:#e67600}.page-orders .carrier-red{background:#fff0f1;color:#d93c48}.page-orders .carrier-green{background:#ecfbf2;color:#16864a}.page-orders .carrier-blue{background:#edf4ff;color:#155eef}.page-orders .order-carrier-select{height:32px;min-width:100px;border:0!important;background:transparent!important;box-shadow:none!important;padding:0 22px 0 0;font-size:12px;font-weight:700;appearance:none;-webkit-appearance:none}.page-orders .carrier-select-shell .status-select-chevron{right:0;position:absolute;display:flex;pointer-events:none}.page-orders .carrier-select-shell .status-select-chevron svg{width:14px;height:14px}.page-orders .orders-table-footer{min-height:52px;display:flex;align-items:center;justify-content:space-between;gap:15px;padding:0 18px;border-top:1px solid var(--orders-border);color:#71809a;font-size:12px;background:#fff}.page-orders .orders-table-hint{color:#94a0b3}
@media(max-width:1300px){.page-orders .order-filter-bar{grid-template-columns:minmax(250px,1.4fr) repeat(2,minmax(170px,1fr))}.page-orders .order-reset-btn{width:100%}}
@media(max-width:900px){.page-orders .content{padding:18px}.page-orders .order-filter-bar{grid-template-columns:1fr 1fr}.page-orders .order-search-control{grid-column:1/-1}.page-orders .page-head{align-items:flex-start}.page-orders .page-actions{width:100%}.page-orders .page-actions .order-action-btn{flex:1}.page-orders .orders-table-hint{display:none}}
@media(max-width:600px){.page-orders .content{padding:12px}.page-orders .order-filter-bar{grid-template-columns:1fr;padding:12px}.page-orders .order-search-control{grid-column:auto}.page-orders .order-search-control,.page-orders .order-filter-control,.page-orders .order-reset-btn{height:48px}.page-orders .page-head h1{font-size:25px}.page-orders .page-actions{gap:6px}.page-orders .order-action-btn{padding:0 10px;font-size:12px}.page-orders .order-action-btn svg{width:16px;height:16px}.page-orders .orders-table-panel{border:0;box-shadow:none;background:transparent}.page-orders .orders-table-footer{display:none}}
.page-orders .order-search-control input[name=q]{min-width:0!important;max-width:none!important}

/* ================================================================
   V1.0.6 — UI Refresh toàn hệ thống theo Design System "Mẫu 1"
   PHẠM VI: CHỈ GIAO DIỆN. Không thay đổi DB / nghiệp vụ / quyền / API.
   ================================================================ */
:root{
  --bg:#f6f8fc;
  --panel:#ffffff;
  --text:#14213d;
  --muted:#71809a;
  --line:#e3e9f2;
  --brand:#155eef;
  --brand2:#2f6ff2;
  --sidebar:#182f5b;
  --danger:#e0454f;
  --green:#16864a;
  --amber:#d47b05;
  --blue:#155eef;
  --indigo:#6d4aff;
  --shadow:0 8px 28px rgba(30,52,91,.065);
  --shadow-soft:0 2px 10px rgba(30,52,91,.045);
  --radius:14px;
  --control-h:46px;
}
html,body{background:var(--bg);color:var(--text);font-size:14px}
body{letter-spacing:-.005em}
a{color:var(--brand)}

/* App shell / sidebar */
.sidebar{width:190px;background:linear-gradient(180deg,#1a315e 0%,#172b52 100%);padding:16px 10px;box-shadow:8px 0 24px rgba(17,35,68,.05)}
.main{margin-left:190px}
.brand{gap:10px;padding:0 4px}
.brand-mark{width:38px;height:38px;border-radius:10px;color:#17315f;font-size:13px;box-shadow:0 3px 10px rgba(0,0,0,.08)}
.brand strong{font-size:13px;letter-spacing:.8px}
.brand small{font-size:10px;opacity:.58}
.sidebar nav{margin-top:18px;gap:3px}
.nav-link{min-height:39px;border-radius:9px;padding:9px 10px;gap:9px;color:#dbe6ff;font-size:12px;font-weight:600;transition:background .16s,color .16s,transform .16s}
.nav-link span{width:18px;font-size:13px;opacity:.9}
.nav-link:hover{background:rgba(255,255,255,.075);transform:translateX(1px)}
.nav-link.active{background:rgba(255,255,255,.14);box-shadow:inset 3px 0 0 #7ea7ff;color:#fff}
.sidebar-bottom{border-top-color:rgba(255,255,255,.1);padding-top:12px}
.user-mini{padding:8px 10px 10px}
.user-mini strong{font-size:13px}.user-mini small{font-size:10px}

/* Topbar */
.topbar{height:62px;padding:0 26px;background:rgba(255,255,255,.96);border-bottom:1px solid #e7ecf4;box-shadow:0 1px 0 rgba(20,33,61,.015)}
.global-search{max-width:510px}
.global-search input{height:42px;border-color:#dce4ef;border-radius:10px 0 0 10px;background:#fbfcfe;padding-left:14px}
.global-search button{height:42px;border-color:#dce4ef;border-radius:0 10px 10px 0;color:#42526d;background:#fbfcfe}
.top-user{font-weight:700;color:#23324c;font-size:13px}
.menu-btn{color:#1c3155}

/* Content / headings */
.content{padding:28px 30px 38px;max-width:1720px}
.page-head{align-items:center;margin-bottom:20px}
.page-head h1{font-size:29px;line-height:1.15;font-weight:800;letter-spacing:-.7px;color:#12213d}
.page-head p{font-size:13px;color:#75849d;margin-top:6px}
.page-actions{gap:9px}

/* Buttons */
.btn{min-height:42px;border-radius:10px;padding:0 14px;border:1px solid #dce4ef;background:#fff;color:#22324d;font-size:13px;font-weight:700;box-shadow:0 1px 3px rgba(20,33,61,.02);transition:.15s}
.btn:hover{background:#f9fbff;border-color:#becce0;transform:translateY(-1px)}
.btn.primary{background:#155eef;border-color:#155eef;color:#fff;box-shadow:0 7px 18px rgba(21,94,239,.18)}
.btn.primary:hover{background:#0f52da;border-color:#0f52da}
.btn.ghost{background:#fff;color:#4a5b75}
.btn.large{min-height:46px;padding:0 18px}
.link-btn{color:#155eef;font-weight:700}
.link-danger{color:#d83946;font-weight:700}

/* Panels */
.panel{border:1px solid #e3e9f2;border-radius:14px;box-shadow:var(--shadow);padding:18px;background:#fff;margin-bottom:18px}
.panel-head{margin-bottom:15px}.panel-head h3,.panel h3{font-size:15px;font-weight:800;color:#192842}
.panel-note{background:#f8faff;border:1px solid #e0e7f2;border-left:3px solid #9db8f1;border-radius:9px;color:#667791;padding:11px 13px}

/* Inputs / selects */
input,select,textarea{border:1px solid #dbe3ee;border-radius:10px;background:#fff;color:#17233b;padding:10px 12px;min-height:42px;transition:border-color .15s,box-shadow .15s}
input:hover,select:hover,textarea:hover{border-color:#c7d2e3}
input:focus,select:focus,textarea:focus{border-color:#7aa3ff;box-shadow:0 0 0 3px rgba(21,94,239,.08)}
input::placeholder,textarea::placeholder{color:#9aa6b8}

/* Generic filter bars — đồng bộ Mẫu 1 */
.filter-bar{gap:10px;align-items:center;padding:14px;background:#fff;border:1px solid #e2e8f1;border-radius:14px;box-shadow:var(--shadow-soft);margin-bottom:16px}
.filter-bar input,.filter-bar select{min-height:44px;border-radius:10px}
.filter-bar input[name=q]{min-width:260px}
.filter-bar .btn{min-height:44px}

/* Tables */
.table-wrap{border-radius:11px}
.data-table{border-collapse:separate;border-spacing:0}
.data-table th{height:50px;padding:0 12px;background:#fafbfd;color:#596983;border-bottom:1px solid #e4eaf2;font-size:10.5px;font-weight:800;letter-spacing:.42px}
.data-table td{padding:11px 12px;border-bottom:1px solid #edf1f6;font-size:12.5px;color:#273750;background:#fff}
.data-table tbody tr:last-child td{border-bottom:0}
.data-table tbody tr:hover td{background:#fbfdff}
.data-table .strong{font-weight:800;color:#172542}
.data-table small{color:#7c8ba2}
.order-code{color:#155eef;font-weight:800}
.empty{padding:36px!important;color:#8190a6}
.icon-btn{width:32px;height:32px;border:1px solid #e0e7f1;background:#f8faff;color:#263b60;border-radius:9px}

/* Badges/status */
.badge{padding:6px 9px;border-radius:8px;font-size:11px;font-weight:800;border:1px solid transparent}
.badge-green,.dot.badge-green{background:#ecfbf2;color:#16864a;border-color:#ccefd9}
.badge-blue,.dot.badge-blue{background:#edf4ff;color:#155eef;border-color:#cfddff}
.badge-amber,.dot.badge-amber{background:#fff8e7;color:#d47b05;border-color:#ffe1aa}
.badge-red,.dot.badge-red{background:#fff0f1;color:#e0454f;border-color:#ffcfd3}
.badge-gray,.dot.badge-gray{background:#f1f4f8;color:#66758f;border-color:#dde4ed}
.inline-select{border-radius:8px;font-size:11.5px;font-weight:800;min-height:32px}

/* Dashboard */
.kpi-grid{gap:14px}
.kpi{position:relative;overflow:hidden;border:1px solid #e3e9f2;border-top:1px solid #e3e9f2;border-radius:14px;padding:17px 18px;box-shadow:var(--shadow);background:#fff;min-height:118px}
.kpi:before{content:"";position:absolute;left:0;top:0;bottom:0;width:4px;background:#a5afc0}
.kpi.blue:before{background:#155eef}.kpi.indigo:before{background:#6d4aff}.kpi.green:before{background:#16864a}.kpi.red:before{background:#e0454f}.kpi.amber:before{background:#d47b05}
.kpi span,.kpi small{font-size:11.5px;color:#76849a}
.kpi strong{font-size:24px;color:#14213d;margin:9px 0 6px;font-weight:850}
.section-title{font-size:17px;font-weight:800;color:#172542;margin:25px 0 12px}
.alert-grid{gap:12px}
.alert-card{border:1px solid #e3e9f2;border-left:1px solid #e3e9f2;border-radius:13px;box-shadow:var(--shadow-soft);padding:16px;position:relative;overflow:hidden}
.alert-card:before{content:"";position:absolute;left:0;top:0;bottom:0;width:4px;background:#8795ab}
.alert-card.danger:before{background:#e0454f}.alert-card.warning:before{background:#d47b05}.alert-card.info:before{background:#155eef}.alert-card.muted:before{background:#8795ab}
.alert-card strong{font-size:25px;color:#172542}.alert-card span{color:#687891;font-weight:600}
.two-col{gap:16px}.bar-track{background:#eef2f7}.bar-track i{background:#3d71e8}
.trend-col i{background:linear-gradient(180deg,#155eef,#4f7ef2)}

/* Cards used in payments/shipping */
.mini-kpi-row,.carrier-cards{gap:12px}
.mini-kpi-row a,.carrier-cards a{border:1px solid #e3e9f2;border-radius:13px;padding:14px 15px;box-shadow:var(--shadow-soft);transition:.15s}
.mini-kpi-row a:hover,.carrier-cards a:hover{transform:translateY(-1px);border-color:#c9d6e9;box-shadow:var(--shadow)}

/* Tabs */
.tabs{gap:7px;margin-bottom:16px}
.tabs a{padding:9px 13px;border:1px solid #dde5ef;border-radius:9px;background:#fff;color:#50617b;font-size:12px;font-weight:700}
.tabs a:hover{background:#f8faff}
.tabs a.active{background:#155eef;color:#fff;border-color:#155eef;box-shadow:0 5px 14px rgba(21,94,239,.15)}

/* Forms */
.form-panel{max-width:1180px}
.form-section{padding:5px 0 22px;border-bottom:1px solid #e8edf4;margin-bottom:22px}
.form-section h3{font-size:15px;color:#1a2943;margin-bottom:15px}
.form-grid{gap:15px}.form-grid label,.stack-form label,.install-form label,.login-card label{color:#5e6e87;font-size:11.5px;font-weight:700}
.form-actions{gap:9px}.upload-box{border-color:#cbd7e8;background:#fafcff;border-radius:12px;color:#73829a}
.upload-box:hover{background:#f6f9ff;border-color:#8facdf}

/* Detail pages */
.detail-grid{gap:16px}.detail-list{gap:12px}.detail-list>div{padding:12px 13px;background:#f8faff;border:1px solid #edf1f6;border-radius:10px}
.detail-list dt{color:#7a889c;font-size:10px;font-weight:800}.detail-list dd{color:#23334e}
.big-money{color:#155eef}
.gallery{gap:13px}.image-card{border-color:#e2e8f1;border-radius:11px;box-shadow:var(--shadow-soft)}

/* Settings / permissions */
.settings-grid{gap:16px}
.simple-table td{padding:11px 7px;border-color:#edf1f6}
.status-row{gap:9px}.status-edit-grid{gap:16px}
.permission-item{border-color:#e1e8f2;border-radius:11px;background:#fff;padding:13px}
.permission-item:hover{background:#f8faff;border-color:#cbd8ea}
.permission-item input{accent-color:#155eef}
.permission-group{border-radius:14px}
.permission-role label{color:#5e6e87}

/* Alerts / severity */
.severity{border-radius:7px;padding:5px 7px;letter-spacing:.2px}
.severity.red{background:#fff0f1;color:#d93a46}.severity.orange{background:#fff4e8;color:#c96c00}.severity.yellow{background:#fff9df;color:#8a6b00}.severity.gray{background:#f1f4f8;color:#66758f}

/* Flash / toast */
.flash{border-radius:10px;padding:12px 14px;font-weight:650}
.flash.success{background:#ecfbf2;color:#167b46;border-color:#ccefd9}.flash.error{background:#fff0f1;color:#c63743;border-color:#ffcfd3}
.toast{background:#172b52;border-radius:10px;box-shadow:0 12px 34px rgba(23,43,82,.2)}

/* Login / installer — cùng design system */
.login-page,.install-page{background:radial-gradient(circle at 10% 10%,#f0f5ff 0,transparent 34%),linear-gradient(135deg,#f7f9fd,#eef3fb)}
.login-card,.install-wrap{border-color:#e1e8f2;border-radius:18px;box-shadow:0 24px 70px rgba(30,52,91,.13)}
.login-brand .brand-mark{background:#172f5c}.requirements{background:#f8faff;border-color:#e3e9f2}

/* Orders page: giữ UI Mẫu 1 nhưng đồng bộ với theme toàn hệ thống */
.page-orders .content{background:var(--bg)}
.page-orders .orders-page-shell{max-width:1680px}
.page-orders .order-filter-bar{box-shadow:var(--shadow-soft);border-color:#e2e8f1}
.page-orders .orders-table-panel{box-shadow:var(--shadow-soft)}
.page-orders .order-data-table th{background:#fafbfd}
.page-orders .orders-table-footer{background:#fbfcfe}

/* Mobile */
.mobile-order-card{border-color:#e2e8f1;border-radius:13px;box-shadow:var(--shadow-soft);padding:14px}
.mobile-order-foot{border-color:#edf1f6}

@media(max-width:1200px){
  .content{padding:24px}
}
@media(max-width:900px){
  .sidebar{width:190px}
  .main{margin-left:0}
  .content{padding:18px}
  .page-head h1{font-size:25px}
  .topbar{padding:0 16px}
}
@media(max-width:600px){
  .content{padding:12px}
  .page-head{margin-bottom:15px}
  .page-head h1{font-size:24px}
  .filter-bar{padding:11px}
  .panel{padding:13px;border-radius:12px}
  .kpi{min-height:105px;padding:14px}
  .kpi strong{font-size:20px}
}


/* =========================================================
   V1.0.7 — UI POLISH
   Chỉ tinh chỉnh presentation. Không thay nghiệp vụ / DB.
   ========================================================= */

/* Sidebar icons: một bộ line-icon thống nhất */
.nav-link .nav-svg{width:17px;height:17px;display:block;stroke-width:1.9}
.nav-link span{display:flex;align-items:center;justify-content:center}
.brand-mark{box-shadow:0 5px 16px rgba(9,25,58,.18)}

/* Dashboard: hierarchy rõ hơn, giảm cảm giác "ô Excel" */
.page-dashboard .kpi-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:13px}
.page-dashboard .kpi{min-height:112px;padding:16px 17px 15px;transition:transform .16s,border-color .16s,box-shadow .16s}
.page-dashboard .kpi:hover{transform:translateY(-1px);border-color:#d6e0ee;box-shadow:0 10px 28px rgba(30,52,91,.075)}
.kpi-top{display:flex;align-items:center;justify-content:space-between;gap:10px}
.kpi-top>span:first-child{font-weight:700;color:#74839a}
.kpi-icon{width:32px;height:32px;border-radius:9px;display:flex!important;align-items:center;justify-content:center;background:#f3f6fb;color:#64758f;border:1px solid #e7ecf4}
.kpi-icon svg{width:16px;height:16px}
.kpi.blue .kpi-icon{background:#edf4ff;color:#155eef;border-color:#dbe7ff}
.kpi.indigo .kpi-icon{background:#f1efff;color:#6d4aff;border-color:#e3ddff}
.kpi.green .kpi-icon{background:#ecfbf2;color:#16864a;border-color:#d7f2e1}
.kpi.red .kpi-icon{background:#fff0f1;color:#e0454f;border-color:#ffdbde}
.kpi.amber .kpi-icon{background:#fff8e7;color:#d47b05;border-color:#ffebc1}
.page-dashboard .kpi strong{font-size:23px;margin:8px 0 4px}
.page-dashboard .alert-grid{grid-template-columns:repeat(5,minmax(0,1fr));gap:12px}
.page-dashboard .alert-card{min-height:88px;justify-content:center;padding:14px 16px 14px 18px}
.page-dashboard .alert-card strong{font-size:23px}
.page-dashboard .alert-card span{font-size:12px;line-height:1.35}
.page-dashboard .two-col{margin-top:16px}
.page-dashboard .two-col .panel{padding:16px 17px}
.page-dashboard .trend-chart{height:168px;padding-top:10px}
.page-dashboard .trend-col i{width:min(34px,64%)}
.page-dashboard .status-summary{gap:9px}
.page-dashboard .bar-list{gap:10px}
.page-dashboard .bar-track{height:7px}

/* Order form: rộng hơn, cân giữa, section rõ nhưng vẫn cùng workflow */
.page-order_form .content{max-width:1720px}
.page-order_form .page-head{max-width:1320px;margin-left:auto;margin-right:auto}
.order-form-panel{width:min(1320px,96%);max-width:1320px;margin:0 auto 20px;padding:22px 24px}
.order-form-panel .form-section{position:relative;padding:4px 0 24px;margin-bottom:24px}
.order-form-panel .form-section h3{display:flex;align-items:center;gap:9px;font-size:16px;margin-bottom:16px;color:#172642}
.order-form-panel .form-section h3:before{content:"";width:8px;height:8px;border-radius:50%;background:#155eef;box-shadow:0 0 0 5px #edf4ff}
.order-form-panel .form-grid{gap:16px 18px}
.order-form-panel .form-grid label{font-size:12px;color:#5d6d86}
.order-form-panel input,.order-form-panel select,.order-form-panel textarea{background:#fcfdff}
.order-form-panel input:focus,.order-form-panel select:focus,.order-form-panel textarea:focus{background:#fff}
.field-hint{display:inline;font-size:10px!important;font-weight:600!important;color:#99a5b5!important;margin-left:6px}
.legacy-stt-field input{background:#f7f9fc;color:#69778e}
.order-form-panel .form-actions{padding-top:2px}
.order-form-panel .upload-box{min-height:102px}

/* Reconciliation: dùng cùng ngôn ngữ bảng Đơn hàng */
.reconcile-panel{padding:0;overflow:hidden}
.reconcile-toolbar{margin:0;padding:13px 16px;background:#f8faff;border:0;border-bottom:1px solid #e6ecf4;border-radius:0;align-items:center;display:grid;grid-template-columns:minmax(220px,1fr) minmax(180px,240px) auto;gap:12px}
.reconcile-toolbar-copy{display:flex;flex-direction:column;gap:3px}
.reconcile-toolbar-copy strong{font-size:13px;color:#1d2c47}
.reconcile-toolbar-copy small{font-size:11px;color:#7b899f}
.reconcile-toolbar select{width:100%;min-width:0}
.reconcile-table{min-width:900px}
.reconcile-table th{height:48px}
.reconcile-table td{height:56px;padding-top:10px;padding-bottom:10px}
.reconcile-table .check-col{width:54px;text-align:center;padding-left:14px;padding-right:8px}
.table-check{appearance:none;-webkit-appearance:none;width:18px!important;height:18px!important;min-height:18px!important;padding:0!important;margin:0!important;border:1.5px solid #b9c4d4!important;border-radius:5px!important;background:#fff!important;display:inline-grid!important;place-content:center;cursor:pointer;vertical-align:middle}
.table-check:before{content:"";width:9px;height:9px;transform:scale(0);transition:transform .1s ease;box-shadow:inset 1em 1em #fff;clip-path:polygon(14% 44%,0 59%,42% 100%,100% 16%,84% 0,40% 62%)}
.table-check:checked{background:#155eef!important;border-color:#155eef!important}
.table-check:checked:before{transform:scale(1)}
.reconcile-table .badge{min-width:112px;justify-content:center}

/* Settings: card cao theo nội dung, checkbox nhỏ gọn, danh sách rõ hơn */
.page-settings .settings-grid{align-items:start;grid-template-columns:minmax(0,1fr) minmax(0,1fr)}
.page-settings .settings-card{align-self:start;margin-bottom:0}
.page-settings .stack-form{gap:10px}
.page-settings .stack-form .check{min-height:38px;padding:8px 10px;border:1px solid #e8edf4;border-radius:9px;background:#fafcff;color:#465872}
.page-settings .stack-form .check:hover{background:#f7faff;border-color:#d7e2f2}
.check input[type=checkbox]{width:17px!important;height:17px!important;min-height:17px!important;padding:0!important;accent-color:#155eef;flex:0 0 17px}
.telegram-settings-card .stack-form label:not(.check){margin-bottom:1px}
.carrier-settings-panel .inline-form{padding:12px;background:#f8faff;border:1px solid #e6ecf4;border-radius:11px;margin:13px 0 8px}
.carrier-settings-panel .simple-table td{height:48px;padding:9px 10px}
.carrier-settings-panel .simple-table tr:hover td{background:#fbfdff}
.carrier-settings-panel .simple-table td:nth-child(2){width:150px}
.carrier-settings-panel .simple-table td:last-child{width:70px}
.status-settings-panel .status-edit-grid>div{padding:14px;border:1px solid #e7ecf4;border-radius:11px;background:#fbfcfe}
.status-settings-panel .status-edit-grid h4{margin:0 0 10px;color:#263752}
.status-settings-panel .status-row{margin:7px 0}

/* Bảng chung / form: nhịp spacing đồng nhất hơn */
.data-table td{line-height:1.35}
.data-table th{line-height:1.2}
.simple-table{border-collapse:separate;border-spacing:0}
.simple-table tr:last-child td{border-bottom:0}

@media(max-width:1450px){
  .page-dashboard .alert-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
}
@media(max-width:1200px){
  .page-dashboard .kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .order-form-panel{width:100%}
  .reconcile-toolbar{grid-template-columns:1fr 220px}
  .reconcile-toolbar-copy{grid-column:1/-1}
}
@media(max-width:900px){
  .page-dashboard .alert-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .page-settings .settings-grid{grid-template-columns:1fr}
  .order-form-panel{padding:16px}
  .reconcile-toolbar{grid-template-columns:1fr}
}
@media(max-width:600px){
  .page-dashboard .kpi-grid,.page-dashboard .alert-grid{grid-template-columns:1fr}
  .order-form-panel{padding:13px}
  .field-hint{display:block;margin:3px 0 0}
}

/* =========================================================
   V1.0.8 — COMPACT LAYOUT
   UI-only: tối ưu mật độ hiển thị, gom các mục cùng hàng.
   Không thay nghiệp vụ / dữ liệu / database.
   ========================================================= */

/* Dashboard: gom KPI cùng một khung, giảm chiều cao và khoảng trắng */
.page-dashboard .content{padding-top:18px;padding-bottom:28px}
.page-dashboard .page-head{margin-bottom:12px;align-items:center}
.page-dashboard .page-head h1{font-size:27px}
.page-dashboard .page-head p{margin-top:3px}
.page-dashboard .kpi-grid{
  gap:0;
  overflow:hidden;
  border:1px solid #e3e9f2;
  border-radius:14px;
  background:#fff;
  box-shadow:var(--shadow-soft);
}
.page-dashboard .kpi{
  min-height:86px;
  padding:11px 13px 10px;
  border:0;
  border-radius:0;
  box-shadow:inset -1px -1px 0 #edf1f6;
  background:#fff;
  transition:background .15s;
}
.page-dashboard .kpi:before{display:none}
.page-dashboard .kpi:hover{transform:none;box-shadow:inset -1px -1px 0 #e5ebf3;background:#fbfdff}
.page-dashboard .kpi-top{min-height:27px}
.page-dashboard .kpi-top>span:first-child{font-size:11px}
.page-dashboard .kpi-icon{width:27px;height:27px;border-radius:8px}
.page-dashboard .kpi-icon svg{width:14px;height:14px}
.page-dashboard .kpi strong{font-size:20px;margin:3px 0 1px;line-height:1.15}
.page-dashboard .kpi small{font-size:10.5px}
.page-dashboard .section-title{margin:15px 0 7px;font-size:15px}

/* Việc cần xử lý: một khung duy nhất thay vì nhiều card rời */
.page-dashboard .alert-grid{
  gap:0;
  overflow:hidden;
  border:1px solid #e3e9f2;
  border-radius:13px;
  background:#fff;
  box-shadow:var(--shadow-soft);
}
.page-dashboard .alert-card{
  min-height:62px;
  padding:10px 13px;
  border:0;
  border-radius:0;
  box-shadow:inset -1px 0 0 #edf1f6;
  background:#fff;
  justify-content:center;
  transition:background .15s;
}
.page-dashboard .alert-card:before{display:none}
.page-dashboard .alert-card:hover{background:#f9fbff}
.page-dashboard .alert-card strong{font-size:20px;line-height:1}
.page-dashboard .alert-card span{font-size:10.8px;line-height:1.25;margin-top:4px}
.page-dashboard .alert-card.danger strong{color:#d83f4b}
.page-dashboard .alert-card.warning strong{color:#c87300}
.page-dashboard .alert-card.info strong{color:#155eef}
.page-dashboard .alert-card.muted strong{color:#62728b}

/* Dashboard charts/list: thấp hơn, ưu tiên thấy nhiều thông tin trong một màn hình */
.page-dashboard .two-col{gap:12px;margin-top:12px}
.page-dashboard .two-col .panel{padding:12px 14px;margin-bottom:0;border-radius:13px}
.page-dashboard .panel-head{margin-bottom:8px}
.page-dashboard .panel-head h3{font-size:13.5px}
.page-dashboard .trend-chart{height:128px;padding-top:5px}
.page-dashboard .trend-value{font-size:9px}
.page-dashboard .trend-col small{font-size:9px}
.page-dashboard .status-summary{gap:6px}
.page-dashboard .status-summary>div{font-size:11.5px}
.page-dashboard .bar-list{gap:7px}
.page-dashboard .bar-item>div:first-child{font-size:11.5px}
.page-dashboard .bar-track{height:6px;margin-top:4px}
.page-dashboard>.panel{margin-top:12px;margin-bottom:12px;padding:14px}

/* Form tạo/sửa đơn: một form compact, 12 cột, giảm tối đa cuộn dọc */
.page-order_form .content{padding-top:18px;max-width:1800px}
.page-order_form .page-head{max-width:1500px;margin:0 auto 12px;align-items:center}
.page-order_form .page-head h1{font-size:27px}
.page-order_form .page-head p{margin-top:3px}
.order-form-panel.compact-order-form{
  width:min(1500px,98%);
  max-width:1500px;
  margin:0 auto 16px;
  padding:15px 18px 12px;
  border-radius:14px;
}
.compact-form-grid{
  display:grid;
  grid-template-columns:repeat(12,minmax(0,1fr));
  gap:9px 11px;
  align-items:start;
}
.compact-form-grid .span-2{grid-column:span 2}
.compact-form-grid .span-3{grid-column:span 3}
.compact-form-grid .span-4{grid-column:span 4}
.compact-form-grid .span-5{grid-column:span 5}
.compact-form-grid .span-7{grid-column:span 7}
.compact-form-grid .span-12{grid-column:1/-1}
.compact-form-grid>label{
  display:block;
  min-width:0;
  font-size:11px;
  line-height:1.2;
  color:#5d6d86;
  font-weight:700;
}
.compact-form-grid>label>input,
.compact-form-grid>label>select,
.compact-form-grid>label>textarea{
  display:block;
  width:100%;
  margin-top:4px;
  min-height:38px;
  height:38px;
  padding:7px 10px;
  border-radius:8px;
  background:#fcfdff;
}
.compact-form-grid>label>textarea.compact-textarea{
  height:58px;
  min-height:58px;
  resize:vertical;
  line-height:1.35;
}
.compact-form-grid .legacy-stt-field input{background:#f7f9fc}
.compact-form-grid .field-hint{font-size:9px!important;margin-left:4px}
.compact-section-title{
  display:flex;
  align-items:baseline;
  gap:9px;
  padding:1px 0 2px;
  margin-top:1px;
  color:#172642;
}
.compact-section-title:not(:first-child){margin-top:4px;padding-top:8px;border-top:1px solid #edf1f6}
.compact-section-title strong{font-size:13.5px;font-weight:800;white-space:nowrap}
.compact-section-title strong:before{content:"";display:inline-block;width:6px;height:6px;border-radius:50%;background:#155eef;box-shadow:0 0 0 3px #edf4ff;margin:0 8px 1px 1px}
.compact-section-title span{font-size:10.5px;color:#8a98ac;font-weight:500}
.compact-upload-label{margin-top:0}
.compact-upload-title{display:block;margin-bottom:4px}
.order-form-panel .upload-box.compact-upload{
  min-height:42px;
  height:42px;
  padding:7px 12px;
  border-width:1px;
  border-style:dashed;
  border-radius:8px;
  justify-content:flex-start;
  font-size:11px;
  background:#fafcff;
}
.compact-form-actions{
  position:sticky;
  bottom:8px;
  z-index:8;
  margin-top:10px;
  padding:9px 0 0;
  border-top:1px solid #edf1f6;
  background:linear-gradient(180deg,rgba(255,255,255,.88),#fff 35%);
  backdrop-filter:blur(6px);
}
.compact-form-actions .btn{min-height:38px;padding:0 14px}

/* Nhỏ gọn thêm các input trong trang form nhưng không ảnh hưởng trang khác */
.page-order_form .compact-order-form input:focus,
.page-order_form .compact-order-form select:focus,
.page-order_form .compact-order-form textarea:focus{background:#fff}

@media(max-width:1450px){
  .page-dashboard .alert-grid{grid-template-columns:repeat(5,minmax(0,1fr))}
}
@media(max-width:1200px){
  .page-dashboard .kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .page-dashboard .alert-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
  .compact-form-grid .span-2,.compact-form-grid .span-3,.compact-form-grid .span-4{grid-column:span 6}
  .compact-form-grid .span-5,.compact-form-grid .span-7{grid-column:span 6}
  .order-form-panel.compact-order-form{width:100%}
}
@media(max-width:900px){
  .page-dashboard .alert-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .page-dashboard .two-col{grid-template-columns:1fr}
  .compact-form-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .compact-form-grid .span-2,.compact-form-grid .span-3,.compact-form-grid .span-4,.compact-form-grid .span-5,.compact-form-grid .span-7{grid-column:span 1}
  .compact-form-grid .span-12{grid-column:1/-1}
  .compact-section-title{grid-column:1/-1!important}
}
@media(max-width:600px){
  .page-dashboard .kpi-grid,.page-dashboard .alert-grid{grid-template-columns:1fr}
  .compact-form-grid{grid-template-columns:1fr}
  .compact-form-grid .span-2,.compact-form-grid .span-3,.compact-form-grid .span-4,.compact-form-grid .span-5,.compact-form-grid .span-7,.compact-form-grid .span-12{grid-column:1/-1}
  .compact-section-title span{display:none}
  .order-form-panel.compact-order-form{padding:12px}
  .compact-form-actions{position:static;flex-direction:column}
}

/* =========================================================
   V1.0.9 — MODULE UI SYNC
   Đồng bộ Thanh toán / Vận chuyển / Đối soát / Cảnh báo / Khách hàng
   theo ngôn ngữ UI của tab Đơn hàng. UI-only, không đổi DB/nghiệp vụ.
   ========================================================= */
.module-page-shell{max-width:1680px;margin:0 auto}
.module-page-shell .page-head{margin-bottom:16px}
.module-page-shell .page-head h1{font-size:28px;letter-spacing:-.65px;color:#102142}
.module-page-shell .page-head p{font-size:13px;color:#7b899f}

/* Thanh công cụ: dùng lại cấu trúc của Đơn hàng */
.module-page-shell .order-filter-bar{display:grid;grid-template-columns:minmax(300px,1.55fr) minmax(220px,.9fr) auto;gap:10px;padding:14px 16px;background:#fff;border:1px solid #e2e8f1;border-radius:14px;box-shadow:var(--shadow-soft);margin-bottom:16px}
.module-page-shell .order-search-control,.module-page-shell .order-filter-control{position:relative;display:flex;align-items:center;height:50px;min-width:0;border:1px solid #dbe3ee;border-radius:10px;background:#fff;transition:.18s}
.module-page-shell .order-search-control:focus-within,.module-page-shell .order-filter-control:focus-within{border-color:#7aa3ff;box-shadow:0 0 0 3px rgba(21,94,239,.08)}
.module-page-shell .order-search-control input,.module-page-shell .order-filter-control select{height:100%;width:100%;border:0!important;box-shadow:none!important;background:transparent!important;border-radius:10px;padding:0 38px 0 44px;color:#17233b;font-size:14px}
.module-page-shell .order-search-control input::placeholder{color:#8b98ad}
.module-page-shell .order-filter-control select{appearance:none;-webkit-appearance:none;cursor:pointer;padding-right:36px;font-weight:700}
.module-page-shell .order-control-icon{position:absolute;left:15px;display:flex;color:#13274b;z-index:1;pointer-events:none}
.module-page-shell .order-control-icon svg{width:18px;height:18px}
.module-page-shell .order-control-chevron{position:absolute;right:12px;display:flex;color:#2f405c;pointer-events:none}
.module-page-shell .order-control-chevron svg{width:16px;height:16px}
.module-page-shell .order-reset-btn{height:50px;gap:8px;padding:0 15px;border-radius:10px;border-color:#dbe3ee;background:#fff;color:#155eef;font-weight:800}
.module-page-shell .order-reset-btn svg{width:18px;height:18px}
.customer-filter-bar{grid-template-columns:minmax(360px,1fr) auto!important}

/* Summary: thay card cũ bằng strip gọn, cùng tinh thần Đơn hàng */
.module-summary-strip{display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:10px;margin:0 0 16px}
.module-summary-card{position:relative;display:flex;align-items:center;gap:11px;min-height:82px;padding:12px 14px;border:1px solid #e2e8f1;border-radius:12px;background:#fff;box-shadow:var(--shadow-soft);color:#24324b;transition:.15s}
.module-summary-card:hover{transform:translateY(-1px);border-color:#c9d6e9;box-shadow:0 9px 24px rgba(30,52,91,.08)}
.module-summary-card.active{border-color:#8eb0ff;box-shadow:0 0 0 3px rgba(21,94,239,.07)}
.module-summary-icon{width:34px;height:34px;display:flex;align-items:center;justify-content:center;border-radius:9px;background:#edf4ff;color:#155eef;border:1px solid #dce7fb;flex:0 0 34px}
.module-summary-icon svg{width:17px;height:17px}
.module-summary-copy{display:flex;min-width:0;flex-direction:column;gap:2px}
.module-summary-copy small{font-size:11px;color:#77869f;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.module-summary-copy strong{font-size:16px;color:#15213a}
.module-summary-copy b{font-size:11px;color:#66758f;font-weight:700}
.module-summary-card.badge-green .module-summary-icon{background:#ecfbf2;color:#16864a;border-color:#ccefd9}
.module-summary-card.badge-red .module-summary-icon{background:#fff0f1;color:#e0454f;border-color:#ffcfd3}
.module-summary-card.badge-amber .module-summary-icon{background:#fff8e7;color:#d47b05;border-color:#ffe1aa}
.module-summary-card.badge-blue .module-summary-icon{background:#edf4ff;color:#155eef;border-color:#cfddff}
.module-summary-card.badge-gray .module-summary-icon{background:#f1f4f8;color:#66758f;border-color:#dde4ed}

/* Bảng module: cùng kích thước, header, hover, pill, icon như Đơn hàng */
.module-table-panel{padding:0;border:1px solid #e2e8f1;border-radius:14px;overflow:hidden;box-shadow:var(--shadow-soft);background:#fff}
.module-page-shell .order-data-table{min-width:1080px;border-collapse:separate;border-spacing:0}
.module-page-shell .order-data-table th{height:56px;padding:0 16px;background:#fafbfd;color:#53637e;border-bottom:1px solid #e2e8f1;font-size:11px;font-weight:800;letter-spacing:.45px;text-transform:uppercase;white-space:nowrap}
.module-page-shell .order-data-table td{height:62px;padding:9px 16px;border-bottom:1px solid #edf1f6;font-size:13px;color:#24324b;background:#fff;vertical-align:middle}
.module-page-shell .order-data-table tbody tr:last-child td{border-bottom:0}
.module-page-shell .order-data-table tbody tr:hover td{background:#fbfdff}
.module-page-shell .order-data-table .order-code{color:#155eef;font-weight:800}
.module-page-shell .order-data-table td>strong{font-weight:750;color:#15213a}
.module-page-shell .order-data-table td>small,.module-page-shell .order-data-table strong+small{display:block;color:#8190a7;font-size:11px;margin-top:3px}
.module-page-shell .order-data-table .num.strong{font-size:14px;color:#13213e;font-weight:800}
.module-page-shell .orders-table-footer{min-height:50px;display:flex;align-items:center;justify-content:space-between;gap:15px;padding:0 18px;border-top:1px solid #e2e8f1;color:#71809a;font-size:12px;background:#fbfcfe}
.module-page-shell .orders-table-hint{color:#94a0b3}
.module-page-shell .order-more-btn{width:34px;height:34px;border:1px solid #dde5f0;background:#fff;color:#253654;border-radius:9px}
.module-page-shell .order-more-btn:hover{border-color:#b8c7dc;background:#f7faff}
.module-page-shell .order-more-btn svg{width:18px;height:18px}

/* Fix V1.0.9.1: icon Ngày/Giờ trong các module dùng bảng Đơn hàng
   Phải đặt kích thước SVG rõ ràng, nếu không browser dùng kích thước SVG mặc định rất lớn. */
.module-page-shell .order-date{display:flex;align-items:flex-start;gap:8px;white-space:nowrap;color:#52647f;line-height:1.25}
.module-page-shell .order-date>span:last-child{display:flex;flex-direction:column;min-width:0}
.module-page-shell .order-date-icon{display:flex;align-items:center;justify-content:center;width:17px;height:17px;flex:0 0 17px;margin-top:1px;color:#60769b}
.module-page-shell .order-date-icon svg{display:block;width:17px!important;height:17px!important;min-width:17px;min-height:17px;max-width:17px;max-height:17px}
.module-page-shell .order-date small{display:flex!important;align-items:center;gap:4px;margin-top:3px!important;font-size:11px!important;line-height:1.25;color:#8190a7}
.module-page-shell .clock-mini{display:flex;align-items:center;justify-content:center;width:13px;height:13px;flex:0 0 13px}
.module-page-shell .clock-mini svg{display:block;width:13px!important;height:13px!important;min-width:13px;min-height:13px;max-width:13px;max-height:13px}
.payment-page-shell .order-data-table td,.shipping-page-shell .order-data-table td{height:62px}

/* Premium status/carrier helpers ngoài tab Đơn hàng */
.module-page-shell .order-status-pill{position:relative;display:inline-flex;align-items:center;gap:6px;min-height:30px;padding:5px 9px;border-radius:8px;border:1px solid transparent;font-size:12px;font-weight:800;white-space:nowrap}
.module-page-shell .order-status-pill>span{display:flex}.module-page-shell .order-status-pill svg{width:15px;height:15px}
.module-page-shell .order-status-pill.badge-green{background:#ecfbf2;color:#16864a;border-color:#ccefd9}
.module-page-shell .order-status-pill.badge-blue{background:#edf4ff;color:#155eef;border-color:#cfddff}
.module-page-shell .order-status-pill.badge-amber{background:#fff8e7;color:#d47b05;border-color:#ffe1aa}
.module-page-shell .order-status-pill.badge-red{background:#fff0f1;color:#e0454f;border-color:#ffcfd3}
.module-page-shell .order-status-pill.badge-gray{background:#f1f4f8;color:#66758f;border-color:#dde4ed}
.module-page-shell .status-select-shell{position:relative;display:inline-flex;align-items:center;min-height:32px;min-width:132px;padding-left:30px;border-radius:8px;border:1px solid transparent;font-weight:700;white-space:nowrap}
.module-page-shell .status-select-shell.badge-green{background:#ecfbf2;color:#16864a;border-color:#ccefd9}.module-page-shell .status-select-shell.badge-blue{background:#edf4ff;color:#155eef;border-color:#cfddff}.module-page-shell .status-select-shell.badge-amber{background:#fff8e7;color:#d47b05;border-color:#ffe1aa}.module-page-shell .status-select-shell.badge-red{background:#fff0f1;color:#e0454f;border-color:#ffcfd3}.module-page-shell .status-select-shell.badge-gray{background:#f1f4f8;color:#66758f;border-color:#dde4ed}
.module-page-shell .status-select-icon{position:absolute;left:9px;display:flex;pointer-events:none}.module-page-shell .status-select-icon svg{width:16px;height:16px}
.module-page-shell .status-select-shell .order-inline-select{min-width:130px;height:30px;border:0!important;box-shadow:none!important;background:transparent!important;color:inherit!important;font-size:12px;font-weight:800;padding:0 28px 0 0;appearance:none;-webkit-appearance:none;cursor:pointer}
.module-page-shell .status-select-shell .status-select-chevron{position:absolute;right:7px;display:flex;pointer-events:none}.module-page-shell .status-select-shell .status-select-chevron svg{width:14px;height:14px}
.module-page-shell .carrier-select-shell,.module-page-shell .carrier-label{display:inline-flex;align-items:center;gap:8px;min-width:122px;position:relative}
.module-page-shell .carrier-select-shell{padding-right:18px}.module-page-shell .carrier-icon{width:28px;height:28px;border-radius:7px;display:inline-flex;align-items:center;justify-content:center;flex:0 0 28px;border:1px solid currentColor}.module-page-shell .carrier-icon svg{width:16px;height:16px}
.module-page-shell .carrier-orange{background:#fff6ea;color:#e67600}.module-page-shell .carrier-red{background:#fff0f1;color:#d93c48}.module-page-shell .carrier-green{background:#ecfbf2;color:#16864a}.module-page-shell .carrier-blue{background:#edf4ff;color:#155eef}
.module-page-shell .order-carrier-select{height:32px;min-width:100px;border:0!important;background:transparent!important;box-shadow:none!important;padding:0 22px 0 0;font-size:12px;font-weight:700;appearance:none;-webkit-appearance:none}.module-page-shell .carrier-select-shell .status-select-chevron{right:0;position:absolute;display:flex;pointer-events:none}.module-page-shell .carrier-select-shell .status-select-chevron svg{width:14px;height:14px}

/* Đối soát */
.module-bulk-toolbar{display:grid;grid-template-columns:minmax(220px,1fr) minmax(220px,280px) auto;align-items:center;gap:12px;padding:12px 16px;background:#f8faff;border-bottom:1px solid #e6ecf4}
.module-bulk-toolbar>div{display:flex;flex-direction:column;gap:2px}.module-bulk-toolbar strong{font-size:13px;color:#1d2c47}.module-bulk-toolbar small{font-size:11px;color:#7b899f}.module-bulk-toolbar .order-filter-control{height:42px}.module-bulk-toolbar .btn{min-height:42px}
.reconciliation-page-shell .reconcile-table{min-width:980px}.reconciliation-page-shell .reconcile-table .check-col{width:54px;text-align:center;padding-left:14px;padding-right:8px}

/* Cảnh báo */
.module-tabs-bar{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;padding:12px;background:#fff;border:1px solid #e2e8f1;border-radius:14px;box-shadow:var(--shadow-soft);margin-bottom:16px}
.module-tabs-bar a{min-height:58px;display:grid;grid-template-columns:32px 1fr auto;align-items:center;gap:9px;padding:8px 11px;border:1px solid #e4eaf2;border-radius:10px;color:#40516d;background:#fff;font-size:12px;font-weight:750}
.module-tabs-bar a:hover{background:#f8faff;border-color:#cfdaea}.module-tabs-bar a.active{border-color:#8eb0ff;background:#f4f8ff;box-shadow:0 0 0 3px rgba(21,94,239,.06);color:#17468f}
.module-tabs-bar a b{min-width:26px;height:24px;padding:0 7px;border-radius:99px;display:flex;align-items:center;justify-content:center;background:#eef3fa;color:#53637e;font-size:11px}
.tab-icon{width:32px;height:32px;border-radius:8px;display:flex;align-items:center;justify-content:center;background:#edf4ff;color:#155eef}.tab-icon svg{width:16px;height:16px}.tab-icon.warning{background:#fff8e7;color:#d47b05}.tab-icon.danger{background:#fff0f1;color:#e0454f}.tab-icon.muted{background:#f1f4f8;color:#66758f}
.module-info-strip{padding:10px 15px;background:#f8faff;border-bottom:1px solid #e7edf5;color:#6a7890;font-size:12px}
.alert-table-panel .severity{min-width:58px;justify-content:center;font-size:10px;letter-spacing:.35px}
.module-date-cell{display:flex;flex-direction:column;color:#35465f}.module-date-cell small{color:#8794a8;font-size:11px;margin-top:2px}.field-chip{display:inline-flex;padding:5px 8px;border:1px solid #dfe7f1;background:#f8faff;border-radius:7px;color:#586a84;font-size:11px;font-weight:700}

/* Khách hàng */
.customer-data-table{min-width:1000px!important}.customer-address{max-width:420px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.count-chip{display:inline-flex;min-width:32px;height:28px;align-items:center;justify-content:center;padding:0 9px;border-radius:8px;background:#edf4ff;color:#155eef;font-weight:800}.money-warning{color:#d84a54;font-weight:800}.customer-profile-strip{display:grid;grid-template-columns:1fr 2.3fr .7fr 1.1fr 1.1fr;gap:0;margin-bottom:16px;border:1px solid #e2e8f1;border-radius:14px;background:#fff;box-shadow:var(--shadow-soft);overflow:hidden}.customer-profile-strip>div{min-height:78px;padding:13px 16px;border-right:1px solid #edf1f6;display:flex;flex-direction:column;justify-content:center}.customer-profile-strip>div:last-child{border-right:0}.customer-profile-strip small{font-size:11px;color:#7b899f;margin-bottom:4px}.customer-profile-strip strong{font-size:14px;color:#17233b}.customer-profile-strip .customer-address-wide strong{font-weight:650}.text-danger{color:#d84a54!important}.module-section-head{padding:14px 16px 8px}.module-section-head h3{margin:0;font-size:15px}.module-section-head p{margin:3px 0 0;color:#8390a4;font-size:11px}

@media(max-width:1200px){.module-page-shell .module-summary-strip{grid-template-columns:repeat(2,minmax(0,1fr))}.module-tabs-bar{grid-template-columns:repeat(2,minmax(0,1fr))}.customer-profile-strip{grid-template-columns:repeat(2,minmax(0,1fr))}.customer-profile-strip>div{border-bottom:1px solid #edf1f6}.module-bulk-toolbar{grid-template-columns:1fr 240px}.module-bulk-toolbar>div{grid-column:1/-1}}
@media(max-width:900px){.module-page-shell .order-filter-bar{grid-template-columns:1fr 1fr}.module-page-shell .order-search-control{grid-column:1/-1}.customer-filter-bar{grid-template-columns:1fr!important}.module-tabs-bar{grid-template-columns:1fr 1fr}.module-page-shell .orders-table-hint{display:none}.module-bulk-toolbar{grid-template-columns:1fr}.customer-profile-strip{grid-template-columns:1fr}}
@media(max-width:600px){.module-page-shell .order-filter-bar{grid-template-columns:1fr;padding:12px}.module-page-shell .order-search-control{grid-column:auto}.module-page-shell .order-search-control,.module-page-shell .order-filter-control,.module-page-shell .order-reset-btn{height:46px}.module-summary-strip{grid-template-columns:1fr}.module-tabs-bar{grid-template-columns:1fr}.module-page-shell .page-head h1{font-size:25px}.module-page-shell .orders-table-footer{display:none}}

/* === V1.1 Large Data Architecture === */
.large-data-page .ajax-panel{position:relative;min-height:180px}
.ajax-hidden-form{display:none!important}
.ajax-loading{position:absolute;z-index:20;top:12px;right:14px;display:none;align-items:center;gap:8px;padding:7px 10px;border-radius:999px;background:rgba(20,34,62,.92);color:#fff;font-size:11px;font-weight:700;box-shadow:0 8px 24px rgba(15,35,70,.14)}
.ajax-loading.show{display:flex}.ajax-loading span{width:12px;height:12px;border:2px solid rgba(255,255,255,.35);border-top-color:#fff;border-radius:50%;animation:nnspin .7s linear infinite}@keyframes nnspin{to{transform:rotate(360deg)}}
.ajax-busy [data-ajax-results]{opacity:.58;pointer-events:none;transition:opacity .12s ease}.ajax-results-inner{min-width:0}
.server-pager{min-height:52px;display:flex;align-items:center;justify-content:space-between;gap:14px;padding:9px 16px;border-top:1px solid #e6ecf4;background:#fbfcfe;color:#6d7d96;font-size:12px}
.server-pager-summary{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.ajax-latency{color:#9aa7b9;font-size:10px}.server-pager-actions{display:flex;align-items:center;gap:8px}.server-pager-actions label{display:flex;align-items:center;gap:7px;white-space:nowrap}.server-pager-actions select{height:34px;min-width:70px;border:1px solid #dce4ef;border-radius:8px;background:#fff;padding:0 26px 0 10px;color:#33445f}.pager-btn{min-height:34px;padding:6px 11px}.pager-btn:disabled{opacity:.42;cursor:not-allowed}
.server-hint{padding:7px 16px 10px;background:#fbfcfe;border-top:0;color:#93a0b3;font-size:11px}
.inline-select.is-saving{opacity:.62;cursor:progress}.large-data-page .data-table tbody tr{content-visibility:auto;contain-intrinsic-size:62px}
@media(max-width:700px){.server-pager{align-items:flex-start;flex-direction:column}.server-pager-actions{width:100%;justify-content:space-between;flex-wrap:wrap}.server-pager-summary{width:100%}}

/* === V1.1.2 — QUICK PASTE ORDER === */
.quick-paste-panel{
  width:min(1500px,98%);max-width:1500px;margin:0 auto 10px;padding:12px 14px;
  border:1px solid #dbe5f2;border-radius:12px;background:linear-gradient(180deg,#fff,#fbfdff);
  box-shadow:0 5px 18px rgba(25,48,86,.045)
}
.quick-paste-head{display:flex;align-items:center;justify-content:space-between;gap:14px;margin-bottom:8px}
.quick-paste-head>div{min-width:0;display:flex;align-items:baseline;gap:10px;flex-wrap:wrap}
.quick-paste-head strong{font-size:13px;color:#172642;font-weight:850}
.quick-paste-head small{font-size:10.5px;color:#8290a6}
.quick-paste-badge{display:inline-flex;align-items:center;height:25px;padding:0 9px;border-radius:999px;background:#edf4ff;border:1px solid #cfe0ff;color:#155eef;font-size:9px;font-weight:900;letter-spacing:.45px;white-space:nowrap}
.quick-paste-panel textarea{display:block;width:100%;height:44px;min-height:44px;max-height:100px;padding:10px 12px;border:1px solid #cfdbea;border-radius:8px;background:#fff;color:#1c2c49;font-size:12px;line-height:1.4;resize:vertical;outline:0}
.quick-paste-panel textarea:focus{border-color:#7ea7ff;box-shadow:0 0 0 3px rgba(21,94,239,.07)}
.quick-paste-panel textarea:disabled{opacity:.7;cursor:progress}
.quick-paste-meta{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:7px}
.quick-paste-meta>span{min-width:0;color:#7a889e;font-size:9.5px;line-height:1.35;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.quick-paste-meta .btn{min-height:30px;height:30px;padding:0 10px;font-size:10.5px;white-space:nowrap}
.quick-paste-status{margin-top:5px;min-height:16px;color:#8b98ab;font-size:10px}
.quick-paste-status.is-busy{color:#155eef}.quick-paste-status.is-ok{color:#16864a}.quick-paste-status.is-error{color:#d33d49;font-weight:700}
@media(max-width:900px){.quick-paste-panel{width:100%}.quick-paste-meta{align-items:flex-start;flex-direction:column}.quick-paste-meta>span{white-space:normal}.quick-paste-meta .btn{align-self:flex-end}}
@media(max-width:600px){.quick-paste-head{align-items:flex-start}.quick-paste-head>div{display:block}.quick-paste-head small{display:block;margin-top:3px}.quick-paste-badge{display:none}.quick-paste-panel textarea{height:64px;min-height:64px}.quick-paste-meta .btn{width:100%}}

/* V1.1.3 Admin delete + Telegram diagnostics + global log */
.btn.danger{background:#fff0f1;border-color:#ffcfd3;color:#c63743}.btn.danger:hover{background:#ffe5e8;border-color:#ffb8bf}.btn.danger svg{width:16px;height:16px;margin-right:6px}.inline-delete-order{display:inline-flex;margin:0}.telegram-toggle-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px 16px}.telegram-actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.telegram-actions form{margin:0}.telegram-health{margin-top:12px;padding:10px 12px;border:1px solid var(--line);background:#f8faff;border-radius:9px;display:flex;gap:14px;flex-wrap:wrap;font-size:12px;color:var(--muted)}.telegram-health small{width:100%;color:#b13a43}.audit-order-link{font-weight:800;color:#155eef}.audit-event-pill{display:inline-flex;padding:4px 7px;border-radius:7px;background:#f1f5ff;color:#3457a6;font-weight:700;font-size:11px}.audit-deleted{color:#c63743}.audit-value{max-width:320px;white-space:normal;word-break:break-word}.audit-meta{font-size:11px;color:var(--muted)}@media(max-width:700px){.telegram-toggle-grid{grid-template-columns:1fr}}

.admin-danger-zone{display:flex;justify-content:space-between;align-items:center;gap:18px;border-color:#ffd3d7;background:#fffafa}.admin-danger-zone div{display:flex;flex-direction:column;gap:3px}.admin-danger-zone small{color:var(--muted)}.admin-danger-zone form{margin:0}@media(max-width:700px){.admin-danger-zone{align-items:stretch;flex-direction:column}.admin-danger-zone .btn{width:100%}}

/* === V1.1.4 — DUPLICATE ORDER WARNING === */
body.modal-open{overflow:hidden}
.duplicate-warning-panel{margin:0 0 18px;padding:16px;border:1px solid #fecaca;background:#fff7f7;border-radius:12px;box-shadow:0 10px 28px rgba(127,29,29,.06)}
.duplicate-warning-title{display:flex;gap:12px;align-items:flex-start}.duplicate-warning-title strong{display:block;font-size:17px;color:#991b1b}.duplicate-warning-title small{display:block;margin-top:3px;color:#7f1d1d}
.duplicate-warning-icon{width:34px;height:34px;border-radius:10px;background:#fee2e2;color:#dc2626;display:grid;place-items:center;flex:none}.duplicate-warning-icon svg{width:18px;height:18px}
.duplicate-warning-list{display:grid;gap:8px;margin-top:12px}.duplicate-warning-item{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:12px;align-items:center;padding:10px 12px;background:#fff;border:1px solid #fee2e2;border-radius:10px}.duplicate-warning-item strong{display:block;color:#172554}.duplicate-warning-item small{display:block;margin-top:2px;color:#64748b}.duplicate-reasons{display:flex;gap:6px;flex-wrap:wrap;justify-content:flex-end}.duplicate-reason{display:inline-flex;align-items:center;min-height:24px;padding:2px 8px;border-radius:999px;background:#fff1f2;border:1px solid #fecdd3;color:#be123c;font-size:11px;font-weight:800;white-space:nowrap}.duplicate-warning-actions{display:flex;gap:8px;justify-content:flex-end;margin-top:14px}.duplicate-note{display:block;margin-top:8px;color:#94a3b8;text-align:right}
.duplicate-modal-backdrop{position:fixed;inset:0;z-index:9999;background:rgba(15,23,42,.46);backdrop-filter:blur(2px);display:grid;place-items:center;padding:18px}.duplicate-modal{width:min(720px,96vw);max-height:min(760px,90vh);overflow:auto;background:#fff;border-radius:16px;border:1px solid #e2e8f0;box-shadow:0 28px 80px rgba(15,23,42,.24);padding:18px}.duplicate-modal-head{display:flex;gap:12px;align-items:flex-start;padding-bottom:14px;border-bottom:1px solid #eef2f7}.duplicate-modal-head strong{display:block;font-size:20px;color:#0f172a}.duplicate-modal-head small{display:block;margin-top:4px;line-height:1.45;color:#64748b}.duplicate-modal-icon{width:38px;height:38px;border-radius:11px;display:grid;place-items:center;background:#fee2e2;color:#dc2626;font-size:21px;font-weight:900;flex:none}.duplicate-modal-list{display:grid;gap:10px;margin:14px 0}.duplicate-modal-group{border:1px solid #e2e8f0;border-radius:12px;overflow:hidden;background:#f8fafc}.duplicate-modal-customer{padding:10px 12px;background:#fff;border-bottom:1px solid #e2e8f0}.duplicate-modal-customer strong,.duplicate-modal-customer small{display:block}.duplicate-modal-customer strong{color:#0f172a}.duplicate-modal-customer small{margin-top:2px;color:#64748b}.duplicate-modal-match{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:10px;align-items:center;padding:9px 12px;border-top:1px solid #edf2f7}.duplicate-modal-match:first-of-type{border-top:0}.duplicate-modal-match a,.duplicate-modal-match strong{display:block;font-weight:800;color:#1d4ed8;text-decoration:none}.duplicate-modal-match small{display:block;margin-top:2px;color:#64748b}.duplicate-modal-actions{display:flex;justify-content:flex-end;gap:9px;padding-top:14px;border-top:1px solid #eef2f7}
@media(max-width:720px){.duplicate-warning-item,.duplicate-modal-match{grid-template-columns:1fr}.duplicate-reasons{justify-content:flex-start}.duplicate-warning-actions,.duplicate-modal-actions{flex-direction:column-reverse}.duplicate-warning-actions .btn,.duplicate-modal-actions .btn{width:100%}.duplicate-note{text-align:left}}


/* V1.1.4.3 - Google Drive image preview + thumbnail column */
th.image-col,td.image-col{width:86px;min-width:86px;text-align:center}.order-thumb-link{display:inline-flex;align-items:center;justify-content:center}.order-thumb-shell{position:relative;display:inline-flex}.order-thumb{width:54px;height:54px;object-fit:cover;border-radius:12px;border:1px solid #d9dfeb;background:#f3f5fa;box-shadow:0 6px 18px rgba(31,45,82,.08)}.order-thumb.mobile .order-thumb,.order-thumb-link.mobile .order-thumb{width:52px;height:52px}.order-thumb.placeholder{display:inline-flex;align-items:center;justify-content:center;width:54px;height:54px;border-radius:12px;border:1px dashed #cfd6e4;color:#8a94aa;background:#f8f9fc}.order-thumb.placeholder svg{width:22px;height:22px}.order-thumb-badge{position:absolute;right:-5px;bottom:-5px;background:#1f2d52;color:#fff;border-radius:999px;padding:2px 6px;font-size:10px;font-weight:700;line-height:1.2;border:2px solid #fff}.mobile-order-top-has-thumb{gap:12px;align-items:center}.mobile-order-thumb-wrap{flex:0 0 auto}.mobile-order-main{min-width:0}.source-image-field-wrap>label{display:block}.source-image-inline-preview{margin-top:8px}.source-image-card{display:flex;align-items:center;gap:12px;padding:10px;border:1px solid #e1e7f0;border-radius:12px;background:#fafbfe}.source-image-card img{width:88px;height:88px;object-fit:cover;border-radius:10px;border:1px solid #d9dfeb;background:#f1f3f8;display:block}.source-image-meta{display:flex;flex-direction:column;gap:5px;font-size:12px}.source-image-meta strong{font-size:13px}.source-image-empty{padding:12px;border:1px dashed #d2d9e6;border-radius:12px;color:#7b859c;background:#fafbfe;font-size:12px}.external-source-image{border-style:dashed}.image-preview-modal{position:fixed;inset:0;background:rgba(15,23,42,.72);display:flex;align-items:center;justify-content:center;padding:24px;z-index:120}.image-preview-dialog{position:relative;max-width:min(92vw,1100px);max-height:92vh;background:#fff;border-radius:16px;padding:16px;box-shadow:0 24px 60px rgba(0,0,0,.28)}.image-preview-dialog img{max-width:min(88vw,1020px);max-height:76vh;width:auto;height:auto;display:block;border-radius:12px;background:#f4f6fb}.image-preview-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}.image-preview-head strong{font-size:14px}.image-preview-close{border:0;background:#eef2f8;color:#24304b;width:36px;height:36px;border-radius:10px;font-size:20px;cursor:pointer}.image-preview-actions{display:flex;justify-content:flex-end;margin-top:12px}.source-image-link{display:block}.gallery .source-image-card{grid-column:1/-1}@media(max-width:900px){th.image-col,td.image-col{width:74px;min-width:74px}.source-image-card img{width:72px;height:72px}.image-preview-dialog{padding:12px;border-radius:14px}}@media(max-width:600px){.source-image-card{padding:9px;gap:10px}.source-image-card img{width:64px;height:64px}.image-preview-modal{padding:12px}.image-preview-dialog{max-width:100%;width:100%}.image-preview-dialog img{max-width:100%;max-height:68vh}}

/* V1.1.4.4 - Drive large preview reliability */
.image-preview-stage{display:flex;align-items:center;justify-content:center;min-width:280px;min-height:180px}.image-preview-error{max-width:520px;padding:24px;text-align:center;color:#6d7690;background:#f7f8fc;border:1px dashed #cfd6e5;border-radius:12px}.image-preview-stage img[hidden]{display:none!important}

/* V1.1.4.5 - Mobile quick edit trạng thái */
.mobile-quick-field{min-width:0}.mobile-quick-field>span{display:block;font-size:10px;color:var(--muted);margin-bottom:4px}.mobile-quick-value{position:relative;display:flex;width:100%;min-height:42px;align-items:center;gap:7px;padding:8px 30px 8px 10px;border:1px solid #dce4ef;border-radius:10px;background:#fff;color:#24324b;font-size:12px;font-weight:750;text-align:left;cursor:pointer}.mobile-quick-value>svg{width:16px;height:16px;flex:0 0 16px}.mobile-quick-value>span[data-mobile-quick-label],.mobile-quick-value.is-readonly>span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mobile-quick-value.badge-green{background:#ecfbf2;color:#16864a;border-color:#ccefd9}.mobile-quick-value.badge-blue{background:#edf4ff;color:#155eef;border-color:#cfddff}.mobile-quick-value.badge-amber{background:#fff8e7;color:#d47b05;border-color:#ffe1aa}.mobile-quick-value.badge-red{background:#fff0f1;color:#e0454f;border-color:#ffcfd3}.mobile-quick-value.badge-gray{background:#f1f4f8;color:#66758f;border-color:#dde4ed}.mobile-quick-value.is-readonly{cursor:default}.mobile-quick-chevron{position:absolute;right:8px;top:50%;transform:translateY(-50%);display:flex}.mobile-quick-chevron svg{width:14px;height:14px}.mobile-carrier-value{background:#f8fafc}.mobile-status-grid{gap:10px}.mobile-quick-sheet-backdrop{position:fixed;inset:0;z-index:180;background:rgba(15,23,42,.48);display:flex;align-items:flex-end;justify-content:center}.mobile-quick-sheet{width:min(100%,620px);background:#fff;border-radius:18px 18px 0 0;padding:14px 14px max(18px,env(safe-area-inset-bottom));box-shadow:0 -18px 48px rgba(15,23,42,.2);animation:mobileSheetUp .18s ease-out}.mobile-quick-sheet-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding:3px 2px 12px;border-bottom:1px solid #edf1f6}.mobile-quick-sheet-head>div{display:flex;flex-direction:column;gap:3px}.mobile-quick-sheet-head strong{font-size:16px;color:#17233b}.mobile-quick-sheet-head small{font-size:11px;color:#7b879d}.mobile-quick-sheet-close{border:0;background:#f0f3f8;width:36px;height:36px;border-radius:10px;font-size:22px;color:#33415c;cursor:pointer}.mobile-quick-sheet-options{display:flex;flex-direction:column;gap:8px;padding-top:12px}.mobile-quick-option{min-height:48px;display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;border:1px solid #dde5ef;background:#fff;border-radius:11px;padding:10px 13px;text-align:left;color:#24324b;font-weight:700;cursor:pointer}.mobile-quick-option.active{border-color:#9fb9f3;background:#f2f6ff;color:#155eef}.mobile-quick-option b{font-size:16px}.mobile-quick-sheet.is-saving{opacity:.62;pointer-events:none}.mobile-sheet-open{overflow:hidden}@keyframes mobileSheetUp{from{transform:translateY(18px);opacity:.6}to{transform:none;opacity:1}}
@media(min-width:701px){.mobile-quick-sheet-backdrop{align-items:center}.mobile-quick-sheet{border-radius:16px;max-height:80vh;overflow:auto;padding-bottom:14px}}
.mobile-quick-dot{width:8px;height:8px;border-radius:999px;flex:0 0 8px;background:currentColor;box-shadow:0 0 0 3px rgba(255,255,255,.7)}


/* V1.1.4.6 - Mobile native quick edit + compact card */
.mobile-order-card-compact{padding:11px 12px}.mobile-order-summary{display:grid;grid-template-columns:48px minmax(0,1fr);gap:10px;align-items:center}.mobile-order-summary .mobile-order-thumb-wrap{width:48px}.mobile-order-summary .order-thumb,.mobile-order-summary .order-thumb.placeholder{width:48px;height:48px;border-radius:10px}.mobile-order-summary-main{min-width:0}.mobile-order-line{display:flex;align-items:center;justify-content:space-between;gap:8px;min-width:0}.mobile-order-line+.mobile-order-line{margin-top:3px}.mobile-order-line .order-code{font-size:12px;overflow:hidden;text-overflow:ellipsis}.mobile-order-line>small{font-size:10px;color:#8995a8;white-space:nowrap}.mobile-order-line>strong{font-size:13px;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mobile-order-line>b{font-size:13px;white-space:nowrap;color:#142a50}.mobile-order-phone{display:block;margin-top:2px;font-size:10px;color:#8a96aa}.mobile-compact-status-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;margin-top:9px}.mobile-quick-field{min-width:0}.mobile-quick-field>span{margin:0 0 3px 2px;font-size:9px;line-height:1;color:#8390a5}.mobile-native-select{display:block!important;width:100%!important;min-width:0!important;height:36px!important;min-height:36px!important;margin:0!important;padding:5px 26px 5px 9px!important;border:1px solid #dce4ef!important;border-radius:9px!important;font-size:11px!important;font-weight:750!important;line-height:1.2!important;box-shadow:none!important;cursor:pointer;-webkit-tap-highlight-color:transparent;touch-action:manipulation}.mobile-native-select.badge-green{background:#ecfbf2!important;color:#16864a!important;border-color:#ccefd9!important}.mobile-native-select.badge-blue{background:#edf4ff!important;color:#155eef!important;border-color:#cfddff!important}.mobile-native-select.badge-amber{background:#fff8e7!important;color:#b86b04!important;border-color:#ffe1aa!important}.mobile-native-select.badge-red{background:#fff0f1!important;color:#cf3440!important;border-color:#ffcfd3!important}.mobile-native-select.badge-gray{background:#f1f4f8!important;color:#66758f!important;border-color:#dde4ed!important}.mobile-native-carrier-select{background:#f7f9fc!important;color:#33415c!important}.mobile-native-readonly{display:flex;width:100%;height:36px;align-items:center;gap:6px;padding:5px 9px;border:1px solid #dde4ed;border-radius:9px;background:#f5f7fa;color:#66758f;font-size:11px;font-weight:750;overflow:hidden}.mobile-native-readonly>span:last-child{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mobile-native-readonly.badge-green{background:#ecfbf2;color:#16864a;border-color:#ccefd9}.mobile-native-readonly.badge-blue{background:#edf4ff;color:#155eef;border-color:#cfddff}.mobile-native-readonly.badge-amber{background:#fff8e7;color:#b86b04;border-color:#ffe1aa}.mobile-native-readonly.badge-red{background:#fff0f1;color:#cf3440;border-color:#ffcfd3}.mobile-native-truck{display:flex;flex:0 0 14px}.mobile-native-truck svg{width:14px;height:14px}.mobile-order-foot-compact{margin-top:8px;padding-top:7px}.mobile-order-foot-compact a{font-weight:700}@media(max-width:360px){.mobile-order-card-compact{padding:10px}.mobile-order-summary{grid-template-columns:44px minmax(0,1fr);gap:8px}.mobile-order-summary .mobile-order-thumb-wrap,.mobile-order-summary .order-thumb,.mobile-order-summary .order-thumb.placeholder{width:44px;height:44px}.mobile-native-select,.mobile-native-readonly{font-size:10.5px}.mobile-order-line>b{font-size:12px}}

.mobile-order-summary .order-thumb-link.mobile .order-thumb{width:48px!important;height:48px!important}.mobile-native-select.is-saving{opacity:.6;pointer-events:none}@media(max-width:360px){.mobile-order-summary .order-thumb-link.mobile .order-thumb{width:44px!important;height:44px!important}}


/* V1.1.4.12 - Paste fills form + multi-image chooser */
.quick-paste-badge{white-space:nowrap}.paste-filled-highlight{border-radius:8px;animation:pasteFilledPulse 1.5s ease}@keyframes pasteFilledPulse{0%,100%{background:transparent}25%{background:#eaf2ff}}.multi-image-upload{display:block!important}.multi-image-upload .compact-upload-title small{font-weight:500;color:var(--muted);margin-left:6px}.multi-image-preview{display:flex;gap:10px;flex-wrap:wrap;margin-top:10px}.multi-image-preview:empty{display:none}.multi-image-item{position:relative;width:88px;border:1px solid var(--line);border-radius:10px;background:#fff;padding:5px;box-shadow:0 4px 14px rgba(31,45,82,.06)}.multi-image-item img{width:76px;height:62px;display:block;object-fit:cover;border-radius:7px;background:#f0f2f6}.multi-image-name{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:10px;color:var(--muted);margin-top:4px}.multi-image-remove{position:absolute;right:-7px;top:-7px;width:23px;height:23px;border:2px solid #fff;border-radius:50%;background:#d94a53;color:#fff;line-height:17px;cursor:pointer;font-weight:800;padding:0}.upload-box.is-dragover{border-color:var(--brand);background:#eef4ff}.quick-paste-status.is-ok{color:#24734b}.quick-paste-status.is-error{color:#a52d37}.quick-paste-status.is-busy{color:var(--brand)}@media(max-width:600px){.quick-paste-meta{align-items:stretch}.quick-paste-meta .btn{width:100%;margin-top:6px}.multi-image-item{width:78px}.multi-image-item img{width:66px;height:58px}}

/* V1.1.4.13 - multiple Google Drive / external image links */
.external-images-editor{display:flex;flex-direction:column;gap:10px}.external-images-head{display:flex;align-items:center;justify-content:space-between;gap:10px}.external-images-head>div{display:flex;flex-direction:column;gap:2px}.external-images-head strong{font-size:12px;color:#5d667c}.external-images-head small,.external-images-note{font-size:11px;color:var(--muted)}.external-images-list{display:flex;flex-direction:column;gap:10px}.external-image-row{padding:9px;border:1px solid #e1e7f0;border-radius:12px;background:#fafbfe}.external-image-input-line{display:flex;gap:8px;align-items:center}.external-image-input-line input{flex:1;min-width:0}.external-image-remove{flex:0 0 34px;width:34px;height:34px;border:1px solid #f0c8cd;background:#fff5f6;color:#aa3440;border-radius:9px;cursor:pointer;font-size:19px;line-height:1}.external-image-preview{margin-top:8px}.external-image-preview .source-image-card{padding:8px;background:#fff}.external-image-preview .source-image-card img{width:64px;height:64px}.image-preview-stage{position:relative;display:flex;align-items:center;justify-content:center;min-height:180px}.image-preview-nav{position:absolute;top:50%;transform:translateY(-50%);z-index:2;width:42px;height:42px;border:0;border-radius:999px;background:rgba(255,255,255,.9);box-shadow:0 6px 22px rgba(15,23,42,.18);font-size:30px;cursor:pointer;color:#26334e}.image-preview-nav.prev{left:10px}.image-preview-nav.next{right:10px}.image-preview-footer{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:12px}.image-preview-count{font-size:12px;color:var(--muted)}
@media(max-width:600px){.external-images-head{align-items:flex-start}.external-images-head .btn{padding:7px 9px}.external-image-row{padding:7px}.external-image-preview .source-image-card img{width:56px;height:56px}.image-preview-nav{width:36px;height:36px;font-size:26px}.image-preview-nav.prev{left:4px}.image-preview-nav.next{right:4px}}

/* V1.1.4.14 - Orders activity time filter (created/edited today or custom range) */
.page-orders .order-filter-bar{grid-template-columns:minmax(260px,1.45fr) repeat(5,minmax(150px,.78fr)) auto}
.page-orders .order-time-control select{font-weight:700}
.page-orders .order-custom-range[hidden]{display:none!important}
.page-orders .order-custom-range{grid-column:1/-1;display:grid;grid-template-columns:auto minmax(160px,220px) auto minmax(160px,220px) minmax(240px,1fr);gap:10px;align-items:end;padding:10px 12px;border:1px solid #dfe7f2;border-radius:11px;background:#f8faff}
.page-orders .order-custom-range-title{display:flex;align-items:center;gap:7px;min-height:40px;color:#263858;white-space:nowrap}
.page-orders .order-custom-range-title svg{width:17px;height:17px;color:#155eef}
.page-orders .order-custom-range-title b{font-size:12px}
.page-orders .order-custom-range label{display:flex;flex-direction:column;gap:4px;margin:0}
.page-orders .order-custom-range label>span{font-size:10px;font-weight:700;color:#75839a}
.page-orders .order-custom-range input[type=date]{width:100%;min-width:0;height:40px;min-height:40px;border:1px solid #d7e0ec;border-radius:9px;background:#fff;padding:0 10px;color:#24324a;font-weight:650;box-shadow:none}
.page-orders .order-custom-range input[type=date]:focus{outline:none;border-color:#7aa3ff;box-shadow:0 0 0 3px rgba(21,94,239,.08)}
.page-orders .order-custom-range-sep{align-self:center;padding-top:15px;color:#8491a5;font-weight:800}
.page-orders .order-custom-range small{align-self:center;color:#748198;font-size:11px;line-height:1.45}
@media(max-width:1500px){.page-orders .order-filter-bar{grid-template-columns:minmax(250px,1.35fr) repeat(3,minmax(165px,1fr))}.page-orders .order-reset-btn{width:100%}}
@media(max-width:900px){.page-orders .order-filter-bar{grid-template-columns:1fr 1fr}.page-orders .order-search-control{grid-column:1/-1}.page-orders .order-custom-range{grid-template-columns:1fr 1fr;align-items:end}.page-orders .order-custom-range-title,.page-orders .order-custom-range small{grid-column:1/-1}.page-orders .order-custom-range-sep{display:none}}
@media(max-width:600px){.page-orders .order-filter-bar{grid-template-columns:1fr;padding:12px}.page-orders .order-search-control{grid-column:auto}.page-orders .order-custom-range{grid-template-columns:1fr;padding:10px}.page-orders .order-custom-range-title,.page-orders .order-custom-range small{grid-column:auto}.page-orders .order-custom-range label>span{font-size:10px}.page-orders .order-custom-range input[type=date]{height:42px;min-height:42px}}

/* ================================================================
   V1.1.5.0 — A.Nhật shipper settlement module
   ================================================================ */
.page-anh_nhat .content,.page-anh_thang .content{max-width:1680px}
.an-page{--an-purple:#4f46e5;--an-purple-soft:#eef0ff;--an-red:#e0444e;--an-green:#15935e;--an-amber:#d48707}
.an-topline{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:-6px 0 14px}
.an-carrier-chip{display:inline-flex;align-items:center;gap:8px;min-height:38px;padding:0 11px;border:1px solid #dfe5ef;border-radius:10px;background:#fff;color:#586983;font-size:12px}
.an-carrier-chip svg{width:16px;height:16px;color:#4f46e5}.an-carrier-chip b{color:#1c2b47}
.an-carrier-change{position:relative;font-size:12px;color:#64738c}.an-carrier-change summary{cursor:pointer;font-weight:700;color:#51627c}.an-carrier-change form{position:absolute;right:0;top:28px;z-index:20;width:320px;padding:12px;background:#fff;border:1px solid #dfe5ef;border-radius:12px;box-shadow:0 12px 30px rgba(31,45,82,.12);display:grid;grid-template-columns:1fr auto;gap:8px}
.an-setup{width:100%;margin:0}.an-setup p{color:var(--muted)}.an-setup-form{display:flex;gap:8px;max-width:620px}.an-setup-form select{flex:1}
.an-tabs{display:flex;align-items:center;gap:4px;margin-bottom:18px;border-bottom:1px solid #e4e9f2}
.an-tabs a{position:relative;padding:11px 15px 12px;color:#6d7b91;font-size:13px;font-weight:750}
.an-tabs a:hover{color:#2b3d5d}.an-tabs a.active{color:#4338ca}.an-tabs a.active:after{content:"";position:absolute;left:10px;right:10px;bottom:-1px;height:2px;border-radius:3px 3px 0 0;background:#4f46e5}
.an-kpi-grid,.an-create-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin-bottom:16px}
.an-kpi{display:flex;align-items:center;gap:12px;min-height:96px;padding:14px;border:1px solid #e0e6f0;border-radius:14px;background:#fff;box-shadow:var(--shadow-soft);color:inherit;transition:.15s}
.an-kpi[href]:hover{transform:translateY(-1px);border-color:#c7d3e5;box-shadow:0 9px 24px rgba(30,52,91,.08)}
.an-kpi-icon{width:38px;height:38px;border-radius:10px;display:flex;align-items:center;justify-content:center;flex:0 0 38px;background:#edf4ff;color:#155eef}.an-kpi-icon svg{width:18px;height:18px}
.an-kpi>span:last-child{display:flex;flex-direction:column;min-width:0}.an-kpi small{font-size:11px;color:#7b899f;font-weight:650}.an-kpi strong{font-size:20px;line-height:1.25;margin:4px 0 2px;color:#14213d;letter-spacing:-.35px}.an-kpi em{font-size:10px;color:#94a0b3;font-style:normal;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.an-kpi-red .an-kpi-icon{background:#fff0f1;color:#d9424d}.an-kpi-red strong{color:#d63d48}.an-kpi-green .an-kpi-icon{background:#eafaf2;color:#15935e}.an-kpi-green strong{color:#138653}.an-kpi-amber .an-kpi-icon{background:#fff7e8;color:#d48707}.an-kpi-blue .an-kpi-icon{background:#eef1ff;color:#4f46e5}
.an-info-strip{display:flex;justify-content:space-between;gap:14px;align-items:center;margin-bottom:16px;padding:11px 13px;border:1px solid #dce4ef;border-left:3px solid #6b73e8;border-radius:10px;background:#fbfcff;color:#687790;font-size:11px}.an-info-strip span{display:flex;align-items:center;gap:6px}.an-info-strip svg{width:15px;height:15px;color:#4f46e5}.an-info-strip b{color:#35425a}
.an-overview-grid{display:grid;grid-template-columns:1.2fr .8fr;gap:16px}.an-panel-head p{margin:4px 0 0;font-size:11px;color:#8490a4}.an-panel-head>a{font-size:12px;font-weight:750}
.an-aging-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:10px}.an-aging{display:flex;flex-direction:column;padding:13px;border:1px solid #e3e8f1;border-radius:11px;background:#fbfcff;color:#24324b}.an-aging span{font-size:11px;color:#78869c}.an-aging strong{font-size:16px;margin:5px 0 2px}.an-aging small{font-size:10px;color:#98a3b5}.an-aging-green{border-left:3px solid #22a66f}.an-aging-blue{border-left:3px solid #4f6fe7}.an-aging-amber{border-left:3px solid #e3a11f}.an-aging-red{border-left:3px solid #e0444e}.an-aging-red strong{color:#d63d48}
.an-last-settlement{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:12px;margin-top:12px;padding-top:12px;border-top:1px solid #edf0f5;font-size:11px;color:#77869c}.an-last-settlement b{color:#23324d}.an-last-settlement a{font-weight:750}
.an-tasks{display:flex;flex-direction:column}.an-tasks>a{display:grid;grid-template-columns:10px 1fr auto;gap:10px;align-items:center;padding:11px 4px;border-bottom:1px solid #edf0f5;color:#24324b}.an-tasks>a:last-child{border-bottom:0}.an-tasks span:nth-child(2){display:flex;flex-direction:column}.an-tasks b{font-size:14px}.an-tasks small{font-size:10px;color:#8794a8;margin-top:2px}.an-task-dot{width:8px;height:8px;border-radius:50%}.an-task-dot.red{background:#e0444e}.an-task-dot.amber{background:#e3a11f}.an-task-dot.blue{background:#4f6fe7}
.an-table{min-width:1030px}.an-table th{font-size:10px}.an-table td{padding-top:10px;padding-bottom:10px}.an-table .an-check{width:34px;text-align:center}.an-table .an-check input{width:16px;height:16px;min-height:0}.an-table .an-outstanding{color:#d63d48;font-weight:800}
.an-badge{display:inline-flex;align-items:center;min-height:25px;padding:0 8px;border-radius:999px;font-size:10px;font-weight:800;white-space:nowrap}.an-badge-red{background:#fff0f1;color:#cf3945}.an-badge-green{background:#eafaf2;color:#138653}.an-badge-amber{background:#fff7e8;color:#bc7607}.an-badge-gray{background:#f0f3f7;color:#68768c}.an-badge-blue{background:#edf3ff;color:#315fb9}
.an-filter{display:grid;grid-template-columns:minmax(320px,1fr) minmax(180px,240px) auto auto;align-items:center}.an-filter input,.an-filter select{width:100%!important;min-width:0!important}.an-search{position:relative;display:block}.an-search svg{position:absolute;left:11px;top:50%;transform:translateY(-50%);width:17px;height:17px;color:#8794a8;z-index:1}.an-search input{padding-left:37px}.an-list-meta{display:flex;justify-content:space-between;gap:12px;align-items:center;margin:0 2px 10px;color:#7f8ca1;font-size:11px}.an-list-meta b{color:#293953}
.an-select-form{position:relative}.an-bulk-bar{position:sticky;bottom:12px;z-index:15;display:flex;align-items:center;justify-content:space-between;gap:12px;margin:12px auto 0;max-width:760px;padding:10px 12px;border:1px solid #ced9ea;border-radius:12px;background:rgba(255,255,255,.96);backdrop-filter:blur(8px);box-shadow:0 10px 28px rgba(30,52,91,.13)}.an-bulk-bar span{font-size:12px;color:#66758d}.an-bulk-bar strong{color:#d63d48}.an-bulk-bar .btn svg{width:16px;height:16px;margin-right:6px}.an-bulk-bar .btn:disabled{opacity:.45;cursor:not-allowed;transform:none}
.an-pager{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:12px;color:#7c899e;font-size:11px}.an-pager>div{display:flex;gap:7px}
.an-create-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:15px}.an-create-head>a,.an-create-head>div>a{font-size:11px;font-weight:750}.an-create-head h2{font-size:22px;margin:7px 0 3px;color:#17233c}.an-create-head p{margin:0;color:#7a879c;font-size:12px}
.an-settlement-form .panel{margin-bottom:14px}.an-form-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:13px}.an-form-grid label{display:flex;flex-direction:column;gap:5px;font-size:11px;font-weight:700;color:#5f6f88}.an-form-grid label small{font-size:10px;font-weight:500;color:#95a0b2}.an-form-wide{grid-column:1/-1}.an-form-actions{display:flex;justify-content:flex-end;gap:9px;margin-top:2px}.an-empty-action{text-align:center;padding:34px}.an-empty-action p{color:#7d899b}.an-empty-action .btn{margin-top:8px}
.an-detail-grid{display:grid;grid-template-columns:1.2fr .8fr;gap:16px}.an-detail-list{margin:10px 0 0}.an-detail-list>div{display:grid;grid-template-columns:130px 1fr;gap:12px;padding:9px 0;border-bottom:1px solid #edf0f5}.an-detail-list>div:last-child{border-bottom:0}.an-detail-list dt{font-size:11px;color:#7f8ba0}.an-detail-list dd{margin:0;font-size:12px;font-weight:650;color:#263651}.an-detail-list .btn svg{width:15px;height:15px;margin-right:5px}.an-danger-panel{border-color:#ffd3d7;background:#fffafa}.an-danger-panel p{font-size:11px;color:#8c6d72}.an-danger-panel form{display:flex;flex-direction:column;gap:9px}.an-danger-panel .btn{align-self:flex-start}
.an-mobile-list{display:none}
@media(max-width:1150px){.an-kpi-grid,.an-create-summary{grid-template-columns:repeat(2,minmax(0,1fr))}.an-overview-grid,.an-detail-grid{grid-template-columns:1fr}.an-filter{grid-template-columns:1fr 1fr auto auto}.an-form-grid{grid-template-columns:1fr 1fr}}
@media(max-width:760px){.page-anh_nhat .content,.page-anh_thang .content{padding:12px}.an-topline{align-items:stretch;flex-direction:column}.an-carrier-chip{width:100%}.an-carrier-change form{position:static;width:100%;margin-top:8px}.an-tabs{overflow-x:auto;white-space:nowrap;margin-left:-12px;margin-right:-12px;padding:0 8px}.an-tabs a{padding-left:12px;padding-right:12px}.an-kpi-grid,.an-create-summary{grid-template-columns:1fr 1fr;gap:8px}.an-kpi{min-height:84px;padding:10px;gap:9px}.an-kpi-icon{width:32px;height:32px;flex-basis:32px}.an-kpi strong{font-size:16px}.an-kpi em{font-size:9px}.an-info-strip{align-items:flex-start;flex-direction:column}.an-aging-grid{grid-template-columns:1fr}.an-last-settlement{grid-template-columns:1fr}.an-filter{grid-template-columns:1fr}.an-filter .btn{width:100%}.an-list-meta{align-items:flex-start;flex-direction:column}.an-table-desktop{display:none}.an-mobile-list{display:flex;flex-direction:column;gap:9px}.an-mobile-card{padding:11px;border:1px solid #e2e7f0;border-radius:12px;background:#fff;box-shadow:var(--shadow-soft)}.an-mobile-head{display:flex;align-items:flex-start;gap:9px;justify-content:space-between}.an-mobile-head>input{width:19px;height:19px;min-height:0;flex:0 0 19px;margin-top:2px}.an-mobile-head>div{display:flex;flex:1;min-width:0;flex-direction:column;gap:3px}.an-mobile-head strong{font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.an-mobile-money{display:grid;grid-template-columns:repeat(3,1fr);gap:7px;margin:10px 0}.an-mobile-money span{display:flex;flex-direction:column;gap:3px;padding:7px;border-radius:8px;background:#f8faff;font-size:9px;color:#8290a5}.an-mobile-money b{font-size:11px;color:#273651;white-space:nowrap}.an-mobile-money .an-outstanding{color:#d63d48}.an-mobile-foot{display:flex;align-items:center;justify-content:space-between;padding-top:8px;border-top:1px solid #edf0f5;font-size:10px;color:#8490a3}.an-mobile-foot a{font-weight:750}.an-bulk-bar{bottom:8px;flex-direction:column;align-items:stretch;margin-top:10px}.an-bulk-bar .btn{width:100%}.an-pager{align-items:stretch;flex-direction:column}.an-pager>div .btn{flex:1}.an-create-head{flex-direction:column}.an-form-grid{grid-template-columns:1fr}.an-form-wide{grid-column:auto}.an-form-actions{flex-direction:column-reverse}.an-form-actions .btn{width:100%}.an-detail-list>div{grid-template-columns:1fr}.an-setup-form{flex-direction:column}.an-setup-form .btn{width:100%}}
@media(max-width:430px){.an-kpi-grid,.an-create-summary{grid-template-columns:1fr 1fr}.an-kpi{align-items:flex-start;flex-direction:column}.an-kpi-icon{display:none}.an-mobile-money{grid-template-columns:1fr 1fr}.an-mobile-money span:last-child{grid-column:1/-1}.an-page .page-head h1{font-size:24px}}

/* =========================================================
   V1.1.5.2 — A.Nhật permanent handover log + compact dashboard
   ========================================================= */
.an-kpi-grid-compact{gap:10px;margin-bottom:10px}.an-kpi-grid-compact .an-kpi{min-height:82px;padding:11px 13px}.an-kpi-grid-compact .an-kpi-icon{width:34px;height:34px;flex-basis:34px}.an-kpi-grid-compact .an-kpi strong{font-size:18px}
.an-info-strip-compact{margin-bottom:10px;padding:8px 11px;min-height:36px}
.an-aging-strip{display:grid;grid-template-columns:minmax(0,1fr) minmax(230px,310px);gap:10px;margin-bottom:12px}.an-aging-mini-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}.an-aging-mini{display:grid;grid-template-columns:1fr auto;grid-template-areas:"label amount" "qty amount";align-items:center;gap:2px 8px;padding:9px 10px;border:1px solid #e1e7f0;border-radius:10px;background:#fff;color:#263651;min-width:0}.an-aging-mini span{grid-area:label;font-size:10px;color:#7b899e;white-space:nowrap}.an-aging-mini strong{grid-area:amount;font-size:13px;white-space:nowrap}.an-aging-mini small{grid-area:qty;font-size:9px;color:#98a4b6}.an-aging-mini.an-aging-green{border-left:3px solid #22a66f}.an-aging-mini.an-aging-blue{border-left:3px solid #4f6fe7}.an-aging-mini.an-aging-amber{border-left:3px solid #e3a11f}.an-aging-mini.an-aging-red{border-left:3px solid #e0444e}.an-aging-mini.an-aging-red strong{color:#d63d48}
.an-last-mini{display:grid;grid-template-columns:1fr auto;grid-template-areas:"label arrow" "value arrow";align-items:center;gap:2px 10px;padding:9px 11px;border:1px solid #e1e7f0;border-radius:10px;background:#fff;color:#263651}.an-last-mini span{grid-area:label;font-size:10px;color:#7b899e}.an-last-mini b{grid-area:value;font-size:12px}.an-last-mini em{grid-area:arrow;font-size:10px;font-style:normal;font-weight:750;color:#4f46e5}.an-last-mini.muted em{color:#9aa5b5}
.an-dashboard-dual{display:grid;grid-template-columns:1fr 1fr;gap:12px}.an-compact-panel{padding:14px;margin-bottom:0;min-width:0}.an-compact-panel .panel-head{margin-bottom:8px}.an-compact-orders{display:flex;flex-direction:column}.an-compact-order{display:grid;grid-template-columns:minmax(0,1fr) 78px 104px auto;gap:8px;align-items:center;padding:8px 2px;border-bottom:1px solid #edf0f5;color:#293953;min-width:0}.an-compact-order:last-child{border-bottom:0}.an-compact-order:hover{background:#fafbfe}.an-compact-main{display:flex;flex-direction:column;min-width:0}.an-compact-main b{font-size:11px;color:#315fb9;white-space:nowrap}.an-compact-main em{font-size:10px;font-style:normal;color:#687790;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.an-compact-date{display:flex;flex-direction:column;font-size:10px;color:#687790}.an-compact-date small{font-size:9px;color:#98a4b6}.an-compact-money{font-size:11px;font-weight:800;text-align:right;white-space:nowrap}.an-compact-order .an-badge{justify-self:end}
.an-filter-wide{grid-template-columns:minmax(300px,1fr) minmax(170px,220px) minmax(150px,190px) auto auto}.an-table{min-width:1200px}.an-settlement-table{min-width:1180px}.an-mobile-head small{font-size:9px;color:#8b97a9;line-height:1.35}.an-mobile-foot>span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;margin-right:8px}
.an-payment-panel .panel-head p,.an-detail-grid .panel-head p{margin:4px 0 0;font-size:11px;color:#8490a4}.an-allocation-table{min-width:900px}.an-allocation-applied{color:#138653;font-weight:800}.an-allocation-total{display:flex;align-items:center;gap:18px;flex-wrap:wrap;margin-top:10px;padding:10px 12px;border:1px solid #dfe6f0;border-radius:10px;background:#fafcff;font-size:11px;color:#65748b}.an-allocation-total b{font-size:12px;color:#263651}.an-allocation-total span:nth-child(2) b{color:#d63d48}.an-allocation-total small{margin-left:auto;color:#8b97aa}.an-settlement-form.is-over .an-allocation-total{border-color:#f0b7bc;background:#fff7f8}.an-settlement-form.is-over [data-an-settlement-submit]{opacity:.5;pointer-events:none}.an-settlement-form.is-over [data-an-received]{border-color:#e0444e;box-shadow:0 0 0 3px rgba(224,68,78,.08)}
@media(max-width:1250px){.an-aging-strip{grid-template-columns:1fr}.an-dashboard-dual{grid-template-columns:1fr}.an-compact-panel{margin-bottom:0}.an-filter-wide{grid-template-columns:1fr 1fr 1fr auto auto}}
@media(max-width:760px){.an-kpi-grid-compact .an-kpi{min-height:76px}.an-info-strip-compact{font-size:10px}.an-aging-mini-grid{grid-template-columns:1fr 1fr}.an-aging-strip{gap:8px}.an-dashboard-dual{gap:9px}.an-compact-panel{padding:11px}.an-compact-order{grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"main badge" "date money";padding:9px 1px}.an-compact-main{grid-area:main}.an-compact-date{grid-area:date}.an-compact-money{grid-area:money}.an-compact-order .an-badge{grid-area:badge}.an-filter-wide{grid-template-columns:1fr}.an-allocation-total{align-items:flex-start;flex-direction:column;gap:5px}.an-allocation-total small{margin-left:0}.an-allocation-card .an-mobile-money{grid-template-columns:repeat(3,1fr)}}
@media(max-width:430px){.an-aging-mini-grid{grid-template-columns:1fr 1fr}.an-aging-mini{grid-template-columns:1fr;grid-template-areas:"label" "amount" "qty"}.an-aging-mini strong{font-size:12px}.an-allocation-card .an-mobile-money{grid-template-columns:1fr 1fr}.an-allocation-card .an-mobile-money span:last-child{grid-column:1/-1}}

/* V1.1.5.3 - Chuẩn bị hàng: thêm đúng một lớp kiểm soát trước giao hàng. */
.page-orders .order-filter-bar{grid-template-columns:minmax(240px,1.35fr) repeat(6,minmax(142px,.75fr)) auto}
.page-orders .order-data-table{min-width:1280px}
.page-orders .preparation-select-shell{min-width:128px}
.page-orders .preparation-select-shell .preparation-inline-select{min-width:126px}
@media(max-width:1500px){.page-orders .order-filter-bar{grid-template-columns:minmax(250px,1.35fr) repeat(3,minmax(165px,1fr))}.page-orders .order-reset-btn{width:100%}}
@media(max-width:900px){.page-orders .order-filter-bar{grid-template-columns:1fr 1fr}.page-orders .order-search-control{grid-column:1/-1}.page-orders .mobile-preparation-field{grid-column:1/-1}}
@media(max-width:600px){.page-orders .order-filter-bar{grid-template-columns:1fr}.page-orders .order-search-control{grid-column:auto}}

/* =========================================================
   V1.1.5.4 — Compact desktop Orders table, no horizontal drag
   Scope: UI only. Keep every business column and workflow intact.
   ========================================================= */
@media(min-width:1181px){
  .page-orders .orders-table-panel .table-wrap.orders-desktop{overflow-x:hidden;overflow-y:visible}
  .page-orders .order-data-table{width:100%!important;min-width:0!important;table-layout:fixed}
  .page-orders .order-data-table th,.page-orders .order-data-table td{padding-left:7px;padding-right:7px}
  .page-orders .order-data-table th{height:52px;font-size:10px;letter-spacing:.28px}
  .page-orders .order-data-table td{height:60px;font-size:12px}
  .page-orders .order-data-table .num.strong{font-size:13px}

  .page-orders .order-data-table th:nth-child(1),.page-orders .order-data-table td:nth-child(1){width:10%}
  .page-orders .order-data-table th:nth-child(2),.page-orders .order-data-table td:nth-child(2){width:4.5%}
  .page-orders .order-data-table th:nth-child(3),.page-orders .order-data-table td:nth-child(3){width:9.5%}
  .page-orders .order-data-table th:nth-child(4),.page-orders .order-data-table td:nth-child(4){width:8%}
  .page-orders .order-data-table th:nth-child(5),.page-orders .order-data-table td:nth-child(5){width:7%}
  .page-orders .order-data-table th:nth-child(6),.page-orders .order-data-table td:nth-child(6){width:10%}
  .page-orders .order-data-table th:nth-child(7),.page-orders .order-data-table td:nth-child(7){width:10%}
  .page-orders .order-data-table th:nth-child(8),.page-orders .order-data-table td:nth-child(8){width:10%}
  .page-orders .order-data-table th:nth-child(9),.page-orders .order-data-table td:nth-child(9){width:10%}
  .page-orders .order-data-table th:nth-child(10),.page-orders .order-data-table td:nth-child(10){width:6%}
  .page-orders .order-data-table th:nth-child(11),.page-orders .order-data-table td:nth-child(11){width:10%}
  .page-orders .order-data-table th:nth-child(12),.page-orders .order-data-table td:nth-child(12){width:5%}

  .page-orders .order-data-table td:nth-child(1),
  .page-orders .order-data-table td:nth-child(3),
  .page-orders .order-data-table td:nth-child(4){overflow:hidden}
  .page-orders .order-data-table td:nth-child(3)>strong,
  .page-orders .order-data-table td:nth-child(3)>small{display:block;overflow:hidden;text-overflow:ellipsis}
  .page-orders .order-data-table td:nth-child(3)>strong{white-space:normal;line-height:1.25;max-height:2.5em}
  .page-orders .order-data-table td:nth-child(3)>small{white-space:nowrap}
  .page-orders .order-data-table .order-code{display:block;max-width:100%;overflow:hidden;text-overflow:ellipsis;font-size:11.5px}

  .page-orders .order-data-table th.image-col,.page-orders .order-data-table td.image-col{min-width:0!important;text-align:center}
  .page-orders .order-data-table .order-thumb,
  .page-orders .order-data-table .order-thumb.placeholder{width:40px;height:40px;border-radius:9px}
  .page-orders .order-data-table .order-thumb-badge{right:-4px;bottom:-4px;padding:1px 4px;font-size:9px}

  .page-orders .order-date{gap:5px;font-size:11px}
  .page-orders .order-date-icon svg{width:14px;height:14px}
  .page-orders .order-date small{gap:3px;font-size:9.5px}
  .page-orders .clock-mini svg{width:11px;height:11px}

  .page-orders .status-select-shell,
  .page-orders .preparation-select-shell{width:100%;min-width:0!important;max-width:100%;min-height:30px;padding-left:25px}
  .page-orders .status-select-shell .order-inline-select,
  .page-orders .preparation-select-shell .preparation-inline-select{width:100%;min-width:0!important;max-width:100%;height:28px;font-size:11px;padding-right:20px}
  .page-orders .status-select-icon{left:7px}
  .page-orders .status-select-icon svg{width:14px;height:14px}
  .page-orders .status-select-shell .status-select-chevron{right:5px}
  .page-orders .status-select-shell .status-select-chevron svg{width:12px;height:12px}
  .page-orders .order-status-pill{max-width:100%;padding:5px 6px;font-size:11px;overflow:hidden;text-overflow:ellipsis}

  .page-orders .carrier-select-shell,.page-orders .carrier-label{width:100%;min-width:0!important;max-width:100%;gap:5px}
  .page-orders .carrier-select-shell{padding-right:13px}
  .page-orders .carrier-icon{width:24px;height:24px;flex:0 0 24px;border-radius:6px}
  .page-orders .carrier-icon svg{width:14px;height:14px}
  .page-orders .order-carrier-select{width:100%;min-width:0!important;max-width:100%;height:30px;padding-right:14px;font-size:11px}
  .page-orders .carrier-select-shell .status-select-chevron svg{width:12px;height:12px}

  .page-orders .order-more-btn{width:30px;height:30px;border-radius:8px}
  .page-orders .order-more-btn svg{width:16px;height:16px}

  .page-orders .order-filter-bar{gap:8px;padding:14px}
  .page-orders .order-search-control,.page-orders .order-filter-control,.page-orders .order-reset-btn{height:46px}
  .page-orders .order-search-control input,.page-orders .order-filter-control select{padding-left:38px;padding-right:30px;font-size:12px}
  .page-orders .order-control-icon{left:12px}.page-orders .order-control-icon svg{width:17px;height:17px}
  .page-orders .order-control-chevron{right:9px}.page-orders .order-control-chevron svg{width:14px;height:14px}
}

/* Mid-size laptop/tablet: use cards instead of forcing a horizontal table. */
@media(min-width:701px) and (max-width:1180px){
  .page-orders .orders-desktop{display:none!important}
  .page-orders .mobile-order-list{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
  .page-orders .mobile-order-card{margin-bottom:0}
  .page-orders .mobile-preparation-field{grid-column:auto}
}

/* === V1.1.5.8 — MULTI ORDER PASTE / SAME-PAGE BATCH FORMS === */
.batch-order-workspace{margin-top:12px}.batch-order-workspace[hidden]{display:none!important}.batch-order-workspace form{display:block}.batch-order-summary{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-bottom:12px;padding:14px 16px}.batch-order-summary>div{display:flex;flex-direction:column;gap:3px}.batch-order-summary strong{font-size:14px;color:#172642}.batch-order-summary small{font-size:11px;color:var(--muted)}
.batch-orders-list{display:flex;flex-direction:column;gap:14px}.batch-order-card{position:relative;padding-top:0;overflow:hidden}.batch-order-card.batch-order-needs-check{box-shadow:0 0 0 2px rgba(218,147,28,.18)}.batch-order-card-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 -20px 14px;padding:11px 16px;border-bottom:1px solid var(--line);background:#f8faff}.batch-order-card-head>div{display:flex;align-items:center;gap:9px;min-width:0;flex-wrap:wrap}.batch-order-number{display:inline-flex;align-items:center;height:24px;padding:0 8px;border-radius:999px;background:#eaf1ff;color:#155eef;font-size:10px;font-weight:900;white-space:nowrap}.batch-order-card-head strong{font-size:13px;color:#172642;max-width:320px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.batch-order-card-head small{font-size:11px;color:#6e7d95}.batch-remove-order{white-space:nowrap}
.batch-sticky-actions{position:sticky;bottom:10px;z-index:18;display:flex;align-items:center;justify-content:space-between;gap:16px;margin-top:16px;padding:12px 14px;border:1px solid #d6e0ef;border-radius:13px;background:rgba(255,255,255,.96);box-shadow:0 12px 32px rgba(31,45,82,.16);backdrop-filter:blur(8px)}.batch-sticky-actions>div{display:flex;align-items:baseline;gap:12px}.batch-sticky-actions strong{font-size:14px;color:#172642}.batch-sticky-actions span{font-size:12px;color:#60708a}.batch-sticky-actions .btn{min-width:190px}.batch-order-card .external-images-note{font-size:9.5px}
@media(max-width:900px){.batch-order-card-head{margin-left:-16px;margin-right:-16px}.batch-sticky-actions{bottom:8px}.batch-order-summary{align-items:flex-start}.batch-order-summary .btn{flex:0 0 auto}}
@media(max-width:600px){.batch-order-summary{display:block}.batch-order-summary .btn{width:100%;margin-top:10px}.batch-order-card-head{align-items:flex-start}.batch-order-card-head>div{display:grid;grid-template-columns:auto 1fr}.batch-order-card-head small{grid-column:1/-1}.batch-remove-order{padding:0 8px}.batch-sticky-actions{left:0;right:0;bottom:6px;display:block;padding:10px}.batch-sticky-actions>div{display:flex;justify-content:space-between;margin-bottom:8px}.batch-sticky-actions .btn{width:100%;min-width:0}.batch-order-workspace .compact-form-grid{grid-template-columns:1fr}.batch-order-workspace .compact-form-grid>[class*="span-"]{grid-column:1/-1}.batch-order-workspace .compact-section-title{margin-top:2px}.quick-paste-panel textarea{height:86px;min-height:86px}}

/* === V1.1.5.9 — READABLE ORDER HISTORY === */
.order-note-detail dd{white-space:normal;word-break:break-word;line-height:1.55}
.audit-detail-panel{display:flex;flex-direction:column;gap:14px}
.audit-detail-panel>.panel-head{margin-bottom:0}
.audit-evolution{border:1px solid #dfe7f3;background:#f8faff;border-radius:13px;padding:14px}
.audit-evolution-head{display:flex;justify-content:space-between;gap:12px;align-items:flex-start;margin-bottom:11px}
.audit-evolution-head h3{margin:0;font-size:14px;color:#172642}
.audit-evolution-head p{margin:4px 0 0;font-size:11px;color:var(--muted)}
.audit-evolution-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.audit-evolution-card{min-width:0;border:1px solid #e2e8f1;background:#fff;border-radius:11px;padding:11px 12px}
.audit-evolution-card>strong{display:block;font-size:12px;color:#41516e;margin-bottom:8px}
.audit-evolution-values{display:flex;align-items:center;gap:6px;flex-wrap:wrap;min-width:0}
.audit-evolution-value{display:inline-flex;align-items:center;max-width:100%;padding:5px 8px;border-radius:8px;background:#f4f6fa;border:1px solid #e4e8ef;color:#4f5e75;font-size:12px;font-weight:700;white-space:normal;word-break:break-word}
.audit-evolution-value.current{background:#eef5ff;border-color:#c8dcff;color:#155eef}
.audit-evolution-arrow{color:#8b98ad;font-weight:800}
.audit-readable-list{display:flex;flex-direction:column;gap:9px}
.audit-readable-item{border:1px solid #e2e7ef;background:#fff;border-radius:11px;padding:11px 12px}
.audit-readable-meta{display:flex;align-items:center;gap:7px;flex-wrap:wrap;color:#77859b;font-size:11px;margin-bottom:6px}
.audit-readable-meta strong{color:#44516a;font-size:11px}
.audit-readable-meta .audit-event-pill{margin-left:auto}
.audit-readable-sentence{font-size:13px;font-weight:800;color:#1d2a44;line-height:1.45}
.audit-before-after{display:grid;grid-template-columns:minmax(0,1fr) 24px minmax(0,1fr);gap:8px;align-items:center;margin-top:9px}
.audit-before-after>div{min-width:0;padding:8px 10px;border-radius:9px;background:#f8f9fc;border:1px solid #e8ebf1}
.audit-before-after>div:last-child{background:#f1f6ff;border-color:#d7e5ff}
.audit-before-after small{display:block;font-size:9px;text-transform:uppercase;letter-spacing:.05em;color:#8a96aa;margin-bottom:3px;font-weight:800}
.audit-before-after span{display:block;font-size:12px;color:#3c4960;white-space:normal;word-break:break-word;line-height:1.4}
.audit-before-after>div:last-child span{color:#155eef;font-weight:800}
.audit-change-arrow{text-align:center;color:#8b98ad;font-weight:900}
@media(max-width:760px){
  .audit-evolution-grid{grid-template-columns:1fr}
  .audit-readable-meta .audit-event-pill{margin-left:0}
  .audit-before-after{grid-template-columns:1fr}
  .audit-change-arrow{transform:rotate(90deg);line-height:16px}
}

/* === V1.1.6.0 — AUTOMATIC PRODUCT GROUPS === */
.product-group-badge{display:inline-flex;align-items:center;max-width:100%;min-height:20px;margin-top:4px;padding:2px 7px;border-radius:999px;font-size:9.5px;font-weight:800;line-height:1.2;white-space:nowrap;border:1px solid transparent}
.product-group-tone-1{background:#eef4ff;color:#315fb9;border-color:#dce7ff}.product-group-tone-2{background:#eaf8f0;color:#177a4d;border-color:#d3efdf}.product-group-tone-3{background:#fff3ea;color:#b35b20;border-color:#ffe1cc}.product-group-tone-4{background:#f3efff;color:#6847ba;border-color:#e6dcff}.product-group-tone-5{background:#fff0f4;color:#b84468;border-color:#ffdce7}.product-group-tone-6{background:#eef7f7;color:#26747a;border-color:#d6eeee}
.mobile-order-group{margin-top:3px}.mobile-order-group .product-group-badge{margin-top:0}
.page-orders .order-filter-bar{grid-template-columns:minmax(230px,1.35fr) repeat(7,minmax(132px,.72fr)) auto}
.product-group-quickbar{grid-column:1/-1;display:flex;align-items:center;gap:7px;min-width:0;padding-top:2px;overflow-x:auto;scrollbar-width:thin}
.product-group-chip{display:inline-flex;align-items:center;gap:7px;height:32px;padding:0 12px;border:1px solid #dfe5ef;border-radius:999px;background:#fff;color:#475570;font-size:11px;font-weight:800;white-space:nowrap;cursor:pointer;transition:.16s}
.product-group-chip:hover{border-color:#a9bfe9;background:#f7faff;color:#2458ae}.product-group-chip.active{border-color:#155eef;background:#155eef;color:#fff;box-shadow:0 4px 12px rgba(21,94,239,.18)}.product-group-chip-label{display:inline-flex;align-items:center}.product-group-chip-count{display:inline-flex;align-items:center;justify-content:center;min-width:20px;height:20px;padding:0 7px;border-radius:999px;background:#eff4fb;color:#3b567e;font-size:10px;font-weight:900;line-height:1}.product-group-chip.active .product-group-chip-count{background:rgba(255,255,255,.18);color:#fff}
.product-group-auto-note{display:inline-flex;align-items:center;gap:6px;margin-left:auto;color:#7b889c;font-size:10.5px;white-space:nowrap}.product-group-auto-note svg{width:14px;height:14px}
.product-group-settings-entry{display:flex;align-items:center;justify-content:space-between;gap:16px;border-color:#dbe6fa;background:linear-gradient(135deg,#fff 0%,#f8fbff 100%)}.product-group-settings-entry>div{display:flex;align-items:center;gap:12px}.product-group-settings-entry h3{margin:0 0 4px}.product-group-settings-entry p{margin:0;color:var(--muted);font-size:12px}.product-group-entry-icon{display:flex;align-items:center;justify-content:center;width:42px;height:42px;flex:0 0 42px;border-radius:12px;background:#eaf1ff;color:#155eef}.product-group-entry-icon svg{width:21px;height:21px}
.product-group-info-banner{display:flex;align-items:flex-start;gap:11px;margin-bottom:16px;padding:13px 15px;border:1px solid #bcd2ff;border-radius:12px;background:#f4f8ff;color:#23416f}.product-group-info-banner>svg{width:19px;height:19px;flex:0 0 19px;margin-top:1px;color:#155eef}.product-group-info-banner div{display:flex;flex-direction:column;gap:3px}.product-group-info-banner strong{font-size:12px}.product-group-info-banner span{font-size:11px;color:#5c6f8b}
.product-group-settings-panel{padding:0;overflow:hidden}.product-group-settings-toolbar{display:flex;justify-content:space-between;align-items:flex-start;gap:16px;padding:16px 18px;border-bottom:1px solid var(--line)}.product-group-settings-toolbar h3{margin:0}.product-group-settings-toolbar p{margin:4px 0 0;font-size:11px;color:var(--muted)}.product-group-settings-toolbar>div:last-child{display:flex;gap:8px}.product-group-settings-toolbar .btn svg{width:16px;height:16px;margin-right:5px}
.product-group-table-wrap{overflow:auto}.product-group-settings-table{width:100%;min-width:930px;border-collapse:collapse}.product-group-settings-table th{padding:11px 13px;background:#f8faff;border-bottom:1px solid var(--line);color:#64728a;font-size:10px;text-align:left;text-transform:uppercase;letter-spacing:.35px;white-space:nowrap}.product-group-settings-table td{padding:10px 13px;border-bottom:1px solid #edf0f5;vertical-align:middle}.product-group-settings-table tr:last-child td{border-bottom:0}.product-group-settings-table input[type=text],.product-group-settings-table input:not([type]){min-height:38px}.product-group-settings-table td:nth-child(1){width:19%}.product-group-settings-table td:nth-child(2){width:37%}.product-group-settings-table td:nth-child(3){width:11%}.product-group-settings-table td:nth-child(4){width:9%}.product-group-settings-table td:nth-child(5){width:16%}.product-group-settings-table td:nth-child(6){width:8%}.product-group-center{text-align:center}.product-group-sort{width:72px!important;min-width:72px;text-align:center}
.product-group-radio,.product-group-toggle{display:inline-flex;align-items:center;justify-content:center;gap:5px;min-height:30px;padding:0 9px;border-radius:999px;background:#f1f4f8;color:#657188;font-size:10px;font-weight:800;cursor:pointer;white-space:nowrap}.product-group-radio input,.product-group-toggle input{width:14px!important;height:14px!important;min-height:0!important;margin:0}.product-group-radio:has(input:checked){background:#e8f7ef;color:#1a7b4f}.product-group-toggle:has(input:checked){background:#e8f7ef;color:#1a7b4f}.product-group-remove{margin:auto;color:#b54450;background:#fff5f6;border:1px solid #ffdadd}.product-group-remove:disabled{opacity:.35;cursor:not-allowed}.product-group-mobile-note{display:none;padding:10px 13px;border-top:1px solid var(--line);font-size:10px;color:var(--muted);background:#fafbfe}
.product-group-settings-bottom{position:sticky;bottom:10px;z-index:12;display:flex;align-items:center;justify-content:space-between;gap:12px;max-width:720px;margin:12px auto 0;padding:10px 12px;border:1px solid #d7e0ef;border-radius:12px;background:rgba(255,255,255,.96);box-shadow:0 12px 30px rgba(31,45,82,.13);backdrop-filter:blur(8px)}.product-group-settings-bottom span{font-size:11px;color:var(--muted)}
@media(max-width:1500px){.page-orders .order-filter-bar{grid-template-columns:minmax(250px,1.35fr) repeat(3,minmax(165px,1fr))}.product-group-auto-note{margin-left:0}}
@media(max-width:900px){.product-group-settings-entry{align-items:flex-start;flex-direction:column}.product-group-settings-entry .btn{width:100%}.product-group-settings-toolbar{flex-direction:column}.product-group-settings-toolbar>div:last-child{width:100%}.product-group-settings-toolbar .btn{flex:1}.product-group-mobile-note{display:block}.product-group-settings-bottom{bottom:7px}.product-group-auto-note{display:none}}
@media(max-width:600px){.product-group-quickbar{margin:0 -2px;padding-bottom:3px}.product-group-chip{height:30px;padding:0 10px;font-size:10.5px}.product-group-settings-toolbar>div:last-child{flex-direction:column}.product-group-settings-toolbar .btn{width:100%}.product-group-settings-bottom{display:block;margin-top:8px}.product-group-settings-bottom span{display:block;margin-bottom:7px}.product-group-settings-bottom .btn{width:100%}.product-group-info-banner{padding:11px}.product-group-settings-entry>div{align-items:flex-start}.product-group-entry-icon{width:36px;height:36px;flex-basis:36px}}

/* === V1.1.6.2 — DATABASE INFO IN SETTINGS === */
.database-info-panel{padding:17px 18px;border-color:#dce6f5;background:linear-gradient(135deg,#fff 0%,#f9fbff 100%)}
.database-info-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:15px}.database-info-head>div:first-child{display:flex;align-items:center;gap:12px}.database-info-head h3{margin:0 0 4px}.database-info-head p{margin:0;color:var(--muted);font-size:11px}.database-info-icon{display:flex;align-items:center;justify-content:center;width:42px;height:42px;flex:0 0 42px;border-radius:12px;background:#eaf1ff;color:#155eef}.database-info-icon svg{width:21px;height:21px}.database-connection-ok{display:inline-flex;align-items:center;gap:7px;min-height:30px;padding:0 10px;border:1px solid #ccebd9;border-radius:999px;background:#edf9f2;color:#167447;font-size:10.5px;font-weight:800;white-space:nowrap}.database-connection-ok i{width:7px;height:7px;border-radius:50%;background:#19a55c;box-shadow:0 0 0 3px rgba(25,165,92,.1)}
.database-info-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.database-info-grid>div{min-width:0;padding:11px 12px;border:1px solid #e5eaf2;border-radius:10px;background:#fff}.database-info-grid span,.database-info-grid strong{display:block}.database-info-grid span{margin-bottom:5px;color:#7a879c;font-size:10px;font-weight:700}.database-info-grid strong{overflow:hidden;text-overflow:ellipsis;color:#1b2b47;font-size:12px;white-space:nowrap}
@media(max-width:900px){.database-info-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:600px){.database-info-head{flex-direction:column}.database-info-grid{grid-template-columns:1fr}.database-connection-ok{align-self:flex-start}}

/* === V1.1.7.0 — POSTAL RECONCILIATION V1 === */
.postal-recon-shell{max-width:1500px}.postal-upload-panel{padding:18px}.postal-upload-intro{display:flex;align-items:flex-start;justify-content:space-between;gap:18px;margin-bottom:15px}.postal-upload-intro h3{margin:0 0 4px;font-size:15px;color:#172642}.postal-upload-intro p{margin:0;color:var(--muted);font-size:11.5px;line-height:1.5}.postal-carrier-chip{display:flex;align-items:center;gap:7px;min-height:38px;padding:7px 11px;border:1px solid #d8e4f6;border-radius:10px;background:#f7faff;color:#45617f;white-space:nowrap}.postal-carrier-chip svg{width:17px;height:17px;color:#155eef}.postal-carrier-chip span{font-size:9px;text-transform:uppercase;letter-spacing:.05em;font-weight:800;color:#8490a3}.postal-carrier-chip strong{font-size:11.5px;color:#1d3558}
.postal-upload-form{display:grid;grid-template-columns:minmax(320px,1.5fr) minmax(260px,.8fr) auto;gap:11px;align-items:stretch}.postal-file-box{position:relative;display:flex;align-items:center;gap:12px;min-height:72px;padding:12px 14px;border:1px dashed #aebfda;border-radius:12px;background:#fbfdff;cursor:pointer}.postal-file-box>span{display:flex;align-items:center;justify-content:center;width:38px;height:38px;flex:0 0 38px;border-radius:10px;background:#eaf1ff;color:#155eef}.postal-file-box svg{width:19px;height:19px}.postal-file-box div{display:flex;flex-direction:column;gap:3px;min-width:0}.postal-file-box strong{font-size:12px;color:#203452}.postal-file-box small{font-size:10px;color:#7d899b;line-height:1.4}.postal-file-box input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}.postal-actual-field{display:flex;flex-direction:column;justify-content:center;gap:5px;min-height:72px;padding:10px 12px;border:1px solid #e1e7f0;border-radius:12px;background:#fff}.postal-actual-field>span{font-size:10.5px;font-weight:800;color:#56647a}.postal-actual-field em{font-style:normal;font-weight:600;color:#8a96a8}.postal-actual-field input{height:36px;font-weight:800}.postal-actual-field small{font-size:9.5px;color:#8a96a8;line-height:1.35}.postal-check-btn{min-width:175px;align-self:stretch;display:flex;align-items:center;justify-content:center;gap:7px}.postal-check-btn svg{width:17px;height:17px}.postal-readonly-note{margin-top:10px;padding:8px 10px;border-radius:9px;background:#f4f6fa;color:#6c788c;font-size:10.5px}
.postal-statement-head{display:flex;align-items:center;justify-content:space-between;gap:14px;margin:15px 0 10px;padding:12px 14px;border:1px solid #dfe6f1;border-radius:12px;background:#fff}.postal-statement-head>div{display:flex;align-items:baseline;gap:9px;flex-wrap:wrap}.postal-statement-head span{font-size:10px;font-weight:800;text-transform:uppercase;color:#8592a5;letter-spacing:.04em}.postal-statement-head strong{font-size:13px;color:#1c2f4d}.postal-statement-head small{font-size:10.5px;color:#778499}
.postal-kpi-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:9px;margin-bottom:9px}.postal-kpi-grid article{min-height:78px;padding:12px 14px;border:1px solid #e2e7ef;border-radius:12px;background:#fff}.postal-kpi-grid small,.postal-kpi-grid strong{display:block}.postal-kpi-grid small{margin-bottom:5px;font-size:10px;font-weight:800;color:#7c899d}.postal-kpi-grid strong{font-size:25px;line-height:1;color:#243653}.postal-kpi-grid article.ok{background:#f4fbf7;border-color:#d9eee2}.postal-kpi-grid article.ok strong{color:#16824f}.postal-kpi-grid article.warn{background:#fffaf0;border-color:#f2e5bd}.postal-kpi-grid article.warn strong{color:#a56d10}.postal-kpi-grid article.danger{background:#fff6f6;border-color:#f2d8d8}.postal-kpi-grid article.danger strong{color:#bd3d49}.postal-kpi-grid article.ambiguous{background:#f8f5ff;border-color:#e4dbfa}.postal-kpi-grid article.ambiguous strong{color:#7251b5}
.postal-check-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px;margin-bottom:12px}.postal-check-grid>a{display:flex;align-items:center;gap:10px;min-height:58px;padding:10px 12px;border:1px solid #e1e7f0;border-radius:11px;background:#fff;color:inherit;text-decoration:none}.postal-check-grid>a:hover{border-color:#b6caed;background:#f9fbff}.postal-check-grid>a>span{display:flex;align-items:center;justify-content:center;width:27px;height:27px;flex:0 0 27px;border-radius:8px;background:#edf3ff;color:#155eef;font-size:11px;font-weight:900}.postal-check-grid div{min-width:0}.postal-check-grid small,.postal-check-grid strong{display:block}.postal-check-grid small{font-size:9.5px;color:#8490a3;line-height:1.25}.postal-check-grid strong{margin-top:3px;font-size:12px;color:#283b58}.text-danger{color:#bd3d49!important}
.postal-money-panel{margin-bottom:12px}.postal-money-panel .panel-head p,.postal-missing-panel .panel-head p{margin:3px 0 0;color:var(--muted);font-size:10.5px}.postal-money-grid{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:9px}.postal-money-grid>div{padding:11px 12px;border:1px solid #e4e9f1;border-radius:10px;background:#fafbfc}.postal-money-grid small,.postal-money-grid strong{display:block}.postal-money-grid small{font-size:9.5px;color:#8490a4;margin-bottom:4px}.postal-money-grid strong{font-size:14px;color:#22344f}.postal-money-grid .primary{background:#eef5ff;border-color:#cfe0ff}.postal-money-grid .primary strong{color:#155eef}.postal-money-grid .danger{background:#fff4f4;border-color:#f1d4d6}.postal-money-grid .danger strong{color:#bd3d49}.postal-money-grid .ok{background:#f1faf5;border-color:#d6ebdf}.postal-money-grid .ok strong{color:#16764a}
.postal-result-badge{display:inline-flex;align-items:center;justify-content:center;min-height:24px;padding:3px 8px;border-radius:999px;font-size:9.5px;font-weight:900;white-space:nowrap}.postal-result-badge.ok{background:#eaf8f0;color:#177a4d}.postal-result-badge.warn{background:#fff4dd;color:#a96a00}.postal-result-badge.danger{background:#ffecee;color:#b73543}.postal-result-badge.ambiguous{background:#f1ebff;color:#6c49ae}.postal-results-panel{padding:0;overflow:hidden}.postal-results-panel>.panel-head{padding:15px 17px;margin:0}.postal-results-panel>.panel-head p{margin:3px 0 0;color:var(--muted);font-size:10.5px}.postal-table{min-width:1100px}.postal-table td{vertical-align:top}.postal-table td>small{display:block;margin-top:4px;max-width:260px;color:#7a879b;font-size:9.5px;line-height:1.35;white-space:normal}.postal-table tr.diff{background:#fffdf8}.postal-table tr.not_found{background:#fff9f9}.postal-table tr.ambiguous{background:#fcfaff}.postal-table .num small{text-align:right}.postal-details{margin-top:7px}.postal-details summary{display:inline-flex;align-items:center;cursor:pointer;color:#42679e;font-size:9.5px;font-weight:800}.postal-details[open] summary{margin-bottom:8px}.postal-compare-grid{display:flex;flex-direction:column;gap:5px;min-width:360px;padding:8px;border:1px solid #e4e9f1;border-radius:9px;background:#fff}.postal-compare-line{display:grid;grid-template-columns:105px minmax(120px,1fr) minmax(120px,1fr);gap:7px;align-items:start;padding:6px 7px;border-radius:7px;background:#f8fafc}.postal-compare-line.bad{background:#fff4f4}.postal-compare-line>strong{font-size:9.5px;color:#5f6c81}.postal-compare-line>span{font-size:10px;color:#34445e;word-break:break-word}.postal-compare-line>span small{display:inline-block;margin-right:5px;color:#8b97aa;font-size:8px;font-weight:900;text-transform:uppercase}.postal-compare-line.bad>span{color:#9d3540}.postal-candidate-list{display:flex;flex-direction:column;gap:5px;min-width:310px;padding:8px;border:1px solid #e5def8;border-radius:9px;background:#fbf9ff}.postal-candidate-list>strong{font-size:10px;color:#66518f}.postal-candidate-list a{font-size:10px;font-weight:800;color:#315c9d;text-decoration:none}.postal-empty-detail{padding:8px 10px;border-radius:8px;background:#fff4f4;color:#97414a;font-size:10px;line-height:1.45}.postal-mobile-cards{display:none}
.postal-missing-panel{margin-top:12px}.postal-count-pill{display:inline-flex;align-items:center;justify-content:center;min-width:58px;height:29px;padding:0 9px;border-radius:999px;font-size:10px;font-weight:900}.postal-count-pill.ok{background:#eaf8f0;color:#177a4d}.postal-count-pill.warn{background:#fff0e8;color:#b85524}.postal-empty-ok{padding:12px;border-radius:9px;background:#f1faf5;color:#22744f;font-size:11px;font-weight:700}
@media(max-width:1100px){.postal-upload-form{grid-template-columns:1fr 1fr}.postal-check-btn{grid-column:1/-1;min-height:46px}.postal-kpi-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.postal-check-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.postal-money-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:700px){.postal-upload-panel{padding:14px}.postal-upload-intro{flex-direction:column}.postal-carrier-chip{width:100%;white-space:normal}.postal-upload-form{grid-template-columns:1fr}.postal-check-btn{grid-column:auto}.postal-file-box{min-height:82px}.postal-statement-head{align-items:flex-start;flex-direction:column}.postal-statement-head .btn{width:100%}.postal-kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.postal-kpi-grid article:first-child{grid-column:1/-1}.postal-kpi-grid article{min-height:68px}.postal-kpi-grid strong{font-size:22px}.postal-check-grid{grid-template-columns:1fr 1fr}.postal-money-grid{grid-template-columns:1fr 1fr}.postal-money-grid .primary{grid-column:1/-1}.postal-desktop{display:none!important}.postal-mobile-cards{display:flex;flex-direction:column;gap:9px;padding:0 11px 12px}.postal-mobile-card{padding:12px;border:1px solid #e3e8f0;border-radius:11px;background:#fff}.postal-mobile-card.diff{border-color:#eddcad;background:#fffdf7}.postal-mobile-card.not_found{border-color:#efcfd2;background:#fffafa}.postal-mobile-card.ambiguous{border-color:#ddd1f5;background:#fcfaff}.postal-card-head{display:flex;justify-content:space-between;align-items:flex-start;gap:9px}.postal-card-head>div{min-width:0}.postal-card-head strong,.postal-card-head small{display:block}.postal-card-head strong{font-size:12px;color:#1f304d}.postal-card-head small{margin-top:3px;font-size:9.5px;color:#7e899b}.postal-card-body{display:grid;grid-template-columns:1fr 1fr;gap:7px;margin-top:10px}.postal-card-body>div{padding:8px;border-radius:8px;background:#f6f8fb}.postal-card-body small,.postal-card-body strong,.postal-card-body a{display:block}.postal-card-body small{font-size:8.5px;color:#8b96a7;margin-bottom:3px}.postal-card-body strong,.postal-card-body a{font-size:10.5px;font-weight:800;color:#2b4366}.postal-mobile-card>p{margin:9px 0 0;font-size:10px;color:#66738a;line-height:1.4}.postal-compare-grid{min-width:0}.postal-compare-line{grid-template-columns:1fr}.postal-compare-line>strong{margin-bottom:2px}.postal-candidate-list{min-width:0}.postal-missing-panel .panel-head{align-items:flex-start}.postal-missing-panel .table-wrap{overflow:auto}}
@media(max-width:440px){.postal-check-grid{grid-template-columns:1fr}.postal-money-grid{grid-template-columns:1fr}.postal-money-grid .primary{grid-column:auto}.postal-card-body{grid-template-columns:1fr}.postal-kpi-grid{gap:7px}}
.postal-files-panel{margin-top:12px}.postal-file-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.postal-file-list>div{border:1px solid var(--line);border-radius:10px;padding:11px 12px;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:3px 12px;align-items:center}.postal-file-list strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.postal-file-list small{grid-column:1;color:var(--muted)}.postal-file-list span{grid-column:2;grid-row:1/3;font-weight:700}@media(max-width:760px){.postal-file-list{grid-template-columns:1fr}.postal-file-list>div{grid-template-columns:minmax(0,1fr) auto}}

/* V1.1.7.5 — Show every website order matching an Excel row (phone-first). */
.postal-all-matches-row td{padding:0 12px 12px!important;background:#f8fbff;border-top:0}
.postal-all-matches{padding:12px 13px;border:1px solid #dbe6f5;border-radius:12px;background:#f8fbff}
.postal-all-matches-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:10px}
.postal-all-matches-head strong,.postal-all-matches-head small{display:block}
.postal-all-matches-head strong{font-size:12px;color:#23466f}
.postal-all-matches-head small{margin-top:3px;font-size:9.5px;color:#7b889c}
.postal-all-matches-head>span{display:inline-flex;align-items:center;justify-content:center;min-width:54px;height:25px;padding:0 8px;border-radius:999px;background:#e7f0ff;color:#155eef;font-size:10px;font-weight:900;white-space:nowrap}
.postal-all-matches-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}
.postal-match-order-card{padding:11px 12px;border:1px solid #dfe7f2;border-radius:10px;background:#fff}
.postal-match-order-card.primary{border-color:#9fbbeb;box-shadow:0 0 0 2px rgba(21,94,239,.07)}
.postal-match-order-top{display:flex;align-items:flex-start;justify-content:space-between;gap:10px}
.postal-match-order-top>div{display:flex;align-items:center;gap:7px;flex-wrap:wrap;min-width:0}
.postal-match-order-top a{font-size:11.5px;font-weight:900;color:#155eef;text-decoration:none}
.postal-match-order-top>small{font-size:9.5px;color:#7f8b9d;white-space:nowrap}
.postal-picked-badge{display:inline-flex;align-items:center;min-height:21px;padding:2px 7px;border-radius:999px;background:#eaf1ff;color:#155eef;font-size:8.5px;font-weight:900}
.postal-match-order-info{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;margin-top:9px}
.postal-match-order-info>div{padding:7px 8px;border-radius:8px;background:#f6f8fb;min-width:0}
.postal-match-order-info small,.postal-match-order-info strong{display:block}
.postal-match-order-info small{font-size:8px;color:#8b96a8;margin-bottom:2px}
.postal-match-order-info strong{font-size:9.5px;color:#30445f;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.postal-match-reasons{display:flex;flex-wrap:wrap;gap:5px;margin-top:8px}
.postal-match-reasons span{display:inline-flex;align-items:center;min-height:20px;padding:2px 7px;border-radius:999px;font-size:8.5px;font-weight:900}
.postal-match-reasons .ok{background:#eaf8f0;color:#177a4d}
.postal-match-reasons .near{background:#fff4dd;color:#9a6506}
.postal-match-reasons .bad{background:#ffecee;color:#b73543}
@media(max-width:1100px){.postal-all-matches-grid{grid-template-columns:1fr}.postal-match-order-info{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:700px){.postal-all-matches{margin-top:10px;padding:10px}.postal-all-matches-head{flex-direction:column}.postal-all-matches-grid{grid-template-columns:1fr}.postal-match-order-info{grid-template-columns:1fr 1fr}.postal-match-order-card{padding:10px}.postal-match-order-top{flex-direction:column;gap:5px}}
@media(max-width:430px){.postal-match-order-info{grid-template-columns:1fr}}

/* V1.1.7.6 — Cleaner all-matching-orders layout. */
.postal-multi-count{color:#155eef;font-size:12px}
.postal-all-matches-row td{padding:0 12px 14px!important;background:#fbfdff;border-top:0}
.postal-all-matches.compact{padding:12px 14px;border:1px solid #dbe6f5;border-radius:12px;background:#f8fbff}
.postal-all-matches.compact .postal-all-matches-head{margin-bottom:10px}
.postal-all-matches.compact .postal-all-matches-head strong{font-size:12.5px;color:#1f416c}
.postal-all-matches.compact .postal-all-matches-head small{max-width:780px;line-height:1.4}
.postal-all-matches.compact .postal-all-matches-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(285px,1fr));gap:9px}
.postal-all-matches.compact .postal-match-order-card{display:flex;flex-direction:column;gap:9px;padding:11px 12px;border:1px solid #dfe7f2;border-radius:11px;background:#fff;min-width:0}
.postal-all-matches.compact .postal-match-order-card.primary{border-color:#7ba5e8;background:#f8fbff;box-shadow:0 0 0 2px rgba(21,94,239,.06)}
.postal-all-matches.compact .postal-match-order-top{display:flex;align-items:center;justify-content:space-between;gap:8px;padding-bottom:8px;border-bottom:1px solid #eef2f7}
.postal-all-matches.compact .postal-match-order-top a{font-size:12px;font-weight:900;color:#155eef}
.postal-all-matches.compact .postal-picked-badge{min-height:20px;padding:2px 7px;background:#e8f0ff;color:#155eef;font-size:8.5px}
.postal-match-order-summary{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(0,1fr);gap:7px 10px}
.postal-match-order-summary>div{min-width:0}
.postal-match-order-summary small,.postal-match-order-summary strong{display:block}
.postal-match-order-summary small{font-size:8px;color:#8a96a8;margin-bottom:2px}
.postal-match-order-summary strong{font-size:10px;color:#2a3f5e;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.postal-match-order-summary .customer{grid-column:1/-1}
.postal-match-order-summary .customer strong{font-size:11px}
.postal-match-order-summary .tracking{grid-column:1/-1;padding-top:2px}
.postal-match-order-foot{display:flex;align-items:flex-end;justify-content:space-between;gap:8px;margin-top:auto}
.postal-all-matches.compact .postal-match-reasons{margin-top:0;gap:5px}
.postal-all-matches.compact .postal-match-reasons span{min-height:19px;padding:2px 6px;font-size:8px}
.postal-open-order{display:inline-flex;align-items:center;justify-content:center;min-height:29px;padding:5px 9px;border:1px solid #cfdcf0;border-radius:8px;background:#fff;color:#315c9d;font-size:9px;font-weight:900;text-decoration:none;white-space:nowrap}
.postal-open-order:hover{border-color:#9db8e5;background:#f5f9ff}
@media(max-width:700px){.postal-all-matches.compact .postal-all-matches-grid{grid-template-columns:1fr}.postal-match-order-foot{align-items:flex-start;flex-direction:column}.postal-open-order{width:100%}.postal-match-order-summary{grid-template-columns:1fr 1fr}}
@media(max-width:430px){.postal-match-order-summary{grid-template-columns:1fr}.postal-match-order-summary .customer,.postal-match-order-summary .tracking{grid-column:auto}}

/* V1.1.7.7 — Clickable reconciliation KPI filters + quick order status editing. */
.postal-kpi-card{appearance:none;-webkit-appearance:none;width:100%;min-height:78px;padding:12px 14px;border:1px solid #e2e7ef;border-radius:12px;background:#fff;text-align:left;font:inherit;cursor:pointer;transition:border-color .16s,box-shadow .16s,transform .16s,background .16s}
.postal-kpi-card:hover{border-color:#b8cae6;box-shadow:0 5px 16px rgba(31,53,88,.07);transform:translateY(-1px)}
.postal-kpi-card small,.postal-kpi-card strong,.postal-kpi-card em{display:block}
.postal-kpi-card small{margin-bottom:5px;font-size:10px;font-weight:800;color:#7c899d}
.postal-kpi-card strong{font-size:25px;line-height:1;color:#243653}
.postal-kpi-card em{margin-top:7px;font-size:9px;font-style:normal;font-weight:700;color:#97a1b1}
.postal-kpi-card.ok{background:#f4fbf7;border-color:#d9eee2}.postal-kpi-card.ok strong{color:#16824f}
.postal-kpi-card.warn{background:#fffaf0;border-color:#f2e5bd}.postal-kpi-card.warn strong{color:#a56d10}
.postal-kpi-card.danger{background:#fff6f6;border-color:#f2d8d8}.postal-kpi-card.danger strong{color:#bd3d49}
.postal-kpi-card.ambiguous{background:#f8f5ff;border-color:#e4dbfa}.postal-kpi-card.ambiguous strong{color:#7251b5}
.postal-kpi-card.active{border-color:#155eef;box-shadow:0 0 0 2px rgba(21,94,239,.14),0 7px 18px rgba(21,94,239,.08)}
.postal-kpi-card.active em{color:#155eef}
.postal-filter-state{display:flex;flex-direction:column;align-items:flex-end;justify-content:center;gap:2px;min-width:160px;padding:8px 10px;border:1px solid #dce5f2;border-radius:10px;background:#f8fbff}
.postal-filter-state small{font-size:8.5px!important;text-transform:uppercase;letter-spacing:.04em;font-weight:900;color:#8b97a8!important}
.postal-filter-state strong{font-size:11px;color:#155eef}
.postal-row[hidden],.postal-all-matches-row[hidden],.postal-mobile-card[hidden]{display:none!important}
.postal-quick-edit{display:grid;grid-template-columns:repeat(2,minmax(118px,1fr));gap:7px;margin-top:8px;padding-top:8px;border-top:1px dashed #e0e6ef}
.postal-quick-edit>label{display:flex;flex-direction:column;gap:4px;min-width:0}
.postal-quick-edit>label>span{font-size:8px;font-weight:900;color:#8894a6;text-transform:uppercase;letter-spacing:.03em}
.postal-quick-edit .status-select-shell{width:100%;min-width:0}
.postal-quick-edit .order-inline-select{width:100%;min-width:0;height:32px;font-size:9.5px;padding-right:25px}
.postal-all-matches.compact .postal-quick-edit{margin-top:0;padding-top:8px}
.postal-results-panel>.panel-head{align-items:flex-start}
@media(max-width:900px){.postal-filter-state{align-items:flex-start;width:100%;min-width:0}.postal-results-panel>.panel-head{flex-direction:column}.postal-quick-edit{grid-template-columns:1fr 1fr}}
@media(max-width:700px){.postal-kpi-card{min-height:68px}.postal-kpi-card strong{font-size:22px}.postal-kpi-card em{font-size:8.5px}.postal-quick-edit{grid-template-columns:1fr 1fr;margin:9px 0}.postal-mobile-card .postal-quick-edit{padding:9px;border:1px solid #e4e9f1;border-radius:9px;background:#f9fbfd}}
@media(max-width:430px){.postal-quick-edit{grid-template-columns:1fr}}

/* V1.1.7.8 — Postal filter + compact quick-status layout fix. */
.postal-filter-hidden{display:none!important}

/* Give the website-order cell enough room for the two quick status controls. */
.postal-table th:nth-child(2),.postal-table td:nth-child(2){min-width:245px}

/* Compact, balanced two-row status editor: label on the left, control on the right. */
.postal-quick-edit{
  display:flex;
  flex-direction:column;
  gap:6px;
  width:100%;
  max-width:220px;
  margin-top:7px;
  padding-top:7px;
  border-top:1px dashed #e0e6ef;
}
.postal-quick-edit>label{
  display:grid;
  grid-template-columns:62px minmax(0,1fr);
  align-items:center;
  gap:7px;
  min-width:0;
  margin:0;
}
.postal-quick-edit>label>span{
  font-size:9px;
  line-height:1.15;
  font-weight:800;
  color:#7e899c;
  text-transform:none;
  letter-spacing:0;
  white-space:nowrap;
}
.postal-quick-edit .status-select-shell{
  width:100%;
  min-width:0;
  height:34px;
}
.postal-quick-edit .order-inline-select{
  width:100%;
  min-width:0;
  height:34px;
  padding:5px 28px 5px 28px;
  font-size:10px;
  line-height:1;
}
.postal-quick-edit .status-select-icon{left:8px}
.postal-quick-edit .status-select-icon svg{width:13px;height:13px}
.postal-quick-edit .status-select-chevron{right:7px}
.postal-quick-edit .status-select-chevron svg{width:12px;height:12px}

/* Cards containing several same-phone orders use the same compact rhythm. */
.postal-match-order-card .postal-quick-edit{
  max-width:none;
  margin-top:9px;
  padding:8px 0 0;
}
.postal-match-order-card .postal-quick-edit>label{
  grid-template-columns:64px minmax(0,180px);
  justify-content:start;
}

@media(max-width:700px){
  .postal-table th:nth-child(2),.postal-table td:nth-child(2){min-width:0}
  .postal-quick-edit{max-width:none;margin-top:9px;padding:9px;border:1px solid #e4e9f1;border-radius:9px;background:#f9fbfd}
  .postal-quick-edit>label,.postal-match-order-card .postal-quick-edit>label{grid-template-columns:70px minmax(0,1fr)}
}

/* V1.1.7.9 — Automatic tracking-code sync visibility. */
.postal-tracking-sync{display:inline-flex;align-items:center;max-width:100%;margin-top:6px;padding:4px 7px;border-radius:7px;font-size:9.5px;font-weight:800;line-height:1.25;white-space:normal}
.postal-tracking-sync.synced{background:#eaf8f0;color:#177a4d}
.postal-tracking-sync.same{background:#eef5ff;color:#315c9d}
.postal-tracking-sync.conflict{background:#fff1e8;color:#a7551f}
.postal-tracking-sync-summary{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:12px 0;padding:11px 14px;border:1px solid #d7eadf;border-radius:12px;background:#f3fbf6;color:#285d42}
.postal-tracking-sync-summary>div{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.postal-tracking-sync-summary strong{font-size:12px}.postal-tracking-sync-summary span{font-size:11px}.postal-tracking-sync-summary small{font-size:10px;color:#7a5b37}
@media(max-width:700px){.postal-tracking-sync-summary{align-items:flex-start;flex-direction:column}}

/* V1.1.7.10 — Manual tracking sync button. */
.postal-tracking-sync-btn{display:inline-flex;align-items:center;justify-content:center;min-height:30px;margin-top:7px;padding:5px 10px;border:1px solid #bfd1f5;border-radius:8px;background:#edf4ff;color:#155eef;font-size:10px;font-weight:900;cursor:pointer;white-space:nowrap}
.postal-tracking-sync-btn:hover{background:#e3eeff;border-color:#9ebaf0}
.postal-tracking-sync-btn:disabled{opacity:.65;cursor:wait}
.postal-quick-edit+.postal-tracking-sync-btn{margin-top:8px}
@media(max-width:700px){.postal-tracking-sync-btn{width:100%;min-height:36px}}

/* V1.1.7.11 - Exact Excel source reference for postal reconciliation */
.postal-excel-ref{display:flex;flex-direction:column;gap:2px;margin-top:7px;padding:7px 9px;border:1px solid #dce7f7;border-radius:8px;background:#f6f9fe;max-width:300px}.postal-excel-ref small{margin:0!important;color:#71829a!important;font-size:8.5px!important;font-weight:800;text-transform:uppercase;letter-spacing:.02em}.postal-excel-ref strong{color:#244b82;font-size:9.5px;line-height:1.35;word-break:break-word}.postal-excel-ref em{color:#7b8798;font-size:8.5px;font-style:normal;line-height:1.3}.postal-excel-ref.compact{display:inline-flex;flex-direction:row;align-items:center;width:auto;max-width:280px;margin-top:5px;padding:3px 7px;border-color:#dce7f7;border-radius:999px;color:#315f98;font-size:8.5px;font-weight:800;line-height:1.25;white-space:normal}.postal-result-badge+.postal-excel-ref{margin-top:6px}@media(max-width:900px){.postal-excel-ref{max-width:none}.postal-excel-ref.compact{max-width:100%}}
