/* Shared staff portal design. Local assets only; no external fonts or trackers. */
:root{--navy:#123744;--ink:#19343e;--muted:#647780;--accent:#146e68;--accent-soft:#e5f2ee;--line:#dbe4e8;--surface:#fff;--canvas:#f3f6f8;--brand-blue:#146e68;--brand-blue-dark:#105a55;--brand-navy:#123744;--brand-ink:#19343e}
*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;background:var(--canvas);color:var(--ink);font-family:Segoe UI,Tahoma,sans-serif;font-size:14px;line-height:1.8}button,input,select,textarea{font:inherit}button,a,input,select,textarea{-webkit-tap-highlight-color:transparent}button,a{touch-action:manipulation}button{cursor:pointer}button:disabled{cursor:wait;opacity:.55}a{color:var(--accent)}:focus-visible{outline:3px solid #c08b38;outline-offset:3px}[hidden]{display:none!important}h1,h2,h3,p{overflow-wrap:anywhere}h1{font-size:28px;line-height:1.65;letter-spacing:-.5px}h2{font-size:18px}h3{font-size:16px}.muted,.ops-muted{color:var(--muted)}.eyebrow{font-size:12px;letter-spacing:0;color:var(--accent);font-weight:650}.primary{background:var(--accent);border:1px solid var(--accent);color:#fff}.primary:hover{background:#0c5550}.secondary{background:#fff;border:1px solid #cad9dd;color:var(--ink)}.secondary:hover{background:#edf4f4;border-color:#9bb8b8}.primary,.secondary,.icon-button{border-radius:9px;min-height:42px;padding:9px 16px;font-size:13px;font-weight:600;box-shadow:none}.icon-button{padding:8px 12px}.danger{color:#a52836}.primary.wide{width:100%}input:not([type=checkbox]):not([type=radio]),select,textarea{max-width:100%;min-height:44px;border:1px solid #c9d7dd;border-radius:8px;background:#fff;color:var(--ink);padding:10px 12px;font-size:14px}input:focus,select:focus,textarea:focus{border-color:var(--accent)}label{font-size:13px;color:var(--ink)}input[type=checkbox],input[type=radio]{accent-color:var(--accent);width:18px;height:18px}table{font-size:13px}th{font-size:12px;font-weight:650;color:#4e6570;background:#f3f7f8}td,th{padding:13px 15px;border-color:#e6edf0}tbody tr:hover{background:#f6faf9}.table-wrap,.ops-table-wrap{overflow:auto;max-width:100%}.card,.ops-card,.stats>div{border:1px solid var(--line);border-radius:14px;box-shadow:0 3px 12px #12374404}.card,.ops-card{background:#fff}.ops-card{padding:24px;margin-bottom:20px}.ops-card>h2{margin:0 0 18px}.ops-empty{padding:34px 20px;text-align:center;background:#f7f9fa;border:1px dashed #d6e1e5;border-radius:10px;color:#637983}.notice,.form-error:not(:empty){border-radius:9px;padding:12px 16px;line-height:1.9}.form-error:not(:empty){background:#fff0f0;color:#9b2636;border:1px solid #f2d3d7}.ops-badge{background:var(--accent-soft);color:#165d57;border-radius:6px;padding:4px 9px;font-size:11px}.stats{gap:16px}.stats strong,.ops-metric strong{font-size:28px;letter-spacing:-.5px}.ops-metrics{gap:12px}.ops-metric{padding:18px;border-radius:10px;background:#f4f8f8;border:1px solid #e0eae9}.ops-actions{gap:10px;margin-bottom:22px;flex-wrap:wrap}.ops-link{padding:9px 12px;border-radius:8px}.ops-link:hover{background:#e8f0f0}
/* Navigation and page chrome */
.app-shell{display:grid;grid-template-columns:256px minmax(0,1fr);min-height:100vh}.sidebar{width:auto;background:var(--navy);padding:25px 16px;border:0;color:#fff;position:sticky;top:0;height:100vh;overflow:auto;overscroll-behavior:contain;display:flex;flex-direction:column;gap:16px}.sidebar .brand{padding:0 8px 22px;border-bottom:1px solid #ffffff20;min-height:88px;margin:0}.sidebar .company-logo{width:51px;height:51px;border-radius:12px;background:#fff;object-fit:contain}.sidebar .company-name{color:white;font-size:17px}.sidebar .company-subtitle,.sidebar .brand-sub{color:#b7cdd3;font-size:10px}.sidebar .workspace-label{display:none}.sidebar nav{display:flex;flex-direction:column;gap:5px;overflow:visible}.nav-section-title{font-size:10px;color:#9ebfc5;margin:19px 12px 6px;letter-spacing:.3px;font-weight:600}.sidebar .nav-button{display:flex;align-items:center;gap:11px;width:100%;min-height:44px;text-decoration:none;border:1px solid transparent;border-radius:9px;padding:10px 12px;font-size:12px;text-align:right;white-space:normal;color:#dce9ec;background:transparent;line-height:1.7}.sidebar .nav-button:hover{background:#ffffff0c;color:white}.sidebar .nav-button.active{background:#e2f1ec;color:#123e3c;border-color:#e2f1ec;font-weight:650}.nav-icon{display:inline-flex;flex:0 0 20px;width:20px;height:20px;color:currentColor}.nav-icon svg{width:100%;height:100%;fill:none;stroke:currentColor;stroke-width:1.65;stroke-linecap:round;stroke-linejoin:round}.sidebar-bottom{margin-top:auto;font-size:11px;padding:20px 10px;border-top:1px solid #ffffff20}.sidebar-bottom a{color:#c5dce0}.workspace{min-width:0}.topbar{min-height:82px;height:auto;background:#ffffffed;border-bottom:1px solid var(--line);padding:15px 32px;gap:16px;display:flex;flex-wrap:wrap}.topbar .company-page-brand{margin-inline-start:auto}.topbar .company-logo{width:40px;height:40px}.topbar .company-name{font-size:14px}.topbar .company-subtitle{font-size:10px}.account{font-size:12px;gap:10px}.avatar{background:#e5efec;color:#285c55;width:38px;height:38px;border-radius:12px}.workspace-tools{gap:8px;display:flex;align-items:center;flex-wrap:wrap}.workspace-home,.workspace-switch{font-size:12px;padding:7px 10px}.content{max-width:1560px;padding:32px;min-width:0}.page-heading{margin-bottom:28px;gap:20px;align-items:center}.page-heading h1{margin:4px 0 5px}.page-heading p{font-size:13px;max-width:860px;margin:0}.company-footer{font-size:11px;color:#758891;padding:22px 30px}.menu-toggle,.nav-scrim{display:none}.skip-link{position:fixed;top:-100px;right:18px;z-index:300;background:white;padding:12px;border:2px solid var(--accent);border-radius:6px}.skip-link:focus{top:10px}
/* Login: a quiet architectural identity for the company's employees. */
.auth-layout{min-height:100vh;max-width:none;margin:0;display:grid;grid-template-columns:minmax(0,1.15fr) minmax(400px,.85fr);padding:0;gap:0;background:#f5f7f8;align-items:stretch}.auth-story{position:relative;isolation:isolate;overflow:hidden;background:#123744;color:#fff;border-radius:0;padding:60px clamp(32px,6vw,110px);display:flex;flex-direction:column;justify-content:center;min-height:100vh}.auth-story:before{content:"";position:absolute;inset:0;z-index:-1;background:linear-gradient(155deg,#12374400 40%,#071f28a8),url('/construction-lines.svg') center bottom/cover no-repeat;opacity:.6}.auth-story .brand{margin-bottom:65px}.auth-story .company-logo{width:68px;height:68px;background:white;border-radius:14px;object-fit:contain}.auth-story .company-name{color:#fff;font-size:24px}.auth-story .company-subtitle{color:#c0d5da;font-size:12px}.auth-story .eyebrow{color:#a2cbbf;font-size:12px;letter-spacing:1px}.auth-story h1{font-size:clamp(32px,3.4vw,54px);line-height:1.75;margin:18px 0 22px;letter-spacing:-1.4px;max-width:600px;color:#fff}.auth-story>p{color:#c9dce1;line-height:2.2;font-size:15px;max-width:490px}.flow-visual{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:32px 0}.flow-visual div{border:1px solid #ffffff30;background:#ffffff08;border-radius:8px;padding:9px 18px;font-size:12px;color:#e8f1ef}.flow-visual b{color:#c19b5d}.auth-story .company-dedication{border-color:#ffffff20;color:#bad1d6;font-size:11px;margin-top:35px}.auth-card{align-self:center;justify-self:center;width:min(100%,440px);padding:40px;border:0;background:transparent;box-shadow:none;margin:40px 24px;border-radius:0}.auth-card .small-tag{color:var(--accent);font-size:12px;background:#e5eeea;border-radius:20px;padding:5px 12px}.auth-card h2{font-size:28px;margin:16px 0 8px}.auth-card>.muted{font-size:13px;margin-bottom:30px;line-height:2}.auth-card form>label:not(.workspace-check){display:block;margin:19px 0 7px;font-weight:600}.auth-card form>input{width:100%;height:50px;background:#fff;border-radius:9px}.auth-card .primary{height:50px;margin-top:12px;font-size:14px}.workspace-check{display:flex;align-items:center;gap:9px;line-height:1.8;font-size:12px;margin:20px 0}.auth-note{padding-top:24px;margin-top:22px;border-top:1px solid var(--line);font-size:11px;line-height:2.1;color:var(--muted)}
/* Home */
.workspace-home-layout{max-width:1320px;margin:0 auto;padding:40px 36px 60px}.workspace-welcome{position:relative;background:var(--navy);border:1px solid var(--navy);border-radius:18px;color:#fff;padding:32px 36px;margin-bottom:22px;background-image:url('/construction-lines.svg');background-size:cover}.workspace-welcome .eyebrow{color:#aecfc5}.workspace-welcome h1{font-size:30px;margin:7px 0}.workspace-welcome .muted{color:#c6dbe0;margin:0}.workspace-account-actions{justify-content:flex-end;display:flex;gap:10px;margin-bottom:24px}.home-meta{font-size:12px;color:#c1d8d8;margin:14px 0 0}.home-search{display:flex;justify-content:space-between;gap:18px;align-items:center;margin:28px 0}.home-search input{width:min(100%,390px)}.home-search p{color:var(--muted);font-size:12px;margin:0}.workspace-grid{display:block}.module-group{margin:30px 0}.module-group>h2{font-size:15px;margin:0 0 16px;display:flex;gap:14px;align-items:center}.module-group>h2:after{content:"";height:1px;background:var(--line);flex:1}.module-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}.workspace-card{position:relative;display:flex;flex-direction:column;gap:12px;border:1px solid #dce6e8;border-radius:12px;background:#fff;padding:22px;min-height:200px;text-decoration:none;transition:transform .16s,border-color .16s,box-shadow .16s;color:var(--ink)}.workspace-card:hover{border-color:#84b4a9;transform:translateY(-3px);box-shadow:0 7px 20px #1d4c3610}.workspace-card>.nav-icon{width:37px;height:37px;padding:8px;background:#e8f2ee;color:var(--accent);border-radius:10px;flex-basis:37px}.workspace-card strong{font-size:15px}.workspace-card>span:not(.nav-icon){font-size:12px;color:var(--muted);line-height:1.9;flex:1}.workspace-card>b{font-size:11px;color:var(--accent);margin-top:4px}.workspace-selector{padding:28px;border-radius:14px}.workspace-choice{padding:16px;border-radius:9px}.workspace-choice:has(input:checked){background:#edf7f3;border-color:#72a99c}
.app-shell:not(:has(>.sidebar)){display:block;min-height:70vh}.app-shell.inbound{max-width:1600px;padding:32px}.app-shell.inbound .page-heading{display:flex;justify-content:space-between}
/* Accessible dialogs */
dialog{border:1px solid var(--line);border-radius:16px;max-width:min(850px,calc(100vw - 32px));max-height:90vh;padding:0;box-shadow:0 25px 80px #102b3a40;color:var(--ink)}dialog::backdrop{background:#0a263b70;backdrop-filter:blur(3px)}.dialog-head{padding:20px 26px;background:#f5f8f9;border-bottom:1px solid var(--line)}.dialog-head h2{font-size:19px}#dialogForm{padding:24px}#dialogForm label{margin:0;font-size:13px}#dialogForm>label{display:block;margin-top:15px}.ops-form{gap:20px}.ops-form label>input,.ops-form label>select,.ops-form label>textarea{margin-top:7px;width:100%}.ops-form label.ops-check{display:flex;gap:9px}.ops-form label.ops-check>input{width:18px;margin:0}.dialog-actions{padding-top:20px;margin-top:22px;border-top:1px solid var(--line);gap:10px}
/* Branch charts. Wide trees scroll within their canvas, never the page. */
.chart-toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-bottom:16px}.chart-toolbar input{width:240px}.chart-toolbar label{display:flex;gap:8px;align-items:center}.chart-caption{font-size:12px;color:var(--muted);margin:12px 0}.branch-canvas{width:100%;max-height:900px;overflow:auto;overscroll-behavior:contain;background-color:#f7fafb;background-image:radial-gradient(#cbdcde .8px,transparent .8px);background-size:18px 18px;border:1px solid var(--line);border-radius:12px;padding:32px 24px;direction:rtl}.branch-tree,.branch-tree ul{display:flex;list-style:none;margin:0;padding:0;justify-content:center;width:max-content;min-width:100%;position:relative}.branch-tree{min-width:100%;align-items:flex-start}.branch-tree ul{padding-top:38px}.branch-tree li{position:relative;text-align:center;padding:0 12px;display:flex;flex-direction:column;align-items:center;flex:none}.branch-tree ul>li:before{content:"";height:20px;border-top:1.5px solid #9bb6be;position:absolute;top:-20px;left:0;right:0}.branch-tree ul>li:first-child:before{right:50%}.branch-tree ul>li:last-child:before{left:50%}.branch-tree ul>li:only-child:before{display:none}.branch-tree ul>li:after{content:"";position:absolute;height:38px;width:1.5px;background:#9bb6be;top:-38px;left:50%}.branch-tree ul>li:not(:only-child):after{height:20px;top:-20px}.branch-tree li:has(>ul:not([hidden]))>.branch-node:after{content:"";position:absolute;height:19px;width:1.5px;background:#9bb6be;bottom:-20px;left:50%}.branch-node{position:relative;width:220px;min-height:115px;background:#fff;border:1px solid #cedfe2;border-top:3px solid var(--accent);border-radius:10px;box-shadow:0 3px 8px #12374406;padding:16px 14px;display:flex;flex-direction:column;align-items:center;gap:8px}.branch-node>strong{font-size:14px;line-height:1.8}.branch-node>.secondary{border:0;padding:0;background:none;min-height:30px;font-size:14px}.branch-node>.ops-duty{font-size:11px;line-height:1.8;color:#536b74;display:block}.branch-node .node-edit{font-size:11px;min-height:28px;padding:2px 10px;background:#f3f7f7;border:1px solid #e0e8e9}.branch-node.root-node{background:var(--navy);color:#fff;border-color:var(--navy);min-height:90px}.branch-node.root-node small{color:#bad4db}.branch-node.is-inactive{opacity:.65;border-top-color:#89979e}.branch-node.is-reference{border-style:dashed;border-top-color:#b48d50;min-height:85px}.branch-node.is-match{outline:3px solid #d0aa59;background:#fffaf0}.branch-node.is-terminal{border-top-color:#67979c}.branch-edge{font-size:10px;color:#526a75;line-height:1.7;background:#edf4f5;border-radius:5px;padding:3px 7px;max-width:100%}.branch-toggle{border:1px solid #cfdde1;border-radius:20px;background:#fff;color:var(--accent);font-size:11px;padding:2px 10px;min-height:28px}.branch-canvas[data-scale="75"]>.branch-tree{zoom:.75}.branch-canvas[data-scale="125"]>.branch-tree{zoom:1.25}.chart-summary{padding:14px 18px;border-right:3px solid var(--accent);background:#edf5f2;border-radius:8px;font-size:12px;line-height:2}.chart-summary ul{padding-right:20px;margin:0}.ops-filter{margin-bottom:20px}.ops-filter select{min-width:300px}
@media(min-width:1700px){.content{margin-inline:auto}.auth-card{width:480px}}
@media(max-width:1150px){.app-shell{grid-template-columns:225px minmax(0,1fr)}.content{padding:24px}.sidebar{padding:20px 12px}.topbar{padding:14px 24px}.topbar .company-page-brand{display:none}.module-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.auth-story{padding:40px}.auth-story h1{font-size:36px}.auth-card{padding:28px;margin:24px 12px}}
@media(max-width:800px){.app-shell{display:block}.sidebar{display:flex;position:fixed;inset:0 0 0 auto;width:280px;max-width:85vw;height:100dvh;z-index:110;transform:translateX(105%);transition:transform .2s}.nav-open .sidebar{transform:translateX(0)}.menu-toggle{display:inline-flex;align-items:center;justify-content:center;padding:10px;min-width:44px}.nav-open .nav-scrim{display:block;position:fixed;inset:0;z-index:100;background:#09283580;border:0;cursor:default}.topbar{padding:12px 16px;min-height:74px;gap:10px}.topbar .account{margin-inline-start:auto}.workspace-tools{gap:4px}.workspace-tools .secondary{padding:7px 9px}.workspace-home,.workspace-switch{font-size:11px;padding:6px}.content{padding:22px 16px}.page-heading{align-items:flex-start}.page-heading h1{font-size:24px}.page-heading>.secondary{font-size:11px;white-space:nowrap;padding:8px}.ops-card{padding:18px}.workspace-home-layout{padding:24px 18px}.workspace-welcome{padding:24px}.workspace-welcome h1{font-size:27px}.auth-layout{grid-template-columns:1fr}.auth-story{min-height:0;padding:32px 26px 28px}.auth-story .brand{margin-bottom:30px}.auth-story h1{font-size:31px;margin:14px 0}.auth-story>p{font-size:13px;max-width:570px}.auth-story .company-name{font-size:21px}.auth-story .company-logo{width:54px;height:54px}.auth-story .company-dedication{display:none}.flow-visual{margin:16px 0 0;gap:9px}.flow-visual div{padding:6px 13px;font-size:11px}.auth-card{margin:0;max-width:490px;padding:32px 26px 40px}.auth-card h2{font-size:25px}.auth-card>.muted{margin-bottom:20px}.branch-canvas{max-height:680px;padding:24px 14px}.chart-toolbar input{width:100%}.chart-toolbar{gap:8px}.chart-toolbar .secondary{font-size:11px}.chart-caption{font-size:11px}}
@media(max-width:520px){.module-grid{grid-template-columns:1fr}.workspace-card{min-height:0;padding:20px}.workspace-card>.nav-icon{position:absolute;left:20px;top:20px}.workspace-card strong{padding-left:48px;min-height:36px;display:flex;align-items:center}.home-search{flex-direction:column;align-items:stretch;gap:8px}.home-search input{width:100%}.workspace-account-actions .secondary{font-size:11px}.ops-form{grid-template-columns:minmax(0,1fr)}.ops-wide{grid-column:auto}.ops-metrics{grid-template-columns:1fr}.ops-filter select{min-width:0;width:100%}.topbar .account{width:100%;order:3;font-size:11px}.topbar .avatar{width:28px;height:28px;font-size:11px}.page-heading{flex-wrap:wrap}.page-heading h1{font-size:23px}.dialog-head{padding:16px}#dialogForm{padding:18px}.dialog-actions{flex-wrap:wrap}.stats{grid-template-columns:1fr 1fr}.chart-toolbar label{font-size:11px}.company-footer{padding:20px 16px}}
@media(prefers-reduced-motion:reduce){*,*:before,*:after{scroll-behavior:auto!important;transition:none!important;animation:none!important}}
.branch-canvas{direction:ltr}.branch-tree{direction:rtl}.skip-link{clip-path:inset(100%)}.skip-link:focus{clip-path:none}
@media(max-width:800px){.sidebar{transition:none}.app-shell.inbound{padding:22px 16px}.branch-tree,.branch-tree ul{display:block;min-width:0;width:max-content}.branch-tree{min-width:100%}.branch-tree li{align-items:flex-start;padding:0 0 20px}.branch-tree ul{padding:20px 20px 0 0;margin-right:18px;border-right:1.5px solid #9bb6be}.branch-tree ul>li:before{display:block!important;top:30px;right:-20px!important;left:auto!important;width:20px;height:1px}.branch-tree ul>li:after,.branch-tree li:has(>ul:not([hidden]))>.branch-node:after{display:none}.branch-node{width:220px}.branch-canvas{max-height:680px}}
@media print{.sidebar,.topbar,.chart-toolbar,.ops-actions,.workspace-account-actions,.company-footer{display:none!important}.app-shell{display:block}.branch-canvas{max-height:none;overflow:visible;background:white;border:0;zoom:.6}.content{padding:0}.branch-node{break-inside:avoid}}
