:root {
  --primary: #0f4c3a;
  --secondary: #c99a2e;
  --accent: #2f7d61;
  --surface: #fff;
  --background: #f3f6f4;
  --text: #17211d;
  --muted: #65736d;
  --danger: #b42318;
  --success: #087443;
  --radius: 14px;
  --font: Aptos, Segoe UI Variable, Inter, system-ui, sans-serif;
  --border: color-mix(in srgb, var(--muted) 22%, transparent);
  --shadow: 0 14px 38px rgba(15, 43, 33, .09);
  --sidebar: 272px;
  --sidebar-colour: #0c352a;
}

* { box-sizing: border-box; }
html { min-height: 100%; overflow-x: hidden; overflow-y: scroll; scrollbar-gutter: stable; color-scheme: light; }
body { margin: 0; min-height: 100%; overflow-x:hidden; overflow-y:visible; background: var(--background); color: var(--text); font-family: var(--font); font-size: 15px; line-height: 1.45; }
button, input, textarea, select { font: inherit; }
button { color: inherit; }
a { color: inherit; }
img, video { max-width: 100%; }
.ui-icon { display:block; width:20px; height:20px; flex:0 0 auto; max-width:100%; max-height:100%; }
[hidden] { display: none !important; }

:focus-visible { outline: 3px solid color-mix(in srgb, var(--secondary) 70%, white); outline-offset: 2px; }

.brand-mark { display: inline-grid; place-items: center; width: 42px; height: 42px; flex: 0 0 auto; border-radius: 13px; background: linear-gradient(145deg, var(--primary), var(--accent)); color: #fff; font-weight: 850; letter-spacing: -.04em; box-shadow: 0 8px 20px color-mix(in srgb, var(--primary) 28%, transparent); }
.brand-mark-large { width: 72px; height: 72px; border-radius: 22px; font-size: 23px; }

.btn { border: 1px solid transparent; border-radius: 11px; min-height: 42px; max-width:100%; padding: 9px 15px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-weight: 720; line-height:1.2; white-space:nowrap; overflow-wrap:normal; word-break:keep-all; cursor: pointer; transition: transform .15s ease, background .15s ease, border .15s ease, opacity .15s ease; text-decoration: none; }
.btn:hover { transform: translateY(-1px); }
.btn:disabled { cursor: not-allowed; opacity: .55; transform: none; }
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 8px 20px color-mix(in srgb, var(--primary) 20%, transparent); }
.btn-primary:hover { background: color-mix(in srgb, var(--primary) 88%, black); }
.btn-secondary { background: var(--surface); color: var(--primary); border-color: var(--border); }
.btn-secondary:hover { background: color-mix(in srgb, var(--primary) 5%, var(--surface)); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-quiet { background: transparent; color: var(--muted); }
.btn-small { min-height: 34px; padding: 6px 10px; font-size: 13px; }
.btn-block { width: 100%; }
.link-button { border: 0; background: transparent; color: var(--primary); padding: 8px 0; font-weight: 700; cursor: pointer; }

.field { display: grid; gap: 7px; min-width: 0; }
.field > span, .field-label { color: var(--text); font-weight: 700; font-size: 13px; }
.field > span span, .required { color: var(--danger); }
.field small { color: var(--muted); font-size: 12px; }
.field input, .field textarea, .field select, .control { width: 100%; min-height: 44px; border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; color: var(--text); background: var(--surface); transition: border .15s, box-shadow .15s; }
.field textarea { min-height: 108px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 15%, transparent); outline: none; }
.field input[readonly] { background: color-mix(in srgb, var(--muted) 7%, var(--surface)); color: var(--muted); }
.field.has-error input, .field.has-error textarea, .field.has-error select { border-color: var(--danger); }
.field-error { color: var(--danger); font-size: 12px; font-weight: 650; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.form-grid .span-2 { grid-column: 1 / -1; }
.checkbox-field, .radio-option { display: flex; align-items: flex-start; gap: 9px; font-weight: 550; }
.checkbox-field input, .radio-option input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--primary); }
.option-row { display: flex; flex-wrap: wrap; gap: 14px; padding: 8px 0; }
.inline-control { display: flex; gap: 8px; }
.inline-control input { min-width: 0; }
.form-alert, .install-alert { padding: 12px 14px; border-radius: 10px; background: color-mix(in srgb, var(--danger) 9%, white); color: var(--danger); border: 1px solid color-mix(in srgb, var(--danger) 25%, white); font-weight: 650; }

/* One consistent feedback surface for success, information, warning and errors. */
.feedback-backdrop { position: fixed; inset: 0; z-index: 1200; display: grid; place-items: center; padding: 20px; background: rgba(6,24,19,.48); backdrop-filter: blur(9px); animation: feedbackIn .2s ease both; }
.feedback-backdrop.leaving { animation: feedbackOut .18s ease both; }
.feedback-modal { --feedback: var(--primary); width: min(490px,100%); position: relative; display: grid; grid-template-columns: 64px minmax(0,1fr); gap: 18px; align-items: start; padding: 28px; border-radius: 24px; background: linear-gradient(145deg,color-mix(in srgb,var(--feedback) 8%,white),var(--surface) 58%); border: 1px solid color-mix(in srgb,var(--feedback) 28%,var(--border)); box-shadow: 0 30px 90px rgba(4,31,23,.35), inset 0 1px rgba(255,255,255,.8); animation: feedbackCard .25s cubic-bezier(.2,.8,.2,1) both; }
.feedback-success .feedback-modal { --feedback: var(--success); }.feedback-error .feedback-modal { --feedback: var(--danger); }.feedback-warning .feedback-modal { --feedback: #c78000; }.feedback-info .feedback-modal { --feedback: #2776c9; }
.feedback-symbol { width: 60px; height: 60px; border-radius: 20px; display: grid; place-items: center; color: white; background: linear-gradient(145deg,color-mix(in srgb,var(--feedback) 88%,white),var(--feedback)); box-shadow: 0 12px 25px color-mix(in srgb,var(--feedback) 28%,transparent); font-size: 28px; font-weight: 900; }
.feedback-modal small { display: block; margin: 2px 0 4px; color: var(--feedback); font-size: 10px; font-weight: 900; letter-spacing: .16em; }
.feedback-modal h2 { margin: 0; font-size: 22px; letter-spacing: -.025em; }.feedback-modal p { margin: 8px 0 0; color: var(--text); line-height: 1.58; overflow-wrap: anywhere; }.feedback-reference { display: inline-block; margin-top: 11px; color: var(--muted); font-size: 11px; }
.feedback-modal > .btn { grid-column: 2; justify-self: end; min-width: 94px; }.feedback-close { position: absolute; top: 11px; right: 13px; width: 34px; height: 34px; border: 0; border-radius: 11px; background: color-mix(in srgb,var(--feedback) 7%,var(--surface)); color: var(--muted); cursor: pointer; font-size: 21px; }
@keyframes feedbackIn { from { opacity: 0; } } @keyframes feedbackOut { to { opacity: 0; } } @keyframes feedbackCard { from { transform: translateY(18px) scale(.97); opacity: 0; } }
@media (max-width:520px) { .feedback-modal { grid-template-columns: 48px minmax(0,1fr); padding: 22px; gap: 13px; }.feedback-symbol { width: 47px; height: 47px; border-radius: 15px; }.feedback-modal > .btn { grid-column: 1 / -1; width: 100%; } }

/* Installation */
.install-page { background: radial-gradient(circle at top right, color-mix(in srgb, var(--secondary) 14%, transparent), transparent 32%), var(--background); }
.install-shell { width: min(1080px, calc(100% - 28px)); margin: 34px auto 70px; }
.install-heading { display: flex; gap: 15px; align-items: center; margin-bottom: 24px; }
.install-heading h1 { margin: 0; font-size: clamp(26px, 4vw, 38px); letter-spacing: -.04em; }
.install-heading p { color: var(--muted); margin: 4px 0 0; }
.install-form { display: grid; gap: 20px; }
.install-section { background: var(--surface); border: 1px solid var(--border); padding: clamp(18px, 3vw, 28px); border-radius: var(--radius); box-shadow: var(--shadow); }
.install-section h2 { margin: 0 0 20px; font-size: 18px; }
.install-actions { display: flex; justify-content: flex-end; }

/* Login */
.login-page { background: var(--primary); overflow-x: hidden; }
.login-media { position: fixed; inset: 0; background: radial-gradient(circle at 20% 20%, color-mix(in srgb, var(--secondary) 28%, transparent), transparent 40%), linear-gradient(130deg, color-mix(in srgb, var(--primary) 90%, black), var(--accent)); background-size: cover; background-position: center; }
.login-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, color-mix(in srgb, var(--primary) 80%, transparent), color-mix(in srgb, var(--primary) 38%, transparent)); }
.login-media video { width: 100%; height: 100%; object-fit: cover; display: none; }
.login-media.has-video video { display: block; }
.login-shell { position: relative; z-index: 1; width: min(1180px, calc(100% - 28px)); min-height: 100vh; margin: auto; display: grid; grid-template-columns: minmax(0, 1fr) minmax(360px, 450px); align-items: center; gap: clamp(34px, 8vw, 120px); padding: 40px 0; }
.login-brand { color: #fff; max-width: 620px; }
.login-brand p { margin: 24px 0 4px; text-transform: uppercase; font-weight: 750; letter-spacing: .1em; opacity: .82; font-size: 13px; }
.login-brand h1 { font-size: clamp(36px, 6vw, 68px); line-height: .98; letter-spacing: -.055em; margin: 0 0 18px; max-width: 700px; }
.login-brand > span:last-child { font-size: 18px; opacity: .88; font-style: italic; }
.login-card { background: color-mix(in srgb, var(--surface) 96%, transparent); backdrop-filter: blur(18px); padding: clamp(24px, 4vw, 38px); border-radius: 24px; box-shadow: 0 28px 70px rgba(0, 0, 0, .24); display: grid; gap: 20px; }
.login-card h2 { margin: 3px 0 0; font-size: 30px; letter-spacing: -.035em; }
.eyebrow { color: var(--primary); font-weight: 800; letter-spacing: .07em; text-transform: uppercase; font-size: 12px; }
#login-form { display: grid; gap: 16px; }
.password-field { position: relative; }
.password-field input { padding-right: 64px; }
.password-toggle { position: absolute; right: 6px; top: 6px; height: 32px; border: 0; background: transparent; color: var(--primary); font-size: 12px; font-weight: 750; cursor: pointer; }
.verify-mini { padding-top: 18px; border-top: 1px solid var(--border); }
.login-card footer { color: var(--muted); font-size: 12px; text-align: center; }

/* Application shell */
.app-loading { min-height: 100vh; display: grid; place-content: center; justify-items: center; gap: 13px; color: var(--muted); }
.loading-mark { width: 52px; height: 52px; border-radius: 17px; display: grid; place-items: center; background: var(--primary); color: white; font-weight: 850; animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 50% { transform: scale(.94); opacity: .75; } }
.app-shell { min-height: 100vh; display: grid; grid-template-columns: var(--sidebar) minmax(0, 1fr); }
.sidebar { position: fixed; inset: 0 auto 0 0; width: var(--sidebar); background: var(--sidebar-colour); color: #e9f3ef; display: flex; flex-direction: column; z-index: 40; border-right: 1px solid rgba(255,255,255,.08); }
.sidebar-brand { min-height: 84px; display: flex; align-items: center; gap: 12px; padding: 18px 19px; border-bottom: 1px solid rgba(255,255,255,.08); }
.sidebar-brand .brand-mark { background: linear-gradient(145deg, var(--secondary), #f1c96a); color: #332407; }
.sidebar-brand strong { display: block; font-size: 16px; }
.sidebar-brand small { display: block; opacity: .65; margin-top: 1px; max-width: 170px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-nav { flex: 1; overflow-y: auto; padding: 14px 10px 28px; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.2) transparent; }
.nav-group-label { display: block; margin: 18px 11px 7px; color: rgba(255,255,255,.45); font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .12em; }
.nav-link { width: 100%; border: 0; background: transparent; color: rgba(255,255,255,.78); display: flex; align-items: center; gap: 11px; min-height: 42px; padding: 9px 11px; border-radius: 10px; cursor: pointer; text-align: left; font-weight: 620; font-size: 13px; }
.nav-link:hover { color: #fff; background: rgba(255,255,255,.07); }
.nav-link.active { color: #fff; background: rgba(255,255,255,.13); box-shadow: inset 3px 0 0 var(--secondary); }
.nav-icon { width: 25px; height: 25px; display: grid; place-items: center; border-radius: 8px; background: rgba(255,255,255,.07); font-size: 11px; font-weight: 850; }
.sidebar-footer { padding: 13px; border-top: 1px solid rgba(255,255,255,.08); }
.sidebar-user { display: flex; align-items: center; gap: 10px; padding: 7px; min-width: 0; }
.user-avatar { width: 38px; height: 38px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 12px; background: color-mix(in srgb, var(--secondary) 85%, white); color: #352708; font-weight: 850; }
.sidebar-user div { min-width: 0; }
.sidebar-user strong, .sidebar-user small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-user small { color: rgba(255,255,255,.5); font-size: 11px; }
.signout-btn { width: 100%; margin-top: 5px; color: rgba(255,255,255,.75); }
.app-main { grid-column: 2; min-width: 0; min-height: 100vh; display: grid; grid-template-rows: 72px minmax(calc(100vh - 72px),auto); }
.topbar { height: 72px; position: sticky; top:0; z-index: 30; display: flex; align-items: center; gap: 15px; padding: 0 clamp(16px, 3vw, 34px); background: color-mix(in srgb, var(--surface) 90%, transparent); backdrop-filter: blur(16px); border-bottom: 1px solid var(--border); }
.menu-toggle { display: none; border: 1px solid var(--border); background: var(--surface); border-radius: 10px; width: 42px; height: 42px; cursor: pointer; }
.page-context { min-width: 0; }
.page-context strong { display: block; font-size: 15px; }
.page-context small { display: block; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 270px; }
.global-search { margin-left:auto; width:min(460px,42vw); position:relative; display:flex; align-items:center; transition:width .18s ease; }
.global-search input { width:100%; height:42px; border-radius:12px; border:1px solid var(--border); background:var(--background); padding:8px 78px 8px 14px; }
.global-search button { position:absolute; top:4px; width:34px; height:34px; border:0; background:transparent; color:var(--muted); cursor:pointer; display:grid; place-items:center; }
.global-search .global-search-toggle { left:4px; right:auto; }
.global-search .global-search-submit { right:4px; }
.global-search:not(.is-collapsed) .global-search-toggle { display:none; }
.global-search.is-collapsed { width:42px; height:42px; }
.global-search.is-collapsed input,.global-search.is-collapsed .global-search-submit { visibility:hidden; pointer-events:none; }
.global-search.is-collapsed .global-search-toggle { inset:4px; border:1px solid var(--border); border-radius:9px; background:var(--surface); color:var(--text); }
.search-results { position:absolute; top:calc(100% + 8px); right:0; width:min(560px,calc(100vw - 32px)); background:var(--surface); border:1px solid var(--border); border-radius:12px; box-shadow:var(--shadow); padding:6px; max-height:min(520px,70vh); overflow-y:auto; overflow-x:hidden; }
.search-result { width:100%; min-width:0; display:grid; grid-template-columns:34px minmax(0,1fr); align-items:center; gap:9px; padding:10px; border:0; background:transparent; text-align:left; border-radius:9px; color:var(--text); cursor:pointer; }
.search-result:hover,.search-result:focus-visible { background:color-mix(in srgb,var(--primary) 9%,var(--surface)); outline:none; }
.search-result>span:last-child { min-width:0; display:grid; gap:2px; }
.search-result strong,.search-result small { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.search-result small { color:var(--muted); }
.search-result-icon { width:32px; height:32px; display:grid; place-items:center; border-radius:9px; background:color-mix(in srgb,var(--primary) 10%,var(--surface)); color:var(--primary); }
.search-result-icon .ui-icon { width:17px; height:17px; }
.topbar-action { position: relative; width: 42px; height: 42px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); cursor: pointer; }
.notification-dot { position: absolute; top: -4px; right: -4px; min-width: 19px; height: 19px; border-radius: 10px; background: var(--danger); color: white; font-size: 10px; font-weight: 800; display: grid; place-items: center; border: 2px solid var(--surface); }
.content { width: 100%; padding: clamp(19px, 3vw, 34px); max-width: 1600px; margin: 0 auto; min-height: calc(100vh - 72px); overflow: visible; }
.presence-pill { min-height: 38px; border: 1px solid var(--border); border-radius: 999px; background: var(--surface); display: inline-flex; align-items: center; gap: 6px; padding: 6px 11px; cursor: pointer; color: var(--muted); font-size: 11px; }
.presence-pill i, .online-person i { width: 8px; height: 8px; border-radius: 50%; background: var(--success); box-shadow: 0 0 0 4px color-mix(in srgb, var(--success) 12%, transparent); }
.presence-pill strong { color: var(--text); }
.topbar-language select { min-height:38px; max-width:110px; border:1px solid var(--border); border-radius:10px; background:var(--surface); color:var(--text); padding:0 26px 0 9px; font:600 11px/1 var(--font); }
.about-link { margin-bottom: 6px; }
.about-product { display: grid; grid-template-columns: 84px minmax(0,1fr); gap: 20px; align-items: start; }
.about-mark { width: 76px; height: 76px; display: grid; place-items: center; border-radius: 22px; color: white; background: linear-gradient(145deg,var(--primary),var(--accent)); font-size: 25px; font-weight: 850; }
.about-product h3 { font-size: 25px; margin: 0 0 4px; }.about-product p { color: var(--muted); }
.about-product dl { display: grid; gap: 7px; }.about-product dl div { display: grid; grid-template-columns: 110px 1fr; gap: 10px; }.about-product dt { color: var(--muted); }.about-product dd { margin: 0; font-weight: 700; }
.identity-lock { display: flex; align-items: center; gap: 16px; border: 1px solid color-mix(in srgb,var(--primary) 24%,var(--border)); border-radius: var(--radius); background: linear-gradient(135deg,color-mix(in srgb,var(--primary) 7%,white),var(--surface)); padding: 18px; }.identity-lock h2,.identity-lock p { margin: 0; }.identity-lock small { color: var(--primary); text-transform: uppercase; font-weight: 800; letter-spacing: .09em; }.identity-lock p { color: var(--muted); margin-top: 3px; }
.account-controls { border: 1px solid var(--border); border-radius: 13px; padding: 16px; background: color-mix(in srgb,var(--primary) 3%,var(--surface)); }.account-controls h3 { margin: 0 0 13px; }.account-controls > .field { margin-top: 15px; }
.permission-stack { margin-top: 18px; }
.online-strip { display: flex; align-items: center; gap: 9px; overflow-x: auto; margin: -7px 0 13px; padding: 9px 3px; }.online-strip > strong { white-space: nowrap; }.online-person { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; border: 1px solid var(--border); border-radius: 999px; padding: 6px 10px; background: var(--surface); color: var(--muted); font-size: 11px; }.online-person:not(.active) i { background: #a7b1ac; box-shadow: none; }
.chat-file { width: 43px; height: 43px; flex: none; border: 1px solid var(--border); border-radius: 11px; display: grid; place-items: center; cursor: pointer; background: var(--surface); color: var(--primary); }.chat-file input { position: absolute; opacity: 0; pointer-events: none; }.chat-file .ui-icon { width: 20px; }
.message-attachment { display: grid; gap: 7px; margin-top: 8px; }.message-attachment img { width: min(320px,100%); max-height: 260px; object-fit: cover; border-radius: 10px; }.message-attachment a { color: var(--primary); font-weight: 750; text-decoration: none; }.message-attachment .ui-icon { width: 28px; height: 28px; }.chat-head small { color: var(--success); }
.letterhead-preview { width: min(760px,100%); min-height: 860px; margin: auto; background: white; color: #111; border: 1px solid #bcc5c1; padding: 34px 38px 24px; display: grid; grid-template-rows: auto 1fr auto; font-family: Georgia, 'Times New Roman', serif; }.letterhead-preview header { border-bottom: 2px solid #4b5652; padding-bottom: 14px; }.letterhead-preview header > h1 { text-align: center; font-size: 23px; letter-spacing: .035em; margin: 0; }.letterhead-preview header > h2 { text-align: center; font-size: 17px; font-weight: 700; margin: 2px 0 10px; }.letterhead-identity { display: grid; grid-template-columns: 92px 1.2fr 1.05fr 92px; gap: 12px; align-items: center; }.letterhead-logo { height: 84px; display: grid; place-items: center; border: 1px dashed #aeb7b3; color: #7b8581; font: 10px Aptos,Arial,sans-serif; }.letterhead-logo img { max-height: 82px; }.letterhead-identity address,.letterhead-identity section { font-style: normal; font-size: 12px; line-height: 1.4; }.letterhead-identity section { text-align: center; }.letterhead-identity.layout-contacts_logo_identity_logo > address { order:1; }.letterhead-identity.layout-contacts_logo_identity_logo > .letterhead-logo:first-child { order:2; }.letterhead-identity.layout-contacts_logo_identity_logo > section { order:3; }.letterhead-identity.layout-contacts_logo_identity_logo > .letterhead-logo:last-child { order:4; }.letterhead-identity.layout-logo_identity_contacts_logo > .letterhead-logo:first-child { order:1; }.letterhead-identity.layout-logo_identity_contacts_logo > section { order:2; }.letterhead-identity.layout-logo_identity_contacts_logo > address { order:3; }.letterhead-identity.layout-logo_identity_contacts_logo > .letterhead-logo:last-child { order:4; }.letterhead-preview main { padding: 42px 45px; text-align: center; }.letterhead-preview main h2 { font-size: 19px; letter-spacing: .08em; }.letterhead-preview footer { border-top: 1px solid #4b5652; padding-top: 7px; text-align: center; font-size: 10px; }
.letterhead-preview header > h2.facility-title { font-weight:800; font-size:24px; letter-spacing:.025em; text-transform:uppercase; }
.organisation-line { text-align:center; margin:0 0 10px; font-size:12px; }
.page-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 18px; margin-bottom: 24px; }
.page-header h1 { margin: 0; font-size: clamp(25px, 3.2vw, 38px); line-height: 1.05; letter-spacing: -.045em; }
.page-header p { margin: 7px 0 0; color: var(--muted); max-width: 780px; }
.page-actions { display: flex; flex-wrap: wrap; gap: 9px; justify-content: flex-end; }
.mobile-overlay { display: none; }

/* Content */
.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 24px; }
.stat-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: 0 7px 24px rgba(20, 54, 42, .05); position: relative; overflow: hidden; }
.stat-card::after { content: ""; position: absolute; width: 82px; height: 82px; border-radius: 50%; right: -30px; top: -30px; background: var(--card-colour, var(--primary)); opacity: .1; }
.stat-card span { color: var(--muted); font-size: 12px; font-weight: 740; text-transform: uppercase; letter-spacing: .06em; }
.stat-card strong { display: block; font-size: 32px; letter-spacing: -.04em; margin-top: 8px; }
.tone-gold { --card-colour: #b77f08; } .tone-blue { --card-colour: #2167ae; } .tone-green { --card-colour: #138250; } .tone-red { --card-colour: #ba382e; } .tone-purple { --card-colour: #6f4eb0; }
.dashboard-hero { position: relative; overflow: hidden; border-radius: calc(var(--radius) + 8px); padding: clamp(20px, 3vw, 32px); margin-bottom: 18px; color: #fff; background: linear-gradient(125deg, #063b33 0%, var(--primary) 45%, color-mix(in srgb, var(--accent) 72%, #6944dc) 100%); box-shadow: 0 24px 60px color-mix(in srgb, var(--primary) 26%, transparent); }
.dashboard-hero::before, .dashboard-hero::after { content: ""; position: absolute; border-radius: 50%; pointer-events: none; }
.dashboard-hero::before { width: 260px; height: 260px; right: -70px; top: -130px; border: 42px solid rgba(255,255,255,.08); }
.dashboard-hero::after { width: 120px; height: 120px; right: 19%; bottom: -80px; background: color-mix(in srgb, var(--secondary) 50%, transparent); filter: blur(4px); }
.dashboard-hero .page-header { position: relative; z-index: 1; margin: 0; }
.dashboard-hero .page-header p { color: rgba(255,255,255,.76); }
.dashboard-stats { perspective: 1200px; }
.dashboard-stats .stat-card { min-height: 130px; border: 0; color: #fff; background: linear-gradient(145deg, color-mix(in srgb, var(--card-colour, var(--primary)) 88%, #fff), color-mix(in srgb, var(--card-colour, var(--primary)) 78%, #111)); box-shadow: 0 17px 30px color-mix(in srgb, var(--card-colour, var(--primary)) 24%, transparent), inset 0 1px 0 rgba(255,255,255,.3); transform: rotateX(2deg); animation: dashboardRise .45s ease both; animation-delay: var(--delay); }
.dashboard-stats .stat-card::before { content: ""; position: absolute; inset: auto 8% -22px 8%; height: 36px; border-radius: 50%; background: rgba(0,0,0,.25); filter: blur(18px); z-index: -1; }
.dashboard-stats .stat-card span { color: rgba(255,255,255,.8); }
.dashboard-stats .stat-card strong { font-size: clamp(31px, 4vw, 46px); text-shadow: 0 4px 12px rgba(0,0,0,.2); }
.stat-orbit { position: absolute; width: 86px; height: 86px; right: -9px; bottom: -14px; border: 13px solid rgba(255,255,255,.12); border-radius: 50%; box-shadow: inset 0 0 0 8px rgba(255,255,255,.05); }
@keyframes dashboardRise { from { opacity: 0; transform: translateY(15px) rotateX(6deg); } }
.dashboard-charts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin: 0 0 24px; perspective: 1400px; }
.chart-card { --scheme: var(--primary); position: relative; min-height: 360px; overflow: hidden; padding: 20px; border: 1px solid color-mix(in srgb, var(--scheme) 22%, var(--border)); border-radius: calc(var(--radius) + 4px); background: linear-gradient(155deg, color-mix(in srgb, var(--scheme) 8%, var(--surface)), var(--surface) 60%); box-shadow: 0 18px 38px color-mix(in srgb, var(--scheme) 13%, transparent), inset 0 1px 0 rgba(255,255,255,.8); transform-style: preserve-3d; transition: transform .2s ease, box-shadow .2s ease; }
.chart-card:hover { transform: translateY(-4px) rotateX(1deg); box-shadow: 0 25px 55px color-mix(in srgb, var(--scheme) 18%, transparent); }
.chart-card::after { content: ""; position: absolute; width: 170px; height: 170px; right: -80px; top: -90px; border-radius: 50%; background: color-mix(in srgb, var(--scheme) 12%, transparent); box-shadow: 0 0 0 26px color-mix(in srgb, var(--scheme) 5%, transparent); }
.chart-card > header { position: relative; z-index: 1; display: flex; align-items: flex-start; justify-content: space-between; gap: 15px; }
.chart-card > header small { color: var(--scheme); font-weight: 850; text-transform: uppercase; letter-spacing: .11em; }
.chart-card > header h2 { margin: 4px 0 0; font-size: 20px; letter-spacing: -.025em; }
.chart-card > header svg { width: 28px; height: 28px; color: var(--scheme); }
.scheme-emerald { --scheme: #079669; } .scheme-violet { --scheme: #6d4add; } .scheme-coral { --scheme: #ec5b68; } .scheme-cyan { --scheme: #0397bd; } .scheme-gold { --scheme: #dd9200; } .scheme-blue { --scheme: #2d6cdf; } .scheme-pink { --scheme: #d13f8c; } .scheme-teal { --scheme: #008e8b; } .scheme-indigo { --scheme: #4646c6; } .scheme-spectrum { --scheme: #7747b8; }
.chart-visual { height: 195px; display: grid; place-items: center; margin: 18px 0 12px; color: var(--scheme); }
.donut-chart { position: relative; width: 174px; aspect-ratio: 1; display: grid; place-items: center; border-radius: 50%; background: conic-gradient(var(--segments)); box-shadow: 0 18px 28px color-mix(in srgb, var(--scheme) 22%, transparent), inset -9px -10px 16px rgba(0,0,0,.12), inset 8px 8px 14px rgba(255,255,255,.36); transform: rotateX(6deg); }
.donut-chart::before { content: ""; position: absolute; inset: 30px; border-radius: 50%; background: linear-gradient(145deg, #fff, color-mix(in srgb, var(--scheme) 6%, #fff)); box-shadow: inset 0 3px 8px rgba(0,0,0,.08); }
.donut-chart > div { position: relative; z-index: 1; text-align: center; color: var(--text); }
.donut-chart strong, .donut-chart small { display: block; }
.donut-chart strong { font-size: 30px; letter-spacing: -.04em; }
.donut-chart small { color: var(--muted); }
.bar-chart { width: 100%; height: 100%; display: flex; align-items: end; justify-content: space-around; gap: 8px; border-bottom: 1px solid var(--border); padding: 14px 8px 0; background: repeating-linear-gradient(to top, transparent 0 39px, color-mix(in srgb, var(--muted) 10%, transparent) 40px); }
.bar-column { height: 100%; flex: 1; min-width: 0; display: grid; grid-template-rows: minmax(0,1fr) 26px; align-items: end; text-align: center; }
.bar-column > span { position: relative; width: min(36px, 72%); justify-self: center; border-radius: 9px 9px 3px 3px; background: linear-gradient(90deg, color-mix(in srgb, var(--bar) 72%, #111), var(--bar) 52%, color-mix(in srgb, var(--bar) 70%, white)); box-shadow: 8px 7px 14px color-mix(in srgb, var(--bar) 20%, transparent), inset 2px 0 0 rgba(255,255,255,.25); transition: height .35s ease; }
.bar-column > span::after { content: ""; position: absolute; left: 4px; right: -5px; top: -6px; height: 8px; transform: skewX(-34deg); border-radius: 4px; background: color-mix(in srgb, var(--bar) 68%, white); }
.bar-column b { position: absolute; left: 50%; top: -22px; transform: translateX(-50%); font-size: 10px; color: var(--text); }
.bar-column small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font-size: 9px; }
.line-chart { width: 100%; height: 100%; overflow: visible; filter: drop-shadow(0 9px 9px color-mix(in srgb, var(--scheme) 22%, transparent)); }
.chart-legend { min-height: 50px; display: flex; flex-wrap: wrap; gap: 8px 14px; align-content: start; }
.chart-legend span { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 11px; }
.chart-legend i { width: 9px; height: 9px; border-radius: 3px; background: var(--dot); box-shadow: 1px 2px 4px color-mix(in srgb, var(--dot) 30%, transparent); }
.chart-legend b { color: var(--text); }
.dashboard-lists { margin-top: 4px; }
.content-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(300px, .75fr); gap: 20px; }
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 7px 25px rgba(20,54,42,.045); overflow: hidden; }
.panel-header { min-height: 61px; padding: 14px 18px; display: flex; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--border); }
.panel-header h2, .panel-header h3 { margin: 0; font-size: 16px; }
.panel-body { padding: 18px; }
.stack { display: grid; gap: 14px; }
.list-item { display: flex; align-items: flex-start; justify-content: space-between; gap: 15px; padding: 14px 0; border-bottom: 1px solid var(--border); }
.list-item:first-child { padding-top: 0; }
.list-item:last-child { border-bottom: 0; padding-bottom: 0; }
.list-item h3, .list-item h4 { margin: 0; font-size: 14px; }
.list-item p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.list-item small { color: var(--muted); }
.empty-state { min-height: 220px; display: grid; place-content: center; justify-items: center; text-align: center; padding: 30px; color: var(--muted); }
.empty-state strong { color: var(--text); font-size: 17px; }
.empty-state p { max-width: 420px; margin: 7px 0 0; }
.badge { display: inline-flex; align-items: center; min-height: 25px; padding: 3px 9px; border-radius: 999px; font-size: 11px; font-weight: 780; background: color-mix(in srgb, var(--muted) 11%, var(--surface)); color: var(--muted); text-transform: capitalize; white-space: nowrap; }
.badge-approved, .badge-completed, .badge-active, .badge-published, .badge-resolved, .badge-verified { background: color-mix(in srgb, var(--success) 11%, white); color: var(--success); }
.badge-rejected, .badge-withdrawn, .badge-critical, .badge-locked { background: color-mix(in srgb, var(--danger) 10%, white); color: var(--danger); }
.badge-returned, .badge-draft, .badge-high { background: color-mix(in srgb, var(--secondary) 18%, white); color: color-mix(in srgb, var(--secondary) 76%, black); }
.badge-submitted, .badge-under_review, .badge-scheduled, .badge-open, .badge-in_progress { background: #edf4ff; color: #215f9c; }
.cards-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 17px; }
.record-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 19px; display: grid; align-content: start; gap: 13px; min-width: 0; transition: transform .15s, box-shadow .15s; }
.record-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.record-card h3 { margin: 0; font-size: 17px; letter-spacing: -.02em; }
.record-card p { margin: 0; color: var(--muted); font-size: 13px; }
.record-card-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; color: var(--muted); font-size: 12px; }
.record-sequence{display:inline-grid;place-items:center;min-width:25px;height:25px;padding:0 7px;border-radius:999px;background:color-mix(in srgb,var(--primary) 11%,var(--surface));color:var(--primary);font-size:10px;font-weight:900;font-variant-numeric:tabular-nums}
.record-card-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: 5px; }
.filter-bar { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 13px; display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 18px; }
.filter-bar input, .filter-bar select { min-height: 40px; border: 1px solid var(--border); border-radius: 9px; padding: 8px 11px; background: var(--surface); }
.table-wrap { position:relative; overflow:auto; border:1px solid var(--border); border-radius:var(--radius); background:var(--surface); isolation:isolate; }
.data-table { width: 100%; border-collapse: collapse; min-width: 720px; }
.data-table th { padding: 11px 13px; background: color-mix(in srgb, var(--primary) 4%, var(--surface)); border-bottom: 1px solid var(--border); color: var(--muted); font-size: 11px; letter-spacing: .05em; text-transform: uppercase; text-align: left; white-space: nowrap; }
.data-table td { position:relative; padding:13px; border-bottom:1px solid var(--border); vertical-align:top; line-height:1.42; font-size:13px; }
.data-table tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover { background: color-mix(in srgb, var(--primary) 2.5%, var(--surface)); }
.table-actions { display: flex; gap: 6px; flex-wrap: wrap; }

/* Dynamic forms */
.form-shell { max-width: 1050px; margin: auto; }
.form-banner { background: linear-gradient(125deg, var(--primary), color-mix(in srgb, var(--primary) 70%, var(--accent))); color: white; padding: clamp(22px, 4vw, 35px); border-radius: var(--radius); margin-bottom: 18px; position: relative; overflow: hidden; }
.form-banner::after { content: ""; position: absolute; width: 230px; height: 230px; right: -80px; top: -110px; border-radius: 50%; border: 36px solid rgba(255,255,255,.08); }
.form-banner h1 { margin: 0; font-size: clamp(24px, 4vw, 36px); letter-spacing: -.04em; }
.form-banner p { margin: 7px 0 0; opacity: .78; max-width: 700px; }
.form-code { display: inline-flex; margin-bottom: 9px; background: rgba(255,255,255,.13); border-radius: 8px; padding: 4px 8px; font-size: 11px; font-weight: 780; letter-spacing: .05em; }
.instruction-list { padding: 14px 18px; margin: 0 0 18px; background: color-mix(in srgb, var(--secondary) 10%, var(--surface)); border: 1px solid color-mix(in srgb, var(--secondary) 28%, var(--border)); border-radius: var(--radius); color: color-mix(in srgb, var(--text) 86%, var(--secondary)); }
.instruction-list li + li { margin-top: 5px; }
.dynamic-form { display: grid; gap: 18px; }
.form-section { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.form-section-heading { padding: 17px 20px; border-bottom: 1px solid var(--border); background: color-mix(in srgb, var(--primary) 2.8%, var(--surface)); }
.form-section-heading h2 { margin: 0; font-size: 17px; }
.form-section-heading p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.form-section-body { padding: 20px; }
.form-footer { position: sticky; bottom: 0; z-index: 10; background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(15px); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px; display: flex; justify-content: space-between; align-items: center; gap: 12px; box-shadow: 0 -8px 25px rgba(20,54,42,.07); }
.save-state { color: var(--muted); font-size: 12px; }
.form-table { border: 1px solid var(--border); border-radius: 10px; overflow-x: auto; }
.form-table table { min-width: 660px; width: 100%; border-collapse: collapse; }
.form-table th { padding: 9px; font-size: 11px; color: var(--muted); background: var(--background); text-align: left; }
.form-table td { padding: 7px; border-top: 1px solid var(--border); vertical-align: top; }
.form-table input, .form-table textarea, .form-table select { width: 100%; min-height: 38px; padding: 7px 8px; border: 1px solid var(--border); border-radius: 7px; background: var(--surface); }
.form-table textarea { min-height: 62px; resize: vertical; }
.table-remove { border: 0; background: color-mix(in srgb, var(--danger) 9%, white); color: var(--danger); border-radius: 7px; height: 35px; width: 35px; cursor: pointer; }
.upload-box { border: 1px dashed color-mix(in srgb, var(--primary) 35%, var(--border)); border-radius: 10px; padding: 13px; background: color-mix(in srgb, var(--primary) 2%, var(--surface)); }
.upload-status { color: var(--muted); font-size: 12px; margin-top: 6px; }
.timeline { display: grid; gap: 0; }
.timeline-item { position: relative; padding: 0 0 20px 32px; }
.timeline-item::before { content: ""; position: absolute; left: 9px; top: 18px; bottom: 0; border-left: 2px solid var(--border); }
.timeline-item:last-child::before { display: none; }
.timeline-dot { position: absolute; left: 2px; top: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--surface); border: 4px solid var(--primary); }
.timeline-item h4 { margin: 0; }
.timeline-item p { margin: 4px 0; color: var(--muted); }

/* Builders and administration */
.admin-tabs { display: flex; gap: 5px; overflow-x: auto; padding: 5px; background: color-mix(in srgb, var(--muted) 7%, var(--surface)); border-radius: 12px; margin-bottom: 18px; }
.admin-tab { border: 0; background: transparent; min-height: 38px; padding: 7px 13px; white-space: nowrap; border-radius: 9px; cursor: pointer; color: var(--muted); font-weight: 680; }
.admin-tab.active { background: var(--surface); color: var(--primary); box-shadow: 0 3px 12px rgba(0,0,0,.06); }
.builder-layout { display: grid; grid-template-columns: minmax(0, 1fr) 270px; gap: 18px; }
.builder-canvas { display: grid; gap: 15px; }
.builder-section { border: 1px solid var(--border); border-radius: 12px; background: var(--surface); padding: 14px; }
.builder-section-head { display: flex; gap: 8px; align-items: center; margin-bottom: 11px; }
.builder-section-head input { min-width: 0; flex: 1; height: 40px; border: 1px solid var(--border); border-radius: 8px; padding: 8px; font-weight: 740; }
.builder-field { min-height: 54px; display: flex; justify-content: space-between; align-items: center; gap: 12px; border: 1px solid var(--border); border-radius: 9px; padding: 10px; margin-top: 8px; background: var(--background); }
.builder-field strong { display: block; font-size: 13px; }
.builder-field small { color: var(--muted); }
.builder-field-actions { display: flex; gap: 5px; }
.builder-tools { position: sticky; top: 92px; align-self: start; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 14px; }
.builder-tools h3 { margin: 0 0 12px; font-size: 14px; }
.field-type-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.field-type-button { border: 1px solid var(--border); background: var(--surface); border-radius: 8px; min-height: 38px; padding: 7px; cursor: pointer; text-align: left; font-size: 11px; font-weight: 680; }
.field-type-button:hover { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 5%, var(--surface)); }
.colour-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 14px; }
.colour-field { display: grid; gap: 7px; }
.colour-field input { width: 100%; min-height: 48px; border: 1px solid var(--border); padding: 3px; border-radius: 9px; background: var(--surface); }
.permission-group { border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.permission-group h3 { margin: 0; padding: 12px 14px; background: var(--background); font-size: 14px; }
.permission-options { padding: 12px 14px; display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 9px; }
.metric-bars { display: grid; gap: 12px; }
.metric-row { display: grid; grid-template-columns: 160px minmax(0,1fr) 45px; gap: 10px; align-items: center; }
.metric-track { height: 9px; border-radius: 99px; background: var(--background); overflow: hidden; }
.metric-fill { height: 100%; background: linear-gradient(90deg, var(--primary), var(--accent)); border-radius: 99px; }
.access-explainer, .decision-identity, .privacy-note { padding: 14px; border-radius: 12px; background: color-mix(in srgb, var(--accent) 7%, var(--surface)); border: 1px solid color-mix(in srgb, var(--accent) 22%, var(--border)); }
.decision-identity h3, .staff-onboarding h3 { margin: 0 0 5px; }
.decision-identity .permission-options { padding: 8px 0 0; }
.privacy-choice { padding: 15px; border-radius: 12px; background: color-mix(in srgb, var(--secondary) 12%, var(--surface)); border: 1px solid color-mix(in srgb, var(--secondary) 28%, var(--border)); }
.privacy-note { color: var(--muted); font-size: 12px; }
.staff-onboarding { margin-top: 6px; padding: 15px 0 4px; border-top: 1px solid var(--border); }
.staff-onboarding p { margin: 0; color: var(--muted); }
.readiness-meter { width: 130px; height: 8px; overflow: hidden; border-radius: 99px; background: color-mix(in srgb, var(--muted) 12%, var(--surface)); }
.readiness-meter span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--secondary), var(--success)); }
.library-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 18px; }
.library-card { position: relative; overflow: hidden; min-height: 235px; padding-top: 26px; }
.library-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 7px; background: linear-gradient(90deg, var(--primary), var(--accent), var(--secondary)); }
.rich-content { line-height: 1.65; }
.rich-content h2, .rich-content h3 { margin: 20px 0 8px; }
.roster-editor { display: grid; gap: 15px; }
.roster-entry-table { overflow-x: auto; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); }
.roster-entry-table table { width: 100%; min-width: 1520px; border-collapse: collapse; }
.roster-entry-table th { position: sticky; top: 0; z-index: 2; padding: 8px 5px; background: color-mix(in srgb, var(--primary) 7%, var(--surface)); border: 1px solid var(--border); font-size: 10px; text-align: center; }
.roster-entry-table td { padding: 5px; border: 1px solid var(--border); }
.roster-entry-table input, .roster-entry-table select { min-height: 34px; width: 100%; min-width: 42px; border: 1px solid var(--border); border-radius: 7px; padding: 5px; background: var(--surface); }
.roster-leave-range { display: grid; grid-template-columns: minmax(140px, 1fr) 138px 138px; gap: 5px; min-width: 430px; }
.report-summary { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px,1fr)); gap: 12px; margin-bottom: 18px; }
.report-summary article { padding: 16px; border-radius: 14px; color: #fff; background: linear-gradient(145deg, var(--primary), var(--accent)); box-shadow: 0 12px 24px color-mix(in srgb, var(--primary) 20%, transparent); }
.report-summary strong, .report-summary span { display: block; }
.report-summary strong { font-size: 30px; }
.survey-result { padding: 16px 0; border-top: 1px solid var(--border); }
.survey-result h3 { margin: 0 0 10px; font-size: 14px; }
.survey-average { color: var(--muted); }
.survey-comments blockquote { margin: 10px 0; padding: 12px 15px; border-left: 4px solid var(--secondary); border-radius: 0 10px 10px 0; background: var(--background); }
.survey-comments blockquote p { margin: 0; white-space: pre-wrap; }

/* Chat */
.chat-layout { height: calc(100vh - 140px); min-height: 520px; display: grid; grid-template-columns: 300px minmax(0,1fr); background: var(--chat-background, var(--surface)); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.thread-list { border-right: 1px solid var(--border); overflow-y: auto; }
.thread-list-head { padding: 14px; border-bottom: 1px solid var(--border); position: sticky; top: 0; background: var(--surface); }
.thread-item { position: relative; width: 100%; border: 0; border-bottom: 1px solid var(--border); background: var(--thread-background, transparent); padding: 13px 44px 13px 13px; text-align: left; cursor: pointer; }
.thread-item.unread strong { font-weight: 800; }
.chat-unread-count { position: absolute; right: 13px; top: 50%; transform: translateY(-50%); display: grid; place-items: center; min-width: 23px; height: 23px; padding: 0 6px; border-radius: 999px; background: var(--primary); color: #fff; font-size: 11px; font-weight: 800; }
.thread-item.active, .thread-item:hover { background: color-mix(in srgb, var(--primary) 5%, var(--surface)); }
.thread-item strong, .thread-item small { display: block; }
.thread-item small { color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 4px; }
.chat-pane { display: grid; grid-template-rows: auto minmax(0,1fr) auto; min-width: 0; background: color-mix(in srgb, var(--chat-background, var(--surface)) 86%, white); }
.chat-head { padding: 14px 17px; border-bottom: 1px solid var(--border); background: var(--surface); }
.chat-head h2 { margin: 0; font-size: 16px; }
.message-list { overflow-y: auto; padding: 18px; display: flex; flex-direction: column; gap: 10px; }
.message { max-width: min(70%, 560px); background: var(--message-background, var(--background)); border: 1px solid color-mix(in srgb, var(--text) 12%, transparent); border-radius: 13px 13px 13px 3px; padding: 10px 12px; align-self: flex-start; }
.message.own { align-self: flex-end; background: var(--message-background, color-mix(in srgb, var(--primary) 12%, white)); border-radius: 13px 13px 3px 13px; }
.message strong { display: block; font-size: 11px; color: var(--primary); margin-bottom: 3px; }
.message p { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.message time { display: block; color: var(--muted); font-size: 9px; text-align: right; margin-top: 5px; }
.chat-compose { padding: 12px; display: flex; gap: 8px; border-top: 1px solid var(--border); }
.chat-compose textarea { flex: 1; resize: none; min-height: 43px; max-height: 110px; border: 1px solid var(--border); border-radius: 11px; padding: 10px; }

/* Modal and toast */
.modal-backdrop { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 18px; background: rgba(8, 22, 17, .62); backdrop-filter: blur(4px); }
.modal { width: min(720px, 100%); max-height: min(880px, calc(100vh - 36px)); background: var(--surface); border-radius: 18px; box-shadow: 0 30px 90px rgba(0,0,0,.28); overflow: hidden; display: grid; grid-template-rows: auto minmax(0,1fr) auto; }
.modal-wide { width: min(1050px, 100%); }
.modal-head { padding: 17px 20px; display: flex; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--border); }
.modal-head h2 { margin: 0; font-size: 19px; }
.modal-close { border: 0; background: var(--background); border-radius: 9px; width: 36px; height: 36px; cursor: pointer; }
.modal-body { padding: 20px; overflow-y: auto; }
.modal-foot { padding: 13px 20px; border-top: 1px solid var(--border); display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 8px; }
.toast-region { position: fixed; z-index: 200; right: 20px; bottom: 20px; display: grid; gap: 9px; width: min(370px, calc(100% - 40px)); }
.toast { background: #10241d; color: white; padding: 13px 15px; border-radius: 12px; box-shadow: 0 18px 50px rgba(0,0,0,.24); animation: toastIn .2s ease-out; }
.toast.error { background: var(--danger); }
.toast.success { background: var(--success); }
@keyframes toastIn { from { transform: translateY(10px); opacity: 0; } }
.skeleton { background: linear-gradient(90deg, var(--background), color-mix(in srgb, var(--background) 40%, white), var(--background)); background-size: 200% 100%; animation: shimmer 1.2s infinite; border-radius: 8px; height: 18px; }
@keyframes shimmer { to { background-position: -200% 0; } }

.system-message { display: grid; place-content: center; padding: 20px; }
.system-message main { max-width: 560px; background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 30px; box-shadow: var(--shadow); }
.system-message h1 { margin: 18px 0 8px; }
.system-message p { color: var(--muted); }

/* Compliance, action plans, personal editor and device history */
.compliance-stats { margin-bottom: 18px; }
.credential-expired { background: color-mix(in srgb, var(--danger) 5%, var(--surface)); }
.credential-expiring { background: color-mix(in srgb, #e4a11b 7%, var(--surface)); }
.progress-line { height: 8px; overflow: hidden; border-radius: 99px; background: var(--background); margin: 13px 0; }
.progress-line.large { height: 13px; }
.progress-line > span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--primary), var(--accent), var(--secondary)); }
.progress-ring { --progress: 0; width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle closest-side, var(--surface) 72%, transparent 73% 99%), conic-gradient(var(--primary) calc(var(--progress) * 1%), var(--background) 0); margin-bottom: 7px; }
.progress-ring strong { font-size: 11px; }
.word-workspace { display: grid; grid-template-columns: 250px minmax(0,1fr); min-height: 720px; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: #e9edf2; box-shadow: var(--shadow); }
.document-library { background: var(--surface); border-right: 1px solid var(--border); overflow-y: auto; }
.document-library > header { display: grid; gap: 3px; padding: 17px; border-bottom: 1px solid var(--border); }
.document-library > header small, .document-list-item span, .document-list-item small { color: var(--muted); }
.document-list-item { width: 100%; border: 0; border-bottom: 1px solid var(--border); background: transparent; text-align: left; padding: 14px 16px; cursor: pointer; display: grid; gap: 5px; }
.document-list-item:hover, .document-list-item.active { background: color-mix(in srgb, var(--primary) 7%, var(--surface)); }
.document-list-item.active { box-shadow: inset 4px 0 var(--primary); }
.word-editor-shell { min-width: 0; display: grid; grid-template-rows: auto auto minmax(0,1fr) auto; }
.editor-toolbar { display: flex; flex-wrap: wrap; gap: 5px; padding: 10px; background: var(--surface); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 2; }
.editor-toolbar button { min-width: 34px; height: 34px; padding: 0 9px; border: 1px solid var(--border); border-radius: 7px; background: var(--surface); color: var(--text); cursor: pointer; }
.editor-toolbar button:hover { border-color: var(--primary); color: var(--primary); }
.document-meta { display: flex; flex-wrap: wrap; gap: 8px; padding: 10px; background: var(--surface); border-bottom: 1px solid var(--border); }
.document-meta > input { flex: 1; min-width: 200px; font-weight: 700; font-size: 16px; }
.document-meta > input, .document-meta > select { border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; background: var(--surface); color: var(--text); }
.word-paper { width: min(210mm, calc(100% - 42px)); min-height: 297mm; margin: 22px auto; background: white; color: #111; box-shadow: 0 5px 26px rgba(24,38,32,.14); padding: 22mm 20mm; outline: 0; font: 11pt/1.5 Aptos, Calibri, Arial, sans-serif; overflow-wrap: anywhere; }
.word-paper:focus { box-shadow: 0 5px 30px rgba(7,95,79,.22); }
.word-paper table { width: 100%; border-collapse: collapse; }
.word-paper td, .word-paper th { border: 1px solid #777; padding: 6px; }
.editor-status { display: flex; justify-content: space-between; gap: 12px; padding: 8px 14px; background: var(--surface); border-top: 1px solid var(--border); color: var(--muted); font-size: 11px; }
.device-list { display: grid; }
.device-row { display: grid; grid-template-columns: 58px minmax(0,1fr) auto; gap: 15px; align-items: center; padding: 20px 24px; border-bottom: 1px solid var(--border); }
.device-row:last-child { border-bottom: 0; }
.device-icon { width: 50px; height: 50px; border-radius: 14px; display: grid; place-items: center; background: color-mix(in srgb, var(--success) 9%, white); color: var(--success); }
.device-icon .ui-icon { width: 26px; height: 26px; }
.device-row h3, .device-row p { margin: 0 0 5px; }
.device-row p, .device-row small { color: var(--muted); overflow-wrap: anywhere; }
.device-row > div:last-child { display: flex; flex-direction: column; align-items: flex-end; gap: 9px; }

@media (max-width: 1180px) {
  .stats-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .cards-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .colour-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .library-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
}

@media (max-width: 900px) {
  .login-shell { grid-template-columns: 1fr; max-width: 520px; }
  .login-brand { text-align: center; margin: auto; }
  .login-brand h1 { font-size: clamp(33px, 10vw, 50px); }
  .app-shell { display: block; height: auto; min-height: 100vh; overflow: visible; }
  .sidebar { transform: translateX(-102%); transition: transform .22s ease; box-shadow: 20px 0 55px rgba(0,0,0,.2); }
  .sidebar.open { transform: translateX(0); }
  .mobile-overlay.open { display: block; position: fixed; inset: 0; z-index: 35; background: rgba(6,18,13,.5); }
  .app-main { min-height: 100vh; height: auto; overflow: visible; display: block; }
  .menu-toggle { display: block; }
  .mobile-brand { display:flex; }
  .dashboard-filter { position:static; grid-template-columns:repeat(2,minmax(0,1fr)); }
  .roles-workspace { grid-template-columns:1fr; }
  .roles-workspace > .panel:first-child { position:static; }
  .dashboard-search-field { grid-column:1 / -1; }
  .content-grid { grid-template-columns: 1fr; }
  .builder-layout { grid-template-columns: 1fr; }
  .builder-tools { position: static; }
  .permission-options { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .dashboard-charts { grid-template-columns: 1fr; }
  .word-workspace { grid-template-columns: 1fr; }
  .document-library { border-right: 0; border-bottom: 1px solid var(--border); max-height: 240px; }
}

@media (max-width: 650px) {
  .form-grid, .cards-grid, .colour-grid, .library-grid { grid-template-columns: 1fr; }
  .form-grid .span-2 { grid-column: auto; }
  .stats-grid { grid-template-columns: repeat(2, minmax(0,1fr)); gap: 10px; }
  .stat-card { padding: 15px; }
  .stat-card strong { font-size: 26px; }
  .page-header { display: grid; }
  .page-actions { justify-content: flex-start; }
  .topbar { padding: 0 11px; gap: 8px; }
  .topbar { height:auto; min-height:72px; flex-wrap:wrap; padding-top:8px; padding-bottom:8px; }
  .app-main { grid-template-rows:auto 1fr; }
  .mobile-brand strong { max-width:68px; overflow:hidden; text-overflow:ellipsis; }
  .topbar-language { display:none; }
  .page-context { display: none; }
  .global-search { width:100%; order:20; flex:1 0 100%; margin-left:0; }
  .global-search.is-collapsed { width:42px; flex:0 0 42px; order:0; margin-left:auto; }
  .history-button { display:none; }
  .content { padding: 16px 12px 28px; }
  .panel-body, .form-section-body { padding: 14px; }
  .form-footer { flex-wrap: wrap; }
  .form-footer .page-actions { width: 100%; }
  .form-footer .btn { flex: 1; }
  .install-shell { margin-top: 18px; }
  .login-shell { width: min(100% - 22px, 500px); padding: 24px 0; }
  .login-brand p { margin-top: 14px; }
  .login-brand > span:last-child { font-size: 15px; }
  .login-card { padding: 22px 18px; border-radius: 18px; }
  .chat-layout { grid-template-columns: 1fr; height: calc(100vh - 110px); }
  .thread-list { border-right: 0; }
  .chat-pane { display: none; }
  .chat-layout.thread-open .thread-list { display: none; }
  .chat-layout.thread-open .chat-pane { display: grid; }
  .message { max-width: 86%; }
  .permission-options { grid-template-columns: 1fr; }
  .metric-row { grid-template-columns: 110px minmax(0,1fr) 35px; }
  .chart-card { min-height: 330px; padding: 16px; }
  .dashboard-filter { grid-template-columns:1fr 1fr; }
  .dashboard-filter .field:nth-child(3),.dashboard-search-field { grid-column:1 / -1; }
  .dashboard-filter .btn { min-width:0; }
  .union-kpis { grid-template-columns:1fr; }
  .chart-visual { height: 175px; }
  .device-row { grid-template-columns: 44px minmax(0,1fr); padding: 16px; }
  .device-row > div:last-child { grid-column: 2; align-items: flex-start; }
  .word-paper { width: calc(100% - 20px); min-height: 800px; margin: 10px auto; padding: 32px 24px; }
  .editor-status { flex-wrap: wrap; }
}

@media print {
  .sidebar, .topbar, .page-actions, .form-footer, .filter-bar { display: none !important; }
  .app-main { display: block; }
  .content { padding: 0; max-width: none; }
  .panel, .form-section { break-inside: avoid; box-shadow: none; }
}

/* RichFlow 6.1 RichMail workspace */
.gmail-shell{display:grid;grid-template-columns:220px minmax(0,1fr);min-height:620px;border:1px solid var(--border);border-radius:22px;overflow:hidden;background:var(--surface);box-shadow:0 16px 42px rgba(12,39,31,.08)}
.gmail-folders{display:flex;flex-direction:column;gap:16px;padding:18px 12px;background:color-mix(in srgb,var(--background) 65%,var(--surface));border-right:1px solid var(--border)}
.gmail-compose{display:flex;align-items:center;gap:12px;width:max-content;min-width:148px;padding:15px 20px;border:0;border-radius:18px;background:color-mix(in srgb,var(--primary) 12%,#fff);color:var(--primary);font-weight:850;box-shadow:0 5px 16px rgba(12,39,31,.10);cursor:pointer}.gmail-compose .ui-icon{width:22px;height:22px}
.gmail-folders nav{display:grid;gap:3px}.gmail-folder{display:grid;grid-template-columns:25px minmax(0,1fr) auto;gap:11px;align-items:center;width:100%;padding:10px 13px;border:0;border-radius:0 18px 18px 0;background:transparent;color:var(--text);text-align:left;font-weight:700;cursor:pointer}.gmail-folder:hover{background:color-mix(in srgb,var(--primary) 7%,transparent)}.gmail-folder.active{background:color-mix(in srgb,var(--primary) 14%,var(--surface));color:var(--primary);font-weight:900}.gmail-folder b{font-size:11px}.gmail-folder .ui-icon{width:20px;height:20px}
.gmail-sync-note{display:flex;align-items:center;gap:8px;margin-top:auto;padding:11px;color:var(--muted);font-size:11px;line-height:1.4}.gmail-sync-note .ui-icon{width:17px;height:17px;color:var(--success)}
.gmail-mailbox{min-width:0;background:var(--surface)}.gmail-toolbar{display:grid;grid-template-columns:42px minmax(220px,1fr) auto 36px 36px;gap:8px;align-items:center;padding:11px 14px;border-bottom:1px solid var(--border);position:sticky;top:0;background:color-mix(in srgb,var(--surface) 96%,transparent);z-index:2}.gmail-toolbar>span{font-size:12px;color:var(--muted);font-variant-numeric:tabular-nums}.icon-button{display:grid;place-items:center;width:36px;height:36px;border:0;border-radius:50%;background:transparent;color:var(--text);font-size:22px;cursor:pointer}.icon-button:hover{background:var(--background)}.icon-button:disabled{opacity:.35;cursor:not-allowed}.gmail-search{display:flex;align-items:center;gap:9px;max-width:620px;padding:0 14px;border-radius:22px;background:var(--background)}.gmail-search input{width:100%;height:40px;border:0;outline:0;background:transparent;color:var(--text)}.gmail-search .ui-icon{width:18px;height:18px;color:var(--muted)}
.gmail-list{max-height:69vh;overflow:auto;scrollbar-gutter:stable}.gmail-row{display:grid;grid-template-columns:50px 30px minmax(145px,220px) minmax(220px,1fr) 155px;gap:8px;align-items:center;width:100%;min-height:52px;padding:7px 15px;border:0;border-bottom:1px solid var(--border);background:color-mix(in srgb,var(--background) 50%,var(--surface));color:var(--text);text-align:left;cursor:pointer}.gmail-row:hover{position:relative;z-index:1;box-shadow:0 2px 9px rgba(0,0,0,.14)}.gmail-row.unread{background:var(--surface)}.gmail-row.unread .gmail-party,.gmail-row.unread .gmail-subject b{font-weight:900}.gmail-record-no{font-size:11px;color:var(--muted);font-variant-numeric:tabular-nums}.gmail-state{color:var(--muted)}.gmail-state .ui-icon{width:17px;height:17px}.gmail-party,.gmail-subject{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.gmail-subject{display:flex;align-items:center;gap:9px}.gmail-subject b{overflow:hidden;text-overflow:ellipsis}.gmail-subject small{flex:0 0 auto;color:var(--muted)}.gmail-row time{justify-self:end;color:var(--muted);font-size:11px}
.gmail-message{display:grid;gap:20px;min-height:420px}.gmail-message>header{display:grid;grid-template-columns:44px minmax(0,1fr) auto;gap:12px;align-items:center;padding-bottom:15px;border-bottom:1px solid var(--border)}.gmail-message>header>div{display:grid;gap:4px;min-width:0}.gmail-message>header small{overflow-wrap:anywhere;color:var(--muted)}.gmail-message>header time{color:var(--muted);font-size:12px}.mail-avatar{display:grid;place-items:center;width:42px;height:42px;border-radius:50%;background:var(--primary);color:#fff;font-size:18px;font-weight:900}.gmail-message-body{min-height:250px;overflow-wrap:anywhere;line-height:1.65}.gmail-message-body table{max-width:100%;border-collapse:collapse}.gmail-message-body img{max-width:100%;height:auto}.mail-attachments{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:9px;padding-top:14px;border-top:1px solid var(--border)}.mail-attachments h4{grid-column:1/-1;margin:0}.mail-attachment{display:flex;align-items:center;gap:10px;padding:11px;border:1px solid var(--border);border-radius:12px;color:var(--text);text-decoration:none}.mail-attachment:hover{border-color:var(--primary)}.mail-attachment span{display:grid;min-width:0}.mail-attachment strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mail-attachment small{color:var(--muted)}
.gmail-compose-form{display:grid;gap:0}.gmail-address{display:grid}.gmail-address label{display:grid;grid-template-columns:42px minmax(0,1fr);align-items:center;min-height:43px;border-bottom:1px solid var(--border);color:var(--muted);font-size:12px}.gmail-address input,.gmail-subject-input{width:100%;height:43px;border:0;outline:0;background:transparent;color:var(--text)}.gmail-subject-input{border-bottom:1px solid var(--border);font-weight:750}.gmail-editor-toolbar{display:flex;flex-wrap:wrap;gap:4px;padding:8px;border-bottom:1px solid var(--border);background:var(--background)}.gmail-editor-toolbar button,.gmail-editor-toolbar select{min-height:32px;padding:5px 9px;border:1px solid var(--border);border-radius:7px;background:var(--surface);color:var(--text);cursor:pointer}.gmail-editor-toolbar input[type=color]{width:34px;height:32px;border:1px solid var(--border);border-radius:7px;background:var(--surface)}.gmail-editor{min-height:310px;max-height:46vh;padding:17px;overflow:auto;outline:0;line-height:1.6}.gmail-editor:empty::before{content:attr(data-placeholder);color:var(--muted)}.gmail-attach{display:flex;align-items:center;gap:8px;width:max-content;margin:8px;padding:9px 12px;border-radius:9px;color:var(--primary);font-weight:800;cursor:pointer}.gmail-attach:hover{background:color-mix(in srgb,var(--primary) 8%,transparent)}.gmail-attach input{position:absolute;opacity:0;pointer-events:none}.mail-selected-files{display:flex;flex-wrap:wrap;gap:7px;padding:0 9px}.mail-selected-files span{display:flex;align-items:center;gap:5px;padding:7px 9px;border-radius:8px;background:var(--background);font-size:11px}.mail-selected-files .ui-icon{width:15px;height:15px}.mail-draft-state{padding:9px;color:var(--muted);text-align:right}.richmail-compose-top{display:none}

@media(max-width:900px){.gmail-shell{grid-template-columns:76px minmax(0,1fr)}.gmail-folders{padding:12px 7px}.gmail-compose{min-width:0;width:54px;height:54px;padding:0;justify-content:center;border-radius:18px}.gmail-compose span,.gmail-folder span,.gmail-folder b,.gmail-sync-note span{display:none}.gmail-folder{grid-template-columns:1fr;justify-items:center;border-radius:14px;padding:11px}.gmail-row{grid-template-columns:38px 25px minmax(110px,170px) minmax(180px,1fr) 100px}.gmail-party{font-size:12px}}
@media(max-width:650px){.gmail-shell{display:block;border-radius:15px}.gmail-folders{display:none}.richmail-compose-top{display:flex}.gmail-toolbar{grid-template-columns:36px minmax(130px,1fr) 34px 34px}.gmail-toolbar>span{display:none}.gmail-row{grid-template-columns:34px minmax(0,1fr) 82px;min-height:68px}.gmail-state{display:none}.gmail-party{grid-column:2}.gmail-subject{grid-column:2}.gmail-row time{grid-column:3;grid-row:1}.gmail-record-no{grid-row:1/3}.gmail-message>header{grid-template-columns:40px minmax(0,1fr)}.gmail-message>header time{grid-column:2}.gmail-editor{min-height:260px}}
.install-checks{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.install-check{display:flex;align-items:center;gap:12px;border:1px solid var(--line,#d6e2dd);border-radius:12px;padding:12px 14px;background:#fff}
.install-check>span{display:grid;place-items:center;width:30px;height:30px;border-radius:50%;font-weight:800;flex:none}
.install-check div{display:grid;gap:2px}.install-check small{color:var(--muted,#65736d)}
.install-check.passed>span{background:#e5f5ec;color:#087443}.install-check.failed{border-color:#e8b4ae;background:#fff6f5}.install-check.failed>span{background:#fde5e2;color:#b42318}
.install-alert{display:grid;gap:4px}
@media(max-width:760px){.install-checks{grid-template-columns:1fr}}
.report-selector { margin-bottom:18px; }
.report-actions { justify-content:flex-end; }
.report-actions .page-actions { min-height:48px; align-items:center; }
.generated-report .panel-header { border-bottom:1px solid var(--border); }

/* RichFlow 3 protected identity and enterprise workspaces */
.developer-lockup { display:flex; align-items:center; gap:14px; }
.developer-lockup img,.login-card-brand img,.product-logo,.mobile-brand img,.about-brand-logo,.loading-brand-logo { object-fit:cover; background:#080808; }
.developer-lockup img { width:78px; height:78px; border-radius:22px; box-shadow:0 16px 36px rgba(0,0,0,.28); }
.developer-lockup strong,.developer-lockup small { display:block; }
.developer-lockup strong { color:#fff; font-size:clamp(30px,5vw,50px); line-height:1; letter-spacing:-.045em; }
.developer-lockup small { color:#f2c263; margin-top:6px; font-weight:800; letter-spacing:.08em; }
.login-card-brand { display:flex; align-items:center; gap:12px; padding-bottom:14px; border-bottom:1px solid var(--border); }
.login-card-brand img { width:54px; height:54px; border-radius:15px; }
.login-card-brand strong,.login-card-brand span { display:block; }
.login-card-brand strong { font-size:11px; letter-spacing:.08em; margin-top:3px; }
.product-logo { width:48px; height:48px; flex:none; border-radius:14px; box-shadow:0 7px 20px rgba(0,0,0,.22); }
.sidebar-developer { margin:0 8px 8px; color:#e9b95e; font-size:9px; font-weight:850; letter-spacing:.1em; }
.mobile-brand { display:none; align-items:center; gap:7px; white-space:nowrap; }
.mobile-brand img { width:34px; height:34px; border-radius:9px; }
.mobile-brand strong { font-size:14px; }
.about-brand-logo { width:76px; height:76px; border-radius:22px; }
.loading-brand-logo { width:86px; height:86px; border-radius:24px; box-shadow:var(--shadow); animation:pulse 1.2s ease-in-out infinite; }
.loading-brand-logo.loading-inline { width:54px; height:54px; border-radius:14px; object-fit:contain; }

/* RichFlow 6 document reliability and readable Info Hub calendars */
.hub-calendar-strip{display:grid!important;grid-template-columns:repeat(auto-fit,minmax(245px,1fr));gap:12px;overflow:auto;max-height:330px;padding:16px!important;align-items:stretch}
.hub-calendar-item{min-width:0!important;width:100%;display:grid!important;grid-template-columns:6px minmax(92px,auto) minmax(0,1fr);gap:12px;align-items:center;text-align:left;white-space:normal!important;overflow:hidden}
.hub-calendar-item time,.hub-calendar-item>span{min-width:0}.hub-calendar-item strong,.hub-calendar-item small{display:block;overflow-wrap:anywhere;word-break:normal;line-height:1.35}.hub-calendar-item time{font-variant-numeric:tabular-nums}.hub-calendar-item time span{display:block;margin-top:4px}
.document-frame{min-height:70vh;background:#fff}.print-document,.report-document{overflow:visible!important}.report-section{break-inside:avoid-page;margin:0 0 18px}.report-section table{width:100%;border-collapse:collapse}.report-section th,.report-section td{padding:9px 10px;vertical-align:top;line-height:1.4;overflow-wrap:anywhere}
@media print{.report-section{break-inside:auto}.report-section h2,.report-section thead{break-after:avoid-page}.report-section tr{break-inside:avoid-page}.document-body{overflow:visible!important;max-height:none!important}}
.richmail-shell{min-height:65vh}.mail-list{display:flex;flex-direction:column;padding:0!important}.mail-row{border:0;border-bottom:1px solid var(--border);background:transparent;padding:14px 18px;display:flex;justify-content:space-between;gap:18px;text-align:left;color:var(--text)}.mail-row:hover{background:color-mix(in srgb,var(--primary) 6%,transparent)}.mail-row>span{min-width:0}.mail-row strong,.mail-row small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mail-row.unread strong{font-weight:850}.mail-row time{flex:none;color:var(--muted);font-size:12px}.mail-message dl{display:grid;gap:5px}.mail-message dl div{display:grid;grid-template-columns:70px 1fr}.mail-message dt{font-weight:800}.mail-message{overflow-wrap:anywhere}
.app-loading strong { font-size:24px; letter-spacing:-.035em; color:var(--text); }

.letterhead-designer { display:grid; grid-template-columns:minmax(0,1fr) 310px; gap:20px; align-items:start; }
.letterhead-designer-canvas { position:relative; width:min(100%,620px); aspect-ratio:210/297; margin:auto; overflow:hidden; background:#fff; border:1px solid #b9c3bf; box-shadow:0 14px 36px rgba(19,39,32,.16); color:#101010; }
.letterhead-element { position:absolute; overflow:hidden; line-height:1.12; cursor:grab; user-select:none; padding:1px; }
.letterhead-element.selected { outline:2px solid var(--accent); outline-offset:2px; background:rgba(47,125,97,.08); }
.letterhead-element.kind-logo img { width:100%; height:100%; object-fit:contain; }
.letterhead-element.kind-rule { display:flex; align-items:center; }
.designer-rule { display:block; width:100%; border-top:1px solid #222; }
.letterhead-element.kind-watermark { color:rgba(110,110,110,.12); }
.letterhead-content-guide { position:absolute; left:3%; right:3%; z-index:90; border-top:1px dashed #db3a5b; color:#a11937; font:600 9px/1 var(--font); pointer-events:none; }
.letterhead-content-guide span { background:#fff; padding:2px 5px; }
.letterhead-tools { position:sticky; top:14px; display:grid; gap:12px; padding:16px; border:1px solid var(--border); border-radius:var(--radius); background:var(--surface); }
.letterhead-tools .form-grid.compact { grid-template-columns:1fr 1fr; gap:9px; }
.letterhead-preview.arranged { width:min(100%,660px); margin:auto; padding:0; border:0; }
.letterhead-preview.arranged .letterhead-designer-canvas { width:100%; }
.letterhead-preview-content { position:absolute; left:8%; right:8%; padding-top:12px; border-top:1px dotted #ccd3d0; text-align:center; }
.letterhead-preview.arranged footer { position:absolute; left:5%; right:5%; bottom:2%; padding-top:5px; border-top:1px solid #222; text-align:center; font:7px/1.2 Georgia,serif; }

@media (max-width:900px) { .letterhead-designer { grid-template-columns:1fr; } .letterhead-tools { position:static; } }
.dashboard-filter { position:sticky; top:10px; z-index:12; display:grid; grid-template-columns:repeat(3,minmax(150px,1fr)) minmax(210px,1.4fr) auto auto; gap:10px; align-items:end; margin:0 0 18px; padding:13px; border:1px solid var(--border); border-radius:15px; background:color-mix(in srgb,var(--surface) 94%,transparent); box-shadow:0 10px 28px rgba(15,43,33,.08); backdrop-filter:blur(16px); }
.dashboard-filter .field > span { font-size:10px; text-transform:uppercase; letter-spacing:.07em; color:var(--muted); }
.dashboard-tables { margin-top:20px; }
.dashboard-table .table-wrap { max-height:390px; }
.mini-table { width:100%; display:grid; align-self:stretch; align-content:center; }
.mini-table > div { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:8px 5px; border-bottom:1px solid var(--border); }
.mini-table span { display:flex; align-items:center; gap:8px; color:var(--muted); }
.mini-table i { width:9px; height:9px; border-radius:3px; background:var(--dot); }
.funnel-chart { width:100%; display:grid; justify-items:center; gap:6px; }
.funnel-chart > div { min-width:28%; display:flex; justify-content:space-between; gap:8px; padding:8px 11px; color:#fff; font-size:11px; border-radius:6px; background:linear-gradient(120deg,color-mix(in srgb,var(--bar) 70%,#111),var(--bar)); box-shadow:0 7px 13px color-mix(in srgb,var(--bar) 25%,transparent); }
.leadership-card { display:grid; gap:4px; padding:16px; border-radius:14px; background:linear-gradient(145deg,color-mix(in srgb,var(--primary) 9%,white),white); border:1px solid var(--border); }
.leadership-card small { color:var(--muted); text-transform:uppercase; font-size:9px; font-weight:800; letter-spacing:.08em; }
.leadership-card span { margin-top:7px; color:var(--muted); }
.union-card { background:linear-gradient(155deg,var(--surface),color-mix(in srgb,var(--primary) 4%,var(--surface))); }
.union-kpis { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; margin:14px 0; }
.union-kpis span { min-width:0; padding:9px; border-radius:10px; background:var(--background); color:var(--muted); font-size:10px; }
.union-kpis strong { display:block; color:var(--text); font-size:16px; overflow-wrap:anywhere; }
.money-income { color:var(--success); font-weight:800; white-space:nowrap; }
.money-expenditure { color:var(--danger); font-weight:800; white-space:nowrap; }
.master-tabs { display:flex; gap:8px; overflow-x:auto; padding-bottom:12px; scrollbar-width:thin; }
.master-tabs .btn { flex:none; }
.tone-teal { --card-colour:#008e8b; }.tone-pink { --card-colour:#d13f8c; }
.identity-lock img { width:66px; height:66px; border-radius:18px; }
.roles-workspace { grid-template-columns:minmax(260px,.72fr) minmax(500px,1.65fr); align-items:start; }
.roles-workspace > .panel { overflow:visible; }
.roles-workspace > .panel:first-child { position:sticky; top:12px; }
.roles-workspace [data-role] { margin:0 0 8px; border:1px solid var(--border)!important; border-radius:12px; padding:13px!important; background:var(--surface)!important; transition:.15s ease; }
.roles-workspace [data-role]:hover,.roles-workspace [data-role].selected { border-color:color-mix(in srgb,var(--primary) 55%,var(--border))!important; background:color-mix(in srgb,var(--primary) 6%,var(--surface))!important; box-shadow:0 7px 18px rgba(15,43,33,.08); }
.roles-workspace [data-role].selected { box-shadow:inset 4px 0 var(--primary),0 7px 18px rgba(15,43,33,.08); }
.permission-toolbar { display:flex; align-items:center; justify-content:space-between; gap:12px; margin:18px 0 4px; padding:11px 13px; border-radius:12px; background:var(--background); }
.permission-toolbar input { flex:1; min-height:40px; border:1px solid var(--border); border-radius:9px; padding:8px 11px; }
.permission-toolbar span { color:var(--muted); font-size:12px; white-space:nowrap; }
.permission-group { border:1px solid var(--border); border-radius:13px; padding:14px; }
.permission-group > header { display:flex; align-items:center; justify-content:space-between; gap:10px; margin-bottom:12px; }
.permission-group > header h3 { margin:0; }
.permission-group .permission-options .checkbox-field { padding:11px; border:1px solid color-mix(in srgb,var(--border) 75%,transparent); border-radius:10px; background:color-mix(in srgb,var(--surface) 96%,var(--background)); }
.permission-group .checkbox-field span,.permission-group .checkbox-field strong,.permission-group .checkbox-field small { display:block; }
.permission-group .checkbox-field small { color:var(--muted); margin-top:3px; font-weight:450; }

/* RichFlow 3.0.1: dependable page scrolling, compact protected branding and access-control UI */
* { scrollbar-width: thin; scrollbar-color: color-mix(in srgb,var(--primary) 56%,#9aa8a2) transparent; }
*::-webkit-scrollbar { width: 11px; height: 11px; }
*::-webkit-scrollbar-thumb { background: color-mix(in srgb,var(--primary) 56%,#9aa8a2); border: 3px solid transparent; border-radius: 999px; background-clip: padding-box; }
*::-webkit-scrollbar-track { background: color-mix(in srgb,var(--background) 92%,white); }
.app-page, .app-page #app, .app-shell, .app-main, .content { height:auto !important; max-height:none !important; overflow-x:hidden; overflow-y:visible !important; }
.content { padding-bottom:max(52px,env(safe-area-inset-bottom)); }
.modal-body { overflow-y:auto; scrollbar-gutter:stable; overscroll-behavior:contain; }
.developer-lockup img { width:112px !important; height:68px !important; max-width:112px !important; max-height:68px !important; min-width:112px; border-radius:999px !important; object-fit:contain !important; }
.developer-lockup strong { font-size:clamp(30px,4vw,46px); }
.login-card-brand { min-width:0; }
.login-card-brand > img { width:72px !important; height:44px !important; max-width:72px !important; max-height:44px !important; min-width:72px; border-radius:999px !important; object-fit:contain !important; }
.login-card-brand > div:nth-child(2) { min-width:0; }
.login-facility-logos { display:flex; align-items:center; justify-content:flex-end; gap:7px; margin-left:auto; }
.login-facility-logos img { width:38px !important; height:38px !important; max-width:38px !important; border-radius:50%; object-fit:contain !important; padding:2px; background:#fff; border:1px solid var(--border); }
.sidebar-brand { display:grid; grid-template-columns:auto minmax(0,1fr) auto; }
.sidebar-brand-copy { min-width:0; }
.sidebar-facility-logo { width:35px; height:35px; max-width:35px; object-fit:contain; border-radius:50%; background:#fff; padding:2px; box-shadow:0 4px 12px rgba(0,0,0,.2); }
.mobile-facility-logo { width:28px !important; height:28px !important; max-width:28px; border-radius:50% !important; object-fit:contain !important; background:#fff !important; padding:2px; }
.dashboard-filter { top:84px; }
.access-control-shell { display:grid; grid-template-columns:minmax(275px,.72fr) minmax(0,1.7fr); gap:20px; align-items:start; }
.role-browser { position:sticky; top:90px; overflow:hidden; }
.role-browser-tools { display:grid; gap:10px; padding:14px; border-bottom:1px solid var(--border); }
.role-browser-tools input,.permission-toolbar input { width:100%; min-height:42px; border:1px solid var(--border); border-radius:10px; padding:9px 12px; background:var(--surface); }
.role-list { display:grid; gap:8px; padding:10px; max-height:calc(100vh - 250px); overflow-y:auto; }
.role-card { width:100%; display:grid; grid-template-columns:minmax(0,1fr) auto; gap:12px; align-items:center; text-align:left; border:1px solid var(--border); border-radius:13px; padding:13px; background:var(--surface); cursor:pointer; }
.role-card:hover,.role-card.selected { border-color:color-mix(in srgb,var(--primary) 55%,var(--border)); background:color-mix(in srgb,var(--primary) 5%,var(--surface)); box-shadow:0 8px 20px rgba(15,43,33,.08); }
.role-card.selected { box-shadow:inset 4px 0 var(--primary),0 8px 20px rgba(15,43,33,.08); }
.role-card strong,.role-card small { display:block; }
.role-card small { color:var(--muted); margin-top:3px; line-height:1.35; }
.role-action-count { white-space:nowrap; border-radius:999px; padding:5px 8px; background:var(--background); color:var(--muted); font-size:11px; font-weight:750; }
.role-detail-head { align-items:flex-start; }
.role-detail-head .role-heading { display:flex; gap:12px; align-items:center; min-width:0; }
.role-heading-icon { width:42px; height:42px; display:grid; place-items:center; flex:none; border-radius:12px; background:color-mix(in srgb,var(--primary) 9%,white); color:var(--primary); }
.role-heading-icon .ui-icon { width:22px; }
.permission-summary { display:flex; flex-wrap:wrap; gap:8px; }
.permission-summary span { padding:6px 9px; border-radius:999px; background:var(--background); color:var(--muted); font-size:11px; font-weight:700; }
.permission-module { border:1px solid var(--border); border-radius:14px; overflow:hidden; background:var(--surface); }
.permission-module summary { list-style:none; display:flex; justify-content:space-between; gap:12px; padding:14px 16px; cursor:pointer; background:color-mix(in srgb,var(--primary) 3%,var(--surface)); font-weight:800; }
.permission-module summary::-webkit-details-marker { display:none; }
.permission-module summary span { color:var(--muted); font-size:11px; font-weight:700; }
.permission-module-body { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; padding:12px; border-top:1px solid var(--border); }
.permission-card { display:grid; grid-template-columns:auto minmax(0,1fr); gap:10px; align-items:start; padding:12px; border:1px solid var(--border); border-radius:11px; background:var(--surface); cursor:pointer; min-width:0; }
.permission-card:has(input:checked) { border-color:color-mix(in srgb,var(--primary) 52%,var(--border)); background:color-mix(in srgb,var(--primary) 5%,var(--surface)); }
.permission-card input { width:18px; height:18px; margin:2px 0 0; accent-color:var(--primary); }
.permission-card-copy { min-width:0; }
.permission-card-copy strong,.permission-card-copy small,.permission-card-copy code { display:block; overflow-wrap:anywhere; }
.permission-card-copy small { color:var(--muted); margin-top:4px; line-height:1.4; }
.permission-card-copy code { color:var(--primary); margin-top:7px; font-size:10px; }
.appearance-logo-preview { display:flex; align-items:center; gap:10px; min-height:52px; }
.appearance-logo-preview img { width:48px; height:48px; object-fit:contain; border-radius:50%; padding:3px; border:1px solid var(--border); background:#fff; }
.dashboard-link { cursor:pointer; }
.dashboard-link:focus-visible { transform:translateY(-3px); box-shadow:0 0 0 4px color-mix(in srgb,var(--secondary) 36%,transparent),var(--shadow); }
.dashboard-charts .widget-wide,.dashboard-charts .widget-full { grid-column:1 / -1; }
.dashboard-config-list { display:grid; gap:10px; }
.dashboard-config-row { display:grid; grid-template-columns:34px 92px minmax(220px,1fr) minmax(125px,.45fr) minmax(125px,.45fr) auto; gap:12px; align-items:end; padding:13px; border:1px solid var(--border); border-radius:13px; background:var(--surface); box-shadow:0 5px 14px rgba(15,43,33,.045); }
.dashboard-config-row.dragging { opacity:.55; border-color:var(--primary); }
.drag-handle { align-self:center; color:var(--muted); cursor:grab; font-size:20px; letter-spacing:-5px; }
.row-order { display:flex; gap:6px; padding-bottom:1px; }
.document-frame { display:block; width:100%; height:min(74vh,900px); border:1px solid var(--border); border-radius:12px; background:#fff; }
.live-support-button { position:fixed; right:max(20px,env(safe-area-inset-right)); bottom:max(20px,env(safe-area-inset-bottom)); z-index:70; min-height:50px; display:flex; align-items:center; gap:8px; border:0; border-radius:999px; padding:12px 17px; color:#fff; background:linear-gradient(135deg,var(--primary),var(--accent)); box-shadow:0 16px 34px color-mix(in srgb,var(--primary) 36%,transparent); cursor:pointer; font-weight:800; }
.live-support-button .ui-icon { width:21px; height:21px; }
.communication-launcher { position:fixed; right:max(20px,env(safe-area-inset-right)); bottom:max(20px,env(safe-area-inset-bottom)); z-index:72; display:grid; justify-items:end; gap:10px; }
.communication-launcher-button { min-height:52px; display:flex; align-items:center; gap:8px; border:0; border-radius:999px; padding:12px 18px; color:#fff; background:linear-gradient(135deg,var(--primary),var(--accent)); box-shadow:0 16px 34px color-mix(in srgb,var(--primary) 36%,transparent); cursor:pointer; font-weight:800; }
.communication-launcher-button .ui-icon { width:21px; height:21px; }
.communication-launcher-menu { min-width:250px; padding:8px; border:1px solid var(--border); border-radius:14px; background:var(--surface); box-shadow:var(--shadow); }
.communication-launcher-menu button { width:100%; display:grid; grid-template-columns:25px minmax(0,1fr); align-items:center; gap:9px; border:0; border-radius:9px; padding:10px; background:transparent; color:var(--text); text-align:left; cursor:pointer; }
.communication-launcher-menu button:hover { background:var(--background); }
.communication-launcher-menu .ui-icon { width:19px; height:19px; color:var(--primary); }
.config-centres { margin-bottom:18px; }
.config-centre-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(165px,1fr)); gap:10px; }
.config-centre-card { min-width:0; display:grid; grid-template-columns:38px minmax(0,1fr); grid-template-rows:auto auto; gap:2px 10px; align-items:center; border:1px solid var(--border); border-radius:12px; padding:12px; background:var(--surface); color:var(--text); text-align:left; cursor:pointer; }
.config-centre-card:hover { border-color:color-mix(in srgb,var(--primary) 45%,var(--border)); box-shadow:0 7px 18px rgba(15,43,33,.07); }
.config-centre-card>span { grid-row:1/3; width:38px; height:38px; display:grid; place-items:center; border-radius:10px; background:color-mix(in srgb,var(--primary) 9%,var(--surface)); color:var(--primary); }
.config-centre-card strong,.config-centre-card small { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.config-centre-card small { color:var(--muted); }
.public-portal-page { min-height:100vh; background:linear-gradient(145deg,color-mix(in srgb,var(--primary) 8%,var(--background)),var(--background)); }
.public-portal-page .login-shell { display:block; width:min(1180px,calc(100% - 28px)); margin:0 auto; padding:24px 0 48px; }
.public-portal-shell { display:grid; gap:20px; }
.public-portal-head { display:flex; align-items:center; justify-content:space-between; gap:16px; }
.public-portal-head .developer-lockup { color:var(--text); text-decoration:none; }
.public-portal-title { padding:clamp(24px,5vw,48px); border-radius:20px; color:#fff; background:linear-gradient(130deg,var(--primary),color-mix(in srgb,var(--primary) 68%,var(--accent))); box-shadow:var(--shadow); }
.public-portal-title h1 { margin:6px 0; font-size:clamp(28px,5vw,48px); }
.public-portal-title p { max-width:760px; margin:0; color:rgba(255,255,255,.78); }
.public-portal-title .eyebrow { color:rgba(255,255,255,.72); }
.public-signin-card { max-width:620px; margin:0 auto; }
.promotion-board { display:grid; grid-template-columns:repeat(4,minmax(230px,1fr)); gap:14px; overflow-x:auto; padding-bottom:10px; }
.promotion-column { min-width:230px; border:1px solid var(--border); border-radius:14px; background:color-mix(in srgb,var(--background) 72%,var(--surface)); overflow:hidden; }
.promotion-column > header { display:flex; justify-content:space-between; gap:8px; padding:13px; border-bottom:1px solid var(--border); }
.promotion-column-body { display:grid; gap:10px; padding:10px; }
.promotion-path { display:flex; flex-wrap:wrap; gap:6px; margin-top:10px; }
.promotion-path span { border-radius:999px; padding:5px 8px; background:var(--background); color:var(--muted); font-size:10px; font-weight:750; }
.promotion-path span.done { color:var(--success); background:color-mix(in srgb,var(--success) 10%,var(--surface)); }
.promotion-files { display:flex; flex-wrap:wrap; gap:5px; margin-top:10px; padding-top:9px; border-top:1px solid var(--border); }

/* RichFlow 3.2 governed workspace portals */
.workspace-portal-page { display:grid; gap:20px; }
.workspace-portal-page > .page-header { margin-bottom:0; }
.workspace-command-hero { position:relative; overflow:hidden; display:flex; align-items:center; justify-content:space-between; gap:28px; min-height:190px; padding:clamp(24px,4vw,42px); color:#fff; border-radius:calc(var(--radius) + 9px); background:radial-gradient(circle at 76% 120%,color-mix(in srgb,var(--secondary) 58%,transparent) 0 16%,transparent 17%),linear-gradient(125deg,color-mix(in srgb,var(--sidebar-colour) 93%,#000),color-mix(in srgb,var(--primary) 84%,#175d80) 58%,color-mix(in srgb,var(--accent) 76%,#5d43d7)); box-shadow:0 24px 60px color-mix(in srgb,var(--primary) 25%,transparent); }
.workspace-command-hero::after { content:""; position:absolute; width:260px; height:260px; right:-80px; top:-120px; border:42px solid rgba(255,255,255,.08); border-radius:50%; }
.workspace-command-hero > * { position:relative; z-index:1; }
.workspace-command-hero h2 { margin:5px 0 7px; font-size:clamp(27px,4vw,44px); letter-spacing:-.045em; }
.workspace-command-hero p { margin:0; max-width:660px; color:rgba(255,255,255,.76); }
.workspace-eyebrow { color:var(--secondary); font-size:10px; font-weight:850; letter-spacing:.12em; text-transform:uppercase; }
.workspace-hero-metrics { display:flex; align-items:center; gap:10px; flex-wrap:wrap; justify-content:flex-end; }
.workspace-hero-metrics article { min-width:86px; padding:12px; text-align:center; border:1px solid rgba(255,255,255,.16); border-radius:14px; background:rgba(255,255,255,.09); backdrop-filter:blur(10px); }
.workspace-hero-metrics article strong,.workspace-hero-metrics article span { display:block; }
.workspace-hero-metrics article strong { font-size:24px; }
.workspace-hero-metrics article span { color:rgba(255,255,255,.7); font-size:10px; }
.workspace-performance { width:92px; height:92px; color:#fff; background:radial-gradient(circle closest-side,color-mix(in srgb,var(--primary) 86%,#10261f) 70%,transparent 72% 99%,color-mix(in srgb,var(--primary) 86%,#10261f) 100%),conic-gradient(var(--secondary) calc(var(--progress) * 1%),rgba(255,255,255,.15) 0); }
.workspace-performance small { display:block; font-size:8px; font-weight:700; color:rgba(255,255,255,.68); }
.workspace-studio .panel-header { align-items:end; }
.workspace-studio .page-actions { align-items:center; }
.workspace-studio .control { min-width:min(260px,40vw); }
.workspace-record-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:14px; padding:16px; }
.workspace-record-card { min-width:0; display:flex; flex-direction:column; gap:9px; min-height:250px; padding:17px; border:1px solid var(--border); border-radius:15px; background:linear-gradient(155deg,var(--surface),color-mix(in srgb,var(--primary) 4%,var(--surface))); box-shadow:0 8px 20px rgba(15,43,33,.045); transition:transform .16s ease,border-color .16s ease,box-shadow .16s ease; }
.workspace-record-card:hover { transform:translateY(-3px); border-color:color-mix(in srgb,var(--primary) 36%,var(--border)); box-shadow:0 15px 30px rgba(15,43,33,.09); }
.workspace-record-card header,.workspace-record-card footer,.workspace-record-meta { display:flex; align-items:center; justify-content:space-between; gap:10px; }
.workspace-record-card header > div { display:grid; justify-items:end; gap:4px; }
.workspace-record-card h3 { margin:3px 0 0; font-size:18px; line-height:1.2; }
.workspace-record-card p { margin:0; color:var(--muted); flex:1; }
.workspace-record-card footer { margin-top:auto; padding-top:10px; border-top:1px solid var(--border); color:var(--muted); font-size:11px; }
.workspace-record-meta { flex-wrap:wrap; color:var(--muted); font-size:11px; }
.workspace-record-icon { width:43px; height:43px; flex:none; display:grid; place-items:center; color:var(--primary); border-radius:13px; background:color-mix(in srgb,var(--primary) 9%,var(--surface)); }
.workspace-record-icon .ui-icon { width:23px; height:23px; }
.workspace-paper { min-height:470px; max-width:850px; margin:0 auto; }
.workspace-record-banner { display:flex; align-items:center; justify-content:space-between; gap:20px; padding:20px 24px; border-radius:var(--radius); color:#fff; background:linear-gradient(130deg,var(--primary),color-mix(in srgb,var(--accent) 70%,#5752d8)); box-shadow:var(--shadow); }
.workspace-record-banner p { margin:9px 0 0; color:rgba(255,255,255,.78); }
.workspace-document { max-width:900px; margin:auto; font-family:Aptos,Calibri,Arial,sans-serif; line-height:1.62; }
.record-detail-list { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:11px; margin:0; }
.record-detail-list > div { display:grid; gap:3px; padding:11px; border-radius:10px; background:var(--background); }
.record-detail-list dt,.record-detail-list small { color:var(--muted); font-size:10px; font-weight:780; text-transform:uppercase; letter-spacing:.05em; }
.record-detail-list dd { margin:0; font-weight:700; overflow-wrap:anywhere; }
.workspace-file-list { display:grid; gap:9px; }
.workspace-file-list > article { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:12px; border:1px solid var(--border); border-radius:11px; }
.workspace-file-list > article > div { display:flex; align-items:center; gap:10px; min-width:0; }
.workspace-file-list strong,.workspace-file-list small { display:block; overflow-wrap:anywhere; }
.workspace-file-list small { color:var(--muted); }
.submission-status-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:9px; padding:15px; border-bottom:1px solid var(--border); }
.submission-status { display:flex; justify-content:space-between; align-items:center; gap:8px; padding:10px; border-radius:11px; border:1px solid var(--border); background:var(--surface); }
.submission-status.accepted { border-color:color-mix(in srgb,var(--success) 45%,var(--border)); background:color-mix(in srgb,var(--success) 6%,var(--surface)); }
.submission-status.missing,.submission-status.returned { border-color:color-mix(in srgb,var(--danger) 32%,var(--border)); }
.information-hub-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:18px; }
.hub-row { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:11px; border:1px solid var(--border); border-radius:11px; }
.hub-row p { margin:3px 0 0; color:var(--muted); font-size:11px; }
.record-type-grid .record-card { min-height:285px; }
.checkbox-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:10px; margin-top:8px; }
.checkbox-grid .checkbox-field { padding:9px; border:1px solid var(--border); border-radius:9px; background:var(--surface); }
.selected-audience-panel { padding:14px; border:1px solid color-mix(in srgb,var(--primary) 28%,var(--border)); border-radius:12px; background:color-mix(in srgb,var(--primary) 4%,var(--surface)); }
.audience-columns { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:14px; margin:9px 0; }
.audience-columns fieldset { display:grid; align-content:start; gap:7px; max-height:210px; overflow:auto; padding:11px; border:1px solid var(--border); border-radius:10px; background:var(--surface); }
.audience-columns legend { padding:0 5px; font-size:11px; font-weight:800; }
.section-lock-notice { border-left:5px solid var(--secondary); }

/* Professional staff service record: readable particulars and drill-down KPIs. */
.staff-report-shell { display:grid; gap:18px; }
.staff-report-identity { display:flex; align-items:flex-start; justify-content:space-between; gap:24px; padding:22px; color:#fff; border-radius:17px; background:linear-gradient(125deg,var(--primary),color-mix(in srgb,var(--accent) 72%,#4d54c8)); box-shadow:0 16px 34px color-mix(in srgb,var(--primary) 22%,transparent); }
.staff-report-identity h2 { margin:5px 0 6px; font-size:clamp(23px,3vw,34px); letter-spacing:-.035em; }
.staff-report-identity p { margin:0; color:rgba(255,255,255,.78); }
.staff-assignment { min-width:210px; display:grid; justify-items:end; gap:5px; text-align:right; }
.staff-assignment span { color:rgba(255,255,255,.78); font-size:12px; }
.staff-assignment .badge { margin-top:5px; background:rgba(255,255,255,.15); color:#fff; border-color:rgba(255,255,255,.2); }
.staff-report-kpis { display:grid; grid-template-columns:repeat(auto-fit,minmax(155px,1fr)); gap:12px; }
.staff-report-kpi { min-height:126px; display:grid; align-content:space-between; gap:5px; padding:15px; border:1px solid var(--border); border-radius:15px; text-align:left; color:var(--text); background:linear-gradient(150deg,var(--surface),color-mix(in srgb,var(--primary) 5%,var(--surface))); box-shadow:0 8px 20px rgba(20,44,36,.06); cursor:pointer; transition:transform .15s ease,border-color .15s ease,box-shadow .15s ease; }
.staff-report-kpi:hover,.staff-report-kpi:focus-visible { transform:translateY(-3px); border-color:color-mix(in srgb,var(--primary) 45%,var(--border)); box-shadow:0 14px 28px rgba(20,44,36,.11); outline:0; }
.staff-report-kpi span { min-height:34px; font-size:12px; font-weight:760; line-height:1.35; }
.staff-report-kpi strong { font-size:31px; line-height:1; color:var(--primary); }
.staff-report-kpi small { color:var(--muted); font-size:10px; font-weight:750; text-transform:uppercase; letter-spacing:.05em; }
.staff-profile-sections { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:14px; }
.staff-profile-section { overflow:hidden; border:1px solid var(--border); border-radius:15px; background:var(--surface); }
.staff-profile-section header { padding:13px 16px; border-bottom:1px solid var(--border); background:color-mix(in srgb,var(--primary) 4%,var(--surface)); }
.staff-profile-section h3 { margin:0; font-size:14px; }
.staff-profile-section dl { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:0; margin:0; padding:7px 15px 13px; }
.staff-profile-section dl > div { min-width:0; display:grid; align-content:start; gap:4px; padding:10px 9px; border-bottom:1px solid color-mix(in srgb,var(--border) 72%,transparent); }
.staff-profile-section dt { color:var(--muted); font-size:10px; font-weight:760; text-transform:uppercase; letter-spacing:.045em; }
.staff-profile-section dd { margin:0; font-size:13px; font-weight:700; overflow-wrap:anywhere; }
.staff-report-section-modal { display:grid; gap:14px; }
.staff-report-section-modal > header { display:flex; align-items:center; justify-content:space-between; gap:14px; padding:13px 15px; border:1px solid var(--border); border-radius:12px; background:color-mix(in srgb,var(--primary) 4%,var(--surface)); }
.staff-report-section-modal > header p { margin:0; color:var(--muted); font-size:12px; }
.staff-report-table-wrap { max-height:62vh; overflow:auto; border:1px solid var(--border); border-radius:13px; }
.staff-report-table { min-width:760px; }
.staff-report-table th { position:sticky; top:0; z-index:1; white-space:nowrap; background:color-mix(in srgb,var(--background) 82%,var(--surface)); }
.staff-report-table td { min-width:115px; max-width:260px; line-height:1.45; overflow-wrap:anywhere; }
.staff-report-empty { padding:48px 20px; border:1px dashed var(--border); border-radius:14px; text-align:center; background:var(--background); }
.staff-report-empty strong { display:block; margin-bottom:5px; }
.staff-report-empty p { margin:0; color:var(--muted); }

.topbar-plus { background:linear-gradient(145deg,var(--primary),color-mix(in srgb,var(--primary) 70%,#101b37)); color:#fff; border-color:transparent; }
.module-finder { display:grid; gap:16px; }
.module-finder-results { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:10px; max-height:58vh; overflow:auto; padding:2px; }
.module-finder-results button { display:flex; gap:12px; align-items:center; padding:13px; border:1px solid var(--border); border-radius:13px; background:var(--surface); color:var(--text); text-align:left; cursor:pointer; }
.module-finder-results button:hover,.module-finder-results button:focus-visible { border-color:var(--primary); background:color-mix(in srgb,var(--primary) 5%,var(--surface)); outline:0; }
.module-finder-results button > span:last-child { display:grid; gap:3px; }.module-finder-results small { color:var(--muted); }

.record-view-item { position:relative; }
.record-expand { display:none; width:100%; align-items:center; justify-content:space-between; margin-top:4px; padding:8px 0 0; border:0; border-top:1px solid var(--border); background:transparent; color:var(--primary); font-weight:800; cursor:pointer; }
body[data-record-view="list"] .cards-grid { grid-template-columns:1fr; }
body[data-record-view="list"] .record-view-item { min-height:0; padding:14px 16px; }
body[data-record-view="list"] .record-view-item:not(.expanded) > p,
body[data-record-view="list"] .record-view-item:not(.expanded) > .progress-line,
body[data-record-view="list"] .record-view-item:not(.expanded) > .record-card-actions,
body[data-record-view="list"] .record-view-item:not(.expanded) > .workspace-record-icon { display:none; }
body[data-record-view="list"] .record-expand { display:flex; }
body[data-record-view="list"] .record-view-item.expanded .record-expand b { transform:rotate(180deg); }
.bounded-records { max-height:min(68vh,760px); overflow:auto; overscroll-behavior:contain; scrollbar-gutter:stable; padding-right:4px; }
.device-history-scroll { max-height:min(68vh,760px); overflow:auto; overscroll-behavior:contain; scrollbar-gutter:stable; }
.device-row > div:nth-child(2) { display:grid; gap:4px; }
.empty-state .ui-icon,.empty .ui-icon,.search-empty .ui-icon { width:42px; height:42px; max-width:42px; max-height:42px; }
.schedule-batch-row { display:grid; gap:12px; padding:15px; border:1px solid var(--border); border-radius:14px; background:color-mix(in srgb,var(--primary) 3%,var(--surface)); }
.schedule-batch-row + .schedule-batch-row { margin-top:12px; }
.schedule-batch-row > header { display:flex; align-items:center; justify-content:space-between; gap:12px; }
.table-wrap { max-height:min(72vh,820px); overscroll-behavior:contain; scrollbar-gutter:stable; }
.data-table thead th { position:sticky; top:0; z-index:2; background:color-mix(in srgb,var(--background) 88%,var(--surface)); }

.popup-banner { display:grid; gap:18px; }.popup-banner-icon { width:58px; height:58px; display:grid; place-items:center; border-radius:18px; color:#fff; background:linear-gradient(145deg,var(--primary),var(--secondary)); box-shadow:0 14px 32px color-mix(in srgb,var(--primary) 25%,transparent); }
.popup-banner-icon .ui-icon { width:30px; height:30px; }.popup-banner-media,.popup-banner-video { display:block; width:100%; max-height:52vh; border:0; border-radius:18px; object-fit:contain; background:#07130f; }.popup-banner-video { aspect-ratio:16/9; }
.popup-banner-copy { display:grid; justify-items:start; gap:9px; }.popup-banner-copy p { margin:0; white-space:pre-line; line-height:1.65; }.popup-banner-copy small { color:var(--muted); }

.learning-hero { display:grid; grid-template-columns:minmax(0,1fr) repeat(3,minmax(90px,145px)); align-items:stretch; gap:12px; margin-bottom:24px; padding:20px; border-radius:22px; color:#fff; background:linear-gradient(125deg,#082e25,var(--primary) 58%,#136d84); box-shadow:0 18px 50px rgba(5,48,38,.2); }
.learning-hero > div { display:grid; place-items:center; align-content:center; padding:12px; border-radius:16px; background:rgba(255,255,255,.1); text-align:center; }.learning-hero > div:first-child { grid-template-columns:52px 1fr; gap:14px; justify-items:start; text-align:left; }.learning-hero .ui-icon { width:42px;height:42px; }.learning-hero span { display:grid;gap:4px; }.learning-hero b { font-size:30px; }.learning-hero small { color:rgba(255,255,255,.78); }
.section-title { display:flex; align-items:center; gap:10px; margin:22px 0 12px; }.section-title h2 { margin:0; font-size:19px; }.section-title > span { display:grid;place-items:center;min-width:27px;height:27px;border-radius:50%;background:color-mix(in srgb,var(--primary) 10%,var(--surface));color:var(--primary);font-weight:850; }
.learning-card { border-top:4px solid color-mix(in srgb,var(--primary) 75%,var(--secondary)); }
.course-overview { display:grid; grid-template-columns:minmax(0,1fr) 150px; gap:24px; align-items:center; padding:24px; margin-bottom:18px; border:1px solid var(--border); border-radius:20px; background:linear-gradient(145deg,var(--surface),color-mix(in srgb,var(--primary) 5%,var(--surface))); }.course-overview p{line-height:1.65}.course-progress-ring { --progress:0; width:126px; aspect-ratio:1; display:grid;place-items:center;align-content:center;border-radius:50%;background:radial-gradient(circle closest-side,var(--surface) 76%,transparent 77% 99%),conic-gradient(var(--primary) calc(var(--progress)*1%),color-mix(in srgb,var(--border) 75%,transparent) 0);}.course-progress-ring strong{font-size:27px}.course-progress-ring small{font-size:10px;color:var(--muted);text-transform:uppercase;font-weight:800}
.learning-module { display:grid;grid-template-columns:40px 1fr;gap:13px;padding:14px;border:1px solid var(--border);border-radius:14px;background:var(--surface)}.learning-module-number{display:grid;place-items:center;width:36px;height:36px;border-radius:12px;background:color-mix(in srgb,var(--primary) 10%,var(--surface));color:var(--primary);font-weight:900}.learning-module h3{margin:6px 0}.learning-module p{margin:5px 0 10px;line-height:1.5}.resource-row{display:grid;grid-template-columns:28px minmax(0,1fr) auto;gap:10px;align-items:center;padding:11px;border-bottom:1px solid var(--border)}.resource-row>div:nth-child(2){display:grid;gap:3px}.resource-row small{color:var(--muted)}
.certificate-callout { display:flex;align-items:center;gap:16px;margin:18px 0;padding:20px;border:1px solid #d8b657;border-radius:18px;background:linear-gradient(135deg,#fffaf0,#fff4c9);color:#493a12}.certificate-callout>.ui-icon{width:42px;height:42px}.certificate-callout>div:nth-child(2){display:grid;gap:4px;flex:1}
.question-manager-row{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:12px;border:1px solid var(--border);border-radius:12px}.question-manager-row>div:first-child{display:grid;gap:5px}.question-manager-row small{color:var(--muted)}
.assessment-clock { position:sticky;top:-24px;z-index:3;display:flex;align-items:center;gap:16px;margin:-24px -24px 20px;padding:14px 24px;color:#fff;background:linear-gradient(100deg,#092e27,var(--primary));box-shadow:0 8px 25px rgba(0,0,0,.15)}.assessment-clock strong{font-size:27px;margin-left:auto;font-variant-numeric:tabular-nums}.assessment-paper{display:grid;gap:16px}.assessment-question{display:grid;gap:10px;margin:0;padding:18px;border:1px solid var(--border);border-radius:15px}.assessment-question legend{font-weight:800;line-height:1.5;padding:0 8px}.assessment-question legend>span{display:inline-grid;place-items:center;width:27px;height:27px;margin-right:8px;border-radius:9px;background:var(--primary);color:#fff}.assessment-question legend small{color:var(--muted);font-weight:600}.answer-option{display:flex;align-items:center;gap:10px;padding:11px;border:1px solid var(--border);border-radius:11px;cursor:pointer}.answer-option:has(input:checked){border-color:var(--primary);background:color-mix(in srgb,var(--primary) 7%,var(--surface))}.result-reveal{display:grid;justify-items:center;gap:7px;padding:30px;text-align:center;border-radius:20px;background:color-mix(in srgb,var(--primary) 6%,var(--surface))}.result-reveal>.ui-icon{width:56px;height:56px;color:var(--primary)}.result-reveal>strong{font-size:50px}.result-reveal.passed{background:#edf9f4;color:#0c684b}.result-reveal.failed{background:#fff3f4;color:#a52a39}

.calendar-shell{overflow:hidden;border:1px solid var(--border);border-radius:20px;background:var(--surface);box-shadow:0 12px 35px rgba(12,39,31,.08)}.calendar-toolbar{display:flex;align-items:center;gap:9px;padding:15px;border-bottom:1px solid var(--border)}.calendar-toolbar h2{flex:1;margin:0 8px;font-size:21px}.calendar-toolbar select,.calendar-filters input,.calendar-filters select{height:42px;border:1px solid var(--border);border-radius:11px;background:var(--surface);color:var(--text);padding:0 12px}.calendar-arrow{width:38px;height:38px;border:1px solid var(--border);border-radius:50%;background:var(--surface);font-size:25px;cursor:pointer}.calendar-filters{display:flex;gap:10px;padding:11px 15px;border-bottom:1px solid var(--border);background:color-mix(in srgb,var(--background) 55%,var(--surface))}.calendar-filters input{flex:1}.calendar-weekdays,.calendar-month{display:grid;grid-template-columns:repeat(7,minmax(0,1fr))}.calendar-weekdays span{padding:10px;text-align:center;color:var(--muted);font-size:11px;font-weight:850;text-transform:uppercase;border-right:1px solid var(--border)}.calendar-day{min-height:132px;padding:7px;border-top:1px solid var(--border);border-right:1px solid var(--border);background:var(--surface)}.calendar-day.outside{background:color-mix(in srgb,var(--background) 70%,var(--surface));color:var(--muted)}.calendar-day.today>header,.calendar-day-column.today header strong{display:grid;place-items:center;width:28px;height:28px;border-radius:50%;background:var(--primary);color:#fff}.calendar-day>div{display:grid;gap:4px;margin-top:5px}.calendar-event{display:flex;gap:5px;align-items:center;min-width:0;padding:5px 7px;border:0;border-left:4px solid var(--event-colour);border-radius:6px;background:color-mix(in srgb,var(--event-colour) 12%,var(--surface));color:var(--text);font-size:10px;text-align:left;cursor:pointer}.calendar-event time{font-weight:850}.calendar-event span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.calendar-more{font-size:10px;color:var(--primary);font-weight:750}.calendar-week{display:grid;grid-template-columns:repeat(7,minmax(125px,1fr));min-height:560px;overflow:auto}.calendar-day-column{border-right:1px solid var(--border)}.calendar-day-column>header{display:grid;justify-items:center;gap:5px;padding:12px;border-bottom:1px solid var(--border)}.calendar-day-column>div{display:grid;align-content:start;gap:7px;padding:8px}.calendar-day-column .calendar-event{display:grid;gap:4px;padding:9px}.calendar-agenda-months{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;padding:15px;max-height:72vh;overflow:auto}.calendar-agenda-month{border:1px solid var(--border);border-radius:14px;overflow:hidden}.calendar-agenda-month>header{display:flex;align-items:center;justify-content:space-between;padding:12px;background:color-mix(in srgb,var(--primary) 5%,var(--surface))}.calendar-agenda-month h3{margin:0}.calendar-agenda-month>div{display:grid;max-height:320px;overflow:auto}.calendar-agenda-event{display:grid;grid-template-columns:6px 85px minmax(0,1fr);gap:10px;align-items:center;padding:10px;border:0;border-bottom:1px solid var(--border);background:var(--surface);color:var(--text);text-align:left;cursor:pointer}.calendar-agenda-event i,.event-detail>i{width:6px;height:100%;min-height:32px;border-radius:5px;background:var(--event-colour)}.calendar-agenda-event span{display:grid;gap:3px}.calendar-agenda-event small{color:var(--muted)}.event-detail{display:grid;grid-template-columns:8px 1fr;gap:15px}.event-detail dl{display:grid;grid-template-columns:repeat(2,1fr);gap:12px;margin:0}.event-detail dl>div{display:grid;gap:4px;padding:10px;border:1px solid var(--border);border-radius:10px}.event-detail dt{color:var(--muted);font-size:10px;text-transform:uppercase;font-weight:800}.event-detail dd{margin:0;font-weight:750}

.record-summary-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin-bottom:16px}.record-summary-grid>div{display:grid;align-content:start;gap:5px;padding:13px;border:1px solid var(--border);border-radius:12px}.record-summary-grid small,.record-summary-grid span{color:var(--muted)}.timeline{display:grid;gap:0}.timeline article{display:grid;grid-template-columns:18px 1fr;gap:10px;position:relative;padding:0 0 18px}.timeline article>i{width:11px;height:11px;margin-top:5px;border-radius:50%;background:var(--primary);box-shadow:0 0 0 4px color-mix(in srgb,var(--primary) 12%,transparent)}.timeline article:not(:last-child)::before{content:"";position:absolute;left:5px;top:17px;bottom:1px;width:1px;background:var(--border)}.timeline p{margin:4px 0}.timeline small{color:var(--muted)}
.meeting-facilitator{display:flex;gap:9px;align-items:center;margin:8px 0;padding:9px;border-radius:11px;background:color-mix(in srgb,var(--primary) 5%,var(--surface))}.meeting-facilitator .ui-icon{width:22px;height:22px;color:var(--primary)}.meeting-facilitator span{display:grid}.meeting-facilitator small{color:var(--muted);font-size:9px;text-transform:uppercase;font-weight:800}.bulk-action-bar{position:sticky;top:78px;z-index:5;display:flex;align-items:center;gap:14px;margin:0 0 15px;padding:11px 14px;border:1px solid color-mix(in srgb,var(--primary) 30%,var(--border));border-radius:14px;background:color-mix(in srgb,var(--surface) 95%,transparent);box-shadow:0 10px 30px rgba(10,42,32,.1);backdrop-filter:blur(12px)}.bulk-action-bar strong{margin-left:auto}.record-selector{position:absolute;top:12px;right:12px;z-index:2;display:grid;place-items:center;width:28px;height:28px;border-radius:9px;background:var(--surface);box-shadow:0 3px 12px rgba(0,0,0,.12)}.record-selector input{width:17px;height:17px;accent-color:var(--primary)}body[data-record-view="list"] .promotion-board{display:grid;grid-template-columns:1fr;overflow:visible}body[data-record-view="list"] .promotion-case:not(.expanded) .promotion-path,body[data-record-view="list"] .promotion-case:not(.expanded)>small,body[data-record-view="list"] .promotion-case:not(.expanded)>.record-card-actions,body[data-record-view="list"] .promotion-case:not(.expanded)>.promotion-files{display:none}

.hub-calendar-strip{display:grid;grid-template-columns:repeat(auto-fill,minmax(240px,1fr));gap:10px;max-height:330px;overflow:auto;padding:15px;scrollbar-gutter:stable}.hub-calendar-item{display:grid;grid-template-columns:6px 66px minmax(0,1fr);gap:11px;align-items:center;padding:12px;border:1px solid var(--border);border-radius:13px;background:var(--surface);color:var(--text);text-align:left;cursor:pointer}.hub-calendar-item:hover{border-color:var(--primary);box-shadow:0 7px 20px color-mix(in srgb,var(--primary) 10%,transparent)}.hub-calendar-item>i{width:6px;height:100%;min-height:44px;border-radius:6px;background:var(--event-colour)}.hub-calendar-item time,.hub-calendar-item>span{display:grid;gap:3px}.hub-calendar-item time{font-weight:850}.hub-calendar-item time span,.hub-calendar-item small{color:var(--muted);font-size:11px}.hub-calendar-item strong{overflow:hidden;text-overflow:ellipsis}.security-feature{display:flex;align-items:center;gap:14px;padding:15px;border:1px solid var(--border);border-radius:15px;background:color-mix(in srgb,var(--primary) 5%,var(--surface))}.security-feature h3,.security-feature p{margin:0}.security-feature div{display:grid;gap:6px}.security-feature-icon{display:grid;place-items:center;flex:0 0 46px;height:46px;border-radius:14px;background:var(--primary);color:#fff}.security-feature-icon .ui-icon{width:25px;height:25px}.copy-field{display:flex;align-items:center;gap:10px;padding:10px 12px;border:1px solid var(--border);border-radius:11px;background:var(--background)}.copy-field code{flex:1;font-size:16px;font-weight:800;letter-spacing:.08em;overflow-wrap:anywhere}.wrap-code{display:block;padding:12px;white-space:normal;overflow-wrap:anywhere}.delivery-worker-panel .panel-body{display:grid;gap:12px}.worker-health{display:flex;gap:14px;align-items:center;padding:14px;border:1px solid var(--border);border-radius:14px}.worker-health>span{display:grid;place-items:center;width:43px;height:43px;border-radius:50%;background:#eef2f5;color:#5a6670}.worker-health.healthy>span{background:#e5f7ee;color:#08734e}.worker-health.delayed>span{background:#fff2da;color:#9b5d00}.worker-health p{margin:4px 0;color:var(--muted)}.worker-health small{color:var(--danger)}.worker-instruction{display:grid;gap:8px;padding:13px;border-radius:12px;background:#10251f;color:#e8fff7}.worker-instruction code{overflow:auto;color:#8df0cb}.worker-instruction span{color:#b8d6cb;font-size:12px;line-height:1.5}

@media (max-width:1200px) {
  .dashboard-filter { grid-template-columns:repeat(3,1fr); }
  .dashboard-search-field { grid-column:1 / -1; }
}
@media (max-width:900px) {
  .module-finder-results { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .learning-hero { grid-template-columns:repeat(3,1fr); }.learning-hero>div:first-child{grid-column:1/-1}
  .calendar-toolbar { flex-wrap:wrap; }.calendar-toolbar h2{order:4;flex-basis:100%}.calendar-week,.calendar-month,.calendar-weekdays{min-width:820px}.calendar-shell #calendar-stage{overflow:auto}.record-summary-grid{grid-template-columns:repeat(2,1fr)}
  .access-control-shell { grid-template-columns:1fr; }
  .role-browser { position:static; }
  .role-list { max-height:340px; }
  .dashboard-filter { top:auto; }
  .dashboard-config-row { grid-template-columns:28px 82px 1fr; }
  .dashboard-config-row .widget-title { grid-column:3; }
  .dashboard-config-row .field:not(.widget-title) { grid-column:3; }
  .dashboard-config-row .row-order { grid-column:3; }
  .workspace-command-hero { display:grid; }
  .workspace-hero-metrics { justify-content:flex-start; }
  .workspace-record-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .submission-status-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width:650px) {
  .module-finder-results,.calendar-agenda-months { grid-template-columns:1fr; }
  .learning-hero { grid-template-columns:1fr 1fr; }.learning-hero>div:first-child{grid-column:1/-1}.course-overview{grid-template-columns:1fr}.course-progress-ring{justify-self:center}.question-manager-row,.certificate-callout{display:grid}.record-summary-grid,.event-detail dl{grid-template-columns:1fr}.calendar-filters{display:grid}
  .developer-lockup { justify-content:center; }
  .developer-lockup img { width:86px !important; height:52px !important; min-width:86px; }
  .login-card-brand > img { width:62px !important; height:38px !important; min-width:62px; }
  .login-facility-logos img { width:32px !important; height:32px !important; }
  .permission-module-body { grid-template-columns:1fr; }
  .role-detail-head { display:grid; }
  .dashboard-config-row { grid-template-columns:24px 1fr; align-items:start; }
  .dashboard-config-row > * { grid-column:2 !important; }
  .dashboard-config-row > .drag-handle { grid-column:1 !important; grid-row:1 / span 5; }
  .live-support-button span { display:none; }
  .live-support-button { width:52px; height:52px; justify-content:center; padding:0; }
  .workspace-command-hero { padding:22px; min-height:0; }
  .workspace-hero-metrics article { min-width:74px; flex:1; }
  .workspace-record-grid,.information-hub-grid,.record-detail-list,.submission-status-grid,.checkbox-grid,.audience-columns { grid-template-columns:1fr; }
  .workspace-studio .panel-header,.workspace-file-list > article,.workspace-record-banner { align-items:stretch; display:grid; }
  .workspace-studio .page-actions { display:grid; width:100%; }
  .workspace-studio .control { min-width:0; width:100%; }
  .workspace-paper { min-height:360px; padding:24px 18px; }
  .staff-report-identity,.staff-report-section-modal > header { display:grid; }
  .staff-assignment { min-width:0; justify-items:start; text-align:left; }
  .staff-profile-sections,.staff-profile-section dl { grid-template-columns:1fr; }
}
@media print {
  .page-header,.report-selector,.app-footer,.floating-chat { display:none !important; }
  .app-shell,.app-main,.content-scroll { display:block !important; overflow:visible !important; height:auto !important; }
  .content-scroll { padding:0 !important; }
  #generated-report { display:block !important; }
  .generated-report { border:0; box-shadow:none; }
  .printing-personal-document > *:not(.modal-backdrop) { display:none !important; }
  .printing-personal-document .modal-backdrop { position:static; display:block; background:#fff; padding:0; }
  .printing-personal-document .modal { width:100%; max-width:none; max-height:none; border:0; box-shadow:none; }
  .printing-personal-document .modal > header,.printing-personal-document .modal-footer { display:none; }
  .printing-personal-document .modal-body { overflow:visible; padding:0; }
}

/* My Info Hub events keep date, time and activity text in separate readable columns. */
.hub-calendar .hub-calendar-strip{display:grid!important;grid-template-columns:repeat(auto-fit,minmax(300px,1fr))!important;gap:12px!important;max-height:360px;overflow:auto;padding:16px!important;scrollbar-gutter:stable}
.hub-calendar .hub-calendar-item{display:grid!important;grid-template-columns:6px 94px minmax(0,1fr)!important;gap:14px;align-items:center;min-width:0;min-height:86px;padding:13px 15px;border:1px solid var(--border);border-radius:15px;background:var(--surface);color:var(--text);text-align:left;cursor:pointer;overflow:hidden}
.hub-calendar .hub-calendar-item>i{display:block;width:6px;height:100%;min-height:56px;border-radius:999px;background:var(--event-colour)}
.hub-calendar .hub-calendar-item>time{display:flex!important;flex-direction:column;gap:5px;min-width:0;font-style:normal;font-size:14px;line-height:1.2;white-space:nowrap}
.hub-calendar .hub-calendar-item>time span{font-size:12px;color:var(--muted)}
.hub-calendar .hub-calendar-item>span{display:flex!important;flex-direction:column;gap:7px;min-width:0}
.hub-calendar .hub-calendar-item>span strong{display:block;white-space:normal!important;overflow:visible!important;text-overflow:clip!important;overflow-wrap:anywhere;line-height:1.3;font-size:15px}
.hub-calendar .hub-calendar-item>span small{display:block;white-space:normal;overflow-wrap:anywhere;color:var(--muted);line-height:1.35}
@media(max-width:620px){.hub-calendar .hub-calendar-strip{grid-template-columns:1fr!important}.hub-calendar .hub-calendar-item{grid-template-columns:5px 82px minmax(0,1fr)!important}}
.renewal-window-callout{display:flex;align-items:center;justify-content:space-between;gap:14px;margin:0 0 16px;padding:14px 16px;border:1px solid color-mix(in srgb,var(--primary) 24%,var(--border));border-radius:15px;background:color-mix(in srgb,var(--primary) 7%,var(--surface))}.renewal-window-callout>div{display:flex;align-items:center;gap:12px;min-width:0}.renewal-window-callout .ui-icon{flex:none;width:24px;height:24px;color:var(--primary)}.renewal-window-callout span{display:grid;gap:4px;min-width:0}.renewal-window-callout small{color:var(--muted);overflow-wrap:anywhere}.timeline-item.timeline-reverted{opacity:.78}.timeline-item.timeline-reverted .timeline-dot{background:var(--danger)}

/* RichMail 7 keeps the mailbox fast and familiar while preserving numbered records. */
.gmail-toolbar{grid-template-columns:30px 38px minmax(210px,1fr) minmax(135px,auto) auto auto 36px 36px!important}.gmail-select-all{display:grid;place-items:center}.gmail-select-all input,.gmail-select{width:16px;height:16px;accent-color:var(--primary);cursor:pointer}.gmail-toolbar select{height:36px;max-width:170px;border:1px solid var(--border);border-radius:9px;background:var(--surface);color:var(--text);padding:0 9px}.gmail-row{grid-template-columns:24px 42px 27px minmax(145px,210px) minmax(240px,1fr) 145px!important;cursor:pointer}.gmail-select-placeholder{width:16px}.gmail-subject{display:grid!important;grid-template-columns:auto minmax(70px,1fr) auto}.gmail-subject em{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--muted);font-size:12px;font-style:normal}.gmail-subject em:not(:empty)::before{content:"— ";}.gmail-subject small{display:flex;align-items:center;gap:4px}.gmail-subject small .ui-icon{width:14px;height:14px}.gmail-row:focus-visible{outline:2px solid var(--primary);outline-offset:-2px}.gmail-local-draft .gmail-party,.gmail-local-draft .gmail-record-no{color:#b14d00}.mail-attachment{display:grid!important;grid-template-columns:34px minmax(0,1fr) auto}.mail-attachment-icon{display:grid;place-items:center;width:32px;height:32px;border-radius:9px;background:var(--background);color:var(--primary)}.mail-attachment>div{display:flex;gap:6px;flex-wrap:wrap}.mail-colour-tool{display:flex;align-items:center;gap:4px;min-height:32px;padding:4px 7px;border:1px solid var(--border);border-radius:7px;background:var(--surface);font-weight:850}.mail-colour-tool input[type=color]{width:22px!important;height:22px!important;border:0!important;padding:0}.gmail-editor blockquote{margin:14px 0;padding:8px 14px;border-left:3px solid var(--border);color:var(--muted)}

/* Governed work modules. */
.audience-summary{display:flex;flex-wrap:wrap;gap:10px;align-items:center}
.compact-stats{grid-template-columns:repeat(4,minmax(0,1fr))}.task-grid{grid-template-columns:repeat(auto-fit,minmax(290px,1fr))}.task-progress,.table-progress{height:8px;overflow:hidden;border-radius:999px;background:var(--background)}.task-progress span,.table-progress span{display:block;height:100%;border-radius:inherit;background:linear-gradient(90deg,var(--primary),var(--accent))}.task-detail-hero{display:grid;grid-template-columns:minmax(0,1.5fr) minmax(300px,1fr);gap:18px;margin-bottom:18px;padding:22px;border:1px solid var(--border);border-radius:19px;background:linear-gradient(135deg,color-mix(in srgb,var(--primary) 7%,var(--surface)),var(--surface))}.task-detail-hero p{font-size:15px;line-height:1.65}.task-detail-hero dl{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:0}.task-detail-hero dl>div,.record-summary>div{display:grid;align-content:start;gap:5px;padding:12px;border:1px solid var(--border);border-radius:12px;background:color-mix(in srgb,var(--surface) 90%,transparent)}.task-detail-hero dt,.record-summary>div>span{color:var(--muted);font-size:10px;font-weight:850;text-transform:uppercase}.task-detail-hero dd{margin:0;font-weight:750}.record-summary{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:11px;margin-bottom:18px}.record-summary>div strong{font-size:15px}.record-summary>div small{color:var(--muted)}.department-form-sections{display:grid;grid-template-columns:repeat(auto-fit,minmax(260px,1fr));gap:12px}.department-form-section{display:grid;align-content:start;gap:12px;padding:16px;border:1px solid var(--border);border-radius:15px}.department-form-section>header{display:flex;align-items:flex-start;justify-content:space-between;gap:10px}.department-form-section>header>div{display:grid;grid-template-columns:auto 1fr;gap:5px 9px}.department-form-section h3,.department-form-section p{margin:0}.department-form-section p{grid-column:2;color:var(--muted);font-size:12px}.department-contributors{display:flex;flex-wrap:wrap;gap:6px}.department-contributors span{padding:5px 8px;border-radius:999px;background:var(--background);font-size:10px}.record-accordion{border:1px solid var(--border);border-radius:13px;overflow:hidden}.record-accordion summary{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:13px 15px;cursor:pointer;font-weight:750}.record-accordion-body{padding:0 14px 14px}.department-operations-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;margin-top:18px}.department-operations-grid>.panel{min-width:0}.department-operations-grid>.panel:last-child{grid-column:1/-1}
@media(max-width:1050px){.gmail-toolbar{grid-template-columns:30px 38px minmax(160px,1fr) auto auto 36px 36px!important}.gmail-toolbar>span{display:none}.gmail-row{grid-template-columns:22px 36px 24px minmax(110px,160px) minmax(180px,1fr) 100px!important}.compact-stats,.record-summary{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){.gmail-toolbar{grid-template-columns:28px 36px minmax(120px,1fr) 36px 36px!important}.gmail-toolbar select,.gmail-toolbar #mail-apply-action{display:none}.gmail-row{grid-template-columns:20px 34px minmax(0,1fr) 82px!important;min-height:74px}.gmail-state{display:none}.gmail-party{grid-column:3}.gmail-subject{grid-column:3;grid-template-columns:minmax(0,1fr) auto}.gmail-subject em{display:none}.gmail-row time{grid-column:4;grid-row:1}.gmail-record-no{grid-row:1/3}.gmail-select,.gmail-select-placeholder{grid-row:1/3}.task-detail-hero,.department-operations-grid{grid-template-columns:1fr}.department-operations-grid>.panel:last-child{grid-column:auto}.task-detail-hero dl{grid-template-columns:1fr}.compact-stats,.record-summary{grid-template-columns:1fr 1fr}}

/* Bidirectional mailbox flags and spam actions. */
.gmail-row{grid-template-columns:24px 28px 42px 27px minmax(145px,210px) minmax(240px,1fr) 145px!important}.gmail-star,.gmail-star-placeholder{width:25px;height:25px}.gmail-star{display:grid;place-items:center;border:0;border-radius:50%;background:transparent;color:#79818d;font-size:20px;line-height:1;cursor:pointer}.gmail-star:hover{background:var(--background);color:#d29b00}.gmail-star.flagged{color:#e2aa08}
@media(max-width:1050px){.gmail-row{grid-template-columns:22px 26px 36px 24px minmax(110px,160px) minmax(180px,1fr) 100px!important}}
@media(max-width:760px){.gmail-row{grid-template-columns:20px 34px minmax(0,1fr) 82px!important}.gmail-star,.gmail-star-placeholder{display:none}.gmail-party,.gmail-subject{grid-column:3}.gmail-row time{grid-column:4}.gmail-record-no{grid-column:2}}

/* Dynamic budgets remain readable on screen and translate directly into legal copies. */
.budget-document-preview{display:grid;gap:16px;margin:18px 0}.budget-section{margin:0}.budget-table-editor{min-width:0;border:1px solid var(--border);border-radius:14px;overflow:hidden}.budget-table-editor>header{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:12px 14px;background:var(--background)}.budget-table-editor>header>div{display:grid;gap:3px}.budget-table-editor input{min-width:110px;width:100%;padding:9px;border:1px solid var(--border);border-radius:8px;background:var(--surface);color:var(--text)}.budget-schema-section{display:grid;gap:12px;padding:14px;border:1px solid var(--border);border-radius:14px;background:var(--background)}.budget-schema-section>header{display:grid;grid-template-columns:minmax(0,1fr) 38px;gap:10px}.budget-schema-section>header>input{font-weight:800}.budget-schema-fields{display:grid;gap:9px}.budget-schema-field{display:grid;grid-template-columns:minmax(130px,1.4fr) minmax(110px,1fr) 130px 130px auto minmax(190px,1.5fr) 38px;gap:8px;align-items:start}.budget-schema-field input,.budget-schema-field select,.budget-schema-field textarea,.budget-schema-section>header>input{width:100%;min-height:39px;padding:8px 10px;border:1px solid var(--border);border-radius:9px;background:var(--surface);color:var(--text)}.budget-schema-field textarea{min-height:70px;resize:vertical}.budget-schema-field>label{display:flex;align-items:center;gap:6px;min-height:39px;font-size:12px}.stat-text{font-size:17px!important;line-height:1.25}.readable-copy{font-size:15px;line-height:1.7}

/* RichCall uses a compact hospital directory and responsive media grid. */
.richcall-availability{display:flex;align-items:center;gap:8px;font-size:12px;font-weight:750}.richcall-availability select{padding:8px 10px;border:1px solid var(--border);border-radius:9px;background:var(--surface);color:var(--text)}.richcall-directory{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:10px;padding:16px}.richcall-person{display:grid;grid-template-columns:20px 12px minmax(0,1fr) auto auto;align-items:center;gap:10px;padding:13px;border:1px solid var(--border);border-radius:13px;background:var(--surface);cursor:pointer}.richcall-person:has(input:checked){border-color:var(--primary);box-shadow:0 0 0 2px color-mix(in srgb,var(--primary) 18%,transparent)}.richcall-person input{width:17px;height:17px;accent-color:var(--primary)}.richcall-person>div{display:grid;gap:4px;min-width:0}.richcall-person small,.richcall-person>span:last-child{color:var(--muted);font-size:11px;overflow-wrap:anywhere}.presence-dot{width:10px;height:10px;border-radius:50%;background:#9da5a1;box-shadow:0 0 0 3px color-mix(in srgb,#9da5a1 15%,transparent)}.presence-available{background:#14a66a}.presence-busy,.presence-in_call{background:#ca304e}.presence-away{background:#e2a621}.presence-in_meeting{background:#7258d6}.richcall-ringing{display:grid;justify-items:center;gap:8px;padding:22px;text-align:center;background:var(--call-background,#0f172a);color:#fff;border-radius:14px}.richcall-avatar{display:grid;place-items:center;width:88px;height:88px;border-radius:50%;background:rgba(255,255,255,.13);color:#fff;animation:richcall-pulse 1.4s infinite}.richcall-avatar .ui-icon{width:40px;height:40px}.richcall-ringing h2,.richcall-ringing p{margin:0}.richcall-session{display:grid;gap:14px}.richcall-session>header{display:flex;align-items:start;justify-content:space-between;gap:16px}.richcall-session>header h2{margin:6px 0}.richcall-session>header>div{min-width:0}.richcall-media-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:10px;min-height:300px;padding:10px;border-radius:17px;background:#071410}.richcall-video-tile{position:relative;display:grid;place-items:center;min-height:240px;overflow:hidden;border-radius:13px;background:#10251f}.richcall-video-tile video{width:100%;height:100%;min-height:240px;object-fit:cover}.richcall-video-tile audio{width:88%}.richcall-video-tile>span{position:absolute;left:10px;bottom:10px;padding:5px 8px;border-radius:8px;background:rgba(0,0,0,.62);color:#fff;font-size:12px}.richcall-video-tile.disconnected{opacity:.48}.richcall-privacy{display:flex;align-items:center;gap:8px;color:var(--muted);font-size:12px}.richcall-privacy .ui-icon{width:18px;height:18px;flex:none}@keyframes richcall-pulse{50%{box-shadow:0 0 0 18px color-mix(in srgb,var(--primary) 0%,transparent)}}

.richlibrary-surface{background:var(--richlibrary-background,var(--background));padding:18px;border-radius:var(--radius);min-height:calc(100vh - 150px)}.library-card.publication-disabled{background:color-mix(in srgb,var(--surface) 88%,var(--muted) 12%);border-style:dashed}.library-card.publication-disabled>h2,.library-card.publication-disabled>p{color:var(--muted)}
@media(max-width:1100px){.budget-schema-field{grid-template-columns:repeat(2,minmax(0,1fr))}.budget-schema-field textarea{grid-column:1/-1}.budget-schema-field>.icon-button{grid-column:2;justify-self:end}}
@media(max-width:650px){.budget-schema-field{grid-template-columns:1fr}.budget-schema-field textarea,.budget-schema-field>.icon-button{grid-column:auto}.richcall-directory{grid-template-columns:1fr}.richcall-person{grid-template-columns:20px 12px minmax(0,1fr)}.richcall-person>span:last-child{grid-column:3}.richcall-media-grid{grid-template-columns:1fr}.richcall-session>header{display:grid}}

/* RichFlow 9.1 responsive record tools and dynamic annual-report studio. */
.next-holiday-card{display:grid;grid-template-columns:46px minmax(0,1fr) auto;align-items:center;gap:14px;margin:0 0 18px;padding:16px 18px;border:1px solid color-mix(in srgb,var(--secondary) 38%,var(--border));border-radius:17px;background:linear-gradient(120deg,color-mix(in srgb,var(--secondary) 13%,var(--surface)),var(--surface));box-shadow:0 8px 24px rgba(26,48,39,.06)}.next-holiday-card>span{display:grid;place-items:center;width:46px;height:46px;border-radius:14px;background:var(--secondary);color:#1d2a25}.next-holiday-card>span .ui-icon{width:24px;height:24px}.next-holiday-card>div{display:grid;gap:3px;min-width:0}.next-holiday-card small{color:var(--muted);font-weight:750;text-transform:uppercase;letter-spacing:.04em}.next-holiday-card strong{font-size:17px;overflow-wrap:anywhere}.next-holiday-card p{margin:0;color:var(--muted);font-size:12px}
.selection-chip{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 12px;border:1px solid var(--border);border-radius:12px;background:var(--surface)}.selection-chip>span{display:grid;gap:3px;min-width:0}.selection-chip strong,.selection-chip small{overflow-wrap:anywhere}.selection-chip small{color:var(--muted)}
.staff-record-detail>td{padding:0!important;background:color-mix(in srgb,var(--primary) 3%,var(--surface))}.record-inline-details{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:10px;margin:0;padding:14px 16px}.record-inline-details>div{display:grid;gap:4px;min-width:0}.record-inline-details dt{color:var(--muted);font-size:10px;font-weight:850;text-transform:uppercase;letter-spacing:.04em}.record-inline-details dd{margin:0;overflow-wrap:anywhere}
.annual-report-blocks{display:grid;gap:13px}.annual-report-block{display:grid;gap:14px;padding:15px;border:1px solid var(--border);border-radius:15px;background:var(--surface);box-shadow:0 5px 16px rgba(21,46,37,.04);cursor:grab}.annual-report-block:active{cursor:grabbing}.annual-report-block.dragging{opacity:.45;border-style:dashed}.annual-report-block>header{display:flex;align-items:center;justify-content:space-between;gap:12px;padding-bottom:11px;border-bottom:1px solid var(--border)}.annual-report-block>header>div:first-child{display:flex;align-items:center;gap:9px}.annual-report-block .record-sequence{display:grid;place-items:center;width:28px;height:28px;border-radius:50%;background:var(--primary);color:#fff;font-size:11px;font-weight:900}.annual-image-preview{min-height:0}.annual-image-preview img{display:block;max-width:min(100%,720px);max-height:420px;margin:auto;border:1px solid var(--border);border-radius:12px;object-fit:contain;background:var(--background)}
.data-table th,.data-table td{overflow-wrap:anywhere;word-break:normal}.data-table td::before,.data-table td::after{pointer-events:none}
.data-table td:has(.table-actions),.data-table td:has(> .btn){min-width:max-content}.data-table .btn{overflow-wrap:normal;word-break:keep-all;white-space:nowrap}.table-actions{flex-wrap:wrap;min-width:max-content}
@media(max-width:650px){.next-holiday-card{grid-template-columns:42px minmax(0,1fr)}.next-holiday-card>button{grid-column:1/-1;width:100%}.annual-report-block>header{align-items:flex-start}.annual-report-block>header .table-actions{justify-content:flex-end}.record-inline-details{grid-template-columns:1fr 1fr}}
@media(max-width:430px){.record-inline-details{grid-template-columns:1fr}.annual-report-block>header{display:grid}.annual-report-block>header .table-actions{justify-content:flex-start}}
@media print{.data-table thead th{position:static!important}.data-table tr,.data-table td,.data-table th{break-inside:avoid;page-break-inside:avoid}.data-table td,.data-table th{line-height:1.45!important;padding-top:8px!important;padding-bottom:8px!important}.table-wrap{overflow:visible!important;border-color:#cbd5d1!important}.annual-report-block{break-inside:avoid;box-shadow:none}}
.communication-launcher-restore{position:fixed;right:0;bottom:92px;z-index:999;border:0;border-radius:14px 0 0 14px;padding:12px 10px;background:var(--primary,#0b6655);color:#fff;box-shadow:0 8px 24px #0003;cursor:pointer}.communication-launcher-restore svg{width:22px;height:22px}
.universal-data-tools{display:flex;gap:8px;align-items:end;flex-wrap:wrap;padding:12px 14px;background:#f7faf9;border:1px solid var(--border);border-bottom:0;border-radius:12px 12px 0 0}.universal-data-tools label{display:flex;align-items:center;gap:6px;font-size:12px;font-weight:700}.universal-data-tools .ui-icon{width:17px!important;height:17px!important;flex:0 0 17px}.universal-data-tools input{min-height:36px;padding:7px 9px;border:1px solid var(--border);border-radius:8px;background:#fff}.universal-data-tools label:first-child{flex:1;min-width:230px}.universal-data-tools label:first-child input{width:100%}.universal-data-tools button{display:inline-flex;align-items:center;gap:5px;min-height:36px;border:1px solid var(--border);border-radius:8px;padding:7px 10px;background:#fff;color:var(--primary);font-weight:800;white-space:nowrap}.universal-data-count{margin-left:auto;color:var(--muted);font-size:12px}.native-multiselect{position:absolute!important;width:1px!important;height:1px!important;opacity:0!important;pointer-events:none!important}.checkbox-multiselect{display:grid;gap:8px;padding:10px;border:1px solid var(--border);border-radius:11px;background:var(--surface)}.checkbox-multiselect-search{min-height:36px!important;padding:7px 9px!important}.checkbox-multiselect-options{display:grid;gap:4px;max-height:210px;overflow:auto;overscroll-behavior:contain}.checkbox-multiselect-option{display:flex;align-items:flex-start;gap:9px;padding:8px 9px;border-radius:8px;cursor:pointer;font-weight:600}.checkbox-multiselect-option:hover,.checkbox-multiselect-option:has(input:checked){background:color-mix(in srgb,var(--primary) 8%,var(--surface))}.checkbox-multiselect-option input{width:17px!important;height:17px!important;min-height:0!important;margin:2px 0 0;padding:0!important;accent-color:var(--primary)}.checkbox-multiselect-summary{color:var(--muted);font-size:12px}.checkbox-multiselect.is-disabled{opacity:.6;pointer-events:none}@media(max-width:700px){.universal-data-tools label:first-child{flex-basis:100%}.universal-data-count{margin-left:0}.btn{white-space:normal}.table-actions .btn,.data-table .btn{white-space:nowrap}}
.searchable-select{display:grid;width:100%;border:1px solid var(--border);border-radius:10px;overflow:hidden;background:var(--surface)}.searchable-select-input,.searchable-select select{width:100%!important;border:0!important;border-radius:0!important;box-shadow:none!important}.searchable-select-input{min-height:34px!important;padding:6px 10px!important;background:color-mix(in srgb,var(--surface) 92%,var(--background));border-bottom:1px solid var(--border)!important;font-size:12px!important}.searchable-select select{min-height:42px}.searchable-select:focus-within{border-color:var(--primary);box-shadow:0 0 0 3px color-mix(in srgb,var(--primary) 14%,transparent)}.searchable-select.has-filter select{background:color-mix(in srgb,var(--primary) 3%,var(--surface))}

/* RichFlow 10.2 decision reports and equipment-inspection workbench. */
.management-report{display:grid;gap:18px}.management-report-header{display:grid;gap:7px;padding:22px 24px;border:1px solid var(--border);border-radius:18px;background:linear-gradient(125deg,color-mix(in srgb,var(--primary) 8%,var(--surface)),var(--surface))}.management-report-header h2,.management-report-header p{margin:0}.management-report-header p,.management-report-header small{color:var(--muted)}.report-analysis-grid{align-items:stretch}.decision-list{display:grid;gap:12px;margin:0;padding-left:22px;line-height:1.55}.decision-list li{padding-left:5px}.action-list li::marker{color:var(--primary);font-weight:900}.inspection-template-item,.inspection-run-item{padding:13px;border:1px solid var(--border);border-radius:13px;background:color-mix(in srgb,var(--surface) 94%,var(--background))}.inspection-run-item{display:grid;grid-template-columns:minmax(220px,1.5fr) minmax(180px,1fr);gap:12px}.inspection-template-item+.inspection-template-item,.inspection-run-item+.inspection-run-item{margin-top:10px}
@media(max-width:760px){.inspection-run-item{grid-template-columns:1fr}.management-report-header{padding:18px}.report-analysis-grid{grid-template-columns:1fr}}
@media print{.management-report{gap:12px}.management-report-header{border:0;padding:0 0 14px;background:#fff}.management-report .panel,.management-report .stat-card{box-shadow:none}.management-report .compact-field{display:none}.management-report .bounded-records{max-height:none!important;overflow:visible!important}.decision-list{font-size:11pt}}
