:root{font-family:Inter,system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif;color:#183149;background:#f3f6f9;font-size:14px;line-height:1.5;font-synthesis:none}
*{box-sizing:border-box}body{margin:0}button,input,textarea,select{font:inherit}button{cursor:pointer}a{color:inherit}button:disabled{opacity:.5;cursor:not-allowed}input,textarea,select{outline:none}input:focus,textarea:focus,select:focus{border-color:#2787cb!important;box-shadow:0 0 0 3px #1b83c41b}.loading{padding:12vh 5vw;text-align:center;color:#526b80}
.app-layout{display:grid;grid-template-columns:252px minmax(0,1fr);min-height:100vh}.sidebar{background:#103451;color:#d7e5f1;padding:25px 14px 18px;position:sticky;top:0;height:100vh;display:flex;flex-direction:column}.brand{display:flex;align-items:center;gap:11px;padding:7px 10px 25px;border-bottom:1px solid #ffffff22}.brand-icon{display:grid;place-items:center;width:38px;height:38px;border-radius:11px;background:#2c80b2;color:white;font-size:22px}.brand-name{font-size:15px;font-weight:800;line-height:1.25;color:white}.brand-sub{color:#a7c0d5;font-size:11px;margin-top:3px}.nav-label{font-size:10px;letter-spacing:.15em;color:#86a7be;font-weight:800;text-transform:uppercase;margin:24px 13px 10px}.nav-item{display:flex;align-items:center;gap:12px;width:100%;border:0;border-radius:10px;background:transparent;color:#c5d8e7;text-align:left;padding:12px;margin:2px 0;font-weight:550}.nav-item:hover{background:#ffffff14;color:#fff}.nav-item.active{background:#246387;color:#fff;font-weight:750}.nav-symbol{font-size:17px;width:22px;text-align:center}.sidebar-bottom{margin-top:auto;border-top:1px solid #ffffff24;padding:17px 10px 0;color:#b9d0e0;font-size:12px;line-height:1.55}.sidebar-bottom strong{color:#f1f8ff}.main{min-width:0}.topbar{background:#fff;display:flex;align-items:center;gap:14px;padding:16px clamp(18px,3vw,42px);border-bottom:1px solid #e3eaf0;position:sticky;top:0;z-index:10}.topbar-title{font-size:16px;font-weight:750;white-space:nowrap}.topbar-spacer{flex:1}.search-box{display:flex;align-items:center;gap:8px;background:#f6f8fa;border:1px solid #e3e9f0;border-radius:9px;padding:9px 12px;color:#7c91a2;width:min(36vw,300px)}.search-box input{background:transparent;border:0;width:100%;font-size:13px;min-width:0;color:#16334b}.search-box input:focus{box-shadow:none!important}.user-pill{display:flex;gap:8px;align-items:center;color:#435e72;font-size:12px;white-space:nowrap}.avatar{width:32px;height:32px;border-radius:50%;display:grid;place-items:center;background:#dff0fc;color:#1b73a5;font-weight:800}.content{max-width:1460px;margin:auto;padding:25px clamp(18px,3vw,42px) 80px}.preview-notice{padding:13px 17px;background:#fff8e7;border:1px solid #f2dca1;color:#725316;border-radius:12px;display:flex;align-items:start;gap:10px;margin-bottom:22px}.preview-notice strong{color:#704b09}.notice-symbol{font-size:18px;line-height:1}.page-heading{display:flex;justify-content:space-between;align-items:flex-start;gap:14px;margin:0 0 20px}.page-heading h1{font-size:27px;color:#15354e;margin:0 0 3px;letter-spacing:-.035em;line-height:1.25}.page-heading p{color:#70879a;margin:0}.heading-actions{display:flex;flex-wrap:wrap;justify-content:end;gap:9px}.btn{border:1px solid #d9e3eb;background:white;color:#2a506d;border-radius:9px;padding:9px 13px;display:inline-flex;align-items:center;gap:8px;justify-content:center;white-space:nowrap;font-weight:650;font-size:12px;transition:filter .16s}.btn:hover{filter:brightness(.96)}.btn-primary{border-color:#176ea5;color:#fff;background:#196fa7}.btn-soft{background:#eaf4fb;border-color:#d4e8f6;color:#1c77ab}.btn-danger{background:#fff2f1;color:#b63a35;border-color:#f6d2cf}.btn-xs{padding:6px 9px;font-size:11px;border-radius:7px}.btn-block{width:100%}.grid{display:grid;gap:16px}.stats-grid{grid-template-columns:repeat(4,minmax(0,1fr));margin-bottom:19px}.stat-card{background:white;border:1px solid #e3e9ef;border-radius:13px;padding:19px;display:flex;align-items:center;gap:12px;min-height:111px;box-shadow:0 2px 8px #18384c04;cursor:pointer}.stat-icon{display:grid;place-items:center;width:45px;height:45px;flex-shrink:0;border-radius:13px;background:#e8f2f9;color:#2676ad;font-size:22px}.stat-icon.red{background:#fdebed;color:#c84a51}.stat-icon.orange{background:#fff2dd;color:#c7801c}.stat-icon.green{background:#e5f7ed;color:#328c60}.stat-number{font-size:30px;line-height:1.05;font-weight:830;color:#143a56;letter-spacing:-.05em}.stat-name{font-size:12px;color:#6e8397;margin-top:5px}.section-grid{display:grid;grid-template-columns:minmax(0,1.45fr) minmax(270px,1fr);gap:17px;margin-bottom:16px}.panel{background:white;border:1px solid #e2e9ef;border-radius:13px;min-width:0;overflow:hidden;box-shadow:0 2px 7px #14314b04}.panel-header{padding:17px 19px;border-bottom:1px solid #eef2f6;display:flex;justify-content:space-between;align-items:center;gap:10px}.panel-header h2{margin:0;font-size:15px;color:#193b54}.panel-body{padding:17px 19px}.table-wrap{overflow:auto}.data-table{width:100%;border-collapse:collapse;text-align:left}.data-table th{background:#f7f9fb;color:#6d8498;font-size:11px;letter-spacing:.025em;font-weight:750;padding:12px 14px;white-space:nowrap}.data-table td{border-top:1px solid #edf1f5;padding:12px 14px;font-size:12px;vertical-align:middle}.data-table tbody tr:hover{background:#fafcfd}.item-title{font-weight:750;color:#183b54}.muted{color:#7a91a2;font-size:11px;margin-top:3px}.nowrap{white-space:nowrap}.mono{font-variant-numeric:tabular-nums}.badge{display:inline-flex;align-items:center;gap:5px;border-radius:30px;padding:4px 9px;background:#eaf3fa;color:#2b729e;font-size:11px;font-weight:700;white-space:nowrap}.badge.green{background:#e5f6ee;color:#2a875b}.badge.orange{background:#fff2df;color:#a86b1f}.badge.red{background:#fee9e9;color:#b13d48}.badge.gray{background:#edf1f4;color:#63798b}.badge.violet{background:#f1eaf9;color:#8455a3}.mini-list{display:flex;flex-direction:column}.mini-item{padding:13px 0;border-bottom:1px solid #eef2f5;display:flex;align-items:flex-start;gap:10px}.mini-item:last-child{border:0}.mini-dot{width:8px;height:8px;background:#3188c3;border-radius:50%;margin-top:6px;flex:none}.mini-content{min-width:0;flex:1}.mini-content strong{font-size:12px;color:#21435d;display:block}.mini-content small{font-size:11px;color:#8193a1}.mini-right{font-size:11px;color:#7890a0}.activity-time{color:#7d91a1;white-space:nowrap;font-size:11px}.tool-row{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:16px;flex-wrap:wrap}.tool-row .filters{display:flex;gap:8px;flex-wrap:wrap}.input,.select,.textarea{border:1px solid #dce5ed;border-radius:9px;background:white;color:#254357;padding:10px 12px;min-height:39px;min-width:120px}.select{max-width:240px}.tool-row .input{width:min(300px,100%)}.cards{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:15px}.entity-card{background:white;border:1px solid #e0e8ee;border-radius:13px;padding:17px;min-width:0}.entity-top{display:flex;align-items:flex-start;justify-content:space-between;gap:10px}.entity-icon{display:grid;place-items:center;width:38px;height:38px;background:#eaf3f9;color:#2a749f;border-radius:10px;font-size:20px;margin-bottom:13px}.entity-card h3{margin:0 0 5px;font-size:15px;color:#1b3b53}.entity-card p{margin:0;color:#708699;font-size:12px}.entity-meta{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin:13px 0}.entity-bottom{border-top:1px solid #ecf1f5;padding-top:12px;margin-top:14px;display:flex;justify-content:space-between;gap:8px;align-items:center}.small-link{border:0;background:transparent;color:#1c78b0;padding:5px 1px;font-weight:650;font-size:12px}.small-link:hover{text-decoration:underline}.empty{padding:44px 18px;text-align:center;color:#8395a5}.empty-symbol{font-size:32px;margin-bottom:7px}.empty strong{display:block;color:#536c7f}.empty p{margin:5px auto 0;max-width:440px;font-size:12px}.inventory-table td:nth-child(4),.inventory-table td:nth-child(5){font-variant-numeric:tabular-nums}.panel-split{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.subtle-card{background:#f8fafc;border:1px solid #e8eef3;border-radius:10px;padding:14px}.subtle-card strong{font-size:12px;color:#23455e}.subtle-card p{font-size:12px;color:#6b8193;margin:5px 0 0}.note{color:#6a8091;font-size:12px;line-height:1.6}.alert-row{background:#fff9ec;padding:13px;border-radius:9px;color:#95651b;font-size:12px;margin:12px 0}.timeline{border-left:2px solid #dae7f0;margin:0 0 0 7px;padding:0 0 0 17px}.timeline-item{position:relative;margin-bottom:17px}.timeline-item:before{content:"";position:absolute;left:-23px;top:5px;width:10px;height:10px;border-radius:50%;background:#61a7d2;border:2px solid white}.timeline-item strong{font-size:12px;color:#264960;display:block}.timeline-item p{font-size:12px;color:#6e8293;margin:4px 0}.form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.field{display:flex;flex-direction:column;gap:6px}.field label{font-weight:650;font-size:12px;color:#405c71}.field .input,.field .textarea,.field .select{width:100%;max-width:none}.field.span2{grid-column:span 2}.field small{color:#899baa}.textarea{min-height:90px;resize:vertical}.modal-backdrop{position:fixed;inset:0;background:#10283a9c;z-index:30;display:flex;align-items:center;justify-content:center;padding:22px}.modal{background:white;border-radius:16px;width:min(720px,100%);max-height:min(91vh,960px);overflow:auto;box-shadow:0 16px 60px #0b203655}.modal-header{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:20px 24px 15px;border-bottom:1px solid #edf1f4}.modal-header h2{margin:0;font-size:18px;color:#18384f}.close{font-size:24px;border:0;color:#7590a3;background:transparent;line-height:1}.modal-body{padding:20px 24px}.modal-footer{border-top:1px solid #edf1f4;padding:15px 24px;display:flex;gap:9px;justify-content:flex-end}.modal-info{background:#eef7fc;border:1px solid #d9eaf5;border-radius:10px;padding:12px;color:#486e86;font-size:12px;margin-bottom:17px}.detail-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 16px;margin-bottom:18px}.detail-cell{border-bottom:1px solid #edf2f5;padding:7px 0}.detail-label{font-size:11px;color:#8699a7}.detail-value{font-weight:650;font-size:12px;color:#28495f;margin-top:3px}.divider{height:1px;background:#ecf1f4;margin:17px 0}.photo-grid{display:flex;gap:10px;flex-wrap:wrap}.photo-tile{width:116px;border:1px solid #e0e9ee;border-radius:9px;overflow:hidden;background:#f7fafd}.photo-tile img{width:100%;height:82px;object-fit:cover}.photo-placeholder{height:82px;display:grid;place-items:center;font-size:26px;color:#a4bac8}.photo-label{font-size:10px;color:#587184;word-break:break-word;padding:6px}.footer-note{text-align:center;color:#9aabba;font-size:11px;padding:12px}.mobile-nav{display:none}.report-summary{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:18px}.report-number{font-size:25px;color:#143d5e;font-weight:800}.report-label{color:#7290a4;font-size:11px}.quick-actions{display:flex;gap:10px;flex-wrap:wrap}.layout-flex{display:flex;gap:12px;align-items:center;flex-wrap:wrap}.tag-outline{color:#6f91a7;border:1px solid #dbe7ee;border-radius:6px;padding:2px 6px;font-size:11px}.toast{position:fixed;bottom:24px;right:24px;max-width:420px;background:#153d57;color:white;z-index:50;padding:13px 17px;border-radius:10px;box-shadow:0 10px 25px #09283f44;font-size:13px}.toast.error{background:#a03f46}.mobile-title{display:none}
@media(max-width:1140px){.sidebar{width:220px}.app-layout{grid-template-columns:220px minmax(0,1fr)}.stats-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.cards{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){.app-layout{display:block}.sidebar{display:none}.main{padding-bottom:69px}.topbar{position:static;padding:14px 16px}.topbar-title{font-size:14px}.topbar .user-pill span:last-child{display:none}.search-box{width:auto;flex:1}.content{padding:18px 14px 40px}.page-heading{align-items:flex-start;flex-direction:column}.page-heading h1{font-size:23px}.heading-actions{width:100%;justify-content:flex-start}.section-grid,.panel-split{grid-template-columns:1fr}.cards{grid-template-columns:1fr}.mobile-nav{position:fixed;bottom:0;left:0;right:0;display:flex;overflow:auto;background:#fff;border-top:1px solid #dfe9ef;z-index:20;padding:6px 4px calc(5px + env(safe-area-inset-bottom));box-shadow:0 -5px 18px #294a6112}.mobile-nav button{flex:1;min-width:55px;border:0;background:transparent;border-radius:8px;color:#668296;display:flex;align-items:center;flex-direction:column;gap:3px;font-size:10px;padding:5px 2px}.mobile-nav button.active{background:#ecf5fb;color:#1674aa;font-weight:750}.mobile-nav button span{font-size:19px}.modal-backdrop{align-items:flex-end;padding:0}.modal{width:100%;max-height:93vh;border-radius:17px 17px 0 0}.modal-header,.modal-body,.modal-footer{padding-left:17px;padding-right:17px}.form-grid,.detail-grid{grid-template-columns:1fr}.field.span2{grid-column:auto}.report-summary{grid-template-columns:repeat(2,minmax(0,1fr))}.preview-notice{font-size:12px}.data-table{min-width:620px}.entity-card{padding:15px}.toast{bottom:86px;right:12px;left:12px}.mobile-title{display:inline}}
@media(min-width:761px) and (max-width:980px){.section-grid{grid-template-columns:1fr}}
@media print{.sidebar,.topbar,.mobile-nav,.preview-notice,.heading-actions,.tool-row,.btn,.footer-note,.modal-backdrop{display:none!important}.app-layout{display:block}.content{padding:0}.panel,.stat-card{box-shadow:none;break-inside:avoid}body{background:white}.panel{border:1px solid #aaa}.page-heading h1{font-size:20px}}

/* iOS-inspired light interface — restrained surfaces, clear typography, content first. */
:root{font-family:-apple-system,BlinkMacSystemFont,"SF Pro Text","Segoe UI",Arial,sans-serif;color:#20242b;background:#f6f7f9;font-size:14px;line-height:1.48;-webkit-font-smoothing:antialiased}
body{background:#f6f7f9;color:#20242b}
button,input,select,textarea{font-family:inherit}
button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible{outline:3px solid #a6c8ee;outline-offset:2px}
.app-layout{grid-template-columns:226px minmax(0,1fr)}
.sidebar{background:#fbfbfd;color:#333a42;padding:22px 12px 16px;border-right:1px solid #e6e8eb}
.brand{border-bottom:0;padding:7px 11px 23px;gap:10px}
.brand-icon{width:34px;height:34px;border-radius:11px;background:#edf3fb;color:#326a98;font-size:18px}
.brand-name{color:#262f36;font-size:14px;letter-spacing:-.025em;font-weight:730}
.brand-sub{color:#858c96;font-size:11px}
.nav-label{color:#8b939e;font-size:10px;font-weight:640;letter-spacing:.07em;margin:16px 13px 9px}
.nav-item{color:#56616d;font-weight:560;border-radius:10px;padding:10px 13px;gap:9px;margin:2px 0;font-size:13px}
.nav-item:hover{background:#eff1f4;color:#1d2731}
.nav-item.active{background:#e8eef6;color:#286098;font-weight:700}
.nav-symbol{width:20px;color:#87919a;font-size:15px}
.nav-item.active .nav-symbol{color:#286098}
.sidebar-bottom{border-top:1px solid #e9ebee;color:#8b939a;font-size:11px;line-height:1.5;padding:15px 11px 0}
.sidebar-bottom strong{color:inherit}
.topbar{padding:14px clamp(18px,3vw,37px);background:#fbfbfd;border-bottom:1px solid #e9ebee;gap:13px;min-height:64px}
.topbar-title{font-size:14px;color:#30373f;font-weight:680;letter-spacing:-.015em}
.user-pill{color:#55606b}
.avatar{background:#ebeff6!important;color:#4e6479!important;font-weight:680}
.search-box{background:#f1f2f5;border:1px solid #edeff3;border-radius:11px;color:#8e97a2;padding:8px 11px}
.search-box input{font-size:13px;color:#333b44}
.content{max-width:1640px;margin:0 auto;padding:27px clamp(18px,3vw,39px) 34px}
.preview-notice{display:none!important}
.page-heading{margin:0 0 15px;align-items:center;gap:12px}
.page-heading h1{color:#232932;font-size:25px;letter-spacing:-.04em;font-weight:750;margin-bottom:3px}
.page-heading p{color:#8a919a;font-size:12.5px}
.heading-actions{gap:8px}
.btn{background:#fff;border:1px solid #e2e6eb;border-radius:10px;color:#49525d;padding:9px 12px;font-size:12.5px;min-height:36px;font-weight:615;gap:7px;box-shadow:none}
.btn:hover{filter:none;background:#f3f5f8;border-color:#d1dbe3}
.btn-primary{background:#357db9;border-color:#357db9;color:#fff}
.btn-primary:hover{background:#286ca6;color:white;border-color:#286ca6}
.btn-soft{background:#edf3fa;border-color:#e3edf7;color:#396e98}
.btn-soft:hover{background:#e5eff9}
.btn-danger{background:#fff;color:#b3544f;border-color:#ebdfdf}
.btn-xs{min-height:30px;font-size:12px;padding:5px 10px}
.small-link{color:#3477ae;text-decoration:none;font-weight:620}
.small-link:hover{text-decoration:underline}
.panel,.entity-card,.subtle-card,.stat-card{background:#fff;border:1px solid #e7e9ed;border-radius:14px;box-shadow:0 1px 2px rgba(20,30,42,.025)}
.panel{overflow:hidden}
.panel-header{border-bottom:1px solid #f0f1f3;padding:14px 17px;gap:8px}
.panel-header h2{color:#2a3039;font-size:14px;font-weight:670;letter-spacing:-.012em}
.panel-body{padding:16px 17px}
.cards{gap:12px}
.entity-card{padding:17px}
.entity-icon{background:#f3f4f6!important;color:#87919a!important;border:0!important;font-size:14px!important}
.entity-card h3{color:#303741;font-size:14px;letter-spacing:-.016em}
.entity-card p,.entity-meta,.note,.muted{color:#9097a0}
.entity-bottom{border-top:1px solid #f0f2f3}
.stat-card{padding:17px 18px;min-height:103px}
.stat-icon{display:none}
.stat-number{font-size:25px;letter-spacing:-.04em;font-weight:720;color:#2b3540}
.stat-name{font-size:12px;color:#88919a;font-weight:570}
.badge{border-radius:7px;font-size:11px;font-weight:600;border:1px solid transparent;padding:3px 7px}
.badge.green{color:#387258;background:#f0f7f2;border-color:#e3efe7}
.badge.orange{color:#9b7043;background:#fff8ef;border-color:#f6ecda}
.badge.red{color:#b25851;background:#fff3f2;border-color:#f5e2df}
.badge.gray{color:#64717e;background:#f2f4f6;border-color:#e9ecef}
.data-table{border-collapse:collapse}
.data-table th{background:#fbfbfc;color:#89919b;text-transform:none;letter-spacing:0;font-size:11.5px;font-weight:650}
.data-table tr{border-color:#f0f1f3}
.data-table td{color:#414851;font-size:12.5px}
.data-table tr:hover td{background:#fafbfc}
.item-title{color:#2a343d!important;font-weight:650}
.input,.select,.textarea{border:1px solid #e1e5ea;border-radius:9px;background:#fff;color:#303944;font-size:13px;min-height:38px;box-shadow:none}
.input:focus,.select:focus,.textarea:focus{border-color:#72a8d7!important;box-shadow:0 0 0 3px #5c9dd718!important}
.field label,.field>span{color:#6f7781;font-size:12px;font-weight:610}
.modal-backdrop{backdrop-filter:blur(6px);background:#20273365}
.modal{border:1px solid #e8eaed;border-radius:18px;box-shadow:0 18px 65px #1b273638;overflow:hidden}
.modal-header{background:#fff}
.modal-header h2{font-size:17px;letter-spacing:-.018em;color:#28313a}
.modal-footer{background:#fafbfc;border-top:1px solid #eff0f3}
.modal-info{background:#f5f8fb!important;color:#62717c!important;border-color:#e7edf2!important;border-radius:10px}
.mini-dot{background:#9cabb6!important}
.alert-row{background:#fcf9f5!important;color:#99764c!important;border-radius:9px}
.tag-outline{background:#f7f8fa;color:#87919b;border-color:#ebedf0}
.footer-note{font-size:11px;color:#a2a8b0;text-align:center;margin-top:28px}
.filter-section{margin:0 0 16px}
.filter-toggle-row{display:flex;align-items:center;gap:12px;min-height:40px}
.filter-toggle{border-color:#e2e5ea;background:#fff;border-radius:10px;color:#4e5a65;min-width:115px;justify-content:flex-start;font-size:12.5px;min-height:38px}
.filter-toggle.is-open{background:#eaf1f8;border-color:#ccdfed;color:#286a9e}
.filter-icon{font-size:14px;color:#8b98a5}
.filter-chevron{margin-left:auto;font-size:15px;transition:transform .18s ease;color:#8493a0}
.filter-toggle.is-open .filter-chevron{transform:rotate(180deg)}
.filter-count{background:#dcebf7;color:#3475a6;font-size:11px;border-radius:99px;min-width:19px;text-align:center;padding:2px 5px;margin-left:2px}
.filter-hint{font-size:11px;color:#a2a8b1}
.clear-filter{font-size:12px;color:#6f8ba3}
.filter-panel{margin-top:9px;background:#fff;border:1px solid #e8eaee;border-radius:13px;padding:16px 18px;box-shadow:0 2px 4px #1d2a3605;animation:showFilters .14s ease-out}
@keyframes showFilters{from{opacity:.5;transform:translateY(-4px)}to{opacity:1;transform:translateY(0)}}
.filter-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:13px;align-items:end}
.filter-field{min-width:0;display:flex;flex-direction:column;gap:5px}
.filter-field .input,.filter-field .select{width:100%;min-width:0}
.filter-search{grid-column:span 2}
.export-inline{justify-content:flex-end}
.export-inline .btn{width:100%;min-height:38px}
.planned-block{border:1px solid #ebedf1;background:#fafbfc;border-radius:12px;padding:12px 14px;margin-top:4px}
.planned-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;color:#48515c;font-size:13px;font-weight:700}
.planned-block p{font-weight:400}
.planned-row{display:grid;grid-template-columns:minmax(0,1fr) 110px 36px;gap:8px;margin:9px 0}
.planned-row .btn{padding:0;font-size:18px}
.report-summary .subtle-card{background:#fff}
@media(max-width:1100px){.filter-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:760px){
 :root{font-size:13px}body{background:#f7f8fa}
 .main{padding-bottom:73px}.content{padding:18px 13px 36px}
 .topbar{padding:10px 14px;min-height:56px}.topbar-title{font-size:13px}
 .search-box{max-width:170px;padding:7px 9px}.search-box input{font-size:11px}
 .page-heading{align-items:flex-start;gap:11px;margin-bottom:12px}
 .page-heading h1{font-size:21px}.page-heading p{font-size:11.5px}
 .heading-actions{width:100%;display:flex;flex-wrap:wrap;gap:7px}
 .heading-actions .btn{flex:0 0 auto;min-height:38px}
 .filter-section{margin-bottom:13px}.filter-hint{display:none}
 .filter-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}
 .filter-search{grid-column:span 2}
 .filter-panel{padding:13px}
 .filter-field{min-width:0}.filter-field .input,.filter-field .select{min-height:39px}
 .mobile-nav{border-top:1px solid #e7e9ee;box-shadow:0 -2px 10px #26384a08;background:#fff}
 .mobile-nav button{color:#9099a3;font-size:10px}.mobile-nav button.active{background:#eef4fb;color:#367bad}
 .panel,.entity-card,.stat-card{border-radius:12px}
 .stat-card{padding:13px 15px;min-height:88px}.stat-number{font-size:22px}
 .data-table th,.data-table td{padding:11px}
 .planned-row{grid-template-columns:minmax(0,1fr) 77px 32px;gap:6px}
 .modal{border-radius:17px 17px 0 0;max-height:94vh;overflow-y:auto}
}
@media(max-width:370px){.filter-grid{grid-template-columns:1fr}.filter-search{grid-column:span 1}.topbar-title{display:none}}
@media print{.filter-section,.sidebar,.mobile-nav,.topbar,.footer-note,.heading-actions{display:none!important}}
/* iPhone lists: readable rows instead of wide, horizontally scrolled tables */
@media(max-width:760px){
 .table-wrap{overflow:visible}
 .data-table{display:block;width:100%;border:0}
 .data-table thead{display:none}
 .data-table tbody{display:grid;gap:10px;padding:10px;background:#f8f9fa}
 .data-table tbody tr{display:block;background:#fff;border:1px solid #ebeef1;border-radius:12px;overflow:hidden}
 .data-table tbody td{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;text-align:right;padding:9px 12px;border-bottom:1px solid #f3f4f6;white-space:normal;min-width:0}
 .data-table tbody td:last-child{border:0}
 .data-table tbody td:before{content:attr(data-label);flex:0 0 105px;text-align:left;font-size:11px;color:#929aa4;font-weight:570;line-height:1.55}
 .data-table tbody td:first-child{display:block;text-align:left;padding-top:12px}
 .data-table tbody td:first-child:before{display:block;content:attr(data-label);margin-bottom:3px}
 .data-table tbody td[colspan]{display:block;text-align:center}
 .data-table tbody td[colspan]:before{content:none}
 .data-table .item-title,.data-table .small-link{max-width:100%;overflow-wrap:anywhere;text-align:right}
 .data-table tbody td:first-child .item-title{text-align:left}
 .data-table td .muted{font-size:11px}
}
@media(max-width:760px){.data-table{min-width:0!important;max-width:100%;table-layout:auto}.table-wrap{width:100%;max-width:100%}.data-table tbody{min-width:0;width:100%}.data-table tbody tr{min-width:0;width:100%}}

/* Modal layout: title and actions stay visible at any viewport size / browser zoom.
   Only the form contents scroll; the action bar is never clipped. */
.modal-backdrop{overflow:hidden}
.modal{
  display:flex;
  flex-direction:column;
  max-height:calc(100vh - 32px);
  max-height:calc(100dvh - 32px);
  overflow:hidden;
}
.modal-header,.modal-footer{flex:0 0 auto}
.modal>form{
  display:flex;
  flex-direction:column;
  flex:1 1 auto;
  min-height:0;
  overflow:hidden;
}
.modal-body{
  flex:1 1 auto;
  min-height:0;
  overflow-y:auto;
  overscroll-behavior:contain;
  -webkit-overflow-scrolling:touch;
}
.modal-footer{
  position:relative;
  z-index:1;
  padding-bottom:max(15px, env(safe-area-inset-bottom));
  box-shadow:0 -4px 12px #15243508;
}
@media(max-width:760px){
  .modal{max-height:calc(100vh - 8px);max-height:calc(100dvh - 8px)}
  .modal-footer{padding-bottom:max(16px, env(safe-area-inset-bottom))}
}
@media(max-height:520px){
  .modal-header{padding-top:10px;padding-bottom:10px}
  .modal-body{padding-top:12px;padding-bottom:12px}
  .modal-footer{padding-top:9px;padding-bottom:max(9px, env(safe-area-inset-bottom))}
}

/* 2026-10-29 — readability + navigation sizing + searchable selectors */
:root{font-size:15px}
.sidebar{width:auto}
.nav-item{font-size:16px;gap:12px;min-height:49px;padding:11px 12px;line-height:1.4}
.nav-symbol,.mobile-nav-icon{display:inline-flex;justify-content:center;align-items:center;flex:none;background:#eef3f8;border-radius:10px;width:34px;height:34px}
.nav-glyph{width:21px;height:21px;display:block}
.nav-color-dashboard{color:#4b87b9;background:#eaf3fb}
.nav-color-tasks{color:#698cae;background:#edf3fa}
.nav-color-assets{color:#478a84;background:#e9f5f2}
.nav-color-incidents{color:#b98c62;background:#faf2e8}
.nav-color-inventory{color:#8378b4;background:#f2effb}
.nav-color-reports{color:#568f78;background:#edf6f0}
.nav-item.active{background:#eef2f6;color:#263541}
.nav-item.active .nav-symbol{color:inherit}
.nav-item.active .nav-color-dashboard{color:#3a77aa}
.nav-item.active .nav-color-tasks{color:#587eaa}
.nav-item.active .nav-color-assets{color:#397a75}
.nav-item.active .nav-color-incidents{color:#aa7748}
.nav-item.active .nav-color-inventory{color:#7062a5}
.nav-item.active .nav-color-reports{color:#447f66}
/* Content: increase one step without inflating decorations. */
.content{font-size:15px;line-height:1.55}
.page-heading h1{font-size:27px}
.page-heading p{font-size:14px}
.panel-header h2{font-size:16px}
.entity-card h3{font-size:16px}
.entity-card p,.entity-meta,.note,.muted{font-size:14px}
.data-table th{font-size:13px}
.data-table td{font-size:14px}
.item-title,.mini-content strong{font-size:14px}
.mini-content small,.mini-right,.activity-time{font-size:13px}
.badge{font-size:12px}
.stat-name,.report-label{font-size:13px}
.btn,.small-link{font-size:14px}
.btn-xs{font-size:13px}
.input,.select,.textarea{font-size:14px}
.field label,.field>span{font-size:14px}
.detail-label{font-size:13px}
.detail-value{font-size:14px}
.filter-toggle{display:inline-flex;align-items:center;justify-content:flex-start;gap:9px;min-height:40px;padding:8px 12px;font-size:14px;line-height:1.2}
.filter-toggle-label{display:inline-block;white-space:nowrap}
.filter-toggle .filter-icon{width:17px;height:17px;flex-shrink:0;color:#668396;display:block}
.filter-toggle .filter-chevron{width:16px;height:16px;flex-shrink:0;display:block;transform-origin:center;transition:transform .2s ease;margin-left:4px;color:#6d8497}
.filter-toggle.is-open .filter-chevron{transform:rotate(180deg)}
.filter-count{display:inline-flex;align-items:center;justify-content:center;line-height:1.2}
.filter-hint,.clear-filter{font-size:13px}
.select-search-wrap{position:relative;min-width:0}
.select-search-icon{position:absolute;left:12px;top:50%;transform:translateY(-50%);pointer-events:none;color:#8e9eae;display:block}
.select-search-input{width:100%;max-width:none!important;padding-left:35px!important;min-height:40px;border-radius:9px}
.searchable-select .select{width:100%;max-width:none}
.searchable-select{min-width:0}
.planned-row{align-items:end}
.planned-row .planned-material-search{min-width:0;display:flex;flex-direction:column;gap:6px}
.planned-row>input,.planned-row>button{margin-bottom:0;height:40px}
@media(max-width:760px){
 :root{font-size:14px}
 .content{font-size:14px}
 .page-heading h1{font-size:23px}
 .page-heading p{font-size:13px}
 .mobile-nav{padding-bottom:max(7px,env(safe-area-inset-bottom))}
 .mobile-nav button{font-size:12px;min-width:58px;gap:4px}
 .mobile-nav-icon{width:32px;height:32px;background:transparent}
 .mobile-nav-icon .nav-glyph{width:23px;height:23px}
 .mobile-nav button.active .mobile-nav-icon{background:transparent}
 .mobile-nav-text{font-size:12px;white-space:nowrap}
 .data-table tbody td,.data-table tbody td:before{font-size:13px}
 .filter-toggle{font-size:14px}
 .planned-row{grid-template-columns:minmax(0,1fr) 84px 34px}
 .planned-row .select-search-input{font-size:13px}
}
@media(max-width:390px){.mobile-nav button{min-width:54px}.mobile-nav-text{font-size:11px}}
/* Give long material names/search their full line on narrow mobile task forms. */
@media(max-width:760px){
 .planned-row{grid-template-columns:minmax(0,1fr) 36px;align-items:end}
 .planned-row .planned-material-search{grid-column:1 / -1}
 .planned-row>input[name="plannedQty"]{grid-column:1}
 .planned-row>button[data-action="remove-planned"]{grid-column:2}
}

/* Planning view and compact in-dropdown search controls — 2026-10-29 */
.nav-color-planning{color:#8f7aaa;background:#f3eef8}
.nav-item.active .nav-color-planning{color:#8069a1}
.combo-control{position:relative;min-width:0;width:100%}
.combo-native{position:absolute!important;width:1px!important;height:1px!important;opacity:0!important;pointer-events:none!important;left:-10000px!important}
.combo-trigger{width:100%;min-height:42px;border:1px solid #dce2e9;border-radius:11px;background:#fff;color:#303946;display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px 13px;text-align:left;font:inherit;cursor:pointer}
.combo-trigger:focus-visible{outline:2px solid #83b1e3;outline-offset:2px}
.combo-trigger-label{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.combo-trigger svg{flex:none;color:#7d8997;transition:transform .18s ease}
.combo-control.is-open .combo-trigger{border-color:#b4c8df;border-bottom-left-radius:7px;border-bottom-right-radius:7px}
.combo-control.is-open .combo-trigger svg{transform:rotate(180deg)}
.combo-panel{margin-top:5px;background:#fff;border:1px solid #dde4ed;border-radius:12px;box-shadow:0 8px 20px #16293c13;overflow:hidden}
.combo-panel[hidden],.combo-option[hidden],.combo-empty[hidden]{display:none!important}
.combo-search-area{position:relative;padding:9px 10px;border-bottom:1px solid #eef0f3;display:flex;align-items:center}
.combo-search-area svg{position:absolute;left:22px;color:#8995a2;pointer-events:none}
.combo-search{width:100%;height:38px;border:1px solid #e2e6ec;border-radius:9px;padding:7px 9px 7px 36px;color:#2d3642;font:inherit;font-size:14px;background:#fafbfd;outline:none}
.combo-search:focus{border-color:#9fbcd9;background:#fff}
.combo-list{max-height:240px;overflow:auto;overscroll-behavior:contain;padding:5px}
.combo-option{border:0;background:none;width:100%;text-align:left;padding:9px 11px;border-radius:8px;color:#33404e;display:block;line-height:1.45;font-size:14px;cursor:pointer;word-break:break-word}
.combo-option:hover,.combo-option:focus-visible{background:#eff5fb;outline:none}
.combo-option.selected{background:#eff3f9;color:#34678c;font-weight:650}
.combo-empty{margin:0;padding:13px;color:#8e9ba6;text-align:center;font-size:13px}
.field .combo-control{width:100%}
.field-label{font-weight:650;color:#405c71;font-size:14px}
.planned-material-search{min-width:0}
.plan-period{display:flex;gap:3px;background:#f0f2f5;border:1px solid #e8eaee;border-radius:12px;padding:4px;width:max-content;max-width:100%;margin-bottom:13px}
.plan-period-btn{border:0;border-radius:9px;padding:9px 15px;color:#687583;background:transparent;font:inherit;font-size:13px;font-weight:630;cursor:pointer;white-space:nowrap}
.plan-period-btn.active{background:#fff;color:#2f3e50;box-shadow:0 1px 5px #172a3b13}
.plan-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:12px 0 20px}
.plan-summary>div{border:1px solid #e6e8ec;border-radius:13px;background:#fff;padding:15px;display:flex;flex-direction:column;gap:3px}
.plan-summary strong{color:#243345;font-size:23px;font-weight:740}
.plan-summary span{color:#73818d;font-size:13px}
.plan-day{border:1px solid #e8eaf0;border-radius:14px;background:#fff;margin-bottom:14px;overflow:hidden}
.plan-day-heading{display:flex;gap:10px;align-items:center;padding:13px 17px;background:#fafbfc;border-bottom:1px solid #eff0f3;color:#303e4c}
.plan-day-heading .note{margin-left:auto}
.plan-today{font-size:12px;border-radius:16px;background:#edf3fa;color:#4b7d9e;padding:3px 9px}
.plan-item{display:flex;align-items:center;gap:14px;padding:13px 17px;border-top:1px solid #f1f2f4;min-width:0}
.plan-item:first-of-type{border-top:0}
.plan-item-main{flex:1;min-width:0}
.plan-item-main .small-link{text-align:left;white-space:normal;font-size:14px}
.plan-item-meta{font-size:12px;color:#818c98;margin-top:4px}
.plan-item-flags{display:flex;gap:7px;align-items:center;flex-wrap:wrap;justify-content:flex-end}
@media(max-width:760px){
 .mobile-nav button{min-width:50px;padding-left:1px;padding-right:1px}
 .mobile-nav-text{font-size:11px}
 .plan-summary{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 .plan-summary>div{padding:12px}
 .plan-item{align-items:flex-start;flex-wrap:wrap;gap:8px;padding:12px}
 .plan-item-main{flex:1 1 100%}
 .plan-item-flags{justify-content:flex-start;flex:1}
 .plan-period-btn{padding:9px 11px}
 .combo-list{max-height:min(220px,30vh)}
}

/* Calendar planning workspace. Calendar and day details remain independently scrollable. */
.plan-workspace{
 display:flex;flex-direction:column;min-height:0;
 height:clamp(480px,calc(100dvh - 210px),880px);
 background:#fff;border:1px solid #e5e8ed;border-radius:16px;
 overflow:hidden;box-shadow:0 2px 12px #1d324008;
}
.plan-calendar-pane{flex:0 0 auto;min-height:0;overflow:auto;overscroll-behavior:contain;background:#fff}
.plan-calendar-toolbar{display:flex;gap:12px;justify-content:space-between;align-items:center;padding:14px 18px 12px;position:sticky;top:0;z-index:2;background:#fff;border-bottom:1px solid #f1f2f4}
.plan-calendar-navigation{display:flex;gap:7px;align-items:center;min-width:0}
.plan-calendar-navigation h2{font-size:16px;font-weight:700;margin:0 7px;color:#242b33;white-space:nowrap;font-variant-numeric:tabular-nums}
.plan-arrow{border:1px solid #e7e9ed;color:#4e5b68;background:#fff;border-radius:9px;font-size:24px;line-height:1;width:32px;height:33px;display:grid;place-items:center;cursor:pointer}
.plan-arrow:hover{background:#f5f7f9}
.plan-today-btn{margin-left:3px}
.plan-view-switch{display:flex;gap:3px;align-items:center;padding:3px;border-radius:11px;background:#f2f3f5;white-space:nowrap}
.plan-view-switch button{font:inherit;font-weight:600;font-size:12px;border:0;border-radius:8px;background:transparent;color:#6b7480;padding:7px 13px;cursor:pointer}
.plan-view-switch button.active{background:#fff;color:#296fa8;box-shadow:0 1px 5px #112c4815}
.plan-calendar-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));padding:8px 12px 12px;gap:3px;min-width:0}
.plan-week-label{text-align:center;color:#9299a3;font-size:11px;font-weight:650;padding:4px 2px 7px}
.plan-calendar-day{appearance:none;display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:4px;min-width:0;min-height:43px;padding:5px 1px 3px;background:#fff;color:#374351;border:1px solid transparent;border-radius:9px;cursor:pointer;font:inherit;line-height:1.1}
.plan-calendar-day:hover{background:#f3f7fa}
.plan-calendar-day:focus-visible{outline:2px solid #6096cf;outline-offset:-2px}
.plan-calendar-day.outside{color:#adb5c0}
.plan-calendar-day.selected{border-color:#b9d5ec;background:#eaf4fb;color:#205c92}
.plan-calendar-day.today .plan-calendar-number{font-weight:750;color:#2075b7}
.plan-calendar-number{font-size:12px;font-weight:620;font-variant-numeric:tabular-nums}
.plan-day-count{font-size:10px;color:#68839b;white-space:nowrap}
.plan-day-dot{display:none;width:5px;height:5px;background:#7ca5c8;border-radius:50%}
.plan-day-empty{height:11px}
.plan-divider{height:24px;flex:0 0 24px;background:#f6f7f9;display:flex;align-items:center;justify-content:center;gap:15px;border-top:1px solid #e8ecf0;border-bottom:1px solid #e8ecf0;touch-action:none;user-select:none;cursor:row-resize;position:relative;z-index:3}
.plan-divider:focus-visible{outline:2px solid #438ac4;outline-offset:-2px}
.plan-grip{width:58px;height:5px;background:#abb9c5;border-radius:20px}
.plan-collapse-button{width:30px;height:21px;border:0;background:transparent;border-radius:6px;color:#768899;font-size:17px;line-height:1;cursor:pointer;display:grid;place-items:center}
.plan-collapse-button:hover{background:#e8edf2;color:#326a99}
.plan-detail-pane{flex:1 1 auto;min-height:0;overflow:auto;overscroll-behavior:contain;background:#fff;padding:17px 18px 22px}
.plan-detail-top{display:flex;justify-content:space-between;align-items:center;gap:14px;margin-bottom:12px}
.plan-eyebrow{font-size:10px;font-weight:750;letter-spacing:.08em;color:#9da6af}
.plan-detail-top h2{font-size:18px;margin:3px 0 0;font-weight:730;color:#27313a}
.plan-task-count{font-size:12px;font-weight:600;color:#82909d;margin-left:7px}
.plan-detail-list{display:grid;gap:8px}
.plan-detail-item{display:flex;gap:12px;align-items:center;justify-content:space-between;padding:12px 13px;background:#fafbfc;border:1px solid #eceef1;border-radius:11px}
.plan-detail-content{flex:1;min-width:0;display:grid;gap:4px}
.plan-detail-content .small-link{width:fit-content;text-align:left;font-size:13px;white-space:normal}
.plan-detail-content>span{font-size:11.5px;color:#89929d}
.plan-detail-badges{display:flex;gap:5px;flex-wrap:wrap;align-items:center;justify-content:flex-end}
.plan-empty-day{padding:24px 10px;text-align:center;display:grid;gap:8px;justify-items:center;color:#8a96a2}
.plan-workspace.show-details-only .plan-calendar-pane{height:75px!important;overflow:hidden}
.plan-workspace.show-calendar-only .plan-calendar-pane{flex:1 1 auto;height:auto!important}
.plan-workspace.show-calendar-only .plan-detail-pane{display:none}
@media(max-width:760px){
 .plan-workspace{height:clamp(420px,calc(100dvh - 225px),820px);border-radius:13px}
 .plan-calendar-toolbar{padding:10px 9px;gap:7px;flex-wrap:wrap}
 .plan-calendar-navigation{gap:3px;flex:1;min-width:0}
 .plan-calendar-navigation h2{font-size:13px;margin:0 3px}
 .plan-arrow{height:30px;width:27px;font-size:21px}
 .plan-view-switch button{padding:6px 9px;font-size:11px}
 .plan-today-btn{padding:5px 8px;font-size:10px}
 .plan-calendar-grid{padding:6px 6px 8px;gap:1px}
 .plan-calendar-day{min-height:42px;padding:4px 0;gap:3px}
 .plan-calendar-number{font-size:12px}
 .plan-day-count{display:none}
 .plan-day-dot{display:block}
 .plan-day-empty{height:5px}
 .plan-detail-pane{padding:12px 10px 18px}
 .plan-detail-top h2{font-size:15px}
 .plan-detail-top .btn{font-size:11px;padding:8px}
 .plan-detail-item{flex-wrap:wrap;gap:7px;padding:10px}
 .plan-detail-badges{justify-content:flex-start}
 .plan-detail-item>.btn{margin-left:auto}
}
@media(max-width:375px){
 .plan-calendar-navigation h2{font-size:12px;max-width:122px;overflow:hidden;text-overflow:ellipsis}
 .plan-view-switch button{padding:5px 8px}
 .plan-today-btn{font-size:10px}
 .plan-calendar-day{min-height:39px}
}
/* Reduce expensive paint effects on slower devices. */
.modal-backdrop{backdrop-filter:none}
@media(prefers-reduced-motion:reduce){.filter-panel,.filter-chevron,.btn{animation:none!important;transition:none!important}}
@media(max-width:760px){
 .plan-calendar-toolbar{display:grid;grid-template-columns:minmax(0,1fr);row-gap:7px}
 .plan-calendar-navigation{width:100%;justify-content:flex-start}
 .plan-calendar-navigation h2{font-size:13px;min-width:0;overflow:hidden;text-overflow:ellipsis}
 .plan-view-switch{justify-self:end}
 .mobile-nav{justify-content:space-between;gap:0;overflow:hidden}
 .mobile-nav button{flex:1 1 0;min-width:0;padding:5px 0;overflow:hidden}
 .mobile-nav-text{font-size:clamp(9px,2.45vw,11px);line-height:1.15;max-width:100%;white-space:normal;word-break:normal;text-align:center}
 .mobile-nav-icon{min-height:23px;display:grid;place-items:center}
}