/* Liquid Glass material only: preserve the existing blue palette, layout and motion. */
@media screen{
 html body #main :is(.box,.stat,.decision-panel,.memo-box,.finance-nav,.forecast-project),html body #director-brief.brief-ocean :is(.brief-kpi,.brief-section),html body :is(.sidebar,.workspace .topbar,.memo-dialog){background:linear-gradient(135deg,#ffffff21,#ffffff02 48%,#ffffff09),#102d4d45!important;border-color:var(--o-line)!important;box-shadow:var(--o-shadow)!important;backdrop-filter:blur(32px) saturate(115%);-webkit-backdrop-filter:blur(32px) saturate(115%)}
 html body :is(.sidebar,.workspace .topbar,.memo-dialog){background:linear-gradient(135deg,#ffffff20,#ffffff02 48%,#ffffff09),#102d4d66!important}
 html[data-theme=light] body #main :is(.box,.stat,.decision-panel,.memo-box,.finance-nav,.forecast-project),html[data-theme=light] body #director-brief.brief-ocean :is(.brief-kpi,.brief-section){background:linear-gradient(135deg,#ffffff92,#ffffff20 48%,#ffffff50),#f5faff35!important}
 html[data-theme=light] body :is(.sidebar,.workspace .topbar){background:linear-gradient(135deg,#ffffffa0,#ffffff25),#f5faff40!important}
 html body .memo-dialog{background:linear-gradient(135deg,#ffffff20,#ffffff05),#12345499!important}
 html[data-theme=light] body .memo-dialog{background:linear-gradient(135deg,#ffffffad,#ffffff36),#f7faff85!important}
 html body dialog::backdrop{background:#071b3430;backdrop-filter:blur(9px);-webkit-backdrop-filter:blur(9px)}
 html body .button.secondary,html body .workspace #director-brief.brief-ocean .button.secondary{background:var(--o-secondary)!important;border-color:var(--o-input-border)!important;color:var(--o-secondary-ink)!important;box-shadow:inset 0 1px 0 #ffffff6b,0 3px 9px #001c3c14!important}
 html body .button.primary{background:var(--o-primary)!important;color:#fff!important;border-color:#ffffff6b!important;box-shadow:inset 0 1px 0 #ffffff78,0 4px 12px #06458028!important}
 html body .sidebar nav a.active,html body .sidebar .navigation-group a.active{background:var(--o-secondary)!important;color:var(--o-ink)!important;border-color:var(--o-line)!important;box-shadow:inset 0 1px 0 #ffffff70,0 4px 12px #001a3619!important}
 html body .sidebar .brand-icon,html body #director-brief.brief-ocean .brief-icon{background:var(--o-primary)!important;box-shadow:inset 0 1px 0 #ffffff80,0 5px 15px #00244c26!important}
 html body .workspace #director-brief.brief-ocean{--brief-text:var(--o-ink);--brief-muted:var(--o-muted);--brief-border:var(--o-line);--brief-accent:var(--o-accent);--brief-glass:var(--o-glass);--brief-shadow:var(--o-shadow)}
 html body #director-brief.brief-ocean .brief-hero{background:radial-gradient(ellipse at 90% 80%,#c2e7ff1c,transparent 68%),linear-gradient(135deg,#ffffff21,#ffffff02 48%,#ffffff09),#102d4d45!important}
 html body #director-brief.brief-ocean :is(.brief-list,.brief-plan-footer,.brief-plan-bottom,.brief-count,.brief-attention-count,.brief-period){background:var(--o-secondary)!important;color:var(--o-ink)!important;border-color:var(--o-input-border)!important}
 html body #director-brief.brief-ocean select{background:var(--o-field)!important;color:var(--o-ink)!important;border-color:var(--o-input-border)!important}
 html body .workspace .stat.blue{border-top-color:var(--o-line)!important}
 html body :is(.dialog-head,.dialog-actions,.compact-operation-footer){background:var(--o-table)!important}
 html body :is(button,a,summary,input,textarea,select):focus-visible{outline-color:#72c6ff!important}
 @supports not (backdrop-filter:blur(1px)){
  html body #main :is(.box,.stat),html body :is(.sidebar,.memo-dialog){background:#163351!important}
  html[data-theme=light] body #main :is(.box,.stat),html[data-theme=light] body :is(.sidebar,.memo-dialog){background:#f7faff!important}
 }
}
/* Clear glass reference: thin edge, low tint, visible background through the surface. */
@media screen{
 html:not([data-theme=light]) body,html:not([data-theme=light]) body:has(#director-brief.brief-ocean){background:radial-gradient(ellipse 80% 125% at 108% 4%,transparent 47%,#7babee26 48%,#c6e1ff40 48.4%,#2465ad26 49.4%,transparent 51%),radial-gradient(ellipse 95% 100% at 8% 110%,transparent 59%,#75b2ff24 60%,#3c83c71c 62%,transparent 65%),radial-gradient(ellipse at 53% 28%,#085abe57,transparent 58%),#07162e!important;background-attachment:fixed!important}
 html[data-theme=light] body{background:radial-gradient(ellipse 80% 125% at 108% 4%,transparent 47%,#89b5e73b 48%,#ffffffb3 48.4%,#b2d4f54d 49.4%,transparent 51%),radial-gradient(ellipse 95% 100% at 8% 110%,transparent 59%,#90bde72b 60%,#ffffff80 62%,transparent 65%),radial-gradient(ellipse at 53% 28%,#a7cef559,transparent 58%),#edf5fd!important;background-attachment:fixed!important}
 html body #main :is(.box,.stat,.decision-panel,.memo-box,.finance-nav,.forecast-project),html body .workspace #director-brief.brief-ocean :is(.box,.brief-kpi,.brief-section,.brief-hero){background:linear-gradient(140deg,#ffffff12,transparent 40%,#ffffff03 70%,#c9e8ff08),#0a213d12!important;border-color:#d7efff52!important;box-shadow:inset 0 1px 0 #ffffffa1,inset 1px 0 0 #ffffff29,inset 0 -1px 0 #c8e8ff47,0 16px 38px #000e2824!important;backdrop-filter:blur(18px) saturate(120%);-webkit-backdrop-filter:blur(18px) saturate(120%)}
 html[data-theme=light] body #main :is(.box,.stat,.decision-panel,.memo-box,.finance-nav,.forecast-project),html[data-theme=light] body .workspace #director-brief.brief-ocean :is(.box,.brief-kpi,.brief-section,.brief-hero){background:linear-gradient(140deg,#ffffff4a,#ffffff08 45%,#ffffff1a),#f9fcff14!important;border-color:#ffffffba!important;box-shadow:inset 0 1px 0 #fff,inset 1px 0 0 #ffffff66,inset 0 -1px 0 #ffffffad,0 16px 38px #22456317!important}
 html body:has(#director-brief.brief-ocean) :is(.sidebar,.workspace .topbar),html body :is(.sidebar,.workspace .topbar){background:linear-gradient(140deg,#ffffff13,transparent 45%,#ffffff05),#0a213d35!important;border-color:#d7efff52!important;backdrop-filter:blur(22px) saturate(120%);-webkit-backdrop-filter:blur(22px) saturate(120%)}
 html[data-theme=light] body:has(#director-brief.brief-ocean) :is(.sidebar,.workspace .topbar),html[data-theme=light] body :is(.sidebar,.workspace .topbar){background:linear-gradient(140deg,#ffffff45,#ffffff0c 45%,#ffffff1c),#f9fcff22!important}
 html body .memo-dialog{background:linear-gradient(140deg,#ffffff21,#ffffff04 45%,#ffffff0a),#0a213d66!important;backdrop-filter:blur(30px) saturate(120%);-webkit-backdrop-filter:blur(30px) saturate(120%)}
 html[data-theme=light] body .memo-dialog{background:linear-gradient(140deg,#ffffff75,#ffffff12 45%,#ffffff26),#f9fcff4d!important}
 html body .workspace #director-brief.brief-ocean .brief-kpi::before{background:linear-gradient(125deg,#efffff8c,#8fd8ff14 28%,#ffffff00 49%,#98d7ff29 76%,#e8ffff66)!important}
}
@media(prefers-reduced-transparency:reduce){html body #main :is(.box,.stat),html body .workspace #director-brief.brief-ocean :is(.box,.brief-kpi),html body :is(.sidebar,.workspace .topbar,.memo-dialog){background:#102d4b!important;backdrop-filter:none;-webkit-backdrop-filter:none}html[data-theme=light] body #main :is(.box,.stat),html[data-theme=light] body .workspace #director-brief.brief-ocean :is(.box,.brief-kpi),html[data-theme=light] body :is(.sidebar,.workspace .topbar,.memo-dialog){background:#f7faff!important}}

/* CRM emblem: prismatic glass ring. Scoped to the brand, never other buttons. */
html body .sidebar .brand .brand-icon.crm-brand-glass,
html body:has(#director-brief.brief-ocean) .sidebar .brand .brand-icon.crm-brand-glass{
 position:relative;isolation:isolate;display:grid;place-items:center;flex:0 0 40px;width:40px;height:40px;overflow:hidden;border-radius:50%;
 background:radial-gradient(ellipse at 29% 15%,#ffffff29,transparent 52%),linear-gradient(145deg,#24466fcc,#071a38e8)!important;
 border:1px solid #b8c7de45;box-shadow:inset 0 1px 0 #ffffff70,inset 0 -1px 0 #000b195e,0 3px 10px #000b2947,0 0 0 3px #b4d4ff0b!important;
 backdrop-filter:blur(14px);-webkit-backdrop-filter:blur(14px);
}
.crm-brand-glass::before{content:"";position:absolute;inset:2px;border-radius:50%;padding:2px;pointer-events:none;
 background:conic-gradient(from 8deg,#f5fdff 0deg,#9bdcff 15deg,#3aa8ff 29deg,#0b255d85 48deg,#2061db 69deg,#8ee3ff 81deg,#fff 88deg,#328cff 105deg,#10295c80 132deg,#285ee5 152deg,#b9efff 169deg,#f6fdff 178deg,#10295480 204deg,#2b77ef 231deg,#9ee5ff 246deg,#fff 253deg,#398dff 271deg,#0e255480 297deg,#2568df 318deg,#b4eeff 338deg,#f5fdff 360deg);
 -webkit-mask:linear-gradient(#fff 0 0) content-box,linear-gradient(#fff 0 0);-webkit-mask-composite:xor;mask:linear-gradient(#fff 0 0) content-box,linear-gradient(#fff 0 0);mask-composite:exclude;
 filter:drop-shadow(0 0 2px #9dd5ff8c);animation:crm-brand-prism-turn 14s linear infinite;
}
.crm-brand-glass::after{content:"";position:absolute;inset:5px;border:1px solid #c7d6ec26;border-radius:50%;background:radial-gradient(ellipse at 30% 12%,#ffffff29,transparent 61%),linear-gradient(145deg,#ffffff03,#000a1a2b);box-shadow:inset 0 1px 1px #ffffff4d,inset 0 -2px 3px #000b2633;pointer-events:none}
.crm-brand-symbol{position:relative;z-index:1;width:24px;height:24px;filter:drop-shadow(0 1.5px 1px #00091e80);pointer-events:none}
html[data-theme=light] body .sidebar .brand .brand-icon.crm-brand-glass,
html[data-theme=light] body:has(#director-brief.brief-ocean) .sidebar .brand .brand-icon.crm-brand-glass{background:radial-gradient(ellipse at 29% 15%,#ffffff47,transparent 52%),linear-gradient(145deg,#497eacce,#123460ef)!important;border-color:#ffffffb3;box-shadow:inset 0 1px 0 #ffffffbd,0 3px 9px #2542642b,0 0 0 3px #8bb4e114!important}
.brand:hover .crm-brand-glass::before{filter:brightness(1.17) drop-shadow(0 0 2px #b4e2ff)}
@keyframes crm-brand-prism-turn{to{transform:rotate(360deg)}}
@media(prefers-reduced-motion:reduce){.crm-brand-glass::before{animation:none}}
@media print{.crm-brand-glass::before{animation:none}}

/* Blue glossy glass: material and colour only; no layout, workflow or reveal timing. */
@media screen{
 html body #main :is(.box,.stat,.decision-panel,.memo-box,.finance-nav,.forecast-project),html body .workspace #director-brief.brief-ocean :is(.box,.brief-kpi,.brief-section,.brief-hero){
  background:radial-gradient(ellipse at 8% -12%,#d9f2ff1a,transparent 57%),linear-gradient(132deg,#0a2c5810,#438fdf08 58%,#96d9ff0e)!important;
  border-color:#c9e8ff57!important;box-shadow:inset 0 1px 0 #effaffb3,inset 1px 0 0 #b4deff30,inset 0 -1px 0 #83c9ff38,0 12px 30px #000f291f!important;
  backdrop-filter:blur(22px) saturate(130%);-webkit-backdrop-filter:blur(22px) saturate(130%);
 }
 html[data-theme=light] body #main :is(.box,.stat,.decision-panel,.memo-box,.finance-nav,.forecast-project),html[data-theme=light] body .workspace #director-brief.brief-ocean :is(.box,.brief-kpi,.brief-section,.brief-hero){
  background:radial-gradient(ellipse at 8% -12%,#ffffff7a,transparent 57%),linear-gradient(132deg,#ffffff33,#e0f2ff12 58%,#d3edff26)!important;
  border-color:#ffffffd1!important;box-shadow:inset 0 1px 0 #fff,inset 1px 0 0 #ffffff8c,inset 0 -1px 0 #bedfff66,0 12px 30px #22518a12!important;
 }
 html body :is(button.button.primary,a.button.primary),html body .workspace #director-brief.brief-ocean .button.primary{
  background:radial-gradient(ellipse at 24% -36%,#d5f4ff70,transparent 64%),linear-gradient(145deg,#133b7b 0%,#1265b5 59%,#1678c6 100%)!important;
  color:#fff!important;border-color:#afddffb3!important;box-shadow:inset 0 1px 0 #ecfaffd1,inset 1px 0 0 #b9eaff38,inset 0 -1px 0 #073b8157,0 5px 14px #0866bd24!important;
  backdrop-filter:blur(16px) saturate(135%);-webkit-backdrop-filter:blur(16px) saturate(135%);
 }
 html body :is(button.button.secondary,a.button.secondary),html body .workspace #director-brief.brief-ocean .button.secondary{
  background:radial-gradient(ellipse at 16% -38%,#dbf5ff38,transparent 65%),linear-gradient(140deg,#28599138,#6dbdff14)!important;
  color:#e3f3ff!important;border-color:#a9d5ff73!important;box-shadow:inset 0 1px 0 #e8faff8c,inset 0 -1px 0 #9bd8ff24,0 4px 12px #00162d17!important;
  backdrop-filter:blur(16px) saturate(125%);-webkit-backdrop-filter:blur(16px) saturate(125%);
 }
 html[data-theme=light] body :is(button.button.secondary,a.button.secondary),html[data-theme=light] body .workspace #director-brief.brief-ocean .button.secondary{
  background:radial-gradient(ellipse at 16% -38%,#ffffffd9,transparent 65%),linear-gradient(140deg,#ffffff80,#d9efff47)!important;
  color:#234f7b!important;border-color:#9bc8eb99!important;box-shadow:inset 0 1px 0 #fff,inset 0 -1px 0 #a9d5ed3b,0 4px 12px #1b55851a!important;
 }
 @media(hover:hover){html body :is(button.button.primary,a.button.primary):not(:disabled):hover{border-color:#e1f7ff!important;box-shadow:inset 0 1px 0 #fff,inset 1px 0 0 #b9eaff52,0 5px 17px #2d9ce845!important}html body :is(button.button.secondary,a.button.secondary):not(:disabled):hover{border-color:#a3dcff!important}}
}
@media(prefers-reduced-transparency:reduce){
 html body #main :is(.box,.stat),html body .workspace #director-brief.brief-ocean :is(.box,.brief-kpi){background:#102d4b!important;backdrop-filter:none;-webkit-backdrop-filter:none}
 html[data-theme=light] body #main :is(.box,.stat),html[data-theme=light] body .workspace #director-brief.brief-ocean :is(.box,.brief-kpi){background:#f7faff!important}
 html body :is(button.button,a.button){backdrop-filter:none;-webkit-backdrop-filter:none}
}
@media screen{
 html[data-theme=light] body :is(button.button.primary,a.button.primary),html[data-theme=light] body .workspace #director-brief.brief-ocean .button.primary{background:radial-gradient(ellipse at 24% -36%,#d5f4ff70,transparent 64%),linear-gradient(145deg,#133b7b 0%,#1265b5 59%,#1678c6 100%)!important;color:#fff!important;border-color:#afddffb3!important;box-shadow:inset 0 1px 0 #ecfaffd1,inset 1px 0 0 #b9eaff38,inset 0 -1px 0 #073b8157,0 5px 14px #0866bd24!important}
 html body :is(#memo-dialog,dialog.memo-dialog):not(.rko-sign-dialog){background:radial-gradient(ellipse at 6% 0%,#d2eeff26,transparent 58%),linear-gradient(136deg,#0c2c586b,#3f8acf24),#071b354d!important;border-color:#bfdefd80!important;box-shadow:inset 0 1px 0 #effaffbd,inset 1px 0 0 #a6d5ff3b,0 14px 38px #000f2933!important;backdrop-filter:blur(30px) saturate(130%);-webkit-backdrop-filter:blur(30px) saturate(130%)}
 html[data-theme=light] body :is(#memo-dialog,dialog.memo-dialog):not(.rko-sign-dialog){background:radial-gradient(ellipse at 6% 0%,#ffffffb3,transparent 58%),linear-gradient(136deg,#ffffff80,#d9efff40),#f5faff45!important;border-color:#fffffff0!important;box-shadow:inset 0 1px 0 #fff,inset 1px 0 0 #ffffffa6,0 14px 38px #22518a1f!important}
 html body #memo-dialog:not(.compact-operation-drawer):not(.request-editor)>:is(.dialog-head,.dialog-actions){background:transparent!important}
}
@media(prefers-reduced-transparency:reduce){html body :is(#memo-dialog,dialog.memo-dialog):not(.rko-sign-dialog){background:#102d4b!important;backdrop-filter:none;-webkit-backdrop-filter:none}html[data-theme=light] body :is(#memo-dialog,dialog.memo-dialog):not(.rko-sign-dialog){background:#f7faff!important}}
@media screen{
 html[data-theme=light] body :is(button,a).button.primary:not(.brand-icon){background:radial-gradient(ellipse at 24% -36%,#d5f4ff70,transparent 64%),linear-gradient(145deg,#133b7b 0%,#1265b5 59%,#1678c6 100%)!important;color:#fff!important;border-color:#afddffb3!important;box-shadow:inset 0 1px 0 #ecfaffd1,inset 1px 0 0 #b9eaff38,inset 0 -1px 0 #073b8157,0 5px 14px #0866bd24!important}
 html[data-theme=light] body :is(button,a).button.secondary:not(.brand-icon){background:radial-gradient(ellipse at 16% -38%,#ffffffd9,transparent 65%),linear-gradient(140deg,#ffffff80,#d9efff47)!important;color:#234f7b!important;border-color:#9bc8eb99!important;box-shadow:inset 0 1px 0 #fff,inset 0 -1px 0 #a9d5ed3b,0 4px 12px #1b55851a!important}
}

/* Readable signed-in identity on light glass; keep the existing mobile visibility rules. */
@media screen{
 html[data-theme=light] body .topbar .profile #avatar{color:#173e69!important;background:#e8f2ff!important;border:1px solid #8eafcf;box-shadow:inset 0 1px 0 #fff,0 2px 6px #183d6512;font-size:13px;font-weight:750;line-height:1;letter-spacing:0;text-shadow:none}
 html[data-theme=light] body .topbar .profile #user-name{color:#172f4c!important;text-shadow:none}
 html[data-theme=light] body .topbar .profile #user-role{color:#40566f!important;font-size:11px;text-shadow:none}
}

/* Readable type, without scaling the workspace or changing grid/dialog widths. */
@media screen {
  html body { font-size:17px; }
  html body :is(table,.compact-operation-table,.dividend-table,.payroll-detail-table,.budget-sheet table) { font-size:15px; }
  html body :is(table th,.compact-operation-table th,.payroll-detail-table th) { font-size:13px; }
  html body :is(table td,.compact-operation-table td,.budget-sheet .budget-value,.budget-sheet .budget-project-link) { font-size:15px; }
  html body :is(.cell-sub,.helper,.subheading,.stat-label,.stat-meta,.budget-status,.operation-status,.agency-status,.finance-footnote,.finance-metric small,.finance-metric span,.finance-forecast,.instruction-article figcaption) { font-size:13px; }
  html body :is(.erp-toolbar label,.memo-filters label,.memo-form-grid label,dialog form>label,.form-pair label,.bank-journal-search) { font-size:14px; }
  html body :is(.button,.finance-nav .button,.table-export-tools button,.project-picker>summary,.counterparty-picker-trigger,.operation-date) { font-size:14px; }
  html body :is(input:not([type=checkbox]):not([type=radio]),select,textarea,.project-picker-menu,.counterparty-picker-panel) { font-size:16px; }
  html body :is(.sidebar nav>a,.sidebar nav .navigation-group a) { font-size:14px; }
  html body :is(#breadcrumb,.profile strong) { font-size:14px; }
  html body .profile :is(small,#user-role) { font-size:13px; }
  html body .sidebar .brand-sub { font-size:12px; }
  html body .num { font-variant-numeric:tabular-nums; white-space:nowrap; }
  /* Existing fixed columns and horizontal table scrolling remain in charge. */
  html body .director-account-balances { table-layout:fixed; }
  html body .director-account-balances th:last-child { width:30%; }
  html body .director-account-balances .account-group-total th { font-weight:700; }
}
@media screen and (min-width:1101px) {
  /* Keep desktop navigation in its original single row as type grows. */
  html body .finance-nav { flex-wrap:nowrap; overflow-x:auto; }
  html body .finance-nav>.button { flex:0 0 auto; }
}
