:root{--ink:#163533;--muted:#677b7a;--accent:#087e74;--line:#e0e9e7;--bs-primary:#087e74}body{background:#f5f8f7;color:var(--ink);font-family:Inter,system-ui,-apple-system,"Segoe UI",sans-serif;font-size:15px}a{text-decoration:none}button,a,input,select{touch-action:manipulation}[x-cloak]{display:none!important}.sidebar{width:246px;position:fixed;inset:0 auto 0 0;background:#103d38;padding:35px 22px;color:white;display:flex;flex-direction:column;z-index:10}.brand{display:flex;gap:12px;align-items:center;color:white;font-size:10px;letter-spacing:2px}.brand strong{display:block;font-size:34px;letter-spacing:-1px;line-height:1.1}.brand-mark{display:grid;place-items:center;border:1px solid #6a9f95;border-radius:12px;font-size:25px;width:45px;height:48px}.brand-dot,.text-accent{color:#41bda5}.nav-label{font-size:10px;letter-spacing:2px;color:#a3c1ba;margin:55px 12px 15px}.nav-item{display:flex;gap:14px;color:#c0d5d0;padding:13px 14px;margin:6px 0;border-radius:8px}.nav-item:hover,.nav-item.selected{color:white;background:#23554b}.nav-item.selected{box-shadow:inset 3px 0 #6fe0bb}.nav-item span{font-size:20px;line-height:1}.sidebar-note{margin-top:auto;font-size:12px;color:#d2e4df;line-height:2}.sidebar-note small{color:#9bbdb4}.status-dot{display:inline-block;width:7px;height:7px;background:#7cd2ad;border-radius:50%;margin-right:7px}.workspace{margin-left:246px}.topbar{height:83px;padding:0 44px;background:white;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;gap:16px}.breadcrumb-label{color:var(--muted);font-size:13px}.breadcrumb-label span{margin:0 16px;color:#bccbc8}.breadcrumb-label strong{font-weight:500;color:var(--ink)}.starter-badge,.connection-badge{display:inline-block;padding:6px 11px;border-radius:6px;font-size:11px;font-weight:600;white-space:nowrap}.starter-badge{background:#eef3f1;color:#526b65}.connection-badge{background:#e6f2ed;color:#356954}main{max-width:none;width:100%;margin:0;padding:43px 44px 50px;min-height:calc(100vh - 140px)}.eyebrow,.small-label,.panel-kicker{font-size:10px;font-weight:700;letter-spacing:1.8px}.eyebrow{color:var(--accent);margin-bottom:12px}h1{font-size:clamp(27px,3vw,38px);letter-spacing:-1.4px;font-weight:650;margin-bottom:12px}.page-intro{color:var(--muted);line-height:1.7;margin-bottom:30px}.welcome-panel{background:#164e44;border-radius:14px;color:white;padding:38px;display:flex;justify-content:space-between;align-items:center;overflow:hidden;margin-bottom:36px;gap:24px}.panel-kicker{color:#9bd7c1}.welcome-panel h2{font-size:32px;letter-spacing:-.7px;margin:18px 0}.welcome-panel p{max-width:450px;color:#bddbd0;line-height:1.7}.welcome-panel .btn{margin-top:8px;font-size:13px;padding:11px 18px}.welcome-panel .btn span{margin-left:20px}.one-art{font-size:clamp(80px,10vw,150px);font-weight:650;letter-spacing:-10px;color:#a3d8c8;transform:rotate(-9deg);padding-right:20px}.one-art span{color:#64bc9a}.section-heading{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:20px}.section-heading h2{font-size:18px;font-weight:600;margin:0}.section-heading>span{font-size:12px;color:var(--muted)}.module-card,.info-card{background:white;border:1px solid var(--line);padding:28px;border-radius:12px;height:100%;color:var(--ink)}.module-card{display:flex;gap:22px;transition:border-color .2s}.module-card:hover{border-color:var(--accent)}.module-icon{background:#e7f3ee;border-radius:10px;padding:7px 15px;color:var(--accent);font-size:28px;height:fit-content}.small-label{color:var(--muted);font-size:9px}h3{font-size:20px;margin:10px 0}.module-card p,.info-card p{color:var(--muted);font-size:13px;line-height:1.8}.text-link{color:var(--accent);font-size:13px;font-weight:600}.page-heading{display:flex;justify-content:space-between;align-items:center;gap:20px}.connection-notice{border:1px solid #cfe3db;background:#edf6f1;border-radius:10px;padding:20px;display:flex;gap:16px;align-items:center;margin-bottom:28px}.notice-icon{border:1px solid #81aa99;border-radius:50%;width:25px;height:25px;text-align:center;flex-shrink:0}.connection-notice strong{font-size:13px}.connection-notice p{margin:4px 0 0;color:var(--muted);font-size:12px}.connection-notice>.starter-badge{margin-left:auto}.inventory-panel{background:white;border:1px solid var(--line);border-radius:12px;overflow:hidden}.inventory-panel .section-heading{padding:25px 25px 0}.filter-form{padding:0 25px 24px}.form-label{font-size:12px;font-weight:500}.form-control,.form-select{font-size:13px;min-height:42px;border-color:#d9e3df}.btn{font-size:13px;min-height:40px;display:inline-flex;align-items:center;justify-content:center}.btn-primary{--bs-btn-bg:#087e74;--bs-btn-border-color:#087e74;--bs-btn-hover-bg:#08685f;--bs-btn-hover-border-color:#08685f;--bs-btn-active-bg:#08685f;--bs-btn-disabled-bg:#087e74;--bs-btn-disabled-border-color:#087e74}.table th{background:#f6f9f8;color:#667b74;font-size:11px;font-weight:600;padding:14px 24px;white-space:nowrap}.table td{font-size:13px;padding:14px 24px}.empty-state{text-align:center;padding:60px 12px 70px}.empty-icon{display:inline-grid;place-items:center;background:#f0f6f3;border:1px solid #dce9e2;border-radius:14px;width:60px;height:60px;color:#6e9c8b;font-size:32px;margin-bottom:14px}.empty-state h3{font-size:18px}.empty-state p,.page-footnote{font-size:12px;color:var(--muted)}.page-footnote{margin:18px 0}.mobile-toggle{display:none}footer{border-top:1px solid var(--line);margin:0 44px;padding:18px 0;color:#799087;font-size:10px;letter-spacing:1px;display:flex;justify-content:space-between}footer span{letter-spacing:0}.skip-link{position:absolute;top:8px;left:260px;background:white;padding:10px;z-index:100}:focus-visible{outline:3px solid #35ac93;outline-offset:3px}@media(max-width:991px){.sidebar{width:205px;padding:28px 16px}.workspace{margin-left:205px}main{padding:30px 24px}.topbar{padding:0 24px}.one-art{display:none}.welcome-panel{padding:28px}footer{margin:0 24px}}@media(max-width:640px){.sidebar{display:none;top:83px;width:230px}.sidebar.is-open{display:flex}.workspace{margin-left:0}.mobile-toggle{display:inline-flex}.breadcrumb-label{display:none}main{padding:28px 18px}.topbar{padding:0 18px}.page-heading{align-items:flex-start;flex-direction:column;gap:0;margin-bottom:20px}.page-heading .page-intro{margin-bottom:16px}.connection-notice{align-items:flex-start}.connection-notice>.starter-badge{display:none}.welcome-panel h2{font-size:27px}.section-heading>span{font-size:10px}.table th,.table td{padding:14px}.skip-link{left:18px}footer span{display:none}}


/* Authentication and signed-in user chrome */
.topbar-left,.user-menu,.user-summary{display:flex;align-items:center}.topbar-left{gap:16px}.user-menu{gap:14px}.user-summary{gap:9px}.user-summary>span:last-child{display:flex;flex-direction:column;line-height:1.25}.user-summary strong{font-size:12px;font-weight:600}.user-summary small{font-size:10px;color:var(--muted);max-width:220px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.user-avatar{display:grid;place-items:center;width:34px;height:34px;border-radius:50%;background:#e4f2ed;color:#176b5d;font-size:13px;font-weight:700}
.auth-page{min-height:100vh;background:#f4f8f7}.auth-shell{min-height:100vh;display:grid;grid-template-columns:minmax(340px,42%) 1fr}.auth-brand-panel{background:#123f39;color:white;padding:56px;display:flex;flex-direction:column;position:relative;overflow:hidden}.auth-brand-panel:after{content:"One.";position:absolute;right:-40px;bottom:40px;font-size:150px;font-weight:700;letter-spacing:-12px;color:rgba(151,220,197,.09);transform:rotate(-8deg)}.auth-brand-lockup{display:flex;align-items:center;gap:12px;position:relative;z-index:1}.auth-brand-name{font-size:10px;letter-spacing:2px}.auth-brand-name strong{display:block;font-size:34px;letter-spacing:-1px;line-height:1.05}.auth-brand-copy{margin:auto 0;position:relative;z-index:1;max-width:520px}.auth-eyebrow{color:#8ed4bd}.auth-brand-copy h1{font-size:clamp(38px,5vw,64px);letter-spacing:-3px;line-height:1.02;margin:18px 0 24px}.auth-brand-copy p{color:#b9d7ce;max-width:460px;line-height:1.8;font-size:15px}.auth-brand-footer{font-size:10px;letter-spacing:2px;color:#8fb7ac;position:relative;z-index:1}.auth-form-panel{display:grid;place-items:center;padding:42px}.auth-card-one{width:min(100%,440px);background:white;border:1px solid var(--line);border-radius:16px;padding:38px;box-shadow:0 18px 60px rgba(17,60,54,.08)}.auth-card-one h2{font-size:28px;letter-spacing:-.8px;margin:0 0 10px}.auth-intro{color:var(--muted);font-size:13px;margin-bottom:28px}.auth-card-one .form-control-lg{font-size:14px;min-height:50px}.auth-core-note{margin-top:24px;padding-top:18px;border-top:1px solid var(--line);color:var(--muted);font-size:11px}.auth-core-note .status-dot{background:#3ab98e}.auth-card-one .alert{font-size:12px;border-radius:9px}
@media(max-width:800px){.auth-shell{grid-template-columns:1fr}.auth-brand-panel{display:none}.auth-form-panel{padding:22px;min-height:100vh}.auth-card-one{padding:28px}.user-summary small{display:none}}
@media(max-width:640px){.user-summary>span:last-child{display:none}.user-menu{gap:8px}}

/* Formulations */
.detail-back{font-size:12px;margin-bottom:20px}.detail-back a{color:var(--accent);font-weight:600}.code-pill{display:inline-block;background:#eef4f2;border:1px solid #d9e6e2;border-radius:6px;padding:4px 8px;font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-size:11px;color:#315e56;white-space:nowrap}.status-chip,.company-chip{display:inline-block;border-radius:999px;padding:5px 9px;font-size:10px;font-weight:700;letter-spacing:.4px;background:#e5f4ed;color:#27705d}.status-chip.inactive{background:#f1f2f2;color:#77807e}.company-chip{background:#edf2f8;color:#49657b}.formulation-description{max-width:420px}.formulation-table tbody tr:hover{background:#fbfdfc}.formulation-hero{padding-bottom:12px}.recipe-meta{display:grid;grid-template-columns:repeat(4,1fr);gap:12px}.recipe-meta>div{background:#f6f9f8;border:1px solid var(--line);border-radius:9px;padding:14px}.recipe-meta span{display:block;font-size:9px;letter-spacing:1px;text-transform:uppercase;color:var(--muted);margin-bottom:6px}.recipe-meta strong{font-size:13px}.recipe-table tfoot th{background:#f4f8f6;border-top:2px solid #dbe7e3}.revision-list{display:flex;flex-direction:column}.revision-row{display:flex;justify-content:space-between;gap:12px;padding:13px 0;border-bottom:1px solid var(--line)}.revision-row:last-child{border-bottom:0}.revision-row div{display:flex;flex-direction:column}.revision-row strong{font-size:12px}.revision-row small,.revision-row>span{font-size:10px;color:var(--muted)}
@media(max-width:800px){.recipe-meta{grid-template-columns:repeat(2,1fr)}.formulation-description{max-width:220px}}

/* Formulations v2 */
.formulations-heading{padding-bottom:18px!important;margin-bottom:0!important;border-bottom:1px solid var(--line)}
.formulations-heading>div:first-child{display:flex;flex-direction:column;gap:4px}.table-subtitle{font-size:11px!important;color:var(--muted)}.table-actions{display:flex;gap:8px}.formulation-toolbar{display:grid;grid-template-columns:minmax(280px,1fr) 220px 180px;gap:14px;padding:20px 25px;border-bottom:1px solid var(--line);background:#fbfcfc}.toolbar-field{min-width:0}.one-tabulator{border:0!important;background:white}.tabulator{border:0!important;background:white;font-size:13px}.tabulator .tabulator-header{border-bottom:1px solid var(--line);background:#f6f9f8}.tabulator .tabulator-header .tabulator-col{background:#f6f9f8;border-right:0;color:#667b74}.tabulator .tabulator-header .tabulator-col .tabulator-col-content{padding:13px 14px}.tabulator-row{border-bottom:1px solid #edf2f0;background:white;min-height:48px}.tabulator-row:hover{background:#fbfdfc!important}.tabulator-row .tabulator-cell{border-right:0;padding:12px 14px;vertical-align:middle;line-height:1.45}.tabulator .tabulator-footer{border-top:1px solid var(--line);background:#fbfcfc;padding:10px 14px}.tabulator .tabulator-footer .tabulator-page{border-color:#d7e3df;background:white;border-radius:6px}.regional-selector{display:flex;align-items:center;justify-content:space-between;gap:20px;background:white;border:1px solid var(--line);border-radius:12px;padding:18px 22px;margin-bottom:22px}.regional-selector-copy{display:flex;flex-direction:column;gap:4px}.regional-selector-copy strong{font-size:13px}.regional-selector-copy span{font-size:11px;color:var(--muted)}.regional-tabs{display:flex;gap:8px;flex-wrap:wrap}.regional-tab{display:flex;align-items:center;gap:7px;padding:9px 13px;border:1px solid var(--line);border-radius:8px;background:#fff;color:var(--ink);font-size:12px;font-weight:600}.regional-tab:hover{border-color:#7faaa1;color:var(--accent)}.regional-tab.selected{background:#e8f5f1;border-color:#8bc8b8;color:#11675c}.regional-flag{font-size:18px}.formulation-detail-heading .page-intro{margin-bottom:24px}.recipe-meta{grid-template-columns:repeat(4,minmax(0,1fr))}.step-pill{display:inline-grid;place-items:center;min-width:28px;height:24px;padding:0 7px;border-radius:6px;background:#eef4f2;color:#315e56;font-size:11px;font-weight:700}.revision-row{color:var(--ink);padding:13px 10px;border-radius:8px}.revision-row:hover{background:#f6f9f8}.revision-row.selected{background:#eaf5f1}.revision-row>span{align-self:center}.company-chip{white-space:nowrap}.me-1{margin-right:.25rem}
@media(max-width:900px){.formulation-toolbar{grid-template-columns:1fr 1fr}.toolbar-search{grid-column:1/-1}.regional-selector{align-items:flex-start;flex-direction:column}.recipe-meta{grid-template-columns:repeat(2,1fr)}}
@media(max-width:600px){.formulation-toolbar{grid-template-columns:1fr}.toolbar-search{grid-column:auto}.recipe-meta{grid-template-columns:1fr 1fr}.regional-tabs{width:100%}.regional-tab{flex:1;justify-content:center}}

/* Liquitherm One table/flag fixes */
.tabulator-row{min-height:48px!important}
.tabulator-row .tabulator-cell{min-height:48px;white-space:normal}
.company-chip{display:inline-flex;align-items:center;gap:6px;vertical-align:middle}
.company-flag{display:inline-block;width:20px;height:12px;object-fit:cover;border-radius:2px;box-shadow:0 0 0 1px rgba(22,53,51,.12);flex:0 0 auto}
.regional-flag .company-flag,.regional-tab .company-flag{width:24px;height:15px}
.company-inline{display:inline-flex;align-items:center;gap:6px}

/* Liquitherm One corporate theme - blue + orange */
:root{
  --liquitherm-blue:#579cc3;
  --liquitherm-blue-dark:#245879;
  --liquitherm-blue-deep:#173f59;
  --liquitherm-blue-soft:#eaf3f7;
  --liquitherm-orange:#f39200;
  --liquitherm-orange-soft:#fff3df;
  --ink:#17394b;
  --muted:#687d89;
  --accent:var(--liquitherm-blue-dark);
  --line:#dbe6ec;
  --bs-primary:var(--liquitherm-blue-dark);
}
body{background:#f5f8fa;color:var(--ink)}
.sidebar{background:var(--liquitherm-blue-deep)}
.brand-dot,.text-accent{color:var(--liquitherm-orange)}
.brand-mark{border-color:rgba(255,255,255,.32)}
.nav-label{color:#a9c7d8}
.nav-item{color:#c8dce7}
.nav-item:hover,.nav-item.selected{background:#245b7b;color:#fff}
.nav-item.selected{box-shadow:inset 3px 0 var(--liquitherm-orange)}
.sidebar-note{color:#d7e7ef}.sidebar-note small{color:#a7c4d4}
.status-dot{background:var(--liquitherm-orange)}
.connection-badge{background:var(--liquitherm-blue-soft);color:var(--liquitherm-blue-dark)}
.eyebrow{color:var(--liquitherm-orange)}
.welcome-panel{background:var(--liquitherm-blue-dark)}
.panel-kicker{color:#d5eaf5}.welcome-panel p{color:#d6e7f0}
.one-art{color:#7db4d2}.one-art span{color:var(--liquitherm-orange)}
.module-icon{background:var(--liquitherm-blue-soft);color:var(--liquitherm-blue-dark)}
.module-card:hover{border-color:var(--liquitherm-blue)}
.connection-notice{border-color:#c7dce7;background:#eef6fa}.notice-icon{border-color:#8db9d1}
.btn-primary{--bs-btn-bg:var(--liquitherm-blue-dark);--bs-btn-border-color:var(--liquitherm-blue-dark);--bs-btn-hover-bg:#1b4866;--bs-btn-hover-border-color:#1b4866;--bs-btn-active-bg:#173f59;--bs-btn-active-border-color:#173f59;--bs-btn-disabled-bg:var(--liquitherm-blue-dark);--bs-btn-disabled-border-color:var(--liquitherm-blue-dark)}
:focus-visible{outline-color:var(--liquitherm-orange)}
.user-avatar{background:var(--liquitherm-blue-soft);color:var(--liquitherm-blue-dark)}
.auth-page{background:#f4f8fa}.auth-brand-panel{background:var(--liquitherm-blue-deep)}.auth-eyebrow{color:var(--liquitherm-orange)}.auth-brand-copy p{color:#c8dfe9}.auth-brand-footer{color:#a9c6d5}
.auth-core-note .status-dot{background:var(--liquitherm-orange)}
.code-pill{background:#eef5f8;border-color:#d4e4ec;color:#315d77}
.status-chip{background:var(--liquitherm-blue-soft);color:var(--liquitherm-blue-dark)}
.status-chip.inactive{background:#f1f2f2;color:#77807e}
.company-chip{background:#f2f6f9;color:#425f73}
.recipe-meta>div{background:#f7fafc}
.recipe-table tfoot th{background:#f2f7fa;border-top-color:#d5e4eb}
.regional-tab:hover{border-color:var(--liquitherm-blue);color:var(--liquitherm-blue-dark)}
.regional-tab.selected{background:var(--liquitherm-blue-soft);border-color:var(--liquitherm-blue);color:var(--liquitherm-blue-dark);box-shadow:inset 0 -3px var(--liquitherm-orange)}
.step-pill{background:#eef5f8;color:#315d77}
.revision-row:hover{background:#f5f9fb}.revision-row.selected{background:var(--liquitherm-blue-soft);box-shadow:inset 3px 0 var(--liquitherm-orange)}
.tabulator-row:hover{background:#f7fbfd!important}.tabulator .tabulator-header,.tabulator .tabulator-header .tabulator-col{background:#f2f7fa}

/* Commercial offering groups */
.commercial-products-panel .section-heading{padding-bottom:18px;border-bottom:1px solid var(--line);margin-bottom:0}
.commercial-products-toolbar{display:flex;align-items:end;gap:14px;padding:18px 25px;background:#fbfdfe;border-bottom:1px solid var(--line)}
.commercial-products-toolbar .toolbar-field{width:min(420px,100%)}
.offering-groups{padding:18px 20px 24px;display:flex;flex-direction:column;gap:10px}
.offering-group{border:1px solid var(--line);border-radius:10px;background:#fff;overflow:hidden}
.offering-group[open]{box-shadow:0 5px 18px rgba(36,88,121,.06)}
.offering-group summary{list-style:none;display:flex;align-items:center;justify-content:space-between;gap:16px;padding:14px 16px;cursor:pointer;background:#f8fbfc}
.offering-group summary::-webkit-details-marker{display:none}
.offering-group summary:hover{background:#f2f7fa}
.offering-group-title{display:flex;align-items:center;gap:10px;font-weight:700;color:var(--ink)}
.offering-group-title:before{content:'›';display:inline-grid;place-items:center;width:22px;height:22px;border-radius:50%;background:var(--liquitherm-blue-soft);color:var(--liquitherm-blue-dark);font-size:18px;line-height:1;transition:transform .15s ease}
.offering-group[open] .offering-group-title:before{transform:rotate(90deg);background:var(--liquitherm-orange-soft);color:#b76500}
.offering-group-count{font-size:11px;font-weight:700;color:var(--liquitherm-blue-dark);background:var(--liquitherm-blue-soft);border-radius:999px;padding:5px 9px;white-space:nowrap}
.offering-group-table{margin:0}
.offering-group-table th{padding:10px 16px;background:#fff;border-top:1px solid var(--line)}
.offering-group-table td{padding:10px 16px}
.offering-group-table tbody tr:last-child td{border-bottom:0}
.offering-name{font-weight:650}
.offering-company{width:135px}.offering-code{width:190px}
.commercial-empty{padding:34px;text-align:center;color:var(--muted)}
@media(max-width:700px){.commercial-products-toolbar{align-items:stretch;flex-direction:column}.commercial-products-toolbar .toolbar-field{width:100%}.offering-company,.offering-code{width:auto}.offering-group-table th,.offering-group-table td{padding:10px}}


/* Liquitherm brand mark */
.brand-logo{display:block;width:48px;height:48px;object-fit:contain;flex:0 0 48px}
.auth-brand-logo{width:54px;height:54px;flex-basis:54px}
@media(max-width:991px){.brand-logo{width:44px;height:44px;flex-basis:44px}}

/* Inventory v1 */
.inventory-toolbar{display:grid;grid-template-columns:minmax(300px,1.5fr) 180px 220px 180px;gap:14px;padding:20px 25px;border-bottom:1px solid var(--line);background:#fbfdfe}.inventory-search{min-width:0}.stock-number{font-variant-numeric:tabular-nums;font-weight:650}.stock-number.negative{color:#b33b32}.stock-number.zero{color:var(--muted);font-weight:500}.site-list{display:flex;gap:5px;flex-wrap:wrap}.site-pill{display:inline-flex;align-items:center;border:1px solid #d9e5eb;background:#f7fafc;border-radius:999px;padding:3px 7px;font-size:10px;color:#526b79}.item-type-chip{display:inline-flex;border-radius:999px;padding:4px 8px;background:var(--liquitherm-blue-soft);color:var(--liquitherm-blue-dark);font-size:10px;font-weight:700;white-space:nowrap}.inventory-kpis{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:14px;margin-bottom:24px}.inventory-kpi{background:white;border:1px solid var(--line);border-radius:12px;padding:18px 20px;box-shadow:0 4px 18px rgba(36,88,121,.035)}.inventory-kpi span{display:block;color:var(--muted);font-size:10px;text-transform:uppercase;letter-spacing:1px;margin-bottom:7px}.inventory-kpi strong{font-size:20px;letter-spacing:-.4px}.inventory-kpi-accent{border-top:3px solid var(--liquitherm-orange)}.item-profile-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px 20px;margin:0}.item-profile-grid div{border-bottom:1px solid var(--line);padding-bottom:12px}.item-profile-grid dt{font-size:9px;text-transform:uppercase;letter-spacing:1px;color:var(--muted);margin-bottom:4px}.item-profile-grid dd{font-size:13px;font-weight:650;margin:0}.legacy-location-note{font-size:10px;color:#9a6500;margin-top:3px}.movement-type{display:inline-flex;border-radius:6px;background:#f1f6f9;color:#365e75;padding:4px 7px;font-size:10px;font-weight:700;text-transform:uppercase}.qty-positive{color:#276b59;font-weight:700}.qty-negative{color:#b33b32;font-weight:700}.movement-table td,.inventory-location-table td{font-size:12px}.inventory-detail-heading .page-intro{margin-bottom:24px}
@media(max-width:1100px){.inventory-toolbar{grid-template-columns:1fr 1fr}.inventory-search{grid-column:1/-1}.inventory-kpis{grid-template-columns:repeat(3,1fr)}}
@media(max-width:700px){.inventory-toolbar{grid-template-columns:1fr}.inventory-search{grid-column:auto}.inventory-kpis{grid-template-columns:1fr 1fr}.item-profile-grid{grid-template-columns:1fr}}

.purchase-order-batches > td {
    background: rgba(15, 74, 110, 0.025);
    padding: 0;
}

.purchase-order-batches-inner {
    padding: 1rem 1.25rem 1.25rem;
}

.batch-breakdown-table {
    margin-bottom: 0;
}

.batch-breakdown-table thead th {
    font-size: 0.72rem;
}


/* Formulation revision foundation - Phase 1A */
.revision-notice{display:flex;align-items:flex-start;gap:12px;border:1px solid var(--line);border-radius:10px;padding:14px 18px;margin:-8px 0 20px;background:#fff}.revision-notice>div{display:flex;flex-direction:column;gap:3px}.revision-notice strong{font-size:12px}.revision-notice span{font-size:11px;color:var(--muted)}.revision-notice-success{border-color:#b9dfcf;background:#f0faf6}.revision-notice-success strong{color:#246b58}.revision-notice-warning{border-color:#efd29a;background:#fff8eb}.revision-notice-warning strong{color:#9a6200}
.lifecycle-status{letter-spacing:.7px}.lifecycle-active{background:#e5f4ed!important;color:#27705d!important}.lifecycle-sandbox{background:var(--liquitherm-orange-soft)!important;color:#9a5a00!important}.lifecycle-superseded{background:#eef1f3!important;color:#6d7880!important}.revision-mini-status{display:inline-flex;align-items:center;border-radius:999px;padding:4px 8px;font-size:9px!important;font-weight:800;letter-spacing:.6px}
.revision-action-bar{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-top:18px;padding:15px 16px;border:1px solid #d8e6ed;border-radius:10px;background:#f8fbfd}.revision-action-bar>div{display:flex;flex-direction:column;gap:3px}.revision-action-bar strong{font-size:12px}.revision-action-bar span{font-size:11px;color:var(--muted)}.revision-clone-button{white-space:nowrap}.formulation-hero .recipe-meta{grid-template-columns:repeat(4,minmax(0,1fr))}
@media(max-width:800px){.revision-action-bar{align-items:stretch;flex-direction:column}.revision-clone-button{width:100%}.formulation-hero .recipe-meta{grid-template-columns:repeat(2,minmax(0,1fr))}}

/* Phase 1B - editable sandbox ingredients */
.sandbox-recipe-table .sandbox-quantity{width:130px;margin-left:auto;text-align:right;font-weight:700}.sandbox-actions{width:92px}.sandbox-editor-footer{border:1px solid var(--line);border-top:0;border-radius:0 0 10px 10px;background:#fbfdfc;padding:16px}.sandbox-add-material{display:grid;grid-template-columns:minmax(280px,1fr) 150px auto;gap:12px;align-items:end}.sandbox-add-material label{display:block;margin-bottom:5px;font-size:10px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);font-weight:700}.sandbox-save-area{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-top:16px;padding-top:14px;border-top:1px solid var(--line)}.sandbox-save-area span{font-size:11px;color:var(--muted)}.sandbox-save-area span.changed{color:#9b6200;font-weight:700}.sandbox-recipe-table .btn-outline-danger{border-color:#e1b9b9;color:#9f3838}.sandbox-recipe-table .btn-outline-danger:hover{background:#fff1f1;border-color:#d99b9b;color:#812b2b}@media(max-width:800px){.sandbox-add-material{grid-template-columns:1fr}.sandbox-save-area{align-items:stretch;flex-direction:column}.sandbox-save-area .btn{width:100%}}

.sandbox-inline-message{margin:14px 0 0;padding:11px 13px;border-radius:8px;font-size:12px;font-weight:600}.sandbox-inline-message-error{border:1px solid #edc2c2;background:#fff4f4;color:#8d2f2f}.sandbox-inline-message-success{border:1px solid #bddfcb;background:#f1fbf5;color:#246a42}.sandbox-add-material select option:disabled{color:#9aa5ad;background:#f3f6f8}
/* Phase 1D - controlled formulation approval */
.revision-promote-button{white-space:nowrap;margin-left:auto}.missing-sg-badge{display:inline-flex;margin-left:7px;padding:2px 6px;border-radius:999px;background:#fff2d9;color:#9a5b00;font-size:9px;font-weight:800;letter-spacing:.04em;text-transform:uppercase;vertical-align:middle}.revision-modal-backdrop{position:fixed;inset:0;z-index:1080;display:flex;align-items:center;justify-content:center;padding:20px;background:rgba(8,35,52,.48);backdrop-filter:blur(3px)}.revision-modal-backdrop.d-none{display:none!important}.revision-modal-card{width:min(520px,100%);padding:28px;border:1px solid #d8e6ed;border-radius:16px;background:#fff;box-shadow:0 24px 70px rgba(8,35,52,.25)}.revision-modal-icon{display:grid;place-items:center;width:42px;height:42px;margin-bottom:16px;border-radius:12px;background:#e8f7ee;color:#237a48;font-size:22px;font-weight:900}.revision-modal-card h3{margin:0 0 10px;font-size:20px;color:var(--navy)}.revision-modal-card p{margin:0;color:var(--muted);font-size:13px;line-height:1.6}.revision-modal-warning{margin:18px 0;padding:12px 14px;border-radius:9px;background:#f5f9fb;border:1px solid #dce9ef;color:#345466;font-size:12px}.revision-modal-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:20px}.revision-audit{display:block!important;margin-top:4px;color:#78909d!important;font-size:10px!important}.sandbox-remove:focus{box-shadow:0 0 0 2px rgba(220,53,69,.16)!important}.sandbox-quantity:focus{position:relative;z-index:1}
@media(max-width:800px){.revision-promote-button{width:100%;margin-left:0}.revision-modal-actions{flex-direction:column-reverse}.revision-modal-actions .btn{width:100%}}

/* Phase 2B - manufacturing procedure builder */
.procedure-panel{margin-top:24px;margin-bottom:24px}.procedure-heading{align-items:center}.procedure-heading-meta{display:flex;align-items:center;gap:10px}.procedure-count{font-size:11px;color:var(--muted)}.procedure-foundation-warning{margin:18px 20px}.procedure-toolbar{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:16px 20px;border-bottom:1px solid var(--line);background:#fbfdfe}.procedure-toolbar>div:first-child{display:flex;flex-direction:column;gap:3px}.procedure-toolbar strong{font-size:12px}.procedure-toolbar span{font-size:11px;color:var(--muted)}.procedure-toolbar-actions{display:flex;gap:8px;flex-wrap:wrap}.procedure-table th{font-size:10px;letter-spacing:.03em;text-transform:uppercase;color:var(--muted);white-space:nowrap}.procedure-table td{vertical-align:middle}.procedure-step-col{width:70px}.procedure-type-col{width:135px}.procedure-material-col{width:220px}.procedure-qty-col{width:120px}.procedure-parent-col{width:210px}.procedure-actions-col{width:170px}.procedure-row-actions{white-space:nowrap}.procedure-row-actions .btn{margin-left:4px}.procedure-save-bar{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:15px 20px;border-top:1px solid var(--line);background:#fbfdfc}.procedure-save-bar span{font-size:11px;color:var(--muted)}.procedure-save-bar span.changed{color:#9b6200;font-weight:700}.procedure-readonly-wrap{position:relative}.procedure-readonly-list{padding:6px 14px 10px}.procedure-readonly-step{display:flex;align-items:center;gap:9px;min-height:32px;padding:5px 8px;border-bottom:1px solid var(--line)}.procedure-readonly-step:last-child{border-bottom:0}.procedure-readonly-copy{display:flex;flex-direction:column;gap:1px;min-width:0}.procedure-readonly-copy strong{font-size:11.5px;line-height:1.25}.procedure-readonly-copy span{font-size:10px;line-height:1.2;color:var(--muted)}.procedure-readonly-step .step-pill{flex:0 0 auto;min-width:26px;height:22px;padding:0 6px;font-size:10px}.procedure-readonly-wrap.is-collapsible.is-collapsed .procedure-readonly-list{max-height:344px;overflow:hidden}.procedure-readonly-wrap.is-collapsible.is-collapsed .procedure-readonly-list:after{content:"";position:absolute;left:0;right:0;bottom:42px;height:42px;pointer-events:none;background:linear-gradient(to bottom,rgba(255,255,255,0),#fff)}.procedure-collapse-footer{display:flex;justify-content:center;padding:7px 14px 10px;border-top:1px solid var(--line);background:#fbfdfe}.procedure-collapse-toggle{min-width:160px}.procedure-table th,.procedure-table td{padding:7px 8px}.procedure-toolbar{padding:11px 14px}.procedure-save-bar{padding:10px 14px;position:sticky;bottom:0;z-index:3;box-shadow:0 -4px 12px rgba(8,35,52,.05)}.procedure-section-step{margin-top:8px;background:#f7fafc;border-radius:8px;border-bottom:0}.procedure-section-step .procedure-readonly-copy strong{color:var(--liquitherm-blue-dark)}.procedure-child-step{margin-left:40px;background:#fcfdfd}.procedure-type,.procedure-material,.procedure-parent,.procedure-instruction,.procedure-quantity{min-height:34px}.procedure-parent:disabled,.procedure-material:disabled,.procedure-quantity:disabled{background:#f3f6f7;color:#8b999f}.procedure-table tr[data-step-type="SECTION"]{background:#f8fbfd}.procedure-table tr[data-step-type="SECTION"] .procedure-instruction{font-weight:700}.procedure-table tr[data-step-type="SECTION"] .step-pill{background:var(--liquitherm-blue-soft);color:var(--liquitherm-blue-dark)}
@media(max-width:1100px){.procedure-toolbar{align-items:stretch;flex-direction:column}.procedure-toolbar-actions{width:100%}.procedure-toolbar-actions .btn{flex:1 1 auto}.procedure-table{min-width:1180px}}
@media(max-width:700px){.procedure-save-bar{align-items:stretch;flex-direction:column}.procedure-save-bar .btn{width:100%}.procedure-heading-meta{align-items:flex-end;flex-direction:column}}
.procedure-field-inactive{pointer-events:none;background:#f3f6f7!important;color:#8b999f!important}


/* Phase 2B.1 formulation audit */
.formulation-audit-panel{margin-top:1.5rem;margin-bottom:1.5rem}.audit-timeline{display:flex;flex-direction:column}.audit-event{display:grid;grid-template-columns:12px minmax(0,1fr) auto;gap:.75rem;align-items:center;padding:.7rem .25rem;border-top:1px solid var(--bs-border-color,#dee2e6)}.audit-event:first-child{border-top:0}.audit-dot{width:8px;height:8px;border-radius:50%;background:currentColor;opacity:.45}.audit-event-main{min-width:0}.audit-event-main strong{display:block;font-size:.92rem}.audit-event-main span{display:block;margin-top:.12rem;font-size:.78rem;color:var(--bs-secondary-color,#6c757d)}.audit-action-badge{font-size:.68rem;font-weight:700;letter-spacing:.04em;padding:.2rem .45rem;border:1px solid var(--bs-border-color,#dee2e6);border-radius:999px}.compact-empty{padding:1.25rem}.compact-empty h3{font-size:1rem;margin-bottom:.25rem}.compact-empty p{margin:0}

/* Phase 2B.3 - Concentrations / Premixes */
.concentration-panel{margin-top:1.5rem;margin-bottom:1.5rem}.concentration-intro{padding:.7rem 1rem;border-bottom:1px solid var(--line);background:#fbfdfe;font-size:.82rem;color:var(--muted)}.concentration-intro strong{color:var(--liquitherm-blue-dark)}.concentration-table th{font-size:10px;letter-spacing:.03em;text-transform:uppercase;color:var(--muted);white-space:nowrap}.concentration-table td{font-size:.84rem;vertical-align:top}.concentration-table input,.concentration-table select,.concentration-table textarea{min-width:110px}.concentration-table .concentration-pct{min-width:86px}.concentration-recipe-cell{min-width:280px}.concentration-save-bar{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:14px;padding:10px 14px;border-top:1px solid var(--line);background:#fbfdfc;position:sticky;bottom:0;z-index:3;box-shadow:0 -4px 12px rgba(8,35,52,.05)}.concentration-save-bar span{font-size:11px;color:var(--muted)}.concentration-save-bar span.changed{color:#9b6200;font-weight:700}.concentration-recipe-details summary{cursor:pointer;display:flex;align-items:center;gap:8px}.concentration-recipe-details ol{margin:.6rem 0 0 1.2rem;padding:0;font-size:.78rem}.concentration-recipe-details li{margin:.25rem 0}.concentration-custom-chip{background:#fff3cd;color:#765700}.concentration-default-chip{background:#eef8f1;color:#27633a}@media(max-width:900px){.concentration-save-bar{grid-template-columns:1fr}.concentration-save-bar .btn{width:100%}}

.test-spec-panel{margin-top:1.5rem;margin-bottom:1.5rem}.test-spec-intro{padding:.7rem 1rem;border-bottom:1px solid var(--line);background:#fbfdfe;font-size:.82rem;color:var(--muted)}.test-spec-intro strong{color:var(--liquitherm-blue-dark)}.test-spec-table th{font-size:10px;letter-spacing:.03em;text-transform:uppercase;color:var(--muted);white-space:nowrap}.test-spec-table td{font-size:.84rem;vertical-align:middle}.test-spec-table input{min-width:82px}.test-spec-table td:nth-child(2) input{min-width:180px}.ri-model-readonly,.ri-model-editor{padding:12px 14px;border-top:1px solid var(--line);background:#fbfdfe}.ri-formula-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-top:8px}.ri-formula-grid div{min-width:0}.ri-formula-grid span{display:block;font-size:10px;text-transform:uppercase;color:var(--muted);margin-bottom:4px}.ri-formula-grid code{display:block;white-space:normal;overflow-wrap:anywhere;font-size:.72rem}.test-spec-save-bar{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:14px;padding:10px 14px;border-top:1px solid var(--line);background:#fbfdfc;position:sticky;bottom:0;z-index:3}.test-spec-save-bar span{font-size:11px;color:var(--muted)}.test-spec-save-bar span.changed{color:#9b6200;font-weight:700}@media(max-width:900px){.ri-formula-grid,.test-spec-save-bar{grid-template-columns:1fr}.test-spec-save-bar .btn{width:100%}}
.regulatory-subsection{border-top:1px solid var(--line);padding:20px 24px}.regulatory-subsection .section-heading{padding:0;margin:0 0 12px}.regulatory-subsection h3,.regulatory-readonly-grid h3{font-size:14px;margin:0 0 8px}.reg-edit-row{display:flex;gap:10px;align-items:flex-start;margin-bottom:10px}.reg-edit-row textarea{min-height:62px}.reg-edit-row-grid{display:grid;grid-template-columns:140px minmax(240px,1fr) auto}.regulatory-readonly-grid{display:grid;grid-template-columns:1fr 1fr;gap:0;border-top:1px solid var(--line)}.regulatory-readonly-grid>div{padding:20px 24px;border-right:1px solid var(--line);border-bottom:1px solid var(--line)}.regulatory-readonly-grid>div:nth-child(2n){border-right:0}.regulatory-readonly-grid .reg-statements{grid-column:1/-1;border-right:0}.regulatory-readonly-grid ul{margin:0;padding-left:20px}.regulatory-readonly-grid li{margin:7px 0;line-height:1.5}.reg-pictogram-list{display:flex;flex-wrap:wrap;gap:7px}@media(max-width:760px){.reg-edit-row-grid{grid-template-columns:1fr}.regulatory-readonly-grid{grid-template-columns:1fr}.regulatory-readonly-grid>div{border-right:0}.regulatory-readonly-grid .reg-statements{grid-column:auto}}

/* Formulations workspace polish */
.formulation-library-summary{display:grid;grid-template-columns:repeat(3,minmax(150px,1fr)) minmax(260px,1.4fr);gap:14px;margin:0 0 22px}.library-summary-card{background:#fff;border:1px solid var(--line);border-radius:12px;padding:18px 20px;min-height:108px;display:flex;flex-direction:column;justify-content:center}.library-summary-card>span{font-size:10px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);font-weight:700}.library-summary-card>strong{font-size:30px;line-height:1.15;margin:4px 0;color:var(--ink)}.library-summary-card>small{color:var(--muted);font-size:11px}.library-summary-regions>div{display:flex;gap:6px;flex-wrap:wrap;margin:8px 0}.library-summary-regions .company-chip b{margin-left:4px}.formulation-library-panel{box-shadow:0 8px 28px rgba(18,63,57,.035)}
.formulation-workspace-bar{display:flex;align-items:center;justify-content:space-between;gap:16px;border:1px solid var(--line);border-radius:12px;padding:14px 16px;margin:0 0 10px;background:#fff}.formulation-workspace-bar.is-sandbox{border-color:#edd69b;background:#fffaf0}.formulation-workspace-bar.is-readonly{background:#f9fbfa}.formulation-workspace-state{display:flex;align-items:center;gap:12px}.workspace-state-icon{width:34px;height:34px;border-radius:9px;display:grid;place-items:center;background:#e9f5f1;color:#176c5e;font-weight:800}.is-sandbox .workspace-state-icon{background:#fff0c7;color:#8a6300}.formulation-workspace-state strong,.formulation-workspace-state span{display:block}.formulation-workspace-state strong{font-size:13px}.formulation-workspace-state div>span{font-size:11px;color:var(--muted);margin-top:2px}.workspace-review-link{font-size:11px;font-weight:700;color:#7b5a00;white-space:nowrap}.workspace-review-link span{margin-left:6px}.formulation-subnav{position:sticky;top:0;z-index:7;display:flex;gap:5px;overflow:auto;padding:8px;margin:0 0 20px;background:rgba(245,248,247,.94);backdrop-filter:blur(8px);border:1px solid var(--line);border-radius:11px}.formulation-subnav a{display:inline-flex;align-items:center;gap:7px;padding:8px 11px;border-radius:8px;color:#4d6864;font-size:11px;font-weight:700;white-space:nowrap}.formulation-subnav a:hover{background:#fff;color:var(--accent)}.formulation-subnav a span{display:inline-grid;place-items:center;min-width:21px;height:21px;padding:0 6px;border-radius:999px;background:#e8efed;color:#61736f;font-size:9px}.formulation-subnav a:hover span{background:#e4f4ef;color:#176c5e}
.section-kicker{font-size:9px;letter-spacing:.12em;font-weight:800;color:#9b6d00;margin-bottom:5px}.revision-review-panel{margin:0 0 24px;border-color:#e7d7ab}.revision-review-heading{background:linear-gradient(180deg,#fffdf7,#fff);padding-bottom:18px!important;margin-bottom:0!important}.review-change-count{border-radius:999px;padding:6px 10px;background:#edf3f1;color:#5c716d;font-size:10px!important;font-weight:700}.review-change-count.has-changes{background:#fff0c7;color:#815d00}.revision-review-grid{display:grid;grid-template-columns:repeat(6,minmax(110px,1fr));gap:10px;padding:16px 20px;border-top:1px solid var(--line)}.revision-review-card{border:1px solid var(--line);border-radius:10px;padding:12px;display:flex;flex-direction:column;gap:3px;color:var(--ink);background:#fbfdfc;min-width:0}.revision-review-card:hover{border-color:#a9cfc5}.revision-review-card.changed{border-color:#e7ce88;background:#fffbef}.revision-review-card strong{font-size:12px}.revision-review-card small{font-size:10px;color:var(--muted)}.review-card-state{font-size:9px;font-weight:800;text-transform:uppercase;letter-spacing:.08em;color:#67817a}.revision-review-card.changed .review-card-state{color:#8b6200}.recipe-diff-details{border-top:1px solid var(--line)}.recipe-diff-details summary{cursor:pointer;padding:13px 20px;font-size:11px;font-weight:700}.recipe-diff-details summary span{margin-left:6px;border-radius:999px;background:#fff0c7;padding:2px 7px;color:#815d00}.recipe-diff-list{border-top:1px solid var(--line)}.recipe-diff-row{display:grid;grid-template-columns:70px minmax(180px,1fr) auto;align-items:center;gap:12px;padding:10px 20px;border-bottom:1px solid #edf2f0;font-size:11px}.recipe-diff-row:last-child{border-bottom:0}.diff-type{font-size:9px;text-transform:uppercase;font-weight:800;letter-spacing:.06em}.diff-added .diff-type{color:#23754f}.diff-removed .diff-type{color:#a24747}.diff-changed .diff-type{color:#8b6200}.diff-values{font-family:ui-monospace,SFMono-Regular,Menlo,monospace;color:#4c625e}.diff-values b{padding:0 6px;color:#91a29e}.review-no-recipe-change{padding:13px 20px;border-top:1px solid var(--line);font-size:11px;color:var(--muted)}
.promotion-review-summary{border:1px solid #dce6e3;border-radius:9px;padding:12px 14px;margin-top:12px;background:#fbfdfc}.promotion-review-summary>strong{font-size:11px}.promotion-review-summary>div{display:flex;gap:6px;flex-wrap:wrap;margin:8px 0}.promotion-review-summary span{font-size:9px;padding:4px 7px;border-radius:999px;background:#edf2f1;color:#687976}.promotion-review-summary span.changed{background:#fff0c7;color:#815d00;font-weight:700}.promotion-review-summary small{display:block;color:var(--muted);font-size:10px}.audit-human-detail{display:block!important;margin-top:4px!important;color:#536b66!important;font-size:10px!important;font-weight:600}.formulation-audit-panel .audit-event{padding:.85rem 1rem}.formulation-audit-panel .audit-event:hover{background:#fbfdfc}
#formulation-recipe,#manufacturing-procedure,#qc-tests,#concentrations,#regulatory,#labels,#audit-history{scroll-margin-top:78px}.product-label-panel,.formulation-regulatory-panel,.test-spec-panel,.concentration-panel,.procedure-panel,.formulation-audit-panel,.revision-review-panel{box-shadow:0 8px 26px rgba(18,63,57,.028)}.regulatory-readonly-grid li{padding-left:2px}.reg-pictogram-list .code-pill{padding:6px 9px}.product-label-panel details summary{cursor:pointer;color:var(--accent);font-weight:600}.procedure-toolbar{background:linear-gradient(180deg,#fcfefd,#f8fbfa)}.procedure-row-actions .procedure-up,.procedure-row-actions .procedure-down{width:32px;padding:0;font-weight:700}.procedure-table tbody tr:hover{background:#fbfdfc}.procedure-table tr[data-step-type="SECTION"]{box-shadow:inset 3px 0 #8fbdb2}.procedure-save-bar{background:#fff}.sandbox-inline-message{border-radius:9px}
@media(max-width:1200px){.formulation-library-summary{grid-template-columns:repeat(2,1fr)}.revision-review-grid{grid-template-columns:repeat(3,1fr)}}@media(max-width:760px){.formulation-library-summary{grid-template-columns:1fr}.formulation-workspace-bar{align-items:flex-start;flex-direction:column}.formulation-subnav{margin-left:-4px;margin-right:-4px}.revision-review-grid{grid-template-columns:repeat(2,1fr)}.recipe-diff-row{grid-template-columns:1fr}.diff-values{justify-self:start}}@media(max-width:480px){.revision-review-grid{grid-template-columns:1fr}}
.library-summary-sandbox{border-color:#ecd89e;background:#fffaf0}.library-summary-sandbox>strong{color:#8a6300}.procedure-row-invalid{background:#fff3f3!important;box-shadow:inset 3px 0 #c95555}.procedure-row-invalid .form-control,.procedure-row-invalid .form-select{border-color:#d99a9a}

/* Formulations section spacing: keep Regulatory and Labels consistent with QC/Concentrations. */
.formulation-regulatory-panel,.product-label-panel{margin-top:1.5rem;margin-bottom:1.5rem}

/* Live operational premix management */
.section-heading-actions{display:flex;align-items:center;gap:12px}.premix-operational-notice{display:flex;align-items:center;gap:10px 18px;padding:12px 16px;border-bottom:1px solid var(--line);background:#f5fbf8;flex-wrap:wrap}.premix-operational-notice strong{color:var(--liquitherm-blue-dark)}.premix-operational-notice span{font-size:.78rem;color:var(--muted);flex:1;min-width:280px}.premix-operational-notice a{font-size:.78rem;font-weight:700;text-decoration:none}.premix-live-table td{vertical-align:middle}.premix-retired-row{opacity:.62;background:#fafafa}.premix-active-chip{background:#eaf7ef;color:#23633b}.premix-retired-chip{background:#f1f2f4;color:#69737d}.premix-test-summary summary{cursor:pointer;color:var(--accent);font-size:.78rem}.premix-test-summary ul{margin:.55rem 0 0;padding-left:1rem;min-width:260px}.premix-test-summary li{margin:.3rem 0;font-size:.76rem}.premix-test-summary li span{display:block;color:var(--muted);margin-top:2px}.premix-live-editor{border-top:1px solid var(--line);background:linear-gradient(180deg,#fbfefd,#f7fbf9);padding:18px}.premix-live-editor form{background:#fff;border:1px solid var(--line);border-radius:14px;box-shadow:0 12px 35px rgba(11,47,42,.08);overflow:hidden}.premix-editor-heading{display:flex;justify-content:space-between;gap:20px;align-items:flex-start;padding:18px 20px;border-bottom:1px solid var(--line)}.premix-editor-heading h3{font-size:1.08rem;margin:.1rem 0 .2rem}.premix-editor-heading p{margin:0;color:var(--muted);font-size:.78rem}.premix-editor-fields{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;padding:18px 20px}.premix-recipe-editor{display:grid;grid-template-columns:minmax(240px,.35fr) 1fr;gap:16px;padding:0 20px 18px}.premix-qc-editor{margin:0 20px 18px;border:1px solid var(--line);border-radius:10px;overflow:hidden}.premix-qc-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:12px 14px;background:#fbfdfe;border-bottom:1px solid var(--line)}.premix-qc-heading h4{font-size:.9rem;margin:0 0 2px}.premix-qc-heading p{margin:0;font-size:.72rem;color:var(--muted)}.premix-qc-editor .test-spec-table input,.premix-qc-editor .test-spec-table select{min-width:84px}.premix-qc-editor .test-spec-table td:first-child input{min-width:180px}.premix-no-tests{padding:18px;text-align:center;color:var(--muted);font-size:.78rem;background:#fff}.premix-editor-actions{display:grid;grid-template-columns:auto auto 1fr auto;align-items:center;gap:10px;padding:12px 20px;border-top:1px solid var(--line);background:#fbfdfc}.premix-editor-actions span{font-size:.72rem;color:var(--muted);text-align:right;padding-right:8px}@media(max-width:1000px){.premix-editor-fields{grid-template-columns:repeat(2,minmax(0,1fr))}.premix-recipe-editor{grid-template-columns:1fr}.premix-editor-actions{grid-template-columns:1fr 1fr}.premix-editor-actions span{display:none}}@media(max-width:620px){.section-heading-actions{align-items:flex-end;flex-direction:column}.premix-editor-fields{grid-template-columns:1fr}.premix-editor-actions{grid-template-columns:1fr}.premix-editor-actions .btn{width:100%}}

/* Formulations completion: controlled master-data editing */
.controlled-edit-callout{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:12px 16px;border-bottom:1px solid var(--line);background:#f7fbfa}.controlled-edit-callout>div{min-width:0}.controlled-edit-callout strong,.controlled-edit-callout span{display:block}.controlled-edit-callout strong{font-size:.82rem;color:var(--liquitherm-blue-dark)}.controlled-edit-callout span{margin-top:2px;font-size:.75rem;color:var(--muted);line-height:1.45}.controlled-edit-callout .btn{white-space:nowrap}.controlled-edit-callout form{flex:0 0 auto}
.test-spec-table td:first-child input{min-width:180px}.test-spec-table td:nth-child(2) input{min-width:120px}.test-spec-table select{min-width:82px}.ri-model-readonly{display:block}.ri-model-readonly summary{display:flex;align-items:center;justify-content:space-between;gap:12px;cursor:pointer;list-style:none}.ri-model-readonly summary::-webkit-details-marker{display:none}.ri-model-readonly summary:after{content:'+';font-weight:800;color:var(--accent)}.ri-model-readonly[open] summary:after{content:'−'}.ri-model-readonly summary span{font-size:.7rem;color:var(--muted);font-weight:600}.ri-model-editor>strong{display:block;margin-bottom:4px}.ri-model-editor:before{content:'Technical calculation model';display:block;font-size:.62rem;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);margin-bottom:2px}
@media(max-width:760px){.controlled-edit-callout{align-items:stretch;flex-direction:column}.controlled-edit-callout .btn,.controlled-edit-callout form,.controlled-edit-callout form .btn{width:100%}}

/* Regional formulation revision hierarchy */
.regional-formulations-card{padding:0;overflow:hidden}.regional-formulations-heading{padding:24px 24px 18px;margin:0;border-bottom:1px solid var(--line)}.regional-formulations-heading>div{display:flex;flex-direction:column;gap:4px}.regional-revision-groups{display:flex;flex-direction:column}.regional-revision-group{padding:18px 20px;border-bottom:1px solid var(--line)}.regional-revision-group:last-child{border-bottom:0}.regional-revision-title{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px}.regional-revision-title strong{font-size:12px;letter-spacing:.2px}.regional-revision-title span{font-size:10px;color:var(--muted)}.regional-revision-card{display:grid;grid-template-columns:28px minmax(0,1fr) auto;align-items:center;gap:10px;color:var(--ink);padding:12px 12px;border:1px solid transparent;border-radius:10px;margin-top:7px;transition:background .15s,border-color .15s,box-shadow .15s}.regional-revision-card:hover{color:var(--ink);background:#f7fafc;border-color:#dbe7ec}.regional-revision-card.selected{box-shadow:inset 3px 0 var(--liquitherm-orange)}.regional-revision-card.revision-active{background:#f4faf7;border-color:#d8ebe2}.regional-revision-card.revision-active.selected{background:#edf8f3}.regional-revision-card.revision-sandbox{background:#fffaf2;border-color:#f1dfbd}.regional-revision-card.revision-sandbox.selected{background:#fff5e6}.revision-state-icon{display:grid;place-items:center;width:25px;height:25px;border-radius:50%;font-size:12px;font-weight:800}.revision-active .revision-state-icon{background:#dff2e8;color:#27705d}.revision-sandbox .revision-state-icon{background:var(--liquitherm-orange-soft);color:#9a5a00}.revision-card-copy{display:flex;flex-direction:column;min-width:0}.revision-card-copy strong{font-size:12px}.revision-card-copy small{font-size:10px;color:#4f666f;margin-top:1px}.revision-card-copy .revision-audit{font-size:9px;color:var(--muted);margin-top:4px;line-height:1.35}.previous-revisions{margin-top:10px;border-top:1px dashed #dce6e9;padding-top:8px}.previous-revisions summary{list-style:none;display:flex;align-items:center;gap:8px;cursor:pointer;padding:7px 8px;color:#60737a;font-size:10px;font-weight:700}.previous-revisions summary::-webkit-details-marker{display:none}.previous-revisions summary:before{content:'›';font-size:16px;line-height:1;transition:transform .15s}.previous-revisions[open] summary:before{transform:rotate(90deg)}.previous-revision-count{display:inline-grid;place-items:center;min-width:20px;height:20px;padding:0 6px;border-radius:999px;background:#eef2f3;color:#66777d;font-size:9px}.previous-revision-list{padding:2px 0 0 16px}.previous-revision-row{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:9px 10px;color:var(--ink);border-radius:8px}.previous-revision-row:hover{background:#f6f8f9;color:var(--ink)}.previous-revision-row.selected{background:var(--liquitherm-blue-soft);box-shadow:inset 3px 0 var(--liquitherm-orange)}.previous-revision-row>span:first-child{display:flex;flex-direction:column}.previous-revision-row strong{font-size:11px}.previous-revision-row small{font-size:9px;color:var(--muted);margin-top:1px}@media(max-width:575px){.regional-revision-card{grid-template-columns:24px minmax(0,1fr)}.regional-revision-card>.revision-mini-status{grid-column:2;justify-self:start}.regional-formulations-heading>span{display:none}}

/* Regional formulation copy workflow */
.regional-revision-action-wrap{display:flex;flex-direction:column;gap:5px}.regional-revision-action-wrap .regional-revision-card{margin-bottom:0}.copy-region-trigger{align-self:flex-end;border:0;background:transparent;color:var(--liquitherm-blue);font-size:9px;font-weight:800;letter-spacing:.02em;padding:3px 5px;cursor:pointer}.copy-region-trigger:hover{text-decoration:underline}.copy-region-trigger:focus-visible{outline:2px solid var(--liquitherm-blue);outline-offset:2px;border-radius:4px}.copy-region-modal-card{width:min(600px,100%)}.copy-region-modal-icon{background:var(--liquitherm-blue-soft);color:var(--liquitherm-blue)}.copy-region-field{display:flex;flex-direction:column;gap:7px;margin-top:20px}.copy-region-field label{display:flex;flex-direction:column;gap:2px;font-size:12px;color:var(--navy)}.copy-region-field label span,.copy-region-options-heading span{font-size:10px;font-weight:400;color:var(--muted)}.copy-region-options{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:18px}.copy-region-options-heading{grid-column:1/-1;display:flex;flex-direction:column;gap:2px;margin-bottom:2px;font-size:12px;color:var(--navy)}.copy-region-option{display:flex;align-items:flex-start;gap:9px;padding:10px;border:1px solid var(--line);border-radius:9px;background:#fff;cursor:pointer}.copy-region-option:hover{border-color:#bfd2dc;background:#f8fbfc}.copy-region-option input{margin-top:2px}.copy-region-option span{display:flex;flex-direction:column;gap:2px}.copy-region-option strong{font-size:11px;color:var(--navy)}.copy-region-option small{font-size:9px;line-height:1.35;color:var(--muted)}.copy-region-option.locked{background:#f5f8f9;cursor:default}.copy-region-option.premix-option{grid-column:1/-1;background:#fffaf2;border-color:#f1dfbd}.copy-region-modal-card .inline-form-error{margin-top:12px}.copy-region-modal-card select option:disabled{color:#8a9aa0}@media(max-width:575px){.copy-region-options{grid-template-columns:1fr}.copy-region-option.premix-option,.copy-region-options-heading{grid-column:1}.copy-region-trigger{align-self:flex-start;margin-left:36px}}

/* USA formulation dual-unit presentation */
.metric-secondary{display:block;margin-top:2px;color:var(--muted);font-size:10px;font-weight:500;line-height:1.25;white-space:nowrap}
.recipe-meta strong .metric-secondary{font-size:9px;font-weight:500}
.sandbox-recipe-table .quantity-lb,.procedure-table .procedure-quantity-lb{margin-top:4px;text-align:right}
/* USA recipes: imperial is the operational display; metric remains canonical/reference. */
.sandbox-quantity-lb-input,.procedure-quantity-lb-input{font-weight:700}
.sandbox-recipe-table .metric-secondary,.procedure-table .metric-secondary{font-weight:500}

/* Phase 3A — Works Orders */
.work-order-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:24px}.works-orders-panel .section-heading{padding:24px 25px 4px}.works-orders-panel .section-heading>div{display:flex;flex-direction:column;gap:4px}.works-orders-panel .section-heading span{font-size:11px;color:var(--muted)}.wo-filter-form{display:grid;grid-template-columns:minmax(260px,1fr) minmax(360px,auto) 190px auto;align-items:end;gap:12px;padding:14px 25px 22px;border-bottom:1px solid var(--line);background:#fbfdfc}.wo-country-filter-wrap{min-width:0}.wo-country-filter{display:flex;align-items:center;gap:6px;min-height:38px}.wo-country-option{display:inline-flex;align-items:center;gap:6px;height:38px;padding:0 11px;border:1px solid var(--line);border-radius:9px;background:#fff;color:#66756f;font-size:10px;font-weight:800;cursor:pointer;white-space:nowrap;transition:background .15s ease,border-color .15s ease,color .15s ease,box-shadow .15s ease}.wo-country-option:hover{background:#f5faf8;border-color:#cddfd8}.wo-country-option.is-active{background:#eaf5f0;border-color:#abd2c3;color:#246b56;box-shadow:0 0 0 1px rgba(36,107,86,.04)}.wo-country-option input{position:absolute;opacity:0;pointer-events:none}.wo-country-flag{font-size:16px;line-height:1}.wo-country-option:first-child .wo-country-flag{font-size:15px}@media(max-width:1050px){.wo-filter-form{grid-template-columns:1fr 1fr}.wo-country-filter{flex-wrap:wrap}.wo-filter-form>.btn{justify-self:start}}@media(max-width:700px){.wo-filter-form{grid-template-columns:1fr}.wo-country-filter{gap:5px}.wo-country-option{padding:0 9px}}.wo-table td{vertical-align:middle}.wo-table td>strong,.wo-table td>small{display:block}.wo-table td>small{font-size:10px;color:var(--muted);margin-top:3px}.wo-click-row{cursor:pointer}.wo-click-row:hover{background:#f7fbf9}.wo-progress{width:120px;height:6px;border-radius:999px;background:#e7efec;overflow:hidden;margin-bottom:5px}.wo-progress span{display:block;height:100%;background:var(--accent);border-radius:999px}.wo-status{display:inline-flex;align-items:center;border-radius:999px;padding:5px 9px;font-size:9px;font-weight:800;letter-spacing:.04em;text-transform:uppercase;background:#eef3f2;color:#5e706b;white-space:nowrap}.wo-status-planned{background:#eaf2fa;color:#426887}.wo-status-in-production{background:#fff0d8;color:#9a5d00}.wo-status-qc{background:#f1eafb;color:#6a4a94}.wo-status-released{background:#e5f5ef;color:#24705d}.wo-status-completed{background:#e5f3ea;color:#326a52}
.wo-create-layout{display:grid;grid-template-columns:1fr 1fr 1.12fr;gap:18px;align-items:start}.wo-create-card{height:auto;padding:0;overflow:hidden}.wo-step-label{display:flex;align-items:center;gap:10px;padding:16px 18px;border-bottom:1px solid var(--line);margin-bottom:18px;background:#fbfdfc;font-size:11px;font-weight:800;text-transform:uppercase;letter-spacing:.06em}.wo-step-label b{display:grid;place-items:center;width:26px;height:26px;border-radius:50%;background:#e4f3ed;color:var(--accent)}.wo-create-card>label,.wo-create-card>.form-select,.wo-create-card>.form-control,.wo-create-card>.row{margin-left:18px;margin-right:18px;width:calc(100% - 36px)}.wo-create-card{padding-bottom:20px}.wo-create-summary{background:linear-gradient(180deg,#fff,#fbfdfc)}.wo-preview-empty{padding:28px 22px 34px;text-align:center;color:var(--muted);font-size:12px}.wo-review-region{display:inline-flex;margin:0 20px 5px;padding:4px 8px;border-radius:999px;background:#edf2f8;color:#49657b;font-size:9px;font-weight:800}.wo-create-summary h3{margin:8px 20px 3px}.wo-create-summary>div#wo-preview>p{margin:0 20px 16px;color:var(--muted);font-size:11px}.wo-review-grid{display:grid;grid-template-columns:1fr 1fr;border-top:1px solid var(--line);border-bottom:1px solid var(--line)}.wo-review-grid>div{padding:13px 16px;border-right:1px solid var(--line);border-bottom:1px solid var(--line)}.wo-review-grid>div:nth-child(2n){border-right:0}.wo-review-grid>div:nth-last-child(-n+2){border-bottom:0}.wo-review-grid span,.wo-review-grid strong,.wo-review-grid small{display:block}.wo-review-grid span{font-size:9px;text-transform:uppercase;letter-spacing:.08em;color:var(--muted)}.wo-review-grid strong{font-size:13px;margin-top:4px}.wo-review-grid small{font-size:9px;color:var(--muted);margin-top:2px}.wo-scan-policy{display:flex;gap:12px;margin:16px 18px 0;padding:13px;border:1px solid #cee6db;background:#eff8f4;border-radius:10px}.wo-scan-policy>span{display:grid;place-items:center;width:30px;height:30px;border-radius:8px;background:#d9f0e6;color:var(--accent);font-size:18px;flex:0 0 auto}.wo-scan-policy strong{font-size:11px}.wo-scan-policy p{font-size:9px;line-height:1.45;color:#58736b;margin:3px 0 0}.wo-create-actions{display:grid;grid-template-columns:1fr auto;gap:14px;align-items:stretch;margin-top:18px}.wo-create-actions .btn{min-width:220px}
.wo-hero{display:flex;justify-content:space-between;align-items:flex-start;gap:24px;margin-bottom:22px}.wo-hero-title{display:flex;align-items:center;gap:12px}.wo-hero-title h1{margin:0}.wo-hero p{margin:8px 0 0;color:var(--muted)}.wo-locked{display:flex;flex-direction:column;min-width:300px;padding:14px 16px;border:1px solid #cfe3db;border-radius:10px;background:#f2f8f5}.wo-locked span{font-size:8px;letter-spacing:.12em;color:#4e776a;font-weight:800}.wo-locked strong{font-size:12px;margin-top:3px}.wo-locked small{font-size:9px;color:var(--muted);margin-top:2px}.wo-meta-grid{display:grid;grid-template-columns:repeat(5,1fr);gap:12px;margin-bottom:18px}.wo-meta-grid>div{background:#fff;border:1px solid var(--line);border-radius:10px;padding:13px 15px}.wo-meta-grid span,.wo-meta-grid strong,.wo-meta-grid small{display:block}.wo-meta-grid span{font-size:8px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted)}.wo-meta-grid strong{font-size:12px;margin-top:4px}.wo-meta-grid small{font-size:9px;color:var(--muted);margin-top:2px}.wo-phase-strip{display:grid;grid-template-columns:repeat(5,1fr);background:#fff;border:1px solid var(--line);border-radius:10px;overflow:hidden;margin-bottom:22px}.wo-phase-strip span{padding:12px;text-align:center;font-size:10px;font-weight:700;color:#83918d;border-right:1px solid var(--line)}.wo-phase-strip span:last-child{border-right:0}.wo-phase-strip span.active{background:#eaf6f1;color:var(--accent)}.wo-batches-panel .section-heading{padding:22px 24px 5px}.wo-batches-panel .section-heading>div{display:flex;flex-direction:column;gap:3px}.wo-batches-panel .section-heading span{font-size:10px;color:var(--muted)}.wo-batch-card{margin:16px 20px 20px;border:1px solid var(--line);border-radius:12px;overflow:hidden;background:#fff}.wo-batch-card header{display:flex;justify-content:space-between;align-items:center;gap:16px;padding:16px 18px;background:#fbfdfc;border-bottom:1px solid var(--line)}.wo-batch-card h3{font-size:16px;margin:2px 0 0}.wo-batch-seq{font-size:8px;letter-spacing:.1em;color:var(--accent);font-weight:800}.wo-batch-measure{text-align:right}.wo-batch-measure strong,.wo-batch-measure small{display:block}.wo-batch-measure strong{font-size:14px}.wo-batch-measure small{font-size:9px;color:var(--muted)}.wo-material-heading{display:flex;justify-content:space-between;align-items:center;gap:16px;padding:14px 18px}.wo-material-heading>div{display:flex;flex-direction:column}.wo-material-heading strong{font-size:11px}.wo-material-heading span{font-size:9px;color:var(--muted);margin-top:2px}.wo-scan-lock,.wo-scan-only{display:inline-flex!important;border-radius:999px;padding:5px 8px!important;background:#edf7f3;color:#28705d!important;font-size:8px!important;font-weight:800!important;letter-spacing:.04em;white-space:nowrap}.wo-material-table td>strong,.wo-material-table td>small{display:block}.wo-material-table td>small{font-size:9px;color:var(--muted);margin-top:2px}.wo-stock-warning strong{color:#b45c2b}.wo-stock-warning small{color:#a6613e!important}.wo-foundation-note{display:flex;gap:16px;margin-top:18px;padding:17px 20px;border:1px solid #dbe6e2;background:#f8fbfa;border-radius:11px}.wo-foundation-note>span{height:fit-content;border-radius:999px;background:#e7f2ed;color:#3f7163;font-size:9px;font-weight:800;padding:5px 8px}.wo-foundation-note strong{font-size:12px}.wo-foundation-note p{font-size:10px;color:var(--muted);line-height:1.55;margin:4px 0 0}.wo-audit-row{display:grid;grid-template-columns:minmax(0,1fr) 180px 160px;gap:18px;align-items:center;padding:12px 0;border-top:1px solid var(--line);font-size:10px}.wo-audit-event,.wo-audit-user,.wo-audit-time{display:flex;flex-direction:column;gap:2px}.wo-audit-event>strong{font-size:11px}.wo-audit-event>small{font-size:9px;line-height:1.45}.wo-audit-user>span,.wo-audit-time>span{font-size:8px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted)}.wo-audit-user>strong{font-size:10px}.wo-audit-row small{color:var(--muted)}
@media(max-width:1100px){.work-order-summary{grid-template-columns:1fr 1fr}.wo-create-layout{grid-template-columns:1fr 1fr}.wo-create-summary{grid-column:1/-1}.wo-filter-form{grid-template-columns:1fr 1fr}.wo-filter-form>div:first-child{grid-column:1/-1}.wo-meta-grid{grid-template-columns:1fr 1fr}}@media(max-width:700px){.work-order-summary,.wo-create-layout,.wo-meta-grid{grid-template-columns:1fr}.wo-create-summary{grid-column:auto}.wo-create-actions{grid-template-columns:1fr}.wo-filter-form{grid-template-columns:1fr}.wo-filter-form>div:first-child{grid-column:auto}.wo-hero{flex-direction:column}.wo-locked{min-width:0;width:100%}.wo-phase-strip{grid-template-columns:1fr}.wo-phase-strip span{border-right:0;border-bottom:1px solid var(--line)}.wo-material-heading{align-items:flex-start;flex-direction:column}.wo-audit-row{grid-template-columns:1fr}}
.wo-hero-side{display:flex;flex-direction:column;gap:9px;align-items:stretch}.wo-status-action .btn{width:100%}

/* Phase 3A: searchable formulation combobox */
.wo-search-select{position:relative;margin-left:18px;margin-right:18px;width:calc(100% - 36px)}
.wo-create-card>.wo-search-select{margin-top:0}
.wo-search-native{position:absolute!important;width:1px!important;height:1px!important;opacity:0!important;pointer-events:none!important;overflow:hidden!important}
.wo-search-results{position:absolute;z-index:50;top:calc(100% + 5px);left:0;right:0;max-height:290px;overflow-y:auto;background:#fff;border:1px solid var(--line);border-radius:9px;box-shadow:0 14px 32px rgba(22,48,65,.14);padding:5px}
.wo-search-option{display:flex;width:100%;flex-direction:column;align-items:flex-start;gap:2px;border:0;background:transparent;border-radius:6px;padding:9px 11px;text-align:left;color:var(--text);cursor:pointer}
.wo-search-option:hover,.wo-search-option.is-active{background:#edf5f8}
.wo-search-option strong{font-size:12px;color:var(--navy)}
.wo-search-option span{font-size:10px;color:var(--muted)}
.wo-search-empty{padding:13px 11px;color:var(--muted);font-size:11px;text-align:center}

/* Inventory stock lots / batches */
.stock-lots-table td{vertical-align:middle}.lot-scan-code{max-width:320px;margin-bottom:6px}.lot-scan-code code{display:inline-block;max-width:100%;padding:5px 7px;border:1px solid #dce7e3;border-radius:6px;background:#f6f9f8;color:#24413d;font-size:11px;white-space:normal;overflow-wrap:anywhere}.copy-scan-code{min-height:30px;padding:4px 8px;font-size:11px}.stock-lots-table .status-chip{white-space:nowrap}

/* Phase 3C - Works Order lifecycle + QC execution */
.wo-phase-strip span{display:flex;align-items:center;justify-content:center;gap:7px;position:relative;background:#fff}.wo-phase-strip span b{display:inline-flex;align-items:center;justify-content:center;width:18px;height:18px;border-radius:50%;font-size:9px;background:#eef3f2;color:#7a8984}.wo-phase-strip span.done{background:#f3faf7;color:#39715f}.wo-phase-strip span.done b{background:#dcefe7;color:#25715a}.wo-phase-strip span.current{background:#eaf6f1;color:var(--accent);font-weight:800}.wo-phase-strip span.current b{background:var(--accent);color:#fff}.wo-phase-strip span.pending{color:#98a39f}.wo-phase-strip span.failed{background:#fff0ed;color:#a64732}.wo-phase-strip span.failed b{background:#c85a42;color:#fff}.wo-status-awaiting-qc{background:#f5f0e5;color:#82651d}.wo-status-quarantined{background:#fde9e5;color:#a44330}.wo-status-qc{background:#e8f4ef;color:#2a6d59}.wo-batch-card header>div:first-child{display:flex;align-items:center;gap:9px;flex-wrap:wrap}.wo-batch-card header>div:first-child .wo-batch-seq{width:100%}.wo-consumed-complete{color:#28705d!important;font-weight:700}.wo-qc-panel{margin:18px;border:1px solid #cfe3db;border-radius:12px;background:#fbfdfc;overflow:hidden}.wo-qc-heading{display:flex;justify-content:space-between;align-items:center;gap:18px;padding:18px 20px;border-bottom:1px solid var(--line);background:#f6fbf8}.wo-qc-heading h3{font-size:17px;margin:2px 0 3px}.wo-qc-heading p{margin:0;font-size:10px;color:var(--muted)}.wo-qc-state{display:inline-flex;align-items:center;border-radius:999px;padding:6px 10px;font-size:8px;font-weight:800;letter-spacing:.05em;white-space:nowrap}.wo-qc-state.pending{background:#f5f0e5;color:#82651d}.wo-qc-state.passed{background:#e3f3eb;color:#246b56}.wo-qc-state.failed{background:#fde9e5;color:#a44330}.wo-qc-form{padding:0 20px 20px}.wo-qc-table{margin-bottom:0}.wo-qc-table th{font-size:9px}.wo-qc-table td{vertical-align:middle}.wo-qc-table td>strong,.wo-qc-table td>small{display:block}.wo-qc-table td>small{font-size:9px;color:var(--muted);margin-top:2px}.wo-qc-result-input{display:flex;align-items:center;gap:8px;min-width:180px}.wo-qc-result-input span{font-size:9px;color:var(--muted);white-space:nowrap}.wo-qc-eval{display:inline-flex;border-radius:999px;padding:5px 8px;background:#eef3f2;color:#75847f;font-size:8px;font-weight:800;white-space:nowrap}.wo-qc-eval.pass{background:#e3f3eb;color:#246b56}.wo-qc-eval.fail{background:#fde9e5;color:#a44330}.wo-qc-meta-grid{display:grid;grid-template-columns:1fr 1fr 2fr;gap:12px;padding:16px 0;border-top:1px solid var(--line)}.wo-qc-meta-grid label{display:flex;flex-direction:column;gap:5px}.wo-qc-meta-grid label>span{font-size:8px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);font-weight:700}.wo-qc-decision{display:flex;align-items:center;gap:10px;padding:14px 16px;border:1px solid var(--line);border-radius:10px;background:#fff}.wo-qc-decision>div{display:flex;flex-direction:column;margin-right:auto}.wo-qc-decision>div strong{font-size:11px}.wo-qc-decision>div small{font-size:9px;color:var(--muted);margin-top:2px}.wo-qc-choice{display:inline-flex;cursor:pointer}.wo-qc-choice input{position:absolute;opacity:0;pointer-events:none}.wo-qc-choice span{display:inline-flex;align-items:center;height:36px;padding:0 12px;border:1px solid var(--line);border-radius:9px;background:#fff;font-size:9px;font-weight:800}.wo-qc-choice.pass input:checked+span{background:#e5f5ef;border-color:#9dcebc;color:#246b56}.wo-qc-choice.fail input:checked+span{background:#fde9e5;border-color:#e4aaa0;color:#a44330}.wo-qc-panel .revision-notice{margin:18px 20px}.section-kicker{font-size:8px;letter-spacing:.11em;color:var(--accent);font-weight:800}
@media(max-width:900px){.wo-qc-heading{align-items:flex-start;flex-direction:column}.wo-qc-meta-grid{grid-template-columns:1fr}.wo-qc-decision{align-items:stretch;flex-direction:column}.wo-qc-decision>div{margin-right:0}.wo-qc-choice span,.wo-qc-decision .btn{width:100%;justify-content:center}}

/* Phase 3C inline QC workstation */
.wo-qc-state.attention{background:#fff3d8;color:#8a6610}.wo-qc-summary-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:0;border-bottom:1px solid var(--line);background:#fff}.wo-qc-summary-grid>div{padding:14px 16px;border-right:1px solid var(--line)}.wo-qc-summary-grid>div:last-child{border-right:0}.wo-qc-summary-grid span,.wo-qc-details-grid label>span{display:block;font-size:8px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);font-weight:700;margin-bottom:5px}.wo-qc-summary-grid strong{font-size:10px;color:var(--ink)}.wo-qc-table th{white-space:nowrap}.wo-qc-table td{font-size:10px}.wo-qc-table .wo-qc-result{min-width:130px}.wo-qc-eval.not-evaluated{background:#eef3f2;color:#75847f}.wo-qc-details-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;padding:18px 0;border-top:1px solid var(--line)}.wo-qc-details-grid label{margin:0}.wo-qc-details-grid .wo-qc-wide{grid-column:span 2}.wo-qc-check{display:flex;align-items:center;gap:9px;min-height:38px;padding-top:17px}.wo-qc-check input{width:17px;height:17px}.wo-qc-check span{margin:0!important;text-transform:none!important;letter-spacing:0!important;font-size:9px!important;color:var(--ink)!important}.wo-qc-actions{display:flex;align-items:center;gap:10px;padding:15px 16px;border:1px solid var(--line);border-radius:10px;background:#fff}.wo-qc-actions>div{display:flex;flex-direction:column;margin-right:auto}.wo-qc-actions>div strong{font-size:10px}.wo-qc-actions>div small{font-size:9px;color:var(--muted);margin-top:3px}.wo-qc-actions .btn{white-space:nowrap}
@media(max-width:1100px){.wo-qc-summary-grid,.wo-qc-details-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:700px){.wo-qc-summary-grid,.wo-qc-details-grid{grid-template-columns:1fr}.wo-qc-details-grid .wo-qc-wide{grid-column:auto}.wo-qc-actions{align-items:stretch;flex-direction:column}.wo-qc-actions>div{margin-right:0}.wo-qc-actions .btn{width:100%}}

/* Phase 3D - completed QC + explicit finished-stock release */
.wo-live-empty{padding:24px 25px;text-align:center;color:var(--muted);font-size:11px;border-top:1px solid var(--line)}
.wo-qc-read-value{display:inline-flex;min-width:90px;padding:7px 8px;border:1px solid #dce8e3;border-radius:7px;background:#f6faf8;color:var(--ink);font-size:10px}
.wo-qc-readonly-grid>div{padding:10px 12px;border:1px solid var(--line);border-radius:9px;background:#fff}.wo-qc-readonly-grid>div>span{display:block;font-size:8px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);font-weight:700;margin-bottom:5px}.wo-qc-readonly-grid>div>strong{display:block;font-size:10px;line-height:1.45}.wo-qc-complete-banner{display:grid;grid-template-columns:1.2fr 1fr 1fr;gap:0;margin-top:2px;border:1px solid #b9ddcf;border-radius:10px;overflow:hidden;background:#edf8f3}.wo-qc-complete-banner>div{display:flex;flex-direction:column;gap:3px;padding:13px 15px;border-right:1px solid #cfe7de}.wo-qc-complete-banner>div:last-child{border-right:0}.wo-qc-complete-banner span,.wo-qc-complete-banner small{font-size:8px;letter-spacing:.07em;text-transform:uppercase;color:#3d7663;font-weight:800}.wo-qc-complete-banner strong{font-size:11px;color:#245f4d}.wo-qc-complete-banner.held{background:#fff5ed;border-color:#efd0b8}.wo-qc-complete-banner.held span,.wo-qc-complete-banner.held small,.wo-qc-complete-banner.held strong{color:#945b32}
.wo-release-panel{margin:18px;border:1px solid #bfdacfff;border-radius:12px;background:#fbfdfc;overflow:hidden}.wo-release-heading{display:flex;justify-content:space-between;align-items:center;gap:18px;padding:18px 20px;border-bottom:1px solid var(--line);background:#f1f8f5}.wo-release-heading h3{font-size:17px;margin:2px 0 3px}.wo-release-heading p{margin:0;font-size:10px;color:var(--muted)}.wo-release-state{display:inline-flex;align-items:center;border-radius:999px;padding:6px 10px;font-size:8px;font-weight:800;letter-spacing:.05em;white-space:nowrap}.wo-release-state.ready{background:#e8f4ef;color:#2a6d59}.wo-release-state.released{background:#dff1e8;color:#23634f}.wo-release-panel .revision-notice{margin:18px 20px}.wo-release-summary-grid,.wo-release-success{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:0;background:#fff}.wo-release-success{grid-template-columns:repeat(5,minmax(0,1fr))}.wo-release-summary-grid>div,.wo-release-success>div{padding:15px 16px;border-right:1px solid var(--line)}.wo-release-summary-grid>div:last-child,.wo-release-success>div:last-child{border-right:0}.wo-release-summary-grid span,.wo-release-success span{display:block;font-size:8px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);font-weight:700;margin-bottom:5px}.wo-release-summary-grid strong,.wo-release-success strong{display:block;font-size:11px}.wo-release-summary-grid small,.wo-release-success small{display:block;font-size:9px;color:var(--muted);margin-top:3px}.wo-release-action{display:flex;align-items:center;gap:14px;margin:18px 20px;padding:15px 16px;border:1px solid #cfe3db;border-radius:10px;background:#fff}.wo-release-action>div{display:flex;flex-direction:column;margin-right:auto}.wo-release-action strong{font-size:10px}.wo-release-action small{font-size:9px;color:var(--muted);margin-top:3px}.wo-release-genealogy{display:flex;align-items:center;gap:10px;margin:18px 20px;padding:12px 14px;border:1px solid #d7e8e1;border-radius:9px;background:#f5faf8}.wo-release-genealogy strong{font-size:10px;color:#2d6d58}.wo-release-genealogy span{font-size:9px;color:var(--muted)}
@media(max-width:1000px){.wo-release-summary-grid,.wo-release-success{grid-template-columns:repeat(2,minmax(0,1fr))}.wo-release-summary-grid>div,.wo-release-success>div{border-bottom:1px solid var(--line)}.wo-qc-complete-banner{grid-template-columns:1fr}}
@media(max-width:700px){.wo-release-heading{align-items:flex-start;flex-direction:column}.wo-release-summary-grid,.wo-release-success{grid-template-columns:1fr}.wo-release-action{align-items:stretch;flex-direction:column}.wo-release-action>div{margin-right:0}.wo-release-action .btn{width:100%}.wo-release-genealogy{align-items:flex-start;flex-direction:column}}

/* Phase 3E - Works Order production documents */
.wo-document-actions{display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:1rem 1.15rem;margin:1rem 0;border:1px solid var(--border-color,#dfe7ea);border-radius:12px;background:#fff}.wo-document-actions>div:first-child{display:flex;flex-direction:column;gap:.15rem}.wo-document-actions strong{font-size:.92rem}.wo-document-actions span{font-size:.78rem;color:#6b7b83}.wo-document-buttons{display:flex;flex-wrap:wrap;gap:.5rem;justify-content:flex-end}.wo-batch-docs{display:flex;gap:.45rem;align-items:center;margin-left:auto;margin-right:.75rem}@media(max-width:900px){.wo-document-actions{align-items:flex-start;flex-direction:column}.wo-document-buttons{justify-content:flex-start}.wo-batch-docs{width:100%;margin:.6rem 0 0;flex-wrap:wrap}}

/* Phase 4A - CRM foundation */
.crm-summary-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:18px}.crm-directory,.crm-create-card,.crm-workspace .content-card{border:1px solid var(--line);border-radius:14px;background:#fff;overflow:hidden}.crm-card-heading{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:18px 20px;border-bottom:1px solid var(--line);background:#fbfcfc}.crm-card-heading h2{font-size:18px;margin:2px 0 3px}.crm-card-heading p{margin:0;color:var(--muted);font-size:10px}.crm-filter-grid{display:grid;grid-template-columns:2.2fr 1fr 1fr 120px;gap:12px;padding:16px 20px;border-bottom:1px solid var(--line)}.crm-filter-grid label,.crm-form-grid label{display:flex;flex-direction:column;gap:5px}.crm-filter-grid label>span,.crm-form-grid label>span{font-size:8px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);font-weight:800}.crm-table-wrap{min-height:160px}.crm-table th{font-size:8px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);background:#f8faf9;white-space:nowrap}.crm-table td{font-size:10px}.crm-account-link{display:flex;flex-direction:column;text-decoration:none;color:var(--ink)}.crm-account-link strong{font-size:11px}.crm-account-link small{font-size:8px;color:var(--muted);margin-top:2px}.crm-stage-chip,.crm-primary-chip{display:inline-flex;align-items:center;border-radius:999px;padding:5px 8px;font-size:8px;font-weight:800;letter-spacing:.04em;white-space:nowrap}.crm-stage-chip{background:#eef3f2;color:#667a73}.crm-stage-chip.stage-lead{background:#eef1f7;color:#50627e}.crm-stage-chip.stage-prospect{background:#fff1d7;color:#826119}.crm-stage-chip.stage-customer{background:#e3f3eb;color:#246b56}.crm-stage-chip.stage-dormant{background:#eef0f1;color:#6c7376}.crm-stage-chip.stage-disqualified{background:#fde9e5;color:#9a4737}.crm-mini-list{font-size:9px;color:#53645e}.crm-table-state,.crm-empty{padding:18px;text-align:center;color:var(--muted);font-size:10px}.crm-pagination{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:13px 20px;border-top:1px solid var(--line);font-size:9px;color:var(--muted)}.crm-pagination>div{display:flex;align-items:center;gap:10px}.crm-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:13px;padding:20px}.crm-span-2{grid-column:span 2}.crm-form-section{display:grid;grid-template-columns:1.2fr 2fr;gap:24px;padding:20px;border-top:1px solid var(--line)}.crm-form-section h3{font-size:15px;margin:3px 0}.crm-form-section p{font-size:9px;color:var(--muted);margin:0}.crm-choice-row{display:flex;align-items:flex-start;gap:9px;flex-wrap:wrap}.crm-choice{position:relative}.crm-choice input{position:absolute;opacity:0}.crm-choice span{display:inline-flex;padding:8px 11px;border:1px solid var(--line);border-radius:9px;font-size:9px;font-weight:800;cursor:pointer;background:#fff}.crm-choice input:checked+span{background:#e7f3ee;border-color:#9ccbbb;color:#246b56}.crm-form-actions{display:flex;justify-content:flex-end;gap:10px;padding:16px 20px;border-top:1px solid var(--line);background:#fbfcfc}.crm-account-heading{align-items:center}.crm-title-row{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.crm-heading-actions{display:flex;gap:8px}.crm-account-overview-grid{display:grid;grid-template-columns:1fr 1.4fr;gap:16px;margin-bottom:16px}.crm-profile-card{padding:20px}.crm-profile-kind{font-size:8px;letter-spacing:.1em;color:var(--accent);font-weight:800}.crm-profile-card h2{font-size:24px;margin:4px 0 18px}.crm-profile-lines{display:grid;grid-template-columns:1fr 1fr;border:1px solid var(--line);border-radius:10px;overflow:hidden}.crm-profile-lines>div{padding:11px 12px;border-right:1px solid var(--line);border-bottom:1px solid var(--line)}.crm-profile-lines>div:nth-child(2n){border-right:0}.crm-profile-lines>div:nth-last-child(-n+2){border-bottom:0}.crm-profile-lines span,.crm-chip-block>span{display:block;font-size:8px;text-transform:uppercase;letter-spacing:.08em;color:var(--muted);font-weight:800;margin-bottom:5px}.crm-profile-lines strong{font-size:9px}.crm-chip-block{margin-top:14px}.crm-chip-block>div{display:flex;gap:6px;flex-wrap:wrap}.crm-lifecycle-card{padding:20px}.crm-lifecycle-card h2{font-size:18px;margin:3px 0 16px}.crm-lifecycle-card>p{font-size:9px;color:var(--muted);margin:14px 0}.crm-lifecycle-flow{display:grid;grid-template-columns:repeat(3,1fr);position:relative;gap:8px}.crm-lifecycle-flow>div{display:flex;align-items:center;gap:8px;padding:10px;border:1px solid var(--line);border-radius:10px;background:#fafbfb;color:#899591}.crm-lifecycle-flow>div>span{display:flex;width:22px;height:22px;align-items:center;justify-content:center;border-radius:50%;background:#edf1f0;font-size:8px;font-weight:800}.crm-lifecycle-flow>div strong{font-size:9px}.crm-lifecycle-flow>div.is-past,.crm-lifecycle-flow>div.is-current{border-color:#b8dace;background:#eff8f4;color:#286a56}.crm-lifecycle-flow>div.is-current{box-shadow:inset 0 0 0 1px #89bea9}.crm-mini-metrics{display:grid;grid-template-columns:repeat(3,1fr);border:1px solid var(--line);border-radius:10px;overflow:hidden}.crm-mini-metrics>div{padding:10px;text-align:center;border-right:1px solid var(--line)}.crm-mini-metrics>div:last-child{border-right:0}.crm-mini-metrics span{display:block;font-size:7px;color:var(--muted);text-transform:uppercase;letter-spacing:.08em}.crm-mini-metrics strong{font-size:16px}.crm-edit-panel{margin-bottom:16px}.crm-tabs{display:flex;gap:4px;border-bottom:1px solid var(--line);margin-bottom:16px}.crm-tabs button{border:0;background:transparent;padding:11px 14px;font-size:9px;font-weight:800;color:var(--muted);border-bottom:2px solid transparent}.crm-tabs button.active{color:var(--accent);border-bottom-color:var(--accent)}.crm-tabs button span{display:inline-flex;margin-left:4px;padding:1px 5px;border-radius:999px;background:#eef2f1;font-size:7px}.crm-tab-content{margin-bottom:16px}.crm-two-col{display:grid;grid-template-columns:1fr 1fr;gap:16px}.crm-list>div,.crm-site-list article,.crm-address-list article{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:13px 16px;border-bottom:1px solid var(--line)}.crm-list>div:last-child,.crm-site-list article:last-child,.crm-address-list article:last-child{border-bottom:0}.crm-list strong,.crm-site-list strong,.crm-address-list strong{display:block;font-size:10px}.crm-list small,.crm-site-list span,.crm-site-list small,.crm-address-list p{display:block;font-size:8px;color:var(--muted);margin:2px 0 0}.crm-role-grid{display:flex;gap:8px;flex-wrap:wrap;padding:16px}.crm-inline-form{display:flex;gap:8px;align-items:center;padding:13px 16px;border-top:1px solid var(--line);background:#fbfcfc}.crm-inline-form .form-select{max-width:220px}.crm-inline-form .form-check{margin:0}.crm-future-card{margin-top:16px;padding:20px}.crm-future-card h2,.crm-activity-placeholder h2{font-size:18px;margin:3px 0 15px}.crm-future-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.crm-future-grid>div{padding:14px;border:1px solid var(--line);border-radius:10px;background:#fafcfc}.crm-future-grid strong{display:block;font-size:10px}.crm-future-grid span{display:block;font-size:8px;color:var(--muted);margin-top:4px;line-height:1.45}.crm-subform{border-bottom:1px solid var(--line);background:#fbfcfc}.crm-check{justify-content:flex-end;padding-top:20px;flex-direction:row!important;align-items:center;gap:7px!important}.crm-contact-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;padding:16px}.crm-contact-card{display:grid;grid-template-columns:38px 1fr auto;gap:10px;align-items:center;padding:13px;border:1px solid var(--line);border-radius:10px}.crm-contact-avatar{display:flex;width:38px;height:38px;align-items:center;justify-content:center;border-radius:50%;background:#e9f2ef;color:#2a6b57;font-size:10px;font-weight:800}.crm-contact-card strong,.crm-contact-card span,.crm-contact-card a,.crm-contact-card small{display:block}.crm-contact-card strong{font-size:10px}.crm-contact-card span,.crm-contact-card a,.crm-contact-card small{font-size:8px;color:var(--muted);margin-top:2px}.crm-contact-card a{color:var(--accent);text-decoration:none}.crm-primary-chip{background:#e3f3eb;color:#246b56}.crm-address-type{display:inline-flex!important;font-size:7px!important;letter-spacing:.08em;font-weight:800;color:var(--accent)!important;margin-bottom:4px!important}.crm-activity-placeholder{padding:22px}.crm-activity-placeholder>p{font-size:10px;color:var(--muted);max-width:900px}
@media(max-width:1100px){.crm-summary-grid{grid-template-columns:repeat(2,1fr)}.crm-filter-grid{grid-template-columns:1fr 1fr}.crm-account-overview-grid,.crm-two-col{grid-template-columns:1fr}.crm-contact-grid{grid-template-columns:repeat(2,1fr)}}
@media(max-width:700px){.crm-summary-grid,.crm-filter-grid,.crm-form-grid,.crm-contact-grid,.crm-future-grid{grid-template-columns:1fr}.crm-span-2{grid-column:auto}.crm-form-section{grid-template-columns:1fr}.crm-account-heading{align-items:flex-start}.crm-heading-actions{width:100%;flex-wrap:wrap}.crm-profile-lines{grid-template-columns:1fr}.crm-profile-lines>div{border-right:0}.crm-profile-lines>div:nth-last-child(-n+2){border-bottom:1px solid var(--line)}.crm-profile-lines>div:last-child{border-bottom:0}.crm-lifecycle-flow{grid-template-columns:1fr}.crm-tabs{overflow-x:auto}.crm-pagination{align-items:flex-start;flex-direction:column}.crm-contact-grid{padding:10px}}

/* Phase 4A.1 contact experience */
.crm-contact-toolbar{display:flex;gap:12px;padding:16px 20px}.crm-contact-toolbar input{flex:1}.crm-contact-toolbar select{max-width:190px}.crm-contact-card{grid-template-columns:58px minmax(0,1fr);align-items:start;padding:20px;gap:16px;box-shadow:0 3px 14px rgba(20,50,40,.05)}.crm-contact-avatar{width:56px;height:56px;font-size:18px}.crm-contact-info{min-width:0}.crm-contact-card .crm-contact-name{font-size:17px;font-weight:750;color:var(--ink);overflow-wrap:anywhere}.crm-contact-card .crm-contact-position{font-size:12px;color:var(--muted);margin:5px 0 12px}.crm-contact-card .crm-contact-info>a:not(.crm-contact-name){font-size:12px;margin-top:7px;overflow-wrap:anywhere}.crm-contact-badges,.crm-contact-actions{display:flex;flex-wrap:wrap;gap:7px;margin:10px 0}.crm-contact-badges span{font-size:10px}.crm-modal-backdrop{position:fixed;inset:0;z-index:1050;background:rgba(17,34,29,.58);display:flex;align-items:center;justify-content:center;padding:20px}.crm-contact-modal{width:min(760px,100%);max-height:90vh;overflow:auto;background:white;border-radius:16px;box-shadow:0 25px 70px #0003}.crm-contact-modal .crm-form-grid label>span{font-size:11px}.crm-contact-modal textarea{min-height:75px}.crm-contact-grid{grid-template-columns:repeat(2,minmax(0,1fr))}@media(max-width:700px){.crm-contact-grid{grid-template-columns:1fr}.crm-contact-toolbar{flex-direction:column}.crm-contact-toolbar select{max-width:none}}

/* Phase 4A.1 Contact workspace refinement */
.crm-contact-workspace .crm-contact-hero{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-bottom:20px}
.crm-contact-workspace .crm-profile-card{margin-bottom:16px;overflow:visible}
.crm-contact-workspace .section-kicker{margin-bottom:8px}
.crm-contact-workspace .crm-profile-card h2{font-size:21px}
.crm-contact-workspace .crm-detail-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));border:1px solid var(--line);border-radius:10px;overflow:hidden;margin-top:16px}
.crm-contact-workspace .crm-detail-grid>div{padding:15px;border-bottom:1px solid var(--line);min-width:0}
.crm-contact-workspace .crm-detail-grid>div:nth-child(odd){border-right:1px solid var(--line)}
.crm-contact-workspace .crm-detail-grid span{display:block;font-size:11px;font-weight:700;color:var(--muted);margin-bottom:7px}
.crm-contact-workspace .crm-detail-grid strong,.crm-contact-workspace .crm-detail-grid a{display:block;font-size:14px;line-height:1.5;overflow-wrap:anywhere}
.crm-contact-workspace .crm-contact-badges{display:flex;gap:8px;flex-wrap:wrap}
.crm-contact-workspace .crm-contact-notes{font-size:14px;white-space:pre-wrap;line-height:1.7}
.crm-contact-modal-wide{max-width:850px;width:min(850px,94vw);max-height:90vh;overflow-y:auto}
.crm-contact-edit-form label>span{font-size:11px}
@media(max-width:900px){.crm-contact-workspace .crm-contact-hero{grid-template-columns:1fr}}
@media(max-width:560px){.crm-contact-workspace .crm-detail-grid{grid-template-columns:1fr}.crm-contact-workspace .crm-detail-grid>div:nth-child(odd){border-right:0}.crm-contact-edit-form{grid-template-columns:1fr}.crm-contact-edit-form .crm-span-2{grid-column:span 1}}

/* Phase 4A.1: compact Account workspace contact cards */
.crm-contact-grid.crm-contact-grid--compact{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;padding:16px 20px}
.crm-contact-card.crm-contact-card--compact{display:flex;flex-direction:column;gap:11px;min-width:0;padding:16px 18px;box-shadow:0 2px 9px rgba(20,50,40,.035)}
.crm-contact-card--compact .crm-contact-card-head{display:flex;align-items:center;gap:12px;min-width:0}
.crm-contact-card--compact .crm-contact-avatar{width:44px;height:44px;flex:0 0 44px;font-size:15px}
.crm-contact-card--compact .crm-contact-info{flex:1;min-width:0}
.crm-contact-card--compact .crm-contact-name{font-size:15px;line-height:1.3}
.crm-contact-card--compact .crm-contact-position{font-size:11px;margin:3px 0 0;line-height:1.35}
.crm-contact-card--compact .crm-contact-open{flex:0 0 auto;font-size:11px;padding:7px 10px;white-space:nowrap;color:#fff}
.crm-contact-card--compact .crm-contact-badges{margin:0;gap:6px}
.crm-contact-card--compact .crm-contact-badges span{font-size:9px;margin:0}
.crm-contact-methods{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px 18px;padding-top:11px;border-top:1px solid var(--line)}
.crm-contact-methods>div{min-width:0}
.crm-contact-card--compact .crm-contact-method-label{display:block;font-size:9px;letter-spacing:.05em;text-transform:uppercase;font-weight:750;color:var(--muted);margin:0 0 3px}
.crm-contact-card--compact .crm-contact-methods a{display:block;font-size:12px;line-height:1.4;overflow-wrap:anywhere;margin:0}
.crm-contact-no-details{font-size:11px;color:var(--muted)}
@media(max-width:1000px){.crm-contact-grid.crm-contact-grid--compact{grid-template-columns:1fr}}
@media(max-width:480px){.crm-contact-card--compact .crm-contact-card-head{flex-wrap:wrap}.crm-contact-card--compact .crm-contact-open{margin-left:56px}.crm-contact-methods{grid-template-columns:1fr}}

/* Phase 4A.1 card layout correction: stretch flex children across the card.
   The original .crm-contact-card align-items:start caused the header and
   methods grid to shrink to their intrinsic content width. */
.crm-contact-card.crm-contact-card--compact{align-items:stretch;width:100%;box-sizing:border-box}
.crm-contact-card--compact .crm-contact-card-head,.crm-contact-card--compact .crm-contact-badges,.crm-contact-card--compact .crm-contact-methods{width:100%;box-sizing:border-box}
.crm-contact-card--compact .crm-contact-card-head{display:grid;grid-template-columns:44px minmax(0,1fr) auto;align-items:center;column-gap:12px}
.crm-contact-card--compact .crm-contact-open{justify-self:end;margin:0}
.crm-contact-card--compact .crm-contact-methods{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px 18px}
@media(max-width:1250px){.crm-contact-card--compact .crm-contact-methods{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:600px){.crm-contact-card--compact .crm-contact-card-head{grid-template-columns:44px minmax(0,1fr)}.crm-contact-card--compact .crm-contact-open{grid-column:2;justify-self:start}.crm-contact-card--compact .crm-contact-methods{grid-template-columns:1fr}}

/* Phase 4A: consistent Account workspace location cards */
.crm-workspace .crm-two-col>.content-card{min-width:0}
.crm-location-list{display:grid;grid-template-columns:1fr;gap:12px;padding:16px 20px}
.crm-location-card{min-width:0;border:1px solid var(--line);border-radius:11px;padding:16px 18px;background:#fff;box-shadow:0 2px 9px rgba(20,50,40,.035)}
.crm-location-card-top{display:flex;align-items:center;gap:12px;min-width:0}
.crm-location-icon{width:44px;height:44px;flex:0 0 44px;display:flex;align-items:center;justify-content:center;border-radius:50%;background:#e9f2ef;color:#2a6b57;font-size:23px;font-weight:700}
.crm-location-title{min-width:0;flex:1}
.crm-location-title strong{display:block;font-size:15px;line-height:1.35;color:var(--ink);overflow-wrap:anywhere}
.crm-location-title>span{display:block;font-size:11px;color:var(--muted);margin-top:3px;overflow-wrap:anywhere}
.crm-location-badges{display:flex;gap:6px;flex-wrap:wrap;margin:11px 0}
.crm-location-badges .crm-stage-chip,.crm-location-badges .crm-primary-chip{font-size:9px}
.crm-location-detail{border-top:1px solid var(--line);padding-top:11px;margin-top:11px;display:flex;flex-direction:column;gap:4px;min-width:0}
.crm-location-detail-label{font-size:9px;letter-spacing:.05em;font-weight:750;color:var(--muted)}
.crm-location-detail>span:last-child{font-size:12px;line-height:1.5;overflow-wrap:anywhere;color:var(--ink)}
.crm-location-list .crm-empty{padding:25px 12px}
@media(max-width:1100px){.crm-location-list{padding:14px}}

/* Phase 4A: compact two-across address and site cards, with edit actions */
.crm-workspace .crm-location-list{grid-template-columns:repeat(2,minmax(0,1fr));align-items:start;gap:10px;padding:12px}
.crm-workspace .crm-location-card{position:relative;padding:12px;align-self:start}
.crm-workspace .crm-location-card-top{padding-right:48px;align-items:flex-start;gap:8px}
.crm-workspace .crm-location-icon{width:32px;height:32px;flex-basis:32px;font-size:18px}
.crm-workspace .crm-location-badges{margin:8px 0}
.crm-workspace .crm-location-detail{margin-top:8px;padding-top:8px}
.crm-location-edit{position:absolute;top:10px;right:10px;font-size:11px;padding:3px 8px}
.crm-location-form-actions{display:flex;justify-content:flex-end;gap:8px;align-items:center}
@media(max-width:1050px){.crm-workspace .crm-location-list{grid-template-columns:1fr}}
@media(min-width:1501px) and (max-width:1750px){.crm-workspace .crm-location-card{padding:10px}}
/* Phase 4A.3 — Customer Site workspace */
.crm-site-workspace .crm-site-overview{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin-bottom:16px;align-items:start}
.crm-site-workspace .crm-site-panel{min-width:0}
.crm-site-workspace .crm-site-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0;padding:12px 20px}
.crm-site-workspace .crm-site-fields>div{padding:12px 8px;border-bottom:1px solid var(--line);min-width:0}
.crm-site-workspace .crm-site-fields span{display:block;font-size:11px;color:var(--muted);font-weight:700;margin-bottom:5px}
.crm-site-workspace .crm-site-fields strong,.crm-site-workspace .crm-site-fields a{font-size:14px;overflow-wrap:anywhere}
.crm-site-workspace .crm-site-address{padding:20px;font-size:14px;line-height:1.65;overflow-wrap:anywhere}
.crm-site-workspace .crm-site-address p{margin:7px 0;color:var(--ink)}
.crm-site-workspace .crm-site-address small{font-size:12px;color:var(--muted)}
.crm-site-workspace .crm-site-person{font-size:16px;font-weight:700}
.crm-site-workspace .crm-site-notes{white-space:pre-wrap}
.crm-site-workspace .crm-site-actions{display:flex;justify-content:flex-end;gap:10px}
.crm-location-title .crm-site-link{font-size:inherit;font-weight:800;color:var(--ink);text-decoration:none}
.crm-location-title .crm-site-link:hover{text-decoration:underline;color:var(--accent)}
@media(max-width:900px){.crm-site-workspace .crm-site-overview{grid-template-columns:1fr}}
@media(max-width:550px){.crm-site-workspace .crm-site-fields{grid-template-columns:1fr}}

/* Phase 4A.3: site workspace contact and modal polish */
.crm-site-edit-modal{width:min(860px,calc(100vw - 32px));max-height:90vh;overflow-y:auto}
.crm-site-contact-list{display:grid;gap:8px;margin:14px 0}
.crm-site-contact-row{display:flex;align-items:center;gap:12px;justify-content:space-between;padding:10px 12px;border:1px solid var(--border-color,#e3e8ef);border-radius:10px}
.crm-site-contact-row>div{flex:1;min-width:0;display:grid;gap:2px}.crm-site-contact-row small{color:#64748b}
.crm-site-contact-form{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;align-items:end;margin-top:16px}
.crm-site-contact-form label{display:grid;gap:5px}.crm-site-contact-form .crm-check{display:flex;align-items:center;gap:8px}
@media(max-width:700px){.crm-site-contact-form{grid-template-columns:1fr}.crm-site-contact-row{flex-wrap:wrap}}

/* Phase 4A.4 shared CRM timeline */
.crm-timeline{padding:20px;margin:18px 0}.crm-timeline-tabs{display:flex;gap:8px;border-bottom:1px solid #dce6ed;margin:14px 0}.crm-timeline-tabs button{border:0;background:transparent;padding:10px 16px;color:#31546a;cursor:pointer}.crm-timeline-tabs button.active{border-bottom:3px solid #215e80;font-weight:700}.crm-timeline-form{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:18px 0;padding:16px;border:1px solid #e1e8ee;border-radius:12px;background:#f8fbfd}.crm-timeline-form label{display:grid;gap:6px;min-width:0}.crm-timeline-form label span{font-size:12px;color:#476278}.crm-timeline-wide{grid-column:1/-1}.crm-timeline-subject{grid-column:span 2}.crm-timeline-items{padding:8px 4px}.crm-timeline-item{display:flex;gap:14px;border-left:2px solid #d6e5ee;padding:4px 0 20px 16px;position:relative}.crm-timeline-dot{position:absolute;left:-6px;top:8px;background:#276585;width:10px;height:10px;border-radius:50%}.crm-timeline-item h3{font-size:15px;margin:7px 0}.crm-timeline-item p,.crm-task-item p{white-space:pre-wrap;margin:5px 0}.crm-timeline-meta{display:flex;gap:12px;flex-wrap:wrap;color:#60798a;font-size:12px}.crm-task-item{display:flex;justify-content:space-between;gap:16px;align-items:center;padding:14px 0;border-bottom:1px solid #e3ebf0}.crm-task-item select{max-width:165px}.crm-task-item small{display:block;color:#627c8d;margin-top:5px}.crm-timeline-empty{padding:18px;color:#667d8c}.crm-timeline-pagination{display:flex;justify-content:center;align-items:center;gap:15px;margin:15px}.crm-site-contact-form{padding:14px;gap:12px;align-items:center}.crm-site-contact-form .crm-check{align-self:center;margin:0}.crm-site-contact-form button{min-height:38px}.crm-site-contact-list{padding:12px}.crm-site-contact-row{padding:12px;gap:10px}.crm-site-workspace .crm-site-panel{min-width:0;overflow:hidden}@media(max-width:750px){.crm-timeline-form{grid-template-columns:1fr}.crm-timeline-subject,.crm-timeline-wide{grid-column:1}.crm-task-item{flex-direction:column;align-items:stretch}.crm-task-item select{max-width:none}}

/* Phase 4A.4: side-by-side composer and timeline, consistent on all CRM records */
.crm-timeline-columns{display:grid;grid-template-columns:minmax(0,2fr) minmax(0,3fr);gap:20px;align-items:start;margin-top:16px}
.crm-timeline-compose,.crm-timeline-history{min-width:0}
.crm-timeline-compose{border:1px solid #e1e8ee;border-radius:12px;background:#f8fbfd;padding:18px}
.crm-timeline-history{border:1px solid #e1e8ee;border-radius:12px;background:#fff;padding:18px;min-height:320px}
.crm-timeline-column-title{font-size:15px;font-weight:750;color:#173e56;margin:0 0 14px}
.crm-timeline-compose .crm-timeline-form{grid-template-columns:repeat(2,minmax(0,1fr));padding:0;margin:0;background:transparent;border:0}
.crm-timeline-compose .crm-timeline-subject,.crm-timeline-compose .crm-timeline-wide{grid-column:1/-1}
.crm-timeline-history .crm-timeline-items{padding:4px 0;max-height:650px;overflow-y:auto;overflow-x:hidden}
.crm-timeline-history .crm-timeline-item{overflow-wrap:anywhere}
@media(max-width:1100px){.crm-timeline-columns{grid-template-columns:1fr}.crm-timeline-history .crm-timeline-items{max-height:none}}
@media(max-width:560px){.crm-timeline-compose .crm-timeline-form{grid-template-columns:1fr}.crm-timeline-compose .crm-timeline-subject,.crm-timeline-compose .crm-timeline-wide{grid-column:1}.crm-timeline-compose,.crm-timeline-history{padding:14px}}

.crm-related-selector{display:grid;gap:8px}.crm-related-selector label{display:grid;gap:5px}.crm-related-results{border:1px solid #d6e5ee;border-radius:8px;max-height:175px;overflow:auto}.crm-related-results button{display:block;width:100%;border:0;background:#fff;padding:9px 12px;text-align:left;color:#174864}.crm-related-results button:hover{background:#edf6fa}.crm-related-chips{display:flex;gap:6px;flex-wrap:wrap}.crm-related-chips>span{background:#e7f1f6;border-radius:20px;padding:5px 10px;font-size:12px}.crm-related-chips button{border:0;background:none;cursor:pointer}.crm-related-selector small{color:#5d7484}

/* Phase 4A.5: make shared CRM relationships visible on timeline entries */
.crm-activity-related{display:flex;flex-wrap:wrap;align-items:center;gap:6px;margin-top:8px}.crm-activity-related small{color:#64748b}.crm-related-link{display:inline-block;border:1px solid #d5e4ec;border-radius:16px;padding:3px 9px;background:#f0f7fa;color:#205775;font-size:12px;text-decoration:none}.crm-related-link:hover{background:#e2f0f6;text-decoration:underline}

/* Phase 4A.5 task composer polish */
.crm-compose-switch{display:grid;grid-template-columns:1fr 1fr;gap:6px;margin-bottom:16px;background:#eaf1f6;border-radius:9px;padding:5px}
.crm-compose-switch button{border:0;border-radius:7px;padding:10px;background:transparent;color:#31546a;cursor:pointer;font-weight:600}
.crm-compose-switch button.active{background:#fff;color:#154967;box-shadow:0 1px 4px #16394b24}
.crm-task-overdue{display:inline-block;margin-top:6px;color:#a32228;background:#fff0f1;border-radius:6px;padding:3px 8px;font-size:12px;font-weight:700}

/* Phase 4A.5: balanced CRM activity/task workspace cards */
@media(min-width:1101px){.crm-timeline-columns{align-items:stretch}.crm-timeline-compose,.crm-timeline-history{min-height:680px}.crm-timeline-history{display:flex;flex-direction:column}.crm-timeline-history .crm-timeline-items{flex:1;min-height:0;max-height:630px;overflow-y:auto}}

/* Phase 4A.5: matched composer/history heights without clipping long forms. */
@media(min-width:1101px){
 .crm-timeline-columns{align-items:stretch;grid-template-columns:minmax(0,2fr) minmax(0,3fr)}
 .crm-timeline-compose,.crm-timeline-history{min-height:0;height:100%;box-sizing:border-box}
 .crm-timeline-history{min-width:0;display:flex;flex-direction:column;overflow:hidden}
 .crm-timeline-history>.crm-timeline-items{flex:1 1 auto;min-height:0;max-height:600px;overflow-y:auto;overscroll-behavior:contain}
}

/* Phase 4A.5 consolidated task editor */
.crm-task-edit-panel{padding:16px;margin-top:12px;border:1px solid #d7e3ed;border-radius:12px;background:#f8fafc}
.crm-task-edit-panel form{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.crm-task-edit-panel label{display:flex;flex-direction:column;gap:5px;font-weight:600;font-size:.9rem}
.crm-task-edit-panel label:nth-child(2),.crm-task-edit-actions{grid-column:1/-1}
@media(max-width:600px){.crm-task-edit-panel form{grid-template-columns:1fr}}

/* Phase 4B CRM navigation: accessible expandable parent and nested links. */
.sidebar nav{min-height:0;overflow-y:auto;overflow-x:hidden;scrollbar-width:thin}
.crm-nav-parent{width:100%;border:0;background:transparent;text-align:left;font:inherit;cursor:pointer;align-items:center}
.crm-nav-parent-label{flex:1}.crm-nav-chevron{margin-left:auto;font-size:19px!important}
.crm-submenu{margin:0 0 8px 20px;padding:3px 0 3px 12px;border-left:1px solid rgba(185,217,235,.25)}
.crm-subitem{display:flex;justify-content:space-between;align-items:center;gap:8px;color:#c8dce7;padding:10px 12px;margin:2px 0;border-radius:7px;font-size:13px;line-height:1.25}
.crm-subitem:hover,.crm-subitem.selected{background:#245b7b;color:#fff}
.crm-subitem.selected{box-shadow:inset 3px 0 var(--liquitherm-orange);font-weight:650}
.crm-subitem-pending{color:#93aaba;cursor:default;opacity:.75}
.crm-subitem-pending small{font-size:9px;white-space:nowrap;color:#b0c2cf}
.crm-nav-parent:focus-visible,.crm-subitem:focus-visible{outline:2px solid #fff;outline-offset:-2px}

/* Phase 4B CRM Contacts: align directory presentation with Accounts. */
.crm-contacts-directory{grid-column:1/-1;min-width:0}
.crm-contacts-filters{grid-template-columns:minmax(220px,2.2fr) repeat(3,minmax(120px,1fr)) 100px}
.crm-contacts-directory .crm-table td{vertical-align:middle}
@media(max-width:1100px){.crm-contacts-filters{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:700px){.crm-contacts-filters{grid-template-columns:1fr}}

.crm-sites-filters{grid-template-columns:minmax(220px,2fr) minmax(140px,1fr) minmax(110px,120px)}
@media(max-width:700px){.crm-sites-filters{grid-template-columns:1fr}}

/* Phase 4B: Opportunity workspace */
.crm-opportunity-workspace{max-width:1560px;margin:0 auto}.crm-opportunity-heading{align-items:center}.crm-opportunity-heading-actions{display:flex;gap:12px;align-items:center;flex-wrap:wrap}.crm-opportunity-workspace .crm-stage-chip{font-size:11px;padding:9px 13px}.crm-opportunity-pipeline{padding:22px 24px;margin-bottom:16px}.crm-opportunity-section-head{display:flex;justify-content:space-between;align-items:center;gap:14px;margin-bottom:17px}.crm-opportunity-section-head h2{font-size:19px;margin:3px 0 0}.crm-opportunity-muted{font-size:12px;color:var(--muted);line-height:1.6}.crm-opportunity-steps{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:7px;margin:15px 0}.crm-opportunity-step{display:flex;align-items:center;gap:10px;padding:13px 10px;border-radius:9px;border:1px solid var(--line);background:#f7f9f8;color:#7a8984;min-width:0}.crm-opportunity-step strong{font-size:12px;white-space:normal}.crm-opportunity-step-icon{display:flex;align-items:center;justify-content:center;width:25px;height:25px;min-width:25px;border-radius:50%;background:#e5ebe9;font-size:11px;font-weight:800}.crm-opportunity-step.complete{background:#eaf6f0;border-color:#b8decb;color:#246c4d}.crm-opportunity-step.complete .crm-opportunity-step-icon{background:#2c9068;color:#fff}.crm-opportunity-step.current{background:#fff4e8;border-color:#f1bd82;color:#945218;box-shadow:inset 0 0 0 1px #f1bd82}.crm-opportunity-step.current .crm-opportunity-step-icon{background:#d97927;color:#fff}.crm-opportunity-lost{color:#a34940;font-size:12px;font-weight:700}.crm-opportunity-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:18px}.crm-opportunity-metric{padding:19px 21px;display:flex;flex-direction:column;gap:7px}.crm-opportunity-metric>span{font-size:11px;font-weight:750;color:var(--muted);text-transform:uppercase;letter-spacing:.04em}.crm-opportunity-metric>strong{font-size:24px;line-height:1.2;overflow-wrap:anywhere}.crm-opportunity-metric>small{font-size:11px;color:var(--muted)}.crm-opportunity-tabs{display:flex;gap:8px;border-bottom:1px solid var(--line);margin-bottom:18px;overflow-x:auto}.crm-opportunity-tabs button{padding:13px 16px;border:0;border-bottom:3px solid transparent;background:transparent;font-size:13px;font-weight:750;color:var(--muted);white-space:nowrap}.crm-opportunity-tabs button.active{border-bottom-color:var(--accent);color:var(--ink)}.crm-opportunity-tabs button span{font-size:10px;border-radius:20px;background:#e9f0ed;padding:3px 7px}.crm-opportunity-overview{display:grid;grid-template-columns:minmax(0,1.5fr) minmax(310px,1fr);gap:16px;align-items:start}.crm-opportunity-side{display:grid;gap:16px}.crm-opportunity-panel{padding:23px 25px}.crm-opportunity-facts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin:0}.crm-opportunity-facts>div{padding:13px 15px;background:#f8faf9;border:1px solid var(--line);border-radius:10px;min-width:0}.crm-opportunity-facts dt{font-size:10px;text-transform:uppercase;letter-spacing:.07em;color:var(--muted);font-weight:800;margin-bottom:6px}.crm-opportunity-facts dd{font-size:13px;font-weight:650;margin:0;overflow-wrap:anywhere}.crm-opportunity-description{margin-top:22px}.crm-opportunity-description h3{font-size:14px}.crm-opportunity-description p{font-size:13px;line-height:1.7;white-space:pre-line}.crm-opportunity-linked{display:grid;gap:8px}.crm-opportunity-linked a{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:11px 13px;background:#f8faf9;border:1px solid var(--line);border-radius:9px;text-decoration:none;font-size:12px}.crm-opportunity-linked a strong{font-size:12px}.crm-opportunity-linked a small{font-size:11px;color:var(--muted)}.crm-opportunity-empty{font-size:12px;color:var(--muted)}.crm-opportunity-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.crm-opportunity-form-grid label,.crm-opportunity-link-form label{display:flex;flex-direction:column;gap:7px;font-size:12px;font-weight:700}.crm-opportunity-wide{grid-column:span 2}.crm-opportunity-edit{max-width:1000px}.crm-opportunity-form-actions{display:flex;align-items:center;justify-content:flex-end;gap:16px;padding-top:20px}.crm-opportunity-form-actions #opportunity-message{font-size:12px}.crm-opportunity-relations{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;align-items:start}.crm-opportunity-link-form{display:grid;gap:13px;margin-top:19px;padding-top:17px;border-top:1px solid var(--line)}.crm-opportunity-link-form .crm-opportunity-primary{flex-direction:row;align-items:center}.crm-opportunity-link-form button{justify-self:start}.opportunity-link-message{font-size:12px}@media(max-width:1050px){.crm-opportunity-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-opportunity-overview,.crm-opportunity-relations{grid-template-columns:1fr}}@media(max-width:700px){.crm-opportunity-steps{grid-template-columns:1fr 1fr}.crm-opportunity-step{padding:10px}.crm-opportunity-metrics{grid-template-columns:1fr 1fr;gap:9px}.crm-opportunity-metric{padding:14px}.crm-opportunity-metric>strong{font-size:19px}.crm-opportunity-panel,.crm-opportunity-pipeline{padding:16px}.crm-opportunity-facts,.crm-opportunity-form-grid{grid-template-columns:1fr}.crm-opportunity-wide{grid-column:auto}}

/* Phase 4B.3 Salesforce-compatible Opportunity progression */
.crm-stage-trail{display:flex;gap:6px;overflow-x:auto;overscroll-behavior-inline:contain;padding:8px 2px 14px;scrollbar-width:thin;scroll-snap-type:x proximity}
.crm-stage-trail .crm-opportunity-step{flex:0 0 174px;min-height:65px;text-align:left;cursor:pointer;scroll-snap-align:start;transition:background .15s,border-color .15s,box-shadow .15s}
.crm-stage-trail .crm-opportunity-step:hover{border-color:#7394a8;background:#eef5f8}
.crm-stage-trail .crm-opportunity-step.selected{outline:2px solid #246d9a;outline-offset:2px;background:#eaf3fa}
.crm-stage-trail .crm-opportunity-step.current{background:#e8f3fc;border-color:#8dbbdd;color:#1c587e;box-shadow:inset 0 0 0 1px #8dbbdd}
.crm-stage-trail .crm-opportunity-step.current .crm-opportunity-step-icon{background:#2477aa}
.crm-stage-trail-label{font-size:11px;line-height:1.4;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden;font-weight:700}
.crm-stage-actionbar{display:flex;justify-content:space-between;align-items:center;gap:20px;padding:13px 0;border-top:1px solid var(--line)}
.crm-stage-actionbar>div{min-width:0}.crm-stage-actionbar strong{font-size:13px}.crm-stage-actionbar p{margin:4px 0 0}
.crm-stage-history{border-top:1px solid var(--line);padding-top:12px;margin-top:10px;font-size:12px}.crm-stage-history summary{cursor:pointer;font-weight:700}.crm-stage-history li{padding:5px 0;overflow-wrap:anywhere}
@media(max-width:700px){.crm-stage-actionbar{align-items:stretch;flex-direction:column}.crm-stage-trail .crm-opportunity-step{flex-basis:150px}}

/* Phase 4B.4: completed stages stay green; current stage stays blue. */
.crm-stage-trail .crm-opportunity-step.complete{background:#e5f5eb;border-color:#86cda7;color:#176341}
.crm-stage-trail .crm-opportunity-step.complete .crm-opportunity-step-icon{background:#22865a;color:#fff}
.crm-stage-trail .crm-opportunity-step.current{background:#e8f3fc;border-color:#8dbbdd;color:#1c587e}
.crm-stage-trail .crm-opportunity-step:disabled{cursor:wait;opacity:.8}
.crm-stage-instruction{margin:10px 0 5px}
.crm-new-stage-label{display:block;font-size:12px;font-weight:700;margin-bottom:7px}
.crm-new-stage-value{padding:10px 12px;border:1px solid #cfe2d6;background:#edf8f0;border-radius:7px;font-size:12px;font-weight:700;color:#246c4d}

/* Phase 4B.5: stage progression feedback and linked-record clarity */
#opportunity-stage-feedback[hidden]{display:none!important}
.crm-opportunity-pipeline .crm-stage-history{margin-top:10px}
.opportunity-link-message.text-success{color:#167448}
.opportunity-link-message.text-danger{color:#b42318}

/* Phase 4B.6: compact, horizontally scrollable pipeline */
.crm-opportunity-pipeline{padding:10px 16px!important;margin-bottom:12px!important}
.crm-stage-trail .crm-opportunity-step{min-height:38px!important;flex-basis:128px!important;padding:5px 8px!important;gap:5px!important;font-size:10px!important}
.crm-stage-trail .crm-opportunity-step-icon{width:19px!important;height:19px!important;min-width:19px!important;font-size:10px!important}
.crm-stage-trail .crm-stage-trail-label{font-size:10px!important;line-height:1.15!important}
.crm-opportunity-pipeline h2{font-size:14px!important;margin-bottom:6px!important}
/* Phase 4C.1: consistent, accessible commercial management dialogs */
.commercial-modal-backdrop{position:fixed;inset:0;background:rgba(12,31,41,.5);z-index:1500;display:flex;align-items:center;justify-content:center;padding:20px}
.commercial-modal{width:min(740px,100%);max-height:90vh;overflow:auto;padding:25px;background:#fff;box-shadow:0 24px 70px rgba(0,0,0,.22)}
.commercial-form{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;padding-top:16px}
.commercial-form label{display:flex;flex-direction:column;gap:7px;font-size:13px;font-weight:650}
.commercial-form label:has(input[type=checkbox]){flex-direction:row;align-items:center}
.commercial-wide{grid-column:1/-1}
@media(max-width:650px){.commercial-form{grid-template-columns:1fr}.commercial-modal{padding:16px}}

/* Phase 4C.2 quotation workspace */
.crm-quote-opportunity-panel{margin-top:20px;padding:24px}.crm-quote-list{margin:16px 0}.crm-quote-list-row{display:flex;gap:18px;align-items:center;justify-content:space-between;border-top:1px solid #e5edf2;padding:13px 5px;text-decoration:none}.crm-quote-pill{display:inline-flex;border-radius:999px;background:#e7f3f8;color:#135376;font-size:12px;padding:5px 11px;white-space:nowrap}.crm-quote-create-grid{display:flex;gap:14px;align-items:end;flex-wrap:wrap}.crm-quote-create-grid label{flex:1;min-width:190px;font-weight:600}.crm-quote-metrics{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin-bottom:18px}.crm-quote-metrics>section{padding:20px}.crm-quote-metrics h2{font-size:21px;margin:7px 0}.crm-quote-metrics small{color:#607788}.crm-quote-layout{display:grid;grid-template-columns:minmax(0,2fr) minmax(270px,1fr);gap:18px}.crm-quote-section{padding:22px;margin-bottom:16px}.crm-quote-section h2{font-size:20px}.crm-quote-section h3{font-size:17px}.crm-quote-table td,.crm-quote-table th{font-size:13px;padding:13px 10px;vertical-align:middle}.crm-quote-add{border-top:1px solid #e5edf2;padding-top:20px;margin-top:14px}.crm-quote-add>label{display:block;max-width:700px}.crm-quote-line-form{display:flex;align-items:end;gap:12px;flex-wrap:wrap;margin-top:12px}.crm-quote-line-form label{max-width:140px}.crm-quote-selected{font-size:13px;color:#24556e;min-width:170px;max-width:300px}.crm-quote-results{max-width:700px;max-height:260px;overflow:auto}.crm-quote-result{display:flex;width:100%;justify-content:space-between;gap:12px;text-align:left;background:#fff;border:1px solid #e5edf2;padding:11px;cursor:pointer}.crm-quote-result:hover{background:#f0f7fa}.crm-quote-result small{color:#567}.crm-quote-history-row,.crm-quote-event{padding:12px 0;border-bottom:1px solid #e5edf2}.crm-quote-history-row{display:flex;justify-content:space-between;gap:12px}.crm-quote-event small{display:block;color:#657c8a}.crm-quote-event p{margin:4px 0;font-size:13px}.crm-quote-feedback{color:#a33232;margin-top:12px}@media(max-width:900px){.crm-quote-layout{grid-template-columns:1fr}.crm-quote-metrics{grid-template-columns:1fr}.crm-quote-list-row{flex-wrap:wrap}}
/* Phase 4C.3: compact, accessible quotation workspace */
.crm-quote-modern{max-width:1550px;margin:0 auto}.crm-quote-modern-heading{margin-bottom:18px}.crm-quote-modern-heading h1{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.crm-quote-compact-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin:0 0 18px}.crm-quote-compact-stats>div{background:#fff;border:1px solid #dce6ed;border-radius:12px;padding:16px 20px;display:flex;flex-direction:column;gap:4px}.crm-quote-compact-stats small{font-size:11px;letter-spacing:.07em;font-weight:700;color:#60788b}.crm-quote-compact-stats strong{font-size:20px;color:#143b53}.crm-quote-compact-stats span{font-size:13px;color:#637d8b}.crm-quote-toolbar{display:flex;justify-content:space-between;align-items:center;gap:14px;margin:0 0 12px;flex-wrap:wrap}.crm-quote-tabs{display:flex;gap:4px;border-bottom:1px solid #d9e4ec;overflow-x:auto}.crm-quote-tabs button{border:0;background:transparent;padding:12px 16px;color:#587487;cursor:pointer;white-space:nowrap;font-weight:600}.crm-quote-tabs button.active{color:#155477;border-bottom:3px solid #1471a0}.crm-quote-modern-panel{background:#fff;border:1px solid #dce6ed;border-radius:12px;padding:22px;margin-bottom:20px}.crm-quote-modern-panel[hidden],.crm-quote-dialog[hidden]{display:none!important}.crm-quote-panel-heading h2{font-size:20px;margin:0 0 4px}.crm-quote-panel-heading p{color:#667d8b;font-size:14px;margin:0 0 18px}.crm-quote-modern-table th{font-size:11px;letter-spacing:.04em;white-space:nowrap}.crm-quote-modern-table td{font-size:14px;padding:16px 10px}.crm-quote-number{text-align:right;font-variant-numeric:tabular-nums;white-space:nowrap}.crm-quote-product-link{border:0;background:none;text-align:left;color:#174c69;cursor:pointer;padding:0;display:flex;flex-direction:column;gap:4px}.crm-quote-product-link:hover strong{text-decoration:underline}.crm-quote-product-link strong{font-size:14px}.crm-quote-product-link small{font-size:12px;color:#718392}.crm-quote-empty{text-align:center;padding:46px!important}.crm-quote-empty strong,.crm-quote-empty span{display:block}.crm-quote-empty span{color:#6d8290;margin-top:7px}.crm-quote-total-strip{display:flex;align-items:flex-end;justify-content:flex-end;gap:28px;padding:18px 8px 0;flex-wrap:wrap}.crm-quote-total-strip>div{display:flex;flex-direction:column;gap:5px}.crm-quote-total-strip span{color:#637b8c;font-size:12px}.crm-quote-total-strip strong{font-size:16px}.crm-quote-total-strip .crm-quote-grand strong{font-size:23px;color:#103c54}.crm-quote-dialog{position:fixed;inset:0;z-index:1050;display:flex;align-items:center;justify-content:center;padding:18px}.crm-quote-dialog-shade{position:absolute;inset:0;background:rgba(12,35,51,.58)}.crm-quote-dialog-card{position:relative;width:min(640px,100%);max-height:90vh;overflow-y:auto;background:#fff;border-radius:14px;box-shadow:0 20px 70px rgba(0,0,0,.2);padding:26px}.crm-quote-detail-card{width:min(780px,100%)}.crm-quote-dialog-head{display:flex;align-items:start;justify-content:space-between;gap:20px;margin-bottom:18px}.crm-quote-dialog-head h2{margin:0 0 5px;font-size:23px}.crm-quote-dialog-head p{margin:0;color:#60798a}.crm-quote-dialog-close{border:0;background:#eef3f6;color:#173f54;border-radius:9px;font-size:26px;cursor:pointer;width:38px;height:38px}.crm-quote-dialog-open{overflow:hidden}.crm-quote-field{display:block;margin:14px 0;font-weight:600}.crm-quote-field .form-control{margin-top:6px}.crm-quote-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;margin:14px 0}.crm-quote-form-grid label{display:block;font-weight:600}.crm-quote-form-grid input{margin-top:6px}.crm-quote-dialog-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:22px;flex-wrap:wrap}.crm-quote-dialog .crm-quote-results{margin-top:8px}.crm-quote-dialog .crm-quote-selected{max-width:none;margin-top:14px;font-weight:600}@media(max-width:700px){.crm-quote-compact-stats{grid-template-columns:1fr}.crm-quote-form-grid{grid-template-columns:1fr}.crm-quote-modern-panel{padding:14px}.crm-quote-total-strip{justify-content:space-between;gap:14px}}

/* Phase 4C.3a: quote line creation with full commercial details */
.crm-quote-add-total{display:flex;justify-content:space-between;align-items:center;padding:14px 16px;margin-top:14px;background:#edf5fa;border:1px solid #d4e5ef;border-radius:10px;font-size:15px}.crm-quote-add-total strong{font-size:21px;color:#123b54}.crm-quote-dialog-card:has(#quote-line-form){max-height:min(90vh,920px);overflow-y:auto}.crm-quote-dialog-card:has(#quote-line-form) .crm-quote-form-grid{gap:12px 16px}.crm-quote-dialog-card:has(#quote-line-form) label{font-size:13px}

/* Phase 4C.4: compact Opportunity workspace; no behavioural changes to stage selection. */
.crm-opportunity-workspace .crm-opportunity-heading{margin-bottom:12px;gap:12px}
.crm-opportunity-workspace .crm-opportunity-heading h1{font-size:clamp(22px,2vw,30px);line-height:1.2;margin:5px 0}
.crm-opportunity-workspace .crm-opportunity-heading .page-intro{margin:4px 0;font-size:12px}
.crm-opportunity-workspace .crm-opportunity-pipeline{padding:10px 14px!important;margin-bottom:10px!important}
.crm-opportunity-workspace .crm-opportunity-pipeline .crm-opportunity-section-head{margin-bottom:4px}
.crm-opportunity-workspace .crm-opportunity-pipeline .crm-opportunity-section-head h2{display:inline;font-size:13px!important}
.crm-opportunity-workspace .crm-opportunity-pipeline .section-kicker{display:none}
.crm-opportunity-workspace .crm-stage-trail{gap:4px;padding:4px 2px 8px}
.crm-opportunity-workspace .crm-stage-trail .crm-opportunity-step{min-height:32px!important;flex-basis:110px!important;padding:4px 6px!important;gap:5px!important}
.crm-opportunity-workspace .crm-stage-trail .crm-stage-trail-label{font-size:9px!important;-webkit-line-clamp:2}
.crm-opportunity-workspace .crm-stage-trail .crm-opportunity-step-icon{width:17px!important;height:17px!important;min-width:17px!important;font-size:9px!important}
.crm-opportunity-workspace .crm-opportunity-pipeline .crm-stage-history{margin-top:0;font-size:11px}
.crm-opportunity-workspace .crm-opportunity-metrics{gap:10px;margin-bottom:10px}
.crm-opportunity-workspace .crm-opportunity-metric{padding:12px 15px;gap:4px}
.crm-opportunity-workspace .crm-opportunity-metric>strong{font-size:clamp(18px,1.8vw,23px)}
.crm-opportunity-workspace .crm-opportunity-tabs{margin-bottom:12px}
.crm-opportunity-workspace .crm-opportunity-tabs button{padding:10px 13px}
.crm-opportunity-workspace .crm-opportunity-panel{padding:16px 18px}
.crm-opportunity-workspace .crm-opportunity-section-head{margin-bottom:10px}
.crm-opportunity-workspace .crm-opportunity-section-head h2{font-size:16px}
.crm-opportunity-workspace .crm-opportunity-overview{grid-template-columns:minmax(0,1.6fr) minmax(260px,1fr);gap:12px}
.crm-opportunity-workspace .crm-opportunity-side{gap:12px}
.crm-opportunity-workspace .crm-opportunity-facts{gap:7px 14px}
.crm-opportunity-workspace .crm-opportunity-facts>div{padding:8px 0;border:0;border-bottom:1px solid var(--line);border-radius:0;background:transparent;display:flex;align-items:baseline;justify-content:space-between;gap:12px}
.crm-opportunity-workspace .crm-opportunity-facts dt{margin:0;flex:0 0 85px;font-size:10px}
.crm-opportunity-workspace .crm-opportunity-facts dd{text-align:right;font-size:12px}
.crm-opportunity-workspace .crm-opportunity-description{margin-top:12px}
.crm-opportunity-workspace .crm-opportunity-description h3{font-size:12px;margin-bottom:4px}
.crm-opportunity-workspace .crm-opportunity-description p{margin:0}
.crm-opportunity-workspace .crm-opportunity-linked{gap:5px}
.crm-opportunity-workspace .crm-opportunity-linked a{padding:7px 10px}
.crm-opportunity-quick-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:14px}
.crm-opportunity-quotes-tab .crm-quote-opportunity-panel{margin-top:0;padding:18px}
.crm-opportunity-quotes-tab .crm-quote-list{margin:8px 0}
@media(max-width:1000px){.crm-opportunity-workspace .crm-opportunity-overview{grid-template-columns:1fr}}
@media(max-width:650px){.crm-opportunity-workspace .crm-opportunity-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-opportunity-workspace .crm-opportunity-facts{grid-template-columns:1fr}.crm-opportunity-workspace .crm-opportunity-heading-actions{justify-content:flex-start}}

/* Phase 4C.5: premium Opportunity workspace, scoped to avoid changes elsewhere. */
.crm-wow-workspace{--wow-navy:#173e56;--wow-ink:#15384d;--wow-orange:#f4a044;max-width:1560px}
.crm-wow-hero{background:linear-gradient(112deg,#14364d 0%,#1a4860 70%,#24536a 100%);border-radius:16px;color:#fff;padding:27px 32px 25px;box-shadow:0 12px 30px rgba(16,48,68,.15);position:relative;overflow:hidden;margin-bottom:15px}
.crm-wow-hero:after{content:"";position:absolute;right:-90px;top:-170px;width:460px;height:460px;border:1px solid rgba(255,255,255,.09);border-radius:50%;box-shadow:0 0 0 70px rgba(255,255,255,.025),0 0 0 150px rgba(255,255,255,.018);pointer-events:none}
.crm-wow-hero-top,.crm-wow-hero-actions,.crm-wow-customer,.crm-wow-progress-head{display:flex;align-items:center;justify-content:space-between;gap:14px}.crm-wow-hero-top{position:relative;z-index:1}
.crm-wow-eyebrow{font-size:10px;letter-spacing:.15em;font-weight:800;color:#f7b766}.crm-wow-hero h1{color:white!important;font-size:clamp(23px,2.5vw,36px)!important;line-height:1.2;margin:14px 0 8px;max-width:1060px;position:relative;z-index:1}
.crm-wow-customer{justify-content:flex-start;flex-wrap:wrap;color:#c5dce8;font-size:13px;position:relative;z-index:1}.crm-wow-customer a{color:#d8e9f2;text-decoration:none}.crm-wow-customer a:hover{text-decoration:underline}.crm-wow-dot{color:#f4a044}
.crm-wow-status{border:1px solid rgba(255,255,255,.24);background:rgba(255,255,255,.11);border-radius:100px;padding:7px 11px;font-size:11px;font-weight:700;max-width:360px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#f1f8fb}.crm-wow-edit{background:#fff!important;color:#17445e!important;border:0!important;white-space:nowrap;font-weight:700}
.crm-wow-hero-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:22px;margin-top:24px;padding-top:20px;border-top:1px solid rgba(255,255,255,.2);position:relative;z-index:1}
.crm-wow-hero-metrics>div{display:flex;flex-direction:column;gap:6px;min-width:0}.crm-wow-hero-metrics span{font-size:10px;font-weight:800;letter-spacing:.09em;color:#b4d0df}.crm-wow-hero-metrics strong{font-size:clamp(20px,2.1vw,29px);line-height:1.2;color:#fff;overflow-wrap:anywhere}.crm-wow-hero-metrics small{font-size:11px;color:#b8d1df}
.crm-wow-progress{background:#fff;border:1px solid #dce7ed;border-radius:12px;padding:15px 20px;margin-bottom:15px;box-shadow:0 3px 10px rgba(22,55,73,.035)}
.crm-wow-progress-head{margin-bottom:13px}.crm-wow-progress-head>div{display:flex;align-items:center;gap:12px;flex-wrap:wrap}.crm-wow-progress-kicker{font-size:10px;letter-spacing:.1em;font-weight:800;color:#668296}.crm-wow-progress-head strong{font-size:13px;color:#1b4e6b}.crm-wow-expand{border:0;background:#eaf3f8;color:#1b5779;border-radius:7px;padding:8px 12px;font-size:12px;font-weight:750;cursor:pointer}.crm-wow-expand:hover{background:#dbeaf4}
.crm-wow-progress-bars{display:flex;gap:4px}.crm-wow-bar{height:11px;min-width:2px;flex:1;border-radius:4px;background:#e7edf1}.crm-wow-bar.complete{background:#279a77}.crm-wow-bar.current{background:#f2a04a;box-shadow:0 0 0 2px rgba(242,160,74,.18)}.crm-wow-stage-expanded{padding-top:14px}.crm-wow-stage-expanded .crm-stage-trail{padding-bottom:12px}.crm-wow-stage-expanded .crm-opportunity-step{flex-basis:170px!important;min-height:52px!important}.crm-wow-stage-expanded .crm-stage-trail-label{font-size:11px!important;-webkit-line-clamp:3!important}
.crm-wow-workspace .crm-opportunity-tabs{background:#fff;border:1px solid #e0e9ee;border-radius:11px;padding:5px;gap:4px;margin-bottom:18px;box-shadow:0 3px 12px rgba(20,54,77,.035)}.crm-wow-workspace .crm-opportunity-tabs button{border:0!important;border-radius:7px;padding:12px 18px;font-size:13px}.crm-wow-workspace .crm-opportunity-tabs button.active{background:#e7f1f7;color:#124c6d}.crm-wow-workspace .crm-opportunity-panel,.crm-wow-workspace .crm-quote-opportunity-panel{border:1px solid #e1eaf0;border-radius:12px;box-shadow:0 4px 14px rgba(20,54,77,.035)}
.crm-wow-workspace .crm-opportunity-overview{gap:16px}.crm-wow-workspace .crm-opportunity-facts>div{padding:13px 4px}.crm-wow-workspace .crm-opportunity-facts dd{font-size:13px}.crm-wow-workspace .crm-opportunity-linked a{background:#f6fafc;padding:11px 13px}
.crm-wow-quotes-tab .crm-quote-opportunity-panel{padding:24px!important;background:transparent;border:0!important;box-shadow:none!important}.crm-wow-quotes-tab .crm-card-heading{margin-bottom:20px}.crm-wow-quotes-tab .crm-card-heading h2{font-size:23px;margin:5px 0}.crm-wow-quotes-tab .crm-card-heading p{font-size:13px;color:#688093}.crm-wow-quotes-tab .crm-quote-list{display:grid;gap:12px}
.crm-wow-quote-card{display:flex;align-items:center;gap:19px;padding:22px 24px;background:#fff;border:1px solid #dce8ef;border-radius:13px;color:#163d54;text-decoration:none;box-shadow:0 4px 14px rgba(20,54,77,.045);transition:transform .15s,box-shadow .15s,border-color .15s}.crm-wow-quote-card:hover{transform:translateY(-2px);box-shadow:0 10px 25px rgba(20,54,77,.1);border-color:#8eb6ce;text-decoration:none}.crm-wow-quote-icon{display:grid;place-items:center;width:52px;height:52px;flex:0 0 52px;background:#e8f3f8;border-radius:11px;font-size:29px;color:#216a8e}.crm-wow-quote-body{flex:1;min-width:0}.crm-wow-quote-title{font-size:19px;font-weight:800}.crm-wow-quote-title span{font-size:12px;font-weight:700;color:#617e90;margin-left:7px}.crm-wow-quote-meta{font-size:12px;color:#657e8d;margin-top:7px}.crm-wow-quote-meta span{padding:0 5px;color:#b5c4ce}.crm-wow-quote-total{display:flex;flex-direction:column;align-items:flex-end;gap:5px}.crm-wow-quote-total small{font-size:10px;letter-spacing:.08em;color:#728a99;font-weight:750}.crm-wow-quote-total strong{font-size:22px;color:#153e55;white-space:nowrap}.crm-wow-quote-arrow{font-size:24px;color:#2a7598;margin-left:6px}.crm-wow-count{font-size:13px;color:#658295}
@media(max-width:950px){.crm-wow-hero-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-wow-quote-card{flex-wrap:wrap}.crm-wow-quote-total{margin-left:auto}}@media(max-width:650px){.crm-wow-hero{padding:20px}.crm-wow-hero-top,.crm-wow-hero-actions{align-items:flex-start;flex-wrap:wrap}.crm-wow-hero-metrics{gap:16px}.crm-wow-hero-metrics strong{font-size:19px}.crm-wow-progress{padding:12px}.crm-wow-progress-head{align-items:flex-start;flex-direction:column}.crm-wow-workspace .crm-opportunity-tabs button{padding:10px 12px}.crm-wow-quote-card{padding:16px;gap:12px}.crm-wow-quote-total{width:100%;align-items:flex-start;margin-left:64px}.crm-wow-quote-arrow{display:none}}

/* Phase 4C.6: one scrolling, numbered stage track. Every label shares its bar's column. */
.crm-wow-stage-track{overflow-x:auto;overflow-y:hidden;scrollbar-width:thin;scrollbar-color:#91a8b5 #eaf0f4;overscroll-behavior-inline:contain;padding-bottom:8px}
.crm-wow-stage-grid{display:grid;grid-template-columns:repeat(26,minmax(64px,1fr));gap:5px;min-width:1850px;align-items:stretch}
.crm-wow-stage-grid .crm-wow-stage-cell{display:flex!important;flex-direction:column;justify-content:flex-start;align-items:stretch;gap:6px;min-width:0!important;min-height:0!important;width:100%;flex-basis:auto!important;text-align:center;padding:0!important;border:0!important;border-radius:7px!important;background:transparent!important;box-shadow:none!important;outline-offset:2px;cursor:pointer;color:#254a5f!important}
.crm-wow-stage-grid .crm-wow-stage-number{display:grid;place-items:center;height:28px;border-radius:6px;background:#e5edf2;color:#456375;font-size:12px;font-weight:800;transition:background .15s,box-shadow .15s}
.crm-wow-stage-grid .crm-wow-stage-cell.complete .crm-wow-stage-number{background:#279a77;color:white}
.crm-wow-stage-grid .crm-wow-stage-cell.current .crm-wow-stage-number{background:#f2a04a;color:#173e56;box-shadow:0 0 0 2px rgba(242,160,74,.25)}
.crm-wow-stage-grid .crm-wow-stage-cell:hover .crm-wow-stage-number{filter:brightness(.93)}
.crm-wow-stage-grid .crm-wow-stage-cell:focus-visible{outline:2px solid #287aa9}
.crm-wow-stage-grid .crm-wow-stage-description{display:block;min-height:58px;max-height:76px;overflow:hidden;font-size:10px;font-weight:700;line-height:1.3;overflow-wrap:anywhere;text-align:left;padding:7px 4px;color:#38576a}
.crm-wow-stage-grid .crm-wow-stage-cell.current .crm-wow-stage-description{color:#a05b15}
.crm-wow-stage-foot{display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap;color:#728897;font-size:11px;margin:6px 0 10px}
.crm-wow-progress .crm-stage-history{border-top:1px solid #e8eff3;padding-top:9px}
.crm-unified-quote-hero{margin-bottom:16px}
.crm-unified-quote-hero .crm-unified-quote-status{display:inline-flex;border:1px solid rgba(255,255,255,.28);background:rgba(255,255,255,.12);border-radius:30px;padding:7px 12px;color:#fff;font-size:12px;font-weight:800;white-space:nowrap}
.crm-unified-quote-metrics strong{font-size:clamp(18px,2vw,27px)!important}
.crm-quote-modern .crm-quote-toolbar{background:white;border:1px solid #dfeaf0;border-radius:12px;padding:8px 12px;box-shadow:0 3px 12px rgba(20,54,77,.04);margin-bottom:16px}
.crm-quote-modern .crm-quote-tabs{border:0;gap:4px}
.crm-quote-modern .crm-quote-tabs button{border:0!important;border-radius:7px;padding:11px 15px;font-size:13px;font-weight:700}
.crm-quote-modern .crm-quote-tabs button.active{background:#e7f1f7;color:#124c6d}
.crm-quote-modern .crm-quote-modern-panel{border-color:#dfeaf0;box-shadow:0 4px 14px rgba(20,54,77,.045)}
.crm-quote-modern .crm-quote-modern-table tbody tr:hover{background:#f5fafc}
@media(max-width:650px){.crm-wow-stage-grid{min-width:1650px;grid-template-columns:repeat(26,minmax(58px,1fr))}.crm-unified-quote-hero .crm-wow-hero-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-quote-modern .crm-quote-toolbar{align-items:stretch}}
/* Phase 4C.7 — preserved quote versions */
.crm-version-list{display:grid;gap:12px;margin:20px 0}.crm-version-card{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:17px 20px;border:1px solid #dce6ec;border-radius:12px;background:#f8fbfd}.crm-version-card>div{display:grid;gap:6px}.crm-version-card small{color:#647c89}.crm-history-workspace .crm-quote-modern-panel{margin-top:18px}.crm-history-workspace td p{white-space:normal;margin:8px 0}.crm-history-workspace td{vertical-align:top}
@media(max-width:650px){.crm-version-card{align-items:flex-start;flex-direction:column}}

/* Phase 4C.8 — commercial intelligence overview */
.crm-intelligence-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin:20px 0 10px}.crm-intelligence-panel{background:#fff;border:1px solid #dce8ef;border-radius:14px;padding:22px;box-shadow:0 5px 22px rgba(18,54,76,.045);min-width:0}.crm-intelligence-head{margin-bottom:16px}.crm-intelligence-head h2{font-size:1.12rem;margin:5px 0;color:#173e56}.crm-intelligence-panel p{line-height:1.55}.crm-intelligence-quote{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px;padding:14px;background:#edf5f9;border-radius:10px;text-decoration:none}.crm-intelligence-quote strong{font-size:1.1rem}.crm-intelligence-sub{font-size:.85rem;color:#60798a;margin:12px 0}.crm-intelligence-panel .btn{margin-top:8px}@media(max-width:850px){.crm-intelligence-grid{grid-template-columns:1fr}}

/* Phase 4C.9 Opportunity management */
.crm49-heading{font-size:.78rem;letter-spacing:.075em;text-transform:uppercase;font-weight:800;color:#225c78;margin:1.5rem 0 .7rem;padding-bottom:.6rem;border-bottom:1px solid #d8e5ed}.crm49-relationships{margin:1rem 0;padding:1.4rem;border:1px solid #d8e5ed;border-radius:14px;background:#fff}.crm49-supersede{margin-top:1rem;padding:1rem;border:1px solid #d8e5ed;border-radius:10px}.crm49-supersede summary{cursor:pointer;font-weight:700;color:#194c66}.crm49-supersede form{display:grid;gap:1rem;margin-top:1rem;max-width:620px}

/* Phase 4C.10b: uniform opportunity tab card alignment and white surfaces. */
.crm-wow-workspace .crm-opportunity-tabs{margin-bottom:18px}
.crm-wow-workspace .crm-opportunity-quotes-tab .crm-quote-opportunity-panel{margin:0!important;padding:20px 22px!important;background:#fff!important;border:1px solid #e1eaf0!important;border-radius:12px!important;box-shadow:0 4px 14px rgba(20,54,77,.035)!important}
.crm-wow-workspace .crm-opportunity-quotes-tab .crm-card-heading{margin-top:0}
.crm-wow-workspace .crm-timeline{margin:0!important;padding:20px 22px!important;background:#fff!important;border:1px solid #e1eaf0!important;border-radius:12px!important;box-shadow:0 4px 14px rgba(20,54,77,.035)!important}
.crm-wow-workspace .crm-opportunity-panel,.crm-wow-workspace .crm49-relationships,.crm-wow-workspace .crm-opportunity-relations>.content-card{background:#fff!important}
.crm-wow-workspace .crm-timeline-compose{background:#fff}
@media(max-width:650px){.crm-wow-workspace .crm-opportunity-quotes-tab .crm-quote-opportunity-panel,.crm-wow-workspace .crm-timeline{padding:16px!important}}

/* Phase 4C.11d: full-width customer correspondence composer */
#quote-customer-dialog .crm-customer-email-card{width:min(760px,calc(100vw - 32px));max-width:none;padding:30px;max-height:min(92vh,950px);overflow-y:auto}
#quote-customer-dialog .crm-customer-email-form{display:flex;flex-direction:column;gap:14px;width:100%;min-width:0}
#quote-customer-dialog .crm-customer-email-form .crm-quote-field{display:flex;flex-direction:column;gap:7px;margin:0;width:100%;min-width:0;font-size:13px;font-weight:650;color:#21465f}
#quote-customer-dialog .crm-customer-email-form input.form-control,#quote-customer-dialog .crm-customer-email-form textarea.form-control{display:block;width:100%;max-width:100%;min-width:0;box-sizing:border-box;margin:0;font:inherit;border:1px solid #d3e0e8;border-radius:9px;background:#fff;padding:12px 14px;color:#183c53}
#quote-customer-dialog .crm-customer-email-form textarea.form-control{min-height:220px;resize:vertical;line-height:1.6}
#quote-customer-dialog .crm-customer-email-bcc,#quote-customer-dialog .crm-customer-email-attachment{display:flex;flex-direction:column;gap:4px;background:#f1f6fa;border:1px solid #dce7ee;border-radius:10px;padding:12px 14px;color:#244b64;font-size:13px}
#quote-customer-dialog .crm-customer-email-bcc span,#quote-customer-dialog .crm-customer-email-attachment span{color:#5c7484}
#quote-customer-dialog .crm-quote-dialog-actions{margin-top:4px}
.crm-quote-modern-table td:nth-child(3){min-width:110px;max-width:190px;overflow-wrap:anywhere}
@media(max-width:650px){#quote-customer-dialog .crm-customer-email-card{padding:20px}}

/* Phase 5B: match CRM Opportunities workspace */
.sales-order-workspace{width:100%;max-width:none;margin:0;padding:0}
.sales-order-workspace>.content-card{border:1px solid var(--line);border-radius:14px;box-shadow:none}
.sales-order-register .sales-order-filters{grid-template-columns:minmax(0,2.2fr) 1fr 1fr auto;align-items:end}
.sales-order-register .sales-order-filters label:nth-child(2) .btn{width:100%}
.sales-order-register .sales-order-filters>a{align-self:end}
.sales-order-workspace .page-heading{margin-bottom:20px}
@media(max-width:800px){.sales-order-register .sales-order-filters{grid-template-columns:1fr 1fr}}
@media(max-width:520px){.sales-order-register .sales-order-filters{grid-template-columns:1fr}}
