/* OneSync rescue visual layer: light blue, blue-gray, restrained orange. */
:root {
  color-scheme: light;

  --brand-blue: #2A6F94;
  --brand-blue-hover: #1E587A;
  --brand-blue-900: #13202E;
  --brand-blue-800: #2A6F94;
  --brand-blue-100: #D8EDF8;
  --brand-blue-075: #E8F3F9;
  --brand-blue-050: #F5FBFE;

  --brand-gray-950: #142033;
  --brand-gray-850: #26364f;
  --brand-gray-700: #40516b;
  --brand-gray-650: #5A6878;
  --brand-gray-500: #667892;
  --brand-gray-300: #aab8c9;
  --brand-gray-200: #d5dfeb;
  --brand-gray-100: #edf3fa;

  --brand-orange: #F37021;
  --brand-orange-hover: #C95714;
  --brand-orange-soft: rgba(243, 112, 33, 0.13);

  --surface-0: #eaf4ff;
  --surface-1: #f8fcff;
  --surface-2: #ffffff;
  --surface-3: #dcecff;
  --surface-4: #c9def6;
  --ink-1: var(--brand-gray-950);
  --ink-2: var(--brand-gray-850);
  --ink-3: var(--brand-gray-700);
  --ink-4: var(--brand-gray-500);

  --accent-one: var(--brand-blue);
  --accent-one-hover: var(--brand-blue-hover);
  --accent-sync: var(--brand-orange);
  --accent-sync-soft: var(--brand-orange-soft);
  --accent-primary: var(--brand-blue);
  --accent-primary-hover: var(--brand-blue-hover);
  --accent-secondary: var(--brand-orange);
  --accent-sage: #15803d;
  --accent-terracotta: var(--brand-orange);
  --accent-crimson: #c62828;
  --accent-smoke: #52677f;

  --line-1: rgba(42, 111, 148, 0.12);
  --line-2: rgba(42, 111, 148, 0.22);
  --line-3: rgba(42, 111, 148, 0.34);
  --line-gold: rgba(249, 115, 22, 0.48);
  --line: var(--line-1);

  --gold-1: var(--brand-blue);
  --gold-2: var(--brand-orange);
  --gold-3: var(--brand-orange-soft);
  --gold-ink: #ffffff;

  --bg: var(--surface-0);
  --bg-1: var(--surface-0);
  --bg-2: var(--surface-2);
  --bg-3: var(--surface-1);
  --text: var(--ink-1);
  --text-dim: var(--ink-2);
  --text-mute: var(--ink-3);
  --accent: var(--brand-blue);
  --accent-2: var(--brand-orange);
  --danger: var(--accent-crimson);
  --success: var(--accent-sage);
  --warn: var(--brand-orange);

  --color-primary: var(--brand-blue);
  --color-primary-dark: var(--brand-blue-hover);
  --color-primary-hover: var(--brand-blue-hover);
  --color-surface: var(--surface-2);
  --color-surface-alt: var(--surface-1);
  --color-border: var(--line-2);
  --color-text: var(--ink-1);
  --color-text-muted: var(--ink-4);

  --font-display: 'Geist', 'DM Sans', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
  --font-sans: 'DM Sans', 'Geist', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
  --font-data: 'Geist', ui-monospace, 'SF Mono', Menlo, Consolas, monospace;

  --shadow-1: 0 12px 28px rgba(20, 32, 51, 0.08);
  --shadow-2: 0 18px 42px rgba(20, 32, 51, 0.12);
  --shadow-pop: 0 28px 72px rgba(20, 32, 51, 0.22);
  --r-1: 6px;
  --r-2: 8px;
  --r-3: 8px;
  --r-4: 8px;
}

html {
  background: var(--surface-0);
}

body {
  background-color: #E8F3F9 !important;
  background-image:
    linear-gradient(135deg, rgba(47, 111, 236, 0.15), rgba(255, 255, 255, 0) 34%),
    linear-gradient(315deg, rgba(249, 115, 22, 0.09), rgba(255, 255, 255, 0) 42%),
    linear-gradient(180deg, var(--surface-0) 0%, #f8fcff 48%, #eef7ff 100%) !important;
  color: var(--ink-1);
}

body::before {
  content: none !important;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(47, 111, 236, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(47, 111, 236, 0.035) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: linear-gradient(180deg, rgba(0,0,0,0.55), transparent 68%);
  z-index: -1;
}

.text-flow-ltr,
[dir="rtl"] .text-flow-ltr,
[dir="rtl"] .content,
[dir="rtl"] .topbar,
[dir="rtl"] .sidebar {
  direction: ltr;
  text-align: left;
  unicode-bidi: plaintext;
}

a {
  color: var(--brand-blue);
}

a:hover {
  color: var(--brand-blue-hover);
  text-decoration-color: var(--brand-orange);
}

.shell {
  grid-template-columns: minmax(248px, 280px) minmax(0, 1fr);
}

.main {
  grid-column: 2;
  min-width: 0;
  width: 100%;
}

.sidebar {
  grid-column: 1;
}

[dir="rtl"] .main {
  grid-column: 1;
}

[dir="rtl"] .sidebar {
  grid-column: 2;
}

.skip-link {
  left: 12px !important;
  transform: translateY(-140%) !important;
}

.skip-link:focus {
  left: 12px !important;
  transform: translateY(0) !important;
}

.content {
  width: 100%;
  max-width: 1440px;
  padding: clamp(18px, 2.2vw, 28px) clamp(16px, 2.4vw, 30px) 46px !important;
}

.sidebar {
  background: linear-gradient(180deg, #f8fcff 0%, #e3f0ff 100%) !important;
  border-right: 1px solid rgba(47, 111, 236, 0.18) !important;
  color: var(--ink-1);
  box-shadow: inset -1px 0 0 rgba(255, 255, 255, 0.66);
}

.sidebar .logo {
  border-bottom: 1px solid rgba(47, 111, 236, 0.18) !important;
  gap: 12px !important;
  min-height: 74px;
  padding-bottom: 16px !important;
}

.sidebar .logo img,
.brand-mark {
  background: transparent;
  border-radius: 12px;
  box-shadow: 0 0 0 1px rgba(143, 200, 232, 0.26), 0 12px 26px rgba(42, 127, 174, 0.16);
  height: 38px !important;
  width: 38px !important;
}

.sidebar .logo .brand-name,
.sidebar .role-badge .name {
  color: var(--brand-blue-900) !important;
}

.sidebar .logo .brand-name {
  font-size: 20px !important;
  font-weight: 900 !important;
  letter-spacing: 0 !important;
}

.sidebar .logo .small,
.sidebar .nav-group-title,
.sidebar .role-badge {
  color: var(--ink-4) !important;
}

.sidebar .logo .small {
  font-size: 10px !important;
  font-weight: 750 !important;
  letter-spacing: 0 !important;
  text-transform: none !important;
}

.sidebar a.nav {
  display: flex;
  align-items: center;
  gap: var(--space-3, 0.75rem);
  margin: 2px 10px;
  padding: 9px 12px !important;
  color: var(--ink-3) !important;
  border-left: 3px solid transparent !important;
  border-radius: 8px !important;
  min-width: 0;
}

.sidebar a.nav::before {
  content: none !important;
}

.sidebar a.nav:hover {
  background: rgba(47, 111, 236, 0.09) !important;
  color: var(--brand-blue-900) !important;
  text-decoration: none !important;
}

.sidebar a.nav.active {
  background: linear-gradient(90deg, rgba(249, 115, 22, 0.16), rgba(47, 111, 236, 0.13)) !important;
  border-left-color: var(--brand-orange) !important;
  color: var(--brand-blue-900) !important;
  font-weight: 700 !important;
}

.sidebar .nav-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--brand-blue-800);
}

.sidebar a.nav.active .nav-icon,
.sidebar a.nav:hover .nav-icon {
  color: var(--brand-orange);
}

.sidebar .nav-icon svg {
  width: 20px;
  height: 20px;
}

.sidebar .role-badge {
  background: rgba(255, 255, 255, 0.70) !important;
  border-color: rgba(47, 111, 236, 0.16) !important;
  border-radius: 8px !important;
}

.sidebar-footer-actions {
  display: flex;
  gap: 8px;
  padding: 12px;
  flex-wrap: wrap;
}

.smart-sidebar {
  padding-bottom: 18px !important;
}

.sidebar-search {
  padding: 10px 12px 8px;
}

.sidebar-search input {
  width: 100% !important;
  min-height: 36px;
  padding: 8px 10px;
  border-radius: 8px !important;
  border: 1px solid rgba(47, 111, 236, 0.18) !important;
  background: rgba(255, 255, 255, 0.72) !important;
  color: var(--ink-2) !important;
  font-size: 13px;
}

.sidebar-search input:focus {
  border-color: rgba(249, 115, 22, 0.42) !important;
  box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.12) !important;
}

.sidebar-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 10px 12px 12px;
  border-bottom: 1px solid rgba(47, 111, 236, 0.14);
}

.sidebar a.sidebar-tab {
  align-items: flex-start;
  background: rgba(255, 255, 255, 0.62) !important;
  border: 1px solid rgba(47, 111, 236, 0.16) !important;
  border-left: 3px solid transparent !important;
  flex-direction: column;
  gap: 8px;
  justify-content: space-between;
  margin: 0 !important;
  min-height: 70px;
  padding: 10px !important;
}

.sidebar a.sidebar-tab .label {
  font-size: 12px;
  font-weight: 850;
  line-height: 1.15;
}

.sidebar a.sidebar-tab.active {
  background: linear-gradient(135deg, rgba(249, 115, 22, 0.15), rgba(47, 111, 236, 0.12)) !important;
  border-left-color: var(--brand-orange) !important;
}

.smart-nav-sections {
  display: grid;
  gap: 8px;
  padding: 10px 10px 0;
}

.smart-nav-section {
  background: rgba(255, 255, 255, 0.56);
  border: 1px solid rgba(47, 111, 236, 0.14);
  border-radius: 8px;
  overflow: hidden;
}

.smart-nav-section[open] {
  background: rgba(255, 255, 255, 0.76);
  border-color: rgba(47, 111, 236, 0.22);
}

.smart-nav-section summary {
  align-items: center;
  color: var(--brand-blue-900);
  cursor: pointer;
  display: grid;
  gap: 9px;
  grid-template-columns: 30px minmax(0, 1fr) auto 10px;
  list-style: none;
  padding: 10px;
}

.smart-nav-section summary::-webkit-details-marker {
  display: none;
}

.smart-nav-section summary::after {
  content: "";
  width: 7px;
  height: 7px;
  border-right: 2px solid rgba(42, 111, 148, 0.55);
  border-bottom: 2px solid rgba(42, 111, 148, 0.55);
  transform: rotate(45deg);
  transition: transform 160ms ease;
}

.smart-nav-section[open] summary::after {
  transform: rotate(225deg);
}

.nav-summary-icon {
  align-items: center;
  background: rgba(47, 111, 236, 0.09);
  border-radius: 8px;
  color: var(--brand-blue);
  display: inline-flex;
  height: 30px;
  justify-content: center;
  width: 30px;
}

.nav-summary-icon svg {
  height: 18px;
  width: 18px;
}

.nav-summary-copy {
  min-width: 0;
}

.nav-summary-copy strong {
  display: block;
  font-size: 13px;
  font-weight: 850;
  line-height: 1.1;
}

.nav-summary-copy small {
  color: var(--ink-4);
  display: block;
  font-size: 11px;
  line-height: 1.2;
  margin-top: 2px;
}

.nav-summary-count {
  background: rgba(249, 115, 22, 0.11);
  border-radius: 999px;
  color: var(--brand-orange);
  font-size: 11px;
  font-weight: 850;
  min-width: 22px;
  padding: 3px 7px;
  text-align: center;
}

.smart-nav-list {
  display: grid;
  gap: 4px;
  padding: 0 7px 8px 9px;
}

.sidebar a.smart-nav-link {
  align-items: center;
  border-left-width: 3px !important;
  column-gap: 8px;
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  margin: 0 !important;
  padding: 8px 9px !important;
}

.sidebar a.smart-nav-link .nav-icon {
  grid-row: 1 / 3;
}

.sidebar a.smart-nav-link .label {
  font-size: 13px;
  font-weight: 750;
  line-height: 1.1;
}

.sidebar a.smart-nav-link small {
  color: var(--ink-4);
  display: block;
  font-size: 11px;
  grid-column: 2;
  line-height: 1.25;
  margin-top: 2px;
}

.sidebar a.nav[hidden],
.smart-nav-section[hidden] {
  display: none !important;
}

header.topbar {
  background: rgba(248, 252, 255, 0.88) !important;
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(47, 111, 236, 0.14) !important;
}

.topbar .crumb {
  min-width: 0;
  color: var(--ink-4) !important;
}

.topbar .crumb b {
  color: var(--brand-blue-900) !important;
}

.topbar .sidebar-toggle {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 42px;
  min-width: 42px;
  height: 38px;
  min-height: 38px;
  padding: 0 !important;
  border-radius: 8px !important;
  background: rgba(47, 111, 236, 0.10) !important;
  border: 1px solid rgba(47, 111, 236, 0.18) !important;
  color: transparent !important;
  font-size: 0 !important;
  box-shadow: none !important;
}

.topbar .sidebar-toggle::before {
  content: "";
  width: 18px;
  height: 12px;
  background:
    linear-gradient(var(--brand-blue-900), var(--brand-blue-900)) 0 0 / 18px 2px no-repeat,
    linear-gradient(var(--brand-blue-900), var(--brand-blue-900)) 0 5px / 18px 2px no-repeat,
    linear-gradient(var(--brand-blue-900), var(--brand-blue-900)) 0 10px / 18px 2px no-repeat;
}

.topbar .sidebar-toggle:hover {
  background: rgba(249, 115, 22, 0.12) !important;
  border-color: rgba(249, 115, 22, 0.36) !important;
}

.topbar .sidebar-toggle:hover::before {
  background:
    linear-gradient(var(--brand-orange), var(--brand-orange)) 0 0 / 18px 2px no-repeat,
    linear-gradient(var(--brand-orange), var(--brand-orange)) 0 5px / 18px 2px no-repeat,
    linear-gradient(var(--brand-orange), var(--brand-orange)) 0 10px / 18px 2px no-repeat;
}

.topbar .search input,
.field input,
input,
select,
textarea {
  border-radius: 8px !important;
  border-color: rgba(64, 81, 107, 0.24) !important;
  background: rgba(255, 255, 255, 0.82) !important;
  color: var(--ink-1) !important;
}

.topbar .search input:focus,
.field input:focus,
input:focus,
select:focus,
textarea:focus {
  border-color: var(--brand-blue) !important;
  box-shadow: 0 0 0 3px rgba(47, 111, 236, 0.17) !important;
  outline: none !important;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid rgba(243, 112, 33, 0.72) !important;
  outline-offset: 3px !important;
}

.inline-form {
  display: inline;
}

button,
.btn {
  border-radius: 8px !important;
  background: rgba(255, 255, 255, 0.88) !important;
  border: 1px solid rgba(47, 111, 236, 0.22) !important;
  color: var(--brand-blue-900) !important;
  box-shadow: none !important;
}

button:hover,
.btn:hover {
  background: rgba(47, 111, 236, 0.10) !important;
  border-color: rgba(47, 111, 236, 0.42) !important;
  color: var(--brand-blue-hover) !important;
  text-decoration: none !important;
}

button[type="submit"]:not(.lang-btn),
.btn-primary,
.fab-send,
#ai-fab-send {
  background: linear-gradient(135deg, var(--brand-blue), var(--brand-blue-hover)) !important;
  border-color: rgba(35, 89, 199, 0.82) !important;
  color: #ffffff !important;
  box-shadow: 0 10px 22px rgba(47, 111, 236, 0.18) !important;
}

button[type="submit"]:not(.lang-btn):hover,
.btn-primary:hover,
.fab-send:hover,
#ai-fab-send:hover {
  background: linear-gradient(135deg, var(--brand-blue-hover), var(--brand-blue)) !important;
  border-color: var(--brand-orange) !important;
  color: #ffffff !important;
}

.btn-warning,
.lang-active {
  background: linear-gradient(135deg, var(--brand-orange), var(--brand-orange-hover)) !important;
  border-color: var(--brand-orange) !important;
  color: #ffffff !important;
}

.card,
.kpi,
.sub-card,
.bento-tile,
.onesync-today-tile,
.hero-panel,
.login-card,
.error-card,
.ov-card {
  background: rgba(255, 255, 255, 0.90) !important;
  border: 1px solid rgba(47, 111, 236, 0.14) !important;
  border-top: 3px solid rgba(47, 111, 236, 0.42) !important;
  border-radius: 8px !important;
  box-shadow: var(--shadow-1) !important;
}

.card:hover,
.kpi:hover,
.sub-card:hover,
.bento-tile:hover,
.ov-card:hover {
  border-color: rgba(249, 115, 22, 0.42) !important;
  box-shadow: var(--shadow-2) !important;
}

.card .card-title,
.page-title h1,
h1,
h2,
h3 {
  color: var(--brand-gray-950);
  letter-spacing: 0 !important;
}

.page-title .sub,
.muted,
.small,
.help,
.kpi .label,
.kpi .delta {
  color: var(--ink-4) !important;
}

.onesync-hero {
  grid-template-columns: minmax(0, 1.25fr) minmax(320px, 0.75fr) !important;
  align-items: center !important;
  padding: 18px 0 26px !important;
  margin-bottom: 26px !important;
}

.onesync-greet {
  font-size: clamp(2rem, 3vw, 2.85rem) !important;
  font-weight: 800 !important;
  letter-spacing: 0 !important;
  color: var(--brand-blue-900) !important;
}

.onesync-brief {
  font-size: 1rem !important;
  max-width: 760px !important;
  color: var(--ink-3) !important;
}

.onesync-brief::first-letter,
.onesync-dropcap::first-letter {
  float: none !important;
  padding: 0 !important;
  font: inherit !important;
  color: inherit !important;
  letter-spacing: 0 !important;
}

.onesync-brief .onesync-num {
  border-bottom-color: var(--brand-orange) !important;
  color: var(--brand-blue) !important;
}

.onesync-date-sep,
.onesync-today-label,
.kpi.brand .value {
  color: var(--brand-orange) !important;
}

.kpi .value,
.onesync-today-value {
  color: var(--brand-blue-900) !important;
}

.table-wrap,
.card:has(table),
.sub-card:has(table) {
  overflow-x: auto;
}

table.t {
  background: rgba(255, 255, 255, 0.70);
}

table.t th {
  background: rgba(47, 111, 236, 0.08) !important;
  color: var(--brand-gray-700) !important;
}

table.t td {
  color: var(--ink-2) !important;
}

table.t tbody tr:hover td,
table.t tr:hover td {
  background: rgba(47, 111, 236, 0.06) !important;
}

.status,
.badge,
.chip,
.prayer-indicator {
  border-radius: 999px !important;
}

.cmdk {
  display: block !important;
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 10000;
}

.cmdk[hidden] {
  display: none !important;
}

.cmdk.cmdk--visible {
  pointer-events: auto;
}

.cmdk-overlay {
  background: rgba(20, 32, 51, 0.34) !important;
  backdrop-filter: blur(4px);
}

.cmdk-panel {
  border-radius: 8px !important;
  border: 1px solid rgba(47, 111, 236, 0.24) !important;
  box-shadow: var(--shadow-pop) !important;
  background: #ffffff !important;
}

.cmdk-search {
  background: #ffffff !important;
}

.cmdk-result.active,
.cmdk-result:hover {
  background: rgba(47, 111, 236, 0.10) !important;
}

.cmdk-result .icon {
  background: rgba(47, 111, 236, 0.10);
  border: 1px solid rgba(47, 111, 236, 0.16);
  color: var(--brand-blue-900) !important;
  border-radius: 6px;
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px !important;
  font-weight: 800;
  letter-spacing: 0;
}

.shell.sidebar-collapsed {
  grid-template-columns: 68px minmax(0, 1fr) !important;
}

.shell.sidebar-collapsed .sidebar {
  width: 68px !important;
  overflow-x: hidden !important;
}

.shell.sidebar-collapsed .sidebar .logo {
  justify-content: center !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

.shell.sidebar-collapsed .sidebar .brand-name,
.shell.sidebar-collapsed .sidebar .small,
.shell.sidebar-collapsed .sidebar .nav-group-title,
.shell.sidebar-collapsed .sidebar .role-badge,
.shell.sidebar-collapsed .sidebar .nav-personalize,
.shell.sidebar-collapsed .sidebar .sidebar-order-reset,
.shell.sidebar-collapsed .sidebar .sidebar-footer-actions,
.shell.sidebar-collapsed .smart-sidebar .sidebar-search,
.shell.sidebar-collapsed .smart-sidebar .nav-summary-copy,
.shell.sidebar-collapsed .smart-sidebar .nav-summary-count,
.shell.sidebar-collapsed .smart-sidebar .smart-nav-list,
.shell.sidebar-collapsed .smart-sidebar .sidebar-tab .label,
.shell.sidebar-collapsed .sidebar a.nav > *:not(.nav-icon):not(.badge) {
  display: none !important;
}

.shell.sidebar-collapsed .sidebar a.nav {
  justify-content: center !important;
  margin-left: 8px !important;
  margin-right: 8px !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

.shell.sidebar-collapsed .smart-sidebar .sidebar-tabs {
  grid-template-columns: 1fr;
  padding: 8px;
}

.shell.sidebar-collapsed .smart-sidebar .sidebar-tab,
.shell.sidebar-collapsed .smart-sidebar .smart-nav-section summary {
  display: flex;
  justify-content: center;
  min-height: 42px;
  padding: 8px !important;
}

.shell.sidebar-collapsed .smart-sidebar .smart-nav-section {
  background: transparent;
  border-color: transparent;
}

#ai-fab-btn {
  background: linear-gradient(135deg, var(--brand-blue), var(--brand-orange)) !important;
  border-radius: 999px !important;
  color: #ffffff !important;
  box-shadow: 0 18px 38px rgba(47, 111, 236, 0.24) !important;
}

#ai-fab-panel,
.ai-panel {
  border-radius: 8px !important;
  border: 1px solid rgba(47, 111, 236, 0.22) !important;
  box-shadow: var(--shadow-pop) !important;
  background: #ffffff !important;
}

.ai-panel[hidden],
#ai-fab-panel[hidden] {
  display: none !important;
}

.fab-header,
.ai-panel-head {
  background: linear-gradient(135deg, var(--brand-blue-900), var(--brand-blue)) !important;
  color: #ffffff !important;
}

.fab-close {
  background: transparent !important;
  border: 0 !important;
  color: #ffffff !important;
  box-shadow: none !important;
}

.fab-msg.ai {
  background: var(--brand-blue-050) !important;
  border: 1px solid var(--line-1);
  color: var(--ink-1) !important;
}

.fab-msg.user {
  background: var(--brand-blue) !important;
  color: #ffffff !important;
}

.ov-card .icon {
  background: rgba(47, 111, 236, 0.10);
  border: 1px solid rgba(47, 111, 236, 0.16);
  color: var(--brand-blue-900);
}

.ov-card .title,
.login-card h1 {
  color: var(--brand-blue-900) !important;
}

.offline-banner {
  border-radius: 8px !important;
}

@media (min-width: 901px) {
  header.topbar {
    min-height: 62px !important;
    padding: 10px clamp(16px, 2.4vw, 30px) !important;
  }

  .sidebar .logo {
    min-height: 68px;
  }
}

@media (max-width: 900px) {
  .shell {
    grid-template-columns: 68px minmax(0, 1fr) !important;
  }

  .sidebar {
    width: 68px !important;
    overflow-x: hidden !important;
  }

  .main {
    grid-column: 2 !important;
  }

  .sidebar {
    grid-column: 1 !important;
  }

  [dir="rtl"] .shell {
    grid-template-columns: minmax(0, 1fr) 68px !important;
  }

  [dir="rtl"] .main {
    grid-column: 1 !important;
  }

  [dir="rtl"] .sidebar {
    grid-column: 2 !important;
  }

  .sidebar .brand-name,
  .sidebar .small,
  .sidebar .nav-group-title,
  .sidebar .role-badge,
  .sidebar .nav-personalize,
  .sidebar .sidebar-order-reset,
  .sidebar .sidebar-footer-actions,
  .smart-sidebar .sidebar-search,
  .smart-sidebar .nav-summary-copy,
  .smart-sidebar .nav-summary-count,
  .smart-sidebar .smart-nav-list,
  .smart-sidebar .sidebar-tab .label,
  .sidebar a.nav > *:not(.nav-icon):not(.badge) {
    display: none !important;
  }

  .sidebar a.nav,
  .smart-sidebar .sidebar-tab,
  .smart-sidebar .smart-nav-section summary {
    justify-content: center !important;
  }

  .smart-sidebar .sidebar-tabs {
    grid-template-columns: 1fr;
  }

  .content {
    padding: 20px !important;
  }
}

@media (max-width: 880px) {
  .onesync-hero {
    grid-template-columns: 1fr !important;
  }
}

@media (max-width: 600px) {
  .shell,
  .shell.sidebar-collapsed {
    grid-template-columns: 0 minmax(0, 1fr) !important;
  }

  header.topbar {
    z-index: 80 !important;
    align-items: center !important;
    gap: 8px !important;
    min-width: 0 !important;
    overflow-x: clip !important;
  }

  .topbar .crumb {
    flex: 0 1 auto !important;
    max-width: 28vw !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  .topbar .search {
    display: block !important;
    flex: 1 1 104px !important;
    min-width: 104px !important;
    max-width: 38vw !important;
  }

  .topbar .search input {
    width: 100% !important;
  }

  .lang-switcher {
    display: flex !important;
    flex: 0 0 auto !important;
    gap: 3px !important;
  }

  .lang-switcher .lang-btn {
    min-width: 34px !important;
    padding-inline: 7px !important;
  }

  .user-area {
    flex: 0 0 auto !important;
    gap: 6px !important;
    min-width: 0 !important;
  }

  .user-area .user-name,
  .user-area .user-meta {
    display: none !important;
  }

  .user-area .logout {
    padding-inline: 8px !important;
  }

  .sidebar {
    bottom: 0 !important;
    height: 100dvh !important;
    left: min(-286px, -88vw) !important;
    top: 0 !important;
    width: 286px !important;
    max-width: 88vw !important;
    grid-column: 1 !important;
    z-index: 110 !important;
  }

  .main {
    grid-column: 2 !important;
  }

  .sidebar.open {
    left: 0 !important;
  }

  [dir="rtl"] .shell {
    grid-template-areas: none !important;
    grid-template-columns: 0 minmax(0, 1fr) !important;
  }

  [dir="rtl"] .shell.sidebar-collapsed {
    grid-template-columns: 0 minmax(0, 1fr) !important;
  }

  [dir="rtl"] .sidebar,
  [dir="rtl"] .main {
    order: 0 !important;
  }

  [dir="rtl"] .sidebar {
    grid-column: 1 !important;
    left: auto !important;
    right: min(-286px, -88vw) !important;
  }

  [dir="rtl"] .main {
    grid-column: 2 !important;
  }

  [dir="rtl"] .sidebar.open {
    left: auto !important;
    right: 0 !important;
  }

  .sidebar.open .brand-name,
  .sidebar.open .small,
  .sidebar.open .nav-group-title,
  .sidebar.open .role-badge,
  .sidebar.open .nav-personalize,
  .sidebar.open .sidebar-order-reset,
  .sidebar.open .sidebar-footer-actions,
  .sidebar.open .sidebar-search,
  .sidebar.open .nav-summary-copy,
  .sidebar.open .nav-summary-count,
  .sidebar.open .smart-nav-list,
  .sidebar.open .sidebar-tab .label,
  .sidebar.open a.nav > *:not(.nav-icon) {
    display: revert !important;
  }

  .shell.sidebar-collapsed .sidebar.open .sidebar-search,
  .shell.sidebar-collapsed .sidebar.open .nav-summary-copy,
  .shell.sidebar-collapsed .sidebar.open .nav-summary-count,
  .shell.sidebar-collapsed .sidebar.open .sidebar-tab .label {
    display: block !important;
  }

  .shell.sidebar-collapsed .sidebar.open .smart-nav-list,
  .sidebar.open .smart-nav-list,
  .shell.sidebar-collapsed .sidebar.open .sidebar-tabs,
  .sidebar.open .sidebar-tabs {
    display: grid !important;
  }

  .content {
    padding: 16px !important;
    padding-bottom: calc(120px + env(safe-area-inset-bottom, 0px)) !important;
  }

  #ai-fab-panel {
    width: calc(100vw - 16px) !important;
    right: 8px !important;
    bottom: 72px !important;
    height: min(72vh, 540px) !important;
  }
}

/* Guided OneSync journey pages */
.journey-hero,
.journey-section,
.task-board,
.request-shell,
.insights-shell,
.studio-grid {
  width: 100%;
  scroll-margin-top: calc(var(--topbar-h, 64px) + 20px);
}

.journey-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding: 30px;
  margin-bottom: 20px;
  border: 1px solid rgba(47, 111, 236, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(47, 111, 236, 0.13), rgba(255, 255, 255, 0.72)),
    linear-gradient(180deg, #ffffff, #f7fbff);
  box-shadow: 0 18px 44px rgba(47, 111, 236, 0.12);
}

.journey-hero h1 {
  margin: 0;
  max-width: 780px;
  color: var(--brand-gray-950);
  font-size: clamp(30px, 4vw, 54px);
  line-height: 1.03;
  letter-spacing: 0;
}

.hero-copy {
  margin: 14px 0 0;
  max-width: 720px;
  color: var(--brand-gray-650);
  font-size: 16px;
  line-height: 1.65;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--brand-orange);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero-actions,
.form-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.attention-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 26px;
}

.attention-card,
.journey-card,
.insight-card,
.request-type-card,
.health-row,
.task-row,
.guide-grid > a,
.guide-grid > article,
.studio-card,
.module-group-card {
  border: 1px solid rgba(47, 111, 236, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 12px 30px rgba(20, 32, 51, 0.06);
  color: inherit;
  text-decoration: none;
}

.attention-card {
  display: block;
  min-height: 132px;
  padding: 18px;
}

.attention-card .label,
.insight-card span,
.health-row span,
.journey-card span,
.request-type-card span {
  display: block;
  color: var(--brand-gray-650);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.attention-card strong {
  display: block;
  margin-top: 8px;
  color: var(--brand-gray-950);
  font-size: 34px;
  line-height: 1;
}

.attention-card p,
.journey-card p,
.request-type-card p,
.insight-card p,
.guide-grid p,
.studio-card p,
.section-heading p {
  color: var(--brand-gray-650);
  line-height: 1.55;
}

.journey-section {
  margin: 26px 0;
}

.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 14px;
}

.section-heading.compact {
  align-items: flex-start;
  margin-bottom: 18px;
}

.section-heading h2 {
  margin: 0;
  color: var(--brand-gray-950);
  font-size: 24px;
  letter-spacing: 0;
}

.section-heading p {
  max-width: 560px;
  margin: 0;
}

.journey-grid,
.request-type-grid,
.insight-card-grid,
.guide-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.journey-card,
.request-type-card,
.insight-card,
.guide-grid > a,
.guide-grid > article {
  display: block;
  padding: 20px;
}

.journey-card:hover,
.request-type-card:hover,
.attention-card:hover,
.insight-card:hover,
.health-row:hover,
.task-row:hover,
.guide-grid > a:hover,
.module-group-card a:hover {
  border-color: rgba(47, 111, 236, 0.34);
  box-shadow: 0 16px 38px rgba(47, 111, 236, 0.12);
  transform: translateY(-1px);
}

.journey-card strong,
.request-type-card strong,
.insight-card strong,
.guide-grid strong,
.studio-card h2,
.studio-card h3 {
  display: block;
  margin: 8px 0;
  color: var(--brand-gray-950);
}

.journey-card small,
.request-type-card small,
.insight-card small,
.module-group-card a span {
  color: var(--brand-orange);
  font-weight: 800;
}

.task-board {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 16px;
  margin: 26px 0;
}

.task-column {
  padding: 18px;
  border: 1px solid rgba(47, 111, 236, 0.16);
  border-radius: 8px;
  background: rgba(248, 252, 255, 0.9);
}

.task-column.wide {
  width: 100%;
}

.task-column h2,
.task-column h3 {
  margin: 0 0 12px;
  color: var(--brand-gray-950);
}

.task-row,
.queue-row,
.health-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px;
  margin-bottom: 10px;
}

.task-row strong,
.queue-row strong,
.health-row strong {
  color: var(--brand-gray-950);
}

.task-row span,
.queue-row span,
.health-row small {
  display: block;
  margin-top: 4px;
  color: var(--brand-gray-650);
  font-size: 13px;
}

.empty-text {
  margin: 0;
  color: var(--brand-gray-650);
}

.request-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.6fr);
  gap: 16px;
  margin: 26px 0;
}

.request-form-panel,
.request-guide {
  padding: 22px;
  border: 1px solid rgba(47, 111, 236, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.88);
}

.guided-form {
  display: grid;
  gap: 12px;
}

.guided-form label {
  color: var(--brand-gray-850);
  font-weight: 800;
}

.guided-form input,
.guided-form select,
.guided-form textarea {
  width: 100%;
  border: 1px solid rgba(47, 111, 236, 0.22);
  border-radius: 8px;
  background: #ffffff;
}

.guided-form input:focus,
.guided-form select:focus,
.guided-form textarea:focus {
  outline: none;
  border-color: var(--brand-blue);
  box-shadow: 0 0 0 3px rgba(47, 111, 236, 0.16);
}

.form-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.step-list {
  display: grid;
  gap: 12px;
  padding: 0;
  margin: 14px 0 0;
  list-style: none;
}

.step-list li {
  display: grid;
  gap: 4px;
  padding-left: 14px;
  border-left: 3px solid var(--brand-orange);
}

.step-list span {
  color: var(--brand-gray-650);
}

.queue-row {
  border: 1px solid rgba(47, 111, 236, 0.12);
  border-radius: 8px;
  background: #ffffff;
}

.queue-row select {
  width: auto;
  min-width: 150px;
}

.studio-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 22px 0;
}

.studio-card {
  padding: 22px;
}

.control-list {
  display: grid;
  gap: 12px;
}

.control-list div,
.admin-type-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
  padding: 14px;
  border: 1px solid rgba(47, 111, 236, 0.12);
  border-radius: 8px;
  background: var(--surface-1);
}

.admin-type-row > div {
  flex: 1 1 260px;
}

.control-list span,
.admin-type-row span,
.admin-type-row small {
  display: block;
  margin-top: 4px;
  color: var(--brand-gray-650);
}

.link-grid,
.module-map {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.link-grid a,
.module-group-card a {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 12px;
  border-radius: 8px;
  background: rgba(47, 111, 236, 0.07);
  color: var(--brand-gray-950);
  text-decoration: none;
}

.module-map {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.module-group-card {
  padding: 16px;
}

.module-group-card h3 {
  margin: 0 0 10px;
}

.module-group-card a {
  margin: 8px 0;
}

.insights-shell {
  display: grid;
  gap: 16px;
}

.insight-section {
  padding: 20px;
  border: 1px solid rgba(47, 111, 236, 0.16);
  border-radius: 8px;
  background: rgba(248, 252, 255, 0.92);
}

.branch-bars {
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid rgba(47, 111, 236, 0.16);
  border-radius: 8px;
  background: #ffffff;
}

.branch-bar-row {
  display: grid;
  grid-template-columns: minmax(120px, 0.6fr) minmax(160px, 1fr) minmax(120px, 0.4fr);
  align-items: center;
  gap: 12px;
}

.bar-track {
  height: 10px;
  border-radius: 999px;
  background: rgba(47, 111, 236, 0.1);
  overflow: hidden;
}

.bar-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--brand-blue), var(--brand-orange));
}

.list-tip {
  display: none !important;
}

.page-title .sub::after {
  content: "";
}

.row-attachments {
  border-top: 1px solid rgba(47, 111, 236, 0.14);
  padding-top: 14px;
}

@media (max-width: 1100px) {
  .attention-grid,
  .journey-grid,
  .request-type-grid,
  .insight-card-grid,
  .module-map {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .journey-hero,
  .section-heading,
  .task-board,
  .request-shell,
  .studio-grid,
  .request-type-admin,
  .form-grid-2,
  .link-grid,
  .guide-grid,
  .attention-grid,
  .journey-grid,
  .request-type-grid,
  .insight-card-grid,
  .module-map {
    grid-template-columns: 1fr;
  }

  .journey-hero {
    align-items: flex-start;
    padding: 22px;
  }

  .section-heading {
    align-items: flex-start;
  }

  .branch-bar-row {
    grid-template-columns: 1fr;
  }

  .task-row,
  .queue-row,
  .health-row,
  .control-list div,
  .admin-type-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .queue-row select {
    width: 100%;
  }
}

/* Keep older setup screens inside the light OneSync palette. */
.wiz-shell,
.int-page {
  color: var(--brand-gray-950) !important;
}

.wiz-header h1,
.wiz-step-meta h2,
.int-header h1 {
  color: var(--brand-gray-950) !important;
  letter-spacing: 0 !important;
}

.wiz-progress-wrap,
.wiz-card,
.int-card,
.int-filter-btn,
.int-section-title {
  background: rgba(255, 255, 255, 0.88) !important;
  border-color: rgba(47, 111, 236, 0.16) !important;
  color: var(--brand-gray-650) !important;
}

.wiz-back,
.int-back,
.wiz-step-label.done,
.int-filter-btn.active,
.int-filter-btn:hover {
  color: var(--brand-blue) !important;
  border-color: rgba(47, 111, 236, 0.28) !important;
  background: rgba(47, 111, 236, 0.08) !important;
}

.wiz-step-label.active {
  color: var(--brand-gray-950) !important;
}

.wiz-bar-fill,
.wiz-dot.active,
.wiz-dot.done {
  background: linear-gradient(90deg, var(--brand-blue), var(--brand-orange)) !important;
  border-color: var(--brand-blue) !important;
  box-shadow: none !important;
}

.wiz-step-badge {
  background: var(--brand-orange-soft) !important;
  border-color: rgba(230, 106, 26, 0.24) !important;
  color: var(--brand-orange) !important;
}

/* Report-applied OneSync journey layer: Ford GT baby-blue / orange / white. */
.brand-name {
  letter-spacing: 0 !important;
}

.module-catalog {
  margin: 10px 0 0;
  border-top: 1px solid rgba(42, 111, 148, 0.14);
  padding-top: 8px;
}

.module-catalog summary {
  cursor: pointer;
  margin: 0 12px 8px;
  padding: 8px 10px;
  border-radius: 8px;
  color: var(--brand-blue-900);
  font-weight: 800;
  font-size: 12px;
  list-style: none;
}

.module-catalog summary::-webkit-details-marker {
  display: none;
}

.module-catalog summary::after {
  content: "+";
  float: right;
  color: var(--brand-orange);
}

.module-catalog[open] summary::after {
  content: "-";
}

.sidebar a.primary-nav {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  column-gap: 10px;
  min-height: 52px;
}

.sidebar a.primary-nav .nav-icon {
  grid-row: 1 / 3;
  align-self: center;
}

.sidebar a.primary-nav .label {
  font-weight: 850;
  color: inherit;
}

.sidebar a.primary-nav small {
  display: block;
  grid-column: 2;
  margin-top: 2px;
  color: var(--brand-gray-650);
  font-size: 11px;
  line-height: 1.2;
}

.today-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: end;
  margin-bottom: 18px;
  padding: 36px;
  overflow: hidden;
  border: 1px solid rgba(42, 111, 148, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(122, 184, 220, 0.24), rgba(255,255,255,0.9) 56%),
    linear-gradient(180deg, #ffffff, #F5FBFE);
  box-shadow: 0 18px 40px rgba(19, 32, 46, 0.08);
}

.today-hero::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 8px;
  background: var(--brand-orange);
}

.today-hero::after {
  content: "";
  position: absolute;
  right: -60px;
  top: 22px;
  width: 320px;
  height: 42px;
  transform: rotate(-12deg);
  background: linear-gradient(90deg, rgba(122,184,220,0.34), rgba(243,112,33,0.82));
  opacity: 0.45;
}

.today-hero-copy,
.today-actions {
  position: relative;
  z-index: 1;
}

.today-hero h1 {
  max-width: 820px;
  margin: 0;
  color: var(--brand-blue-900);
  font-size: clamp(34px, 4.4vw, 64px);
  line-height: 1.02;
  letter-spacing: 0 !important;
}

.today-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.today-action-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 0 0 24px;
}

.today-action,
.work-panel,
.flow-panel {
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 10px 26px rgba(19, 32, 46, 0.06);
}

.today-action {
  padding: 18px;
  color: inherit;
  text-decoration: none;
  border-top: 3px solid rgba(122, 184, 220, 0.75);
}

.today-action:hover,
.flow-row:hover,
.work-panel:hover,
.flow-panel:hover {
  border-color: rgba(243, 112, 33, 0.38);
  text-decoration: none;
}

.today-action span,
.flow-row strong {
  color: var(--brand-gray-650);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.today-action strong {
  display: block;
  margin: 8px 0;
  color: var(--brand-blue-900);
  font-size: 34px;
  line-height: 1;
}

.today-action p {
  margin: 0;
  color: var(--brand-gray-650);
}

.today-command-grid,
.today-flow-grid,
.request-detail-grid {
  display: grid;
  gap: 16px;
  margin: 24px 0;
}

.today-command-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.today-flow-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.request-detail-grid {
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 0.65fr);
}

.work-panel,
.flow-panel {
  padding: 18px;
}

.flow-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 6px 14px;
  padding: 14px 0;
  border-top: 1px solid rgba(42, 111, 148, 0.12);
  color: inherit;
  text-decoration: none;
}

.flow-row:first-of-type {
  border-top: 0;
}

.flow-row span {
  color: var(--brand-blue-900);
  font-weight: 850;
}

.flow-row p {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--brand-gray-650);
}

.journey-grid-six,
.request-type-grid-wide {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.request-type-card.selected {
  border-color: rgba(243, 112, 33, 0.55);
  background: linear-gradient(180deg, #ffffff, rgba(255,232,214,0.42));
}

.request-shell-wide {
  grid-template-columns: minmax(0, 1.55fr) minmax(300px, 0.45fr);
}

.readonly-field {
  min-height: 40px;
  display: flex;
  align-items: center;
  padding: 9px 12px;
  border: 1px solid rgba(42, 111, 148, 0.16);
  border-radius: 8px;
  background: rgba(232, 243, 249, 0.62);
  color: var(--brand-blue-900);
  font-weight: 800;
}

.type-field-band {
  margin: 18px 0;
  padding: 16px;
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-left: 4px solid var(--brand-orange);
  border-radius: 8px;
  background: rgba(245, 251, 254, 0.88);
}

.type-field-band h3 {
  margin: 0 0 12px;
  font-size: 18px;
}

.guide-note {
  margin-top: 16px;
  padding: 12px;
  border-radius: 8px;
  background: rgba(255, 232, 214, 0.62);
  color: var(--brand-gray-650);
  line-height: 1.45;
}

.request-row {
  color: inherit;
  text-decoration: none;
}

.request-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0 20px;
}

.request-facts-wide {
  grid-template-columns: 1fr;
}

.request-facts div {
  padding: 12px;
  border: 1px solid rgba(42, 111, 148, 0.12);
  border-radius: 8px;
  background: rgba(245, 251, 254, 0.72);
}

.request-facts dt {
  color: var(--brand-gray-650);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.request-facts dd {
  margin: 5px 0 0;
  color: var(--brand-blue-900);
  font-weight: 750;
}

.request-body {
  color: var(--brand-gray-650);
  line-height: 1.65;
}

.compact-form {
  margin-top: 12px;
}

.request-timeline {
  list-style: none;
  margin: 0;
  padding: 0;
}

.request-timeline li {
  position: relative;
  padding: 0 0 18px 22px;
  border-left: 2px solid rgba(122, 184, 220, 0.55);
}

.request-timeline li::before {
  content: "";
  position: absolute;
  left: -6px;
  top: 3px;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--brand-orange);
}

.request-timeline span,
.comment-row span {
  display: block;
  color: var(--brand-gray-650);
  font-size: 12px;
}

.request-timeline strong,
.comment-row strong {
  display: block;
  margin-top: 3px;
  color: var(--brand-blue-900);
}

.request-timeline em {
  display: block;
  margin-top: 2px;
  color: var(--brand-orange);
  font-style: normal;
  font-size: 12px;
  font-weight: 800;
}

.request-timeline p,
.comment-row p {
  margin: 5px 0 0;
  color: var(--brand-gray-650);
  line-height: 1.5;
}

.comment-row {
  padding: 12px 0;
  border-bottom: 1px solid rgba(42, 111, 148, 0.12);
}

.status.late,
.status.warning {
  background: var(--brand-orange-soft) !important;
  color: var(--brand-orange) !important;
  border-color: rgba(243, 112, 33, 0.28) !important;
}

.status.ok,
.status.closed {
  background: rgba(21, 128, 61, 0.10) !important;
  color: var(--accent-sage) !important;
  border-color: rgba(21, 128, 61, 0.22) !important;
}

@media (max-width: 1100px) {
  .today-action-strip,
  .today-flow-grid,
  .journey-grid-six,
  .request-type-grid-wide {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .request-detail-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .today-hero,
  .today-command-grid,
  .today-flow-grid,
  .today-action-strip,
  .journey-grid-six,
  .request-type-grid-wide,
  .request-shell-wide,
  .request-facts {
    grid-template-columns: 1fr;
  }

  .today-hero {
    padding: 24px;
  }

  .today-actions {
    justify-content: flex-start;
  }
}

/* Table dashboards and non-spreadsheet list experience. */
.page-actions {
  align-items: center !important;
}

.list-search-form {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.list-search-form input,
.list-search-form select {
  width: auto !important;
  min-width: 180px;
}

.page-actions .btn,
.page-actions button {
  align-self: center !important;
  min-height: 40px !important;
}

.table-dashboard-strip {
  margin: 0 0 12px;
  padding: 14px;
  border: 1px solid rgba(42, 111, 148, 0.16);
  border-left: 4px solid var(--brand-orange);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(232, 243, 249, 0.92), rgba(255, 255, 255, 0.94));
  box-shadow: 0 10px 26px rgba(19, 32, 46, 0.06);
  scroll-margin-top: calc(var(--topbar-h, 64px) + 16px);
}

.table-dashboard-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}

.table-dashboard-head strong {
  display: block;
  color: var(--brand-blue-900);
  font-size: 18px;
}

.table-eyebrow,
.table-kpi span,
.page-section-tabs span {
  display: block;
  color: var(--brand-gray-650);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0;
  text-transform: uppercase;
}

.table-showing {
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(243, 112, 33, 0.12);
  color: var(--brand-orange);
  font-weight: 850;
  font-size: 12px;
  white-space: nowrap;
}

.table-kpi-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.table-kpi {
  min-height: 74px;
  padding: 12px;
  border: 1px solid rgba(42, 111, 148, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
}

.table-kpi strong {
  display: block;
  margin-top: 6px;
  color: var(--brand-blue-900);
  font-size: 18px;
  line-height: 1.2;
}

.table-fast-filters {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.table-fast-filters input,
.table-fast-filters select {
  width: auto !important;
  min-width: 210px;
}

.table-tabs,
.page-section-tabs,
.table-view-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.table-tab,
.page-section-tabs button,
.table-view-btn {
  min-height: 32px !important;
  padding: 6px 10px !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, 0.88) !important;
  color: var(--brand-gray-700) !important;
}

.table-tab.active,
.table-view-btn.active,
.page-section-tabs button:hover {
  background: linear-gradient(135deg, var(--brand-blue), var(--brand-blue-hover)) !important;
  color: #ffffff !important;
  border-color: var(--brand-blue) !important;
}

.table-view-toggle {
  margin-bottom: 10px;
}

.record-card-panel {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 12px;
  margin: 0 0 12px;
  max-height: none;
  overflow: visible;
  padding-right: 4px;
}

.record-card-panel.is-hidden,
.onesync-table-scroll.is-hidden {
  display: none !important;
}

.record-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 180px;
  padding: 14px;
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 10px 24px rgba(19, 32, 46, 0.05);
}

.record-card--test {
  border-color: rgba(243, 112, 33, 0.28);
  background: linear-gradient(135deg, rgba(255, 249, 244, 0.96), rgba(255, 255, 255, 0.94));
}

.record-card-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.record-card-eyebrow,
.record-field-group-title {
  display: block;
  color: var(--brand-gray-650);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.record-card-title {
  display: block;
  margin-top: 3px;
  color: var(--brand-blue-900);
  font-size: 17px;
  line-height: 1.25;
}

.record-test-badge {
  align-self: flex-start;
  padding: 5px 8px;
  border: 1px solid rgba(243, 112, 33, 0.22);
  border-radius: 999px;
  color: #9a4311;
  background: rgba(243, 112, 33, 0.10);
  font-size: 11px;
  font-weight: 850;
  white-space: nowrap;
}

.data-quality-banner {
  margin: -2px 0 12px;
  padding: 10px 12px;
  border: 1px solid rgba(243, 112, 33, 0.24);
  border-left: 4px solid var(--brand-orange);
  border-radius: 8px;
  color: #7b3a12;
  background: rgba(255, 246, 238, 0.92);
  font-size: 13px;
  font-weight: 800;
}

.record-field-group {
  display: grid;
  gap: 6px;
}

.record-field-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.record-field-chip {
  display: inline-grid;
  gap: 2px;
  min-width: 112px;
  max-width: 100%;
  padding: 7px 9px;
  border: 1px solid rgba(42, 111, 148, 0.11);
  border-radius: 8px;
  background: rgba(232, 243, 249, 0.56);
}

.record-field-chip b {
  color: var(--brand-gray-650);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.record-field-chip em {
  color: var(--ink-2);
  font-style: normal;
  font-size: 13px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.record-card-actions {
  margin-top: auto;
  display: flex;
  justify-content: flex-end;
}

.onesync-table-scroll {
  width: 100%;
  max-height: min(62vh, 620px);
  overflow: auto;
  border: 1px solid rgba(42, 111, 148, 0.12);
  border-radius: 8px;
  background: #ffffff;
}

.onesync-table-scroll table,
.content .onesync-table-scroll table {
  display: table !important;
  width: 100% !important;
  min-width: 760px;
  border-collapse: collapse;
}

.onesync-enhanced-table th {
  position: sticky;
  top: 0;
  z-index: 1;
}

.onesync-enhanced-table .th-sort {
  min-height: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: inherit !important;
  font-size: 11px !important;
  font-weight: 850 !important;
  line-height: 1.25 !important;
  text-transform: uppercase;
}

.onesync-enhanced-table tbody tr:nth-child(even) td {
  background: rgba(232, 243, 249, 0.36);
}

.onesync-enhanced-table td,
.onesync-enhanced-table th {
  white-space: nowrap;
}

.onesync-enhanced-table td:nth-child(2),
.onesync-enhanced-table td:nth-child(3) {
  white-space: normal;
}

.table-row-hidden {
  display: none !important;
}

.page-section-tabs {
  position: sticky;
  top: var(--topbar-h, 64px);
  z-index: 4;
  margin: 0 0 14px;
  padding: 10px;
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-radius: 8px;
  background: rgba(248, 252, 255, 0.92);
  backdrop-filter: blur(12px);
}

/* Owner Briefing decision board ------------------------------------------ */
.owner-brief-shell {
  display: grid;
  gap: 18px;
}

.owner-brief-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 18px;
  min-height: 214px;
  overflow: hidden;
  padding: clamp(22px, 3vw, 34px);
  border: 1px solid rgba(42, 111, 148, 0.16);
  border-left: 6px solid var(--brand-orange);
  border-radius: 8px;
  background:
    linear-gradient(125deg, rgba(255, 255, 255, 0.96) 0%, rgba(232, 243, 249, 0.94) 58%, rgba(255, 247, 241, 0.92) 100%),
    #ffffff;
  box-shadow: 0 18px 44px rgba(19, 32, 46, 0.08);
}

.owner-brief-hero::after {
  content: "";
  position: absolute;
  inset: auto -70px -120px auto;
  width: 420px;
  height: 240px;
  transform: rotate(-18deg);
  background: linear-gradient(90deg, rgba(122, 184, 220, 0.22), rgba(243, 112, 33, 0.14));
  pointer-events: none;
}

.owner-brief-hero > * {
  position: relative;
  z-index: 1;
}

.owner-brief-hero h1 {
  max-width: 760px;
  margin: 4px 0 10px;
  color: var(--brand-blue-900);
  font-size: clamp(34px, 4vw, 56px);
  line-height: 0.98;
  letter-spacing: 0;
}

.owner-brief-hero .hero-copy {
  max-width: 720px;
  margin: 0;
  color: var(--brand-gray-700);
  font-size: 16px;
  line-height: 1.58;
}

.owner-brief-date {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.owner-brief-date span,
.owner-brief-date small {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(42, 111, 148, 0.14);
  color: var(--brand-gray-650);
  font-size: 12px;
  font-weight: 800;
}

.owner-brief-date span {
  color: var(--brand-blue-900);
}

.owner-brief-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  min-width: 250px;
}

.owner-money-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.owner-money-strip article,
.owner-attention-board,
.owner-lane,
.owner-side-panel {
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 14px 32px rgba(19, 32, 46, 0.06);
}

.owner-money-strip article {
  min-height: 118px;
  padding: 16px;
}

.owner-money-strip span,
.owner-brief-row p,
.owner-empty {
  color: var(--brand-gray-650);
}

.owner-money-strip span {
  display: block;
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.owner-money-strip strong {
  display: block;
  margin-top: 8px;
  color: var(--brand-blue-900);
  font-size: clamp(22px, 2.2vw, 30px);
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.owner-money-strip small {
  display: block;
  margin-top: 8px;
  color: var(--brand-gray-650);
  font-size: 12px;
}

.owner-money-strip .good {
  color: #0f7a3a;
}

.owner-money-strip .bad {
  color: #b42318;
}

.owner-attention-board,
.owner-lane,
.owner-side-panel {
  padding: 16px;
}

.owner-attention-list,
.owner-lanes,
.owner-secondary {
  display: grid;
  gap: 12px;
}

.owner-attention-row {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) 90px minmax(240px, 1.4fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 74px;
  padding: 13px 14px;
  border: 1px solid rgba(42, 111, 148, 0.12);
  border-radius: 8px;
  background: linear-gradient(135deg, rgba(248, 252, 255, 0.98), rgba(255, 255, 255, 0.92));
  color: inherit;
  text-decoration: none;
}

.owner-attention-row:hover,
.owner-brief-row:hover {
  border-color: rgba(243, 112, 33, 0.42);
  box-shadow: 0 12px 26px rgba(42, 111, 148, 0.10);
  color: inherit;
  text-decoration: none;
}

.owner-attention-row span,
.owner-brief-row strong {
  color: var(--brand-blue-900);
  font-weight: 850;
}

.owner-attention-row strong {
  color: var(--brand-blue);
  font-size: 24px;
  line-height: 1;
}

.owner-attention-row p,
.owner-attention-row em,
.owner-brief-row p {
  margin: 0;
  line-height: 1.45;
}

.owner-attention-row em {
  justify-self: end;
  padding: 6px 9px;
  border-radius: 999px;
  background: rgba(42, 111, 148, 0.08);
  color: var(--brand-gray-700);
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
  white-space: nowrap;
}

.owner-attention-row.warn {
  border-left: 4px solid var(--brand-orange);
}

.owner-attention-row.watch {
  border-left: 4px solid var(--brand-blue);
}

.owner-attention-row.ok {
  border-left: 4px solid #28a45f;
}

.owner-lanes {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.owner-secondary {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.owner-brief-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px 12px;
  padding: 12px 0;
  border-top: 1px solid rgba(42, 111, 148, 0.12);
  color: inherit;
  text-decoration: none;
}

.owner-brief-row:first-of-type {
  border-top: 0;
}

.owner-brief-row span {
  justify-self: end;
  color: var(--brand-orange);
  font-weight: 850;
  text-align: end;
}

.owner-brief-row p {
  grid-column: 1 / -1;
  font-size: 13px;
}

.owner-brief-row.slim {
  min-height: 54px;
  align-items: center;
}

.owner-empty {
  margin: 0;
  padding: 14px;
  border: 1px dashed rgba(42, 111, 148, 0.20);
  border-radius: 8px;
  background: rgba(232, 243, 249, 0.42);
  line-height: 1.45;
}

.customer-brief-shell {
  display: grid;
  gap: 18px;
}

.customer-brief-hero,
.customer-brief-board,
.customer-relationship-grid,
.customer-admin-grid,
.customer-brief-kpis {
  display: grid;
  gap: 14px;
}

.customer-brief-hero {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  padding: 30px;
  overflow: hidden;
  border: 1px solid rgba(42, 111, 148, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(216, 237, 248, 0.88), rgba(255, 255, 255, 0.94) 62%),
    linear-gradient(180deg, #ffffff, var(--brand-blue-050));
  box-shadow: 0 18px 42px rgba(20, 32, 51, 0.08);
}

.customer-brief-hero h1 {
  margin: 0;
  color: var(--brand-blue-900);
  font-size: clamp(32px, 4vw, 56px);
  line-height: 1.02;
  letter-spacing: 0;
}

.customer-brief-copy {
  max-width: 700px;
  margin: 12px 0 0;
  color: var(--brand-gray-650);
  font-size: 16px;
  line-height: 1.6;
}

.customer-brief-meta,
.customer-brief-actions,
.customer-card-head,
.customer-step-form {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.customer-brief-meta {
  margin-top: 16px;
}

.customer-brief-meta > span:not(.status) {
  padding: 7px 10px;
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
  color: var(--brand-gray-700);
  font-size: 12px;
  font-weight: 800;
}

.customer-brief-actions {
  justify-content: flex-end;
}

.customer-brief-kpis {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.customer-brief-kpi,
.customer-section-card {
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 30px rgba(20, 32, 51, 0.06);
}

.customer-brief-kpi {
  min-height: 128px;
  padding: 16px;
}

.customer-brief-kpi span,
.card-kicker {
  display: block;
  color: var(--brand-gray-650);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.customer-brief-kpi strong {
  display: block;
  margin: 8px 0;
  color: var(--brand-blue-900);
  font-size: 24px;
  line-height: 1.1;
}

.customer-brief-kpi p,
.customer-section-card p,
.customer-empty,
.customer-mini-row span {
  color: var(--brand-gray-650);
  line-height: 1.45;
}

.customer-brief-kpi p,
.customer-section-card p {
  margin: 0;
}

.customer-brief-board {
  grid-template-columns: minmax(280px, 0.85fr) minmax(0, 1.15fr);
}

.customer-section-card {
  padding: 18px;
}

.customer-section-card h2 {
  margin: 8px 0 12px;
  color: var(--brand-gray-950);
  font-size: 22px;
  letter-spacing: 0;
}

.customer-next-card {
  border-color: rgba(243, 112, 33, 0.26);
  background: linear-gradient(180deg, #ffffff, rgba(255, 232, 214, 0.38));
}

.customer-next-card .btn {
  margin-top: 16px;
}

.customer-fact-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.customer-fact {
  min-width: 0;
  padding: 12px;
  border: 1px solid rgba(42, 111, 148, 0.12);
  border-radius: 8px;
  background: rgba(232, 243, 249, 0.42);
}

.customer-fact span {
  display: block;
  color: var(--brand-gray-650);
  font-size: 12px;
  font-weight: 800;
}

.customer-fact strong {
  display: block;
  margin-top: 5px;
  color: var(--brand-blue-900);
  font-size: 14px;
  overflow-wrap: anywhere;
}

.customer-relationship-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.customer-admin-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.customer-card-head {
  justify-content: space-between;
  margin-bottom: 12px;
}

.customer-card-head h2 {
  margin-bottom: 0;
}

.customer-mini-list {
  display: grid;
  gap: 8px;
}

.customer-mini-row {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid rgba(42, 111, 148, 0.12);
  border-radius: 8px;
  background: rgba(248, 252, 255, 0.84);
  color: inherit;
  text-decoration: none;
}

.customer-mini-row:hover {
  border-color: rgba(243, 112, 33, 0.38);
  text-decoration: none;
}

.customer-mini-row strong {
  color: var(--brand-gray-950);
  font-size: 14px;
  overflow-wrap: anywhere;
}

.customer-mini-row p {
  margin-top: 4px;
}

.customer-mini-row-static:hover {
  border-color: rgba(42, 111, 148, 0.12);
}

.customer-empty {
  padding: 13px;
  border: 1px dashed rgba(42, 111, 148, 0.22);
  border-radius: 8px;
  background: rgba(232, 243, 249, 0.45);
}

.customer-empty + .btn {
  margin-top: 12px;
}

.customer-step-panel summary,
.customer-edit-panel summary,
.customer-advanced-panel summary {
  cursor: pointer;
  color: var(--brand-blue-900);
  font-weight: 900;
}

.customer-step-panel[open] summary,
.customer-edit-panel[open] summary,
.customer-advanced-panel[open] summary {
  margin-bottom: 12px;
}

.customer-step-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.customer-step-form {
  justify-content: space-between;
  padding: 12px;
  border: 1px solid rgba(42, 111, 148, 0.12);
  border-radius: 8px;
  background: rgba(248, 252, 255, 0.82);
}

.customer-step-form input[type="text"] {
  flex: 1 1 180px;
}

.customer-edit-form {
  margin-top: 14px;
}

.drill-shell {
  display: grid;
  gap: 18px;
}

.drill-hero,
.drill-kpis,
.drill-card-board {
  display: grid;
  gap: 14px;
}

.drill-hero {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  padding: 30px;
  border: 1px solid rgba(42, 111, 148, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(216, 237, 248, 0.9), rgba(255, 255, 255, 0.95) 64%),
    linear-gradient(180deg, #ffffff, var(--brand-blue-050));
  box-shadow: 0 18px 42px rgba(20, 32, 51, 0.08);
}

.drill-hero h1 {
  margin: 0;
  color: var(--brand-blue-900);
  font-size: clamp(30px, 4vw, 52px);
  line-height: 1.04;
  letter-spacing: 0;
}

.drill-copy {
  max-width: 720px;
  margin: 12px 0 0;
  color: var(--brand-gray-650);
  line-height: 1.6;
}

.drill-kpis {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.drill-kpis article,
.drill-card,
.drill-empty {
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 30px rgba(20, 32, 51, 0.06);
}

.drill-kpis article {
  padding: 16px;
}

.drill-kpis span {
  display: block;
  color: var(--brand-gray-650);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.drill-kpis strong {
  display: block;
  margin: 8px 0;
  color: var(--brand-blue-900);
  font-size: 26px;
  line-height: 1.1;
}

.drill-kpis p,
.drill-copy,
.drill-empty p,
.drill-detail-list span,
.drill-facts span {
  color: var(--brand-gray-650);
}

.drill-kpis p,
.drill-empty p {
  margin: 0;
  line-height: 1.45;
}

.drill-card-board {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.drill-card,
.drill-empty {
  padding: 18px;
}

.drill-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.drill-card h2,
.drill-empty h2 {
  margin: 6px 0 0;
  color: var(--brand-gray-950);
  font-size: 20px;
  letter-spacing: 0;
}

.drill-facts,
.drill-detail-list {
  display: grid;
  gap: 8px;
}

.drill-facts {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.drill-facts div,
.drill-detail-list div {
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(42, 111, 148, 0.12);
  border-radius: 8px;
  background: rgba(248, 252, 255, 0.84);
}

.drill-facts span,
.drill-detail-list span {
  display: block;
  margin-bottom: 4px;
  font-size: 12px;
  font-weight: 800;
}

.drill-facts strong,
.drill-detail-list strong {
  color: var(--brand-blue-900);
  font-size: 14px;
  overflow-wrap: anywhere;
}

.drill-details {
  margin-top: 12px;
}

.drill-details summary {
  cursor: pointer;
  color: var(--brand-orange);
  font-size: 12px;
  font-weight: 900;
}

.drill-details[open] summary {
  margin-bottom: 10px;
}

.erp-brief-shell {
  display: grid;
  gap: 18px;
}

.erp-brief-hero,
.erp-brief-kpis,
.erp-card-board {
  display: grid;
  gap: 14px;
}

.erp-brief-hero {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  padding: 30px;
  border: 1px solid rgba(42, 111, 148, 0.18);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(216, 237, 248, 0.9), rgba(255, 255, 255, 0.95) 64%),
    linear-gradient(180deg, #ffffff, var(--brand-blue-050));
  box-shadow: 0 18px 42px rgba(20, 32, 51, 0.08);
}

.erp-brief-hero h1 {
  margin: 0;
  color: var(--brand-blue-900);
  font-size: clamp(30px, 4vw, 52px);
  line-height: 1.04;
  letter-spacing: 0;
}

.erp-brief-copy,
.erp-help,
.erp-record-card p,
.erp-empty p,
.erp-brief-kpis p,
.erp-facts span {
  color: var(--brand-gray-650);
  line-height: 1.48;
}

.erp-brief-copy {
  max-width: 720px;
  margin: 12px 0 0;
}

.erp-brief-kpis {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.erp-brief-kpis article,
.erp-record-card,
.erp-empty,
.erp-form-card {
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 12px 30px rgba(20, 32, 51, 0.06);
}

.erp-brief-kpis article,
.erp-record-card,
.erp-empty,
.erp-form-card {
  padding: 18px;
}

.erp-brief-kpis span {
  display: block;
  color: var(--brand-gray-650);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.erp-brief-kpis strong {
  display: block;
  margin: 8px 0;
  color: var(--brand-blue-900);
  font-size: 25px;
  line-height: 1.1;
}

.erp-brief-kpis p,
.erp-record-card p,
.erp-empty p {
  margin: 0;
}

.erp-card-board {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.erp-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.erp-card-head h2,
.erp-empty h2,
.erp-form-card h2 {
  margin: 6px 0 0;
  color: var(--brand-gray-950);
  font-size: 21px;
  letter-spacing: 0;
}

.erp-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 14px;
}

.erp-facts div {
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(42, 111, 148, 0.12);
  border-radius: 8px;
  background: rgba(248, 252, 255, 0.84);
}

.erp-facts span {
  display: block;
  margin-bottom: 4px;
  font-size: 12px;
  font-weight: 800;
}

.erp-facts strong {
  color: var(--brand-blue-900);
  font-size: 14px;
  overflow-wrap: anywhere;
}

.erp-form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}

.erp-form-wide {
  grid-column: 1 / -1;
}

.erp-help {
  margin: 10px 0 0;
  font-size: 13px;
}

.studio-advanced {
  margin: 12px 0;
  color: var(--brand-gray-650);
  font-size: 14px;
}

.studio-advanced summary {
  cursor: pointer;
  color: var(--brand-blue-900);
  font-weight: 900;
}

.studio-advanced[open] summary {
  margin-bottom: 10px;
}

.studio-preview {
  display: grid;
  gap: 6px;
  margin-top: 16px;
  padding: 14px;
  border: 1px solid rgba(243, 112, 33, 0.24);
  border-radius: 8px;
  background: linear-gradient(180deg, #ffffff, rgba(255, 232, 214, 0.34));
}

.studio-preview span,
.studio-preview small {
  color: var(--brand-gray-650);
  font-size: 12px;
  font-weight: 850;
}

.studio-preview strong {
  color: var(--brand-blue-900);
  font-size: 20px;
}

.studio-preview p {
  margin: 0;
  color: var(--brand-gray-650);
}

.admin-type-edit {
  flex: 0 0 auto;
}

.module-preference-board {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 12px;
}

.module-preference-card {
  border: 1px solid rgba(42, 111, 148, 0.16);
  border-left: 3px solid rgba(243, 112, 33, 0.48);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255,255,255,0.96), rgba(238,247,255,0.80));
  box-shadow: 0 10px 24px rgba(19, 32, 46, 0.06);
}

.module-preference-card.is-hidden {
  border-left-color: rgba(90, 104, 120, 0.45);
  opacity: 0.82;
}

.module-preference-card form {
  display: grid;
  gap: 9px;
  padding: 14px;
}

.module-pref-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.module-pref-head span,
.module-pref-head small {
  color: var(--brand-gray-650);
  font-size: 11px;
  font-weight: 850;
}

.module-pref-head strong {
  display: block;
  margin-top: 3px;
  color: var(--brand-blue-900);
  font-size: 17px;
  line-height: 1.25;
}

.module-pref-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  color: var(--brand-gray-700);
  font-size: 13px;
  font-weight: 850;
}

.route-action-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
  margin: 18px 0;
}

.route-action-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 150px;
  padding: 18px;
  border: 1px solid rgba(16, 104, 168, 0.14);
  border-left: 4px solid var(--brand-orange);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(238, 247, 255, 0.86));
  box-shadow: 0 12px 28px rgba(30, 78, 128, 0.08);
}

.route-action-card span {
  color: var(--brand-gray-650);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.route-action-card strong {
  color: var(--brand-blue-900);
  font-size: 18px;
}

.route-action-card p {
  margin: 0;
  color: var(--brand-gray-650);
  line-height: 1.5;
}

.route-action-card .btn {
  align-self: flex-start;
  margin-top: auto;
}

.custom-advanced {
  margin: 18px 0;
  border: 1px solid rgba(16, 104, 168, 0.16);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
}

.custom-advanced > summary {
  cursor: pointer;
  padding: 14px 16px;
  color: var(--brand-blue-900);
  font-weight: 900;
}

.custom-advanced[open] {
  padding: 0 14px 14px;
}

.custom-advanced[open] > summary {
  margin: 0 -14px 14px;
  border-bottom: 1px solid rgba(16, 104, 168, 0.12);
  background: rgba(230, 243, 255, 0.72);
}

.submodule-brief-shell {
  display: grid;
  gap: 18px;
}

.submodule-hero {
  margin-bottom: 0;
}

.submodule-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr));
  gap: 12px;
}

.submodule-kpi-grid article,
.submodule-empty,
.submodule-record-card {
  border: 1px solid rgba(42, 111, 148, 0.15);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 10px 24px rgba(19, 32, 46, 0.06);
}

.submodule-kpi-grid article {
  min-height: 112px;
  padding: 14px;
}

.submodule-kpi-grid span,
.submodule-card-head span,
.submodule-facts span,
.submodule-record-details dt {
  display: block;
  color: var(--brand-gray-650);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.submodule-kpi-grid strong {
  display: block;
  margin-top: 6px;
  color: var(--brand-blue-900);
  font-size: 24px;
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.submodule-kpi-grid p,
.submodule-record-card p {
  margin: 7px 0 0;
  color: var(--brand-gray-650);
  line-height: 1.45;
}

.submodule-empty {
  padding: 18px;
}

.submodule-record-board {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 310px), 1fr));
  gap: 12px;
}

.submodule-record-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
  padding: 14px;
  border-left: 3px solid rgba(243, 112, 33, 0.45);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.97), rgba(248,252,255,0.92)),
    linear-gradient(135deg, rgba(216,237,248,0.35), rgba(255,246,238,0.28));
}

.submodule-card-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: flex-start;
}

.submodule-card-head h2 {
  margin: 3px 0 0;
  color: var(--brand-blue-900);
  font-size: 18px;
  line-height: 1.24;
  overflow-wrap: anywhere;
}

.submodule-card-head .status {
  max-width: 150px;
  white-space: normal;
  text-align: center;
}

.submodule-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 130px), 1fr));
  gap: 8px;
}

.submodule-facts div {
  min-width: 0;
  min-height: 56px;
  padding: 8px;
  border: 1px solid rgba(42, 111, 148, 0.11);
  border-radius: 8px;
  background: rgba(232, 243, 249, 0.62);
}

.submodule-facts b {
  display: block;
  margin-top: 3px;
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 750;
  overflow-wrap: anywhere;
}

.submodule-record-details {
  margin-top: auto;
  border: 1px solid rgba(42, 111, 148, 0.12);
  border-radius: 8px;
  background: rgba(255,255,255,0.70);
  overflow: hidden;
}

.submodule-record-details summary {
  cursor: pointer;
  padding: 9px 10px;
  color: var(--brand-blue-900);
  font-size: 13px;
  font-weight: 850;
}

.submodule-record-details dl {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
  padding: 10px;
  border-top: 1px solid rgba(42,111,148,0.10);
}

.submodule-record-details dd {
  margin: 3px 0 0;
  color: var(--ink-2);
  font-size: 13px;
  overflow-wrap: anywhere;
}

.finance-report-shell {
  display: grid;
  gap: 18px;
}

.finance-report-hero {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 18px;
  padding: 24px;
  border: 1px solid rgba(42, 111, 148, 0.16);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(216, 237, 248, 0.86), rgba(255,255,255,0.76)),
    linear-gradient(180deg, #ffffff, #f7fbff);
  box-shadow: 0 16px 36px rgba(19, 32, 46, 0.08);
}

.finance-report-hero h1 {
  margin: 0;
  color: var(--brand-blue-900);
  font-size: clamp(28px, 3vw, 44px);
  line-height: 1.05;
}

.finance-report-hero p {
  margin: 10px 0 0;
  max-width: 680px;
  color: var(--brand-gray-650);
  line-height: 1.55;
}

.finance-report-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
}

.finance-report-actions form {
  display: flex;
  align-items: center;
  gap: 8px;
}

.finance-report-actions label {
  color: var(--brand-gray-700);
  font-size: 12px;
  font-weight: 850;
}

.finance-report-actions select {
  min-height: 38px;
  border: 1px solid rgba(42, 111, 148, 0.22);
  border-radius: 8px;
  background: #fff;
  color: var(--ink-1);
}

.finance-report-kpis,
.finance-report-sections {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr));
  gap: 12px;
}

.finance-report-kpis article,
.finance-report-card,
.finance-board-card {
  border: 1px solid rgba(42, 111, 148, 0.15);
  border-radius: 8px;
  background: rgba(255,255,255,0.88);
  box-shadow: 0 10px 24px rgba(19, 32, 46, 0.06);
}

.finance-report-kpis article {
  min-height: 110px;
  padding: 14px;
}

.finance-report-kpis span,
.finance-report-card span,
.finance-board-card span {
  display: block;
  color: var(--brand-gray-650);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.finance-report-kpis strong {
  display: block;
  margin-top: 7px;
  color: var(--brand-blue-900);
  font-size: 24px;
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.finance-report-kpis p,
.finance-report-card p,
.finance-board-card p {
  margin: 7px 0 0;
  color: var(--brand-gray-650);
  line-height: 1.45;
}

.finance-report-card,
.finance-board-card {
  display: grid;
  gap: 8px;
  min-height: 150px;
  padding: 16px;
  border-left: 3px solid rgba(243, 112, 33, 0.44);
}

.finance-report-card strong,
.finance-board-card strong {
  color: var(--brand-blue-900);
  font-size: 20px;
  line-height: 1.2;
}

.finance-report-note {
  padding: 12px 14px;
  border: 1px solid rgba(42,111,148,0.16);
  border-radius: 8px;
  background: rgba(232, 243, 249, 0.72);
  color: var(--brand-gray-700);
  font-weight: 800;
}

.finance-report-note.is-warning {
  border-color: rgba(243,112,33,0.30);
  background: rgba(255,246,238,0.82);
  color: #7b3a12;
}

.finance-report-advanced .rpt-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.finance-report-advanced .rpt-table th,
.finance-report-advanced .rpt-table td {
  padding: 8px 10px;
  border-bottom: 1px solid rgba(42,111,148,0.12);
  text-align: left;
}

.finance-report-advanced .rpt-table th {
  color: var(--brand-blue-900);
  background: rgba(232,243,249,0.86);
}

.finance-report-advanced .rpt-table .num {
  text-align: right;
  white-space: nowrap;
}

.finance-report-advanced .section-head td,
.finance-report-advanced .subtotal td,
.finance-report-advanced .grand-total td {
  font-weight: 900;
  color: var(--brand-blue-900);
  background: rgba(232,243,249,0.68);
}

.finance-report-advanced .grand-total td {
  border-top: 2px solid rgba(243,112,33,0.42);
}

.neg,
.finance-report-kpis .is-negative,
.finance-report-card .is-negative {
  color: var(--accent-crimson);
}

.finance-board-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
  gap: 12px;
}

.inline-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.pmo-dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr);
  gap: 12px;
}

.pmo-split-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.status-inline {
  margin-inline-start: 6px;
}

.heatmap-table th,
.heatmap-table td {
  font-size: 11px;
  padding: 4px 6px;
}

.heatmap-table tbody td {
  color: #1a1a1a;
  font-weight: 500;
}

.fill-full {
  width: 100%;
}

.restaurant-channel-note {
  margin-top: 8px;
}

.heat-level-0 { background: rgba(214, 156, 69, 0.06); }
.heat-level-1 { background: rgba(214, 156, 69, 0.13); }
.heat-level-2 { background: rgba(214, 156, 69, 0.20); }
.heat-level-3 { background: rgba(214, 156, 69, 0.27); }
.heat-level-4 { background: rgba(214, 156, 69, 0.34); }
.heat-level-5 { background: rgba(214, 156, 69, 0.41); }
.heat-level-6 { background: rgba(214, 156, 69, 0.48); }
.heat-level-7 { background: rgba(214, 156, 69, 0.55); }
.heat-level-8 { background: rgba(214, 156, 69, 0.62); }
.heat-level-9 { background: rgba(214, 156, 69, 0.69); }
.heat-level-10 { background: rgba(214, 156, 69, 0.76); }

@media (max-width: 860px) {
  .pmo-dashboard-grid,
  .pmo-split-grid {
    grid-template-columns: 1fr;
  }
}

.text-link {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  color: var(--brand-orange);
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
  white-space: nowrap;
}

.text-link:hover {
  color: var(--brand-orange-hover);
  text-decoration: none;
}

@media (max-width: 900px) {
  .table-kpi-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .owner-money-strip,
  .owner-lanes,
  .owner-secondary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .owner-brief-hero,
  .owner-attention-row {
    grid-template-columns: 1fr;
  }

  .owner-brief-actions,
  .owner-attention-row em {
    justify-self: start;
  }

  .customer-brief-hero,
  .customer-brief-board,
  .customer-admin-grid {
    grid-template-columns: 1fr;
  }

  .customer-brief-actions {
    justify-content: flex-start;
  }

  .customer-brief-kpis,
  .customer-relationship-grid,
  .customer-fact-grid,
  .drill-kpis,
  .drill-card-board,
  .erp-brief-kpis,
  .erp-card-board {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .drill-hero,
  .erp-brief-hero {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .table-dashboard-head,
  .table-fast-filters,
  .list-search-form {
    align-items: stretch;
    flex-direction: column;
  }

  .table-kpi-strip {
    grid-template-columns: 1fr;
  }

  .customer-brief-hero {
    padding: 22px;
  }

  .customer-brief-kpis,
  .customer-relationship-grid,
  .customer-fact-grid,
  .drill-kpis,
  .drill-card-board,
  .drill-facts,
  .erp-brief-kpis,
  .erp-card-board,
  .erp-facts {
    grid-template-columns: 1fr;
  }

  .table-fast-filters input,
  .table-fast-filters select,
  .list-search-form input,
  .list-search-form select {
    width: 100% !important;
  }

  .owner-brief-shell {
    gap: 14px;
  }

  .owner-brief-hero,
  .owner-attention-board,
  .owner-lane,
  .owner-side-panel {
    padding: 14px;
  }

  .owner-brief-hero h1 {
    font-size: 34px;
    line-height: 1.02;
  }

  .owner-brief-actions,
  .owner-brief-actions .btn {
    width: 100%;
  }

  .owner-money-strip,
  .owner-lanes,
  .owner-secondary {
    grid-template-columns: 1fr;
  }

  .owner-attention-row strong {
    font-size: 22px;
  }

  .owner-brief-row {
    grid-template-columns: 1fr;
  }

  .owner-brief-row span {
    justify-self: start;
    text-align: start;
  }
}

/* Rich shared module lists -------------------------------------------------- */
.list-card-rich {
  display: grid;
  gap: 14px;
  padding: 16px !important;
  border: 1px solid rgba(243, 112, 33, 0.28) !important;
  background:
    linear-gradient(135deg, rgba(232, 243, 249, 0.92), rgba(255, 250, 246, 0.90)),
    #ffffff !important;
  box-shadow: 0 16px 38px rgba(19, 32, 46, 0.07) !important;
}

.list-board-note {
  margin: 0;
  padding: 10px 12px;
  border: 1px solid rgba(243, 112, 33, 0.18);
  border-radius: 8px;
  background: rgba(255, 246, 238, 0.74);
  color: #7b3a12;
  font-size: 13px;
  font-weight: 800;
}

.list-card-rich .empty-mascot {
  width: auto !important;
  height: auto !important;
  min-height: 220px;
  max-width: 620px;
  padding: 28px 20px !important;
}

.list-card-rich .empty-mascot-title,
.list-card-rich .empty-mascot-body {
  max-width: 100%;
}

.list-summary-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 158px), 1fr));
  gap: 10px;
}

.list-summary-tile {
  display: grid;
  align-content: start;
  gap: 5px;
  min-width: 0;
  min-height: 82px;
  padding: 12px;
  border: 1px solid rgba(42, 111, 148, 0.13);
  border-top: 3px solid rgba(243, 112, 33, 0.42);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 8px 18px rgba(19, 32, 46, 0.04);
}

.list-summary-tile span,
.list-record-eyebrow,
.list-record-chip b,
.list-record-details dt {
  display: block;
  color: var(--brand-gray-650);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.list-summary-tile strong {
  display: block;
  color: var(--brand-blue-900);
  font-size: 1.08rem;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

@supports selector(body:has(*)) {
  body:has(.page-actions a[href="/ops/opening-checklist/new"]) .list-summary-strip .list-summary-tile:nth-child(3) {
    display: none;
  }

  body:has(.page-actions a[href="/procurement/pr/new"]) .list-record-actions .btn,
  body:has(.page-actions a[href="/ops/opening-checklist/new"]) .list-record-actions .btn {
    max-width: 100%;
    white-space: normal !important;
    overflow-wrap: anywhere;
    line-height: 1.2;
    text-align: center;
  }
}

.list-record-board {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: 12px;
  align-items: stretch;
  max-height: none;
  overflow: visible;
  padding: 2px 4px 4px 2px;
}

.daily-close-form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr));
  gap: 10px;
  padding: 14px;
}

.daily-close-form label {
  display: grid;
  gap: 6px;
  color: var(--brand-gray-700);
  font-size: 12px;
  font-weight: 850;
}

.daily-close-form-wide {
  grid-column: 1 / -1;
}

.list-record-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
  height: auto;
  min-height: 226px;
  padding: 14px;
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-left: 3px solid rgba(243, 112, 33, 0.38);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.97), rgba(248, 252, 255, 0.93)),
    linear-gradient(135deg, rgba(216, 237, 248, 0.42), rgba(255, 246, 238, 0.34));
  box-shadow: 0 10px 24px rgba(19, 32, 46, 0.06);
  overflow: hidden;
}

.list-record-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: linear-gradient(90deg, rgba(42, 111, 148, 0.52), rgba(243, 112, 33, 0.54));
  pointer-events: none;
}

.list-record-card:hover {
  border-color: rgba(243, 112, 33, 0.36);
  box-shadow: 0 14px 30px rgba(19, 32, 46, 0.10);
}

.list-record-head {
  display: grid;
  align-items: flex-start;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  min-width: 0;
}

.list-record-head .status {
  max-width: 150px;
  white-space: normal;
  overflow-wrap: anywhere;
  text-align: center;
}

.list-record-title {
  display: block;
  margin-top: 4px;
  color: var(--brand-blue-900);
  font-size: 17px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.list-record-summary {
  margin: 0;
  color: var(--brand-gray-700);
  font-size: 14px;
  font-weight: 750;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.list-record-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.list-record-brief,
.list-record-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 138px), 1fr));
  gap: 8px;
}

.list-record-brief span,
.list-record-chip,
.list-record-fact {
  display: grid;
  gap: 3px;
  min-width: 0;
  min-height: 58px;
  padding: 8px 9px;
  border: 1px solid rgba(42, 111, 148, 0.11);
  border-radius: 8px;
  background: rgba(232, 243, 249, 0.62);
}

.list-record-brief span {
  background: rgba(255, 255, 255, 0.72);
  border-color: rgba(42, 111, 148, 0.14);
}

.list-record-brief b,
.list-record-brief em,
.list-record-chip em,
.list-record-fact em {
  min-width: 0;
  overflow-wrap: anywhere;
}

.list-record-brief b {
  color: var(--brand-gray-650);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.list-record-brief em,
.list-record-chip em,
.list-record-fact em {
  color: var(--ink-2);
  font-size: 13px;
  font-style: normal;
  line-height: 1.25;
}

.list-record-chip.is-missing,
.list-record-fact.is-missing,
.list-record-details dd.is-missing,
.list-data-table .list-cell-empty {
  color: #8a5a35 !important;
  background: rgba(255, 246, 238, 0.74) !important;
}

.list-record-note {
  margin: 0;
  padding: 9px 10px;
  border: 1px solid rgba(243, 112, 33, 0.20);
  border-radius: 8px;
  background: rgba(255, 246, 238, 0.72);
  color: #7b3a12;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.35;
}

.list-record-details {
  border: 1px solid rgba(42, 111, 148, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.68);
  overflow: hidden;
}

.list-record-details summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  cursor: pointer;
  padding: 9px 10px;
  color: var(--brand-blue-900);
  font-size: 13px;
  font-weight: 850;
}

.list-record-details summary span {
  color: var(--brand-orange);
  font-size: 11px;
  font-weight: 850;
}

.list-record-details dl {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
  padding: 10px;
  border-top: 1px solid rgba(42, 111, 148, 0.10);
}

.list-record-details dl > div {
  min-width: 0;
}

.list-record-details dd {
  margin: 3px 0 0;
  color: var(--ink-2);
  font-size: 13px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.list-record-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
  margin-top: auto;
  position: relative;
  z-index: 2;
}

.list-record-actions .btn {
  position: relative;
  z-index: 3;
}

.list-advanced {
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  overflow: hidden;
}

.list-advanced > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
  padding: 12px 14px;
  color: var(--brand-blue-900);
  font-size: 14px;
  font-weight: 850;
}

.list-advanced > summary span {
  color: var(--brand-gray-650);
  font-size: 12px;
  font-weight: 750;
}

.list-advanced[open] > summary {
  border-bottom: 1px solid rgba(42, 111, 148, 0.12);
  background: rgba(232, 243, 249, 0.58);
}

.list-table-shell {
  width: 100%;
  min-width: 0;
  max-height: min(60vh, 620px);
  overflow: auto;
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-radius: 8px;
  background: #ffffff;
}

.list-data-table,
.content .list-data-table {
  width: max(100%, calc(var(--list-column-count, 8) * 132px)) !important;
  min-width: max(100%, calc(var(--list-column-count, 8) * 132px)) !important;
  border-collapse: collapse;
  table-layout: fixed;
}

.list-data-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  vertical-align: bottom;
}

.list-card-rich .th-sort {
  min-height: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: inherit !important;
  font-size: 11px !important;
  font-weight: 850 !important;
  line-height: 1.25 !important;
  text-align: inherit !important;
  text-transform: uppercase;
}

.list-card-rich .th-sort::after {
  margin-inline-start: 4px;
}

.list-data-table th,
.list-data-table td {
  min-width: 132px;
  width: 132px;
  max-width: 220px;
  white-space: nowrap;
}

.list-data-table th:first-child,
.list-data-table td:first-child {
  min-width: 140px;
  width: 140px;
}

.list-data-table th:last-child,
.list-data-table td:last-child {
  min-width: 96px;
  width: 96px;
}

.list-data-table th[data-col="id"],
.list-data-table td[data-col="id"] {
  min-width: 140px;
  width: 140px;
}

.list-data-table td {
  overflow: hidden;
  text-overflow: ellipsis;
}

.list-data-table td[data-col="notes"],
.list-data-table td[data-col="description"],
.list-data-table td[data-col="reason"] {
  min-width: 260px;
  width: 260px;
  max-width: 320px;
  white-space: normal;
}

.list-data-table tbody tr:nth-child(even) td {
  background: rgba(232, 243, 249, 0.30);
}

.list-data-table tbody tr:hover td {
  background: rgba(47, 111, 236, 0.07) !important;
}

.record-page-sub {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  min-width: 0;
}

.record-page-sub > span:not(.status) {
  color: var(--ink-3);
  overflow-wrap: anywhere;
}

.record-brief-card {
  display: grid;
  gap: 14px;
  padding: 16px;
  margin-bottom: 14px;
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-left: 4px solid rgba(243, 112, 33, 0.52);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(232, 243, 249, 0.94), rgba(255, 246, 238, 0.76)),
    #ffffff;
  box-shadow: 0 14px 34px rgba(20, 32, 51, 0.08);
  min-width: 0;
}

.record-brief-head {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-start;
  min-width: 0;
}

.record-brief-head strong {
  display: block;
  margin-top: 3px;
  color: var(--brand-blue-900);
  font-size: 20px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.record-brief-eyebrow {
  color: var(--brand-orange);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.record-brief-copy {
  margin: 0;
  color: var(--ink-3);
  font-size: 14px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.record-brief-facts,
.record-detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 10px;
}

.record-brief-facts span,
.record-detail-grid > div {
  min-width: 0;
  padding: 10px;
  border: 1px solid rgba(42, 111, 148, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.84);
}

.record-brief-facts b,
.record-detail-grid dt {
  display: block;
  color: var(--ink-4);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.record-brief-facts em,
.record-detail-grid dd {
  display: block;
  margin: 4px 0 0;
  color: var(--ink-2);
  font-size: 13px;
  font-style: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.record-technical-details {
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-radius: 8px;
  background: rgba(248, 252, 255, 0.76);
  overflow: hidden;
}

.record-technical-details > summary {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  cursor: pointer;
  color: var(--brand-blue-900);
  font-size: 13px;
  font-weight: 850;
}

.record-technical-details > summary span {
  color: var(--ink-4);
  font-size: 12px;
}

.record-technical-details[open] > summary {
  border-bottom: 1px solid rgba(42, 111, 148, 0.12);
}

.record-detail-grid {
  padding: 12px;
}

.record-side-card {
  display: grid;
  gap: 10px;
  border-left: 4px solid rgba(42, 111, 148, 0.34) !important;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(232, 243, 249, 0.72)),
    #ffffff !important;
  min-width: 0;
}

.record-actions-card {
  border-left-color: rgba(243, 112, 33, 0.52) !important;
}

.record-action-form,
.record-workflow-form {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
}

.record-action-form {
  margin-top: 8px;
}

.record-action-form label {
  flex: 1 0 100%;
}

.record-action-form input,
.record-workflow-reason {
  flex: 1 1 180px;
  min-width: 0;
}

.record-action-btn,
.record-workflow-btn {
  max-width: 100%;
  white-space: normal !important;
  overflow-wrap: anywhere;
  text-align: center;
}

.record-status-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid rgba(42, 111, 148, 0.12);
  border-radius: 8px;
  background: rgba(232, 243, 249, 0.58);
  color: var(--brand-gray-700);
  font-size: 12px;
  font-weight: 800;
}

.record-status-line b {
  color: var(--brand-blue-900);
  overflow-wrap: anywhere;
}

.record-workflow-card .text-mute {
  overflow-wrap: anywhere;
}

.record-activity-item {
  min-width: 0;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
}

.record-activity-item:last-child {
  border-bottom: 0;
}

.record-activity-meta {
  color: var(--ink-4);
  font-size: 11px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.record-activity-item .fw-600 {
  overflow-wrap: anywhere;
}

.portal-note {
  padding: 14px 16px;
  margin-bottom: 14px;
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 10px 24px rgba(20, 32, 51, 0.06);
}

.portal-kpi-strip,
.portal-tile-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.portal-kpi-tile,
.portal-tile {
  display: block;
  min-width: 0;
  padding: 16px;
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-radius: 8px;
  background: #ffffff;
  color: inherit;
  text-decoration: none;
  box-shadow: 0 10px 24px rgba(20, 32, 51, 0.06);
}

.portal-tile {
  min-height: 132px;
}

.portal-tile:hover {
  border-color: rgba(243, 112, 33, 0.58);
  box-shadow: 0 16px 34px rgba(20, 32, 51, 0.10);
}

.portal-tile h3 {
  margin: 5px 0 7px;
  color: var(--brand-blue-900);
  font-size: 16px;
  line-height: 1.2;
}

.portal-tile p {
  margin: 0;
}

.portal-tile-head,
.portal-action-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.portal-tile-head {
  justify-content: space-between;
  margin-bottom: 8px;
}

.portal-tile-action {
  margin-top: 12px;
  color: var(--brand-orange);
  font-size: 12px;
  font-weight: 850;
}

.workbench-shell {
  display: grid;
  gap: 18px;
}

.workbench-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 16px;
  padding: 18px;
  border: 1px solid rgba(42, 111, 148, 0.16);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(232, 243, 249, 0.92), rgba(255, 248, 242, 0.86)),
    #ffffff;
  box-shadow: 0 12px 30px rgba(20, 32, 51, 0.07);
}

.workbench-hero h1 {
  margin: 4px 0 6px;
  color: var(--brand-blue-900);
  font-size: clamp(1.8rem, 3vw, 2.7rem);
  line-height: 1.05;
}

.workbench-hero p,
.workbench-card p {
  margin: 0;
  color: var(--brand-gray-700);
  line-height: 1.45;
}

.workbench-actions,
.workbench-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.workbench-actions {
  justify-content: flex-end;
}

.workbench-toolbar {
  padding: 12px;
  border: 1px solid rgba(42, 111, 148, 0.13);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
}

.workbench-toolbar input,
.workbench-toolbar select {
  min-height: 40px;
  min-width: min(100%, 160px);
  padding: 8px 10px;
  border: 1px solid rgba(42, 111, 148, 0.20);
  border-radius: 8px;
  background: #ffffff;
  color: var(--brand-blue-900);
}

.workbench-toolbar input {
  flex: 1 1 220px;
}

.workbench-kpis,
.workbench-card-grid,
.workbench-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  gap: 12px;
}

.workbench-list {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
}

.workbench-card {
  display: grid;
  gap: 10px;
  min-width: 0;
  padding: 14px;
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-left: 3px solid rgba(243, 112, 33, 0.44);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 10px 24px rgba(20, 32, 51, 0.06);
}

.workbench-card h2,
.workbench-card h3 {
  margin: 0;
  color: var(--brand-blue-900);
  font-size: 1rem;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.workbench-card > span,
.workbench-kicker,
.workbench-facts span {
  color: var(--brand-gray-650);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.workbench-card strong {
  color: var(--brand-blue-900);
  overflow-wrap: anywhere;
}

.workbench-card-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.workbench-facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 130px), 1fr));
  gap: 8px;
}

.workbench-facts div {
  display: grid;
  gap: 3px;
  min-width: 0;
  min-height: 56px;
  padding: 8px;
  border: 1px solid rgba(42, 111, 148, 0.11);
  border-radius: 8px;
  background: rgba(232, 243, 249, 0.58);
}

.workbench-facts b {
  color: var(--ink-2);
  font-size: 13px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.confidence-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(232, 243, 249, 0.86);
  color: var(--brand-blue-900);
  font-weight: 850;
}

.confidence-pill.is-low {
  background: rgba(255, 246, 238, 0.92);
  color: #8a4b19;
}

.workbench-document {
  display: grid;
  grid-template-columns: minmax(260px, 360px) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.workbench-preview {
  min-height: 260px;
  border: 1px dashed rgba(42, 111, 148, 0.24);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
  display: grid;
  place-items: center;
  overflow: hidden;
}

.workbench-preview img {
  display: block;
  width: 100%;
  max-height: 360px;
  object-fit: contain;
}

.workbench-detail-list {
  display: grid;
  gap: 8px;
}

.workbench-detail-list div {
  display: grid;
  grid-template-columns: minmax(110px, 0.35fr) minmax(0, 1fr);
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px solid rgba(42, 111, 148, 0.10);
}

.workbench-detail-list dt,
.workbench-detail-list span {
  color: var(--brand-gray-650);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.workbench-detail-list dd,
.workbench-detail-list b {
  margin: 0;
  color: var(--ink-2);
  overflow-wrap: anywhere;
}

.workbench-status-note {
  padding: 12px;
  border: 1px solid rgba(42, 111, 148, 0.14);
  border-left: 3px solid rgba(243, 112, 33, 0.55);
  border-radius: 8px;
  background: rgba(255, 248, 242, 0.86);
}

.module-preference-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 12px;
  padding: 10px;
  border: 1px solid rgba(42, 111, 148, 0.13);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.84);
}

.module-preference-tools input[type="search"] {
  flex: 1 1 260px;
  min-height: 40px;
  padding: 8px 10px;
  border: 1px solid rgba(42, 111, 148, 0.20);
  border-radius: 8px;
}

.module-preference-group {
  margin-bottom: 10px;
  border: 1px solid rgba(42, 111, 148, 0.13);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.78);
  overflow: hidden;
}

.module-preference-group > summary {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  cursor: pointer;
  color: var(--brand-blue-900);
  font-weight: 850;
}

.module-preference-group > summary span {
  color: var(--brand-gray-650);
  font-size: 12px;
  font-weight: 750;
}

.module-preference-board {
  padding: 12px;
}

@media (max-width: 900px) {
  .list-summary-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .workbench-document,
  .workbench-hero {
    grid-template-columns: 1fr;
  }

  .workbench-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 760px) {
  .list-record-head {
    grid-template-columns: 1fr;
  }

  .list-record-head .status {
    justify-self: start;
    max-width: 100%;
  }
}

@media (max-width: 640px) {
  .list-card-rich {
    padding: 12px !important;
  }

  .list-summary-strip,
  .list-record-board,
  .list-record-metrics,
  .list-record-facts,
  .list-record-details dl {
    grid-template-columns: 1fr;
  }

  .list-record-board {
    gap: 14px;
    padding: 0;
  }

  .list-record-card {
    min-height: 0;
  }

  .list-table-shell {
    max-height: none;
  }

  .workbench-toolbar,
  .finance-report-actions,
  .workbench-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .workbench-toolbar input,
  .workbench-toolbar select,
  .workbench-toolbar .btn,
  .finance-report-actions form,
  .finance-report-actions .btn,
  .workbench-actions .btn {
    width: 100%;
  }

  .workbench-kpis,
  .workbench-card-grid,
  .workbench-list,
  .workbench-facts,
  .workbench-detail-list div {
    grid-template-columns: 1fr;
  }
}
