/* EasyDeals — EasyHR-style glossy accents on ModusCore shell */

:root {
  --sh-primary: var(--ov-primary);
  --sh-accent: var(--ov-accent);
  --ed-primary: var(--ov-primary);
  --ed-accent: var(--ov-accent);
  --color-primary: var(--ov-primary);
  --shadow-md: 0 4px 12px rgba(16, 35, 60, 0.12);
  --shadow-lg: 0 10px 24px rgba(16, 35, 60, 0.16);
  --shadow-xl: 0 16px 40px rgba(16, 35, 60, 0.2);
  --transition-fast: 150ms;
  --transition-timing: ease;
}

.theme-main--full {
  margin-left: 0 !important;
  width: 100% !important;
}

/* Dock brand — company, then product name */
.dock-brand-product {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--ov-primary);
  letter-spacing: 0.02em;
  margin-top: 0.1rem;
}
.dock-brand-subtitle {
  margin-top: 0.15rem;
}

/* Slightly smaller dock tiles only — keep flyouts and no inner scrollbar */
.dock-nav {
  gap: 0.32rem;
}

.dock-nav > .theme-nav-item.menu-item,
.dock-nav .menu-group-header {
  min-height: 4.35rem !important;
  padding: 0.4rem 0.35rem !important;
}

.dock-nav > .theme-nav-item.menu-item .theme-nav-icon,
.dock-nav .menu-group-header .menu-group-icon,
.dock-nav > .theme-nav-item.menu-item img.theme-nav-icon--officevault {
  width: 18px !important;
  height: 18px !important;
}

/* Dock menu — opaque colour gradients + glossy glass shine (::before so ::after keep active dots) */
.dock-nav > .theme-nav-item.menu-item,
.dock-nav .menu-group-header {
  position: relative !important;
  overflow: hidden !important;
  isolation: isolate;
  border: 1px solid rgba(255, 255, 255, 0.72) !important;
  color: #fff !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.78),
    inset 0 -12px 20px rgba(0, 0, 0, 0.18),
    0 12px 24px rgba(8, 25, 44, 0.3) !important;
}

.dock-nav > .theme-nav-item.menu-item::before,
.dock-nav .menu-group-header::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  z-index: 1;
  background:
    linear-gradient(
      125deg,
      rgba(255, 255, 255, 0.42) 0%,
      rgba(255, 255, 255, 0.12) 28%,
      rgba(255, 255, 255, 0) 48%
    ),
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.18) 0%,
      rgba(255, 255, 255, 0.03) 42%,
      rgba(0, 0, 0, 0.08) 100%
    );
}

.dock-nav > .theme-nav-item.menu-item > *,
.dock-nav .menu-group-header > * {
  position: relative;
  z-index: 2;
}

/* Dock colours — EasyHR multi-colour tiles mapped to EasyDeals groups */
.dock-nav > a[data-menu-text="Dashboard"] {
  background: linear-gradient(145deg, #38bdf8 0%, #0369a1 100%) !important;
}
.dock-nav > a[data-menu-text="Appointments"] {
  background: linear-gradient(145deg, #fb923c 0%, #c2410c 100%) !important;
}
.dock-nav > a[data-menu-text="Guides"] {
  background: linear-gradient(145deg, #34d399 0%, #047857 100%) !important;
}
.dock-nav .menu-group[data-group-id="sales"] .menu-group-header {
  background: linear-gradient(145deg, #2dd4bf 0%, #0f766e 100%) !important;
}
.dock-nav .menu-group[data-group-id="customers"] .menu-group-header {
  background: linear-gradient(145deg, #22d3ee 0%, #0369a1 100%) !important;
}
.dock-nav .menu-group[data-group-id="admin"] .menu-group-header {
  background: linear-gradient(145deg, #a78bfa 0%, #6d28d9 100%) !important;
}

.dock-nav > .theme-nav-item.menu-item.active,
.dock-nav .menu-group.expanded .menu-group-header,
.dock-nav .menu-group.has-active .menu-group-header {
  filter: brightness(1.08) saturate(1.08) !important;
  border-color: rgba(255, 255, 255, 0.95) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.8),
    0 0 0 3px rgba(255, 255, 255, 0.4),
    0 16px 32px rgba(8, 25, 44, 0.35) !important;
  transform: translateY(-1px) scale(1.015);
}

/* Keep ModusCore active-dot above the gloss layer */
.dock-nav .menu-group.expanded .menu-group-header::after,
.dock-nav .menu-group.has-active .menu-group-header::after {
  z-index: 3;
}

.dock-nav > .theme-nav-item.menu-item .theme-nav-icon,
.dock-nav .menu-group-header .menu-group-icon,
.dock-nav > .theme-nav-item.menu-item > span,
.dock-nav .menu-group-header .menu-group-title span {
  color: #fff !important;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.25));
}

.dock-nav > .theme-nav-item.menu-item.active > span,
.dock-nav > .theme-nav-item.menu-item.active .theme-nav-icon,
.dock-nav .menu-group.expanded .menu-group-header .menu-group-title span,
.dock-nav .menu-group.has-active .menu-group-header .menu-group-title span,
.dock-nav .menu-group.expanded .menu-group-header .menu-group-icon,
.dock-nav .menu-group.has-active .menu-group-header .menu-group-icon {
  color: #fff !important;
}

/* Transparent flyout so background peeks through */
.dock-nav .menu-group-items,
.theme-layout.sp-sidebar-collapsed .dock-nav .menu-group.expanded .menu-group-items {
  background: rgba(241, 245, 249, 0.42) !important;
  backdrop-filter: blur(12px) saturate(1.2);
  -webkit-backdrop-filter: blur(12px) saturate(1.2);
  border: 1px solid rgba(15, 76, 129, 0.18) !important;
  box-shadow: 0 18px 40px rgba(7, 20, 35, 0.22) !important;
}

/* Coloured submenu rows — not black/white, each accent unique */
.dock-nav .menu-group-item {
  border: 1px solid rgba(255, 255, 255, 0.4) !important;
  font-weight: 600;
  margin-bottom: 0.28rem;
  backdrop-filter: blur(8px) saturate(1.15);
  -webkit-backdrop-filter: blur(8px) saturate(1.15);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.45), 0 4px 10px rgba(15, 23, 42, 0.08);
}
.dock-nav .menu-group-item:last-child {
  margin-bottom: 0;
}
.dock-nav .menu-group-item[data-accent="amber"] {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.72), rgba(217, 119, 6, 0.48)) !important;
  color: #78350f !important;
}
.dock-nav .menu-group-item[data-accent="amber"] .theme-nav-icon { color: #b45309 !important; }
.dock-nav .menu-group-item[data-accent="sky"] {
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.72), rgba(2, 132, 199, 0.48)) !important;
  color: #0c4a6e !important;
}
.dock-nav .menu-group-item[data-accent="sky"] .theme-nav-icon { color: #0369a1 !important; }
.dock-nav .menu-group-item[data-accent="violet"] {
  background: linear-gradient(135deg, rgba(167, 139, 250, 0.75), rgba(109, 40, 217, 0.48)) !important;
  color: #4c1d95 !important;
}
.dock-nav .menu-group-item[data-accent="violet"] .theme-nav-icon { color: #6d28d9 !important; }
.dock-nav .menu-group-item[data-accent="teal"] {
  background: linear-gradient(135deg, rgba(45, 212, 191, 0.72), rgba(13, 148, 136, 0.48)) !important;
  color: #134e4a !important;
}
.dock-nav .menu-group-item[data-accent="teal"] .theme-nav-icon { color: #0f766e !important; }
.dock-nav .menu-group-item[data-accent="emerald"] {
  background: linear-gradient(135deg, rgba(52, 211, 153, 0.72), rgba(5, 150, 105, 0.48)) !important;
  color: #064e3b !important;
}
.dock-nav .menu-group-item[data-accent="emerald"] .theme-nav-icon { color: #047857 !important; }
.dock-nav .menu-group-item[data-accent="orange"] {
  background: linear-gradient(135deg, rgba(251, 146, 60, 0.75), rgba(234, 88, 12, 0.5)) !important;
  color: #7c2d12 !important;
}
.dock-nav .menu-group-item[data-accent="orange"] .theme-nav-icon { color: #c2410c !important; }
.dock-nav .menu-group-item[data-accent="lime"] {
  background: linear-gradient(135deg, rgba(190, 242, 100, 0.75), rgba(101, 163, 13, 0.5)) !important;
  color: #365314 !important;
}
.dock-nav .menu-group-item[data-accent="lime"] .theme-nav-icon { color: #4d7c0f !important; }
.dock-nav .menu-group-item[data-accent="slate"] {
  background: linear-gradient(135deg, rgba(125, 211, 252, 0.7), rgba(71, 85, 105, 0.45)) !important;
  color: #1e293b !important;
}
.dock-nav .menu-group-item[data-accent="slate"] .theme-nav-icon { color: #334155 !important; }
.dock-nav .menu-group-item[data-accent="stone"] {
  background: linear-gradient(135deg, rgba(253, 186, 116, 0.7), rgba(120, 113, 108, 0.45)) !important;
  color: #44403c !important;
}
.dock-nav .menu-group-item[data-accent="stone"] .theme-nav-icon { color: #57534e !important; }
.dock-nav .menu-group-item[data-accent="pink"] {
  background: linear-gradient(135deg, rgba(244, 114, 182, 0.72), rgba(190, 24, 93, 0.48)) !important;
  color: #831843 !important;
}
.dock-nav .menu-group-item[data-accent="pink"] .theme-nav-icon { color: #be185d !important; }
.dock-nav .menu-group-item[data-accent="blue"] {
  background: linear-gradient(135deg, rgba(96, 165, 250, 0.75), rgba(37, 99, 235, 0.5)) !important;
  color: #1e3a8a !important;
}
.dock-nav .menu-group-item[data-accent="blue"] .theme-nav-icon { color: #1d4ed8 !important; }
.dock-nav .menu-group-item[data-accent="cyan"] {
  background: linear-gradient(135deg, rgba(103, 232, 249, 0.75), rgba(8, 145, 178, 0.5)) !important;
  color: #164e63 !important;
}
.dock-nav .menu-group-item[data-accent="cyan"] .theme-nav-icon { color: #0e7490 !important; }
.dock-nav .menu-group-item[data-accent="red"] {
  background: linear-gradient(135deg, rgba(252, 165, 165, 0.75), rgba(220, 38, 38, 0.5)) !important;
  color: #7f1d1d !important;
}
.dock-nav .menu-group-item[data-accent="red"] .theme-nav-icon { color: #b91c1c !important; }
.dock-nav .menu-group-item[data-accent="rose"] {
  background: linear-gradient(135deg, rgba(251, 113, 133, 0.72), rgba(225, 29, 72, 0.48)) !important;
  color: #881337 !important;
}
.dock-nav .menu-group-item[data-accent="rose"] .theme-nav-icon { color: #e11d48 !important; }

.dock-nav .menu-group-item:hover {
  filter: brightness(1.08);
  border-color: rgba(15, 76, 129, 0.28) !important;
}
.dock-nav .menu-group-item.active {
  box-shadow: inset 0 0 0 2px rgba(15, 76, 129, 0.45);
  font-weight: 700;
  filter: brightness(1.05);
}

/* Override base theme transparent/gray submenu defaults */
.dock-nav .menu-group-item:hover {
  background-image: none;
}
.dock-nav .menu-group-item[data-accent]:hover {
  filter: brightness(1.1);
}


/* Glossy glass on main theme buttons */
.theme-btn-primary,
.theme-btn-secondary,
.theme-btn-success,
.theme-btn-warning,
.theme-btn-info,
.theme-btn-danger,
.theme-btn.action-view,
.theme-btn.action-edit,
.theme-btn.action-download,
.theme-btn.action-save,
.theme-btn.action-activate,
.theme-btn.action-approve,
.theme-btn.action-upload,
.theme-btn.action-replace,
.theme-btn.action-deactivate,
.theme-btn.action-reject,
.theme-btn.action-delete,
.theme-btn.action-back,
.theme-btn.action-btn {
  /* No backdrop blur: Chrome paints these buttons as blank blocks in long tables. */
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.45), 0 6px 14px rgba(15, 23, 42, 0.15) !important;
  border: 1px solid rgba(255, 255, 255, 0.35) !important;
}

/* Action buttons — wrap to ~2 rows instead of one cramped line */
.theme-action-cell {
  white-space: normal !important;
  vertical-align: top;
  min-width: 10.5rem;
  max-width: 15.5rem;
  width: 15.5rem;
}
.theme-action-group {
  display: inline-flex !important;
  flex-direction: row !important;
  flex-wrap: wrap !important;
  align-items: center;
  justify-content: flex-end;
  gap: 0.3rem;
  white-space: normal !important;
  max-width: 15.5rem;
}
.theme-action-group form {
  display: inline-flex;
  margin: 0;
}
.theme-action-group .theme-btn {
  min-width: 0 !important;
  flex: 0 1 auto;
}
.theme-table td .theme-action-group {
  flex-wrap: wrap !important;
  white-space: normal !important;
}

/* Page / card toolbars also wrap */
.theme-card-header > div,
.deals-reports-desktop-actions,
.deals-view-chips,
.theme-toolbar,
.theme-toolbar-group {
  flex-wrap: wrap !important;
}

/* Anchor buttons must never look like plain links */
a.theme-btn {
  text-decoration: none !important;
  color: inherit;
}
a.theme-btn:hover,
a.theme-btn:focus {
  text-decoration: none !important;
}

.theme-btn.action-btn {
  background: linear-gradient(135deg, #94a3b8, #64748b);
  color: #fff !important;
  border: none;
}
.theme-btn.action-view {
  background: linear-gradient(135deg, #38bdf8, #0284c7);
  color: #fff !important;
  border: none;
}
.theme-btn.action-edit {
  background: linear-gradient(135deg, #2dd4bf, #0f766e);
  color: #fff !important;
  border: none;
}
.theme-btn.action-download {
  background: linear-gradient(135deg, #22d3ee, #0369a1);
  color: #fff !important;
  border: none;
}
.theme-btn.action-save,
.theme-btn.action-activate,
.theme-btn.action-approve {
  background: linear-gradient(135deg, #34d399, #047857);
  color: #fff !important;
  border: none;
}
.theme-btn.action-upload,
.theme-btn.action-replace {
  background: linear-gradient(135deg, #fb923c, #ea580c);
  color: #fff !important;
  border: none;
}
.theme-btn.action-deactivate,
.theme-btn.action-reject {
  background: linear-gradient(135deg, #fbbf24, #b45309);
  color: #fff !important;
  border: none;
}
.theme-btn.action-delete {
  background: linear-gradient(135deg, #fb7185, #dc2626);
  color: #fff !important;
  border: none;
}
.theme-btn.action-back {
  background: linear-gradient(135deg, #94a3b8, #475569);
  color: #fff !important;
  border: none;
}

.theme-btn-sm {
  padding: 0.35rem 0.85rem;
  font-size: 0.75rem;
  min-height: 2.25rem;
  letter-spacing: 0.02em;
}

/* Uniform control height across the app (Back = Search = filters = CTAs) */
.theme-btn,
.theme-btn-sm,
.theme-toolbar .theme-btn,
.theme-action-group .theme-btn,
a.theme-btn {
  min-height: 2.25rem !important;
  height: 2.25rem;
  box-sizing: border-box;
  padding-top: 0.35rem !important;
  padding-bottom: 0.35rem !important;
  padding-left: 0.85rem !important;
  padding-right: 0.85rem !important;
  font-size: 0.75rem !important;
  line-height: 1.2;
  min-width: 5.5rem;
  white-space: nowrap;
}
.theme-btn-sm {
  min-width: 4.75rem;
}

.theme-btn-success {
  background: linear-gradient(135deg, #34d399, #059669) !important;
  color: #fff !important;
  border: none !important;
}
.theme-btn-warning {
  background: linear-gradient(135deg, #fbbf24, #d97706) !important;
  color: #fff !important;
  border: none !important;
}
.theme-btn-info {
  background: linear-gradient(135deg, #38bdf8, #0284c7) !important;
  color: #fff !important;
  border: none !important;
}
.theme-btn-primary {
  background: linear-gradient(135deg, #38bdf8, #0f4c81) !important;
  color: #fff !important;
  border: none !important;
}
.theme-btn-primary:hover {
  filter: brightness(1.08);
  background: linear-gradient(135deg, #7dd3fc, #0c3f6a) !important;
}
/* Secondary is slate — never the same sky-blue as primary / view */
.theme-btn-secondary {
  background: linear-gradient(135deg, #94a3b8, #475569) !important;
  color: #fff !important;
  border: none !important;
}
.theme-btn-secondary:hover {
  filter: brightness(1.08);
  background: linear-gradient(135deg, #cbd5e1, #334155) !important;
}
.theme-btn-danger {
  background: linear-gradient(135deg, #fb7185, #be123c) !important;
  color: #fff !important;
  border: none !important;
}
.theme-btn-danger:hover {
  filter: brightness(1.08);
}

/* Coloured shortcut / accent buttons (avoid all-purple UI) */
.theme-btn-accent-sky {
  background: linear-gradient(135deg, #38bdf8, #0369a1) !important;
  color: #fff !important;
  border: 1px solid rgba(255,255,255,0.4) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), 0 6px 14px rgba(15,23,42,0.14) !important;
}
.theme-btn-accent-violet {
  background: linear-gradient(135deg, #a78bfa, #6d28d9) !important;
  color: #fff !important;
  border: 1px solid rgba(255,255,255,0.4) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), 0 6px 14px rgba(15,23,42,0.14) !important;
}
.theme-btn-accent-emerald {
  background: linear-gradient(135deg, #34d399, #047857) !important;
  color: #fff !important;
  border: 1px solid rgba(255,255,255,0.4) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), 0 6px 14px rgba(15,23,42,0.14) !important;
}
.theme-btn-accent-teal {
  background: linear-gradient(135deg, #2dd4bf, #0f766e) !important;
  color: #fff !important;
  border: 1px solid rgba(255,255,255,0.4) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), 0 6px 14px rgba(15,23,42,0.14) !important;
}
.theme-btn-accent-rose {
  background: linear-gradient(135deg, #fb7185, #be123c) !important;
  color: #fff !important;
  border: 1px solid rgba(255,255,255,0.4) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), 0 6px 14px rgba(15,23,42,0.14) !important;
}
.theme-btn-accent-orange {
  background: linear-gradient(135deg, #fb923c, #c2410c) !important;
  color: #fff !important;
  border: 1px solid rgba(255,255,255,0.4) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), 0 6px 14px rgba(15,23,42,0.14) !important;
}
.theme-btn-accent-amber {
  background: linear-gradient(135deg, #fbbf24, #b45309) !important;
  color: #fff !important;
  border: 1px solid rgba(255,255,255,0.4) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), 0 6px 14px rgba(15,23,42,0.14) !important;
}
.theme-btn-accent-red {
  background: linear-gradient(135deg, #f87171, #b91c1c) !important;
  color: #fff !important;
  border: 1px solid rgba(255,255,255,0.4) !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.5), 0 6px 14px rgba(15,23,42,0.14) !important;
}

.theme-btn.is-active {
  box-shadow: 0 0 0 2px rgba(15, 76, 129, 0.35);
  filter: brightness(1.05);
}

.theme-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}
.theme-toolbar-group {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  align-items: center;
}
.theme-toolbar .theme-form-input,
.theme-toolbar-group .theme-form-input,
.theme-toolbar-search .theme-form-input {
  width: auto;
  min-width: 11rem;
  max-width: 18rem;
  flex: 0 1 auto;
  height: 2.25rem;
  min-height: 2.25rem;
  box-sizing: border-box;
}
.theme-toolbar-search {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.5rem;
}
.theme-toolbar-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  flex: 1 1 auto;
}

/* Adjacent buttons in a group: cycle accents so two blues never sit together */
.theme-action-group > .theme-btn:nth-child(8n + 1):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-toolbar-group > .theme-btn:nth-child(8n + 1):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-btn-row > .theme-btn:nth-child(8n + 1):not([class*="action-"]):not([class*="accent-"]) {
  background: linear-gradient(135deg, #38bdf8, #0369a1) !important;
  color: #fff !important;
}
.theme-action-group > .theme-btn:nth-child(8n + 2):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-toolbar-group > .theme-btn:nth-child(8n + 2):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-btn-row > .theme-btn:nth-child(8n + 2):not([class*="action-"]):not([class*="accent-"]) {
  background: linear-gradient(135deg, #2dd4bf, #0f766e) !important;
  color: #fff !important;
}
.theme-action-group > .theme-btn:nth-child(8n + 3):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-toolbar-group > .theme-btn:nth-child(8n + 3):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-btn-row > .theme-btn:nth-child(8n + 3):not([class*="action-"]):not([class*="accent-"]) {
  background: linear-gradient(135deg, #a78bfa, #6d28d9) !important;
  color: #fff !important;
}
.theme-action-group > .theme-btn:nth-child(8n + 4):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-toolbar-group > .theme-btn:nth-child(8n + 4):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-btn-row > .theme-btn:nth-child(8n + 4):not([class*="action-"]):not([class*="accent-"]) {
  background: linear-gradient(135deg, #fb923c, #c2410c) !important;
  color: #fff !important;
}
.theme-action-group > .theme-btn:nth-child(8n + 5):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-toolbar-group > .theme-btn:nth-child(8n + 5):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-btn-row > .theme-btn:nth-child(8n + 5):not([class*="action-"]):not([class*="accent-"]) {
  background: linear-gradient(135deg, #fbbf24, #b45309) !important;
  color: #fff !important;
}
.theme-action-group > .theme-btn:nth-child(8n + 6):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-toolbar-group > .theme-btn:nth-child(8n + 6):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-btn-row > .theme-btn:nth-child(8n + 6):not([class*="action-"]):not([class*="accent-"]) {
  background: linear-gradient(135deg, #fb7185, #be123c) !important;
  color: #fff !important;
}
.theme-action-group > .theme-btn:nth-child(8n + 7):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-toolbar-group > .theme-btn:nth-child(8n + 7):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-btn-row > .theme-btn:nth-child(8n + 7):not([class*="action-"]):not([class*="accent-"]) {
  background: linear-gradient(135deg, #34d399, #047857) !important;
  color: #fff !important;
}
.theme-action-group > .theme-btn:nth-child(8n + 8):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-toolbar-group > .theme-btn:nth-child(8n + 8):not([class*="action-"]):not([class*="accent-"]):not(.theme-btn-primary):not(.theme-btn-success):not(.theme-btn-warning):not(.theme-btn-danger),
.theme-btn-row > .theme-btn:nth-child(8n + 8):not([class*="action-"]):not([class*="accent-"]) {
  background: linear-gradient(135deg, #94a3b8, #334155) !important;
  color: #fff !important;
}

.company-logo-frame {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border-radius: 14px;
  padding: 0.45rem 0.6rem;
  border: 1px solid rgba(15, 76, 129, 0.12);
  box-shadow: 0 4px 14px rgba(8, 25, 44, 0.12);
  box-sizing: border-box;
  overflow: hidden;
  max-width: 100%;
}
.company-logo-frame img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 2.5rem;
  object-fit: contain;
  object-position: center;
}
.company-logo-frame--topbar {
  padding: 0.35rem 0.5rem;
  border-radius: 12px;
}
.company-logo-frame--topbar img {
  max-height: 1.85rem;
  max-width: 7.5rem;
}
.company-logo-frame--lg {
  padding: 0.75rem 1rem;
}
.company-logo-frame--lg img {
  max-height: 4.5rem;
  max-width: 14rem;
}

.theme-empty {
  text-align: center;
  padding: 2.25rem 1.25rem;
  border: 1px dashed var(--color-neutral-gray-200, #e2e8f0);
  border-radius: var(--ov-radius-lg, 12px);
  background: var(--ov-surface-alt, #f8fafc);
}
.theme-empty-title {
  margin: 0 0 0.5rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ov-ink, #0f172a);
}
.theme-empty-hint {
  margin: 0 auto 1.15rem;
  max-width: 36rem;
  color: var(--ov-ink-muted, #64748b);
  font-size: 0.9rem;
  line-height: 1.45;
}

.theme-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}
a.theme-kpi-card {
  display: block;
  text-decoration: none;
  color: inherit;
  transition: transform 120ms ease, box-shadow 120ms ease;
}
a.theme-kpi-card:hover {
  transform: translateY(-3px);
}
a.theme-kpi-card .theme-card-body strong {
  font-size: 1.5rem;
  display: block;
}
a.theme-kpi-card .theme-kpi-label {
  margin: 0.35rem 0 0;
  color: var(--ov-ink-muted);
  font-size: 0.875rem;
}

/* Cards — coloured borders + light 3D lift (not flat grey clones) */
.theme-card {
  --card-accent: #0284c7;
  --card-tint: rgba(2, 132, 199, 0.06);
  position: relative;
  border: 1.5px solid color-mix(in srgb, var(--card-accent) 42%, #e2e8f0) !important;
  border-left: 4px solid var(--card-accent) !important;
  border-radius: 0.85rem !important;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92) 0%, var(--card-tint) 100%),
    #fff !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    0 1px 2px rgba(15, 23, 42, 0.04),
    0 6px 14px -4px color-mix(in srgb, var(--card-accent) 28%, transparent),
    0 14px 28px -12px rgba(15, 23, 42, 0.14) !important;
  transition: transform 150ms ease, box-shadow 150ms ease;
}

.theme-card:hover {
  transform: translateY(-2px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    0 2px 4px rgba(15, 23, 42, 0.05),
    0 10px 20px -6px color-mix(in srgb, var(--card-accent) 34%, transparent),
    0 18px 36px -14px rgba(15, 23, 42, 0.16) !important;
}

/* Replace ModusCore top stripe with accent-matched bar */
.theme-card.theme-card-stat::before,
.theme-card.theme-card-panel::before,
.theme-content > .theme-card:not(.theme-card-stat):not(.theme-card-panel)::before,
.dashboard-main-grid > div > .theme-card:not(.theme-card-stat):not(.theme-card-panel)::before {
  height: 3px !important;
  background: linear-gradient(90deg, var(--card-accent), color-mix(in srgb, var(--card-accent) 40%, #fff)) !important;
}

.theme-card--sky,
.theme-card-accent-sky { --card-accent: #0284c7; --card-tint: rgba(2, 132, 199, 0.07); }
.theme-card--teal,
.theme-card-accent-teal { --card-accent: #0f766e; --card-tint: rgba(15, 118, 110, 0.07); }
.theme-card--emerald,
.theme-card-accent-emerald { --card-accent: #047857; --card-tint: rgba(4, 120, 87, 0.07); }
.theme-card--amber,
.theme-card-accent-amber { --card-accent: #b45309; --card-tint: rgba(180, 83, 9, 0.07); }
.theme-card--orange,
.theme-card-accent-orange { --card-accent: #c2410c; --card-tint: rgba(194, 65, 12, 0.07); }
.theme-card--rose,
.theme-card-accent-rose { --card-accent: #be123c; --card-tint: rgba(190, 18, 60, 0.07); }
.theme-card--violet,
.theme-card-accent-violet { --card-accent: #6d28d9; --card-tint: rgba(109, 40, 217, 0.07); }
.theme-card--cyan,
.theme-card-accent-cyan { --card-accent: #0e7490; --card-tint: rgba(14, 116, 144, 0.07); }

/* Auto-cycle colours when cards sit as siblings (dashboard KPIs, multi-card pages) */
.theme-kpi-grid > .theme-card:nth-child(8n + 1),
.theme-fade-in > .theme-card:nth-child(8n + 1),
.theme-fade-in > div > .theme-card:nth-child(8n + 1),
.theme-fade-in > div > div > .theme-card:nth-child(8n + 1) {
  --card-accent: #0284c7;
  --card-tint: rgba(2, 132, 199, 0.07);
}
.theme-kpi-grid > .theme-card:nth-child(8n + 2),
.theme-fade-in > .theme-card:nth-child(8n + 2),
.theme-fade-in > div > .theme-card:nth-child(8n + 2),
.theme-fade-in > div > div > .theme-card:nth-child(8n + 2) {
  --card-accent: #0f766e;
  --card-tint: rgba(15, 118, 110, 0.07);
}
.theme-kpi-grid > .theme-card:nth-child(8n + 3),
.theme-fade-in > .theme-card:nth-child(8n + 3),
.theme-fade-in > div > .theme-card:nth-child(8n + 3),
.theme-fade-in > div > div > .theme-card:nth-child(8n + 3) {
  --card-accent: #047857;
  --card-tint: rgba(4, 120, 87, 0.07);
}
.theme-kpi-grid > .theme-card:nth-child(8n + 4),
.theme-fade-in > .theme-card:nth-child(8n + 4),
.theme-fade-in > div > .theme-card:nth-child(8n + 4),
.theme-fade-in > div > div > .theme-card:nth-child(8n + 4) {
  --card-accent: #0e7490;
  --card-tint: rgba(14, 116, 144, 0.07);
}
.theme-kpi-grid > .theme-card:nth-child(8n + 5),
.theme-fade-in > .theme-card:nth-child(8n + 5),
.theme-fade-in > div > .theme-card:nth-child(8n + 5),
.theme-fade-in > div > div > .theme-card:nth-child(8n + 5) {
  --card-accent: #b45309;
  --card-tint: rgba(180, 83, 9, 0.07);
}
.theme-kpi-grid > .theme-card:nth-child(8n + 6),
.theme-fade-in > .theme-card:nth-child(8n + 6),
.theme-fade-in > div > .theme-card:nth-child(8n + 6),
.theme-fade-in > div > div > .theme-card:nth-child(8n + 6) {
  --card-accent: #c2410c;
  --card-tint: rgba(194, 65, 12, 0.07);
}
.theme-kpi-grid > .theme-card:nth-child(8n + 7),
.theme-fade-in > .theme-card:nth-child(8n + 7),
.theme-fade-in > div > .theme-card:nth-child(8n + 7),
.theme-fade-in > div > div > .theme-card:nth-child(8n + 7) {
  --card-accent: #be123c;
  --card-tint: rgba(190, 18, 60, 0.07);
}
.theme-kpi-grid > .theme-card:nth-child(8n + 8),
.theme-fade-in > .theme-card:nth-child(8n + 8),
.theme-fade-in > div > .theme-card:nth-child(8n + 8),
.theme-fade-in > div > div > .theme-card:nth-child(8n + 8) {
  --card-accent: #6d28d9;
  --card-tint: rgba(109, 40, 217, 0.07);
}

.theme-shortcut-panel {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}
.theme-shortcut-panel .theme-btn {
  min-height: 2.5rem;
}

.theme-form-note {
  color: var(--color-neutral-gray-500);
  font-size: 0.75rem;
  display: block;
  margin-top: 0.25rem;
}

.theme-form-actions {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid var(--color-neutral-gray-200);
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.theme-help-card .theme-card-header {
  user-select: none;
}
.theme-help-card .theme-help-card-title {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0;
}
.theme-help-card .theme-help-card-title svg {
  flex-shrink: 0;
}
.theme-help-card-content h3 {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--ov-primary);
}
.theme-help-card-content h4 {
  font-size: 1rem;
  font-weight: 600;
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
}
.theme-help-card-content ul {
  margin-left: 1.5rem;
  margin-bottom: 1rem;
}
.theme-help-card-content li {
  margin-bottom: 0.5rem;
}

.theme-help-card-tip {
  padding: 1rem;
  background: rgba(15, 76, 129, 0.08);
  border-radius: 0.375rem;
  border-left: 4px solid var(--ov-primary);
  margin-top: 1rem;
}

/* Confirm / unread-notifications modal — keep within viewport; body scrolls */
.theme-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.42);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 1rem;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.theme-modal-backdrop.visible { display: flex; }
.theme-modal {
  width: min(92vw, 460px);
  max-height: min(85vh, 640px);
  margin: auto;
  background: var(--color-neutral-white);
  border: 1px solid var(--color-neutral-gray-200);
  border-radius: 0.75rem;
  box-shadow: var(--shadow-xl);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.theme-modal-header {
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--color-neutral-gray-200);
  font-size: 1rem;
  font-weight: 700;
  flex-shrink: 0;
}
.theme-modal-body {
  padding: 1rem;
  line-height: 1.55;
  overflow-y: auto;
  flex: 1 1 auto;
  min-height: 0;
  -webkit-overflow-scrolling: touch;
}
.theme-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.6rem;
  padding: 0.9rem 1rem 1rem;
  border-top: 1px solid var(--color-neutral-gray-200);
  flex-shrink: 0;
}
.login-unread-list {
  display: grid;
  gap: 0.35rem;
  max-height: min(40vh, 18rem);
  overflow-y: auto;
}
.login-unread-list .theme-notification-item {
  display: block;
  padding: 0.55rem 0.65rem;
  border-radius: 10px;
  background: var(--color-neutral-gray-50, #f4f7fb);
  color: inherit;
  text-decoration: none;
}

details > summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.45rem;
}
details > summary::-webkit-details-marker { display: none; }
details > summary::before {
  content: "▸";
  color: var(--color-neutral-gray-600);
  font-size: 1.08rem;
  font-weight: 700;
  line-height: 1;
  transition: transform var(--transition-fast) var(--transition-timing);
}
details[open] > summary::before { transform: rotate(90deg); }

/* Leave balances — one collapsible card per employee, listed vertically */
.leave-balance-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 920px;
}

.leave-balance-card {
  padding: 0 !important;
  overflow: hidden;
}

.leave-balance-card::before {
  display: none !important;
}

.leave-balance-summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.9rem 1.1rem;
  margin: 0;
  user-select: none;
}

.leave-balance-summary::-webkit-details-marker {
  display: none;
}

.leave-balance-summary-main {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.75rem;
  min-width: 0;
  flex: 1;
}

.leave-balance-name {
  font-weight: 700;
  font-size: 0.98rem;
  color: var(--ov-ink, #10233c);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.leave-balance-meta {
  font-size: 0.8rem;
  color: var(--ov-ink-muted, #46617c);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
  flex: 1;
}

.leave-balance-chip {
  flex-shrink: 0;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--ov-primary, #0f4c81);
  background: color-mix(in srgb, var(--card-accent, #0284c7) 14%, #fff);
  border: 1px solid color-mix(in srgb, var(--card-accent, #0284c7) 28%, #e2e8f0);
  border-radius: 999px;
  padding: 0.2rem 0.65rem;
}

.leave-balance-body {
  padding: 0 1.1rem 1.1rem;
  border-top: 1px solid rgba(15, 76, 129, 0.1);
}

.leave-balance-edit {
  display: flex;
  gap: 0.35rem;
  align-items: center;
}

.leave-balance-card .theme-table-wrap {
  overflow-x: auto;
}

@media (max-width: 640px) {
  .leave-balance-summary {
    flex-wrap: wrap;
  }

  .leave-balance-chip {
    margin-left: 1.4rem;
  }
}

.deal-doc-filename {
  display: inline-block;
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  vertical-align: middle;
}

/* Dashboard helpers */
.dashboard-section-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
  padding: 0.35rem;
  background: var(--ov-surface-alt, #f4f7fb);
  border: 1px solid rgba(15, 76, 129, 0.12);
  border-radius: 0.75rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}
.dashboard-section-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.4rem;
  padding: 0.45rem 1rem;
  border-radius: 0.55rem;
  text-decoration: none !important;
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--ov-ink-muted, #46617c);
  background: transparent;
  border: 1px solid transparent;
  transition: background 150ms ease, color 150ms ease, box-shadow 150ms ease;
}
.dashboard-section-tab:hover {
  color: var(--ov-ink, #10233c);
  background: rgba(255, 255, 255, 0.75);
}
.dashboard-section-tab.is-active {
  color: #fff;
  background: linear-gradient(135deg, #38bdf8, #0f4c81);
  border-color: rgba(255, 255, 255, 0.35);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.45), 0 6px 14px rgba(15, 23, 42, 0.15);
}
.dashboard-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}
.dashboard-metric-card {
  --metric-color: var(--ov-primary);
  min-height: 122px;
  padding: 1rem 1.1rem;
  border-radius: 0.5rem;
  border: 1px solid #e6e7eb;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}
.dashboard-metric-card--link {
  transition: transform 150ms ease, box-shadow 150ms ease;
}
.dashboard-metric-card--link:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.12);
}
.dashboard-metric-header {
  margin: 0 0 0.6rem;
  padding: 0;
  border-bottom: none;
}
.dashboard-metric-title {
  margin: 0;
  font-size: 0.76rem;
  font-weight: 500;
  line-height: 1.2;
  color: #6b7280;
}
.dashboard-metric-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 0.9rem;
  min-height: 2.75rem;
}
.dashboard-metric-value {
  color: var(--metric-color);
  font-size: clamp(1.85rem, 2.8vw, 2.2rem);
  font-weight: 700;
  line-height: 1;
  margin: 0;
  text-align: left;
  min-width: 0;
  max-width: 100%;
}
.dashboard-metric-icon {
  width: 2.15rem;
  height: 2.15rem;
  min-width: 2.15rem;
  min-height: 2.15rem;
  color: var(--metric-color);
  opacity: 0.35;
  flex: 0 0 2.15rem;
}
.dashboard-metric-card--welcome .dashboard-metric-row {
  align-items: flex-start;
}
.dashboard-metric-card--welcome .dashboard-metric-value {
  font-size: clamp(1.2rem, 2.1vw, 1.9rem);
  line-height: 1.15;
  overflow-wrap: anywhere;
  word-break: break-word;
  white-space: normal;
  flex: 1 1 auto;
  max-width: calc(100% - 2.8rem);
}
.dashboard-stat-desc {
  margin: 0.55rem 0 0;
  font-size: 0.82rem;
  color: #6b7280;
  line-height: 1.35;
}
.dashboard-stat-pill {
  display: inline-block;
  margin-top: 0.55rem;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
}
.dashboard-stat-pill--muted {
  background: rgba(15, 23, 42, 0.05);
  color: #64748b;
}

/* Deals pipeline view chips */
.deals-view-bar {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin-bottom: 0.9rem;
}
.deals-view-bar-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ov-ink-muted, #46617c);
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.deals-view-chips {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
}
.deals-view-note {
  font-size: 0.82rem;
  color: #64748b;
}
.deals-columns-panel {
  margin: 0 0 1rem;
  padding: 0.65rem 0.85rem;
  border: 1px solid rgba(15, 76, 129, 0.12);
  border-radius: 0.65rem;
  background: var(--ov-surface-alt, #f4f7fb);
}
.deals-columns-panel > summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--ov-ink-muted, #46617c);
  list-style: none;
}
.deals-columns-panel > summary::-webkit-details-marker { display: none; }
.deals-columns-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1.1rem;
  margin-top: 0.65rem;
}
.deals-columns-grid label {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.86rem;
  color: var(--ov-ink, #10233c);
  cursor: pointer;
}
.deals-table-scroll {
  width: 100%;
  overflow-x: auto;
}
.deals-table {
  table-layout: auto;
  min-width: 640px;
}
.deals-title-cell {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  min-width: 0;
}
.deals-month-chip {
  flex: 0 0 auto;
  max-width: 7.5rem;
}
.deals-title-text {
  min-width: 0;
  overflow-wrap: anywhere;
}
.deals-month-summary {
  margin: 0 0 1rem;
}
.deals-month-summary-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.35rem;
}
.deals-month-count {
  max-width: none;
}
.deals-health-pill {
  display: inline-block;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  font-weight: 700;
  border: 1px solid rgba(15, 23, 42, 0.08);
}
.deal-header-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  justify-content: flex-end;
  max-width: 28rem;
}
.workflows-table td,
.workflows-table th {
  vertical-align: top;
}

/* =============================================================================
   Entity list cards — standard for index pages (one horizontal row per item)
   ============================================================================= */

.theme-page-stack {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.theme-entity-grid {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

/* Square card grid — Reports and similar chooser pages */
.theme-entity-grid.theme-entity-grid--cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
}

.theme-entity-grid.theme-entity-grid--cards .theme-entity-card {
  flex-direction: column;
  align-items: stretch;
  justify-content: space-between;
  min-height: 210px;
  padding: 1.15rem 1.25rem;
  border-left-width: 1px;
  border-left-color: rgba(15, 76, 129, 0.12);
}

.theme-entity-grid.theme-entity-grid--cards .theme-entity-card::before {
  display: block;
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--entity-stripe, var(--ov-primary));
  border-radius: 0.65rem 0.65rem 0 0;
}

.theme-entity-grid.theme-entity-grid--cards .theme-entity-card-title,
.theme-entity-grid.theme-entity-grid--cards .theme-entity-card > .theme-form-note {
  flex: 0 0 auto;
}

.theme-entity-grid.theme-entity-grid--cards .theme-entity-card-actions {
  justify-content: flex-start;
  margin-top: auto;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(15, 76, 129, 0.08);
  width: 100%;
}

.theme-entity-card {
  position: relative;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1.25rem;
  margin: 0;
  padding: 0.85rem 1.1rem 0.85rem 1.25rem;
  min-height: 0;
  border-radius: 0.65rem;
  border: 1px solid rgba(15, 76, 129, 0.12);
  border-left: 4px solid var(--entity-stripe, var(--ov-primary));
  box-shadow: var(--ov-shadow-panel, var(--shadow-md));
  background: linear-gradient(165deg, #ffffff 0%, #f4f7fb 100%);
  overflow: hidden;
  transition: transform var(--transition-fast) var(--transition-timing),
    box-shadow var(--transition-fast) var(--transition-timing);
}

.theme-entity-card::before {
  display: none;
}

.theme-entity-card:hover {
  transform: translateY(-1px);
  box-shadow: var(--ov-shadow-dock, var(--shadow-lg));
}

.theme-entity-card-main {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  flex: 1 1 14rem;
  min-width: 0;
}

.theme-entity-card-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: var(--ov-ink, #10233c);
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.theme-entity-card-meta {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 0.35rem 1.1rem;
  flex: 0 1 auto;
  font-size: 0.84rem;
  color: var(--ov-ink-muted, #46617c);
}

.theme-entity-card-meta-row {
  display: inline-flex;
  flex-wrap: nowrap;
  gap: 0.3rem;
  align-items: baseline;
  max-width: 100%;
}

.theme-entity-card-meta-row > span:last-child {
  overflow-wrap: anywhere;
}

.theme-entity-card-meta-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #64748b;
  min-width: 0;
  white-space: nowrap;
}

.theme-entity-card-meta-label::after {
  content: ':';
}

.theme-entity-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0;
  padding-top: 0;
  border-top: none;
  justify-content: flex-end;
  flex: 0 1 auto;
  max-width: 100%;
}

.theme-entity-card > .theme-entity-card-title,
.theme-entity-card > .theme-form-note {
  flex: 1 1 12rem;
  min-width: 0;
}

.theme-entity-card > .theme-entity-card-meta {
  flex: 1 1 18rem;
}

.theme-entity-empty {
  text-align: center;
  padding: 1.5rem 1rem;
  color: var(--color-neutral-gray-600);
}

@media (max-width: 768px) {
  .theme-entity-card {
    align-items: stretch;
  }

  .theme-entity-card-actions {
    justify-content: flex-start;
    width: 100%;
    padding-top: 0.45rem;
    border-top: 1px solid rgba(15, 76, 129, 0.08);
  }
}

.dark .theme-entity-card {
  background: linear-gradient(165deg, #1e293b 0%, #0f172a 100%);
  border-color: rgba(148, 163, 184, 0.2);
}

.dark .theme-entity-card-title {
  color: #f1f5f9;
}

.dark .theme-entity-card-meta {
  color: #94a3b8;
}

/* Alerts */
.theme-alert {
  padding: 0.75rem 1rem;
  border-radius: 0.375rem;
  margin-bottom: 1rem;
  border: 1px solid;
  font-size: 0.875rem;
}
.theme-alert-success {
  background-color: rgba(16, 185, 129, 0.1);
  border-color: var(--color-success);
  color: var(--color-success);
}
.theme-alert-danger {
  background-color: rgba(255, 88, 107, 0.12);
  border-color: var(--color-danger);
  color: #b91c1c;
}
.theme-alert-warning {
  background-color: rgba(255, 141, 96, 0.14);
  border-color: var(--color-warning);
  color: #9a3412;
}
.theme-alert-info {
  background-color: rgba(29, 127, 191, 0.12);
  border-color: var(--ov-accent);
  color: #0f4c81;
}

/* Notifications */
#notifications-btn.theme-toggle-btn,
.theme-notifications .theme-toggle-btn {
  background: none;
  border: none;
  box-shadow: none;
  padding: 0.25rem;
  min-height: auto;
  color: inherit;
  position: relative;
}
.theme-notifications { position: relative; }
.notification-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  min-width: 1.25rem;
  height: 1.25rem;
  padding: 0 0.35rem;
  font-size: 0.7rem;
  line-height: 1.25rem;
  text-align: center;
  background: var(--color-danger);
  color: #fff;
  border-radius: 9999px;
}
.theme-notifications-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 0.5rem;
  min-width: 320px;
  max-width: 400px;
  max-height: 400px;
  overflow: hidden;
  background: var(--color-neutral-white);
  border: 1px solid var(--color-neutral-gray-200);
  border-radius: 0.5rem;
  box-shadow: var(--shadow-lg);
  z-index: 1000;
}
.theme-notifications-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--color-neutral-gray-200);
  font-weight: 600;
  font-size: 0.875rem;
}
#notifications-list { max-height: 320px; overflow-y: auto; }
.theme-notification-item {
  display: block;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--color-neutral-gray-100);
  color: var(--color-neutral-gray-800);
  text-decoration: none;
  font-size: 0.875rem;
}
.theme-notification-item:hover { background: var(--color-neutral-gray-50); }
.theme-notification-body { font-size: 0.8rem; color: var(--color-neutral-gray-600); }
.theme-notification-time { font-size: 0.75rem; color: var(--color-neutral-gray-500); }
.theme-notification-empty {
  padding: 1rem;
  text-align: center;
  color: var(--color-neutral-gray-500);
  font-size: 0.875rem;
}

.theme-user-menu .theme-user-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 0.25rem;
  min-width: 160px;
  background: var(--color-neutral-white);
  border: 1px solid var(--color-neutral-gray-200);
  border-radius: 0.375rem;
  box-shadow: var(--shadow-md);
  z-index: 1001;
  padding: 0.25rem 0;
}
.theme-user-dropdown-item {
  display: block;
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  color: var(--color-neutral-gray-800);
  text-decoration: none;
}
.theme-user-dropdown-item:hover { background: var(--color-neutral-gray-50); }

.theme-topbar-version {
  display: none !important;
}

/* Wizard stepper */
.wizard-stepper {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  padding: 1rem;
  background: var(--ov-surface);
  border: 1px solid var(--color-neutral-gray-200);
  border-radius: var(--ov-radius-lg);
}
.wizard-step {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ov-ink-muted);
  background: var(--ov-surface-alt);
  border: 1px solid transparent;
}
.wizard-step.is-active {
  color: #fff;
  background: linear-gradient(135deg, var(--ov-accent), var(--ov-primary));
  border-color: transparent;
}
.wizard-step.is-done {
  color: var(--ov-primary);
  background: rgba(29, 127, 191, 0.12);
  border-color: rgba(29, 127, 191, 0.35);
}
.wizard-step-num {
  width: 1.4rem;
  height: 1.4rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  background: rgba(255, 255, 255, 0.25);
}
.wizard-step.is-done .wizard-step-num,
.wizard-step:not(.is-active) .wizard-step-num {
  background: rgba(15, 76, 129, 0.12);
}
.wizard-actions {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--color-neutral-gray-200);
}

/* Status chips */
.ed-chip,
.sh-chip {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-sizing: border-box;
}
.ed-chip-green, .sh-chip-green { background: rgba(16, 185, 129, 0.15); color: #047857; }
.ed-chip-amber, .sh-chip-amber { background: rgba(245, 158, 11, 0.18); color: #b45309; }
.ed-chip-red, .sh-chip-red { background: rgba(239, 68, 68, 0.15); color: #b91c1c; }
.ed-chip-blue, .sh-chip-blue { background: rgba(29, 127, 191, 0.15); color: #0f4c81; }
.ed-chip-gray, .sh-chip-gray { background: rgba(100, 116, 139, 0.15); color: #475569; }

/* Prevent long names/emails from breaking layouts */
.theme-nowrap,
.theme-table td,
.theme-table th {
  overflow-wrap: anywhere;
}
.theme-table td .theme-action-group {
  flex-wrap: wrap !important;
  white-space: normal !important;
  max-width: 15.5rem;
}
.employee-profile-name {
  margin: 0.75rem 0 0.25rem;
  font-size: 1.05rem;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}
.employee-profile-chip {
  display: block;
  width: 100%;
  max-width: 100%;
  margin-top: 0.75rem;
  text-align: left;
  white-space: normal;
  overflow: visible;
  height: auto;
  line-height: 1.35;
  box-sizing: border-box;
}
.employee-profile-chip .chip-label {
  font-weight: 700;
  margin-right: 0.25rem;
}
.employee-profile-chip .chip-value {
  display: inline;
  word-break: break-all;
  overflow-wrap: anywhere;
  white-space: normal;
}
@media (max-width: 720px) {
  .employee-profile-grid {
    grid-template-columns: 1fr !important;
  }
}
.collapsible-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.collapsible-list details.theme-card {
  padding: 0 !important;
}
.collapsible-list details.theme-card::before {
  display: none !important;
}
.collapsible-summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.9rem 1.1rem;
  margin: 0;
  user-select: none;
}
.collapsible-summary::-webkit-details-marker { display: none; }
.collapsible-summary-title {
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.collapsible-summary-meta {
  font-size: 0.8rem;
  color: var(--ov-ink-muted, #46617c);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.collapsible-body {
  padding: 0 1.1rem 1.1rem;
  border-top: 1px solid rgba(15, 76, 129, 0.1);
}

/* Placeholder nav items (pre-discovery) */
.theme-nav-item--disabled {
  opacity: 0.55;
  cursor: not-allowed;
  pointer-events: none;
}

.tender-progress-bar {
  height: 0.45rem;
  background: var(--color-neutral-gray-200);
  border-radius: 999px;
  overflow: hidden;
}
.tender-progress-bar > span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--ov-accent), var(--ov-primary));
}

/* =============================================================================
   Sidebar collapse / pin (Smart Production pattern)
   ============================================================================= */

.theme-layout {
  min-width: 0;
}

.theme-main {
  min-width: 0;
  flex: 1 1 auto;
}

.theme-sidebar-toggle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.theme-sidebar-toggle-icon--closed {
  display: none;
}

.sp-sidebar-collapsed .theme-sidebar-toggle-icon--open {
  display: none;
}

.sp-sidebar-collapsed .theme-sidebar-toggle-icon--closed {
  display: inline-block;
}

.theme-mobile-menu-btn {
  display: none;
}

.dock-sidebar-controls {
  margin-top: auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0.35rem 0.1rem 0.15rem;
}

.dock-sidebar-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  width: 100%;
  min-height: 2.1rem;
  padding: 0.4rem 0.55rem;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.55), rgba(15, 76, 129, 0.75));
  color: #fff;
  font-size: 0.68rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, filter 0.15s ease;
}

.dock-sidebar-btn:hover {
  filter: brightness(1.12);
  border-color: rgba(255, 255, 255, 0.55);
}

.dock-sidebar-btn[aria-pressed="true"] {
  background: linear-gradient(135deg, rgba(167, 139, 250, 0.7), rgba(91, 33, 182, 0.85));
  border-color: rgba(255, 255, 255, 0.6);
}

.dock-sidebar-btn svg {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
}

.dock-sidebar-btn-icon--expand,
.dock-sidebar-btn-icon--unpin {
  display: none;
}

#sidebar-collapse-btn[aria-pressed="true"] .dock-sidebar-btn-icon--collapse {
  display: none;
}

#sidebar-collapse-btn[aria-pressed="true"] .dock-sidebar-btn-icon--expand {
  display: inline-block;
}

#sidebar-pin-btn[aria-pressed="true"] .dock-sidebar-btn-icon--pin {
  display: none;
}

#sidebar-pin-btn[aria-pressed="true"] .dock-sidebar-btn-icon--unpin {
  display: inline-block;
}

@media (min-width: 769px) {
  .theme-dock-shell {
    transition: width 0.2s ease, min-width 0.2s ease;
  }

  .theme-layout.sp-sidebar-collapsed .theme-dock-shell {
    width: 4.35rem;
    min-width: 4.35rem;
  }

  .theme-layout.sp-sidebar-collapsed .dock-brand-text,
  .theme-layout.sp-sidebar-collapsed .dock-nav > .theme-nav-item.menu-item > span,
  .theme-layout.sp-sidebar-collapsed .dock-nav .menu-group-header .menu-group-title span,
  .theme-layout.sp-sidebar-collapsed .dock-nav .menu-group-header .menu-group-chevron,
  .theme-layout.sp-sidebar-collapsed .dock-sidebar-btn-label,
  .theme-layout.sp-sidebar-collapsed .dock-quick-search {
    display: none;
  }

  .theme-layout.sp-sidebar-collapsed .dock-brand-logo-wrap {
    padding: 0.4rem 0.45rem;
  }

  .theme-layout.sp-sidebar-collapsed .dock-brand-logo {
    max-height: 1.85rem;
  }

  .theme-layout.sp-sidebar-collapsed .dock-nav > .theme-nav-item.menu-item,
  .theme-layout.sp-sidebar-collapsed .dock-nav .menu-group-header {
    min-height: 3.15rem;
    padding: 0.45rem 0.25rem;
    cursor: pointer;
    justify-content: center;
  }

  .theme-layout.sp-sidebar-collapsed .dock-nav > .theme-nav-item.menu-item .theme-nav-icon,
  .theme-layout.sp-sidebar-collapsed .dock-nav .menu-group-header .menu-group-icon {
    width: 1.2rem;
    height: 1.2rem;
  }

  .theme-layout.sp-sidebar-collapsed .dock-nav .menu-group-header .menu-group-title {
    justify-content: center;
  }

  .theme-layout.sp-sidebar-collapsed .dock-nav .menu-group.expanded .menu-group-items {
    display: block;
    width: 250px;
    min-width: 250px;
    max-width: 250px;
    max-height: min(70vh, 620px);
    overflow: auto;
    box-sizing: border-box;
    background: rgba(241, 245, 249, 0.42);
    backdrop-filter: blur(12px) saturate(1.2);
    -webkit-backdrop-filter: blur(12px) saturate(1.2);
    border: 1px solid rgba(15, 76, 129, 0.18);
    border-radius: 16px;
    box-shadow: 0 18px 40px rgba(7, 20, 35, 0.22);
    padding: 0.45rem;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    z-index: 1200;
  }

  .theme-layout.sp-sidebar-collapsed .dock-sidebar-btn {
    min-height: 2rem;
    padding-inline: 0.35rem;
  }

  .theme-layout:not(.sp-sidebar-collapsed) .theme-dock-shell {
    position: relative;
    z-index: auto;
    width: 12rem;
    min-width: 12rem;
  }

  .theme-mobile-menu-btn {
    display: none !important;
  }
}

@media (max-width: 768px) {
  .theme-sidebar-toggle-btn {
    display: none !important;
  }

  .theme-mobile-menu-btn {
    display: inline-flex !important;
  }

  .dock-sidebar-controls {
    display: none;
  }
}

/* Help + login notification modals */
.theme-help-wrap {
  position: relative;
}

.theme-page-help-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-left: 0.35rem;
  padding: 0.28rem 0.7rem;
  min-height: 2rem;
  border-radius: 999px;
  border: 1px solid rgba(15, 76, 129, 0.18);
  background: linear-gradient(135deg, #e0f2fe, #bae6fd);
  color: #0c4a6e;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.65);
}
.theme-page-help-btn:hover {
  filter: brightness(1.04);
}
.theme-page-help-btn svg {
  width: 0.95rem;
  height: 0.95rem;
}
.theme-page-help-btn[hidden] {
  display: none !important;
}

.theme-help-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 0.35rem);
  width: min(380px, 94vw);
  background: var(--ov-surface, #fff);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 12px;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.16);
  z-index: 60;
  overflow: hidden;
  max-height: 78vh;
  overflow-y: auto;
}

.theme-help-search {
  padding: 0.55rem 0.75rem 0.35rem;
  position: sticky;
  top: 2.6rem;
  background: var(--ov-surface, #fff);
  z-index: 1;
}
.theme-help-search .theme-form-input {
  width: 100%;
  min-height: 2.15rem;
  font-size: 0.85rem;
}

.theme-help-dropdown .theme-notif-header {
  position: sticky;
  top: 0;
  background: var(--ov-surface, #fff);
  z-index: 2;
}

.theme-help-section-label {
  padding: 0.45rem 0.9rem 0.25rem;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--ov-ink-muted, #64748b);
}

.theme-help-item {
  display: block;
  width: 100%;
  text-align: left;
  padding: 0.65rem 0.9rem;
  border: none;
  background: transparent;
  cursor: pointer;
  font: inherit;
  color: inherit;
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.theme-help-item:hover {
  background: rgba(15, 23, 42, 0.04);
}

.theme-help-item--page {
  background: rgba(14, 165, 233, 0.08);
}

.theme-help-item .title {
  font-weight: 600;
  font-size: 0.875rem;
}

.theme-help-item .msg {
  color: var(--ov-ink-muted, #64748b);
  font-size: 0.78rem;
  margin-top: 0.15rem;
}

.theme-help-empty {
  padding: 0.85rem 0.9rem 1rem;
  color: var(--ov-ink-muted, #64748b);
  font-size: 0.82rem;
}

/* In-app help coach + spotlight */
.shr-help-spotlight {
  position: fixed;
  border-radius: 12px;
  box-shadow: 0 0 0 9999px rgba(15, 23, 42, 0.45);
  border: 2px solid #1d7fbf;
  pointer-events: none;
  z-index: 10040;
  transition: top 0.2s ease, left 0.2s ease, width 0.2s ease, height 0.2s ease;
}

.shr-help-target {
  position: relative;
  z-index: 10041 !important;
  border-radius: 10px;
}

.shr-help-coach {
  width: min(360px, calc(100vw - 24px));
  background: #fff;
  border: 1px solid rgba(15, 76, 129, 0.14);
  border-radius: 14px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.22);
  padding: 0.9rem 1rem 1rem;
  color: #0f172a;
}

.shr-help-coach-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.shr-help-coach-kicker {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
}

.shr-help-coach-title {
  font-size: 1.05rem;
  font-weight: 700;
  margin-top: 0.15rem;
}

.shr-help-coach-x {
  border: none;
  background: transparent;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  color: #64748b;
  padding: 0 0.15rem;
}

.shr-help-coach-meta {
  font-size: 0.8rem;
  color: #64748b;
  margin: 0.55rem 0 0.35rem;
}

.shr-help-coach-body {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.5;
  color: #334155;
}

.shr-help-coach-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin-top: 0.9rem;
  flex-wrap: wrap;
}

.shr-help-coach-actions .theme-btn,
.learning-touch {
  min-height: 44px;
  min-width: 44px;
}

a.theme-help-item {
  display: block;
  text-decoration: none;
  color: inherit;
}

.learning-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.learning-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 640px) {
  .learning-grid { grid-template-columns: 1fr 1fr; }
}

@media (min-width: 1024px) {
  .learning-grid { grid-template-columns: 1fr 1fr 1fr; }
}

@media (min-width: 1440px) {
  .learning-grid { grid-template-columns: 1fr 1fr 1fr 1fr; }
}

.learning-card {
  display: block;
  text-decoration: none;
  color: inherit;
  overflow: hidden;
}

.learning-poster,
.learning-poster-frame {
  aspect-ratio: 16 / 9;
  width: 100%;
  display: block;
  background: var(--ov-surface-muted, var(--color-neutral-gray-200, #e8eef4));
}

.learning-poster {
  object-fit: cover;
}

.learning-player {
  width: 100%;
  max-width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
  background: var(--ov-surface-muted, var(--color-neutral-gray-200, #e8eef4));
}

.learning-transcript {
  white-space: pre-wrap;
  font-family: inherit;
}

.help-centre-card {
  display: block;
  text-decoration: none;
  color: inherit;
}

.help-steps {
  padding-left: 1.25rem;
}

@media (max-width: 640px) {
  .shr-help-coach {
    top: auto !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    max-width: none;
    border-radius: 16px 16px 0 0;
  }

  .theme-page-stack,
  .learning-grid,
  .learning-player {
    max-width: 100%;
  }
}

/* ============================================================================
   T1: Inherit font on form controls
   ============================================================================ */
button, input, select, textarea {
  font-family: inherit;
}

/* ============================================================================
   T3: Role pill next to user name in topbar
   ============================================================================ */
.role-pill {
  display: inline-block;
  padding: 0.12rem 0.5rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  background: rgba(15, 76, 129, 0.12);
  color: var(--ov-primary, #0f4c81);
  vertical-align: middle;
  margin-left: 0.35rem;
}

/* ============================================================================
   T5-T7, B19: Pipeline board
   ============================================================================ */
.pipeline-board {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  -webkit-overflow-scrolling: touch;
}
.pipeline-column {
  flex: 0 0 260px;
  min-width: 220px;
  max-width: 300px;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.pipeline-column-header {
  padding: 0.65rem 0.75rem;
  background: var(--ov-surface-alt, #f4f7fb);
  border-radius: var(--ov-radius-lg, 12px);
  border: 1px solid rgba(15, 76, 129, 0.12);
}
.pipeline-column-title {
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--ov-ink, #0f172a);
}
.pipeline-column-meta {
  font-size: 0.75rem;
  color: var(--ov-ink-muted, #64748b);
  margin-top: 0.15rem;
}
.pipeline-column-cards {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.pipeline-card {
  padding: 0.75rem !important;
  margin: 0 !important;
  cursor: pointer;
}
.pipeline-card:hover {
  transform: translateY(-2px);
}
.pipeline-card-title {
  font-weight: 700;
  font-size: 0.88rem;
  line-height: 1.25;
  margin-bottom: 0.2rem;
}
.pipeline-card-meta {
  font-size: 0.78rem;
  color: var(--ov-ink-muted, #64748b);
}

/* ============================================================================
   T6: Deal timeline stepper
   ============================================================================ */
.deal-timeline-stepper {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.5rem;
}
.deal-timeline-step {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ov-ink-muted, #64748b);
  background: var(--ov-surface-alt, #f4f7fb);
  border: 1px solid transparent;
}
.deal-timeline-step.is-active {
  color: #fff;
  background: linear-gradient(135deg, var(--ov-accent, #1d7fbf), var(--ov-primary, #0f4c81));
  border-color: transparent;
}
.deal-timeline-step.is-done {
  color: #047857;
  background: rgba(22, 163, 74, 0.12);
  border-color: rgba(22, 163, 74, 0.3);
}
.deal-timeline-badge {
  width: 1.3rem;
  height: 1.3rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.3);
}
.deal-timeline-step.is-done .deal-timeline-badge {
  background: rgba(22, 163, 74, 0.2);
}
.deal-timeline-step .deal-timeline-label {
  white-space: nowrap;
}

/* ============================================================================
   T7: Status pills (deal cards)
   ============================================================================ */
.status-pill-active { background: rgba(22, 163, 74, 0.12); color: #047857; }
.status-pill-needs-changes { background: rgba(245, 158, 11, 0.15); color: #b45309; }
.status-pill-closed { background: rgba(29, 127, 191, 0.12); color: #0f4c81; }
.status-pill-lost { background: rgba(220, 38, 38, 0.12); color: #b91c1c; }

/* ============================================================================
   T9 / B29: Login page full-height background
   ============================================================================ */
.theme-auth-page {
  min-height: 100vh;
}
.theme-auth-page .theme-main {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
.theme-login-shell {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
  background: linear-gradient(135deg, #0f4c81 0%, #1d7fbf 50%, #0f4c81 100%);
  min-height: 100vh;
}
.theme-login-card {
  background: #fff !important;
}
.theme-login-brand {
  text-align: center;
  margin-bottom: 1rem;
}
.theme-login-brand img {
  max-height: 4rem;
  max-width: 12rem;
}

/* ============================================================================
   B21 / T8: Mobile responsive tables ≤640px
   ============================================================================ */
@media (max-width: 640px) {
  .v2-responsive-table thead {
    display: none;
  }
  .v2-responsive-table tbody tr {
    display: flex;
    flex-direction: column;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(15, 76, 129, 0.1);
  }
  .v2-responsive-table tbody td {
    display: block;
    padding: 0.2rem 0;
    border: none;
  }
  .v2-responsive-table tbody td:first-child {
    font-weight: 700;
  }

  .pipeline-board {
    flex-direction: column;
  }
  .pipeline-column {
    flex: 1 1 auto;
    max-width: 100%;
  }

  .theme-title,
  .theme-topbar-content .theme-title {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    word-break: normal;
    max-width: 40vw;
    min-width: 0;
  }

  .deal-timeline-stepper {
    flex-direction: column;
  }
}

/* Long tables: blur on buttons paints blank blocks in some Chromium builds. */
.theme-table .theme-btn,
.theme-table .theme-btn.action-btn,
.theme-table button,
.theme-table a.theme-btn {
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}
