@font-face{font-family:'Burkes Sans';font-style:normal;font-weight:400 700;font-display:swap;src:url('/fonts/inter-latin.woff2') format('woff2')}

/* A focused shared search surface, separate from pharmacy order sheets. */
.medicine-search-panel{border-top:3px solid var(--accent)}
.medicine-search-form{padding:24px 26px}
.medicine-search-form>label{font-size:1rem;font-weight:650;display:block;margin-bottom:12px}
.medicine-search-controls{display:flex;align-items:center;gap:12px}
.medicine-search-field{position:relative;flex:1;min-width:180px}
.medicine-search-field>.ui-icon{position:absolute;left:16px;top:50%;transform:translateY(-50%);color:var(--accent);pointer-events:none}
.medicine-search-field input{width:100%;padding:15px 16px 15px 46px!important;font-size:1.0625rem!important;min-height:52px;background:var(--surface-raised);border:1px solid var(--line);border-radius:12px;color:var(--ink)}
.medicine-search-form>p{font-size:.875rem;line-height:1.7;color:var(--muted);margin:14px 0 0}
.medicine-search-empty{padding:42px 24px;text-align:center;margin-top:20px}
.medicine-search-empty>.ui-icon{width:32px;height:32px;color:var(--accent);margin-bottom:10px}
.medicine-search-empty p{color:var(--muted);font-size:1rem;line-height:1.6;max-width:680px;margin:10px auto 0}
.medicine-search-count{display:flex;justify-content:space-between;gap:16px;flex-wrap:wrap;margin:22px 2px 14px;color:var(--muted);font-size:.9375rem}
.medicine-search-count p{margin:0}
.medicine-result{margin-bottom:24px;overflow:hidden}
.medicine-result-heading{display:flex;justify-content:space-between;gap:24px;align-items:flex-start;padding:22px 26px;border-bottom:1px solid var(--line)}
.medicine-result-heading h2{font-size:1.25rem;line-height:1.4;margin:0;overflow-wrap:anywhere}
.medicine-result-spec{font-size:1rem;margin:7px 0 0;color:var(--ink)}
.medicine-result-aliases{font-size:.875rem;color:var(--muted);margin:9px 0 0;line-height:1.6}
.medicine-best{background:var(--accent-soft);border:1px solid var(--line);border-radius:12px;padding:14px 18px;min-width:260px;flex-shrink:0}
.medicine-best>span{font-size:.875rem;font-weight:650;color:var(--accent)}
.medicine-best>strong{display:block;font-size:1.625rem;letter-spacing:-.035em;line-height:1.4;color:var(--ink);margin-top:5px}
.medicine-best>strong small{font-size:.875rem;letter-spacing:normal;font-weight:500;color:var(--muted)}
.medicine-best>p{font-size:.875rem;line-height:1.5;margin:7px 0 0;color:var(--muted)}
.medicine-best>.medicine-search-saving{color:var(--accent);font-weight:600}
.medicine-no-best{font-size:.9375rem;color:var(--muted);max-width:280px}
.medicine-search-table{width:100%;min-width:880px}
.medicine-search-table th{font-size:.875rem!important;line-height:1.5;white-space:normal}
.medicine-search-table td{font-size:.9375rem!important;line-height:1.5;padding-top:16px!important;padding-bottom:16px!important}
.medicine-search-table td:first-child{width:35%}
.medicine-search-table .medicine-offer-name{margin:6px 0;color:var(--ink);overflow-wrap:anywhere}
.medicine-offer-supplier{display:flex;align-items:center;gap:9px;flex-wrap:wrap}
.medicine-search-table .medicine-best-row{background:var(--accent-soft)}
.medicine-search-table .medicine-best-row td:first-child{border-left:3px solid var(--accent)}
.medicine-search-table small{display:block;font-size:.8125rem!important;line-height:1.5;color:var(--muted);margin-top:5px;white-space:normal}
.medicine-search-table .medicine-offer-warning{color:#a65c15}
.medicine-missing-supplier td{color:var(--muted);background:var(--surface-raised)}
@media(max-width:1000px){.medicine-result-heading{flex-direction:column}.medicine-best{min-width:0;width:100%;box-sizing:border-box}}
@media(max-width:650px){.medicine-search-form{padding:20px}.medicine-search-controls{flex-wrap:wrap}.medicine-search-field{flex-basis:100%}.medicine-search-controls>.btn{flex:1}.medicine-result-heading{padding:20px}.medicine-search-count{font-size:.875rem}}
@font-face{font-family:'Burkes Display';font-style:normal;font-weight:400 800;font-display:swap;src:url('/fonts/manrope-latin.woff2') format('woff2')}

:root{--font-body:'Burkes Sans',Inter,Arial,sans-serif;--font-heading:'Burkes Display','Burkes Sans',Arial,sans-serif;--ink:#193a51;--muted:#506c80;--line:#d5e3ed;--canvas:#eef4f8;--surface:#fff;--surface-raised:#f8fbfd;--accent:#087f7b;--accent-soft:#e7f5f2;--teal:var(--accent);--green:#167b67;--orange:#a86b1e;--radius:14px;--shadow-sm:0 2px 6px #132f4404,0 7px 22px #153c5305;--shadow-md:0 4px 9px #153c5306,0 12px 30px #153c5311;--shadow-lg:0 16px 40px #12384c17;color-scheme:light;font-family:var(--font-body);font-size:100%}
body{font-family:var(--font-body);font-size:1rem;line-height:1.6;background:radial-gradient(ellipse at 95% 0,#dfeff6,transparent 45%),var(--canvas);color:var(--ink);-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility}
button,input,select,textarea{font-family:var(--font-body)}
h1,h2,h3,.brand,.group-wordmark,.stat-number,.supplier-order-cost,.saved-order-value,.group-order-total strong{font-family:var(--font-heading)}
h1{font-size:2rem;line-height:1.3;letter-spacing:-.035em;font-weight:750;color:#153b53}
h2{font-size:1.1875rem;line-height:1.4;letter-spacing:-.025em;font-weight:750}
h3{line-height:1.45;font-weight:700}
.subtitle{font-size:1rem;line-height:1.65;max-width:820px;color:var(--muted)}
.eyebrow{font-size:.75rem;letter-spacing:.13em;color:#347387;font-weight:600}
.page-heading{gap:22px;margin-bottom:26px;align-items:center;padding-top:2px}
.page-heading>div{min-width:0}
main{scroll-margin-top:110px;max-width:1880px;padding:36px 38px 42px}
.ui-icon{height:1.2rem;width:1.2rem;display:inline-block;flex:none;vertical-align:middle}

/* A permanent navigation rail and an uncluttered tool bar. */
#sidebar{width:248px;background:linear-gradient(160deg,#10283f,#153b52 65%,#155064);border-right:1px solid #ffffff14;box-shadow:8px 0 28px #122e4608;padding:28px 20px 22px}
.shell{margin-left:248px}
#sidebar .brand{padding:0 7px 4px;gap:12px;font-size:1.75rem;letter-spacing:-.055em;color:#b4f0e5}
.brand-sub{font-family:var(--font-body);font-size:.75rem;letter-spacing:.16em;margin-top:5px;font-weight:500;color:#b5d4e4}
.brand-mark{width:47px;height:47px}
#sidebar .side-label{font-size:.8125rem;letter-spacing:.1em;line-height:1.5;margin:25px 12px 12px;color:#b1ccdc}
#nav{gap:4px}
#nav a,#pharmacyNav a{font-size:.9375rem;line-height:1.5;padding:9px 12px;gap:11px;border-radius:10px;position:relative;font-weight:500;transform:none}
#nav a>.ui-icon{width:19px;height:19px;color:#a0c3d7}
#nav a span:first-of-type{min-width:0}
nav a.active{background:linear-gradient(95deg,#2e6879a6,#28617252);border-color:#a1e5e328;box-shadow:inset 3px 0 #82ded1,0 4px 15px #001e301c;color:#f2fffc}
nav a.active>.ui-icon{color:#a3eee3}
nav a.active:hover{background:linear-gradient(95deg,#326f80c9,#2b697960)}
nav a:hover{background:#def6ff0b;border-color:#b0d7e221;transform:none}
#pharmacyNav .branch-dot{width:6px;height:6px;margin:0 6px 0 5px;background:#8fadc2;flex-shrink:0}
#pharmacyNav a.active .branch-dot{background:#9af0df}
.side-footer{font-size:.75rem;line-height:1.6;margin-top:32px;padding:22px 10px 0;color:#b3cedd}
.side-footer p{font-size:.75rem;color:#aac9da}.side-footer-link{font-size:.8rem}
#pendingBadge{margin-left:auto;background:#d6f4ee;color:#1c685d;min-width:21px;text-align:center;font-size:.75rem;border-radius:5px;padding:2px 5px}
.topbar{position:sticky;top:0;background:#ffffffed;border-bottom:1px solid #d7e5ee;box-shadow:0 3px 18px #16344905;backdrop-filter:blur(16px);gap:20px;padding:18px 32px;height:auto;min-height:86px}
.topbar::after{width:25%;height:2px;background:linear-gradient(90deg,#1a8f98,#1a8f9800)}
.group-wordmark{font-size:.875rem;letter-spacing:.055em;font-weight:800;color:#17677b}
.crumb{font-size:.875rem;line-height:1.5;letter-spacing:0;display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.crumb>span{margin:0!important}.crumb>span:first-of-type{color:#afc3d0}
.crumb #portalCrumb{color:#476a80}.workspace-credit{font-size:.75rem;color:#5f7889;line-height:1.4}
.topbar-context{gap:4px;flex-shrink:1}
.top-actions{gap:5px;justify-content:flex-end;flex-wrap:wrap;flex-shrink:0}
.top-actions .ghost{display:inline-flex;align-items:center;justify-content:center;gap:7px;font-size:.875rem;line-height:1.3;border:1px solid transparent;border-radius:8px;padding:9px 10px;min-height:39px;color:#45677e;font-weight:500}
.top-actions .ui-icon{height:17px;width:17px;stroke-width:1.7}
.top-actions .ghost:hover{background:#eaf4f8;border-color:#d0e5ed;color:#116f80;box-shadow:none}
.top-actions #readingControls{color:#126b75;background:#ecf7f5;border-color:#d5eae5}
.top-actions #logout{color:#f2ffff;background:#224d65;border:1px solid #224d65;padding:9px 12px;box-shadow:0 3px 9px #193c5520}
.top-actions #logout:hover{background:#176b76;border-color:#176b76;box-shadow:0 5px 13px #0e5d6f29}
.top-actions .brand-avatar{width:36px;height:36px;border-radius:10px;margin-left:4px;background:#f2f8fa;border-color:#d1e3ea}

/* Hierarchy comes from type, spacing, and useful supplier accents. */
.panel{border-color:var(--line);border-radius:15px;background:var(--surface);box-shadow:var(--shadow-sm);overflow:hidden}
.panel-head{padding:23px 25px;background:linear-gradient(95deg,var(--surface),var(--surface-raised));border-bottom-color:var(--line)}
.panel-head p{font-size:.9375rem;line-height:1.6;color:var(--muted);max-width:760px}
.panel-body{padding:26px}
.stats{gap:15px;margin-bottom:26px}
.stat{position:relative;border:1px solid #dbe7ed;border-radius:14px;padding:22px 21px 21px;background:linear-gradient(150deg,#fff,#fbfdfe);box-shadow:var(--shadow-sm);overflow:hidden}
.stat::before{height:3px;left:0;top:0;right:0;background:linear-gradient(90deg,#318b9e,#a8d7df)}
.stat::after{content:'';position:absolute;width:80px;height:80px;right:-25px;top:-30px;border:15px solid #3a92a905;border-radius:50%;pointer-events:none}
.stat-label{font-size:.8125rem;color:#536f81;font-weight:500;letter-spacing:.025em;min-height:27px;align-items:center;gap:8px}
.stat-icon{display:grid;place-items:center;height:28px;width:28px;border-radius:8px;color:#3f8398;background:#eaf4f7;flex:none;letter-spacing:0}
.stat-icon .ui-icon{height:16px;width:16px}
.stat-number{font-size:1.94rem;font-weight:750;letter-spacing:-.045em;line-height:1.3;margin-top:12px;white-space:nowrap;font-variant-numeric:tabular-nums;color:#20465f}
.stat-foot{font-size:.8125rem;color:#587083;line-height:1.6;min-height:20px;margin-top:8px}
.stat-saving{background:linear-gradient(140deg,#fff,#f2faf7);border-color:#d0e8df}
.stat-saving .stat-number{color:#13816f}.stat-saving .stat-icon{background:#e1f4eb;color:#168170}.stat-saving::before{background:linear-gradient(90deg,#249c85,#93d7c0)}
.stat:hover{box-shadow:var(--shadow-md);border-color:#b7d7e0}
.supplier-order-grid{gap:14px;padding:22px}
.supplier-order-card{border:1px solid #dde8ee;border-top:3px solid var(--supplier-accent);border-radius:12px;background:linear-gradient(150deg,#fff,#f9fcfd);padding:22px;position:relative;overflow:hidden}
.supplier-order-card h3{font-size:1rem;font-weight:750;letter-spacing:-.02em;color:var(--supplier-ink)}
.supplier-order-cost{font-size:1.75rem;font-weight:750;letter-spacing:-.045em;color:#244b62;font-variant-numeric:tabular-nums}
.supplier-order-counts{font-size:.875rem;color:#5a7384;gap:15px}.supplier-order-counts strong{font-weight:600;color:#2b5068}
.supplier-order-saving{padding-top:14px;margin-top:17px;border-top:1px solid #e4edf1;font-size:.875rem;color:#547687}
.supplier-order-saving strong{color:#1a8075}.supplier-order-lines{font-size:.8125rem;color:#567084}
.pharmacy-order-card{border-radius:15px;background:var(--surface);border-color:var(--line);box-shadow:var(--shadow-sm)}
.pharmacy-order-heading h3{font-family:var(--font-heading);font-size:1.12rem;letter-spacing:-.025em;font-weight:750}
.pharmacy-order-metrics{background:#f5f9fc;border-radius:9px;padding:16px 13px;gap:12px;margin:18px 0}
.pharmacy-order-metrics span{font-size:.875rem;color:#506d83;line-height:1.55}.pharmacy-order-metrics strong{font-size:1.25rem;color:#2f536b;margin-top:5px}
.pharmacy-supplier-orders>div{padding:11px 0}.pharmacy-supplier-orders dt{font-size:.875rem;color:#46677f}.pharmacy-supplier-orders dd{font-size:.9rem;font-weight:550;color:#294e68;font-variant-numeric:tabular-nums}.pharmacy-supplier-orders small{font-size:.75rem;color:#59758a}
.pharmacy-order-total,.pharmacy-order-savings{font-size:.9375rem;line-height:1.5}.pharmacy-order-savings strong{color:#168578}
.pharmacy-order-check{font-size:.75rem;line-height:1.65;color:#986c2a}
.group-order-total{border-radius:14px;border-color:#2a6874;background:linear-gradient(115deg,#164459,#126c72);box-shadow:0 7px 23px #1854641a;gap:22px;padding:24px 27px}
.group-order-total span{font-size:.875rem;color:#c1e1e9}.group-order-total strong{font-size:1.2rem;letter-spacing:-.015em;color:#f4fffe}.group-order-total .group-saving strong{color:#aef2d9}
.order-section-heading h2{font-size:1.2rem}.order-section-heading p{font-size:.9375rem;color:var(--muted)}
.two-col{gap:22px}
.ud-trial{border-top:3px solid var(--accent)}
.ud-trial-layout{display:grid;grid-template-columns:1fr 1fr;gap:30px}
.ud-trial-layout>div{min-width:0}.ud-trial-layout label{display:block}
.ud-install{padding:15px 18px;background:var(--surface-raised);border:1px solid var(--line);border-radius:12px;margin-bottom:16px}
.ud-install summary,.ud-report summary{cursor:pointer;font-weight:650}
.ud-install ol{padding-left:22px;line-height:1.65;margin:12px 0 0}.ud-install li+li{margin-top:9px}
.ud-install a{color:var(--accent);text-decoration:underline;text-underline-offset:3px}
.ud-install code{font-size:.82rem;overflow-wrap:anywhere}
.ud-medicine-options{max-height:310px;overflow-y:auto;border:1px solid var(--line);border-radius:12px;margin-top:12px}
.ud-trial-layout .ud-medicine-option{display:flex;align-items:flex-start;gap:12px;padding:12px 14px;cursor:pointer;margin:0;border-bottom:1px solid var(--line);font-size:.9rem}
.ud-medicine-option:last-child{border-bottom:0}.ud-medicine-option:hover{background:var(--surface-raised)}
.ud-medicine-option input{width:17px;height:17px;flex:none;margin:4px 0 0;accent-color:var(--accent)}
.ud-medicine-option strong{display:block;font-weight:600;line-height:1.45}.ud-medicine-option small{display:block;color:var(--muted);font-size:.8rem;margin-top:4px}
.ud-trial-status{padding:14px 16px;margin-top:22px;border:1px solid var(--line);border-left:3px solid var(--accent);border-radius:10px;background:var(--surface-raised);line-height:1.6;font-size:.9rem}
.ud-report{margin-top:16px}.ud-report ul{line-height:1.6;padding-left:20px}.ud-report li+li{margin-top:8px}
@media(max-width:900px){.ud-trial-layout{grid-template-columns:1fr;gap:22px}.ud-trial .panel-head{flex-wrap:wrap}}

/* The medicine sheet stays steady while the surrounding interface moves. */
.toolbar{padding:19px 23px;gap:12px;background:#f9fcfd;border-bottom-color:var(--line)}
.search{max-width:390px}.search input,.toolbar select{font-size:.9375rem;min-height:42px;border:1px solid #cfdee8;background:#fff;border-radius:9px;line-height:1.4}
.search input{padding:11px 13px}.search input::placeholder{color:#5d7689}
.search input:focus,.toolbar select:focus,label input:focus,label select:focus,label textarea:focus{border-color:#39a29d;box-shadow:0 0 0 3px #219f9412}
input[type=checkbox],input[type=radio]{accent-color:var(--accent)}
.count{font-size:.875rem;color:#567084}
.table-wrap th{font-size:.8125rem;color:#45687e;letter-spacing:.045em;font-weight:600;padding:15px 17px;background:#eff6fa}
.table-wrap thead th,.table-wrap thead th:first-child{background:#edf5f9;border-bottom-color:#d4e3ed;box-shadow:0 1px #d8e6ee}
.table-wrap td{padding-left:17px;padding-right:17px;border-bottom-color:#e6eef3;line-height:1.6;color:#385a72;background:var(--surface)}
.table-wrap td:first-child{background:var(--surface)}
.table-wrap tr:nth-child(even) td{background:#fbfdfe}
.table-wrap tr:hover td{background:#edf7fa}
.table-wrap tr:hover td:first-child{box-shadow:inset 3px 0 #329da5,1px 0 #dce8ef}
.table-wrap .product-name{font-weight:550;letter-spacing:-.01em;line-height:1.55;color:#244c65}
.table-wrap .product-id{font-size:.75rem!important;color:#59758a;letter-spacing:.015em;margin-top:4px}
.table-wrap .number{font-variant-numeric:tabular-nums lining-nums;letter-spacing:-.015em}
.table-wrap .price{color:#166f77;font-weight:650}
.table-wrap .notes-cell{color:#607e92}.table-wrap .saving-positive{color:#12816b;font-weight:550}
.quote-date{font-size:.75rem!important;color:#59758a;letter-spacing:0;line-height:1.4}.quote-date.quote-stale{color:#956926}
.sort-button{gap:7px;line-height:1.5}.sort-button span{color:#6491a7}
.input-qty{font-size:.92rem;width:80px;min-height:40px;padding:8px 10px;border-color:#dedfc5;border-radius:8px;background:#fffdf1;color:#355365;box-shadow:inset 0 1px 2px #133e5803}
.input-qty:focus{background:#fff;border-color:#279c8f;box-shadow:0 0 0 3px #209e9314}
.table-footer{font-size:.75rem;line-height:1.65;background:#fcfefe;border-top-color:var(--line);padding:16px 23px}
.order-only,.inline-label{font-size:.875rem;color:#486d85}.order-only{padding:5px 0}
.row-action{font-size:.875rem;line-height:1.4;padding:8px 11px;border-radius:8px;border:1px solid #d5e6eb;background:#f4fafb;color:#256f7f;box-shadow:none;font-weight:500}
.row-action:hover{background:#e7f3f5;border-color:#a5d2d9;color:#105d71}
.btn{font-size:.9375rem;line-height:1.45;padding:12px 18px;border-radius:9px;font-weight:600;background:linear-gradient(110deg,#087b79,#087f75);box-shadow:0 4px 11px #0f84741c;border:1px solid transparent;justify-content:center;position:relative;overflow:hidden}
.btn:hover:not(:disabled){background:linear-gradient(110deg,#066965,#087f74);box-shadow:0 6px 17px #0b776526}
.btn.secondary{background:var(--surface);border:1px solid #d0e2e9;color:#315e76;box-shadow:0 2px 5px #173c5004}
.btn.secondary:hover:not(:disabled){background:#f0f9f9;border-color:#9dcec9;color:#146c72}
.btn.small{font-size:.875rem;padding:9px 12px}
.tag{font-size:.875rem;padding:5px 9px;line-height:1.55;border:1px solid transparent;border-radius:6px;font-weight:500;background:#e9f5ef;color:#247363}
.tag[data-supplier="United Drug"]{color:#326d98;background:#edf4fb;border-color:#dce8f4}.tag[data-supplier=Uniphar]{color:#1b7a67;background:#e8f6f0;border-color:#d3e9df}.tag[data-supplier=McDowells]{color:#68518f;background:#f1edf9;border-color:#e5def2}.tag[data-supplier=iMed]{color:#92641c;background:#fff5e2;border-color:#f1e5c8}
.tag.gray{color:#526d7c;background:#edf3f6;border-color:#dce8ef}.tag.red{color:#a74834;background:#fff0eb;border-color:#f0d7ce}
.tag.amber,.tag.planned{color:#906323;background:#fff6e5;border-color:#f1e3c7}.tag.ordered{color:#326d98;border-color:#d7e8f7}.tag.received{color:#22715e;border-color:#d4eade}
.tiny,.table-sub,.review-warning{font-size:.75rem;line-height:1.55}.tiny{color:#567084}.review-warning{color:#926b2c;max-width:300px}

/* Price forms, saved orders, admin checks, and dialogs share the same finish. */
.supplier-tabs{gap:7px;padding:6px;background:#eaf1f6;border:1px solid #dae6ee;border-radius:11px;width:fit-content;max-width:100%;flex-wrap:wrap}
.supplier-tabs button{font-size:.9375rem;padding:10px 19px;background:transparent;border-color:transparent;border-radius:7px;line-height:1.4;font-weight:500;color:#5b768a}
.supplier-tabs button.active{background:#fff;color:#176b76;border-color:#d4e8e9;box-shadow:0 3px 9px #21485c0c}.supplier-tabs button:hover:not(.active){color:#1b637a;background:#f4f9fc}
.saved-order{padding:24px;border-color:#d8e6ed;border-radius:14px;background:linear-gradient(140deg,#fff,#f8fcfe);box-shadow:var(--shadow-sm)}
.saved-order-title h3{font-size:1.05rem;color:#214e69}.saved-order-value{font-size:1.8rem;line-height:1.35;font-weight:750}.saved-order-value small{font-size:.78rem;color:#667f91;line-height:1.6}.saved-order .order-saving{font-size:.9375rem;color:#178174}
.attention-stat{border-radius:12px;padding:19px;background:#fff;border-color:#d7e5ed;box-shadow:var(--shadow-sm)}.attention-stat span{font-size:.875rem;color:#57758a}.attention-stat strong{font-family:var(--font-heading);font-size:1.7rem;font-weight:750;line-height:1.3}.attention-stat.active{background:#eef8f6;border-color:#8fcac0;box-shadow:inset 0 3px #239787,0 4px 12px #173c5006}
.connection-grid article{padding:24px;background:var(--surface)}.connection-grid p{font-size:.9375rem;color:#5c788b;line-height:1.7}.connection-status{font-size:.875rem;color:#188374}.connection-status.muted{color:#647e91}
.notice{font-size:.9375rem;line-height:1.7;padding:15px 18px;border-radius:10px;border:1px solid #eedfbd;background:#fff8e9;color:#8d692c;box-shadow:0 2px 7px #66480603}
.notice.green{background:#edf8f2;border-color:#d3eade;color:#35745e}
.info-line{font-size:1rem;line-height:1.75;color:var(--muted)}
label{font-size:.875rem;font-weight:500;color:#41677d}label input,label select,label textarea{font-size:.9375rem;border-color:#ccdee8;min-height:44px;line-height:1.5;border-radius:9px;padding:11px 12px;color:var(--ink);background:var(--surface)}
label textarea{min-height:100px}.check-row{font-size:.875rem;font-weight:400;line-height:1.6;gap:10px}.check-row input{min-height:0}
.upload-box{border:1px dashed #a9c9d7;border-radius:12px;background:linear-gradient(145deg,#fbfdfe,#f0f8fa);padding:36px 25px}.upload-box h3{font-family:var(--font-heading);font-size:1.1rem;font-weight:700}.upload-box p{font-size:.9375rem;color:#617e90;line-height:1.7}.upload-icon{font-size:1.7rem;color:#348b9c}
.mini-step h3{font-size:.95rem;font-weight:700}.mini-step p{font-size:.9375rem;line-height:1.65}.step-num{width:31px;height:31px;border-color:#c8e4e4;background:#f0f9f8;color:#228179;font-size:.8rem}
.quote-item{border-color:#d9e8f0;border-radius:11px;background:var(--surface-raised);padding:17px}.quote-item strong{font-size:.92rem;line-height:1.5}.quote-item small{font-size:.78rem;line-height:1.6}.price-preview{padding:18px 20px;background:#edf8f5;border-color:#cce8dd;border-radius:11px}.price-preview strong{font-family:var(--font-heading);font-size:1.8rem;font-weight:750}.price-preview span,.price-preview p{font-size:.84rem;line-height:1.6}
.price-change .old-price{font-size:.82rem}.price-change strong{font-size:.98rem}.price-change+small{font-size:.75rem}
.quote-history summary{font-size:.9rem}.help-steps{font-size:1rem;line-height:1.8}.help-steps li{margin-bottom:17px}
dialog{background:var(--surface);color:var(--ink);width:min(720px,94vw);border:1px solid #d2e3ec;border-radius:17px;box-shadow:0 25px 100px #08273842;max-height:90dvh}
dialog::backdrop{background:#0e2c4160;backdrop-filter:blur(7px)}
.dialog-head{padding:25px 28px 23px;background:linear-gradient(110deg,var(--surface),var(--surface-raised));border-bottom-color:var(--line);gap:18px}
.dialog-head h2{font-size:1.35rem;line-height:1.4;letter-spacing:-.03em}.dialog-head .subtitle{font-size:.9375rem;line-height:1.65}.dialog-body{padding:27px 28px}
.icon-btn{display:inline-flex;align-items:center;justify-content:center;border-radius:8px;min-width:36px;min-height:36px;color:#57778c}.icon-btn .ui-icon{width:20px;height:20px}.icon-btn:hover{background:#ecf5f8;color:#176a79}
.appearance-choices,.reading-choices{border:1px solid #d6e4ed;border-radius:11px;background:#f9fcfd;padding:16px 18px 18px;margin:0 0 23px;min-width:0}
.appearance-choices legend,.reading-choices legend{font-size:.875rem;padding:0 7px;color:#4e748a;font-weight:500}
.appearance-options{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}
.appearance-options label{position:relative;display:flex;align-items:center;justify-content:center;gap:9px;padding:15px 12px;border:1px solid #d5e3ec;background:#fff;border-radius:9px;font-size:.875rem;color:#59778c;cursor:pointer}
.appearance-options input{position:absolute;width:1px;height:1px;opacity:0;min-height:0;margin:0;padding:0}
.appearance-options label:has(input:checked){background:#eaf7f3;color:#137566;border-color:#87c4b5;box-shadow:0 2px 6px #19765407}
.appearance-options label:has(input:focus-visible){outline:3px solid #23978a;outline-offset:3px}
.motion-choice{margin-top:18px}.reading-choices .check-row{margin:5px 0}
.access-result dt{font-size:.8rem}.access-result dd{font-size:.9rem}.access-code{font-size:1rem;border-radius:10px;color:#1d5b6b;background:#eff8fa;border-color:#cce2e8}
.audit-details{font-size:.82rem;color:#37637b;background:#f1f7fa}.empty{font-size:1rem;padding:55px 25px;line-height:1.75;color:#587083}
.loading-panel p{font-size:.85rem}.loading-line{background:linear-gradient(90deg,#e8f1f6,#eff7f9,#e8f1f6)}
.footer{font-size:.75rem;line-height:1.7;color:#587083;padding:0 38px 30px;margin-top:5px}
#toast{font-size:.87rem;line-height:1.6;padding:15px 21px;border:1px solid #64b8b539;box-shadow:0 10px 28px #143b5325;background:linear-gradient(115deg,#174356,#167577);border-radius:11px;max-width:min(470px,calc(100vw - 32px))}

/* Sign-in is a compact working entrance, with the same hierarchy in every portal. */
.login-screen{min-height:100svh;padding:2rem;isolation:isolate;background:radial-gradient(ellipse at 12% 12%,#256e7e55,transparent 52%),linear-gradient(140deg,#102c43,#155665)}
.login-screen::before{display:none}
.login-card{width:100%;max-width:56rem;display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:2.5rem;padding:2.75rem;background:var(--surface);border:1px solid var(--line);border-top:3px solid var(--accent);border-radius:1.25rem;box-shadow:0 1.5rem 5rem #03162733}
.login-intro{min-width:0;padding-right:1.5rem;border-right:1px solid var(--line)}
.login-brand{margin:0 0 2rem;color:var(--ink);font-size:2rem;letter-spacing:-.05em}
.login-brand .brand-sub{font-size:.75rem;color:var(--muted);letter-spacing:.16em}
.login-brand .brand-mark{width:3rem;height:3rem}
.login-card h1{font-size:1.9rem;line-height:1.3;letter-spacing:-.04em;margin:0 0 1rem;overflow-wrap:normal}
.login-card .eyebrow{font-size:.75rem;letter-spacing:.1em;margin:0 0 .6rem;color:var(--accent)}
.login-card .subtitle{font-size:1rem;line-height:1.65;color:var(--muted);margin:0;max-width:36ch}
.login-card form{margin:0;align-self:center;min-width:0}
.login-card label{font-size:.9375rem;font-weight:550;color:var(--ink);margin:0 0 1.1rem}
.login-card input{min-height:3rem;padding:.8rem .9rem;font-size:1rem;border-radius:.65rem;background:var(--surface-raised);color:var(--ink);border:1px solid var(--line)}
.login-card .btn{width:100%;min-height:3rem;margin-top:.3rem;font-size:1rem}
.login-footer{grid-column:1/-1;margin-top:-.75rem;min-width:0}
.login-foot{display:flex;justify-content:space-between;align-items:baseline;gap:1.25rem;flex-wrap:wrap;border-top:1px solid var(--line);margin:0;padding-top:1.15rem}
.login-foot a{flex:1;font-size:.9375rem;line-height:1.5;font-weight:550;color:var(--accent);margin:0;min-width:0}
.login-foot #portalSwitch{text-align:left}.login-foot #ownerSwitch{text-align:right}
.login-credit{font-size:.8125rem;line-height:1.5;color:var(--muted);margin:1rem 0 0;text-align:center}
.login-card .validation-error:empty{display:none}
.validation-error{font-size:.9375rem;color:var(--danger,#a64230);line-height:1.6}
.signed-out #readingControls{display:none}
@media(max-width:800px){.login-screen{padding:1.25rem}.login-card{max-width:29rem;grid-template-columns:1fr;gap:1.75rem;padding:2rem}.login-intro{border:0;padding:0}.login-brand{margin-bottom:1.75rem}.login-card h1{font-size:1.75rem}.login-card .subtitle{max-width:none}.login-footer{margin-top:0}.login-foot a{font-size:.875rem}.login-card form{margin:0}}
@media(max-width:430px){.login-screen{padding:1rem}.login-card{padding:1.75rem 1.4rem;gap:1.5rem}.login-brand{font-size:1.9rem;margin-bottom:1.5rem}.login-card h1{font-size:1.65rem}.login-card .subtitle{line-height:1.6}.login-foot{gap:.75rem}.login-card label{margin-bottom:1rem}}

/* A shared workstation rhythm across purchasing, search, suppliers and records. */
#portalName{padding:12px 13px!important;margin:23px 0 16px!important;border:1px solid #b3e2ef25;border-radius:11px;background:#ffffff09;font-family:var(--font-heading);font-size:.9375rem!important;letter-spacing:-.01em!important;text-transform:none;line-height:1.5!important;color:#e4f7fc!important}
#pharmacyNav a>.ui-icon{height:18px;width:18px;color:#a6c7d8}
#pharmacyNav a.active>.ui-icon{color:#9ce9dc}
#pharmacyNav a{padding-block:10px}
.crumb #portalCrumb{font-weight:600;padding:4px 10px;border:1px solid var(--line);border-radius:7px;background:var(--surface-raised);line-height:1.4}
.topbar-context{min-width:0}
.group-wordmark{line-height:1.5}
.workspace-credit{letter-spacing:.01em}
.panel-head>div,.order-section-heading>div,.pharmacy-order-heading{min-width:0}
.panel-head h2{margin:0}
.panel-head p{margin-top:7px}
.panel-heading-small{font-size:.8125rem;line-height:1.6;font-weight:600;letter-spacing:.06em;color:var(--muted)}
.two-col>*,.supplier-grid>*,.supplier-order-grid>*,.form-grid>*{min-width:0}
.order-section-heading{align-items:center;gap:16px;flex-wrap:wrap}
.order-section-heading p{line-height:1.65}
.pharmacy-order-heading{gap:14px;align-items:flex-start}
.pharmacy-order-heading a{font-size:.875rem;line-height:1.5;border:1px solid var(--line);background:var(--surface-raised);padding:7px 10px;border-radius:8px;white-space:nowrap}
.pharmacy-order-metrics{grid-template-columns:repeat(3,minmax(0,1fr))}
.pharmacy-order-metrics strong{font-variant-numeric:tabular-nums}
.branch-row{padding:21px 25px;gap:14px;border-color:var(--line);background:var(--surface);line-height:1.5}
.branch-row:hover{background:var(--surface-raised)}
.branch-symbol{width:42px;height:42px;border-radius:11px;background:var(--accent-soft);border:1px solid var(--line);color:var(--accent);flex:none}
.branch-symbol .ui-icon{width:22px;height:22px}
.branch-name{font-family:var(--font-heading);font-size:1rem;font-weight:750;letter-spacing:-.02em;color:var(--ink)}
.branch-info{font-size:.8125rem;line-height:1.65;color:var(--muted);margin-top:5px}
.branch-row .cost{font-family:var(--font-heading);font-size:1.125rem;line-height:1.5;white-space:nowrap;font-weight:700;color:var(--ink);font-variant-numeric:tabular-nums}
.branch-row .cost small{font-family:var(--font-body);font-size:.75rem;line-height:1.5;color:var(--muted);font-weight:400}
.toolbar :is(input,select){color:var(--ink)}
.toolbar .search{flex-basis:260px}
.toolbar select{max-width:100%}
.input-qty{font-weight:600;transition:border-color .18s,box-shadow .18s}
.table-wrap{scrollbar-gutter:stable;scrollbar-color:#a7c6d7 var(--surface-raised);scroll-padding-top:55px;scroll-padding-inline-start:245px}
.table-wrap .sort-button{min-height:24px}
.table-wrap tr:focus-within td{background:var(--accent-soft)}
.table-wrap .product-name:hover{color:var(--accent);text-decoration:underline;text-underline-offset:4px}
.table-wrap .notes-cell{min-width:170px;max-width:260px;white-space:normal;line-height:1.65}
.table-wrap .unit-cost,.table-wrap .pack-choice,.pharmacy-order-table td:nth-child(2) small,.pharmacy-order-table td:nth-child(3) small{font-size:max(.8125rem,calc(var(--medicine-font,15px)*.85));line-height:1.5}
.row-buttons{align-items:center;gap:8px}
.row-buttons .row-action{min-height:36px}
.tag{font-variant-numeric:tabular-nums;letter-spacing:0}
.view-only-badge{font-size:.875rem;line-height:1.5;background:var(--accent-soft);border:1px solid var(--line);border-radius:8px;padding:8px 12px;color:var(--accent)}
.check-row input{width:17px;height:17px;flex:none}
.help-steps{padding-left:24px}
.help-steps li::marker{color:var(--accent);font-weight:700}
.ud-install ol,.ud-report ul{font-size:.9375rem}
.ud-sync-progress progress{appearance:none;height:10px;border:0;border-radius:6px;background:var(--surface-raised);overflow:hidden}
.ud-sync-progress progress::-webkit-progress-bar{background:var(--surface-raised);border-radius:6px}
.ud-sync-progress progress::-webkit-progress-value{background:var(--accent);border-radius:6px;transition:width .3s var(--ease)}
.ud-sync-progress progress::-moz-progress-bar{background:var(--accent);border-radius:6px}
.ud-sync-counts{font-size:.875rem;line-height:1.65}
.stock-indicator{font-size:.875rem;border-radius:7px;line-height:1.5;padding:5px 9px}
.ud-medicine-options{scrollbar-width:thin;scrollbar-color:#a7c6d7 var(--surface-raised)}
.ud-medicine-option:has(input:checked){background:var(--accent-soft)}
:where(a,button,input,select,textarea,summary,[tabindex]):focus-visible{outline:3px solid var(--accent);outline-offset:3px}
#sidebar :is(a,button):focus-visible{outline-color:#95e8db}
#main:focus-visible{outline:none}
.table-wrap:focus-visible{outline-offset:-3px}
.skip-link{position:fixed;left:268px;top:12px;transform:translateY(-200%);z-index:50;background:var(--surface);color:var(--ink);border:1px solid var(--accent);border-radius:8px;padding:10px 16px;font-size:.9375rem;box-shadow:var(--shadow-md)}
.skip-link:focus{transform:none}
.signed-out .skip-link{display:none}
.btn:disabled,.row-action:disabled,.ghost:disabled{cursor:wait;opacity:.55}
.login-foot{flex-wrap:wrap;row-gap:8px}
.login-foot a{border-radius:4px;font-weight:500;flex:1}
.login-foot a:hover{color:var(--accent);text-decoration:underline;text-underline-offset:4px}
.login-credit{border:0;letter-spacing:.015em}
.save-failed #saveStatus{color:#ffbeab}.save-failed .pulse{background:#ffb49c}
#toast{font-size:.9375rem}
::selection{background:#b5e5df;color:#163b51}
[data-theme=dark] ::selection{background:#397a75;color:#f1fffc}

/* Night colours are opt-in and apply to every workspace and dialog. */
:root[data-theme=dark]{color-scheme:dark;--ink:#d7e8f1;--muted:#9bb3c5;--line:#2a4355;--canvas:#102132;--surface:#172d40;--surface-raised:#1b3348;--accent:#57c9b3;--accent-soft:#1e4e50;--green:#8bddbd;--orange:#e1c68d;--white:#172d40;--soft:#213f4c;--nav:#102d42;--shadow-sm:0 3px 12px #040e1b20;--shadow-md:0 8px 28px #030d192c;--shadow-lg:0 16px 40px #030b203a}
[data-theme=dark] body{background:radial-gradient(ellipse at 100% 0,#1b3e50,transparent 45%),var(--canvas);color:var(--ink)}
[data-theme=dark] h1,[data-theme=dark] h2,[data-theme=dark] h3{color:#d9eef4}
[data-theme=dark] .eyebrow{color:#8fbccd}[data-theme=dark] .subtitle,[data-theme=dark] .info-line{color:#9db7c9}
[data-theme=dark] #sidebar{background:linear-gradient(160deg,#0b1c2f,#0f2d42 65%,#0e3d4c);border-right-color:#2b4859}
[data-theme=dark] .topbar{background:#132b3ef2;border-bottom-color:#2a4759}[data-theme=dark] .group-wordmark{color:#93d5dc}[data-theme=dark] .crumb #portalCrumb{color:#c4d8e7}[data-theme=dark] .workspace-credit{color:#8ba6ba}
[data-theme=dark] .top-actions .ghost{color:#b6cedd}[data-theme=dark] .top-actions .ghost:hover{color:#d6f9ef;background:#214459;border-color:#396271}
[data-theme=dark] .top-actions #readingControls{color:#a6e7d9;background:#1c4249;border-color:#396261}[data-theme=dark] .top-actions #logout{color:#ddf1f6;background:#2d566e;border-color:#42758c}
[data-theme=dark] .top-actions .brand-avatar{background:#254355;border-color:#3d5c6f}
[data-theme=dark] .panel,[data-theme=dark] .pharmacy-order-card{background:var(--surface);border-color:var(--line)}
[data-theme=dark] .stat,[data-theme=dark] .saved-order,[data-theme=dark] .supplier-order-card{background:linear-gradient(145deg,#193449,#182e40);border-color:#2a495b}
[data-theme=dark] .stat::before{background:linear-gradient(90deg,#48a2b4,#4b7286)}[data-theme=dark] .stat::after{border-color:#74bbd407}
[data-theme=dark] .stat-label,[data-theme=dark] .stat-foot{color:#adc3d2}[data-theme=dark] .stat-number,[data-theme=dark] .supplier-order-cost,[data-theme=dark] .saved-order-value{color:#deeff3}
[data-theme=dark] .stat-icon{background:#254c60;color:#96ccdc}[data-theme=dark] .stat-saving{background:linear-gradient(145deg,#173c42,#193448);border-color:#376054}
[data-theme=dark] .stat-saving .stat-number{color:#8bddbd}[data-theme=dark] .stat-saving .stat-icon{background:#28584f;color:#8de7c5}
[data-theme=dark] .pharmacy-order-heading h3,[data-theme=dark] .pharmacy-order-heading a,[data-theme=dark] .pharmacy-order-metrics strong,[data-theme=dark] .pharmacy-supplier-orders dd{color:#d8ebf4}
[data-theme=dark] .pharmacy-order-metrics{background:#203c50}[data-theme=dark] .pharmacy-order-metrics span,[data-theme=dark] .pharmacy-supplier-orders dt,[data-theme=dark] .pharmacy-supplier-orders small{color:#aac3d3}
[data-theme=dark] .pharmacy-supplier-orders>div+div,[data-theme=dark] .pharmacy-order-total,[data-theme=dark] .pharmacy-order-savings{border-color:#2b495a}
[data-theme=dark] .pharmacy-order-savings strong,[data-theme=dark] .saved-order .order-saving,[data-theme=dark] .supplier-order-saving strong{color:#84d9bc}
[data-theme=dark] .supplier-order-card h3{color:#c6e6ed}[data-theme=dark] .supplier-order-counts,[data-theme=dark] .supplier-order-lines,[data-theme=dark] .supplier-order-saving{color:#aac3d3}[data-theme=dark] .supplier-order-counts strong{color:#d7e7f0}[data-theme=dark] .supplier-order-saving{border-top-color:#304d5d}
[data-theme=dark] .group-order-total{background:linear-gradient(110deg,#1b4056,#175358);border-color:#366b72}

[data-theme=dark] .toolbar{background:#1a3347;border-color:#2a495b}[data-theme=dark] .search input,[data-theme=dark] .toolbar select,[data-theme=dark] label input,[data-theme=dark] label select,[data-theme=dark] label textarea{background:#152b3e;color:#cfe3ef;border-color:#38596e}[data-theme=dark] .search input::placeholder{color:#8eaabd}
[data-theme=dark] .table-wrap th,[data-theme=dark] .table-wrap thead th:first-child{background:#244359;color:#b7d2e2;border-color:#37566b;box-shadow:0 1px #37566b}
[data-theme=dark] .table-wrap td,[data-theme=dark] .table-wrap td:first-child{background:#172d40;color:#c1d5e3;border-color:#294658}
[data-theme=dark] .table-wrap td:first-child{box-shadow:1px 0 #294658}
[data-theme=dark] .table-wrap tr:nth-child(even) td{background:#1a3246}[data-theme=dark] .table-wrap tr:hover td{background:#24485b}[data-theme=dark] .table-wrap tr:hover td:first-child{box-shadow:inset 3px 0 #74cfbd,1px 0 #36586b}
[data-theme=dark] .table-wrap .product-name{color:#d1e7f0}[data-theme=dark] .table-wrap .product-id,[data-theme=dark] .quote-date,[data-theme=dark] .tiny,[data-theme=dark] .table-sub,[data-theme=dark] .count{color:#9fb9cb}
[data-theme=dark] .table-wrap .price{color:#94dcd5}[data-theme=dark] .table-wrap .saving-positive{color:#92dfbe}[data-theme=dark] .table-wrap .notes-cell{color:#a0bbce}[data-theme=dark] .quote-date.quote-stale,[data-theme=dark] .review-warning,[data-theme=dark] .pharmacy-order-check{color:#e0c188}
[data-theme=dark] .input-qty{background:#393e34;border-color:#666550;color:#eeead1}[data-theme=dark] .input-qty:focus{background:#253b3c;border-color:#71bead;color:#dcf4ee}
[data-theme=dark] .table-footer{background:#183143;border-color:#304c5d;color:#a1bbcd}[data-theme=dark] .sort-button{color:#b7d2e2}[data-theme=dark] .sort-button span{color:#90c9ce}
[data-theme=dark] .row-action{background:#203e51;color:#a7d8db;border-color:#365b6c}[data-theme=dark] .row-action:hover{background:#29576a;color:#d3faf2;border-color:#5b98a0}
[data-theme=dark] .btn{color:#effffe;background:linear-gradient(110deg,#1c716d,#197363)}[data-theme=dark] .btn.secondary{background:#203c50;color:#c3deea;border-color:#42657a}[data-theme=dark] .btn.secondary:hover{background:#285569;color:#e2faf5;border-color:#699f9f}
[data-theme=dark] .tag{background:#2c514b;color:#a1ddc5}[data-theme=dark] .tag[data-supplier="United Drug"],[data-theme=dark] .tag.ordered{background:#294a65;color:#b5d7f0;border-color:#405f79}[data-theme=dark] .tag[data-supplier=Uniphar],[data-theme=dark] .tag.received{background:#2c514b;color:#a1ddc5;border-color:#45685c}[data-theme=dark] .tag[data-supplier=McDowells]{background:#443b61;color:#d6c6f4;border-color:#5f537c}[data-theme=dark] .tag[data-supplier=iMed],[data-theme=dark] .tag.amber,[data-theme=dark] .tag.planned{background:#524931;color:#ead09c;border-color:#6a5b3d}
[data-theme=dark] .tag.gray{color:#aec7d8;background:#2d485b;border-color:#425f73}[data-theme=dark] .tag.red{color:#edb7a7;background:#523f3f;border-color:#785452}
[data-theme=dark] .supplier-tabs{background:#192f42;border-color:#304d60}[data-theme=dark] .supplier-tabs button{color:#a7c2d4}[data-theme=dark] .supplier-tabs button.active{background:#2b4d60;color:#c6efe7;border-color:#46717a}[data-theme=dark] .supplier-tabs button:hover:not(.active){background:#244156;color:#d2e8f1}
[data-theme=dark] .attention-stat{background:#1a3347;border-color:#315163}[data-theme=dark] .attention-stat span{color:#a7c0d2}[data-theme=dark] .attention-stat strong{color:#dcf1f6}[data-theme=dark] .attention-stat.active{background:#234b50;border-color:#509b8e}
[data-theme=dark] .connection-grid article{background:#172d40;border-color:#2d4a5b}[data-theme=dark] .connection-grid p,[data-theme=dark] .connection-status.muted{color:#a6bfd1}[data-theme=dark] .connection-status{color:#92dcbc}
[data-theme=dark] .notice{background:#3a3e32;color:#e5cb92;border-color:#625b3d}[data-theme=dark] .notice.green,[data-theme=dark] .intro-card,[data-theme=dark] .price-preview{background:#234941;color:#b0dec9;border-color:#396455}
[data-theme=dark] label,[data-theme=dark] .order-only,[data-theme=dark] .inline-label{color:#b3cddd}[data-theme=dark] .upload-box{background:linear-gradient(145deg,#183448,#214356);border-color:#527a8e}[data-theme=dark] .upload-box p{color:#abc6d7}[data-theme=dark] .mini-step p{color:#a1bed0}[data-theme=dark] .step-num{background:#284b4f;border-color:#456c6c;color:#ace0d3}
[data-theme=dark] .quote-item{background:#1b364b;border-color:#325367}[data-theme=dark] .quote-item small{color:#a6bfd1}[data-theme=dark] .price-preview p,[data-theme=dark] .price-preview span{color:#adcfbe}[data-theme=dark] .price-preview strong,[data-theme=dark] .price-change strong{color:#94dbc7}[data-theme=dark] .price-change .old-price{color:#9db6c8}
[data-theme=dark] dialog{border-color:#416478}[data-theme=dark] dialog::backdrop{background:#020c1b8a}[data-theme=dark] .icon-btn{color:#bad4e3}[data-theme=dark] .icon-btn:hover{background:#2b4b5e;color:#b3e8dc}
[data-theme=dark] .appearance-choices,[data-theme=dark] .reading-choices{background:#1a3347;border-color:#365367}[data-theme=dark] .appearance-choices legend,[data-theme=dark] .reading-choices legend{color:#b7d0df}[data-theme=dark] .appearance-options label{background:#203c50;color:#b4cddb;border-color:#3c5b6f}[data-theme=dark] .appearance-options label:has(input:checked){background:#2e5954;color:#b3f2dc;border-color:#65a38f}
[data-theme=dark] .access-code,[data-theme=dark] .audit-details{background:#203f53;color:#c1dfe9;border-color:#385b6e}[data-theme=dark] .access-result dt,[data-theme=dark] .access-result dd,[data-theme=dark] .empty{color:#adc6d7}[data-theme=dark] .loading-line{background:#2c4d62}
[data-theme=dark] .footer{color:#95afc0}[data-theme=dark] .login-card{background:#172e42;border-color:#335569;border-top-color:#70c8b5}[data-theme=dark] .login-brand{color:#a5e4d6}[data-theme=dark] .login-card h1{color:#e2f1f5}[data-theme=dark] .login-card .subtitle,[data-theme=dark] .login-foot,[data-theme=dark] .login-credit{color:#a1b9ca}[data-theme=dark] .login-card input{background:#1a354a;border-color:#3b5c70;color:#d4eaf3}[data-theme=dark] .login-foot{border-top-color:#2b4b5f}[data-theme=dark] .login-foot a{color:#9ccedb}[data-theme=dark] .login-card label{color:#bad2e2}[data-theme=dark] .validation-error{color:#f1b296}
[data-theme=dark] .branch-row{border-color:#2d4b5f}[data-theme=dark] .branch-row:hover{background:#244256}[data-theme=dark] .branch-name,[data-theme=dark] .branch-row .cost{color:#d0e7f2}[data-theme=dark] .branch-info,[data-theme=dark] .branch-row small{color:#a0bfd1}[data-theme=dark] .branch-symbol{background:#294e52;color:#99ddcd}
[data-theme=dark] .help-steps,[data-theme=dark] .help-steps strong,[data-theme=dark] .quote-history summary,[data-theme=dark] .monthly-order-action p{color:#b2cfdf}

[data-theme=dark] .crumb #portalCrumb{background:#203b4e;border-color:#37576b;color:#d5e9f3}
[data-theme=dark] .branch-row,[data-theme=dark] .branch-row:last-child{background:var(--surface);border-color:var(--line)}
[data-theme=dark] .branch-row:hover{background:var(--surface-raised)}
[data-theme=dark] .branch-name,[data-theme=dark] .branch-row .cost{color:var(--ink)}
[data-theme=dark] .branch-symbol{background:var(--accent-soft);color:var(--accent);border-color:var(--line)}
[data-theme=dark] .table-wrap tr:focus-within td{background:#214a50}
[data-theme=dark] .medicine-search-table .medicine-best-row td{background:#214a50}
[data-theme=dark] .medicine-search-table .medicine-missing-supplier td{background:var(--surface-raised)}
[data-theme=dark] .medicine-search-table .medicine-offer-warning{color:#f0c58a}
[data-theme=dark] .table-wrap,[data-theme=dark] .ud-medicine-options{scrollbar-color:#42667c var(--surface-raised)}
[data-theme=dark] .price-preview{background:#1c4245;border-color:#37645d;color:#c9ece1}
[data-theme=dark] .connection-grid article{border-color:var(--line)}

@keyframes refine-enter{from{opacity:.5;transform:translateY(7px)}to{opacity:1;transform:translateY(0)}}
@keyframes refine-figure{from{opacity:.5;transform:translateY(4px)}to{opacity:1;transform:translateY(0)}}
@keyframes refine-dialog{from{opacity:.55;transform:translateY(7px) scale(.988)}to{opacity:1;transform:translateY(0) scale(1)}}
@keyframes refine-refresh{to{transform:rotate(360deg)}}
@keyframes refine-shimmer{0%{background-position:100% 0}100%{background-position:-100% 0}}
@media(prefers-reduced-motion:no-preference){
 :root:not([data-motion=reduced]) :is(.btn,.row-action,.icon-btn,.top-actions .ghost,.supplier-tabs button){transition:background-color .18s var(--ease),border-color .18s var(--ease),box-shadow .18s var(--ease),color .18s var(--ease),transform .18s var(--ease)}
 :root:not([data-motion=reduced]) .btn:hover:not(:disabled){transform:translateY(-1px)}
 :root:not([data-motion=reduced]) :is(.btn,.row-action,.ghost):active:not(:disabled){transform:translateY(1px);box-shadow:none}
 :root:not([data-motion=reduced]) .btn:not(.secondary)::after{content:'';position:absolute;inset:0;background:linear-gradient(100deg,transparent 10%,#ffffff14 50%,transparent 90%);transform:translateX(-130%);pointer-events:none;transition:transform .5s var(--ease)}
 :root:not([data-motion=reduced]) .btn:not(.secondary):hover::after{transform:translateX(130%)}
 :root:not([data-motion=reduced]) :is(.stat,.pharmacy-order-card,.saved-order,.attention-stat){transition:border-color .2s var(--ease),box-shadow .2s var(--ease),transform .2s var(--ease)}
 :root:not([data-motion=reduced]) .pharmacy-order-card:hover,:root:not([data-motion=reduced]) .saved-order:hover{transform:translateY(-2px);box-shadow:var(--shadow-md);border-color:#accfdc}
 :root:not([data-motion=reduced]) nav a .ui-icon{transition:transform .2s var(--ease),color .2s var(--ease)}
 :root:not([data-motion=reduced]) nav a:hover .ui-icon{transform:translateY(-1px)}
 :root:not([data-motion=reduced]) .workspace-arrive>.page-heading,:root:not([data-motion=reduced]) .workspace-arrive>.panel,:root:not([data-motion=reduced]) .workspace-arrive>.two-col,:root:not([data-motion=reduced]) .workspace-arrive>.pharmacy-order-section{animation:refine-enter .32s var(--ease) both}
 :root:not([data-motion=reduced]) .workspace-arrive .stats>.stat{animation:refine-enter .34s var(--ease) both;animation-delay:calc(var(--enter-index,0)*22ms)}
 :root:not([data-motion=reduced]) .workspace-arrive .stat-number{animation:refine-figure .36s var(--ease) both}
 :root:not([data-motion=reduced]) .workspace-arrive .supplier-order-card{animation:refine-enter .35s var(--ease) both}
 :root:not([data-motion=reduced]) .workspace-arrive .supplier-order-card:nth-child(2){animation-delay:25ms}
 :root:not([data-motion=reduced]) .workspace-arrive .supplier-order-card:nth-child(3){animation-delay:50ms}
 :root:not([data-motion=reduced]) .workspace-arrive .supplier-order-card:nth-child(4){animation-delay:75ms}
 :root:not([data-motion=reduced]) dialog[open],:root:not([data-motion=reduced]) .login-card{animation:refine-dialog .25s var(--ease) both}
 :root:not([data-motion=reduced]) .loading-line{background-size:200% 100%;animation:refine-shimmer 1.6s linear infinite}
 :root:not([data-motion=reduced]) .top-actions #refresh:not(.is-refreshing):hover .ui-icon{transform:rotate(25deg);transition:transform .3s var(--ease)}
 :root:not([data-motion=reduced]) .top-actions #refresh.is-refreshing .ui-icon{animation:refine-refresh .8s linear infinite}
 :root:not([data-motion=reduced]) .branch-row{transition:background-color .18s var(--ease)}
 :root:not([data-motion=reduced]) .branch-symbol{transition:background-color .18s var(--ease),border-color .18s var(--ease)}
 :root:not([data-motion=reduced]) .workspace-arrive>.medicine-result{animation:refine-enter .3s var(--ease) both}
 :root:not([data-motion=reduced]) .supplier-tabs button{transition:background-color .18s var(--ease),box-shadow .18s var(--ease),color .18s var(--ease)}
}
:root[data-motion=reduced] *,:root[data-motion=reduced] *::before,:root[data-motion=reduced] *::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}

/* iPhone Home Screen windows leave room for the status bar and home indicator. */
.app-install-link{align-self:center;display:inline-flex;align-items:center;justify-content:center;font-size:.8125rem;min-height:2.75rem;padding:.4rem .65rem;margin:.25rem auto 0;background:transparent;border:0;box-shadow:none;color:var(--accent)}
.login-footer>.app-install-link,.login-card>.app-install-link{display:flex;width:max-content;max-width:100%}
@media(display-mode:standalone){
 .shell{min-height:100dvh}
 .topbar{padding-top:calc(1rem + env(safe-area-inset-top,0px));padding-left:max(1.75rem,env(safe-area-inset-left,0px));padding-right:max(1.75rem,env(safe-area-inset-right,0px))}
 #sidebar{padding-top:calc(28px + env(safe-area-inset-top,0px));padding-bottom:calc(22px + env(safe-area-inset-bottom,0px))}
 .footer{padding-bottom:calc(1.75rem + env(safe-area-inset-bottom,0px))}
 .login-screen{padding-top:max(1.25rem,env(safe-area-inset-top,0px));padding-bottom:max(1.25rem,env(safe-area-inset-bottom,0px));padding-left:max(1rem,env(safe-area-inset-left,0px));padding-right:max(1rem,env(safe-area-inset-right,0px))}
 .delivery-shell{min-height:100dvh;padding-top:calc(1.25rem + env(safe-area-inset-top,0px));padding-left:max(1rem,env(safe-area-inset-left,0px));padding-right:max(1rem,env(safe-area-inset-right,0px))}
 .app-install-link{display:none}
}
@media(display-mode:standalone) and (max-width:750px){.topbar{padding-top:calc(.85rem + env(safe-area-inset-top,0px));padding-left:max(1rem,env(safe-area-inset-left,0px));padding-right:max(1rem,env(safe-area-inset-right,0px))}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}}
@media(min-width:1700px){main{padding:40px 46px 48px}.topbar{padding-left:42px;padding-right:42px}.top-actions{gap:8px}.top-actions .ghost{padding:10px 12px}}
@media(max-width:1450px){.topbar{flex-wrap:wrap;gap:13px;min-height:88px;padding:17px 25px}.top-actions{margin-left:auto}main{padding:30px 26px}.order-stats{grid-template-columns:repeat(auto-fit,minmax(175px,1fr))}.stat{padding:20px 18px}.stat-number{font-size:1.8rem}.stat-label{font-size:.75rem}.supplier-order-grid{padding:20px;gap:12px}.supplier-order-card{padding:20px}.crumb{gap:9px}}
@media(max-width:1100px){#sidebar{width:225px;padding-left:15px;padding-right:15px}.shell{margin-left:225px}.topbar{gap:10px;min-height:92px}.top-actions{gap:3px}.top-actions .ghost{font-size:.875rem;padding:8px}.top-actions .brand-avatar{display:none}h1{font-size:1.8rem}.page-heading{align-items:flex-start}.page-heading>.row-buttons{justify-content:flex-end}.supplier-order-grid{grid-template-columns:repeat(2,1fr)}.stat-number{font-size:1.75rem}.pharmacy-order-metrics{padding:14px 12px}}
@media(max-width:750px){#sidebar{width:250px}.shell{margin-left:0}.topbar{padding:14px 15px;gap:10px;min-height:74px}.topbar-context{flex:1}.group-wordmark{font-size:.75rem}.crumb{font-size:.75rem}.top-actions{width:100%;gap:5px;justify-content:flex-end}.top-actions .ghost{font-size:.875rem;padding:8px;min-height:35px}.top-actions .ui-icon{width:16px;height:16px}.top-actions #readingControls span{display:none}.workspace-credit{display:none}main{padding:25px 16px 35px}.page-heading{flex-direction:column;gap:17px;margin-bottom:22px}h1{font-size:1.7rem}.subtitle{font-size:1rem}.stats{gap:10px}.stat{padding:18px 16px}.stat-label{font-size:.75rem}.stat-number{font-size:1.7rem}.stat-foot{font-size:.75rem}.toolbar{padding:15px;gap:9px}.search{max-width:none;flex-basis:100%}.toolbar select{font-size:.875rem;max-width:100%}.table-wrap th:first-child,.table-wrap td:first-child{min-width:190px;max-width:240px}.table-wrap td{padding-left:14px;padding-right:14px}.table-wrap .product-name{font-size:var(--medicine-font)!important}.product-table td,.pharmacy-order-table td{font-size:var(--sheet-font)!important}.supplier-order-grid{padding:16px;gap:10px}.supplier-order-card{padding:17px}.supplier-order-cost{font-size:1.55rem}.panel-head{padding:20px}.panel-body{padding:21px}.pharmacy-order-heading h3{font-size:1.05rem}.group-order-total{padding:21px;gap:17px}.group-order-total strong{font-size:1.05rem}.login-screen::before{display:none}.dialog-head{padding:23px}.dialog-body{padding:23px}.form-grid{grid-template-columns:1fr}.appearance-options{gap:7px}.appearance-options label{padding:13px 8px;font-size:.875rem}.reading-choices{margin-bottom:3px}.form-actions{flex-wrap:wrap}.footer{padding:0 18px 25px}#toast{right:16px;bottom:16px}.attention-summary{gap:10px}.attention-stat{padding:17px}}
@media(max-width:430px){.order-stats{grid-template-columns:1fr 1fr}.stat-number{font-size:1.45rem}.stat-label{font-size:.75rem}.stat-icon{width:24px;height:24px}.supplier-order-grid{grid-template-columns:1fr}.top-actions .ghost{font-size:.875rem;padding:7px}.appearance-options label .ui-icon{width:16px;height:16px}}

@media(max-width:1100px){.page-heading>.row-buttons{justify-content:flex-start}.skip-link{left:245px}.branch-row{padding:19px 20px}.supplier-order-counts{gap:12px}}
@media(max-width:750px){#nav a,#pharmacyNav a{padding-block:12px}.skip-link{left:16px}.topbar-context .crumb{gap:8px}.crumb #portalCrumb{font-size:.875rem}.top-actions .ghost{min-height:38px}.branch-row{padding:18px 20px}.branch-row .cost{font-size:1rem}.branch-name{font-size:.9375rem}.group-wordmark{font-size:.8125rem}.toolbar .search{flex-basis:100%}.order-section-heading{align-items:flex-start}.supplier-order-saving{font-size:.875rem}.pharmacy-order-metrics span{font-size:.8125rem}.table-wrap{scroll-padding-inline-start:200px}.login-foot{gap:16px}.form-actions .btn{min-height:44px}.page-heading h1{overflow-wrap:anywhere}}
@media(max-width:430px){.branch-row{gap:11px;padding:17px 16px}.branch-symbol{width:35px;height:35px}.branch-row .cost small{max-width:82px;white-space:normal}.crumb #portalCrumb{font-size:.875rem}.top-actions .ghost{padding:8px;min-height:38px}.appearance-options label{font-size:.875rem}.medicine-best{padding:14px}.supplier-order-cost{font-size:1.625rem}}

/* Catalogue progress uses the same cards and reading scale as purchasing. */
.catalogue-panel{margin-top:24px;overflow:hidden}
.catalogue-panel .eyebrow{margin:0 0 8px}
.catalogue-stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin:22px 0}
.catalogue-stats>div{padding:18px;border:1px solid var(--line,#dce7ed);border-radius:14px;background:var(--surface,#f6fafc)}
.catalogue-stats strong{display:block;font-size:1.5rem;color:var(--ink,#173b4d);font-variant-numeric:tabular-nums}
.catalogue-stats span{display:block;font-size:.87rem;margin-top:6px;line-height:1.5;color:var(--muted,#607d8c)}
.regular-table td>strong{display:block;margin-top:8px;font-variant-numeric:tabular-nums}
.regular-table td small{display:block;margin-top:5px}
.regular-table input[type=checkbox]{width:18px;height:18px;accent-color:#087c78}
.ordering-toolbar{align-items:end;flex-wrap:wrap}
.ordering-toolbar>label{min-width:200px;margin:0}
.order-list-tabs{display:flex;gap:8px;flex-wrap:wrap}
.purchasing-order-table{font-size:var(--medicine-font,.9375rem);min-width:1040px}
.purchasing-order-table td{vertical-align:top;line-height:1.5}
.purchasing-order-table td small{display:block;margin-top:6px;color:var(--muted)}
.purchasing-order-table td>strong{display:block;margin-top:8px;font-variant-numeric:tabular-nums}
.purchasing-order-table .quantity-input{width:88px;min-height:42px;text-align:center;font:inherit}
.purchasing-order-table .product-name{max-width:300px;white-space:normal}
.medtronic-comparisons{min-width:195px}
.medtronic-supplier-price{padding:0 0 10px;margin-bottom:10px;border-bottom:1px solid var(--line)}
.medtronic-supplier-price:last-child{padding-bottom:0;margin-bottom:0;border-bottom:0}
.medtronic-supplier-price strong{margin-left:8px;font-variant-numeric:tabular-nums;white-space:nowrap}
.order-instruction{display:block;max-width:250px;font-weight:600}
.supplier-switch-row td:first-child{border-left:3px solid var(--teal,#087c78)}
.ordering-totals{display:flex;gap:16px;flex-wrap:wrap;padding:22px;border-top:1px solid var(--line)}
.ordering-totals>div{flex:1;min-width:210px;display:flex;align-items:center;gap:12px;flex-wrap:wrap;background:var(--surface);padding:16px;border:1px solid var(--line);border-radius:12px}
.ordering-totals strong{margin-left:auto;font-variant-numeric:tabular-nums;font-size:1.2rem}
.ordering-totals span:last-child{flex-basis:100%;font-size:.9rem;color:var(--muted)}
.ordering-help{padding:0 22px}
.order-email-preview{white-space:pre-wrap;overflow-wrap:anywhere;font:inherit;line-height:1.6;padding:20px;border:1px solid var(--line);border-radius:12px;background:var(--surface)}
@media(max-width:1100px){.catalogue-stats{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:600px){.catalogue-stats{grid-template-columns:1fr 1fr;gap:8px}.catalogue-stats>div{padding:12px}}

/* Purchasing Hub: useful amounts and ordering areas, without target graphics. */
.purchasing-areas{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin:0 0 30px}
.purchasing-area{display:flex;align-items:center;gap:13px;padding:18px 19px;background:var(--surface);border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow-sm);min-width:0}
.purchasing-area>span:nth-child(2){min-width:0;flex:1}
.purchasing-area strong{display:block;font-family:var(--font-heading);font-size:1rem;line-height:1.5;letter-spacing:-.02em;color:var(--ink)}
.purchasing-area small{display:block;margin-top:5px;font-size:.8125rem;line-height:1.6;color:var(--muted)}
.area-icon{display:grid;place-items:center;width:40px;height:40px;flex:none;border:1px solid var(--line);border-radius:11px;background:var(--accent-soft);color:var(--accent)}
.area-arrow{font-size:1.125rem;color:var(--accent)}
.purchasing-area:hover{border-color:var(--accent);background:var(--surface-raised);box-shadow:var(--shadow-md)}
.overview-section-heading{display:flex;align-items:center;justify-content:space-between;gap:20px;margin:0 0 18px}
.overview-section-heading h2{font-size:1.1875rem}
.overview-section-heading p{margin:7px 0 0;font-size:.9375rem;color:var(--muted);line-height:1.6;max-width:840px}
.summary-caption{font-size:.8125rem;line-height:1.6;color:var(--muted);white-space:nowrap;flex:none}
.overview-breakdown{grid-template-columns:minmax(0,1.08fr) minmax(0,1fr);align-items:start;margin-bottom:28px}
.overview-breakdown .panel-head{align-items:flex-start}
.summary-table-scroll{overflow-x:auto;scrollbar-width:thin;scrollbar-color:var(--muted) var(--surface-raised)}
.pharmacy-cost-table{min-width:410px}
.pharmacy-cost-table thead th{background:var(--surface-raised);color:var(--muted);font-size:.75rem;letter-spacing:.035em;white-space:normal;line-height:1.5;padding:14px 20px;border-bottom:1px solid var(--line)}
.pharmacy-cost-table tbody th,.pharmacy-cost-table tbody td,.pharmacy-cost-table tfoot th,.pharmacy-cost-table tfoot td{padding:18px 20px;border-bottom:1px solid var(--line);background:var(--surface);color:var(--ink);font-size:.9375rem;line-height:1.5;font-weight:550;letter-spacing:0;text-transform:none;vertical-align:middle}
.pharmacy-cost-table tbody th,.pharmacy-cost-table tfoot th{white-space:normal;width:48%;text-align:left}
.pharmacy-cost-table th small{display:block;font-family:var(--font-body);font-size:.8125rem;line-height:1.6;color:var(--muted);font-weight:400;margin-top:5px}
.pharmacy-cost-table th a{display:flex;align-items:center;gap:8px;width:fit-content;font-family:var(--font-heading);font-weight:750;letter-spacing:-.015em;font-size:.9375rem}
.pharmacy-cost-table th a span{font-family:var(--font-body);color:var(--accent);font-size:.875rem;opacity:.7}
.pharmacy-cost-table th a:hover{color:var(--accent);text-decoration:underline;text-underline-offset:4px}
.pharmacy-cost-table tbody tr:hover :is(th,td){background:var(--surface-raised)}
.pharmacy-cost-table tbody td,.pharmacy-cost-table tfoot td{font-variant-numeric:tabular-nums lining-nums;font-weight:600}
.pharmacy-cost-table td.summary-saving{color:var(--green)}
.pharmacy-cost-table tfoot :is(th,td){background:var(--surface-raised);border-bottom:0;border-top:2px solid var(--line);font-weight:700}
.summary-note{font-size:.8125rem;line-height:1.7;color:var(--muted);padding:16px 20px;margin:0;border-top:1px solid var(--line)}
.overview-breakdown .supplier-order-grid{grid-template-columns:repeat(2,minmax(0,1fr));padding:20px;gap:12px}
.overview-breakdown .supplier-order-card{padding:18px 16px;background:var(--surface-raised)}
.overview-breakdown .supplier-order-card h3{font-size:.9375rem;margin-bottom:9px}
.overview-breakdown .supplier-order-cost{font-size:1.5rem;line-height:1.35}
.overview-breakdown .supplier-order-counts{font-size:.8125rem;gap:10px;margin-top:12px;flex-wrap:wrap}
.overview-breakdown .supplier-order-saving{font-size:.8125rem;padding-top:11px;margin-top:11px;line-height:1.7}
.overview-breakdown .supplier-order-lines{font-size:.8125rem;line-height:1.5;margin:7px 0 0}
.cost-breakdown{margin-top:24px}
.cost-list{margin:0;padding:0 24px}
.cost-list>div{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:18px 0;border-bottom:1px solid var(--line)}
.cost-list>div:last-child{border-bottom:0}
.cost-list dt{font-weight:600;line-height:1.5}
.cost-list dt small{display:block;color:var(--muted);font-weight:400;font-size:.8125rem;line-height:1.6;margin-top:5px}
.cost-list dd{margin:0;font-weight:650;color:var(--ink);font-variant-numeric:tabular-nums;white-space:nowrap}

/* Keep navigation, controls and monetary figures legible on pharmacy PCs. */
.supplier-order-card{--supplier-accent:#3d929b;--supplier-ink:var(--ink)}
.supplier-order-card[data-order-supplier=Pharmax]{--supplier-accent:#548db1;--supplier-ink:#285a7a}
.supplier-order-card[data-order-supplier=Clonmel]{--supplier-accent:#398c78;--supplier-ink:#246652}
.supplier-order-card[data-order-supplier=Pinewood]{--supplier-accent:#809449;--supplier-ink:#536632}
.supplier-order-card[data-order-supplier=Pharmed]{--supplier-accent:#8874af;--supplier-ink:#675180}
.tag[data-supplier=Pharmax]{color:#285a7a;background:#eaf2fa;border-color:#d7e5f1}
.tag[data-supplier=Clonmel]{color:#246652;background:#eaf5ef;border-color:#d4e7dc}
.tag[data-supplier=Pinewood]{color:#536632;background:#f1f5e8;border-color:#e0e8cd}
.tag[data-supplier=Pharmed]{color:#675180;background:#f3eef8;border-color:#e5daef}
:root .stat .stat-number{color:var(--ink)}
:root .stat-saving .stat-number{color:var(--green)}
.order-stats .stat-label{font-size:.8125rem;letter-spacing:.025em;line-height:1.5;color:var(--muted)}
.order-stats .stat-foot{font-size:.8125rem;line-height:1.6;color:var(--muted)}
.order-stats .stat-number{font-size:1.94rem;line-height:1.3}
.pharmacy-order-heading h3 a{display:inline;padding:0;border:0;background:transparent;white-space:normal;font-size:inherit;font-weight:inherit;line-height:inherit}
.pharmacy-order-heading h3 a:hover{color:var(--accent);text-decoration:underline;text-underline-offset:4px}
.nav-section-label{font-size:.6875rem;letter-spacing:.13em;font-weight:600;color:#9fbdce;padding:19px 12px 7px}
.topbar{display:grid;grid-template-columns:minmax(220px,1fr) auto;gap:16px;min-height:84px;padding:12px 28px}
.topbar .mobile{display:none}
.topbar-context .crumb{display:flex;flex-direction:column;align-items:flex-start;gap:0;font-size:.8125rem}
.topbar-context .crumb>span:first-of-type{display:none}
.topbar-context .group-wordmark{font-size:.8125rem;letter-spacing:.08em;color:var(--accent)}
.topbar-context #portalCrumb{border:0;background:transparent;padding:0;font-size:.875rem;line-height:1.65;color:var(--ink)}
.workspace-credit{font-size:.75rem;color:var(--muted)}
.top-actions{margin-left:0;gap:4px;flex-wrap:nowrap}
.top-actions .ghost{white-space:nowrap}
.top-actions .brand-avatar{display:none}
.purchasing-order-table th,.regular-table th{font-size:.8125rem;line-height:1.5;letter-spacing:.04em}
.purchasing-order-table td,.regular-table td{font-size:var(--sheet-font);line-height:1.6}
.purchasing-order-table .quantity-input{font-size:var(--medicine-font);color:var(--ink);background:var(--surface-raised);border:1px solid var(--line);border-radius:8px;padding:8px}
.purchasing-order-table .quantity-input:focus{background:var(--surface);border-color:var(--accent)}
.purchasing-order-table .order-instruction{font-size:.875rem;line-height:1.6}
.ordering-toolbar>label{font-size:.875rem}
[data-theme=dark] .topbar-context #portalCrumb{background:transparent;border:0;color:var(--ink)}
[data-theme=dark] .topbar-context .group-wordmark{color:var(--accent)}
[data-theme=dark] .overview-breakdown .supplier-order-card{background:var(--surface-raised)}
[data-theme=dark] .nav-section-label{color:#94b3c8}
[data-theme=dark] .tag[data-supplier=Pharmax]{color:#b1d5ee;background:#26465f;border-color:#3b5f7c}
[data-theme=dark] .tag[data-supplier=Clonmel]{color:#b0e0c4;background:#264d43;border-color:#3c6859}
[data-theme=dark] .tag[data-supplier=Pinewood]{color:#c8ddb0;background:#394933;border-color:#53684a}
[data-theme=dark] .tag[data-supplier=Pharmed]{color:#dbc8f0;background:#423558;border-color:#635078}
@media(prefers-reduced-motion:no-preference){
 :root:not([data-motion=reduced]) .purchasing-area{transition:background-color .18s var(--ease),border-color .18s var(--ease),box-shadow .18s var(--ease)}
 :root:not([data-motion=reduced]) .purchasing-area .area-arrow{transition:transform .18s var(--ease)}
 :root:not([data-motion=reduced]) .purchasing-area:hover .area-arrow{transform:translateX(3px)}
 :root:not([data-motion=reduced]) .workspace-arrive>.purchasing-areas{animation:refine-enter .3s var(--ease) both}
}
@media(max-width:1280px){
 .overview-breakdown{grid-template-columns:1fr}
 .overview-breakdown .supplier-order-grid{grid-template-columns:repeat(auto-fit,minmax(180px,1fr))}
 .purchasing-area{padding:16px 14px;gap:10px}.purchasing-area .area-icon{width:34px;height:34px}.purchasing-area .area-arrow{display:none}
 .top-actions #staffPortalLink span,.top-actions #priceHelp span,.top-actions #refresh span,.top-actions #backup span{display:none}
 .top-actions #staffPortalLink,.top-actions #priceHelp,.top-actions #refresh,.top-actions #backup{width:38px;padding:9px}
}
@media(max-width:950px){.purchasing-areas{grid-template-columns:1fr;gap:10px}.purchasing-area{padding:15px 18px}.purchasing-area .area-arrow{display:block}.topbar{grid-template-columns:minmax(195px,1fr) auto;padding-inline:20px}.top-actions{gap:2px}.top-actions .ghost{padding:8px}.order-stats .stat-number{font-size:1.75rem}}
@media(max-width:750px){
 .topbar{grid-template-columns:auto 1fr;gap:10px;padding:12px 16px;min-height:74px}
 .topbar .mobile{display:inline-flex}.topbar-context .group-wordmark{font-size:.8125rem}
 .top-actions{grid-column:1/-1;justify-content:flex-end;flex-wrap:wrap;width:100%;gap:5px}
 .top-actions #readingControls span{display:inline}.overview-section-heading{align-items:flex-start}.overview-section-heading>.summary-caption{display:none}
 .purchasing-areas{margin-bottom:24px}.pharmacy-cost-table :is(thead th,tbody th,tbody td,tfoot th,tfoot td){padding:16px}
 .pharmacy-cost-table{min-width:390px}.overview-breakdown .supplier-order-grid{padding:16px;grid-template-columns:repeat(2,minmax(0,1fr))}
 .order-stats .stat-label,.order-stats .stat-foot{font-size:.75rem}.order-stats .stat-number{font-size:1.7rem}.summary-note{padding:15px 16px}
}
@media(max-width:430px){.overview-breakdown .supplier-order-grid{grid-template-columns:1fr}.order-stats .stat-number{font-size:1.45rem}.top-actions .ghost{font-size:.8125rem}.cost-list{padding-inline:20px}.cost-list>div{align-items:flex-start}.overview-breakdown .panel-head{flex-wrap:wrap}}

.password-admin-table{min-width:940px}
.password-admin-table td,.password-admin-table th{font-size:.875rem}
.password-admin-table td small{display:block;font-size:.8125rem;line-height:1.6;margin-top:5px;color:var(--muted)}
.password-admin-table td code{font-size:.875rem}
.password-admin-table .password-mask{display:inline-block;letter-spacing:.12em;color:var(--muted);margin-right:12px}
.password-history{margin-top:24px}
.password-field{margin-top:18px}
.password-field input[type=checkbox]{width:18px;height:18px;min-height:0;margin:0}
.password-change-notice{border-left:3px solid var(--orange)}
.top-actions #passwordNotice{color:var(--orange);background:var(--surface-raised);border-color:var(--line)}
#passwordChangeCount{font-variant-numeric:tabular-nums;font-weight:650}
.top-actions #changePassword{width:38px;padding:9px}
.password-admin-table .row-buttons{flex-wrap:nowrap}
@media(max-width:750px){.password-history .panel-head{flex-wrap:wrap}.password-admin-table .row-buttons{flex-wrap:wrap}}
:root .medicine-live-panel{padding:1.2rem;margin-bottom:1.3rem}
.medicine-live-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem;margin-bottom:1rem}
.medicine-live-heading h2{font-size:1.1rem;margin:0 0 .4rem}
.medicine-live-heading p,.medicine-live-note,.medicine-live-install p{font-size:.875rem;line-height:1.55;color:var(--muted)}
.medicine-live-heading p{margin:0;max-width:60rem}
.medicine-live-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.8rem}
.medicine-live-source{padding:1rem;border:1px solid var(--line);border-radius:12px;background:var(--surface-raised);display:grid;grid-template-columns:1fr auto;gap:.5rem}
.medicine-live-source>strong{font-size:.95rem}
.medicine-live-source p,.medicine-live-source small,.medicine-live-source a{grid-column:1/-1;margin:0;font-size:.875rem;line-height:1.5}
.medicine-live-source p,.medicine-live-source small{color:var(--muted)}
.medicine-live-source[data-live-status=live]{border-color:#37a494}
.medicine-live-source[data-live-status=checking]{border-color:#3881b1}
.medicine-live-source[data-live-status=checking]>.badge{animation:live-price-pulse 1.5s ease-in-out infinite}
.medicine-live-install{margin-top:1rem;font-size:.875rem}
.medicine-live-install summary{cursor:pointer;font-weight:650;color:var(--ink)}
.medicine-live-note{margin:1rem 0 0}
@keyframes live-price-pulse{50%{opacity:.55}}
@media(max-width:760px){.medicine-live-grid{grid-template-columns:1fr}.medicine-live-heading{flex-direction:column}}
@media(prefers-reduced-motion:reduce){.medicine-live-source[data-live-status=checking]>.badge{animation:none}}
html[data-motion=reduced] .medicine-live-source[data-live-status=checking]>.badge{animation:none}
.prepared-rep-sheet .panel-head{border-left:3px solid var(--accent)}
.rep-source-table{min-width:720px}
.rep-source-table th{position:sticky;top:0;background:var(--surface-raised)}
.rep-source-table td:nth-child(2),.rep-source-table td:nth-child(3),.rep-source-table td:nth-child(4){white-space:nowrap;font-variant-numeric:tabular-nums}
#preparedRepImportForm{margin-top:20px}

/* Saved-list checks use three equal supplier cards on pharmacy monitors. */
.managed-connection-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
.managed-connection-grid p{min-height:0}
.connection-grid.managed-connection-grid article{border-bottom:0;display:flex;flex-direction:column}
.managed-connection-grid .row-buttons{margin-top:auto;padding-top:12px}
@media(max-width:1000px){.managed-connection-grid{grid-template-columns:1fr}.connection-grid.managed-connection-grid article{border-right:0;border-bottom:1px solid var(--line)}}

/* Summary filters use the same dimensions as the informational cards. */
.stat-action{display:block;width:100%;text-align:left;font:inherit;color:inherit;cursor:pointer}
.stat-action .stat-foot{color:var(--accent,#168170)}
.stat-action:focus-visible{outline:3px solid #309ca3;outline-offset:3px}
.stat-action:active{transform:translateY(1px)}

/* Keep everyday lists first; administration lives in one expandable menu. */
#sidebar{overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#638ba0 transparent}
#sidebar>.brand,#sidebar>#portalName,#sidebar>#nav,#sidebar>.branch-label,#sidebar>#pharmacyNav,#sidebar>.side-footer{flex-shrink:0}
.workspace-controls{margin-top:8px;padding-top:8px;border-top:1px solid #b5d4e422}
.workspace-controls>summary{display:flex;align-items:center;gap:11px;cursor:pointer;list-style:none;padding:10px 12px;border-radius:10px;font-size:.9375rem;font-weight:500;line-height:1.5;color:#d6e6e1}
.workspace-controls>summary::-webkit-details-marker{display:none}
.workspace-controls>summary>.ui-icon{width:19px;height:19px;color:#a0c3d7}
.workspace-controls>summary:hover{background:#def6ff0b}
.workspace-controls>summary:focus-visible{outline:2px solid #95e8db;outline-offset:3px}
.controls-chevron{margin-left:auto;font-size:1.1rem;line-height:1;transition:transform .18s ease}
.workspace-controls[open] .controls-chevron{transform:rotate(180deg)}
.workspace-controls.has-active-page>summary{color:#b4f0e5;background:#2e687945}
.workspace-control-links{margin:6px 0 2px 12px;border-left:1px solid #b5d4e424;padding-left:6px;display:flex;flex-direction:column;gap:3px}
#nav .workspace-control-links a{padding:8px 9px;font-size:.875rem;gap:8px}
#nav .workspace-control-links a>.ui-icon{width:17px;height:17px}
.workspace-control-links .nav-section-label{padding:11px 9px 4px;font-size:.75rem;letter-spacing:.12em}
#sidebar .branch-label{letter-spacing:.04em;margin-top:24px}
#sidebar .side-footer{border-top:1px solid #b5d4e420;margin-top:24px;padding-top:12px}
#sidebar .side-footer p{margin:0 0 8px}
.ulm-tabs{display:flex;align-items:center;gap:8px;margin-bottom:22px;padding-bottom:14px;border-bottom:1px solid var(--line)}
.ulm-tabs .btn{min-height:38px}
.overview-jumps{display:flex;flex-direction:row;gap:8px;flex-wrap:wrap;margin:0 0 24px}
.overview-jumps .row-action{padding:8px 14px;border-radius:20px;background:var(--surface);color:var(--ink)}
.overview-category{scroll-margin-top:110px;margin-bottom:26px}
.overview-category .panel-head{flex-wrap:wrap}
.overview-metrics{display:grid;grid-template-columns:repeat(auto-fit,minmax(165px,1fr));gap:18px;margin:0 0 14px}
.overview-metrics>div{border-left:3px solid var(--line);padding:4px 0 4px 16px}
.overview-metrics dt{font-size:.875rem;color:var(--muted);line-height:1.5}
.overview-metrics dd{margin:6px 0 0;font-family:var(--font-heading);font-weight:750;font-size:1.65rem;line-height:1.4;color:var(--ink);font-variant-numeric:tabular-nums}
.overview-metric-link{border:0;padding:0;background:transparent;color:var(--accent);font:inherit;text-align:left;cursor:pointer;text-underline-offset:5px}
.overview-metric-link span{font-size:1rem;vertical-align:middle}
.overview-metric-link:hover{text-decoration:underline}
.overview-category .info-line{margin:12px 0 0}
.purchasing-areas{grid-template-columns:repeat(auto-fit,minmax(200px,1fr))}
@media(max-width:750px){.overview-metrics{grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.overview-metrics dd{font-size:1.4rem}.overview-category{scroll-margin-top:180px}.purchasing-areas{grid-template-columns:1fr}}
@media(prefers-reduced-motion:reduce){.controls-chevron{transition:none}}
:root[data-motion=reduced] .controls-chevron{transition:none}

/* Supplier checks use counts and outcomes, rather than target bars. */
.pharmax-progress { display:flex; flex-direction:column; gap:.45rem; padding:1rem 1.1rem; border:1px solid var(--line); border-left:4px solid var(--accent); border-radius:12px; background:var(--accent-soft); margin-bottom:.75rem; }
.pharmax-progress strong { font-size:1.15rem; color:var(--ink); }
.pharmax-progress span { font-size:.95rem; color:var(--muted); }
.pharmax-product-results { margin:.85rem 0; }
.pharmax-product-results summary { cursor:pointer; font-weight:600; padding:.45rem 0; }
.pharmax-product-results .table-wrap { max-height:30rem; overflow:auto; margin-top:.5rem; }
.pharmax-product-results thead { position:sticky; top:0; background:var(--surface, #fff); z-index:1; }
.pharmax-check-result { display:block; font-size:.85rem; font-weight:600; line-height:1.45; color:var(--muted); }
.pharmax-check-result.check-priced { color:var(--accent); }
.pharmax-check-result.check-error { color:#a35c13; }
.pharmax-list-coverage { display:flex; flex-wrap:wrap; align-items:center; gap:.65rem; }
[data-theme="dark"] .pharmax-progress { background:rgba(42,133,129,.10); }

/* Original supplier artwork stays intact; viewports remove excess white margins. */
.supplier-brand{display:inline-flex;align-items:center;gap:.55em;max-width:100%;vertical-align:middle;text-align:left}
.supplier-brand-name{min-width:0;line-height:1.35;white-space:normal}
.supplier-logo{display:block;width:3.2em;height:1.5em;flex:0 0 3.2em;background:#fff;border:1px solid #e4e9ef;border-radius:4px;overflow:hidden;pointer-events:none}
.tag[data-supplier]{display:inline-flex;align-items:center;max-width:100%;padding:.35em .55em}
.tag .supplier-logo{width:2.8em;height:1.35em;flex-basis:2.8em}
.page-heading h1 .supplier-brand{gap:.7rem}
.page-heading h1 .supplier-logo{width:5rem;height:2.5rem;flex-basis:5rem}
.panel-head h2 .supplier-logo{width:4.5rem;height:1.8rem;flex-basis:4.5rem}
.supplier-tabs button .supplier-brand{gap:.45rem}
.supplier-tabs button .supplier-logo{width:3.4rem;height:1.55rem;flex-basis:3.4rem}
.supplier-order-card h3,.managed-connection-grid h3{min-height:2rem}
.supplier-order-card h3 .supplier-logo,.connection-grid h3 .supplier-logo,.medicine-live-source>strong .supplier-logo{width:3.5rem;height:1.7rem;flex-basis:3.5rem}
.purchasing-order-table th .supplier-brand{display:flex;align-items:center;gap:.4rem;margin-bottom:.25rem}
.purchasing-order-table th .supplier-logo{width:3.3rem;height:1.5rem;flex-basis:3.3rem}
#nav a>.supplier-logo{width:2rem;height:1.5rem;flex-basis:2rem}
.area-icon .supplier-logo{width:2.8rem;height:1.9rem;flex-basis:2.8rem}
.tag[data-supplier="United Drug"]{color:#75074e;background:#faf0f6;border-color:#eed7e5}
.tag[data-supplier=Uniphar]{color:#3047b5;background:#eef1ff;border-color:#dbe1ff}
.tag[data-supplier=Pharmed]{color:#086f98;background:#edf6fa;border-color:#d5e7f1}
.tag[data-supplier=Pinewood]{color:#073d70;background:#eef4fb;border-color:#d8e5f2}
.tag[data-supplier=Clonmel]{color:#b71845;background:#fff0f4;border-color:#f2d9e1}
.supplier-order-card[data-order-supplier="United Drug"]{--supplier-accent:#b51276;--supplier-ink:#75074e}
.supplier-order-card[data-order-supplier=Uniphar]{--supplier-accent:#3047c2;--supplier-ink:#3047b5}
.supplier-order-card[data-order-supplier=Pharmed]{--supplier-accent:#0878a4;--supplier-ink:#086f98}
.supplier-order-card[data-order-supplier=Pinewood]{--supplier-accent:#eb302b;--supplier-ink:#073d70}
.supplier-order-card[data-order-supplier=Clonmel]{--supplier-accent:#d01749;--supplier-ink:#b71845}
[data-theme=dark] .tag[data-supplier="United Drug"]{color:#f1bfdc;background:#4c2b42;border-color:#705068}
[data-theme=dark] .tag[data-supplier=Uniphar]{color:#c4ceff;background:#293655;border-color:#485d8d}
[data-theme=dark] .tag[data-supplier=Pharmed]{color:#b3dfed;background:#253f50;border-color:#3d6479}
[data-theme=dark] .tag[data-supplier=Pinewood]{color:#bfd9f2;background:#263e55;border-color:#405e79}
[data-theme=dark] .tag[data-supplier=Clonmel]{color:#f7c0d0;background:#4b3040;border-color:#765465}
@media(max-width:750px){.supplier-tabs button .supplier-logo{width:2.8rem;flex-basis:2.8rem}.page-heading h1 .supplier-logo{width:4.2rem;height:2.2rem;flex-basis:4.2rem}}

/* A consistent identity and reading rhythm across the working pages. */
.page-heading{align-items:flex-start;gap:1.5rem}
.page-heading>div:first-child{flex:1;min-width:0}
.page-heading-actions{display:flex;align-items:center;justify-content:flex-end;gap:.65rem;flex-wrap:wrap;max-width:48%;padding-top:.2rem}
.page-heading-actions>.row-buttons{margin:0;justify-content:flex-end}
.page-heading h1 .supplier-brand{flex-wrap:wrap;line-height:1.3}
.subtitle{max-width:70ch;line-height:1.7}
.pharmacy-logo{display:block;width:6rem;height:2rem;flex:0 0 6rem;background:#fff;border:1px solid #e4e9ef;border-radius:6px;overflow:hidden;pointer-events:none}
.pharmacy-logo-icon{width:2rem;height:2rem;flex-basis:2rem;padding:2px}
.page-heading .pharmacy-logo{width:8.5rem;height:2.8rem;flex-basis:8.5rem}
#pharmacyNav a{min-height:2.85rem;--branch-accent:#64c8b6}
#pharmacyNav a.active{box-shadow:inset 3px 0 var(--branch-accent)}
#pharmacyNav a[data-nav-pharmacy=poplar]{--branch-accent:#96c746}
#pharmacyNav a[data-nav-pharmacy=fairgreen]{--branch-accent:#80bde6}
#pharmacyNav a[data-nav-pharmacy=leonards-corner]{--branch-accent:#d677be}
#pharmacyNav a:is([data-nav-pharmacy=burkes-naas],[data-nav-pharmacy=kilcullen],[data-nav-pharmacy=ranelagh]){--branch-accent:#f48bab}
.branch-symbol .pharmacy-logo{width:100%;height:100%;border-radius:9px}
.pharmacy-cost-table th a,.pharmacy-order-heading h3 a{display:flex;align-items:center;gap:.65rem;line-height:1.5}
.pharmacy-cost-table th a>span{font-family:var(--font-heading);color:var(--ink);font-size:inherit;opacity:1}
.pharmacy-order-heading .pharmacy-logo{width:2.2rem;height:2.2rem;flex-basis:2.2rem}
.panel-head{gap:1.2rem;align-items:flex-start}
.panel-head>div:first-child{min-width:0}
.panel-head h2,.panel-head h3{line-height:1.45}
.panel-head p{line-height:1.65;max-width:78ch}
.nav-section-label{font-size:.75rem}
.pharmax-check-result{font-size:.875rem}
.managed-connection-grid{gap:1rem;padding:1rem;background:transparent}
.managed-connection-grid article{border:1px solid var(--line)!important;border-top:3px solid var(--connection-accent,var(--accent))!important;border-radius:12px;background:var(--surface-raised);box-shadow:0 3px 12px rgba(23,62,84,.035)}
.managed-connection-grid article[data-connection-supplier="United Drug"]{--connection-accent:#b51276}
.managed-connection-grid article[data-connection-supplier=Uniphar]{--connection-accent:#3047c2}
.managed-connection-grid article[data-connection-supplier=Pharmax]{--connection-accent:#17a89c}
.tag[data-supplier=Pharmax]{color:#08766e;background:#e9f8f5;border-color:#caeae3}
.supplier-order-card[data-order-supplier=Pharmax]{--supplier-accent:#17a89c;--supplier-ink:#08766e}
[data-theme=dark] .tag[data-supplier=Pharmax]{color:#a1e3d8;background:#254b47;border-color:#3c6c62}
.table-scroll{max-height:min(72vh,64rem);overflow:auto;overscroll-behavior:contain;scroll-padding-top:4.5rem}
.table-scroll thead th{position:sticky;top:0;z-index:3}
.table-scroll thead th:first-child{z-index:4}
.table-wrap th{font-size:.875rem;letter-spacing:.02em;line-height:1.5}
.table-wrap .product-name{font-weight:600}
.table-wrap .product-name:not(a):not(button):hover{color:var(--ink);text-decoration:none}
.table-wrap a.product-name:hover{text-decoration:underline}
.regular-price-comparison td,.purchasing-order-table td{overflow-wrap:anywhere}

/* Pharmacy lists put the product and the next order action together. */
.pharmacy-purchasing-table{min-width:0;table-layout:fixed}
.pharmacy-purchasing-table th:first-child{width:42%}
.pharmacy-purchasing-table th:nth-child(2){width:22%}
.pharmacy-purchasing-table td{padding:1rem 1.15rem}
.pharmacy-purchasing-table .product-name{max-width:none}
.order-supplier-label{display:grid;gap:.35rem;font-size:.875rem;color:var(--muted);margin-bottom:.55rem}
.order-supplier-label select{max-width:100%;width:100%;min-height:2.75rem;border:1px solid var(--line);border-radius:.5rem;padding:.5rem .65rem;background:var(--surface);color:var(--ink);font-size:.9375rem}
.order-pack-price{font-variant-numeric:tabular-nums;white-space:nowrap}
.medtronic-order-actions{display:flex;align-items:center;gap:.85rem;flex-wrap:wrap;padding:1rem 1.25rem;border-top:1px solid var(--line);background:var(--surface-raised);font-size:.9375rem}
.medtronic-order-actions>.btn:not(.secondary){margin-left:auto}
.medtronic-order-actions>small{flex-basis:100%;font-size:.875rem;color:var(--muted);line-height:1.55}
.medtronic-order-table .quantity-input{width:5rem}
.order-selected-row{background:var(--accent-soft)}
@media(max-width:760px){
 .pharmacy-purchasing-table{display:block;width:100%;min-width:0}
 .pharmacy-purchasing-table thead{display:none}
 .pharmacy-purchasing-table tbody{display:block;width:100%}
 .pharmacy-purchasing-table tbody tr{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.35fr);border-bottom:1px solid var(--line);padding:.9rem;gap:.8rem}
 .pharmacy-purchasing-table tbody td{display:block;border:0;padding:0;min-width:0}
 .pharmacy-purchasing-table tbody td:first-child{grid-column:1/-1}
 .pharmacy-purchasing-table tbody td:not(:first-child)::before{content:attr(data-label);display:block;font-size:.875rem;font-weight:600;color:var(--muted);margin-bottom:.4rem}
 .pharmacy-purchasing-table .supplier-brand{white-space:normal}
 .pharmacy-purchasing-table .empty{grid-column:1/-1;padding:1rem 0}
 .medtronic-order-actions{padding:1rem;gap:.7rem}
 .medtronic-order-actions>.btn{min-height:2.75rem}
}
@media(max-width:400px){.pharmacy-purchasing-table tbody tr{grid-template-columns:minmax(0,1fr)}.pharmacy-purchasing-table tbody td:first-child{grid-column:auto}.medtronic-order-actions>.btn:not(.secondary){margin-left:0;width:100%;justify-content:center}}
.quantity-input:focus-visible{background:var(--surface-raised);box-shadow:0 0 0 4px var(--accent-soft)}
.ud-install{border-radius:10px;overflow:hidden}
.ud-install>summary{font-size:.9375rem;line-height:1.5;min-height:2.8rem;display:list-item;align-content:center}
.ud-install[open]>summary{border-bottom:1px solid var(--line);margin-bottom:.75rem}
.row-action{line-height:1.5;text-underline-offset:4px}
.btn,.ghost,.row-action,.supplier-tabs button,.purchasing-area,.branch-row{transition:background-color .16s var(--ease),border-color .16s var(--ease),box-shadow .18s var(--ease),transform .18s var(--ease)}
.empty{padding:2.4rem 1.5rem;font-weight:450}
.validation-error:not(:empty){border-left:3px solid currentColor;padding-left:.75rem;margin-block:.65rem}
.login-card input:focus-visible{box-shadow:0 0 0 4px var(--accent-soft)}
#toast{font-size:.9375rem;line-height:1.5;max-width:min(38rem,calc(100vw - 2rem));box-shadow:0 12px 32px rgba(16,42,59,.18)}
@keyframes identity-enter{from{opacity:.5;transform:scale(.95)}to{opacity:1;transform:scale(1)}}
@keyframes supplier-check-breathe{50%{box-shadow:0 0 0 3px rgba(18,135,125,.13)}}
@media(prefers-reduced-motion:no-preference){
 :root:not([data-motion=reduced]) .workspace-arrive .page-heading :is(.supplier-logo,.pharmacy-logo){animation:identity-enter .3s var(--ease) both}
 :root:not([data-motion=reduced]) .workspace-arrive>.overview-category,:root:not([data-motion=reduced]) .workspace-arrive .managed-connection-grid article{animation:refine-enter .35s var(--ease) both}
 :root:not([data-motion=reduced]) .medicine-live-source[data-live-status=checking]>.tag{animation:supplier-check-breathe 1.7s ease-in-out infinite}
 :root:not([data-motion=reduced]) .btn:not(:disabled):hover{transform:translateY(-1px);box-shadow:0 4px 12px rgba(23,62,84,.10)}
 :root:not([data-motion=reduced]) .btn:not(:disabled):active,:root:not([data-motion=reduced]) .ghost:not(:disabled):active{transform:translateY(1px)}
 :root:not([data-motion=reduced]) .purchasing-area:hover{transform:translateY(-2px)}
}
:root[data-motion=reduced] :is(.btn,.ghost,.row-action,.supplier-tabs button,.purchasing-area,.branch-row){transition:none;transform:none}
@media(max-width:1100px){.page-heading-actions{max-width:100%;justify-content:flex-start}.page-heading-actions>.row-buttons{justify-content:flex-start}}
@media(max-width:750px){.page-heading-actions{width:100%;padding-top:0}.page-heading .pharmacy-logo{width:6.5rem;height:2.3rem;flex-basis:6.5rem}.managed-connection-grid{padding:.8rem;gap:.8rem}.table-scroll{max-height:70vh}.panel-head{flex-wrap:wrap}.panel-head .row-buttons{width:100%;justify-content:flex-start}}

/* The Pharmacy Hub uses one type, surface and interaction scale throughout. */
:root{
 --canvas:#f2f5f8;--surface:#fff;--surface-raised:#f8fafc;
 --ink:#172f45;--muted:#52677a;--line:#dce5ec;--accent:#087f78;--accent-soft:#e8f5f2;
 --danger:#aa4434;--warning:#91601e;--warning-soft:#fff5e5;
 --row-stripe:#fafcfd;--row-hover:#eff7f7;--header-surface:#f0f5f8;
 --action:#087f78;--action-hover:#066b65;--focus:#087f78;
 --shadow-sm:0 2px 10px #173b5006;--shadow-md:0 8px 24px #173b5010;
 --control-radius:.65rem;--panel-padding:1.4rem;
 --medicine-font:.9375rem;--sheet-font:.9375rem;
}
:root[data-theme=dark]{
 --canvas:#102132;--surface:#172e41;--surface-raised:#1b354a;
 --ink:#e9f1f6;--muted:#b6c8d6;--line:#355165;--accent:#85e0cf;--accent-soft:#204b4d;
 --danger:#ffb59f;--warning:#ebc58b;--warning-soft:#473b2c;
 --row-stripe:#193247;--row-hover:#244657;--header-surface:#213d52;
 --action:#146f67;--action-hover:#176f69;--focus:#85e0cf;
}
body{background:var(--canvas);line-height:1.6}
main{padding:2rem 2.25rem 2.75rem;min-width:0}
h1{font-size:clamp(1.6rem,1.3rem + .65vw,2rem);line-height:1.3;color:var(--ink)}
h2{font-size:1.2rem;line-height:1.45;color:var(--ink)}
h3{font-size:1rem;line-height:1.5;color:var(--ink)}
.eyebrow,.page-heading .eyebrow{font-size:.75rem;letter-spacing:.1em;color:var(--accent);line-height:1.6;margin-bottom:.5rem}
.subtitle{font-size:1rem;line-height:1.65;color:var(--muted);max-width:76ch}
.page-heading{margin-bottom:1.75rem;align-items:flex-start;gap:1.25rem}
.page-heading-actions{max-width:48%;gap:.5rem}
.page-heading-actions>.row-buttons{justify-content:flex-end}
.page-heading:has(>.btn)>div{flex:1;min-width:0}
.panel{border-radius:.95rem;border:1px solid var(--line);background:var(--surface);box-shadow:var(--shadow-sm)}
.panel-head{padding:1.35rem var(--panel-padding);background:var(--surface-raised);gap:1rem;align-items:center}
.panel-head p{font-size:.9375rem;line-height:1.6;color:var(--muted)}
.panel-body{padding:var(--panel-padding)}
.panel-body>.info-line:first-child{margin-top:0}
.two-col{gap:1.25rem;grid-template-columns:minmax(0,1.45fr) minmax(0,1fr)}
.two-col>*,.supplier-grid>*{min-width:0}
.btn,.btn.small,.row-action,.ghost,.tabs button,.supplier-tabs button{font-size:.9375rem;min-height:2.65rem;line-height:1.45;border-radius:var(--control-radius)}
.btn{padding:.7rem 1.05rem;font-weight:600}
.btn.small,.row-action{padding:.55rem .75rem;font-size:.875rem}
.ghost{color:var(--muted);padding:.5rem .65rem}
.btn:disabled,.row-action:disabled,.ghost:disabled{cursor:default;opacity:.55}
.icon-btn{display:inline-flex;justify-content:center;align-items:center;min-width:2.75rem;min-height:2.75rem;padding:.5rem;border-radius:.65rem;flex:none}
.row-buttons{gap:.5rem;align-items:center}
.row-buttons .row-action{white-space:normal;text-align:center}
.toolbar{padding:1.1rem var(--panel-padding);gap:.75rem;background:var(--surface-raised)}
.search{max-width:28rem;min-width:min(15rem,100%)}
.search input,.toolbar select,label input,label select,label textarea{font-size:1rem;min-height:2.75rem;padding:.65rem .8rem;line-height:1.45;border-radius:var(--control-radius);background:var(--surface);border-color:var(--line);color:var(--ink)}
label{font-size:.9375rem;line-height:1.5;color:var(--ink);font-weight:500;min-width:0}
label small{font-size:.8125rem;line-height:1.6;color:var(--muted);font-weight:400}
label textarea{line-height:1.65}
.form-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:1.15rem}
.form-actions{align-items:center;gap:.65rem;padding-top:1rem;margin-top:1.25rem;border-top:1px solid var(--line)}
.check-row{font-size:.9375rem;font-weight:450;line-height:1.55}
.check-row input{min-height:0;padding:0;width:1.1rem;height:1.1rem;border-radius:.25rem}
.tag{font-size:.875rem;line-height:1.5;white-space:normal;font-weight:550;border-radius:.45rem;max-width:100%}
.stock-indicator{font-size:.875rem;line-height:1.5;white-space:normal}
.tiny,.table-sub,.product-id,.quote-date,.table-footer,.info-line,.review-warning{font-size:.8125rem;line-height:1.6;color:var(--muted)}
.count{font-size:.9375rem;line-height:1.5;color:var(--muted)}
.info-line{font-size:.875rem}
.supplier-price small,#supplierList td small,.price-change+small,.saved-order-value small{font-size:.8125rem;line-height:1.6}
.supplier-price a,.export-label,.status-chip,.metric-pair,.public-price-check{font-size:.875rem;line-height:1.55}
#main .product-table .row-action,#main .pharmacy-order-table .row-action{font-size:.875rem;min-height:2.5rem}
#main .product-table td .tag,#main .pharmacy-order-table td .tag{font-size:.875rem;line-height:1.5}
.review-select{font-size:1rem;min-height:2.75rem;background:var(--surface);border-color:var(--line);color:var(--ink)}
.table-wrap,.hub-sheet-scroll{scrollbar-width:thin;scrollbar-color:#88adbe var(--surface-raised);border-radius:0;max-width:100%}
.table-wrap thead th,.table-wrap thead th:first-child{background:var(--header-surface);color:var(--ink);border-color:var(--line)}
.table-wrap th{font-size:.875rem!important;text-transform:none;letter-spacing:0;font-weight:650;white-space:normal;line-height:1.5;padding:.9rem 1rem}
.table-wrap td{background:var(--surface);color:var(--ink);padding:1rem;line-height:1.55;border-color:var(--line)}
.table-wrap td:first-child{background:var(--surface)}
.table-wrap tr:nth-child(even) td{background:var(--row-stripe)}
.table-wrap tr:hover td,.table-wrap tr:focus-within td{background:var(--row-hover)}
.table-wrap .medicine-best-row td,.table-wrap .medicine-best-row:nth-child(even) td{background:var(--accent-soft)}
.table-wrap .product-name{font-size:var(--medicine-font)!important;color:var(--ink);font-weight:600;line-height:1.5;letter-spacing:-.01em;max-width:30rem}
.table-wrap .product-id{font-size:.75rem!important;font-weight:400;letter-spacing:0;line-height:1.55;overflow-wrap:anywhere;max-width:28rem}
.table-wrap .number,.hub-summary-table,.hub-spending-table{font-variant-numeric:tabular-nums;letter-spacing:0}
.table-wrap .price{color:var(--accent);font-weight:650}
.table-wrap .saving-positive{color:var(--green)}
.table-wrap .notes-cell{font-size:.875rem!important;color:var(--muted)}
.table-wrap small{line-height:1.55}
.table-wrap .quote-date{font-size:.75rem!important}
.table-wrap .quote-stale,.review-warning{color:var(--warning)}
.table-footer{padding:.95rem var(--panel-padding);background:var(--surface-raised);flex-wrap:wrap;justify-content:space-between;font-size:.8125rem}
.input-qty,.quantity-input{min-height:2.65rem;border-radius:.6rem;padding:.55rem .65rem;font-weight:600;font-size:1rem!important}
.medicine-result-heading{padding:1.4rem var(--panel-padding);gap:1.25rem}
.medicine-best{min-width:15rem;padding:1rem 1.15rem;border-radius:.8rem}
.medicine-search-form{padding:var(--panel-padding)}
.medicine-search-form>p,.medicine-result-aliases{font-size:.875rem;line-height:1.6}
.medicine-live-source{border-radius:.8rem;padding:1.1rem}
.medicine-live-source>strong{font-size:1rem}
.stats{gap:.9rem;margin-bottom:1.5rem}
.stat{padding:1.2rem;border-radius:.9rem;min-width:0}
.stat-label,.order-stats .stat-label{font-size:.875rem;line-height:1.5;min-height:1.75rem;font-weight:550;letter-spacing:0;gap:.6rem}
.stat-number,.order-stats .stat-number{font-size:1.9rem;line-height:1.3;white-space:normal;overflow-wrap:anywhere}
.stat-foot,.order-stats .stat-foot{font-size:.8125rem;line-height:1.55}
.stat-icon{width:1.7rem;height:1.7rem;border-radius:.5rem}
.stat-action:hover,.attention-stat:hover{border-color:var(--accent)}
.supplier-order-grid{padding:var(--panel-padding);gap:1rem}
.supplier-order-card{padding:1.25rem;border-radius:.8rem;min-width:0}
.supplier-order-cost{font-size:1.8rem;line-height:1.4;overflow-wrap:anywhere}
.supplier-order-counts{font-size:.9375rem;line-height:1.55;flex-wrap:wrap}
.supplier-tabs,.ulm-tabs,.order-list-tabs{gap:.5rem;max-width:100%;flex-wrap:wrap}
.supplier-tabs button{padding:.6rem .8rem}
.supplier-tabs button.active,.ulm-tabs .btn:not(.secondary){box-shadow:0 2px 8px #133e5610}
.notice{font-size:.9375rem;line-height:1.65;padding:.95rem 1.1rem;border-radius:.75rem;color:var(--warning);background:var(--warning-soft);border-color:var(--line)}
.notice a{text-decoration:underline;text-underline-offset:.2em;font-weight:550}
.notice.green{background:var(--accent-soft);color:var(--ink);border-color:var(--line)}
.empty{padding:2.5rem 1.25rem;font-size:1rem;line-height:1.65;color:var(--muted)}
.loading-panel{padding:1.75rem;min-height:8rem;background:var(--surface-raised);border:1px solid var(--line);border-radius:.9rem}
.loading-panel p{font-size:.9375rem;line-height:1.65;color:var(--muted);margin-bottom:0}
.validation-error{color:var(--danger)}
.ud-trial-layout{gap:1.5rem;grid-template-columns:repeat(2,minmax(0,1fr))}
.ud-trial-layout .ud-medicine-option{font-size:.9375rem;line-height:1.5;padding:.85rem 1rem;gap:.75rem}
.ud-medicine-option small{font-size:.8125rem;line-height:1.55}
.ud-trial-status,.ud-report,.ud-install,.pharmax-progress span{font-size:.9375rem;line-height:1.65}
.ud-install{padding:1rem;border-radius:.75rem}
.ud-install>summary{font-weight:600;min-height:2.5rem}
.pharmax-product-results summary{font-size:.9375rem;line-height:1.5;padding:.6rem 0}
.connection-grid p{font-size:.9375rem;line-height:1.65}
.catalogue-stats span{font-size:.875rem;line-height:1.6}
.upload-box{padding:2rem 1.5rem;border-radius:.8rem;background:var(--surface-raised);border-color:var(--accent)}
.upload-box p{font-size:.9375rem;line-height:1.65;color:var(--muted)}
.price-preview p,.price-preview span,.quote-item small{font-size:.875rem;line-height:1.6}
.quote-item strong{font-size:1rem}
.quote-item{border-radius:.75rem;padding:1rem;align-items:flex-start}
.quote-item .quote-actions{min-width:0}
.saved-order-grid{grid-template-columns:repeat(auto-fit,minmax(min(18rem,100%),1fr))}
.help-steps{font-size:1rem;line-height:1.7;padding-left:1.35rem}
.help-steps li{margin-bottom:1rem}
dialog{max-height:calc(100svh - 2rem);width:min(44rem,calc(100vw - 2rem));background:var(--surface);border-radius:1rem;border-color:var(--line);box-shadow:var(--shadow-lg)}
.dialog-head{padding:1.4rem 1.5rem;gap:1rem;background:var(--surface-raised);position:sticky;top:0;z-index:5}
.dialog-head>div{min-width:0}.dialog-head h2{font-size:1.4rem;line-height:1.4}
.dialog-head .subtitle{font-size:.9375rem;line-height:1.6}
.dialog-body{padding:1.5rem}
.dialog-body .form-actions{flex-wrap:wrap}
.access-result dt,.audit-details{font-size:.875rem;line-height:1.65}
.footer{display:flex;flex-direction:column;align-items:center;gap:.3rem;font-size:.8125rem;line-height:1.6;color:var(--muted);text-align:center;padding:1.25rem 1.5rem 1.75rem;margin-top:auto}
.footer-brand{font-weight:550;font-size:.8125rem}
.footer-credit{font-size:.75rem;font-weight:400}
.topbar{padding:1rem 1.75rem;min-height:5.25rem;align-items:center;gap:1rem}
.topbar-context{min-width:0;gap:.25rem}
.group-wordmark{font-size:.875rem;letter-spacing:.055em;line-height:1.45;color:var(--accent)}
.crumb{gap:.65rem;font-size:.9375rem}
.crumb #portalCrumb{font-size:.9375rem;font-weight:600;border-radius:.5rem}
.top-actions{gap:.35rem;max-width:100%;flex-shrink:1}
.top-actions .ghost{font-size:.875rem;min-height:2.65rem;padding:.55rem .7rem}
.workspace-credit{font-size:.75rem;line-height:1.5;color:var(--muted)}
.workspace-clock{font-size:.875rem;line-height:1.5;margin-top:.2rem}
#nav a,#pharmacyNav a,.workspace-controls>summary{font-size:.9375rem;min-height:2.7rem;padding:.6rem .7rem;line-height:1.45}
#nav .workspace-control-links a{font-size:.875rem;min-height:2.6rem}
#sidebar .side-label{font-size:.8125rem;line-height:1.5}
.nav-section-label{font-size:.75rem;line-height:1.6;letter-spacing:.09em}
.side-footer,.side-footer p{font-size:.8125rem;line-height:1.6}
.navigation-backdrop{display:none}
[data-theme=dark] body{background:var(--canvas)}
[data-theme=dark] :is(h1,h2,h3){color:var(--ink)}
[data-theme=dark] :is(.subtitle,.tiny,.info-line,.count,.workspace-credit){color:var(--muted)}
[data-theme=dark] .login-card{background:var(--surface);border-color:var(--line);border-top-color:var(--accent)}
[data-theme=dark] .login-brand,[data-theme=dark] .login-card h1,[data-theme=dark] .login-card label{color:var(--ink)}
[data-theme=dark] .login-brand .brand-sub,[data-theme=dark] .login-card .subtitle,[data-theme=dark] .login-credit{color:var(--muted)}
[data-theme=dark] .login-foot{border-color:var(--line)}
[data-theme=dark] .login-foot a{color:var(--accent)}
[data-theme=dark] .login-card input{background:var(--surface-raised);border-color:var(--line);color:var(--ink)}
[data-theme=dark] .table-wrap :is(th,td){color:var(--ink);border-color:var(--line)}
[data-theme=dark] .table-wrap thead th,[data-theme=dark] .table-wrap thead th:first-child{background:var(--header-surface)}
[data-theme=dark] .table-wrap td,[data-theme=dark] .table-wrap td:first-child{background:var(--surface)}
[data-theme=dark] .table-wrap tr:nth-child(even) td{background:var(--row-stripe)}
[data-theme=dark] .table-wrap tr:hover td,[data-theme=dark] .table-wrap tr:focus-within td{background:var(--row-hover)}
[data-theme=dark] .table-wrap .medicine-best-row td{background:var(--accent-soft)}
[data-theme=dark] .table-wrap .product-name{color:var(--ink)}
[data-theme=dark] .table-wrap .price{color:var(--accent)}
[data-theme=dark] .table-wrap .notes-cell,[data-theme=dark] .table-footer{color:var(--muted)}
[data-theme=dark] .validation-error{color:var(--danger)}
[data-theme=dark] .notice{background:var(--warning-soft);color:var(--warning);border-color:var(--line)}
[data-theme=dark] .notice.green{background:var(--accent-soft);color:var(--ink)}
@media(min-width:1700px){main{padding:2.5rem 2.75rem 3rem}.topbar{padding-inline:2.5rem}}
@media(max-width:1150px){.two-col,.ud-trial-layout{grid-template-columns:1fr}.page-heading-actions{max-width:100%;justify-content:flex-start}.page-heading-actions>.row-buttons{justify-content:flex-start}.page-heading{flex-wrap:wrap}main{padding:1.75rem 1.5rem 2.5rem}}
@media(max-width:750px){
 main{padding:1.5rem 1rem 2rem}.page-heading{margin-bottom:1.4rem;gap:1rem;flex-direction:column}.page-heading>.btn{align-self:flex-start}
 .page-heading-actions{width:100%;padding:0}.page-heading h1{overflow-wrap:normal}
 .topbar{padding:.85rem 1rem;gap:.65rem;min-height:4.5rem;flex-wrap:wrap}.topbar-context{flex:1}.top-actions{justify-content:flex-start;width:100%;margin:0;gap:.3rem}
 .group-wordmark{font-size:.8125rem}.crumb{gap:.4rem}.crumb #portalCrumb{font-size:.875rem;padding:.3rem .5rem}
 .top-actions .ghost{font-size:.875rem;padding:.55rem .6rem;min-height:2.65rem}.top-actions #logout{margin-left:auto}.workspace-clock{font-size:.8125rem}
 #sidebar{width:min(19rem,calc(100vw - 3rem));z-index:30}.navigation-open .navigation-backdrop{display:block;position:fixed;inset:0;background:#071c2b70;backdrop-filter:blur(3px);z-index:20;border:0;padding:0;cursor:pointer}.navigation-open{overflow:hidden}
 .panel-head,.panel-body,.medicine-result-heading{--panel-padding:1.15rem}.toolbar{padding:1rem;gap:.65rem}.toolbar .search{flex-basis:100%}.toolbar :is(select,.count){max-width:100%}.count{margin-left:0}
 .table-wrap td{padding:.9rem .85rem}.table-wrap th{padding:.85rem}.table-wrap td:first-child,.table-wrap th:first-child{min-width:11rem;max-width:16rem}
 .table-wrap{scroll-padding-inline-start:11rem}.table-scroll{max-height:65svh}
 .stat-label,.order-stats .stat-label{font-size:.875rem}.stat-number,.order-stats .stat-number{font-size:1.65rem}.stat-foot{font-size:.8125rem}.stat{padding:1.05rem}.order-stats{grid-template-columns:repeat(2,minmax(0,1fr))}
 .supplier-order-grid{padding:1rem;gap:.8rem}.supplier-order-card{padding:1.1rem}.supplier-order-cost{font-size:1.65rem}
 .form-grid{grid-template-columns:1fr}.form-grid .full{grid-column:1/-1}.form-actions{flex-wrap:wrap}.form-actions .btn{white-space:normal}
 .dialog-head,.dialog-body{padding:1.25rem}.dialog-head h2{font-size:1.25rem}.dialog-head .subtitle{font-size:.9375rem}
 .quote-item{flex-wrap:wrap}.quote-actions{flex-direction:row;flex-wrap:wrap}.supplier-tabs button{padding:.55rem .7rem}
 .table-footer{gap:.5rem}.table-footer .summary-total{width:100%}.ud-medicine-options{max-height:18rem}
}
@media(max-width:430px){.top-actions #refresh span,.top-actions #priceHelp span{display:none}.top-actions #logout span{display:inline}.top-actions #logout{padding-inline:.85rem}.supplier-order-grid{grid-template-columns:1fr}.order-stats{gap:.6rem}.stat-number,.order-stats .stat-number{font-size:1.5rem}}
@media(prefers-reduced-motion:no-preference){
 :root:not([data-motion=reduced]) .workspace-arrive .hub-overview-cards .overview-hub-card,:root:not([data-motion=reduced]) .workspace-arrive .hub-branch-overview .hub-branch{animation:refine-enter .28s var(--ease) both}
 :root:not([data-motion=reduced]) .workspace-arrive .hub-overview-cards .overview-hub-card:nth-child(2){animation-delay:25ms}
 :root:not([data-motion=reduced]) .workspace-arrive .hub-overview-cards .overview-hub-card:nth-child(3){animation-delay:50ms}
 :root:not([data-motion=reduced]) .hub-activity-row{transition:background-color .18s var(--ease)}
 :root:not([data-motion=reduced]) .navigation-backdrop{animation:refine-figure .18s var(--ease) both}
}

/* A quiet operations desk: clear structure, visible controls and gentle feedback. */
.shell{min-height:100svh;display:flex;flex-direction:column}
.shell>main{flex:1;width:100%;box-sizing:border-box;align-self:center}
.topbar{background:var(--surface);border-color:var(--line);box-shadow:0 2px 12px #173b5005}
.topbar::after{display:none}
.topbar-context .crumb{gap:.25rem}
.topbar-context .group-wordmark{font-size:.8125rem;letter-spacing:.075em}
.topbar-context #portalCrumb{font-size:1rem;line-height:1.5;color:var(--ink);font-weight:650;padding:0}
.workspace-clock{font-variant-numeric:tabular-nums;color:var(--muted)}
.top-actions .ghost{border-color:transparent}
.top-actions .ghost:hover{background:var(--surface-raised);border-color:var(--line);color:var(--ink)}
.top-actions #readingControls{background:var(--accent-soft);border-color:var(--line);color:var(--accent)}
.top-actions #logout{background:#203f56;border-color:#203f56;color:#fff;box-shadow:none}
.top-actions #logout:hover{background:#172f45;border-color:#172f45;color:#fff}
#sidebar{background:linear-gradient(160deg,#122c42,#153b50);box-shadow:none}
#sidebar .side-label{letter-spacing:.025em;font-weight:500;padding-bottom:.8rem;border-bottom:1px solid #ffffff15}
#nav a:hover{background:#ffffff0b;border-color:#ffffff18}
#nav a.active{background:#2a5868;border-color:#83d8ca26;color:#fff;box-shadow:inset 3px 0 #85e0cf}
#nav a.active:hover{background:#306372}
#nav .nav-section-label{color:#b9cdd9;font-weight:600;margin-top:1.2rem}
.workspace-controls{border-top:1px solid #ffffff18;padding-top:.75rem;margin-top:1.25rem}
.workspace-control-links{border-left:1px solid #ffffff1f;margin-left:1.2rem;padding-left:.5rem}
.btn:not(.secondary){background:var(--action);border-color:var(--action);color:#fff;box-shadow:0 2px 6px #087f7810}
.btn:not(.secondary):hover:not(:disabled){background:var(--action-hover);border-color:var(--action-hover);color:#fff}
.btn.secondary{background:var(--surface);border-color:var(--line);color:var(--ink);box-shadow:none}
.btn.secondary:hover:not(:disabled){background:var(--accent-soft);border-color:var(--accent);color:var(--ink)}
.btn:not(.secondary)::after,.stat::after{content:none!important}
.row-action{border-color:var(--line);color:var(--accent);text-underline-offset:.2em}
.row-action:hover{background:var(--accent-soft);color:var(--accent)}
.stat{background:var(--surface);box-shadow:var(--shadow-sm)}
.stat::before{height:2px}
.panel-head{border-bottom-color:var(--line)}
.supplier-order-card{background:var(--surface);box-shadow:none}
.table-wrap th[scope=row]{font-weight:600}
.table-wrap td:has(.quantity-input:focus-visible){background:var(--accent-soft)}
.empty{max-width:60ch;margin-inline:auto}
.hub-footnote:empty,.validation-error:empty{display:none}
.login-screen{background:radial-gradient(ellipse at 12% 15%,#27647440,transparent 45%),linear-gradient(145deg,#122c42,#1b4a59);padding:2rem}
.login-card{border-radius:1.1rem;border-top-width:3px;box-shadow:0 24px 70px #061a3033;gap:2rem 2.5rem}
.login-card .eyebrow{margin-top:2rem}
.login-card h1{font-size:clamp(1.65rem,1.3rem + .8vw,2rem);max-width:16ch}
.login-card .subtitle{max-width:36ch;margin-top:1rem}
.login-card form{align-self:center;min-width:0}
.login-card form label{margin-top:0;margin-bottom:1.2rem}
.login-card form label:last-of-type{margin-bottom:.85rem}
.login-card input{background:var(--surface-raised);border-color:var(--line);min-height:3rem}
.login-card .btn{min-height:3rem}
.login-foot{gap:1rem;flex-wrap:wrap;font-size:.875rem;padding-top:1.25rem;margin-bottom:0}
.login-foot a{font-weight:550;min-height:2.75rem;display:flex;align-items:center;color:var(--accent)}
.login-credit{font-size:.75rem;color:var(--muted);text-align:center;font-weight:400;margin:1.25rem 0 0}
:is(a,button,input,select,textarea,summary,[tabindex]):focus-visible{outline:2px solid var(--focus);outline-offset:3px}
input:focus-visible,select:focus-visible,textarea:focus-visible{border-color:var(--focus);box-shadow:0 0 0 4px var(--accent-soft)}
summary{border-radius:.4rem}
details>summary:hover{color:var(--accent)}
#sidebar :is(a,summary,button):focus-visible{outline-color:#85e0cf}
#sidebar summary:hover{color:#fff}
[data-theme=dark] .topbar{background:var(--surface);border-color:var(--line)}
[data-theme=dark] .top-actions .ghost{color:var(--muted)}
[data-theme=dark] .top-actions .ghost:hover{background:var(--surface-raised);border-color:var(--line);color:var(--ink)}
[data-theme=dark] .top-actions #readingControls{background:var(--accent-soft);border-color:var(--line);color:var(--accent)}
[data-theme=dark] .top-actions #logout{background:#315772;border-color:#406d87;color:#fff}
[data-theme=dark] .top-actions #logout:hover{background:#396681;color:#fff}
[data-theme=dark] .btn:not(.secondary){background:var(--action);border-color:var(--action);color:#fff}
[data-theme=dark] .btn:not(.secondary):hover:not(:disabled){background:var(--action-hover);border-color:var(--action-hover)}
[data-theme=dark] .btn.secondary{background:var(--surface);border-color:var(--line);color:var(--ink)}
[data-theme=dark] .btn.secondary:hover:not(:disabled){background:var(--accent-soft);border-color:var(--accent);color:var(--ink)}
[data-theme=dark] :is(.footer,.workspace-clock){color:var(--muted)}
[data-theme=dark] .stat{background:var(--surface);box-shadow:var(--shadow-sm)}
[data-theme=dark] .login-screen{background:radial-gradient(ellipse at 12% 15%,#27647430,transparent 45%),#0b1e2e}
@media(max-width:800px){.login-card{gap:1.5rem}.login-card .eyebrow{margin-top:1.5rem}.login-card h1{max-width:none}.login-screen{padding:1.25rem}}
@media(max-width:750px){.topbar{gap:.7rem}.topbar-context #portalCrumb{font-size:.9375rem}.topbar-context .group-wordmark{font-size:.75rem}.footer{padding:1.1rem 1rem 1.5rem}.login-foot{gap:.5rem 1rem}.login-foot a{max-width:calc(50% - .5rem)}.login-foot a:last-child{text-align:right;justify-content:flex-end}}
@media(max-width:430px){.login-screen{padding:1rem}.login-card .brand{font-size:1.7rem}.login-card .brand-sub{font-size:.7rem}.login-foot{font-size:.8125rem}.login-credit{margin-top:1rem}}
@media(pointer:coarse){.btn,.btn.small,.row-action,.ghost,.tabs button,.supplier-tabs button,#nav a,.workspace-controls>summary,details>summary{min-height:2.75rem}.hub-status-link{min-height:2.75rem}}
@media(prefers-reduced-motion:no-preference){
 :root:not([data-motion=reduced]) .hub-overview-metric{transition:border-color .18s var(--ease),box-shadow .18s var(--ease),background-color .18s var(--ease)}
 :root:not([data-motion=reduced]) .hub-overview-metric:hover{box-shadow:var(--shadow-md)}
 :root:not([data-motion=reduced]) :is(input,select,textarea){transition:border-color .16s var(--ease),box-shadow .16s var(--ease)}
}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}}
:root[data-motion=reduced] *,:root[data-motion=reduced] *::before,:root[data-motion=reduced] *::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}
