*{box-sizing:border-box}
body{margin:0;background:#F3F5F9;color:#0F172A;font-family:Inter,system-ui,sans-serif;font-size:14px;font-variant-numeric:tabular-nums;line-height:1.4}
h1{margin:0;font-size:24px}h2{margin:0;font-size:16px}h3{margin:18px 0 8px;font-size:14px;color:#1E3A8A}
p{margin:0 0 10px}
a{color:#1D4ED8}
.banner{background:#1E3A8A;color:#fff;padding:8px 16px;font-size:13px;text-align:center}
.layout{display:flex;min-height:100vh}
nav{flex:0 0 220px;background:#fff;border-right:1px solid #E2E8F0;padding:18px 12px}
.brand{display:flex;align-items:center;gap:10px;padding:0 8px 14px}
.brand b{display:block;color:#1E3A8A;font-size:15px}.brand span{font-size:12px;color:#556274}
.navlist{display:flex;flex-direction:column;gap:4px}
.navlist a{display:flex;align-items:center;justify-content:space-between;gap:8px;min-height:44px;padding:0 12px;border-radius:8px;color:#334155;text-decoration:none;font-weight:500;white-space:nowrap}
.navlist a:hover{background:#EFF4FF}
.navlist a.on{background:#1D4ED8;color:#fff}
.badge{background:#B91C1C;color:#fff;border-radius:999px;padding:2px 8px;font-size:12px;font-weight:700}
main{flex:1 1 auto;min-width:0;padding:20px 24px 40px;display:flex;flex-direction:column;gap:16px}
.topbar,.page-h{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px}
.row{display:flex;flex-wrap:wrap;align-items:center;gap:8px}.row.end{justify-content:flex-end}.top{margin-top:12px}
.col{display:flex;flex-direction:column;gap:10px}
.grid{display:grid;gap:16px}
.g2{grid-template-columns:repeat(auto-fit,minmax(min(100%,380px),1fr))}
.g3{grid-template-columns:repeat(auto-fit,minmax(min(100%,300px),1fr))}
.g4{grid-template-columns:repeat(auto-fit,minmax(min(100%,200px),1fr))}
.g13{grid-template-columns:minmax(0,1fr) minmax(0,2.4fr)}
.card{background:#fff;border:1px solid #E2E8F0;border-radius:12px;padding:16px 18px;min-width:0}
.card.flush{padding:0;overflow:hidden}
.card-h{display:flex;flex-wrap:wrap;align-items:flex-start;justify-content:space-between;gap:10px;margin-bottom:10px}
.kpi{background:#fff;border:1px solid #E2E8F0;border-radius:12px;padding:14px 18px}
.kpi-v{font-size:22px;font-weight:700}
.muted{color:#556274}.small{font-size:12px}
.blue{color:#1D4ED8}.good{color:#15803D}.warn{color:#B45309}.bad{color:#B91C1C}
.sec{margin:6px 0 0}
.scroll{overflow-x:auto}
table{width:100%;border-collapse:collapse}
th{background:#1E3A8A;color:#fff;font-size:12px;font-weight:600;text-align:left;padding:9px 10px;white-space:nowrap}
td{padding:8px 10px;border-top:1px solid #E2E8F0;vertical-align:middle}
th.r,td.r{text-align:right;white-space:nowrap}
tfoot td{background:#F1F5F9;border-top:2px solid #CBD5E1}
td.empty,.card.empty{text-align:center;color:#556274;padding:24px}
tr.row-pend td{background:#FFF7E8}tr.row-void td{color:#64748B;background:#F8FAFC}
.pill{display:inline-block;padding:2px 8px;border-radius:6px;font-size:12px;font-weight:600;color:#fff;white-space:nowrap}
.p-credit{background:#1D4ED8}.p-cash{background:#15803D}.p-member{background:#B45309}
.st{font-weight:600;white-space:nowrap}.st-ok{color:#15803D}.st-sign,.st-pay,.st-appr{color:#B45309}.st-void{color:#64748B}.st-bad{color:#B91C1C}
.btn{min-height:44px;padding:0 14px;border-radius:8px;border:1px solid #CBD5E1;background:#fff;color:#0F172A;font:inherit;font-weight:600;cursor:pointer}
.btn:hover{background:#F1F5F9}
.btn.sm{min-height:36px;padding:0 10px;font-size:13px;font-weight:500}
.btn.primary{background:#1D4ED8;border-color:#1D4ED8;color:#fff}.btn.primary:hover{background:#1E3A8A}
.btn.danger{border-color:#FCA5A5;color:#B91C1C}.btn.danger:hover{background:#FEF2F2}
.btn.wide{width:100%;text-align:left}
.btn:disabled,.switch:disabled{opacity:.5;cursor:not-allowed}
.btn:focus-visible,.switch:focus-visible,input:focus-visible,select:focus-visible,a:focus-visible,.alert:focus-visible{outline:3px solid #93C5FD;outline-offset:1px}
.fld{display:flex;flex-direction:column;gap:4px;font-size:12px;color:#556274;min-width:0}
.fld.inline{flex-direction:row;align-items:center;gap:8px}
.fld.grow{flex:1 1 220px}
input,select,textarea{height:44px;padding:0 12px;border-radius:8px;border:1px solid #CBD5E1;background:#fff;color:#0F172A;font:inherit;font-size:14px;max-width:100%}
textarea{height:auto;width:100%;padding:10px;font-family:ui-monospace,monospace;font-size:12px}
input:disabled{background:#F1F5F9;color:#64748B}
.filters{display:flex;flex-wrap:wrap;align-items:flex-end;gap:12px}
.filters .full{flex:1 1 100%}
.form-error{color:#B91C1C;font-weight:600;min-height:0}.form-error:empty{display:none}
.tabs{display:flex;flex-wrap:wrap;gap:6px}
.seg-btn{display:flex;flex-wrap:wrap;gap:6px}
.ai{display:flex;flex-wrap:wrap;align-items:flex-end;gap:12px;background:#fff;border:1px solid #E2E8F0;border-radius:12px;padding:14px 16px;margin-top:10px}
.ai-info{flex:1 1 320px;min-width:0}.ai .form-error{flex:1 1 100%}
.kv{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.4fr);gap:8px 12px}
.kv.wide{grid-template-columns:minmax(0,2fr) minmax(0,1fr)}.kv.wide b{text-align:right}
.kv span{color:#556274}.kv .tot{border-top:1px solid #CBD5E1;padding-top:8px;color:#0F172A;font-weight:700}
.bar{display:flex;align-items:center;gap:8px;min-width:120px}
.bar-t{flex:1 1 auto;height:8px;border-radius:999px;background:#E2E8F0;overflow:hidden}
.bar-f{display:block;height:8px;background:#1D4ED8}.bar-f.hi{background:#B45309}
.chart{display:flex;align-items:flex-end;gap:6px;height:200px;border-bottom:1px solid #CBD5E1;overflow-x:auto}
.col-b{flex:1 1 0;min-width:30px;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;gap:1px}
.seg{width:70%}
.legend{display:flex;flex-wrap:wrap;gap:14px;margin-top:10px;font-size:13px}
.legend i{display:inline-block;width:12px;height:12px;margin-right:6px}
.alert{display:block;text-align:left;background:#fff;border:1px solid #E2E8F0;border-radius:12px;padding:12px 14px;font:inherit;color:#0F172A;cursor:pointer;min-height:44px}
.alert:hover{border-color:#1D4ED8}
.alert b{display:block;font-size:24px}
.role{flex-wrap:nowrap;align-items:stretch}
.role-b{flex:1 1 auto;text-align:left;padding:8px 14px;display:flex;flex-direction:column;justify-content:center;border-width:2px;min-height:58px}
.role-b.on{border-color:#1D4ED8;background:#EFF4FF}
.perms{gap:0 28px}
.perm{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:48px;border-top:1px solid #E2E8F0}
.switch{display:flex;align-items:center;gap:8px;min-height:44px;border:0;background:transparent;font:inherit;font-weight:600;color:#475569;cursor:pointer}
.switch i{display:block;width:44px;height:24px;border-radius:999px;background:#94A3B8;position:relative}
.switch i::after{content:"";position:absolute;top:2px;left:2px;width:20px;height:20px;border-radius:999px;background:#fff}
.switch.on{color:#15803D}.switch.on i{background:#15803D}.switch.on i::after{left:22px}
.overlay{position:fixed;inset:0;background:rgba(15,23,42,.55);display:flex;align-items:flex-start;justify-content:center;padding:24px 12px;overflow-y:auto;z-index:20}
.modal{background:#fff;border-radius:12px;padding:20px;width:100%;max-width:640px;display:flex;flex-direction:column;gap:12px}
.modal .ai{margin-top:0;background:#F8FAFC}
.toast{position:fixed;left:50%;bottom:20px;transform:translateX(-50%);background:#0F172A;color:#fff;padding:12px 18px;border-radius:10px;max-width:calc(100% - 24px);z-index:30;font-weight:500}
.toast.bad{background:#B91C1C}
.login{min-height:100vh;display:flex;align-items:center;justify-content:center;padding:16px}
.login .card{max-width:420px;width:100%}
.report h2{margin-bottom:6px}
@media (max-width:900px){
.layout{flex-direction:column}
nav{flex:0 0 auto;border-right:0;border-bottom:1px solid #E2E8F0;padding:10px 12px}
.brand{padding-bottom:8px}
.navlist{flex-direction:row;overflow-x:auto;padding-bottom:4px}
main{padding:14px 12px 40px}
.g13{grid-template-columns:minmax(0,1fr)}
}
.linkbtn{display:inline-flex;align-items:center;text-decoration:none}
/* ---------- POS terminal ---------- */
body.pos-body{background:#0A1322}
.pos{min-height:100vh;padding:16px 20px 40px;color:#EAF0FA;display:flex;flex-direction:column;gap:14px;font-size:15px}
.pos h1,.pos h2,.pos h3{color:inherit}
.pos .row{gap:12px}
.pos-head{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px}
.pos-title{font-size:20px;font-weight:700}
.pos-muted{color:#9DB0CC;font-size:13px}
.pos-muted select,.pos-select{background:#17263F;color:#EAF0FA;border-color:#263755}
.pos-select{width:100%;height:56px;font-size:16px}
.pos-amber{color:#FCD34D}.pos-green{color:#6EE7A0}.pos-red{color:#FCA5A5}
.pos-pill{display:inline-block;padding:5px 12px;border-radius:999px;font-weight:600;font-size:13px;white-space:nowrap}
.pos-pill.on{background:#0F3D26;color:#6EE7A0}.pos-pill.off{background:#4A1414;color:#FECACA}
.pos-warn{background:#4A2E0B;color:#FDE68A;padding:12px 16px;border-radius:10px;font-weight:600}
.pos-err{background:#4A1414;color:#FECACA;padding:12px 16px;border-radius:10px;font-weight:600}
.pos-cols{display:flex;flex-wrap:wrap;gap:14px;align-items:flex-start}
.pos-grow{flex:1 1 320px;min-width:0}
.pos-stack{display:flex;flex-direction:column;gap:12px}
.pos-menu{flex:1 1 260px;max-width:340px;display:flex;flex-direction:column;gap:10px}
.pos-menu.wide{max-width:420px}
.pos-btn{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:56px;padding:10px 16px;border-radius:10px;border:1px solid #263755;background:#111D31;color:#EAF0FA;font:inherit;font-weight:600;text-align:left;text-decoration:none;cursor:pointer}
.pos-btn:hover{background:#17263F}
.pos-btn.main{background:#1D4ED8;border-color:#1D4ED8}
.pos-btn.sel{border:2px solid #3B82F6;background:#17263F}
.pos-btn.sm{min-height:44px;padding:6px 12px;font-size:14px}
.pos-btn.grow{flex:1 1 0;justify-content:center}
.pos-btn small{display:block;font-weight:400;font-size:13px;color:#9DB0CC}
.pos-btn.main small{color:#DBE7FF}
.pos-btn b{display:block;font-size:16px}
.pos-badge{background:#fff;color:#1D4ED8;border-radius:999px;padding:3px 10px;font-weight:700}
.pos-card,.pos-line{background:#111D31;border:1px solid #263755;border-radius:10px;padding:14px 16px}
.pos-line{display:flex;flex-wrap:wrap;align-items:center;gap:14px}
.pos-num{width:64px;height:64px;border-radius:8px;background:#1E3A8A;display:flex;flex-direction:column;align-items:center;justify-content:center}
.pos-num span{font-size:11px;letter-spacing:1px;color:#C7D8FF;font-weight:600}.pos-num b{font-size:26px;line-height:1}
.pos-big{font-size:18px;font-weight:700}
.pos-bar{height:8px;border-radius:999px;background:#1B2A44;overflow:hidden;margin-top:8px}
.pos-bar>span{display:block;height:8px;background:#3B82F6;transition:width .25s linear}
.pos-bar.blk{display:block}
.pos-q{width:130px}.pos-q span{display:block;font-size:12px;color:#9DB0CC}.pos-q b{font-size:26px}
.pos-start,.pos-stop{min-width:120px;height:60px;border-radius:8px;border:0;color:#fff;font:inherit;font-size:18px;font-weight:700;cursor:pointer}
.pos-start{background:#15803D}.pos-stop{background:#B91C1C}
.pos-start:disabled,.pos-stop:disabled{background:#1B2A44;color:#8FA3C2;cursor:not-allowed}
.pos-start.wide{width:100%}.pos-start.grow2{flex:2 1 0}
.pos-h2{font-size:16px;margin:4px 0 0}
.pos-table{overflow-x:auto;border:1px solid #263755;border-radius:10px;background:#111D31}
.pos-table table{min-width:1420px}
.pos-table .pos-btn.sm{white-space:nowrap}
.pos-table td{white-space:nowrap}
.pos-table th{background:#1E3A8A;color:#DBE7FF}
.pos-table td{border-top:1px solid #1F2E4A;font-size:14px}
.pos-table tr.pend td{background:#2A2113}.pos-table tr.void td{color:#8FA3C2}
.pos-label{font-size:12px;font-weight:600;color:#9DB0CC;letter-spacing:.5px;margin-bottom:8px}
.pos-plate{background:#F8FAFC;color:#0F172A;border-radius:8px;padding:6px 18px;font-size:28px;font-weight:700;letter-spacing:2px}
.pos-entry{background:#060C17;border:2px solid #3B82F6;border-radius:8px;padding:8px 16px;font-size:30px;font-weight:700;text-align:right;min-height:58px}
.pos-entry.big{font-size:40px}
.pos-keys{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:12px 0}
.pos-quick{display:flex;flex-wrap:wrap;gap:10px;margin-top:12px}
.pos-quick .pos-key{flex:1 1 90px;height:52px;font-size:17px;background:#17263F}
.pos-key{height:60px;border-radius:8px;border:1px solid #263755;background:#1B2A44;color:#EAF0FA;font:inherit;font-size:21px;font-weight:600;cursor:pointer}
.pos-key:active{background:#263755}
.pos-three{display:grid;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:12px}
.pos-three.two{grid-template-columns:repeat(auto-fit,minmax(150px,1fr))}
.pos-three span{display:block;font-size:13px;color:#9DB0CC}.pos-three b{font-size:20px}
.pos-check{margin-top:12px;padding:12px 14px;border-radius:8px;background:#17263F;color:#9DB0CC;font-weight:600}
.pos-check.good{background:#0F3D26;color:#6EE7A0}.pos-check.warn{background:#4A2E0B;color:#FCD34D}
.pos-set{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:10px 16px;align-items:center}
.pos-paper{background:#fff;color:#0F172A;border-radius:6px;padding:28px;max-width:560px;width:100%;align-self:center}
.pos-paper h2,.pos-paper h3{color:#0F172A}.pos-paper h3{margin:14px 0}
.pos-sign{display:flex;justify-content:space-between;gap:20px;margin-top:56px}
.pos-sign span{flex:1 1 0;border-top:1px solid #0F172A;padding-top:6px;font-size:12px}
.pos .toast{background:#F8FAFC;color:#0F172A}.pos-body .toast{background:#F8FAFC;color:#0F172A}.pos-body .toast.bad{background:#B91C1C;color:#fff}
.pos-btn:focus-visible,.pos-key:focus-visible,.pos-start:focus-visible,.pos-stop:focus-visible{outline:3px solid #93C5FD;outline-offset:1px}

.photo{display:block;width:100%;max-width:420px;border-radius:8px}
td .photo,.kv .photo{max-width:260px}
.photo-sm .photo{max-width:240px}
.pos-title{font-size:26px}
.pos-time{font-size:17px;gap:22px}
.pos-time small{display:block;font-size:12px;color:#9DB0CC;font-weight:400}
.pos-grow0{flex:1 1 auto;min-width:0}
.pos-menu .pos-btn{justify-content:flex-start;min-height:68px;background:#152238}
.pos-menu .pos-btn.main{background:#1D4ED8}
.pos-menu .pos-btn b{letter-spacing:.3px}
.pos-btn.blue{background:#1D4ED8;border-color:#1D4ED8;gap:8px}
.pl{background:#0E1830;border:1px solid #22304A;border-radius:6px;padding:8px 10px}
.pl-row{display:grid;grid-template-columns:96px minmax(120px,1fr) minmax(120px,1fr) minmax(130px,1.1fr) minmax(130px,1.1fr);gap:14px;align-items:center}
.pl .pos-num{width:auto;height:64px;border-radius:4px}
.pl .pos-start,.pl .pos-stop{width:100%;min-width:0;height:52px;border-radius:4px;display:flex;align-items:center;justify-content:center;gap:10px;letter-spacing:.5px}
.pl .pos-start{background:#0F7A2E}.pl .pos-stop{background:#A31212}
.pl .pos-start:disabled,.pl .pos-stop:disabled{background:#1B2A44;color:#8FA3C2}
.pl-q{text-align:center}.pl-q span{display:block;font-size:12px;color:#C3D0E4;margin-bottom:4px}
.pl-q b{display:block;font-size:24px;font-weight:600;background:#070D1A;border:1px solid #2A3A58;border-radius:4px;padding:3px 8px}
.pl-q.act b{border-color:#1D4ED8}
.pl-cap{display:flex;flex-wrap:wrap;align-items:center;gap:12px;margin-top:6px;font-size:13px;color:#9DB0CC}
.pl-cap .pos-bar{flex:1 1 120px;margin-top:0;height:6px}.pl-cap .pos-bar>span{height:6px}
.pos-link{min-height:36px;padding:0 10px;border-radius:6px;border:1px dashed #5B6F94;background:transparent;color:#C7D8FF;font:inherit;font-size:13px;cursor:pointer}
.pos-rec-h{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px}
.pos-table td.c,.pos-table th.c{text-align:center}
.nowrap{flex-wrap:nowrap;white-space:nowrap}
.dot{display:inline-block;width:12px;height:12px;border-radius:999px;background:#64748B;flex:0 0 auto}
.dot.on{background:#22C55E}.dot.off{background:#EF4444}.dot.amber{background:#F59E0B}.dot.gray{background:#64748B}
.pos-foot{display:flex;flex-wrap:wrap;align-items:center;gap:10px 28px;border-top:1px solid #22304A;padding-top:12px;margin-top:auto;font-size:14px;color:#C3D0E4}
.pos-key.sel{background:#1D4ED8;border-color:#3B82F6}
.pos-quick .pos-key.sel{background:#1D4ED8}
@media (max-width:900px){
.pos-title{font-size:20px}
.pl-row{grid-template-columns:72px 1fr 1fr}
.pl-row .pl-q{grid-column:span 1}
.pl-row .pl-q:first-of-type{grid-column:2}
.pos-menu{max-width:none}
}

.pos-white{color:#EAF0FA}
.pos-sim{display:flex;flex-wrap:wrap;align-items:center;gap:10px;border:1px dashed #5B6F94;border-radius:10px;padding:8px 14px}
.pos-select.slim{width:auto;flex:1 1 220px;height:44px;font-size:14px}
.pos-cat{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
.pos-cat .pos-key{height:56px;font-size:18px}
.pos-entry.field{display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;color:#EAF0FA;font:inherit;font-size:30px;font-weight:700;cursor:pointer;border-color:#2A3A58}
.pos-entry.field.big{font-size:40px}
.pos-entry.field.active{border-color:#3B82F6;box-shadow:0 0 0 2px rgba(59,130,246,.35)}
.pos-entry.field small{font-size:12px;font-weight:600;color:#9DB0CC;letter-spacing:.5px;text-align:left}
.pos-two{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:10px}
.pos-two label{display:flex;flex-direction:column;gap:4px}
.pos-select:disabled{opacity:.5}
.pos-camrow{display:flex;flex-wrap:wrap;align-items:center;gap:14px}
.pos-who{background:#17263F;border-radius:8px;padding:12px 14px}

.pos-sug{display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:8px}
.pos-sug .pos-btn{min-height:60px;background:#17263F}
.pos-sug .pos-btn b{font-size:20px;letter-spacing:1px}
.card:has(form[data-form="fillctl"]){grid-column:1/-1}

.modal:has(input[type="file"]){max-width:900px}

.notfinal{background:#FEF2F2;border:1px solid #FCA5A5;color:#991B1B;border-radius:10px;padding:12px 14px;margin:8px 0 4px}

.pos-table tr.pos-pick{cursor:pointer}.pos-table tr.pos-pick:hover td{background:#16284A}.pos-table tr.sel td,.pos-table tr.sel:hover td{background:#2B3F66;color:#fff;font-weight:700;border-top:2px solid #60A5FA;border-bottom:2px solid #60A5FA}.pos-table tr.sel td:first-child{box-shadow:inset 6px 0 0 #60A5FA}

.pos-search{height:44px;min-width:260px;border-radius:10px;border:1px solid #2B3F66;background:#0B1424;color:#fff;padding:0 14px;font-size:16px}
.pos-modal{position:fixed;inset:0;background:rgba(3,8,20,.72);display:flex;align-items:center;justify-content:center;padding:16px;z-index:50}.pos-modal .pos-card{max-width:720px;width:100%;max-height:90vh;overflow:auto}
.pos-card.good{border-color:#16A34A;color:#BBF7D0}

.pos-warn.pos-red{background:#7F1D1D;border-color:#F87171;color:#fff}

.co-head{display:flex;align-items:center;gap:12px;margin-bottom:6px}.co-logo{max-height:56px;max-width:140px;object-fit:contain}

.ind-row{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:10px;margin:4px 0 14px}.ind{display:flex;align-items:center;gap:10px;text-align:left;border-radius:12px;padding:10px 12px;border:1px solid #BBF7D0;background:#F0FDF4;color:#14532D;cursor:pointer;font:inherit}.ind b{font-size:22px;min-width:24px}.ind span{font-size:13px;line-height:1.25}.ind.warn{border-color:#FCD34D;background:#FFFBEB;color:#78350F}.ind.bad{border-color:#FCA5A5;background:#FEF2F2;color:#7F1D1D}.ind:hover{filter:brightness(.97)}

.note-plant{font-weight:700;margin-top:2px}
.imp-cust td { background: #F1F5F9; border-top: 2px solid #CBD5E1; }
.imp-truck td:first-child { padding-left: 28px; }
.imp-issues { margin: 8px 0 0; padding-left: 20px; max-height: 180px; overflow: auto; }
.pair-box { border: 2px dashed #93C5FD; border-radius: 12px; padding: 16px; text-align: center; background: #EFF6FF; }
.pair-code { font-size: 40px; font-weight: 700; letter-spacing: 6px; font-variant-numeric: tabular-nums; color: #1E3A8A; margin: 6px 0; }
.pair-box .row { justify-content: center; }
/* Operator screens: filling lines in the upper 60% of the screen, recent deliveries below (on a 27-inch screen the last 12
   rows are always visible; the rest scroll). Everything scales with the window; each line keeps a readable minimum
   height, and on a very small window the screen scrolls instead of squeezing. Narrow windows keep the normal flow. */
@media (min-width:1000px) and (min-height:560px){
  .pos:has(> .pos-home){height:100vh;min-height:0;overflow:auto;padding-bottom:12px}
  .pos-home{--lh:clamp(70px,calc((60vh - 78px - (var(--n) - 1) * 8px) / var(--n)),118px);flex:1 1 auto;min-height:calc(var(--n) * var(--lh) + (var(--n) - 1) * 8px + 260px);display:flex;flex-direction:column;gap:10px}
  .pos-home>.pos-cols{flex:0 0 auto;flex-wrap:nowrap;align-items:flex-start}
  .pos-home .pos-menu{flex:0 1 clamp(220px,20vw,340px);gap:clamp(6px,1vh,10px)}
  .pos-home .pos-menu .pos-btn{min-height:clamp(46px,6.5vh,64px);padding-top:4px;padding-bottom:4px}
  .pos-home .pos-grow.pos-stack{display:grid;grid-template-rows:repeat(var(--n),var(--lh));gap:8px}
  .pos-home .pl{display:grid;grid-template-rows:minmax(0,1fr) 16px;row-gap:3px;min-height:0;padding:5px 10px;overflow:hidden}
  .pos-home .pl-row{min-height:0;height:100%;gap:clamp(8px,1vw,14px);grid-template-columns:clamp(56px,6vw,96px) minmax(90px,1fr) minmax(90px,1fr) minmax(100px,1.1fr) minmax(100px,1.1fr)}
  .pos-home .pl .pos-num{height:100%;max-height:64px}
  .pos-home .pl .pos-num b{font-size:clamp(18px,calc(var(--lh) * .26),26px)}
  .pos-home .pl .pos-start,.pos-home .pl .pos-stop{height:100%;max-height:56px;font-size:clamp(14px,calc(var(--lh) * .17),18px)}
  .pos-home .pl-q{display:flex;flex-direction:column;justify-content:center;height:100%;min-height:0}
  .pos-home .pl-q span{margin-bottom:2px;font-size:11px;line-height:12px;white-space:nowrap}
  .pos-home .pl-q b{flex:0 1 auto;min-height:0;font-size:clamp(16px,calc(var(--lh) * .22),24px);line-height:1.2;padding:1px 8px}
  .pos-home .pl-cap{height:16px;margin:0;font-size:12px;line-height:16px;flex-wrap:nowrap;overflow:hidden}
  .pos-home .pl-cap>span:first-child{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:45%}
  .pos-home .pl-cap .pos-link{flex:0 0 auto;min-height:0;height:16px;line-height:14px;padding:0 8px;font-size:11px;white-space:nowrap}
  .pos-home .pos-table{flex:1 1 auto;min-height:190px;overflow:auto}
  .pos-home .pos-table thead th{position:sticky;top:0;z-index:1;padding-top:6px;padding-bottom:6px}
  .pos-home .pos-table td{height:clamp(22px,calc((40vh - 165px) / 12),44px);padding-top:0;padding-bottom:0;font-size:13px}
  .pos-home .pos-table .pos-btn.sm{min-height:0;height:calc(clamp(22px,calc((40vh - 165px) / 12),44px) - 4px);padding:0 10px;font-size:13px}
  .pos-home .pos-rec-h .pos-search{height:38px}
  .pos-home .pos-rec-h .pos-btn{min-height:38px}
}
}
/* Portal V2 additions */
.modal.wide{max-width:1000px}
details{margin:6px 0}details summary{cursor:pointer;font-weight:600;padding:6px 0}
.alert{cursor:pointer}
a.btn{text-decoration:none;display:inline-flex;align-items:center;justify-content:center}
