/* =========================================================
   Oxleon Design System
   Central tokens + shared chrome. Pages use classes, not local CSS.

   Shell:     .ox-page-shell  (+ --overview | --list | --detail | --settings | --operation)
   Header:    .ox-page-header / __crumb / __title / __subtitle / __actions
   Content:   .ox-page-content
   Buttons:   .ox-btn .ox-btn-primary | -secondary | -ghost | -danger
   Cards:     .ox-card  (+ --subtle | --success | --warning | --danger | --info)
   Badge:     .ox-status-badge  (+ --success | --warning | --danger | --info | --neutral)
   Tabs:      .ox-tabs / .ox-tab  (active: cyan hairline)
   Table:     .ox-table  (wrap: .ox-table-wrap)
   Toolbar:   .ox-toolbar
   Forms:     .ox-input .ox-select .ox-textarea .ox-checkbox .ox-toggle
              .ox-field-label .ox-field-help
   Drawer:    .ox-drawer-overlay / .ox-drawer / __header / __body / __footer
   Modal:     .ox-modal-overlay / .ox-modal  (+ --sm | --md | --lg)
   ========================================================= */

:root {
  --ox-brand-cyan: #00A9C4;
  --ox-brand-cyan-hover: #0096AF;
  --ox-brand-cyan-soft: #E6F7FA;
  --ox-brand-cyan-text: #087F93;
  --ox-brand-cyan-selected: #EAF8FA;
  --ox-brand-cyan-ring: rgba(0, 169, 196, 0.10);
  --ox-brand-cyan-ring-strong: rgba(0, 169, 196, 0.18);

  --ox-sidebar-bg: #081018;
  --ox-sidebar-surface: #0D1822;
  --ox-sidebar-active: #102A34;
  --ox-sidebar-border: #172731;
  --ox-sidebar-text: #A9B7C4;
  --ox-sidebar-muted: #718191;

  --ox-page-bg: #F5F7FA;
  --ox-card-bg: #FFFFFF;
  --ox-surface: #FFFFFF;
  --ox-surface-soft: #F8FAFC;
  --ox-surface-elevated: #FFFFFF;

  --ox-text-primary: #111827;
  --ox-text-secondary: #64748B;
  --ox-text-muted: #94A3B8;

  --ox-border: #E2E8F0;
  --ox-border-soft: #EEF2F6;
  /* OXLEON_ZOHO_Z13_2026_10_03: fixed white behind official vendor logos (not overridden in dark mode). */
  --ox-logo-chip-bg: #FFFFFF;
  --ox-border-hover: #C8D6DE;
  --ox-border-strong: #CBD5E1;
  --ox-border-input: #D7DEE6;

  --ox-success: #18A66A;
  --ox-success-bg: #ECFDF5;
  --ox-success-border: #A7F3D0;
  --ox-warning: #F59E0B;
  --ox-warning-bg: #FFFBEB;
  --ox-warning-border: #FCD34D;
  --ox-danger: #E5484D;
  --ox-danger-bg: #FEF2F2;
  --ox-danger-border: #FECACA;
  --ox-danger-strong: #C62B30; /* filled destructive actions: white text >= 4.5:1 */
  --ox-info: #3B82F6;
  --ox-info-bg: #EFF6FF;
  --ox-info-border: #BFDBFE;

  --ox-brand-navy: #081018;
  --ox-brand-navy-deep: #061016;
  --ox-brand-navy-mid: #0D1822;

  --ox-primary: var(--ox-brand-cyan);
  --ox-primary-hover: var(--ox-brand-cyan-hover);
  --ox-primary-soft: var(--ox-brand-cyan-soft);
  --ox-primary-text: #FFFFFF;

  --ox-radius-sm: 8px;
  --ox-radius-md: 12px;
  --ox-radius-lg: 16px;

  --ox-shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.04);
  --ox-shadow-md: 0 4px 12px rgba(15, 23, 42, 0.04);
  --ox-shadow-card:
    0 1px 2px rgba(15, 23, 42, 0.04),
    0 4px 12px rgba(15, 23, 42, 0.04);
  --ox-shadow-hover: 0 6px 18px rgba(15, 23, 42, 0.06);

  --ox-space-1: 4px;
  --ox-space-2: 8px;
  --ox-space-3: 12px;
  --ox-space-4: 16px;
  --ox-space-5: 20px;
  --ox-space-6: 24px;
  --ox-space-7: 32px;

  --ox-page-max-width: 100%;
  --ox-page-padding-x: 24px;
  --ox-page-padding-y: 16px;

  --ox-control-height: 34px;
  --ox-control-height-lg: 38px;
  --ox-control-font: 13px;
  --ox-icon-size: 16px;
  --ox-focus-ring: 0 0 0 3px var(--ox-brand-cyan-ring);
  --ox-focus-ring-strong: 0 0 0 3px var(--ox-brand-cyan-ring-strong);

  --ox-font-title: 21px;
  --ox-font-section: 15px;
  --ox-font-card-title: 14px;
  --ox-font-body: 13px;
  --ox-font-secondary: 12px;
  --ox-font-caption: 11px;
  --ox-font-table: 13px;
  --ox-font-table-label: 11px;
  --ox-font-crumb: 12px;

  --ox-tab-height: 44px;
  --ox-table-head-height: 40px;
  --ox-table-row-height: 44px;
  --ox-drawer-width: 480px;
  --ox-modal-sm: 420px;
  --ox-modal-md: 640px;
  --ox-modal-lg: 880px;

  --ox-bp-mobile: 720px;
  --ox-bp-tablet: 1100px;
  --ox-bp-desktop: 1400px;

  /* Legacy gold aliases now resolve to cyan branding. Warning yellow stays on --ox-warning. */
  --ox-brand-gold: var(--ox-brand-cyan);
  --ox-brand-gold-dark: var(--ox-brand-cyan-hover);
  --ox-brand-gold-deep: var(--ox-brand-cyan-text);
  --ox-brand-gold-light: var(--ox-brand-cyan-soft);
  --ox-brand-gold-border: #7ED4E0;
  --ox-gold: var(--ox-brand-cyan);
  --ox-gold-dark: var(--ox-brand-cyan-hover);
  --ox-gold-deep: var(--ox-brand-cyan-text);
  --ox-gold-border: var(--ox-brand-gold-border);
  --ox-gold-light: var(--ox-brand-cyan-soft);
  --ox-gold-gradient: var(--ox-brand-cyan);
  --ox-navy: var(--ox-brand-navy);
  --ox-navy-deep: var(--ox-brand-navy-deep);
  --ox-navy-mid: var(--ox-brand-navy-mid);

  --ax-card: var(--ox-surface);
  --ax-card-soft: var(--ox-surface-soft);
  --ax-text: var(--ox-text-primary);
  --ax-muted: var(--ox-text-muted);
  --ax-border: var(--ox-border);
  --ax-border-soft: var(--ox-border-soft);
  --ax-success: var(--ox-success);
  --ax-warning: var(--ox-warning);
  --ax-danger: var(--ox-danger);
  --sidebar-width: 280px;
}

/* N1: the 280px above (and in oxleon-sidebar.css) loads after style.css and overrode its <=1200px rail width
   (82px), so on tablet/mobile the content kept a 280px offset next to an 82px sidebar. */
@media (max-width: 1200px) {
  :root {
    --sidebar-width: 82px;
  }
}

.sidebar,
.sidebar--oxleon {
  --ox-border-soft: var(--ox-sidebar-border);
  --ox-gold-light: var(--ox-brand-cyan);
}

html[data-theme="dark"] {
  --ox-page-bg: #09111A;
  --ox-card-bg: #101A24;
  --ox-surface: #101A24;
  --ox-surface-soft: #13202B;
  --ox-surface-elevated: #182430;
  --ox-text-primary: #F1F5F9;
  --ox-text-secondary: #A7B4C2;
  --ox-text-muted: #718191;
  --ox-border: #20303C;
  --ox-border-soft: #1A2833;
  --ox-border-hover: #2A3C49;
  --ox-border-strong: #2A3C49;
  --ox-border-input: #2A3C49;
  --ox-success-bg: #0B2A1C;
  --ox-success-border: #145C3A;
  --ox-warning-bg: #2A1C05;
  --ox-warning-border: #8A5A12;
  --ox-danger-bg: #2A1012;
  --ox-danger-border: #5C2226;
  --ox-info-bg: #0B1C3A;
  --ox-brand-gold-light: #102A34;
  --ox-brand-cyan-soft: #102A34;
  --ox-brand-cyan-selected: #102A34;
  --ox-focus-ring: 0 0 0 3px rgba(0, 169, 196, 0.22);
  --ox-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.28);
  --ox-shadow-md: 0 8px 24px rgba(0, 0, 0, 0.32);
  --ox-shadow-card: 0 1px 2px rgba(0, 0, 0, 0.18), 0 8px 20px rgba(0, 0, 0, 0.22);
  --ox-shadow-hover: 0 8px 22px rgba(0, 0, 0, 0.28);
}

/* ── One canvas ── */

html {
  background: var(--ox-page-bg);
}

html,
body {
  color: var(--ox-text-primary);
}

body {
  background: var(--ox-page-bg);
}

main.content,
.content {
  background: var(--ox-page-bg) !important;
  background-image: none !important;
  padding: calc(var(--ox-shell-top, 64px) + var(--ox-page-padding-y)) var(--ox-page-padding-x) calc(var(--footer-height, 64px) + var(--ox-space-5)) !important;
}

#pageContent {
  width: 100%;
  max-width: var(--ox-page-max-width);
  padding: 0 !important;
  background: transparent !important;
  overflow: visible;
}

html[data-theme="dark"] main.content,
html[data-theme="dark"] .content {
  background: var(--ox-page-bg) !important;
  background-image: none !important;
}

/* ── Page shell ── */

.ox-page-shell,
.ax-sys-shell {
  --ax-sys-bg: var(--ox-page-bg);
  --ax-sys-card: var(--ox-surface);
  --ax-sys-border: var(--ox-border);
  --ax-sys-border-h: var(--ox-border-hover);
  --ax-sys-text-1: var(--ox-text-primary);
  --ax-sys-text-2: var(--ox-text-secondary);
  --ax-sys-text-3: var(--ox-text-muted);
  --ax-sys-accent: var(--ox-info);
  --ax-sys-radius: var(--ox-radius-md);
  --ax-sys-radius-sm: var(--ox-radius-sm);
  --ax-sys-gap: var(--ox-space-4);
  --ax-sys-shadow: var(--ox-shadow-sm);
  --ax-sys-green: var(--ox-success);
  --ax-sys-green-bg: var(--ox-success-bg);
  --ax-sys-red: var(--ox-danger);
  --ax-sys-red-bg: var(--ox-danger-bg);
  --ax-sys-amber: var(--ox-warning);
  --ax-sys-amber-bg: var(--ox-warning-bg);

  width: 100%;
  max-width: var(--ox-page-max-width);
  margin: 0;
  padding: 0 0 var(--ox-space-4) !important;
  background: var(--ox-page-bg) !important;
  background-image: none !important;
  min-height: 0;
  box-sizing: border-box;
  font-family: Inter, Segoe UI, Arial, sans-serif;
  font-size: var(--ox-font-body);
  color: var(--ox-text-primary);
  display: flex;
  flex-direction: column;
  gap: var(--ox-space-4);
  overflow: visible;
  border: 0 !important;
  box-shadow: none !important;
}

.ox-page-content {
  display: flex;
  flex-direction: column;
  gap: var(--ox-space-4);
  min-width: 0;
}

.ox-page-shell--overview,
.ox-page-shell--list,
.ox-page-shell--detail,
.ox-page-shell--settings,
.ox-page-shell--operation {
  gap: var(--ox-space-4);
}

/* ── Page header ── */

.ox-page-header,
.ax-sys-header,
:is(.ox-page-shell, .ax-sys-shell) .sa-header,
:is(.ox-page-shell, .ax-sys-shell) .um-header,
:is(.ox-page-shell, .ax-sys-shell) .rp-header,
:is(.ox-page-shell, .ax-sys-shell) .bk-header,
:is(.ox-page-shell, .ax-sys-shell) .su-header,
:is(.ox-page-shell, .ax-sys-shell) .lic-header,
:is(.ox-page-shell, .ax-sys-shell) .security-top,
:is(.ox-page-shell, .ax-sys-shell) .subs-top,
:is(.ox-page-shell, .ax-sys-shell) .audit-top,
:is(.ox-page-shell, .ax-sys-shell) .ds-header,
:is(.ox-page-shell, .ax-sys-shell) .integrations-page-header,
:is(.ox-page-shell, .ax-sys-shell) .hw-shell-header,
:is(.ox-page-shell, .ax-sys-shell) .hardware-header-block,
.personen-page .subs-top,
.ax-dashboard .dg-header-bar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--ox-space-4);
  flex-wrap: wrap;
  margin: 0 !important;
  padding: 0;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

.ox-page-header__text,
.ox-page-header > div:first-child,
.ax-sys-header-text {
  min-width: 0;
}

.ox-page-header__crumb {
  margin: 0 0 var(--ox-space-1);
  font-size: var(--ox-font-crumb);
  font-weight: 600;
  color: var(--ox-text-muted);
  letter-spacing: 0.01em;
}

.ox-page-header__title,
.ox-page-header h1,
.ax-sys-title,
:is(.ox-page-shell, .ax-sys-shell) .sa-title,
:is(.ox-page-shell, .ax-sys-shell) .um-title,
:is(.ox-page-shell, .ax-sys-shell) .rp-title,
.ax-sys-shell h1,
:is(.ox-page-shell, .ax-sys-shell) .page-title,
:is(.ox-page-shell, .ax-sys-shell) .su-header h1,
:is(.ox-page-shell, .ax-sys-shell) .bk-header h1,
:is(.ox-page-shell, .ax-sys-shell) .lic-header h1,
.personen-page .page-title,
.ax-dashboard .page-title {
  margin: 0 !important;
  font-size: var(--ox-font-title) !important;
  font-weight: 650 !important;
  line-height: 1.2 !important;
  letter-spacing: -0.02em !important;
  color: var(--ox-text-primary) !important;
}

.ox-page-header__subtitle,
.ox-page-header p,
.ax-sys-subtitle,
:is(.ox-page-shell, .ax-sys-shell) .sa-subtitle,
:is(.ox-page-shell, .ax-sys-shell) .um-subtitle,
:is(.ox-page-shell, .ax-sys-shell) .rp-subtitle,
:is(.ox-page-shell, .ax-sys-shell) .page-subtitle,
:is(.ox-page-shell, .ax-sys-shell) .su-header p,
:is(.ox-page-shell, .ax-sys-shell) .bk-header p,
:is(.ox-page-shell, .ax-sys-shell) .lic-header p,
.personen-page .page-subtitle {
  margin: var(--ox-space-1) 0 0 !important;
  font-size: var(--ox-font-secondary) !important;
  font-weight: 400 !important;
  line-height: 1.45 !important;
  color: var(--ox-text-muted) !important;
  max-width: 52rem;
}

.ox-page-header__actions,
.ax-sys-header-actions,
:is(.ox-page-shell, .ax-sys-shell) .sa-header-actions,
:is(.ox-page-shell, .ax-sys-shell) .um-header-actions,
:is(.ox-page-shell, .ax-sys-shell) .rp-header-actions,
:is(.ox-page-shell, .ax-sys-shell) .bk-actions,
:is(.ox-page-shell, .ax-sys-shell) .su-actions,
:is(.ox-page-shell, .ax-sys-shell) .lic-actions,
:is(.ox-page-shell, .ax-sys-shell) .subs-actions {
  display: flex;
  align-items: center;
  gap: var(--ox-space-2);
  flex-wrap: wrap;
}

/* ── Buttons ── */

.ox-btn,
.ax-sys-btn,
:is(.ox-page-shell, .ax-sys-shell) .sa-btn,
:is(.ox-page-shell, .ax-sys-shell) .um-btn,
:is(.ox-page-shell, .ax-sys-shell) .rp-btn,
:is(.ox-page-shell, .ax-sys-shell) .backup-btn,
:is(.ox-page-shell, .ax-sys-shell) .su-btn,
:is(.ox-page-shell, .ax-sys-shell) .lic-btn,
:is(.ox-page-shell, .ax-sys-shell) .security-btn,
:is(.ox-page-shell, .ax-sys-shell) .hw-btn,
:is(.ox-page-shell, .ax-sys-shell) .ds-btn,
:is(.ox-page-shell, .ax-sys-shell) .sn-btn,
:is(.ox-page-shell, .ax-sys-shell) .integration-btn,
:is(.ox-page-shell, .ax-sys-shell) .subs-btn,
:is(.ox-page-shell, .ax-sys-shell) .subs-btn-sm,
:is(.ox-page-shell, .ax-sys-shell) .primary-btn,
:is(.ox-page-shell, .ax-sys-shell) .secondary-btn,
:is(.ox-page-shell, .ax-sys-shell) .org-btn,
:is(.ox-page-shell, .ax-sys-shell) .pin-btn,
:is(.ox-page-shell, .ax-sys-shell) .tv-btn,
:is(.ox-page-shell, .ax-sys-shell) .time-reg-reset-btn,
:is(.ox-page-shell, .ax-sys-shell) .audit-filters-trigger {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  min-height: var(--ox-control-height) !important;
  height: var(--ox-control-height) !important;
  padding: 0 12px !important;
  font-family: inherit !important;
  font-size: var(--ox-control-font) !important;
  font-weight: 600 !important;
  line-height: 1 !important;
  border-radius: var(--ox-radius-sm) !important;
  border: 1px solid var(--ox-border) !important;
  background: var(--ox-surface) !important;
  color: var(--ox-text-secondary) !important;
  box-shadow: var(--ox-shadow-sm) !important;
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  box-sizing: border-box;
  transition: background 0.12s, border-color 0.12s, color 0.12s, box-shadow 0.12s;
}

.ox-btn svg,
:is(.ox-page-shell, .ax-sys-shell) .sa-btn svg,
:is(.ox-page-shell, .ax-sys-shell) .um-btn svg,
:is(.ox-page-shell, .ax-sys-shell) .su-btn svg,
:is(.ox-page-shell, .ax-sys-shell) .hw-btn svg,
:is(.ox-page-shell, .ax-sys-shell) .ds-btn svg,
:is(.ox-page-shell, .ax-sys-shell) .sn-btn svg,
:is(.ox-page-shell, .ax-sys-shell) .subs-btn svg,
.ox-btn img,
:is(.ox-page-shell, .ax-sys-shell) .subs-btn img {
  width: var(--ox-icon-size);
  height: var(--ox-icon-size);
  flex-shrink: 0;
}

.ox-btn:hover,
:is(.ox-page-shell, .ax-sys-shell) .sa-btn:hover,
:is(.ox-page-shell, .ax-sys-shell) .um-btn:hover,
:is(.ox-page-shell, .ax-sys-shell) .su-btn:hover,
:is(.ox-page-shell, .ax-sys-shell) .hw-btn:hover,
:is(.ox-page-shell, .ax-sys-shell) .ds-btn:hover,
:is(.ox-page-shell, .ax-sys-shell) .sn-btn:hover,
:is(.ox-page-shell, .ax-sys-shell) .subs-btn:hover,
:is(.ox-page-shell, .ax-sys-shell) .secondary-btn:hover {
  background: var(--ox-surface-soft) !important;
  border-color: var(--ox-border-hover) !important;
  color: var(--ox-text-primary) !important;
}

.ox-btn:disabled,
:is(.ox-page-shell, .ax-sys-shell) .sa-btn:disabled,
:is(.ox-page-shell, .ax-sys-shell) .um-btn:disabled,
:is(.ox-page-shell, .ax-sys-shell) .su-btn:disabled {
  opacity: 0.5 !important;
  cursor: not-allowed !important;
  transform: none !important;
}

.ox-btn-secondary {
  background: var(--ox-surface) !important;
  color: var(--ox-text-secondary) !important;
}

.ox-btn-primary,
.ax-sys-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .sa-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .sa-disk-cleanup-btn,
:is(.ox-page-shell, .ax-sys-shell) .um-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .rp-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .backup-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .su-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .lic-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .security-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .hw-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .hw-btn.hw-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .ds-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .sn-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .integration-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .primary-btn,
:is(.ox-page-shell, .ax-sys-shell) .subs-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .org-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .pin-btn-primary,
:is(.ox-page-shell, .ax-sys-shell) .tv-btn.primary,
:is(.ox-page-shell, .ax-sys-shell) .su-btn-success-fill,
.personen-page .subs-btn-primary {
  border: 1px solid var(--ox-primary) !important;
  background: var(--ox-primary) !important;
  color: var(--ox-primary-text) !important;
  box-shadow: none !important;
}

.ox-btn-primary:hover,
:is(.ox-page-shell, .ax-sys-shell) .sa-btn-primary:hover,
:is(.ox-page-shell, .ax-sys-shell) .um-btn-primary:hover,
:is(.ox-page-shell, .ax-sys-shell) .su-btn-primary:hover,
:is(.ox-page-shell, .ax-sys-shell) .hw-btn-primary:hover,
:is(.ox-page-shell, .ax-sys-shell) .ds-btn-primary:hover,
:is(.ox-page-shell, .ax-sys-shell) .sn-btn-primary:hover,
:is(.ox-page-shell, .ax-sys-shell) .primary-btn:hover,
:is(.ox-page-shell, .ax-sys-shell) .subs-btn-primary:hover,
:is(.ox-page-shell, .ax-sys-shell) .org-btn-primary:hover,
:is(.ox-page-shell, .ax-sys-shell) .pin-btn-primary:hover,
:is(.ox-page-shell, .ax-sys-shell) .tv-btn.primary:hover,
:is(.ox-page-shell, .ax-sys-shell) .su-btn-success-fill:hover,
.personen-page .subs-btn-primary:hover {
  background: var(--ox-primary-hover) !important;
  border-color: var(--ox-primary-hover) !important;
  color: var(--ox-primary-text) !important;
  filter: none !important;
  transform: none !important;
}

.ox-btn-danger,
.ax-sys-btn-danger,
:is(.ox-page-shell, .ax-sys-shell) .sa-btn-danger,
:is(.ox-page-shell, .ax-sys-shell) .su-btn-danger,
:is(.ox-page-shell, .ax-sys-shell) .lic-btn-danger,
:is(.ox-page-shell, .ax-sys-shell) .backup-btn-restore,
:is(.ox-page-shell, .ax-sys-shell) .ds-btn-danger,
:is(.ox-page-shell, .ax-sys-shell) .sn-btn-danger {
  background: var(--ox-surface) !important;
  border-color: var(--ox-danger-border) !important;
  color: var(--ox-danger) !important;
}

.ox-btn-danger:hover,
:is(.ox-page-shell, .ax-sys-shell) .sa-btn-danger:hover,
:is(.ox-page-shell, .ax-sys-shell) .su-btn-danger:hover,
:is(.ox-page-shell, .ax-sys-shell) .ds-btn-danger:hover,
:is(.ox-page-shell, .ax-sys-shell) .sn-btn-danger:hover {
  background: var(--ox-danger-bg) !important;
  border-color: var(--ox-danger-border) !important;
  color: var(--ox-danger) !important;
}

.ox-btn-ghost,
:is(.ox-page-shell, .ax-sys-shell) .sn-btn-ghost,
:is(.ox-page-shell, .ax-sys-shell) .su-btn-link {
  background: transparent !important;
  border-color: transparent !important;
  box-shadow: none !important;
  color: var(--ox-text-secondary) !important;
}

.ox-btn-ghost:hover,
:is(.ox-page-shell, .ax-sys-shell) .sn-btn-ghost:hover,
:is(.ox-page-shell, .ax-sys-shell) .su-btn-link:hover {
  background: var(--ox-surface-soft) !important;
  border-color: transparent !important;
  color: var(--ox-text-primary) !important;
}

/* ── Cards ── */

.ox-card,
:is(.ox-page-shell, .ax-sys-shell) .ds-card,
:is(.ox-page-shell, .ax-sys-shell) .um-card,
:is(.ox-page-shell, .ax-sys-shell) .su-card,
:is(.ox-page-shell, .ax-sys-shell) .su-product,
:is(.ox-page-shell, .ax-sys-shell) .su-history-panel,
:is(.ox-page-shell, .ax-sys-shell) .su-release-card,
:is(.ox-page-shell, .ax-sys-shell) .sn-surface,
:is(.ox-page-shell, .ax-sys-shell) .security-card,
:is(.ox-page-shell, .ax-sys-shell) .sa-stat,
:is(.ox-page-shell, .ax-sys-shell) .um-stat,
:is(.ox-page-shell, .ax-sys-shell) .rp-stat,
:is(.ox-page-shell, .ax-sys-shell) .hardware-content-card {
  background: var(--ox-surface) !important;
  border: 1px solid var(--ox-border) !important;
  border-radius: var(--ox-radius-md) !important;
  box-shadow: var(--ox-shadow-sm) !important;
  min-width: 0;
}

.ox-card {
  padding: var(--ox-space-4);
}

.ox-card--subtle {
  background: var(--ox-surface-soft) !important;
  box-shadow: none !important;
}

.ox-card--success {
  background: var(--ox-success-bg) !important;
  border-color: var(--ox-success-border) !important;
}

.ox-card--warning {
  background: var(--ox-warning-bg) !important;
  border-color: var(--ox-warning-border) !important;
}

.ox-card--danger {
  background: var(--ox-danger-bg) !important;
  border-color: var(--ox-danger-border) !important;
}

.ox-card--info {
  background: var(--ox-info-bg) !important;
  border-color: var(--ox-info-border) !important;
}

.ox-card__title,
:is(.ox-page-shell, .ax-sys-shell) .ds-card-head h2 {
  margin: 0;
  font-size: var(--ox-font-card-title);
  font-weight: 600;
  color: var(--ox-text-primary);
}

/* ── Status badges ── */

.ox-status-badge,
:is(.ox-page-shell, .ax-sys-shell) .su-badge,
:is(.ox-page-shell, .ax-sys-shell) .users-badge,
:is(.ox-page-shell, .ax-sys-shell) .integration-tile-status,
.personen-page .status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 22px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  border: 1px solid var(--ox-border);
  background: var(--ox-surface-soft);
  color: var(--ox-text-secondary);
}

/* the [hidden] attribute always wins over the badge's display (HWV2: live-display badges were shown while hidden) */
.ox-status-badge[hidden] {
  display: none;
}

.ox-status-badge::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.ox-status-badge--success,
:is(.ox-page-shell, .ax-sys-shell) .su-badge.ok,
:is(.ox-page-shell, .ax-sys-shell) .users-badge.ok {
  background: var(--ox-success-bg);
  border-color: var(--ox-success-border);
  color: var(--ox-success);
}

.ox-status-badge--warning,
:is(.ox-page-shell, .ax-sys-shell) .su-badge.warn {
  background: var(--ox-warning-bg);
  border-color: var(--ox-warning-border);
  color: var(--ox-warning);
}

.ox-status-badge--danger,
:is(.ox-page-shell, .ax-sys-shell) .su-badge.err {
  background: var(--ox-danger-bg);
  border-color: var(--ox-danger-border);
  color: var(--ox-danger);
}

.ox-status-badge--info,
:is(.ox-page-shell, .ax-sys-shell) .su-badge.info {
  background: var(--ox-info-bg);
  border-color: var(--ox-info-border);
  color: var(--ox-info);
}

.ox-status-badge--neutral {
  background: var(--ox-surface-soft);
  border-color: var(--ox-border);
  color: var(--ox-text-muted);
}

/* ── Tabs (cyan hairline) ── */

.ox-tabs,
:is(.ox-page-shell, .ax-sys-shell) .su-tabs,
:is(.ox-page-shell, .ax-sys-shell) .sn-tabs,
:is(.ox-page-shell, .ax-sys-shell) .hardware-tabs,
.pd-tabbar {
  display: flex;
  align-items: stretch;
  gap: var(--ox-space-1);
  min-height: var(--ox-tab-height);
  padding: 0;
  margin: 0;
  border-bottom: 1px solid var(--ox-border);
  background: transparent;
  overflow-x: auto;
  scrollbar-width: none;
}

.ox-tabs::-webkit-scrollbar,
:is(.ox-page-shell, .ax-sys-shell) .su-tabs::-webkit-scrollbar,
:is(.ox-page-shell, .ax-sys-shell) .sn-tabs::-webkit-scrollbar,
:is(.ox-page-shell, .ax-sys-shell) .hardware-tabs::-webkit-scrollbar {
  display: none;
}

.ox-tab,
:is(.ox-page-shell, .ax-sys-shell) .su-tab,
:is(.ox-page-shell, .ax-sys-shell) .sn-tab,
:is(.ox-page-shell, .ax-sys-shell) .hardware-tab,
.pd-tab {
  display: inline-flex !important;
  align-items: center !important;
  gap: var(--ox-space-2) !important;
  min-height: var(--ox-tab-height) !important;
  height: var(--ox-tab-height) !important;
  padding: 0 14px 0 !important;
  margin: 0 0 -1px !important;
  border: 0 !important;
  border-bottom: 2px solid transparent !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: var(--ox-text-muted) !important;
  font-family: inherit !important;
  font-size: var(--ox-font-body) !important;
  font-weight: 600 !important;
  cursor: pointer;
  white-space: nowrap;
}

.ox-tab:hover,
:is(.ox-page-shell, .ax-sys-shell) .su-tab:hover,
:is(.ox-page-shell, .ax-sys-shell) .sn-tab:hover,
:is(.ox-page-shell, .ax-sys-shell) .hardware-tab:hover,
.pd-tab:hover {
  color: var(--ox-text-primary) !important;
  background: transparent !important;
}

.ox-tab.is-active,
.ox-tab[aria-selected="true"],
:is(.ox-page-shell, .ax-sys-shell) .su-tab.is-active,
:is(.ox-page-shell, .ax-sys-shell) .sn-tab.is-active,
:is(.ox-page-shell, .ax-sys-shell) .hardware-tab.active,
:is(.ox-page-shell, .ax-sys-shell) .hardware-tab.is-active {
  color: var(--ox-text-primary) !important;
  color: var(--ox-brand-cyan) !important;
  border-bottom-color: var(--ox-brand-cyan) !important;
  background: transparent !important;
}

.ox-tab.is-active svg,
:is(.ox-page-shell, .ax-sys-shell) .su-tab.is-active .su-tab-icon {
  color: var(--ox-brand-cyan);
}

.pd-tab.is-active {
  color: var(--ox-brand-cyan) !important;
  border-bottom-color: var(--ox-brand-cyan) !important;
  background: transparent !important;
}

/* Integrations category tabs: pills → cyan hairline */
:is(.ox-page-shell, .ax-sys-shell) .integration-category-tabs {
  display: flex;
  align-items: stretch;
  gap: var(--ox-space-1);
  min-height: var(--ox-tab-height);
  border-bottom: 1px solid var(--ox-border);
  background: transparent;
  overflow-x: auto;
}

:is(.ox-page-shell, .ax-sys-shell) .integration-category-tab,
:is(.ox-page-shell, .ax-sys-shell) .integration-category-tab.is-active {
  display: inline-flex !important;
  align-items: center !important;
  min-height: var(--ox-tab-height) !important;
  height: var(--ox-tab-height) !important;
  padding: 0 14px !important;
  margin: 0 0 -1px !important;
  border: 0 !important;
  border-bottom: 2px solid transparent !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: var(--ox-text-muted) !important;
  font-size: var(--ox-font-body) !important;
  font-weight: 600 !important;
}

:is(.ox-page-shell, .ax-sys-shell) .integration-category-tab.is-active {
  color: var(--ox-brand-cyan) !important;
  border-bottom-color: var(--ox-brand-cyan) !important;
}

/* ── Tables ── */

.ox-table-wrap,
:is(.ox-page-shell, .ax-sys-shell) .subs-table-wrap,
:is(.ox-page-shell, .ax-sys-shell) .audit-table-wrap,
:is(.ox-page-shell, .ax-sys-shell) .um-card .um-table-wrap {
  overflow-x: auto;
  overflow-y: visible;
  max-height: none;
  background: var(--ox-surface);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-md);
}

.ox-table,
:is(.ox-page-shell, .ax-sys-shell) .audit-table,
:is(.ox-page-shell, .ax-sys-shell) .um-table,
:is(.ox-page-shell, .ax-sys-shell) .sn-table,
:is(.ox-page-shell, .ax-sys-shell) .subs-table,
.personen-page .subs-table,
.personen-page .personen-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--ox-surface);
  font-size: var(--ox-font-table);
}

.ox-table th,
:is(.ox-page-shell, .ax-sys-shell) .audit-table th,
:is(.ox-page-shell, .ax-sys-shell) .um-table th,
:is(.ox-page-shell, .ax-sys-shell) .sn-table th,
:is(.ox-page-shell, .ax-sys-shell) .subs-table th,
.personen-page .subs-table th {
  height: var(--ox-table-head-height);
  padding: 0 14px;
  font-size: var(--ox-font-table-label);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ox-text-muted);
  background: var(--ox-surface-soft);
  border-bottom: 1px solid var(--ox-border);
  text-align: left;
}

.ox-table td,
:is(.ox-page-shell, .ax-sys-shell) .audit-table td,
:is(.ox-page-shell, .ax-sys-shell) .um-table td,
:is(.ox-page-shell, .ax-sys-shell) .sn-table td,
:is(.ox-page-shell, .ax-sys-shell) .subs-table td,
.personen-page .subs-table td {
  height: var(--ox-table-row-height);
  padding: 0 14px;
  font-size: var(--ox-font-table);
  color: var(--ox-text-primary);
  border-bottom: 1px solid var(--ox-border-soft);
  vertical-align: middle;
}

.ox-table tbody tr:hover td,
:is(.ox-page-shell, .ax-sys-shell) .audit-table tbody tr:hover td,
:is(.ox-page-shell, .ax-sys-shell) .um-table tbody tr:hover td,
.personen-page .subs-table tbody tr:hover td {
  background: #FAFCFD;
}

.ox-table tbody tr.is-selected td,
.ox-table tbody tr.selected td,
:is(.ox-page-shell, .ax-sys-shell) .audit-table tbody tr.selected td,
:is(.ox-page-shell, .ax-sys-shell) .um-table tbody tr.selected td,
.personen-page .subs-table tbody tr.selected td {
  background: var(--ox-brand-cyan-selected);
}

html[data-theme="dark"] .ox-table tbody tr:hover td,
html[data-theme="dark"] :is(.ox-page-shell, .ax-sys-shell) .audit-table tbody tr:hover td,
html[data-theme="dark"] :is(.ox-page-shell, .ax-sys-shell) .um-table tbody tr:hover td,
html[data-theme="dark"] .personen-page .subs-table tbody tr:hover td {
  background: var(--ox-surface-soft);
}

/* Kill nested page-list scroll; keep horizontal overflow for wide tables */
.personen-page .subs-table-wrap,
.audit-page .audit-table-wrap {
  max-height: none !important;
  overflow-y: visible !important;
  overflow-x: auto !important;
}

/* ── Toolbar (Auditlog pattern) ── */

.ox-toolbar,
:is(.ox-page-shell, .ax-sys-shell) .audit-toolbar,
:is(.ox-page-shell, .ax-sys-shell) .um-toolbar,
.personen-page .subs-toolbar {
  display: flex;
  align-items: center;
  gap: var(--ox-space-3);
  flex-wrap: wrap;
  min-height: 52px;
  height: auto !important;
  padding: 10px 0 !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

.ox-toolbar input[type="search"],
.ox-toolbar input[type="text"],
:is(.ox-page-shell, .ax-sys-shell) .audit-search-box input,
:is(.ox-page-shell, .ax-sys-shell) .um-search-wrap input,
:is(.ox-page-shell, .ax-sys-shell) .integration-search,
.personen-page .subs-toolbar input[type="search"],
.personen-page .subs-toolbar input[type="text"] {
  height: var(--ox-control-height) !important;
  min-height: var(--ox-control-height) !important;
  padding: 0 12px 0 36px !important;
  border: 1px solid var(--ox-border) !important;
  border-radius: var(--ox-radius-sm) !important;
  background: var(--ox-surface) !important;
  color: var(--ox-text-primary) !important;
  font-size: var(--ox-font-body) !important;
  box-shadow: none !important;
}

.ox-toolbar select,
:is(.ox-page-shell, .ax-sys-shell) .audit-period-wrap select,
.personen-page .subs-toolbar select {
  height: var(--ox-control-height) !important;
  min-height: var(--ox-control-height) !important;
  padding: 0 12px !important;
  border: 1px solid var(--ox-border) !important;
  border-radius: var(--ox-radius-sm) !important;
  background: var(--ox-surface) !important;
  color: var(--ox-text-primary) !important;
  font-size: var(--ox-font-body) !important;
}

/* ── Forms ── */

.ox-field-label {
  display: block;
  margin: 0 0 var(--ox-space-1);
  font-size: var(--ox-font-caption);
  font-weight: 600;
  color: var(--ox-text-secondary);
}

.ox-field-help {
  margin: var(--ox-space-1) 0 0;
  font-size: var(--ox-font-caption);
  color: var(--ox-text-muted);
  line-height: 1.4;
}

.ox-input,
.ox-select,
.ox-textarea,
.ax-sys-shell input[type="text"],
.ax-sys-shell input[type="search"],
.ax-sys-shell input[type="email"],
.ax-sys-shell input[type="password"],
.ax-sys-shell input[type="number"],
.ax-sys-shell input[type="url"],
.ax-sys-shell input[type="date"],
.ax-sys-shell input[type="time"],
.ax-sys-shell select,
.ax-sys-shell textarea {
  width: 100%;
  min-height: var(--ox-control-height);
  height: var(--ox-control-height);
  padding: 0 12px;
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-sm);
  background: var(--ox-surface);
  color: var(--ox-text-primary);
  font-family: inherit;
  font-size: var(--ox-font-body);
  box-sizing: border-box;
}

.ox-textarea,
.ax-sys-shell textarea {
  height: auto;
  min-height: 88px;
  padding: 10px 12px;
  resize: vertical;
}

.ox-input:focus,
.ox-select:focus,
.ox-textarea:focus,
.ax-sys-shell input:focus,
.ax-sys-shell select:focus,
.ax-sys-shell textarea:focus {
  outline: none;
  border-color: var(--ox-brand-cyan);
  box-shadow: var(--ox-focus-ring);
}

.ox-checkbox {
  width: 16px;
  height: 16px;
  accent-color: var(--ox-brand-cyan);
}

.ox-toggle {
  appearance: none;
  width: 36px;
  height: 20px;
  border-radius: 999px;
  background: var(--ox-border);
  border: 0;
  position: relative;
  cursor: pointer;
}

.ox-toggle::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.12s;
}

.ox-toggle:checked {
  background: var(--ox-brand-cyan);
}

.ox-toggle:checked::after {
  transform: translateX(16px);
}

/* ── Drawer ── */

.ox-drawer-overlay,
.pd-drawer-overlay {
  position: fixed;
  inset: 0;
  z-index: 9000;
  display: flex;
  justify-content: flex-end;
}

.ox-drawer-overlay[hidden],
.pd-drawer-overlay[hidden] {
  display: none !important;
}

.ox-drawer-overlay::before,
.pd-drawer-scrim {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.36);
  content: "";
}

.ox-drawer,
.pd-drawer {
  position: relative;
  z-index: 1;
  width: min(var(--ox-drawer-width), 100vw);
  max-width: 100%;
  height: 100%;
  background: var(--ox-surface);
  border-left: 1px solid var(--ox-border);
  display: flex;
  flex-direction: column;
  box-shadow: var(--ox-shadow-md);
}

.ox-drawer__header,
.pd-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--ox-space-3);
  min-height: 56px;
  padding: 0 var(--ox-space-5);
  border-bottom: 1px solid var(--ox-border);
}

.ox-drawer__body,
.pd-drawer-body {
  flex: 1;
  overflow: auto;
  padding: var(--ox-space-5);
}

.ox-drawer__footer,
.pd-drawer-foot {
  display: flex;
  justify-content: flex-end;
  gap: var(--ox-space-2);
  padding: var(--ox-space-4) var(--ox-space-5);
  border-top: 1px solid var(--ox-border);
  background: var(--ox-surface);
}

/* ── Modal ── */

.ox-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal, 5000);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--ox-space-5);
  background: rgba(15, 23, 42, 0.4);
}

.ox-modal {
  width: 100%;
  max-width: var(--ox-modal-md);
  max-height: min(86vh, 820px);
  overflow: auto;
  background: var(--ox-surface);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-lg);
  box-shadow: var(--ox-shadow-md);
}

.ox-modal--sm { max-width: var(--ox-modal-sm); }
.ox-modal--md { max-width: var(--ox-modal-md); }
.ox-modal--lg { max-width: var(--ox-modal-lg); }

:is(.ox-page-shell, .ax-sys-shell) .um-modal-box,
:is(.ox-page-shell, .ax-sys-shell) .su-modal-dialog {
  border-radius: var(--ox-radius-lg) !important;
}

/* ── Typography helpers ── */

.ox-section-title {
  margin: 0;
  font-size: var(--ox-font-section);
  font-weight: 700;
  color: var(--ox-text-primary);
}

.ox-caption {
  font-size: var(--ox-font-caption);
  color: var(--ox-text-muted);
}

/* ── Footer: no extra page margins ── */

:is(.ox-page-shell, .ax-sys-shell) .subs-footer,
.personen-page .subs-footer {
  margin-bottom: 0;
}

/* ── Priority page canvas lock ── */

main.content:has(.ox-page-shell),
main.content:has(.ax-sys-shell),
main.content:has(.pd-page),
main.content:has(.ax-dashboard),
.content:has(.ox-page-shell),
.content:has(.ax-sys-shell),
.content:has(.pd-page),
.content:has(.ax-dashboard),
#pageContent:has(.ox-page-shell),
#pageContent:has(.ax-sys-shell),
#pageContent:has(.pd-page),
.system-updates-page,
.audit-page,
.um-page,
.personen-page,
.integrations-page,
.security-page,
.pd-page,
.ax-dashboard,
.vms-page,
.settings-hub-page,
.settings-detail-page,
.live-events-page,
.sa-page,
.rp-page {
  background: var(--ox-page-bg) !important;
  background-image: none !important;
}

.ax-sys-shell.integrations-page {
  padding: 0 0 var(--ox-space-4) !important;
}

.audit-page.subs-page {
  background: var(--ox-page-bg) !important;
}

.pd-page {
  padding: 0 0 var(--ox-space-4);
  gap: var(--ox-space-4);
}

/* Dashboard header is a toolbar, not a heavy card */
.ax-dashboard .dg-header-bar.ax-card {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  padding: 0 !important;
  border-radius: 0 !important;
}

.dg-customize-btn {
  width: var(--ox-control-height) !important;
  min-width: var(--ox-control-height) !important;
  height: var(--ox-control-height) !important;
  padding: 0 !important;
  border-radius: var(--ox-radius-sm) !important;
  border: 1px solid var(--ox-border) !important;
  background: var(--ox-surface) !important;
  color: var(--ox-text-secondary) !important;
  box-shadow: var(--ox-shadow-sm) !important;
  filter: none !important;
}

.dg-customize-btn:hover {
  background: var(--ox-surface-soft) !important;
  color: var(--ox-text-primary) !important;
  filter: none !important;
}

.dg-tile-body,
.dg-stat-card {
  border-radius: var(--ox-radius-md) !important;
  border: 1px solid var(--ox-border) !important;
  box-shadow: var(--ox-shadow-sm) !important;
  background: var(--ox-surface) !important;
  background-image: none !important;
}

.dg-layout:not(.dg-layout--edit) .dg-stat-card:hover {
  transform: none !important;
  box-shadow: var(--ox-shadow-sm) !important;
}

.pd-page {
  --pd-gap: var(--ox-space-4);
  --pd-card-gap: var(--ox-space-4);
  --pd-card-pad-x: var(--ox-space-4);
  --pd-card-pad-y: var(--ox-space-3);
  --pd-sticky-bg: var(--ox-page-bg);
  margin-top: 0;
  padding: 0 0 var(--ox-space-4);
  gap: var(--ox-space-4);
}

.pd-header-name,
.pd-header-title {
  font-size: var(--ox-font-title) !important;
}

.pd-form-btn-primary {
  background: var(--ox-primary) !important;
  border-color: var(--ox-primary) !important;
  color: #fff !important;
}

.audit-page .audit-export-actions .subs-btn {
  height: var(--ox-control-height) !important;
  font-size: var(--ox-control-font) !important;
  border-radius: var(--ox-radius-sm) !important;
}

.su-release-list,
#releaseRemoteList,
.su-update-center .su-adv-list {
  max-height: none !important;
  overflow: visible !important;
}

.personen-page:is(.ox-page-shell, .ax-sys-shell) .subs-actions .subs-btn,
.personen-page:is(.ox-page-shell, .ax-sys-shell) .subs-actions .add-btn {
  min-height: var(--ox-control-height) !important;
  height: var(--ox-control-height) !important;
  border-radius: var(--ox-radius-sm) !important;
  font-size: var(--ox-control-font) !important;
}

.personen-stat-card {
  border-radius: var(--ox-radius-md) !important;
  border: 1px solid var(--ox-border) !important;
  box-shadow: var(--ox-shadow-sm) !important;
}

/* Family pages that are not yet tagged ox-page-shell */
.pin-page,
.pin-page-modern,
.devtree-page,
.rv-page,
.io-page,
.anpr-page,
.controllers-page,
.card-readers-page,
.gate-page {
  background: var(--ox-page-bg) !important;
  background-image: none !important;
}

.vms-page {
  --vms-bg: var(--ox-page-bg);
  --vms-panel: var(--ox-surface);
  --vms-panel-2: var(--ox-surface-soft);
  --vms-border: var(--ox-border);
  --vms-text: var(--ox-text-primary);
  --vms-muted: var(--ox-text-muted);
  min-height: 0;
  padding: 0 0 var(--ox-space-4) !important;
}

.vms-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--ox-space-4);
  margin: 0 0 var(--ox-space-4) !important;
}

.vms-header h1 {
  font-size: var(--ox-font-title) !important;
  font-weight: 700 !important;
  color: var(--ox-text-primary) !important;
}

.vms-header p {
  font-size: var(--ox-font-secondary) !important;
  color: var(--ox-text-muted) !important;
}

.vms-btn {
  height: var(--ox-control-height) !important;
  min-height: var(--ox-control-height) !important;
  border-radius: var(--ox-radius-sm) !important;
  font-size: var(--ox-control-font) !important;
  font-weight: 600 !important;
  background: var(--ox-surface) !important;
  color: var(--ox-text-secondary) !important;
  border: 1px solid var(--ox-border) !important;
}

.case-btn-primary,
.ox-page-shell .case-btn-primary {
  height: var(--ox-control-height) !important;
  min-height: var(--ox-control-height) !important;
  padding: 0 12px !important;
  border-radius: var(--ox-radius-sm) !important;
  border: 1px solid var(--ox-success) !important;
  background: var(--ox-success) !important;
  color: #fff !important;
  font-size: var(--ox-control-font) !important;
  font-weight: 600 !important;
  box-shadow: var(--ox-shadow-sm) !important;
}

.vms-btn-primary {
  background: var(--ox-success) !important;
  border-color: var(--ox-success) !important;
  color: #fff !important;
}

.vms-stat,
.vms-panel {
  border-radius: var(--ox-radius-md) !important;
  border: 1px solid var(--ox-border) !important;
  box-shadow: var(--ox-shadow-sm) !important;
  background: var(--ox-surface) !important;
}

.settings-hub-page {
  padding: 0 0 var(--ox-space-4) !important;
}

.settings-hub-title,
.settings-detail-page .page-title,
.live-events-page .page-title {
  font-size: var(--ox-font-title) !important;
  font-weight: 700 !important;
  color: var(--ox-text-primary) !important;
}

.settings-hub-title {
  letter-spacing: -0.02em !important;
}

.settings-detail-page .page-subtitle,
.live-events-page .page-subtitle,
.settings-hub-page p,
.subs-page .page-subtitle,
.ax-page .page-subtitle {
  font-size: var(--ox-font-secondary) !important;
  color: var(--ox-text-muted) !important;
}

.subs-page .page-title,
.ax-page .page-title,
.settings-detail-header h1 {
  font-size: var(--ox-font-title) !important;
  font-weight: 700 !important;
  color: var(--ox-text-primary) !important;
  letter-spacing: -0.02em !important;
}

.settings-detail-card,
.settings-hub-grid .settings-hub-card,
.settings-hub-grid a {
  border-radius: var(--ox-radius-md);
}

.time-reg-kpi-card,
.pin-card,
.tv-card,
.kp-card,
.tarief-list-panel.subs-table-card,
.tarief-detail-panel {
  border-radius: var(--ox-radius-md) !important;
  border: 1px solid var(--ox-border) !important;
  box-shadow: var(--ox-shadow-sm) !important;
  background: var(--ox-surface) !important;
  background-image: none !important;
}

.time-reg-kpi-card.is-accent {
  background: var(--ox-surface) !important;
  color: var(--ox-text-primary) !important;
  border-color: var(--ox-border) !important;
}

.time-reg-kpi-card.is-accent .time-reg-kpi-label,
.time-reg-kpi-card.is-accent .time-reg-kpi-hint {
  color: var(--ox-text-muted) !important;
}

.time-reg-kpi-card.is-accent .time-reg-kpi-value {
  color: var(--ox-text-primary) !important;
}

.pin-page .pin-btn,
.pin-page-modern .pin-btn {
  height: var(--ox-control-height) !important;
  min-height: var(--ox-control-height) !important;
  padding: 0 12px !important;
  border-radius: var(--ox-radius-sm) !important;
  font-size: var(--ox-control-font) !important;
  font-weight: 600 !important;
}

.pin-page .pin-btn-primary,
.pin-page-modern .pin-btn-primary {
  background: var(--ox-primary) !important;
  border-color: var(--ox-primary) !important;
  color: #fff !important;
}

.tickets-page {
  --tv-bg: var(--ox-page-bg);
  --tv-card: var(--ox-surface);
  --tv-soft: var(--ox-surface-soft);
  --tv-text: var(--ox-text-primary);
  --tv-muted: var(--ox-text-muted);
  --tv-border: var(--ox-border);
  --tv-primary: var(--ox-primary);
  --tv-primary-dark: var(--ox-primary-hover);
  --tv-green: var(--ox-success);
  padding: 0 0 var(--ox-space-4) !important;
}

.tickets-page .tv-header h1 {
  font-size: var(--ox-font-title) !important;
  font-weight: 700 !important;
  color: var(--ox-text-primary) !important;
}

.tickets-page .tv-tab.active {
  color: var(--ox-text-primary) !important;
}

.tickets-page .tv-tab.active:after {
  background: var(--ox-brand-cyan) !important;
  height: 2px !important;
  border-radius: 0 !important;
}

.translation-page .translation-actions .subs-btn,
.translation-page .translation-actions .primary-btn,
.tarieven-page .subs-actions .subs-btn {
  min-height: var(--ox-control-height) !important;
  height: var(--ox-control-height) !important;
  font-size: var(--ox-control-font) !important;
}

/* ── Responsive ── */

@media (max-width: 1100px) {
  :root {
    --ox-page-padding-x: 16px;
  }

  :is(.ox-page-shell, .ax-sys-shell) .sa-stat-strip,
  :is(.ox-page-shell, .ax-sys-shell) .um-stat-strip,
  :is(.ox-page-shell, .ax-sys-shell) .rp-stat-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  :root {
    --ox-page-padding-x: 16px;
    --ox-font-title: 18px;
  }

  .ox-page-header,
  :is(.ox-page-shell, .ax-sys-shell) .su-header,
  :is(.ox-page-shell, .ax-sys-shell) .um-header,
  :is(.ox-page-shell, .ax-sys-shell) .audit-top,
  .personen-page .subs-top {
    flex-direction: column;
    align-items: stretch;
  }

  .ox-page-header__actions,
  :is(.ox-page-shell, .ax-sys-shell) .su-actions,
  :is(.ox-page-shell, .ax-sys-shell) .um-header-actions,
  :is(.ox-page-shell, .ax-sys-shell) .subs-actions {
    width: 100%;
  }
}

/* ── Chrome: header, footer, dashboard, scrollbars ── */

html {
  scrollbar-width: thin;
  scrollbar-color: var(--ox-border-strong) transparent;
}

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: var(--ox-border-strong);
  border-radius: 999px;
}

html[data-theme="dark"] {
  scrollbar-color: #2A3C49 transparent;
}

html[data-theme="dark"] ::-webkit-scrollbar-thumb {
  background: #2A3C49;
}

.top-header {
  height: var(--header-height, 64px);
  background: rgba(255, 255, 255, 0.96) !important;
  border-bottom: 1px solid #E7ECF1 !important;
  box-shadow: none !important;
  backdrop-filter: none;
}

html[data-theme="dark"] .top-header {
  padding: 0 28px;
  background: linear-gradient(
    180deg,
    rgba(22, 32, 44, 0.98) 0%,
    rgba(13, 20, 30, 0.96) 100%
  ) !important;
  border-bottom-color: rgba(255, 255, 255, 0.08) !important;
}

html[data-theme="dark"] .top-actions {
  gap: 10px;
}

.top-search {
  height: 42px !important;
  width: min(520px, 46vw) !important;
  border-radius: 12px !important;
  border: 1px solid #DCE3EA !important;
  background: #FFFFFF !important;
  box-shadow: none !important;
}

.top-search:focus-within {
  border-color: var(--ox-brand-cyan) !important;
  box-shadow: var(--ox-focus-ring) !important;
}

html[data-theme="dark"] .top-search {
  background: rgba(19, 32, 43, 0.88) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04) !important;
}

html[data-theme="dark"] .top-search:focus-within {
  background: rgba(19, 32, 43, 0.98) !important;
  border-color: rgba(0, 169, 196, 0.42) !important;
}

html[data-theme="dark"] .top-header .top-search input,
html[data-theme="dark"] .top-search input {
  color: var(--ox-text-primary) !important;
}

html[data-theme="dark"] .top-header .top-search input::placeholder,
html[data-theme="dark"] .top-search input::placeholder {
  color: var(--ox-text-muted) !important;
}

html[data-theme="dark"] .search-icon {
  opacity: 0.72;
}

html[data-theme="dark"] .search-icon img {
  filter: invert(1) brightness(1.35);
}

.header-icon-btn,
.language-button,
.header-sidebar-toggle {
  height: 40px !important;
  min-height: 40px !important;
  border-radius: 10px !important;
  border: 1px solid var(--ox-border) !important;
  background: var(--ox-surface) !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  color: var(--ox-text-secondary) !important;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.header-icon-btn {
  width: 40px !important;
}

.header-icon-btn:hover,
.language-button:hover,
.header-sidebar-toggle:hover {
  background: #F8FAFC !important;
  border-color: var(--ox-border-strong) !important;
  color: var(--ox-text-primary) !important;
}

html[data-theme="dark"] .header-icon-btn:not(.is-ok):not(.has-notifications):not(.is-sound-muted),
html[data-theme="dark"] .language-button,
html[data-theme="dark"] .header-sidebar-toggle {
  background: rgba(19, 32, 43, 0.72) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  color: var(--ox-text-secondary) !important;
}

html[data-theme="dark"] .header-icon-btn:not(.is-ok):not(.has-notifications):not(.is-sound-muted):hover,
html[data-theme="dark"] .language-button:hover,
html[data-theme="dark"] .header-sidebar-toggle:hover {
  background: rgba(255, 255, 255, 0.06) !important;
  border-color: rgba(255, 255, 255, 0.14) !important;
  color: var(--ox-text-primary) !important;
}

html[data-theme="dark"] .header-ask-btn {
  color: #5eead4 !important;
  border-color: rgba(0, 169, 196, 0.28) !important;
  background: var(--ox-brand-cyan-soft) !important;
}

html[data-theme="dark"] .header-ask-btn:hover,
html[data-theme="dark"] .header-ask-btn[aria-expanded="true"] {
  color: #99f6e4 !important;
  border-color: rgba(0, 169, 196, 0.45) !important;
  background: #163844 !important;
}

html[data-theme="dark"] .header-divider {
  background: rgba(255, 255, 255, 0.08) !important;
}

.header-icon-btn:focus-visible,
.language-button:focus-visible,
.header-sidebar-toggle:focus-visible,
.top-search:focus-within,
.ox-btn:focus-visible,
.ox-input:focus-visible {
  outline: none;
  box-shadow: var(--ox-focus-ring-strong);
}

.header-ask-btn {
  color: var(--ox-brand-cyan-text) !important;
  border-color: #B8E4EB !important;
  background: var(--ox-brand-cyan-soft) !important;
}

.header-notify-badge,
.badge {
  min-width: 16px !important;
  height: 16px !important;
  padding: 0 4px !important;
  border-radius: 999px !important;
  color: #fff !important;
  font-size: 10px !important;
  font-weight: 700 !important;
  box-shadow: none !important;
  border: 2px solid #fff !important;
}

.badge {
  background: var(--ox-danger) !important;
}

/* Header alarm bell — traffic light by highest severity.
   Generic .header-icon-btn chrome is flattened (grey + always-red badge);
   these states restore green / orange / red without touching the compact update chip. */
.header-icon-btn.is-ok,
.header-icon-btn.is-ok:hover {
  color: #15803d !important;
  border-color: var(--ox-success-border) !important;
  background: var(--ox-success-bg) !important;
}

.header-icon-btn.has-notifications,
.header-icon-btn.has-notifications:hover {
  color: #b45309 !important;
  border-color: var(--ox-warning-border) !important;
  background: var(--ox-warning-bg) !important;
}

.header-icon-btn.has-notifications.is-critical,
.header-icon-btn.has-notifications.is-critical:hover {
  color: #b91c1c !important;
  border-color: var(--ox-danger-border) !important;
  background: var(--ox-danger-bg) !important;
}

.header-icon-btn.is-ok svg,
.header-icon-btn.has-notifications svg,
.header-icon-btn.has-notifications.is-critical svg,
.header-icon-btn.is-ok:hover svg,
.header-icon-btn.has-notifications:hover svg,
.header-icon-btn.has-notifications.is-critical:hover svg {
  color: inherit !important;
}

.header-notify-badge {
  background: var(--ox-warning) !important;
  box-shadow: 0 2px 6px rgba(245, 158, 11, 0.25) !important;
}

.header-notify-badge.is-critical {
  background: var(--ox-danger) !important;
  box-shadow: 0 2px 8px rgba(229, 72, 77, 0.35) !important;
}

.header-icon-btn.is-sound-muted,
.header-icon-btn.is-sound-muted:hover,
.header-icon-btn.is-sound-muted.has-notifications,
.header-icon-btn.is-sound-muted.has-notifications.is-critical,
.header-icon-btn.is-sound-muted.is-ok {
  color: #b91c1c !important;
  border-color: var(--ox-danger-border) !important;
  background: var(--ox-danger-bg) !important;
}

.header-icon-btn.is-sound-muted svg,
.header-icon-btn.is-sound-muted:hover svg {
  color: inherit !important;
}

html[data-theme="dark"] .header-icon-btn.is-ok,
html[data-theme="dark"] .header-icon-btn.is-ok:hover {
  color: #6ee7b7 !important;
}

html[data-theme="dark"] .header-icon-btn.has-notifications,
html[data-theme="dark"] .header-icon-btn.has-notifications:hover {
  color: #fbbf24 !important;
}

html[data-theme="dark"] .header-icon-btn.has-notifications.is-critical,
html[data-theme="dark"] .header-icon-btn.has-notifications.is-critical:hover,
html[data-theme="dark"] .header-icon-btn.is-sound-muted,
html[data-theme="dark"] .header-icon-btn.is-sound-muted:hover {
  color: #fca5a5 !important;
}

html[data-theme="dark"] .header-notify-badge,
html[data-theme="dark"] .badge {
  border-color: var(--ox-surface) !important;
}

html[data-theme="dark"] .header-alarm-sound-btn {
  background: rgba(255, 255, 255, 0.04) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  color: var(--ox-text-secondary) !important;
}

html[data-theme="dark"] .header-alarm-sound-btn:hover {
  background: rgba(255, 255, 255, 0.08) !important;
  border-color: rgba(255, 255, 255, 0.14) !important;
  color: var(--ox-text-primary) !important;
}

html[data-theme="dark"] .header-ask-form textarea {
  background: rgba(9, 17, 26, 0.9) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  color: var(--ox-text-primary) !important;
}

html[data-theme="dark"] .header-ask-chip {
  background: rgba(255, 255, 255, 0.04) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  color: var(--ox-text-secondary) !important;
}

html[data-theme="dark"] .header-ask-chip:hover {
  background: rgba(255, 255, 255, 0.08) !important;
  color: var(--ox-text-primary) !important;
}

.profile-menu {
  height: 40px !important;
  min-height: 40px !important;
  min-width: 0 !important;
  padding: 2px 8px 2px 2px !important;
  border-radius: 10px !important;
  border: 1px solid var(--ox-border) !important;
  background: var(--ox-surface) !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  gap: 8px !important;
}

.profile-menu:hover {
  background: #F8FAFC !important;
  border-color: var(--ox-border-strong) !important;
}

html[data-theme="dark"] .profile-menu {
  background: rgba(19, 32, 43, 0.72) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}

html[data-theme="dark"] .profile-menu:hover,
html[data-theme="dark"] .profile-menu.open {
  background: rgba(255, 255, 255, 0.06) !important;
  border-color: rgba(255, 255, 255, 0.14) !important;
}

html[data-theme="dark"] .profile-text strong {
  color: var(--ox-text-primary) !important;
}

html[data-theme="dark"] .profile-text span,
html[data-theme="dark"] .profile-arrow {
  color: var(--ox-text-secondary) !important;
}

html[data-theme="dark"] .profile-menu.open .profile-arrow,
html[data-theme="dark"] .profile-menu:has(.profile-dropdown.show) .profile-arrow {
  color: var(--ox-text-primary) !important;
}

.profile-avatar {
  width: 28px !important;
  height: 28px !important;
  min-width: 28px !important;
  border-radius: 8px !important;
  font-size: 12px !important;
  font-weight: 650 !important;
  background: var(--ox-sidebar-bg) !important;
  box-shadow: none !important;
}

.profile-dropdown,
.header-notify-popup,
.header-help-popup,
.header-ask-popup,
.language-menu {
  border-radius: 12px !important;
  border: 1px solid var(--ox-border) !important;
  background: var(--ox-surface) !important;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.10) !important;
}

.profile-dropdown {
  min-width: 260px;
  padding: 12px !important;
}

.profile-dropdown.is-portaled {
  position: fixed !important;
  z-index: 4000 !important;
  margin: 0;
}

html[data-theme="dark"] .profile-dropdown,
html[data-theme="dark"] .header-notify-popup,
html[data-theme="dark"] .header-help-popup,
html[data-theme="dark"] .header-ask-popup,
html[data-theme="dark"] .language-menu {
  background: var(--ox-surface-elevated) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45) !important;
}

html[data-theme="dark"] .profile-dropdown::before {
  display: none;
}

html[data-theme="dark"] .profile-role-badge {
  color: var(--ox-text-secondary) !important;
  background: rgba(255, 255, 255, 0.06) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}

html[data-theme="dark"] .profile-dropdown-head strong,
html[data-theme="dark"] .profile-dropdown-title,
html[data-theme="dark"] .header-notify-head strong,
html[data-theme="dark"] .header-help-head strong,
html[data-theme="dark"] .header-notify-copy strong,
html[data-theme="dark"] .header-help-contact a,
html[data-theme="dark"] .header-help-version-row strong {
  color: var(--ox-text-primary) !important;
}

html[data-theme="dark"] .profile-dropdown-hint,
html[data-theme="dark"] .appearance-label,
html[data-theme="dark"] .header-help-text,
html[data-theme="dark"] .header-help-qr-text,
html[data-theme="dark"] .header-help-contact span,
html[data-theme="dark"] .header-help-version-row span {
  color: var(--ox-text-secondary) !important;
}

html[data-theme="dark"] .profile-dropdown-divider,
html[data-theme="dark"] .header-help-versions-divider {
  background: rgba(255, 255, 255, 0.08) !important;
}

html[data-theme="dark"] .appearance-select {
  background: rgba(19, 32, 43, 0.92) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  color: var(--ox-text-primary) !important;
}

html[data-theme="dark"] .appearance-select:hover,
html[data-theme="dark"] .appearance-select:focus {
  background: rgba(255, 255, 255, 0.06) !important;
  border-color: rgba(255, 255, 255, 0.14) !important;
}

html[data-theme="dark"] .appearance-select-wrap::after {
  border-right-color: var(--ox-text-secondary);
  border-bottom-color: var(--ox-text-secondary);
}

html[data-theme="dark"] .profile-dropdown button,
html[data-theme="dark"] .profile-dropdown-item {
  background: transparent !important;
  color: var(--ox-text-primary) !important;
}

html[data-theme="dark"] .profile-dropdown-item:hover {
  background: rgba(255, 255, 255, 0.06) !important;
}

html[data-theme="dark"] .profile-dropdown-icon--security {
  color: var(--ox-text-primary) !important;
  background: rgba(255, 255, 255, 0.05) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}

html[data-theme="dark"] .profile-dropdown-icon--logout {
  color: #fca5a5 !important;
  background: rgba(229, 72, 77, 0.12) !important;
  border-color: rgba(229, 72, 77, 0.22) !important;
}

html[data-theme="dark"] .profile-dropdown-item--logout .profile-dropdown-title {
  color: #fca5a5 !important;
}

html[data-theme="dark"] .profile-dropdown-item--logout .profile-dropdown-hint {
  color: #f87171 !important;
}

html[data-theme="dark"] .profile-dropdown-item--logout:hover {
  background: rgba(229, 72, 77, 0.12) !important;
  border-color: rgba(229, 72, 77, 0.22) !important;
}

html[data-theme="dark"] .header-notify-empty,
html[data-theme="dark"] .header-help-qr,
html[data-theme="dark"] .header-help-contact,
html[data-theme="dark"] .header-help-versions {
  background: rgba(255, 255, 255, 0.04) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  color: var(--ox-text-secondary) !important;
}

html[data-theme="dark"] .header-notify-item {
  background: rgba(16, 26, 36, 0.72) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}

html[data-theme="dark"] .header-notify-item.is-clickable:hover {
  background: rgba(255, 255, 255, 0.05) !important;
  border-color: rgba(255, 255, 255, 0.14) !important;
}

html[data-theme="dark"] .header-notify-icon {
  background: rgba(255, 255, 255, 0.06) !important;
}

html[data-theme="dark"] .language-menu-list > button {
  background: transparent !important;
  color: var(--ox-text-primary) !important;
}

html[data-theme="dark"] .language-menu-list > button:hover {
  background: rgba(255, 255, 255, 0.06) !important;
}

.language-menu-list > button:hover,
.profile-dropdown-item:hover {
  background: var(--ox-surface-soft) !important;
}

.appearance-select option:checked,
.language-menu-list > button.is-active {
  background: var(--ox-brand-cyan-selected) !important;
  color: var(--ox-brand-cyan-text) !important;
}

.system-footer,
.ax-footer {
  background: var(--ox-surface) !important;
  border-top: 1px solid var(--ox-border) !important;
  box-shadow: none !important;
}

html[data-theme="dark"] .system-footer,
html[data-theme="dark"] .ax-footer {
  background: linear-gradient(
    180deg,
    rgba(13, 20, 30, 0.96) 0%,
    rgba(9, 17, 26, 0.98) 100%
  ) !important;
  border-top-color: rgba(255, 255, 255, 0.08) !important;
}

html[data-theme="dark"] .ax-footer-health-card,
html[data-theme="dark"] .ax-footer-intercom-card {
  background: rgba(19, 32, 43, 0.72) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
  color: var(--ox-text-secondary) !important;
}

html[data-theme="dark"] .ax-footer-health-card:hover,
html[data-theme="dark"] .ax-footer-intercom-card:hover {
  background: rgba(255, 255, 255, 0.06) !important;
  border-color: rgba(255, 255, 255, 0.14) !important;
}

html[data-theme="dark"] .ax-footer-label,
html[data-theme="dark"] .ax-footer-meta-label {
  color: var(--ox-text-muted) !important;
  font-size: 10px !important;
  letter-spacing: 0.08em !important;
  font-weight: 650 !important;
}

html[data-theme="dark"] .ax-footer-value,
html[data-theme="dark"] .ax-footer-meta-value {
  color: var(--ox-text-primary) !important;
  font-size: 12px !important;
  font-weight: 700 !important;
}

html[data-theme="dark"] .ax-footer-meta {
  justify-content: flex-end !important;
  background: transparent !important;
  border-color: transparent !important;
  padding: 0 !important;
}

html[data-theme="dark"] .ax-footer-meta-divider {
  background: rgba(255, 255, 255, 0.10) !important;
}

html[data-theme="dark"] .ax-footer-dot.is-ok {
  background: #22c55e !important;
  box-shadow:
    0 0 0 3px rgba(34, 197, 94, 0.18),
    0 0 12px rgba(34, 197, 94, 0.55) !important;
}

html[data-theme="dark"] .ax-footer-dot.is-warn {
  box-shadow:
    0 0 0 3px rgba(245, 158, 11, 0.18),
    0 0 12px rgba(245, 158, 11, 0.45) !important;
}

html[data-theme="dark"] .ax-footer-dot.is-danger {
  box-shadow:
    0 0 0 3px rgba(239, 68, 68, 0.18),
    0 0 12px rgba(239, 68, 68, 0.45) !important;
}

html[data-theme="dark"] .ax-footer-powered-label {
  color: var(--ox-text-muted) !important;
}

html[data-theme="dark"] .ax-footer-powered {
  background: transparent !important;
}

.ax-footer-health-card.is-online {
  background: var(--ox-success-bg) !important;
  border: 1px solid var(--ox-success-border) !important;
  box-shadow: none !important;
}

.ax-footer-health-card.is-online .ax-footer-value {
  color: #087A4B !important;
}

html[data-theme="dark"] .ax-footer-health-card.is-online {
  background: var(--ox-success-bg) !important;
  border-color: var(--ox-success-border) !important;
  box-shadow: 0 0 18px rgba(34, 197, 94, 0.14) !important;
}

html[data-theme="dark"] .ax-footer-health-card.is-online .ax-footer-value {
  color: #6EE7B7 !important;
}

.ax-footer-powered-logo {
  height: 22px !important;
  max-width: 160px !important;
  opacity: 0.85;
}

.dg-tile-body,
.dg-stat-card,
.ax-dashboard .card,
.quick-action-tile,
.ax-dashboard .stat-card,
.ox-card {
  background: var(--ox-card-bg, var(--ox-surface)) !important;
  border: 1px solid var(--ox-border) !important;
  border-radius: 14px !important;
  box-shadow: var(--ox-shadow-card) !important;
}

.ax-dashboard .page-title,
.dashboard-greeting-wrap h1,
.dashboard-detail-header .page-title {
  font-size: 21px !important;
  font-weight: 650 !important;
  color: #0F172A !important;
  letter-spacing: -0.02em !important;
}

html[data-theme="dark"] .ax-dashboard .page-title,
html[data-theme="dark"] .dashboard-greeting-wrap h1 {
  color: var(--ox-text-primary) !important;
}

.dg-stat-card__glow {
  opacity: 0.22 !important;
}

/* N1 Dashboard KPI tiles: compact, token colours, label wraps (max 2 lines) instead of running out of the card. */
.dg-stat-card {
  gap: var(--ox-space-2);
  padding: var(--ox-space-3) var(--ox-space-4);
}

.dg-stat-card__head {
  align-items: flex-start;
  gap: var(--ox-space-2);
}

.dg-stat-card__icon {
  width: 32px;
  height: 32px;
  border-radius: var(--ox-radius-sm);
}

.dg-stat-card__icon svg {
  width: var(--ox-icon-size);
  height: var(--ox-icon-size);
}

html:root .dg-stat-card small {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  min-width: 0;
  padding-top: 1px;
  color: var(--ox-text-secondary);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.3;
  /* N1.1: break only between words; a word is split only if it cannot fit on a line of its own (was "anywhere"). */
  overflow-wrap: break-word;
  word-break: normal;
  hyphens: manual;
}

/* N1.1 Dashboard KPI tiles: in a narrow tile (e.g. the minimum 3 of 24 grid columns, < 130px content) the decorative
   icon is left out, so the label gets the full tile width instead of the space next to the icon (64px broke "HARDWARE"
   mid-word) and the tile keeps its height. Wider tiles keep icon + label side by side. */
.dg-stat-card {
  container-type: inline-size;
  container-name: dg-stat;
}

@container dg-stat (max-width: 129.98px) {
  .dg-stat-card__icon {
    display: none;
  }

  html:root .dg-stat-card small {
    padding-top: 0;
  }
}

html:root .dg-stat-card h2 {
  margin: 0 0 2px;
  color: var(--ox-text-primary);
  font-size: clamp(22px, 2vw, 28px);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

html:root .dg-stat-card__sub,
html:root .dg-stat-card .stat-sub {
  color: var(--ox-text-muted);
  font-size: var(--ox-font-secondary);
  font-weight: 500;
}

.dg-stat-card h2.is-unknown {
  color: var(--ox-text-muted);
}

/* N1 Dashboard panels: "Bekijk alle" uses the brand accent in both themes (was navy in light, blue in dark). */
html:root .dg-panel-card .card-header > a {
  color: var(--ox-brand-cyan);
  font-size: var(--ox-font-body);
  font-weight: 600;
}

html:root .dg-panel-card .card-header > a:hover {
  text-decoration: underline;
}

/* N1 live events: events from an earlier day show their date under the time. */
/* N1 camera tile: without a picture (loading, no camera, error) the frame is a calm neutral surface with
   icon + text instead of a large black box; a live picture keeps the dark video frame. */
html:root .dg-camera-frame:has(> .dg-camera-empty) {
  background: var(--ox-surface-soft) !important;
  border: 1px dashed var(--ox-border);
}

html:root .dg-camera-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--ox-space-2);
  padding: var(--ox-space-4);
  color: var(--ox-text-secondary) !important;
  font-size: var(--ox-font-body);
  text-align: center;
}

.dg-camera-empty svg {
  width: 22px;
  height: 22px;
  color: var(--ox-text-muted);
}

.dashboard-live-date {
  display: block;
  margin-top: 1px;
  color: var(--ox-text-muted);
  font-size: 10px;
  font-weight: 500;
  line-height: 1.2;
  white-space: nowrap;
}

.dg-layout:not(.dg-layout--edit) .dg-stat-card:hover {
  transform: none !important;
  box-shadow: var(--ox-shadow-card) !important;
}

.quick-action-tile:hover {
  border-color: var(--ox-border-hover) !important;
  box-shadow: var(--ox-shadow-hover) !important;
  transform: translateY(-1px);
}

.dg-floorplan-toolbar,
.dg-camera-toolbar {
  padding: 0 12px 8px !important;
  gap: 8px !important;
}

.dg-floorplan-toolbar select,
.dg-camera-toolbar select,
.dg-floorplan-search input {
  height: 34px !important;
  border-radius: 9px !important;
  border: 1px solid var(--ox-border-input) !important;
}

.dg-floorplan-toolbar select:focus,
.dg-camera-toolbar select:focus,
.dg-floorplan-search input:focus {
  border-color: var(--ox-brand-cyan) !important;
  box-shadow: var(--ox-focus-ring) !important;
  outline: none;
}

.dg-camera-frame {
  background: #0B1320 !important;
  border-radius: 12px !important;
}

.dg-camera-empty {
  color: #94A3B8 !important;
  font-weight: 500 !important;
}

.dashboard-live-item {
  grid-template-columns: 8px 64px minmax(0, 1fr) !important;
  min-height: 36px !important;
  padding: 6px 4px !important;
  background: transparent !important;
  border-radius: 0 !important;
}

.dashboard-live-item::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ox-text-muted);
  align-self: center;
}

.dashboard-live-item.is-granted::before { background: var(--ox-success); }
.dashboard-live-item.is-denied::before { background: var(--ox-danger); }
.dashboard-live-item.is-warning::before { background: var(--ox-warning); }

.dashboard-live-item.is-granted,
.dashboard-live-item.is-denied,
.dashboard-live-item.is-warning {
  background: transparent !important;
}

.dashboard-live-item.is-denied {
  background: rgba(229, 72, 77, 0.04) !important;
}

.dashboard-live-item:hover,
.dashboard-live-item.is-granted:hover,
.dashboard-live-item.is-denied:hover,
.dashboard-live-item.is-warning:hover {
  background: #FAFCFD !important;
  filter: none !important;
}

.dashboard-live-type {
  font-weight: 600 !important;
  font-size: 13px !important;
}

.dg-tile-link {
  color: var(--ox-brand-cyan) !important;
  font-weight: 600 !important;
}

.page-modal-window,
.ox-modal {
  border-radius: 16px !important;
  background: var(--ox-surface) !important;
}

.ox-tooltip,
.tippy-box,
.tooltip {
  background: #101820 !important;
  color: #FFFFFF !important;
  border-radius: 8px !important;
  font-size: 12px !important;
  box-shadow: none !important;
}

@media (max-width: 1100px) {
  .top-search {
    width: min(360px, 38vw) !important;
  }
}

@media (max-width: 800px) {
  .top-search {
    width: min(220px, 32vw) !important;
  }
}

/* =========================================================
   Tree, split panel, property grid, field states
   Generic DS components (first used by Hardware → Config Wizard,
   OXLEON_CONFIG_WIZARD_F1_2026_09_30). Token-based; light + dark.
   ========================================================= */

.ox-stack {
  display: flex;
  flex-direction: column;
  gap: var(--ox-space-4);
  min-width: 0;
}

.ox-stack--tight {
  gap: var(--ox-space-2);
}

.ox-field-label--inline,
.ox-field-help--flush {
  margin: 0;
}

.ox-select--auto,
.ox-input--auto {
  width: auto;
  min-width: 240px;
  max-width: 100%;
}

.ox-mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
}

/* Read-only code/JSON block (scrolls in its own container) */
.ox-code-block {
  margin: 0;
  max-height: 420px;
  overflow: auto;
  padding: var(--ox-space-3);
  background: var(--ox-surface-soft);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-sm);
  color: var(--ox-text-primary);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  line-height: 1.5;
  white-space: pre;
  tab-size: 2;
}

/* ── Screen-reader only text ── */
.ox-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ── Dropdown menu (button + list) ── */
.ox-menu {
  position: relative;
  display: inline-flex;
}

.ox-menu__list {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  z-index: 60;
  min-width: 240px;
  padding: var(--ox-space-1);
  background: var(--ox-surface-elevated);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-md);
  box-shadow: var(--ox-shadow-md);
}

.ox-menu__list[hidden] {
  display: none;
}

.ox-menu__item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  padding: 8px 10px;
  border: 0;
  border-radius: var(--ox-radius-sm);
  background: transparent;
  color: var(--ox-text-primary);
  font: inherit;
  font-size: var(--ox-font-body);
  text-align: left;
  cursor: pointer;
}

.ox-menu__item:hover,
.ox-menu__item:focus-visible {
  background: var(--ox-surface-soft);
  outline: none;
}

.ox-menu__item small {
  color: var(--ox-text-muted);
  font-size: 12px;
}

/* ── Interactive table rows (row = selectable item) ── */
.ox-table--interactive tbody tr {
  cursor: pointer;
}

.ox-table--interactive tbody tr:focus-visible {
  outline: 2px solid var(--ox-brand-cyan);
  outline-offset: -2px;
}

.ox-nowrap {
  white-space: nowrap;
}

/* Opt-in: buttons/menus that are shown or hidden with the [hidden] attribute (.ox-btn sets display) */
.ox-btn--toggle[hidden],
.ox-menu[hidden] {
  display: none !important;
}

/* Toolbar search that grows but stays compact (filters stay on one line on desktop) */
.ox-toolbar .ox-toolbar__search {
  flex: 1 1 220px;
  width: auto !important;
  min-width: 200px;
  max-width: 360px;
}

/* Compact form (drawer/inline forms): DS control height; beats the legacy global input rules */
.ox-form--compact .ox-input,
.ox-form--compact .ox-select {
  height: var(--ox-control-height) !important;
  min-height: var(--ox-control-height) !important;
  padding: 0 10px !important;
  font-size: var(--ox-font-body) !important;
  line-height: 1.2 !important;
}

.ox-form--compact .ox-stack--tight {
  gap: 4px;
}

.ox-cell-sub {
  display: block;
  margin-top: 1px;
  color: var(--ox-text-muted);
  font-size: 12px;
  line-height: 1.35;
}

.ox-cell-stack {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
}

.ox-drawer .ox-tabs {
  padding: 0 var(--ox-space-5);
}

/* Tab bar that wraps instead of hiding tabs behind an invisible horizontal scroll (narrow drawers) */
.ox-tabs.ox-tabs--wrap {
  flex-wrap: wrap;
  overflow-x: visible;
  column-gap: 0;
}

/* ── Split panel (start pane | resizer | end pane) ── */

.ox-split {
  --ox-split-start: 280px;
  display: grid;
  grid-template-columns: var(--ox-split-start) 6px minmax(0, 1fr);
  min-height: 560px;
  background: var(--ox-surface);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-md);
  overflow: hidden;
}

.ox-split__pane {
  min-width: 0;
  min-height: 0;
  overflow: auto;
}

.ox-split__pane--start {
  background: var(--ox-surface-soft);
  border-right: 1px solid var(--ox-border);
}

.ox-split__pane--end {
  padding: var(--ox-space-4) var(--ox-space-5);
}

.ox-split__resizer {
  position: relative;
  margin-left: -1px;
  cursor: col-resize;
  background: transparent;
  touch-action: none;
}

.ox-split__resizer::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 2px;
  width: 2px;
  background: transparent;
  transition: background 0.12s ease;
}

.ox-split__resizer:hover::after,
.ox-split__resizer:focus-visible::after,
.ox-split.is-resizing .ox-split__resizer::after {
  background: var(--ox-brand-cyan);
}

.ox-split__resizer:focus-visible {
  outline: none;
}

.ox-split.is-resizing {
  user-select: none;
}

@media (max-width: 1100px) {
  .ox-split {
    grid-template-columns: minmax(0, 1fr);
  }
  .ox-split__resizer {
    display: none;
  }
  .ox-split__pane--start {
    max-height: 300px;
    border-right: 0;
    border-bottom: 1px solid var(--ox-border);
  }
  .ox-split__pane--end {
    padding: var(--ox-space-4);
  }
}

/* ── Tree ── */

.ox-tree,
.ox-tree [role="group"] {
  list-style: none;
  margin: 0;
  padding: 0;
}

.ox-tree {
  padding: var(--ox-space-1) 0 var(--ox-space-3);
  font-size: var(--ox-font-body);
}

.ox-tree__heading {
  padding: var(--ox-space-3) var(--ox-space-4) var(--ox-space-1);
  font-size: var(--ox-font-table-label);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ox-text-muted);
}

.ox-tree-item {
  display: flex;
  align-items: center;
  gap: var(--ox-space-2);
  min-height: 30px;
  padding: 0 var(--ox-space-3) 0 calc(var(--ox-space-3) + var(--ox-tree-level, 0) * 18px);
  border-left: 2px solid transparent;
  color: var(--ox-text-secondary);
  cursor: pointer;
  user-select: none;
}

.ox-tree-item:hover {
  background: var(--ox-surface);
  color: var(--ox-text-primary);
}

.ox-tree-item.is-selected,
.ox-tree-item[aria-selected="true"] {
  background: var(--ox-brand-cyan-selected);
  border-left-color: var(--ox-brand-cyan);
  color: var(--ox-text-primary);
  font-weight: 600;
}

.ox-tree-item:focus-visible {
  outline: none;
  box-shadow: inset var(--ox-focus-ring);
}

.ox-tree-item__toggle,
.ox-tree-item__spacer {
  flex: 0 0 16px;
  width: 16px;
  height: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--ox-text-muted);
}

.ox-tree-item__toggle svg {
  width: 14px;
  height: 14px;
  transition: transform 0.12s ease;
}

.ox-tree-item[aria-expanded="false"] .ox-tree-item__toggle svg {
  transform: rotate(-90deg);
}

.ox-tree-item[aria-expanded="false"] + [role="group"] {
  display: none;
}

.ox-tree-item__label {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ox-tree-item__meta {
  display: inline-flex;
  gap: var(--ox-space-1);
  margin-left: auto;
}

.ox-tree-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border: 1px solid var(--ox-border);
  border-radius: 999px;
  background: var(--ox-surface);
  color: var(--ox-text-muted);
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
}

.ox-tree-count--error {
  background: var(--ox-danger-bg);
  border-color: var(--ox-danger-border);
  color: var(--ox-danger);
}

.ox-tree-count--warning {
  background: var(--ox-warning-bg);
  border-color: var(--ox-warning-border);
  color: var(--ox-warning);
}

/* ── Property grid (label | value | source) ── */

.ox-property-grid {
  display: grid;
  grid-template-columns: minmax(150px, 32%) minmax(0, 1fr) auto;
  margin: 0;
  background: var(--ox-surface);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-md);
  overflow: hidden;
}

/* label | value only (no source column), e.g. in a drawer */
.ox-property-grid--2col {
  grid-template-columns: minmax(130px, 38%) minmax(0, 1fr);
}

.ox-property-grid > dt,
.ox-property-grid > dd {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 2px var(--ox-space-2);
  min-height: 34px;
  margin: 0;
  padding: 6px 12px;
  border-bottom: 1px solid var(--ox-border-soft);
  font-size: var(--ox-font-body);
  min-width: 0;
}

.ox-property-grid > dt {
  background: var(--ox-surface-soft);
  color: var(--ox-text-secondary);
  font-weight: 500;
}

.ox-property-grid > dd {
  color: var(--ox-text-primary);
  overflow-wrap: anywhere;
}

.ox-property-grid > dd.ox-property-grid__source {
  justify-content: flex-end;
}

.ox-property-grid__note {
  flex-basis: 100%;
  font-size: var(--ox-font-caption);
  color: var(--ox-text-muted);
}

.ox-property-grid__empty {
  color: var(--ox-text-muted);
}

/* ── Source chip ── */

.ox-source {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  padding: 1px 6px;
  border: 1px solid var(--ox-border-soft);
  border-radius: 6px;
  background: var(--ox-surface-soft);
  color: var(--ox-text-muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 10.5px;
  line-height: 1.5;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Technical tables (codes + source chips): long tokens wrap and source chips stay compact (full value in the
   title), so the table fits the detail pane at 1280–1366 instead of scrolling sideways. */
.ox-table--tech td .ox-mono {
  overflow-wrap: anywhere;
}

/* Tokens marked up with <wbr> after . and _ (N1 F20) wrap only at those separators, never mid-word. */
.ox-table--tech td .ox-mono--token {
  overflow-wrap: normal;
}

.ox-table--tech td .ox-source {
  max-width: 18ch;
}

/* ── Field / row states (never colour-only: pair with text or badge) ── */

.ox-field--warning,
.ox-table tr.ox-field--warning > td {
  background: var(--ox-warning-bg) !important;
}

.ox-field--error,
.ox-table tr.ox-field--error > td {
  background: var(--ox-danger-bg) !important;
}

.ox-property-grid > dt.ox-field--warning,
.ox-table tr.ox-field--warning > td:first-child {
  box-shadow: inset 3px 0 0 var(--ox-warning);
}

.ox-property-grid > dt.ox-field--error,
.ox-table tr.ox-field--error > td:first-child {
  box-shadow: inset 3px 0 0 var(--ox-danger);
}

/* ── Steps (compact vertical sequence) ── */

.ox-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}

.ox-steps__item {
  position: relative;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  gap: var(--ox-space-3);
  align-items: start;
  padding: var(--ox-space-2) 0 var(--ox-space-3);
}

.ox-steps__item:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 13px;
  top: 34px;
  bottom: -2px;
  width: 2px;
  background: var(--ox-border);
}

.ox-steps__index {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--ox-border);
  border-radius: 50%;
  background: var(--ox-surface-soft);
  color: var(--ox-text-secondary);
  font-size: var(--ox-font-caption);
  font-weight: 700;
}

.ox-steps__label {
  font-weight: 600;
  color: var(--ox-text-primary);
}

.ox-steps__detail {
  margin-top: 2px;
  font-size: var(--ox-font-secondary);
  color: var(--ox-text-secondary);
}

/* ── Compact meta row (key/value pairs in one line) ── */

.ox-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ox-space-2) var(--ox-space-5);
  margin: 0;
}

.ox-meta__item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.ox-meta__item dt {
  font-size: var(--ox-font-caption);
  font-weight: 600;
  color: var(--ox-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.ox-meta__item dd {
  margin: 0;
  display: flex;
  align-items: center;
  gap: var(--ox-space-2);
  font-size: var(--ox-font-body);
  color: var(--ox-text-primary);
}

/* ── Config Wizard editor (OXLEON_CONFIG_WIZARD_F3C_2026_10_01) ── */

.ox-editbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--ox-space-2) var(--ox-space-3);
  padding: var(--ox-space-2) var(--ox-space-3);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-md);
  background: var(--ox-surface);
}

.ox-editbar[hidden] {
  display: none !important;
}

.ox-editbar--editing {
  border-color: var(--ox-brand-cyan);
  box-shadow: inset 3px 0 0 var(--ox-brand-cyan);
}

.ox-editbar__title {
  font-weight: 600;
  color: var(--ox-text-primary);
}

.ox-editbar__spacer {
  flex: 1 1 auto;
}

.ox-editbar__msg {
  flex-basis: 100%;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--ox-space-2);
  margin: 0;
  font-size: var(--ox-font-secondary);
  color: var(--ox-text-secondary);
}

.ox-editbar__validation {
  display: inline-flex;
  gap: 4px;
  text-decoration: none;
}

/* CWV2 F15: the edit actions wrap as ONE group (never one button per row); cancel/stop left, primary right */
/* One group, right-aligned; it only wraps (right-aligned) when the bar is narrower than the buttons (1024 NL). */
.ox-editbar__actions {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: var(--ox-space-2);
  margin-left: auto;
  max-width: 100%;
}

/* F3D (OXLEON_CONFIG_WIZARD_F3D_2026_10_01): read-only revision view, version text, finding → property highlight */
.ox-editbar--readonly {
  border-style: dashed;
}

.ox-editbar__meta {
  font-size: var(--ox-font-secondary);
  color: var(--ox-text-muted);
}

.ox-ro-value {
  display: inline-flex;
  align-items: center;
  gap: var(--ox-space-1);
  color: var(--ox-text-primary);
}

.ox-highlight,
tr.ox-highlight > td {
  background: var(--ox-info-bg);
  box-shadow: inset 0 0 0 1px var(--ox-info-border);
  transition: background-color 0.4s ease;
}

.ox-inline-controls {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--ox-space-2);
}

.ox-field-error-text {
  flex-basis: 100%;
  color: var(--ox-danger);
  font-size: var(--ox-font-caption);
}

.ox-form--compact .ox-input--auto,
.ox-form--compact .ox-select--auto {
  width: auto !important;
  min-width: 96px;
  max-width: 280px;
}

/* DS toggle inside compact forms: beats the legacy global input[type=checkbox] size rule */
.ox-form--compact input[type="checkbox"].ox-toggle {
  -webkit-appearance: none;
  appearance: none;
  flex: none;
  width: 36px !important;
  height: 20px !important;
  min-height: 20px !important;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: var(--ox-border-strong);
  position: relative;
  cursor: pointer;
  vertical-align: middle;
}

.ox-form--compact input[type="checkbox"].ox-toggle:checked {
  background: var(--ox-brand-cyan);
}

.ox-form--compact input[type="checkbox"].ox-toggle:focus-visible {
  outline: none;
  box-shadow: var(--ox-focus-ring);
}

.ox-form--compact input[type="checkbox"].ox-toggle:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* changed marker in a tree (paired with screen-reader text) */
.ox-tree-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ox-brand-cyan);
  flex: none;
}
/* ── Modal structure + bounded log view (OXLEON_HW_DIAGNOSE_2026_10_01) ── */

.ox-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--ox-space-3);
  min-height: 52px;
  padding: 0 var(--ox-space-5);
  border-bottom: 1px solid var(--ox-border);
}

.ox-modal__title {
  margin: 0;
  font-size: var(--ox-font-section, 15px);
  font-weight: 600;
  color: var(--ox-text-primary);
}

.ox-modal__body {
  display: flex;
  flex-direction: column;
  gap: var(--ox-space-3);
  padding: var(--ox-space-4) var(--ox-space-5);
}

.ox-modal__footer {
  display: flex;
  justify-content: flex-end;
  gap: var(--ox-space-2);
  padding: var(--ox-space-3) var(--ox-space-5);
  border-top: 1px solid var(--ox-border);
}

.ox-log-view {
  margin: 0;
  height: min(52vh, 520px);
  overflow: auto;
  padding: var(--ox-space-3);
  background: var(--ox-surface-soft);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-sm);
  color: var(--ox-text-primary);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  line-height: 1.45;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.ox-check-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--ox-space-2) var(--ox-space-4);
}

.ox-check-row {
  display: flex !important;
  align-items: center;
  gap: var(--ox-space-2);
  margin: 0;
  font-weight: 400 !important;
  font-size: var(--ox-font-body);
  color: var(--ox-text-primary);
}
/* ── Table parent/child rows: one level, e.g. Hardware terminal → linked devices (OXLEON_HW_TREE_2026_10_01) ── */

.ox-row-name {
  display: inline-flex;
  align-items: flex-start;
  gap: var(--ox-space-1);
  min-width: 0;
}

.ox-row-name__text {
  min-width: 0;
}

.ox-row-toggle {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: -1px 0 0 -4px;
  padding: 0;
  border: 0;
  border-radius: var(--ox-radius-sm);
  background: transparent;
  color: var(--ox-text-secondary);
  cursor: pointer;
}

.ox-row-toggle:hover {
  background: var(--ox-surface-soft);
  color: var(--ox-text-primary);
}

.ox-row-toggle:focus-visible {
  outline: none;
  box-shadow: var(--ox-focus-ring);
}

.ox-row-toggle--none,
.ox-row-toggle--none:hover {
  background: transparent;
  cursor: default;
}

.ox-row-toggle__icon {
  transition: transform 0.15s ease;
}

.ox-row-toggle[aria-expanded="true"] .ox-row-toggle__icon {
  transform: rotate(90deg);
}

.ox-row-count {
  display: inline-block;
  min-width: 18px;
  margin-left: 4px;
  padding: 0 5px;
  border-radius: var(--ox-radius-sm);
  background: var(--ox-surface-soft);
  color: var(--ox-text-muted);
  font-size: 11px;
  font-weight: 500;
  line-height: 16px;
  text-align: center;
  vertical-align: 1px;
}

.ox-table tbody tr.ox-table-row--child > td.ox-tree-cell {
  position: relative;
  padding-left: calc(var(--ox-space-3) + 26px);
}

.ox-table tbody tr.ox-table-row--child > td.ox-tree-cell::before,
.ox-table tbody tr.ox-table-row--child > td.ox-tree-cell::after {
  content: "";
  position: absolute;
  left: calc(var(--ox-space-3) + 6px);
  pointer-events: none;
}

.ox-table tbody tr.ox-table-row--child > td.ox-tree-cell::before {
  top: 0;
  bottom: 0;
  border-left: 1px solid var(--ox-border-strong, var(--ox-border));
}

.ox-table tbody tr.ox-table-row--last-child > td.ox-tree-cell::before {
  bottom: calc(100% - 19px);
}

.ox-table tbody tr.ox-table-row--child > td.ox-tree-cell::after {
  top: 19px;
  width: 10px;
  border-top: 1px solid var(--ox-border-strong, var(--ox-border));
}

.ox-table tbody tr.ox-table-group-row > td {
  height: 32px;
  padding-top: var(--ox-space-1);
  padding-bottom: var(--ox-space-1);
  background: var(--ox-surface-soft);
  color: var(--ox-text-secondary);
  font-size: 12px;
  font-weight: 600;
}

.ox-table tbody tr.ox-table-group-row:hover > td {
  background: var(--ox-surface-soft);
}

/* ==========================================================================
   App boot-state (main.html)
   html.ox-app-booting: shell (sidebar/header/content/footer) blijft verborgen
   tot gebruiker, organisatie, rechten, taal en eerste pagina bekend zijn.
   visibility i.p.v. display: de geometrie staat al goed, dus geen layout-
   sprong bij het tonen. Thema komt uit shell-boot.js (pre-paint), dus de
   achtergrond is direct de juiste light/dark kleur. UX, geen beveiliging.
   ========================================================================== */
html.ox-app-booting #sidebar,
html.ox-app-booting #header,
html.ox-app-booting body > main.content,
html.ox-app-booting #footer {
  visibility: hidden;
}

html.ox-app-booting,
html.ox-app-booting body {
  overflow: hidden;
}

.ox-boot-screen {
  display: none;
}

html.ox-app-booting .ox-boot-screen {
  position: fixed;
  inset: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--ox-page-bg);
  pointer-events: none;
}

/* Vast Oxleon-logo → drie rustige punten → vaste laadtekst. Geen
   minimumduur: bij ox-app-ready verdwijnt het scherm direct (element weg). */
.ox-boot-screen__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--ox-space-5);
  padding: 0 var(--ox-space-4);
}

.ox-boot-screen__logo {
  display: block;
  width: 220px;
  max-width: 60vw;
  height: auto;
}

/* Huisstijl 2026: monochroom logo op lichte ondergrond, gekleurd logo in dark mode. */
html[data-theme="dark"] .ox-boot-screen__logo--light,
html:not([data-theme="dark"]) .ox-boot-screen__logo--dark {
  display: none;
}

.ox-boot-screen__dots {
  display: inline-flex;
  align-items: center;
  gap: var(--ox-space-2);
  height: 8px;
}

.ox-boot-screen__dots i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--ox-brand-cyan);
  opacity: 0.25;
  animation: ox-boot-dot 1.4s ease-in-out infinite;
}

.ox-boot-screen__dots i:nth-child(2) { animation-delay: 0.2s; }
.ox-boot-screen__dots i:nth-child(3) { animation-delay: 0.4s; }

.ox-boot-screen__label {
  margin-top: calc(var(--ox-space-1) * -1);
  color: var(--ox-text-secondary);
  font-size: var(--ox-font-body);
  letter-spacing: 0.01em;
  white-space: nowrap;
}

@keyframes ox-boot-dot {
  0%, 80%, 100% { opacity: 0.25; transform: scale(0.85); }
  40% { opacity: 1; transform: scale(1); }
}

/* Reduced motion: statisch •●• met alleen de middelste punt in accent. */
@media (prefers-reduced-motion: reduce) {
  .ox-boot-screen__dots i {
    animation: none;
    transform: none;
  }

  .ox-boot-screen__dots i:nth-child(2) {
    opacity: 1;
  }
}

/* =========================================================
   Card grid, card head, callout
   Generic DS components (first used by Instellingen → Integraties → Zoho,
   OXLEON_ZOHO_Z1_2026_10_02). Token-based; light + dark.
   ========================================================= */

.ox-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: var(--ox-space-3);
  min-width: 0;
}

.ox-card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--ox-space-3);
  min-width: 0;
}

.ox-card__subtitle {
  margin: 2px 0 0;
  font-size: var(--ox-font-secondary);
  color: var(--ox-text-secondary);
}

.ox-card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ox-space-2);
  margin-top: var(--ox-space-3);
}

/* Brand logo chip (OXLEON_ZOHO_Z13_2026_10_03). Official vendor logos stay
   untouched (opaque white background, dark wordmark), so they always sit on a
   fixed white chip: identical in light and dark mode. The logo is a visual row
   above the card head; title and status keep their own space. */
.ox-card__brand {
  display: flex;
  min-width: 0;
  margin-bottom: var(--ox-space-2);
}

.ox-logo-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  height: 44px;
  max-width: 100%;
  padding: 4px var(--ox-space-2);
  background: var(--ox-logo-chip-bg);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-sm);
  overflow: hidden;
}

.ox-logo-chip img {
  display: block;
  height: 34px;
  width: auto;
  max-width: 140px;
  object-fit: contain;
}

/* Integrations overview: the existing 44x44 tile logo box holding a brand image. */
.integrations-page .integration-tile-logo.integration-tile-logo--image {
  box-sizing: border-box;
  padding: 3px;
  background: var(--ox-logo-chip-bg);
}

.integrations-page .integration-tile-logo--image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* OXLEON_ZOHO_Z14_2026_10_03 ------------------------------------------------ */

/* Integrations overview: informative (non-connected) tile states; text, not colour only. */
.integrations-page .integration-tile-status[data-state="restricted"] {
  color: var(--ox-text-secondary);
}

.integrations-page .integration-tile-status[data-state="inactive"] {
  color: var(--ox-warning);
}

/* Long dialogs: header + footer stay visible, only the body scrolls. */
.ox-modal.ox-modal--scroll-body {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.ox-modal.ox-modal--scroll-body .ox-modal__body {
  min-height: 0;
  overflow-y: auto;
}

/* Grouped options inside the Zoho dialogs (token-based instead of the browser's groove border). */
.ox-modal[aria-labelledby="zohoDlgTitle"] fieldset {
  margin: 0;
  padding: var(--ox-space-2) var(--ox-space-3) var(--ox-space-3);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-md);
  background: var(--ox-surface);
}

.ox-modal[aria-labelledby="zohoDlgTitle"] fieldset > legend {
  padding: 0 var(--ox-space-1);
}

/* .ox-btn sets display and would ignore [hidden] (known trap): scoped fix for Zoho UI. */
#zohoRoot .ox-btn[hidden],
.ox-modal-overlay .ox-btn[hidden] {
  display: none !important;
}

/* OXLEON_ZOHO_Z15_2026_10_03 ------------------------------------------------ */

/* Cliq notification dialog: shared channel list bar + one row per rule
   (checkbox + name | severity | channel dropdown; warning on its own line). */
.ox-zoho-channel-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--ox-space-2) var(--ox-space-3);
  padding: var(--ox-space-2) var(--ox-space-3);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-md);
  background: var(--ox-surface-soft);
}

.ox-zoho-channel-bar .ox-field-help {
  flex: 1 1 auto;
  margin: 0;
}

.ox-zoho-rule {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(180px, 240px);
  grid-template-areas: "name sev channel" "warn warn warn";
  align-items: center;
  column-gap: var(--ox-space-3);
  min-height: var(--ox-control-height);
}

.ox-zoho-rule__name { grid-area: name; min-width: 0; margin: 0; }
.ox-zoho-rule > .ox-status-badge { grid-area: sev; justify-self: start; }
.ox-zoho-rule__channel { grid-area: channel; width: 100%; min-width: 0; }
.ox-zoho-rule__warn { grid-area: warn; }
.ox-zoho-rule__warn:empty { display: none; }

@media (max-width: 720px) {
  .ox-zoho-rule {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas: "name sev" "channel channel" "warn warn";
    row-gap: var(--ox-space-1);
  }
}

/* Zoho module cards: state badge + generic "⋯" module-actions button, top right. */
.ox-zoho-module-head-actions {
  display: inline-flex;
  align-items: center;
  gap: var(--ox-space-1);
  flex: 0 0 auto;
}

.ox-btn.ox-zoho-module-more {
  width: 28px;
  min-width: 28px;
  height: 28px;
  min-height: 28px;
  padding: 0;
  justify-content: center;
}

#zohoModules [data-zoho-notify-line] {
  margin: var(--ox-space-3) 0 0;
}

/* "Zoho Cliq" module dialog: compact sections. */
.ox-zoho-section + .ox-zoho-section {
  margin-top: var(--ox-space-4);
  padding-top: var(--ox-space-3);
  border-top: 1px solid var(--ox-border);
}

.ox-zoho-section > h3 {
  margin: 0 0 var(--ox-space-2);
}

.ox-zoho-section > p {
  margin: 0 0 var(--ox-space-1);
}

.ox-zoho-section .ox-card__actions {
  margin-top: var(--ox-space-2);
}

/* Integrations overview, dark mode: the legacy tile title (#071735) and description
   colours were made for light cards. Scoped to .ax-sys-shell, where the tile uses the
   (dark) --ax-sys-card surface in dark mode. Tokens only; light mode is unchanged. */
html[data-theme="dark"] .ax-sys-shell.integrations-page .integration-tile h3 {
  color: var(--ox-text-primary);
}

html[data-theme="dark"] .ax-sys-shell.integrations-page .integration-tile-desc {
  color: var(--ox-text-secondary);
}

/* Same page, dark mode: section headings and the active category tab (legacy #0f172a,
   hardware-shell sets the tab colour with !important). Integrations page only. */
html[data-theme="dark"] .ax-sys-shell.integrations-page .integrations-section-title {
  color: var(--ox-text-primary);
}

html[data-theme="dark"] .ax-sys-shell.integrations-page .integration-category-tab.is-active {
  background: var(--ox-surface-elevated) !important;
  border-color: var(--ox-brand-cyan) !important;
  color: var(--ox-text-primary) !important;
}

/* Integrations overview: functional sub-status under "Verbonden" (e.g. "1 van 6 modules actief"). */
.integrations-page .integration-tile-substatus {
  display: block;
  margin-top: 2px;
  font-size: 12px;
  color: var(--ox-text-secondary);
}

/* Zoho module On/Off switch (button role="switch"; avoids the global checkbox rule trap).
   Text + position, not colour only. */
.ox-zoho-switch {
  display: inline-flex;
  align-items: center;
  gap: var(--ox-space-1);
  min-height: 28px;
  padding: 0 var(--ox-space-2) 0 2px;
  border: 1px solid var(--ox-border);
  border-radius: 999px;
  background: var(--ox-surface);
  color: var(--ox-text-secondary);
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

.ox-zoho-switch:focus-visible {
  outline: none;
  box-shadow: var(--ox-focus-ring);
}

.ox-zoho-switch:disabled {
  opacity: .55;
  cursor: not-allowed;
}

.ox-zoho-switch__track {
  position: relative;
  width: 30px;
  height: 18px;
  border-radius: 999px;
  background: var(--ox-border-strong);
  transition: background .15s ease;
}

.ox-zoho-switch__thumb {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--ox-surface);
  box-shadow: var(--ox-shadow-sm);
  transition: transform .15s ease;
}

.ox-zoho-switch.is-on {
  border-color: var(--ox-success-border);
  background: var(--ox-success-bg);
  color: var(--ox-success);
}

.ox-zoho-switch.is-on .ox-zoho-switch__track {
  background: var(--ox-success);
}

.ox-zoho-switch.is-on .ox-zoho-switch__thumb {
  transform: translateX(12px);
}

/* "Zoho Cliq" dialog: module row on top; note when the module is Off. */
.ox-zoho-module-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--ox-space-3);
  padding: var(--ox-space-2) var(--ox-space-3);
  margin-bottom: var(--ox-space-3);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-md);
  background: var(--ox-surface-soft);
}

.ox-zoho-module-row__title {
  margin: 0;
  font-weight: 700;
  color: var(--ox-text-primary);
}

.ox-zoho-module-row .ox-field-help {
  margin: 2px 0 0;
}

.ox-zoho-off-note {
  color: var(--ox-warning);
}

/* Rollen & rechten: note on a super-only right ("Integratiemeldingen beheren"). */
.rp-perm-row-note {
  display: block;
  margin-top: 2px;
  font-size: 11px;
  font-weight: 500;
  color: var(--ox-text-muted);
}

.rp-perm-lock {
  vertical-align: -2px;
  color: var(--ox-text-muted);
}

/* H1-AUTH: session notice host (session-guard.js) - a callout pinned above the page. */
.ox-session-notice {
  position: fixed;
  top: var(--ox-space-4);
  left: 50%;
  z-index: 10050;
  width: min(560px, calc(100vw - 2 * var(--ox-space-4)));
  transform: translateX(-50%);
  box-shadow: var(--ox-shadow-md);
  border-radius: var(--ox-radius-md);
}

.ox-session-notice .ox-callout {
  align-items: center;
}

.ox-session-notice .ox-callout > div {
  flex: 1 1 auto;
  min-width: 0;
}

/* Callout: prominent notice; always icon + text, never colour only. */
.ox-callout {
  display: flex;
  align-items: flex-start;
  gap: var(--ox-space-3);
  padding: var(--ox-space-3) var(--ox-space-4);
  border: 1px solid var(--ox-border);
  border-left-width: 4px;
  border-radius: var(--ox-radius-md);
  background: var(--ox-surface-soft);
  color: var(--ox-text-primary);
}

.ox-callout__icon {
  flex: none;
  width: var(--ox-icon-size);
  height: var(--ox-icon-size);
  margin-top: 2px;
}

.ox-callout__title {
  margin: 0;
  font-weight: 600;
  color: var(--ox-text-primary);
}

.ox-callout__text {
  margin: 2px 0 0;
  font-size: var(--ox-font-secondary);
  color: var(--ox-text-secondary);
}

.ox-callout--warning {
  background: var(--ox-warning-bg);
  border-color: var(--ox-warning-border);
  border-left-color: var(--ox-warning);
}

.ox-callout--warning .ox-callout__icon { color: var(--ox-warning); }

.ox-callout--danger {
  background: var(--ox-danger-bg);
  border-color: var(--ox-danger-border);
  border-left-color: var(--ox-danger);
}

.ox-callout--danger .ox-callout__icon { color: var(--ox-danger); }

.ox-callout--info {
  background: var(--ox-info-bg);
  border-color: var(--ox-info-border);
  border-left-color: var(--ox-info);
}

.ox-callout--info .ox-callout__icon { color: var(--ox-info); }

.ox-callout__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ox-space-2);
  margin-top: var(--ox-space-2);
}

.ox-callout[hidden] {
  display: none !important;
}

/* OXLEON_ZOHO_Z16_2026_10_03 ------------------------------------------------ */

/* Integratie-instellingen (Cliq routing) card + dialog; DS-classes hide-trap: explicit [hidden]. */
#zohoRoutingCard[hidden],
#zohoRoutingOwnerWrap[hidden],
#zohoRoutingMembersWrap[hidden],
.ox-zoho-ntf-section[hidden] {
  display: none !important;
}

.ox-zoho-routing-status {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ox-space-1);
}

.ox-zoho-routing-mode.ox-check-row {
  align-items: flex-start;
}

.ox-zoho-routing-radio {
  /* global input[type] sizing (style.css) would stretch the radio: pin it to the control size */
  width: 16px !important;
  height: 16px !important;
  min-width: 16px !important;
  min-height: 16px !important;
  margin: 3px 0 0 !important;
  padding: 0 !important;
  accent-color: var(--ox-brand-cyan);
  flex: 0 0 auto;
}

.ox-zoho-routing-members {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: var(--ox-space-1) var(--ox-space-3);
  max-height: 180px;
  overflow-y: auto;
  padding: var(--ox-space-2) var(--ox-space-3);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-sm);
  background: var(--ox-surface-soft);
}

.ox-zoho-routing-consequences {
  margin: var(--ox-space-1) 0 0;
  padding-left: var(--ox-space-5);
  color: var(--ox-text-secondary);
  font-size: var(--ox-font-body);
}

/* "Meldingen instellen": Organisatiemeldingen / Platformmeldingen sections. */
.ox-zoho-ntf-section {
  padding-top: var(--ox-space-3);
  border-top: 1px solid var(--ox-border);
}

.ox-zoho-ntf-section:first-child {
  padding-top: 0;
  border-top: 0;
}

.ox-zoho-ntf-section__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--ox-space-2);
}

.ox-zoho-ntf-section__title {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--ox-text-primary);
}

/* ── Config Wizard CW1 "Algemeen" (OXLEON_CONFIG_WIZARD_CW1_2026_10_11) ──
   .ox-field-origin  who decides a value (icon + text, never colour alone)
   .ox-disclosure    collapsible section (native <details>/<summary>, keyboard + screen reader friendly)
   .ox-general-grid  two section cards side by side from tablet width, one column below */

.ox-general-grid {
  display: grid;
  /* follows the width of the detail pane, not the window: two cards only when both get room */
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 460px), 1fr));
  gap: var(--ox-space-3);
  min-width: 0;
}

.ox-general-card {
  display: flex;
  flex-direction: column;
  gap: var(--ox-space-3);
  min-width: 0;
}

.ox-general-card .ox-property-grid {
  grid-template-columns: minmax(120px, 36%) minmax(0, 1fr);
}

.ox-general-value {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--ox-space-1) var(--ox-space-2);
  min-width: 0;
}

.ox-general-dd > .ox-field-origin {
  margin-left: auto;
}

.ox-general-manage {
  margin: 0;
}

.ox-general-manage a {
  color: var(--ox-brand-cyan);
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--ox-radius-sm);
}

.ox-general-manage a:hover {
  text-decoration: underline;
}

.ox-general-manage a:focus-visible {
  outline: none;
  box-shadow: var(--ox-focus-ring);
}

.ox-field-origin {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: 100%;
  padding: 1px 8px;
  border: 1px solid var(--ox-border);
  border-radius: 999px;
  background: var(--ox-surface-soft);
  color: var(--ox-text-secondary);
  font-size: var(--ox-font-caption);
  font-weight: 500;
  line-height: 18px;
  white-space: nowrap;
}

.ox-field-origin svg {
  width: 12px;
  height: 12px;
  flex: 0 0 auto;
}

.ox-field-origin--info {
  border-color: var(--ox-info-border);
  background: var(--ox-info-bg);
  color: var(--ox-info);
}

.ox-lang-grid {
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: var(--ox-space-1) var(--ox-space-3);
  width: 100%;
}

/* LANG-MAX6 (15-11): language flag (Core catalog /flags) before the name + "n of max" counter */
.ox-lang-flag {
  width: 20px;
  height: 14px;
  object-fit: cover;
  border-radius: 2px;
  box-shadow: 0 0 0 1px var(--ox-border);
  vertical-align: middle;
  flex: 0 0 auto;
  margin-right: var(--ox-space-1);
}

.ox-lang-count {
  display: block;
  margin-top: var(--ox-space-1);
}

.ox-disclosure {
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-md);
  background: var(--ox-surface);
}

.ox-disclosure__summary {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: var(--ox-space-1) var(--ox-space-3);
  padding: var(--ox-space-2) var(--ox-space-4);
  cursor: pointer;
  list-style: none;
  font-size: var(--ox-font-body);
  font-weight: 600;
  color: var(--ox-text-primary);
  border-radius: var(--ox-radius-md);
}

.ox-disclosure__summary::-webkit-details-marker {
  display: none;
}

.ox-disclosure__summary::before {
  content: "";
  width: 7px;
  height: 7px;
  border-right: 2px solid var(--ox-text-secondary);
  border-bottom: 2px solid var(--ox-text-secondary);
  transform: rotate(-45deg);
  transition: transform 0.15s ease;
  align-self: center;
}

.ox-disclosure[open] > .ox-disclosure__summary::before {
  transform: rotate(45deg);
}

.ox-disclosure__summary:focus-visible {
  outline: none;
  box-shadow: var(--ox-focus-ring);
}

.ox-disclosure__hint {
  font-weight: 400;
  font-size: var(--ox-font-caption);
  color: var(--ox-text-muted);
}

.ox-disclosure__body {
  padding: 0 var(--ox-space-4) var(--ox-space-4);
}

@media (prefers-reduced-motion: reduce) {
  .ox-disclosure__summary::before {
    transition: none;
  }
}

/* CW2 fase B4: configuration status chain (Concept -> Gepubliceerd -> Toegepast in Core -> Actief op Edge).
   Status is never colour-only: every step carries an icon + text (+ screen-reader state). Tokens only. */
.ox-status-chain {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--ox-space-1);
  margin: 0;
  padding: 0;
  list-style: none;
}
.ox-status-chain__step,
.ox-status-chain__sep {
  display: inline-flex;
  align-items: center;
}
.ox-status-chain__step {
  position: relative; /* keeps the screen-reader state (.ox-sr-only) inside the step, never in the page width */
}
.ox-status-chain__sep {
  color: var(--ox-text-muted);
}
.ox-status-chain .ox-status-badge::before {
  display: none;
}
.ox-status-chain .ox-status-badge svg {
  flex: 0 0 auto;
}
/* Mobile only: long status texts (chain steps, editbar states) wrap inside their badge instead of widening the page.
   Desktop geometry is unchanged. */
@media (max-width: 720px) {
  .ox-status-chain .ox-status-badge,
  .ox-editbar .ox-status-badge {
    height: auto;
    min-height: 22px;
    padding-top: 2px;
    padding-bottom: 2px;
    line-height: 1.3;
    white-space: normal;
    overflow-wrap: anywhere;
    min-width: 0;
  }
  .ox-status-chain {
    flex-direction: column;
    align-items: flex-start;
    min-width: 0;
    max-width: 100%;
  }
  .ox-status-chain__sep {
    display: none;
  }
  .ox-status-chain__step,
  .ox-status-chain .ox-status-badge > span {
    min-width: 0;
    max-width: 100%;
  }
}

/* OXLEON_CWV2_DANGER_CONFIRM_2026_10_26 - axConfirm danger (delete) is red, not amber.
   The red rules in style.css only target .session-lifetime-modal.is-danger; axConfirm renders .ax-confirm-modal.is-danger,
   so the amber base of .session-lifetime-* won. Geometry is unchanged; dark mode keeps the same rules (tokens). */
.ax-confirm-modal.is-danger .session-lifetime-box {
  border-color: var(--ox-danger-border);
}
.ax-confirm-modal.is-danger .session-lifetime-header-icon {
  background: var(--ox-danger-strong);
  border-color: var(--ox-danger-border);
  box-shadow: var(--ox-shadow-sm);
  color: #fff;
}
.ax-confirm-modal.is-danger .session-lifetime-eyebrow {
  color: var(--ox-danger-strong);
}
html[data-theme="dark"] .ax-confirm-modal.is-danger .session-lifetime-eyebrow {
  color: var(--ox-danger);
}
.ax-confirm-modal.is-danger .session-lifetime-btn-confirm {
  background: var(--ox-danger-strong);
  border-color: var(--ox-danger-strong);
  box-shadow: var(--ox-shadow-sm);
  color: #fff;
}
.ax-confirm-modal.is-danger .session-lifetime-btn-confirm:hover {
  filter: brightness(1.06);
}
.ax-confirm-modal.is-danger .session-lifetime-btn-confirm:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px var(--ox-danger-border);
}

/* ── FLOORPLAN-DO (30-10-2026): diagnostic test output marker next to its terminal on the floorplan ──
   Positioned like .floor-widget (left/top in %), shifted right of the 40px terminal disc; --ox-io-marker-row stacks
   several outputs of one terminal. State is text + dot + border, never colour alone; stale = dashed + "Onbekend".
   --ox-io-marker-scale (set by floorplan-page.js on #mapContent, 1..2.5) undoes the map zoom-out for these markers
   only; scale first with origin 0 0 keeps the offset to the terminal constant on screen. Below the terminal widgets
   (z-index 3 < 4) so no existing object is covered or loses its click. */
.ox-io-marker {
  --ox-io-marker-row: 0;
  position: absolute;
  z-index: 3;
  transform-origin: 0 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 24px;
  padding: 0 8px;
  transform: scale(var(--ox-io-marker-scale, 1)) translate(26px, calc(-50% + var(--ox-io-marker-row) * 28px));
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-sm);
  background: var(--ox-surface);
  color: var(--ox-text-primary);
  box-shadow: var(--ox-shadow-sm);
  font-family: inherit;
  font-size: 11px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
}
.ox-io-marker:hover { box-shadow: var(--ox-shadow-hover); }
.ox-io-marker:focus-visible { outline: none; box-shadow: var(--ox-focus-ring); }
.ox-io-marker__dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; flex: none; }
.ox-io-marker__label { font-family: var(--ox-font-mono, ui-monospace, monospace); color: var(--ox-text-secondary); }
.ox-io-marker__state { font-weight: 700; }
.ox-io-marker__sr {
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}
.ox-io-marker--success { border-color: var(--ox-success-border); background: var(--ox-success-bg); }
.ox-io-marker--success .ox-io-marker__dot,
.ox-io-marker--success .ox-io-marker__state { color: var(--ox-success); }
.ox-io-marker--neutral .ox-io-marker__dot { color: var(--ox-text-muted); }
.ox-io-marker--warning { border-color: var(--ox-warning-border); background: var(--ox-warning-bg); }
.ox-io-marker--warning .ox-io-marker__dot,
.ox-io-marker--warning .ox-io-marker__state { color: var(--ox-warning); }
.ox-io-marker.is-stale { border-style: dashed; }

.ox-io-out-drawer .ox-drawer { --ox-drawer-width: 420px; }
.ox-io-out-drawer .ox-drawer__header { padding-block: var(--ox-space-3); }
.ox-io-out-drawer .ox-io-out-state {
  display: flex; align-items: center; gap: var(--ox-space-2); margin-bottom: var(--ox-space-4);
}
.ox-io-out-drawer .ox-io-out-msg { margin-top: var(--ox-space-4); padding: var(--ox-space-3); }
.ox-io-out-drawer .ox-drawer__footer { flex-wrap: wrap; align-items: center; }
.ox-io-out-drawer .ox-io-out-blocked { flex: 1 1 100%; margin: 0; color: var(--ox-text-secondary); }
/* H1-DO0: latched fault notice + the authorized reset form (reason, confirmation) */
.ox-io-out-drawer .ox-io-out-fault { margin-top: var(--ox-space-4); padding: var(--ox-space-3); }
.ox-io-out-drawer .ox-io-out-reset { display: grid; gap: var(--ox-space-2); margin-top: var(--ox-space-4); }
.ox-io-out-drawer .ox-io-out-reset .ox-card { padding: var(--ox-space-3); }
.ox-io-out-drawer .ox-io-out-reset .ox-textarea { width: 100%; resize: vertical; }
.ox-io-out-drawer .ox-io-out-reset__confirm {
  display: flex; align-items: flex-start; gap: var(--ox-space-2); font-size: var(--ox-font-body); color: var(--ox-text-primary);
}

/* ── FASE-C V2 (30-10-2026): I/O-diagnostiek channel tables (Hardwarebeheer -> terminal -> I/O, also in a drawer) ──
   The table always fits its own container: fixed layout, the name input takes the full column, long values wrap. In a
   narrow container (drawer, tablet, phone) every channel becomes one compact block with the column name above each
   value, so no column is cut off and nothing scrolls horizontally. Container query: the drawer is narrow on desktop too. */
.ox-iod-wrap { container: ox-iod / inline-size; }
.ox-iod-table { table-layout: fixed; }
.ox-iod-table th,
.ox-iod-table td { vertical-align: top; overflow-wrap: anywhere; }
.ox-iod-table .ox-iod-col-nr { width: 76px; }
.ox-iod-table .ox-iod-col-status { width: 26%; }
.ox-iod-table .ox-iod-col-changed { width: 96px; }
.ox-iod-table .ox-iod-col-test { width: 132px; }
.ox-iod-table .ox-input { width: 100%; min-width: 0; }
.ox-iod-table .ox-iod-mark { margin-top: var(--ox-space-1); align-items: flex-start; }
.ox-iod-table .ox-iod-mark.is-disabled { color: var(--ox-text-muted); }
.ox-iod-table .ox-iod-mark .ox-checkbox { flex: none; margin-top: 2px; }
.ox-iod-table .ox-btn { max-width: 100%; white-space: normal; }

@container ox-iod (max-width: 620px) {
  .ox-iod-table thead {
    position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
  }
  .ox-iod-table,
  .ox-iod-table tbody { display: block; width: 100%; }
  .ox-iod-table tr {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr) minmax(0, 1fr);
    gap: var(--ox-space-1) var(--ox-space-3);
    padding: var(--ox-space-2) var(--ox-space-3);
    border-bottom: 1px solid var(--ox-border);
  }
  .ox-iod-table tr:last-child { border-bottom: 0; }
  .ox-iod-table td { display: block; padding: 0; border: 0; min-width: 0; height: auto; }
  .ox-iod-table td:first-child { grid-row: span 2; }
  .ox-iod-table td:nth-child(2) { grid-column: 2 / 4; }
  .ox-iod-table td:not(:first-child)::before {
    content: attr(data-label);
    display: block;
    font-size: var(--ox-font-caption);
    color: var(--ox-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.02em;
  }
  .ox-iod-table td:nth-child(5) { grid-column: 2 / 4; }
}
@container ox-iod (max-width: 360px) {
  .ox-iod-table tr { grid-template-columns: 52px minmax(0, 1fr); }
  .ox-iod-table td:nth-child(2),
  .ox-iod-table td:nth-child(5) { grid-column: 2; }
  .ox-iod-table td:first-child { grid-row: span 4; }
}
/* FASE-C V2: the flask marks a floorplan object as a diagnostic TEST output (never a barrier / door object) */
.ox-io-marker__icon { flex: none; color: var(--ox-info); }
/* FASE-C DO0 (31-10-2026): the operational "Barrier open" output (DO0) - cyan accent and its own icon, so it is never
   mistaken for a test output; same geometry, state colours and stale (dashed) rule as the test-output marker */
.ox-io-marker--barrier { border-left: 3px solid var(--ox-brand-cyan); }
.ox-io-marker--barrier .ox-io-marker__icon { color: var(--ox-brand-cyan); }
/* FPIO1 (FASE-C V2): own position of a test output - centred on its point, not shifted next to the terminal disc */
.ox-io-marker.is-placed { transform: scale(var(--ox-io-marker-scale, 1)) translate(-50%, -50%); }
.ox-io-placing, .ox-io-placing * { cursor: crosshair !important; }
.ox-io-place-hint {
  position: fixed; left: 50%; top: var(--ox-space-6); transform: translateX(-50%); z-index: 1200;
  padding: var(--ox-space-2) var(--ox-space-4); box-shadow: var(--ox-shadow-md); max-width: calc(100vw - 32px);
}
.ox-io-place-hint .ox-field-help { margin: 0; color: var(--ox-text-primary); }
.ox-io-out-drawer .ox-io-out-pos { margin-top: var(--ox-space-4); padding-top: var(--ox-space-3); border-top: 1px solid var(--ox-border); }
.ox-io-out-drawer .ox-io-out-pos__row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--ox-space-2); margin-top: var(--ox-space-2); }
.ox-io-out-drawer .ox-io-out-pos__row .ox-input { width: 84px; }
.ox-io-out-drawer .ox-io-out-pos__row .ox-field-label { margin: 0; }

/* FASE-C V2 (31-10-2026): floorplan page in dark mode. style.css hardcodes white for the toolbar, the zoom controls and
   the stage grid; in dark mode the zoom percentage was white on white and the grid glared. Dark only - light unchanged. */
html[data-theme="dark"] .floorplan-toolbar { background: var(--ox-surface); border-color: var(--ox-border); }
html[data-theme="dark"] .floorplan-stage {
  border-color: var(--ox-border);
  background-color: var(--ox-page-bg);
  background-image: linear-gradient(90deg, var(--ox-border-soft) 1px, transparent 1px), linear-gradient(var(--ox-border-soft) 1px, transparent 1px);
}
html[data-theme="dark"] .floorplan-zoom button,
html[data-theme="dark"] .floorplan-zoom span {
  background: var(--ox-surface-elevated);
  color: var(--ox-text-primary);
  border: 1px solid var(--ox-border);
  box-shadow: var(--ox-shadow-sm);
}
html[data-theme="dark"] .floorplan-zoom button:hover { border-color: var(--ox-border-hover); }
html[data-theme="dark"] .floorplan-page.is-fullscreen { background: var(--ox-page-bg); }

/* Passagecyclus: one recorded passage with its steps in order */
.ox-lane-card__head { display: flex; flex-wrap: wrap; gap: var(--ox-space-2); margin-bottom: var(--ox-space-2); }
.ox-lane-card .ox-field-help { margin-top: var(--ox-space-2); }
.ox-passage-list { display: flex; flex-direction: column; gap: var(--ox-space-2); }
.ox-passage { border: 1px solid var(--ox-border); border-radius: var(--ox-radius-sm); background: var(--ox-surface); }
.ox-passage > summary { display: flex; flex-wrap: wrap; align-items: center; gap: var(--ox-space-2); padding: var(--ox-space-2) var(--ox-space-3); cursor: pointer; font-size: var(--ox-font-body); color: var(--ox-text-primary); }
.ox-passage > summary:focus-visible { outline: none; box-shadow: var(--ox-focus-ring); border-radius: var(--ox-radius-sm); }
.ox-passage__time { color: var(--ox-text-secondary); font-variant-numeric: tabular-nums; }
.ox-passage__terminal { color: var(--ox-text-secondary); }
.ox-passage__plate { font-weight: 600; letter-spacing: .02em; }
.ox-passage-steps { list-style: none; margin: 0; padding: 0 var(--ox-space-3) var(--ox-space-2); display: flex; flex-direction: column; gap: var(--ox-space-1); }
.ox-passage-step { display: grid; grid-template-columns: 16px minmax(120px, 170px) minmax(0, 1fr) auto; align-items: center; gap: var(--ox-space-2); font-size: 12px; color: var(--ox-text-muted); }
.ox-passage-step.is-done { color: var(--ox-text-primary); }
.ox-passage-step.is-done > svg { color: var(--ox-success); }
.ox-passage-step.is-warning, .ox-passage-step.is-warning > svg { color: var(--ox-warning); }
.ox-passage-step__note { color: var(--ox-text-secondary); min-width: 0; overflow-wrap: anywhere; }
.ox-passage-step__time { color: var(--ox-text-muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (max-width: 720px) { .ox-passage-step { grid-template-columns: 16px minmax(0, 1fr); } .ox-passage-step__note, .ox-passage-step__time { grid-column: 2; } }
.live-passages { margin: 0 var(--ox-space-4) var(--ox-space-3); }
.live-passages .ox-passage-list { max-height: 240px; overflow-y: auto; }

/* IDLE-DISPLAY (10-11): Config Wizard > Display - terminal idle screen preview. The preview shows the KIOSK screen,
   which is dark in both themes on purpose: the two kiosk colours are fixed and documented here, everything else
   uses the shared tokens. */
.ox-display-idle { display: grid; grid-template-columns: minmax(0, 560px) minmax(260px, 360px); gap: var(--ox-space-5); align-items: start; }
@media (max-width: 1100px) { .ox-display-idle { grid-template-columns: minmax(0, 1fr); } }
.ox-display-preview { --ox-kiosk-text: #FFFFFF; --ox-kiosk-scrim: #000000; position: relative; aspect-ratio: 4 / 3; max-width: 560px; overflow: hidden; border: 1px solid var(--ox-border); border-radius: var(--ox-radius-md); background: linear-gradient(160deg, var(--ox-brand-navy-mid), var(--ox-brand-navy-deep)); box-shadow: var(--ox-shadow-sm); }
.ox-display-preview__bg { position: absolute; inset: -24px; background-size: cover; background-position: center; }
.ox-display-preview__scrim { position: absolute; inset: 0; background: var(--ox-kiosk-scrim); }
.ox-display-preview__center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--ox-space-2); color: var(--ox-kiosk-text); text-align: center; padding: var(--ox-space-4); }
.ox-display-preview__logo { max-width: 46%; max-height: 28%; object-fit: contain; }
.ox-display-preview__words { font-size: var(--ox-font-body); font-weight: 600; letter-spacing: .02em; opacity: .9; }
.ox-display-preview__tag { position: absolute; left: var(--ox-space-2); top: var(--ox-space-2); }
.ox-range { width: 100%; accent-color: var(--ox-brand-cyan); }
.ox-range:focus-visible { outline: none; box-shadow: var(--ox-focus-ring); border-radius: var(--ox-radius-sm); }
.ox-display-idle__value { color: var(--ox-text-secondary); font-variant-numeric: tabular-nums; }
/* browser check 10-11: the global form rules made the radios ~40px circles and the ranges control-height boxes */
.ox-display-idle fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.ox-display-idle .ox-check-row { display: flex; align-items: center; justify-content: flex-start; gap: var(--ox-space-2); }
.ox-display-idle input[type="radio"] { flex: 0 0 auto; width: var(--ox-icon-size); height: var(--ox-icon-size); min-width: 0; min-height: 0; margin: 0; padding: 0; accent-color: var(--ox-brand-cyan); }
.ox-display-idle input.ox-range { height: 20px; min-height: 0; padding: 0; margin: 0; border: 0; box-shadow: none; background: transparent; }

/* ── Receipt viewer popup (OXLEON_B63_RECEIPT_VIEWER, receipt-viewer.js; first user: Parkeerhistorie) ── */
.ox-receipt-viewer [hidden] { display: none !important; }
.ox-modal.ox-receipt-viewer { display: flex; flex-direction: column; overflow: hidden; }
.ox-receipt-viewer .ox-modal__header { flex: 0 0 auto; padding-top: var(--ox-space-2); padding-bottom: var(--ox-space-2); }
.ox-receipt-viewer__heading { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ox-receipt-viewer__heading .ox-field-help { margin: 0; }
.ox-receipt-viewer .ox-modal__body { flex: 1 1 auto; min-height: 0; overflow: auto; }
.ox-receipt-viewer .ox-modal__footer { flex: 0 0 auto; align-items: center; }
.ox-receipt-viewer__spacer { flex: 1 1 auto; }
.ox-receipt-viewer__controls { display: flex; flex-wrap: wrap; gap: var(--ox-space-3); }
.ox-receipt-viewer__field { display: flex; flex-direction: column; gap: var(--ox-space-1); flex: 1 1 220px; min-width: 0; }
.ox-receipt-viewer__field .ox-select { width: 100%; }
.ox-receipt-viewer__meta { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: var(--ox-space-2) var(--ox-space-4); margin: 0; padding: var(--ox-space-3); border: 1px solid var(--ox-border); border-radius: var(--ox-radius-md); background: var(--ox-surface-soft); }
.ox-receipt-viewer__meta--stack { grid-template-columns: 1fr; }
.ox-receipt-viewer__meta-item { min-width: 0; }
.ox-receipt-viewer__meta dt { font-size: var(--ox-font-caption); color: var(--ox-text-muted); }
.ox-receipt-viewer__meta dd { margin: 0; font-size: var(--ox-font-body); color: var(--ox-text-primary); overflow-wrap: anywhere; }
.ox-receipt-viewer__mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: var(--ox-font-caption); }
.ox-receipt-viewer__preview { display: flex; flex-direction: column; min-height: 0; }
.ox-receipt-viewer__frame { display: block; width: 100%; height: min(56vh, 560px); min-height: 240px; border: 1px solid var(--ox-border); border-radius: var(--ox-radius-md); background: var(--ox-surface); }
.ox-receipt-viewer__message { margin: 0; padding: var(--ox-space-4); text-align: center; color: var(--ox-text-secondary); border: 1px dashed var(--ox-border); border-radius: var(--ox-radius-md); }
.ox-receipt-viewer__message.is-error { color: var(--ox-danger); border-style: solid; border-color: var(--ox-danger-border); background: var(--ox-danger-bg); }
.ox-receipt-viewer__mail { display: flex; flex-direction: column; gap: var(--ox-space-2); }
.ox-receipt-viewer__mail .ox-input { width: 100%; }
.ox-receipt-viewer__error { color: var(--ox-danger); margin: var(--ox-space-1) 0 0; }
.ox-receipt-viewer__result { display: flex; gap: var(--ox-space-3); align-items: flex-start; padding: var(--ox-space-3); border: 1px solid var(--ox-success-border); border-radius: var(--ox-radius-md); background: var(--ox-success-bg); color: var(--ox-text-primary); }
.ox-receipt-viewer__result > svg { flex: 0 0 auto; color: var(--ox-success); }
.ox-receipt-viewer__result.is-error { border-color: var(--ox-danger-border); background: var(--ox-danger-bg); }
.ox-receipt-viewer__result.is-error > svg { color: var(--ox-danger); }
.ox-receipt-viewer__result p { margin: var(--ox-space-1) 0 0; }
.ox-receipt-viewer .ox-btn { display: inline-flex; align-items: center; gap: var(--ox-space-1); }
.ox-receipt-viewer .ox-btn svg { flex: 0 0 auto; }
@media (max-width: 720px) {
  .ox-receipt-viewer__footer { flex-wrap: wrap; }
  .ox-receipt-viewer__spacer { display: none; }
}

/* ============================================================================
   B63-DEVICE-MENU (11-11-2026): premium device context menu (.ox-dcm) for the
   Plattegrond and the Dashboard + the three-dot button on touch screens.
   Tokens only (light/dark follow automatically). Layer: just above the device
   modal, below the confirmation dialog (fp-ctl-dialog-backdrop = +60).
   ============================================================================ */
.ox-dcm {
  position: fixed;
  z-index: calc(var(--z-modal-top, 7000) + 40);
  width: 288px;
  max-width: calc(100vw - 16px);
  overflow-x: hidden;
  overflow-y: auto;
  background: var(--ox-surface-elevated, var(--ox-surface));
  color: var(--ox-text-primary);
  border: 1px solid var(--ox-border);
  border-radius: var(--ox-radius-md);
  box-shadow: var(--ox-shadow-md);
  font-size: var(--ox-font-body, 13px);
  line-height: 1.35;
  overscroll-behavior: contain;
}
.ox-dcm[hidden] { display: none !important; }
.ox-dcm svg { width: var(--ox-icon-size, 16px); height: var(--ox-icon-size, 16px); flex: 0 0 auto; }
.ox-dcm__header {
  padding: var(--ox-space-3) var(--ox-space-3) var(--ox-space-2);
  border-bottom: 1px solid var(--ox-border-soft, var(--ox-border));
}
.ox-dcm__title { display: block; font-weight: 600; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ox-dcm__meta { display: flex; flex-wrap: wrap; align-items: center; gap: var(--ox-space-2); margin-top: var(--ox-space-1); }
.ox-dcm__type { color: var(--ox-text-secondary); font-size: var(--ox-font-caption, 12px); }
.ox-dcm__status { display: inline-flex; align-items: center; gap: 4px; }
.ox-dcm__status svg, .ox-dcm__status-icon svg { width: 12px; height: 12px; }
.ox-dcm__status-icon { display: inline-flex; }
.ox-dcm__checking { display: flex; align-items: center; gap: var(--ox-space-1); margin-top: var(--ox-space-2); color: var(--ox-text-muted); font-size: var(--ox-font-caption, 12px); }
.ox-dcm__spin { display: inline-flex; animation: ox-dcm-spin 0.9s linear infinite; }
.ox-dcm__spin svg { width: 12px; height: 12px; }
@keyframes ox-dcm-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .ox-dcm__spin { animation: none; } }
.ox-dcm__notes { display: grid; gap: var(--ox-space-1); padding: var(--ox-space-2) var(--ox-space-3) 0; }
.ox-dcm__note, .ox-dcm__feedback {
  display: flex; align-items: flex-start; gap: var(--ox-space-2);
  padding: 6px var(--ox-space-2);
  border-radius: var(--ox-radius-sm);
  border: 1px solid var(--ox-border-soft, var(--ox-border));
  background: var(--ox-surface-soft, var(--ox-surface));
  color: var(--ox-text-primary);
  font-size: var(--ox-font-caption, 12px);
}
.ox-dcm__note svg, .ox-dcm__feedback svg { width: 14px; height: 14px; margin-top: 1px; }
.ox-dcm__note--danger { background: var(--ox-danger-bg); border-color: var(--ox-danger-border); }
.ox-dcm__note--danger svg { color: var(--ox-danger); }
.ox-dcm__note--warning, .ox-dcm__feedback--warning { background: var(--ox-warning-bg); border-color: var(--ox-warning-border); }
.ox-dcm__note--warning svg, .ox-dcm__feedback--warning svg { color: var(--ox-warning); }
.ox-dcm__note--info { background: var(--ox-info-bg); border-color: var(--ox-info-border); }
.ox-dcm__note--info svg { color: var(--ox-info); }
.ox-dcm__note--neutral svg { color: var(--ox-text-muted); }
.ox-dcm__feedback { margin: 0 var(--ox-space-3) var(--ox-space-2); }
.ox-dcm__feedback[hidden] { display: none; }
.ox-dcm__list { padding: var(--ox-space-1) 0; }
.ox-dcm__sep { height: 1px; margin: var(--ox-space-1) var(--ox-space-3); background: var(--ox-border-soft, var(--ox-border)); }
.ox-dcm__group-label {
  padding: 6px var(--ox-space-3) 2px;
  color: var(--ox-text-muted);
  font-size: 11px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase;
}
.ox-dcm__mode { display: flex; align-items: center; justify-content: space-between; gap: var(--ox-space-2); padding: 2px var(--ox-space-3) 4px; }
.ox-dcm__mode-label { color: var(--ox-text-secondary); font-size: var(--ox-font-caption, 12px); }
.ox-dcm__empty { padding: 2px var(--ox-space-3) 6px; color: var(--ox-text-muted); font-size: var(--ox-font-caption, 12px); }
.ox-dcm__item {
  display: flex; align-items: center; gap: var(--ox-space-2);
  min-height: 32px;
  margin: 0 var(--ox-space-1);
  padding: 0 var(--ox-space-2);
  border-radius: var(--ox-radius-sm);
  color: var(--ox-text-primary);
  cursor: pointer;
  user-select: none;
  outline: none;
}
.ox-dcm__item .ox-dcm__icon { display: inline-flex; color: var(--ox-text-secondary); }
.ox-dcm__label { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ox-dcm__item:hover { background: var(--ox-brand-cyan-soft, var(--ox-surface-soft)); }
.ox-dcm__item:focus-visible, .ox-dcm__item:focus { background: var(--ox-brand-cyan-soft, var(--ox-surface-soft)); box-shadow: var(--ox-focus-ring); }
.ox-dcm__item:hover .ox-dcm__icon, .ox-dcm__item:focus .ox-dcm__icon { color: var(--ox-brand-cyan-text, var(--ox-brand-cyan)); }
.ox-dcm__item--danger .ox-dcm__label, .ox-dcm__item--danger .ox-dcm__icon,
.ox-dcm__item--danger:hover .ox-dcm__icon, .ox-dcm__item--danger:focus .ox-dcm__icon { color: var(--ox-danger); }
.ox-dcm__item--danger:hover, .ox-dcm__item--danger:focus { background: var(--ox-danger-bg); }
.ox-dcm__item.is-disabled { cursor: not-allowed; }
.ox-dcm__item.is-disabled .ox-dcm__label, .ox-dcm__item.is-disabled .ox-dcm__icon { color: var(--ox-text-muted); }
.ox-dcm__item.is-disabled:hover { background: var(--ox-surface-soft, transparent); }
.ox-dcm__badge {
  flex: 0 0 auto; padding: 1px 6px;
  border: 1px solid var(--ox-border); border-radius: 999px;
  color: var(--ox-text-muted); font-size: 11px;
}
.ox-dcm__chev { display: inline-flex; color: var(--ox-text-muted); transition: transform 0.15s ease; }
.ox-dcm__item--more[aria-expanded="true"] .ox-dcm__chev { transform: rotate(90deg); }
.ox-dcm__group--sub { margin: 2px 0 2px var(--ox-space-4); border-left: 1px solid var(--ox-border-soft, var(--ox-border)); }
.ox-dcm__group--sub[hidden] { display: none; }

/* three-dot button on a device marker: only on touch screens (no hover, coarse pointer) */
.ox-dcm-kebab {
  display: none;
  position: absolute; top: -10px; right: -10px;
  width: 28px; height: 28px; padding: 0;
  align-items: center; justify-content: center;
  border: 1px solid var(--ox-border); border-radius: 999px;
  background: var(--ox-surface-elevated, var(--ox-surface));
  color: var(--ox-text-secondary);
  box-shadow: var(--ox-shadow-sm);
  cursor: pointer; z-index: 3;
}
.ox-dcm-kebab svg { width: 16px; height: 16px; }
.ox-dcm-kebab:focus-visible { outline: none; box-shadow: var(--ox-focus-ring); }
@media (hover: none) and (pointer: coarse) {
  .ox-dcm-kebab { display: inline-flex; }
  /* a long press on a marker never selects text or opens the native callout */
  [data-dcm-decorated="1"] { -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; }
}
@media (max-width: 720px) {
  .ox-dcm { width: min(320px, calc(100vw - 16px)); }
  .ox-dcm__item { min-height: 40px; }
}
