/* =========================================================
   Globaler Hell/Dunkel-Ausgleich
   Wird nach den Seiten-CSS geladen und bleibt fuer Flyer
   Editor/Flyer Liste bewusst deaktiviert.
   ========================================================= */

html[data-theme="dark"]{
  color-scheme:dark;
  --global-dark-bg:#2f3a46;
  --global-dark-bg-soft:#263341;
  --global-dark-surface:#1e2a38;
  --global-dark-surface-2:#223143;
  --global-dark-surface-3:#2b3b50;
  --global-dark-border:#40546d;
  --global-dark-border-soft:#34475d;
  --global-dark-text:#f4f7fb;
  --global-dark-muted:#aebaca;
  --global-dark-faint:#7f8ea3;
  --global-dark-accent:#60a5fa;
  --global-dark-accent-2:#c084fc;
  --global-dark-green:#84bd00;
  --global-dark-danger:#fca5a5;
  --global-dark-warning:#fbbf24;
  --global-dark-shadow:0 22px 54px rgba(0,0,0,.22);
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme){
  --bg-1:var(--global-dark-bg);
  --bg-2:#303b47;
  --card:var(--global-dark-surface);
  --card-2:var(--global-dark-surface-2);
  --text:var(--global-dark-text);
  --muted:var(--global-dark-muted);
  --line:var(--global-dark-border);
  --line-2:var(--global-dark-border-soft);
  --primary-2:#1e3a5f;
  --primary-3:#203650;
  --green:#84bd00;
  --green-bg:#17351f;
  --warn:#fbbf24;
  --warn-bg:#3b2f19;
  --warn-line:#7c5f27;
  --danger:#fca5a5;
  --danger-bg:#2b1114;
  --danger-line:#7f1d1d;
  --linked-bg:#252840;
  --linked-line:#4a4f7a;
  --linked-chip:#a78bfa;
  --shadow-lg:var(--global-dark-shadow);
  --shadow-md:0 12px 28px rgba(0,0,0,.18);
  --shadow-sm:0 6px 16px rgba(0,0,0,.16);
  background:
    radial-gradient(circle at 16% 0%, rgba(132,189,0,.10), transparent 38%),
    radial-gradient(circle at 86% 16%, rgba(96,165,250,.08), transparent 34%),
    linear-gradient(180deg, #303b47 0%, var(--global-dark-bg) 100%) !important;
  color:var(--global-dark-text);
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .wrap{
  background:transparent !important;
  color:var(--global-dark-text);
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .page,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [class$="-page"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) main,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .content,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .container{
  background:transparent !important;
  color:var(--global-dark-text);
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) h1,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) h2,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) h3,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) h4,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) h5,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) h6,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) strong,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) b,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) label{
  color:var(--global-dark-text);
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) p,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) small,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .muted,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .sub,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .hint,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .meta,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .text-muted,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .subtitle{
  color:var(--global-dark-muted) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) a:not(.brand-link):not(.logout-link):not(.btn):not(.tile):not(.dashboard-ipad-alert-link){
  color:#bfdbfe;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .header,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .topbar,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .page-head,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .page-header,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .section-head,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .toolbar,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .filters,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .filterbar{
  border-color:var(--global-dark-border) !important;
  background:linear-gradient(135deg, #223142 0%, #1e2a38 100%) !important;
  color:var(--global-dark-text) !important;
  box-shadow:var(--global-dark-shadow);
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .card,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [class*="-card"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .panel,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [class*="-panel"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .box,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [class*="-box"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .tile-box,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .form-card,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .settings-card,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .detail-card,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .modal,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .modal-content,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .modal-dialog,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .acc,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) details,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) fieldset{
  border-color:var(--global-dark-border) !important;
  background:var(--global-dark-surface) !important;
  color:var(--global-dark-text) !important;
  box-shadow:var(--global-dark-shadow);
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .card-header,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .card-head,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .panel-head,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [class*="-head"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .modal-header,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) summary,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .acc-head{
  border-color:var(--global-dark-border) !important;
  background:var(--global-dark-surface-2) !important;
  color:var(--global-dark-text) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) input,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) select,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) textarea,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .input,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .search,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .search-input{
  border-color:var(--global-dark-border) !important;
  background:#172332 !important;
  color:var(--global-dark-text) !important;
  box-shadow:none;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) input::placeholder,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) textarea::placeholder{
  color:var(--global-dark-faint) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) input:focus,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) select:focus,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) textarea:focus{
  border-color:var(--global-dark-accent) !important;
  outline:0;
  box-shadow:0 0 0 4px rgba(96,165,250,.20) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) input[readonly],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) input:disabled,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) select:disabled,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) textarea:disabled{
  background:#2a394c !important;
  color:#97a6ba !important;
  border-color:#3b4f66 !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .btn,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) button:not(.theme-toggle),
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .button,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .btn-link,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .icon-btn,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .toolbar-btn{
  border-color:var(--global-dark-border) !important;
  background:var(--global-dark-surface-2) !important;
  color:var(--global-dark-text) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .btn:hover,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) button:not(.theme-toggle):hover,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .button:hover,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .btn-link:hover,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .icon-btn:hover,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .toolbar-btn:hover{
  border-color:var(--global-dark-accent) !important;
  background:var(--global-dark-surface-3) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .btn.primary,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) button.primary,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .primary,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .btn-success,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .success{
  border-color:transparent !important;
  background:linear-gradient(135deg, #2563eb 0%, #7c3aed 100%) !important;
  color:#fff !important;
  box-shadow:0 12px 26px rgba(37,99,235,.20);
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .btn.danger,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .danger,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .btn-danger{
  border-color:#7f1d1d !important;
  background:#2b1114 !important;
  color:#fecaca !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) table{
  color:var(--global-dark-text);
  border-color:var(--global-dark-border) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) th,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) thead th{
  border-color:var(--global-dark-border) !important;
  background:#1a2635 !important;
  color:#dbeafe !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) td{
  border-color:var(--global-dark-border-soft) !important;
  background:var(--global-dark-surface) !important;
  color:var(--global-dark-text) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) tbody tr:nth-child(even) td,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .row:nth-child(even){
  background:var(--global-dark-surface-2) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) tbody tr:hover td,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .row:hover{
  background:var(--global-dark-surface-3) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .table-wrap,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [class*="-table-wrap"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .table-container,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .table-responsive{
  border-color:var(--global-dark-border) !important;
  background:var(--global-dark-surface) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .badge,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .pill,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .chip,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .tag,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .count-pill{
  border-color:var(--global-dark-border) !important;
  background:var(--global-dark-surface-2) !important;
  color:var(--global-dark-text) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .alert,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .notice,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .flash-msg{
  border-color:var(--global-dark-border) !important;
  background:var(--global-dark-surface-2) !important;
  color:var(--global-dark-text) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .alert-err,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .error,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .err{
  border-color:#7f1d1d !important;
  background:#2b1114 !important;
  color:#fecaca !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .alert-ok,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .ok{
  border-color:#166534 !important;
  background:#052e1a !important;
  color:#bbf7d0 !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="background:#fff"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="background: #fff"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="background:#ffffff"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="background: #ffffff"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="background:#f8fafc"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="background: #f8fafc"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="background:#f9fafb"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="background: #f9fafb"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="background:linear-gradient"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="background: linear-gradient"]{
  background:var(--global-dark-surface) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="color:#0f172a"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="color: #0f172a"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="color:#111827"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="color: #111827"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="color:#162033"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="color: #162033"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="color:#334155"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="color: #334155"]{
  color:var(--global-dark-text) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="color:#64748b"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="color: #64748b"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="color:#6b7280"],
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [style*="color: #6b7280"]{
  color:var(--global-dark-muted) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .users-page{
  background:
    radial-gradient(circle at 16% 0%, rgba(132,189,0,.08), transparent 34%),
    radial-gradient(circle at 88% 10%, rgba(96,165,250,.08), transparent 32%),
    linear-gradient(180deg, #303b47 0%, var(--global-dark-bg) 100%) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .users-shell{
  background:transparent !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .users-topbar{
  padding:18px 20px;
  border:1px solid var(--global-dark-border);
  border-radius:22px;
  background:linear-gradient(135deg, #223142 0%, #1e2a38 100%) !important;
  box-shadow:var(--global-dark-shadow);
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .users-badge,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .back-btn,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .users-count,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .linked-count,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .collapse-chip,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .collapse-icon,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .user-id-pill,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .section-chip,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .self-chip{
  border-color:var(--global-dark-border) !important;
  background:var(--global-dark-surface-2) !important;
  color:var(--global-dark-text) !important;
  box-shadow:none !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .users-table,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .users-table tbody tr,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .users-table td{
  background:var(--global-dark-surface) !important;
  color:var(--global-dark-text) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .users-table tbody tr:nth-child(even),
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .users-table tbody tr:nth-child(even) td{
  background:var(--global-dark-surface-2) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .input-wrap,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .table-field,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .field-icon{
  border-color:var(--global-dark-border) !important;
  background:#172332 !important;
  color:var(--global-dark-muted) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .modal-backdrop,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .backdrop,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) [id*="Backdrop"]{
  background:rgba(8,13,21,.72) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) hr{
  border-color:var(--global-dark-border);
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) img,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) canvas,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) svg{
  color:inherit;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) ::selection{
  background:rgba(96,165,250,.35);
}

html[data-theme="dark"] body.login-fixed-theme{
  color-scheme:light;
}

/* =========================================================
   Header und globale Reminder bleiben bewusst im hellen Look
   ========================================================= */

html[data-theme="dark"] .site-header{
  background:
    radial-gradient(circle at top left, rgba(132,189,0,.35), transparent 35%),
    radial-gradient(circle at top right, rgba(34,197,94,.18), transparent 45%),
    linear-gradient(
      135deg,
      #1d3b0f 0%,
      #254d12 30%,
      #1f2937 70%,
      #111827 100%
    ) !important;
  color:#f8fafc !important;
  border-bottom:1px solid rgba(132,189,0,.15) !important;
  box-shadow:0 14px 40px rgba(0,0,0,.22) !important;
}

html[data-theme="dark"] .site-header .brand-link,
html[data-theme="dark"] .site-header .brand-link:hover,
html[data-theme="dark"] .site-header .brand-link:focus,
html[data-theme="dark"] .site-header .brand-link:active,
html[data-theme="dark"] .site-header .brand-link:visited{
  color:inherit !important;
  text-decoration:none !important;
}

html[data-theme="dark"] .site-header .brand-icon-wrap{
  background:rgba(255,255,255,.10) !important;
  border-color:rgba(255,255,255,.14) !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.18),
    0 10px 26px rgba(0,0,0,.25) !important;
}

html[data-theme="dark"] .site-header .user-pill,
html[data-theme="dark"] .site-header .logout-link,
html[data-theme="dark"] .site-header .theme-toggle{
  border-color:rgba(255,255,255,.18) !important;
  background:rgba(255,255,255,.10) !important;
  color:#f8fafc !important;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.12) !important;
}

html[data-theme="dark"] .reminder-overlay{
  top:74px;
  background:rgba(15,23,42,.42) !important;
  backdrop-filter:blur(7px);
}

html[data-theme="dark"] .reminder-box{
  background:#ffffff !important;
  border:1px solid rgba(15,23,42,.08) !important;
  color:#111827 !important;
  box-shadow:
    0 28px 80px rgba(15,23,42,.32),
    inset 0 1px 0 rgba(255,255,255,.75) !important;
}

html[data-theme="dark"] .reminder-title{
  color:#0f172a !important;
}

html[data-theme="dark"] .reminder-status{
  background:#f8fafc !important;
  border-color:#e5e7eb !important;
  color:#111827 !important;
}

html[data-theme="dark"] #reminderMessage{
  color:#64748b !important;
}

html[data-theme="dark"] .reminder-btn{
  border:0 !important;
}

html[data-theme="dark"] .reminder-btn.btn-green{
  background:linear-gradient(135deg, #84bd00, #6ea000) !important;
  color:#ffffff !important;
  box-shadow:0 10px 24px rgba(132,189,0,.28) !important;
}

html[data-theme="dark"] .reminder-btn.btn-gray{
  background:#e5e7eb !important;
  color:#111827 !important;
  box-shadow:none !important;
}

/* =========================================================
   Migrierte seitenbezogene Dark-Regeln
   ========================================================= */

/* =========================================================
   Migrierte Dark-Regeln: dashboard.css
   Zentralisiert aus der Seiten-CSS, per Body-Scope begrenzt.
   ========================================================= */
/* Theme-Test: Dashboard reagiert auf den Day/Dark-Schalter im Header */
html[data-theme="dark"] body.dark-scope-dashboard{
  background:#2f3844;
}

html[data-theme="dark"] body.dark-scope-dashboard .wrap{
  max-width:1600px;
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-layout{
  gap:32px;
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-head{
  margin-bottom:16px;
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-title-main{
  color:#f8fafc;
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-title-sub{
  color:#b7c4d6;
}

html[data-theme="dark"] body.dark-scope-dashboard .modules{
  gap:24px;
}

html[data-theme="dark"] body.dark-scope-dashboard .tile{
  min-height:128px;
  border:1px solid #4a5d74;
  border-radius:12px;
  background:#2b3b4f;
  color:#f8fafc;
  box-shadow:0 18px 34px rgba(15,23,42,.12);
}

html[data-theme="dark"] body.dark-scope-dashboard .tile::before{
  border-radius:12px;
  background:linear-gradient(180deg, rgba(255,255,255,.065), rgba(255,255,255,.02));
}

html[data-theme="dark"] body.dark-scope-dashboard .tile::after{
  inset:0;
  border-radius:12px;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.08);
}

html[data-theme="dark"] body.dark-scope-dashboard .tile:hover{
  transform:translateY(-2px);
  border-color:#6d829c;
  box-shadow:0 22px 42px rgba(15,23,42,.18);
  filter:none;
}

html[data-theme="dark"] body.dark-scope-dashboard .tile:hover .tile-title{
  color:#f8fafc;
  letter-spacing:0;
}

html[data-theme="dark"] body.dark-scope-dashboard .tile-icon{
  filter:drop-shadow(0 8px 18px rgba(0,0,0,.18));
}

html[data-theme="dark"] body.dark-scope-dashboard .tile:hover .tile-icon{
  transform:translateY(-1px) scale(1.02);
  filter:drop-shadow(0 10px 20px rgba(0,0,0,.20));
}

html[data-theme="dark"] body.dark-scope-dashboard .tile-title{
  color:#f8fafc;
  font-weight:850;
}

html[data-theme="dark"] body.dark-scope-dashboard .kpi-card,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-chart-card,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-top-products,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-card,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-ipad-alert{
  border:1px solid #334253;
  border-radius:12px;
  background:#182331;
  box-shadow:0 18px 34px rgba(15,23,42,.12);
}

html[data-theme="dark"] body.dark-scope-dashboard .kpi-title,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-chart-sub,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-product-sub,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-product-rank,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-sub,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-meta,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-empty,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-ipad-alert-sub,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-ipad-alert-meta,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-ipad-alert-filiale{
  color:#9fb0c6;
}

html[data-theme="dark"] body.dark-scope-dashboard .kpi-time,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-chart-title,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-top-products-title,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-product-name,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-title,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-name,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-ipad-alert-title,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-ipad-alert-name{
  color:#f8fafc;
}

html[data-theme="dark"] body.dark-scope-dashboard .kpi-value,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-product-value{
  color:#9adf70;
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-product-header,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-section + .dashboard-absence-section{
  border-color:rgba(159,176,198,.14);
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-product-header,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-section-title{
  color:#c7d2e1;
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-product-row,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-row,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-empty,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-ipad-alert-item{
  border-radius:10px;
  color:#d8e6f5;
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-product-row{
  padding:8px 10px;
  background:transparent;
  border:1px solid transparent;
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-product-row:hover{
  background:rgba(255,255,255,.035);
  border-color:rgba(159,176,198,.10);
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-row{
  border:1px solid rgba(159,176,198,.12);
  background:rgba(255,255,255,.035);
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-empty{
  border:1px dashed rgba(159,176,198,.16);
  background:rgba(255,255,255,.025);
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-product-img{
  background:#111a26;
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-count{
  background:rgba(255,255,255,.055);
  color:#d8e6f5;
  border-color:rgba(159,176,198,.12);
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-badge.is-urlaub,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-badge.is-frei{
  background:rgba(255,255,255,.045);
  color:#c7d2e1;
  border-color:rgba(159,176,198,.14);
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-absence-badge.is-krank{
  background:rgba(255,255,255,.045);
  color:#c7d2e1;
  border-color:rgba(159,176,198,.14);
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-ipad-alert-count,
html[data-theme="dark"] body.dark-scope-dashboard .dashboard-ipad-alert-battery.is-red{
  background:rgba(248,113,113,.13);
  color:#fecaca;
  border-color:rgba(248,113,113,.24);
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-ipad-alert-battery.is-yellow{
  background:rgba(251,191,36,.13);
  color:#fde68a;
  border-color:rgba(251,191,36,.24);
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-ipad-alert-link{
  color:#93c5fd;
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-ipad-alert-link:hover{
  color:#bfdbfe;
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-chart-canvas canvas{
  filter:saturate(.95);
}

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-left .tile{
    border-radius:12px;
  }

html[data-theme="dark"] body.dark-scope-dashboard .dashboard-left .tile::before,
  html[data-theme="dark"] body.dark-scope-dashboard .dashboard-left .tile::after{
    border-radius:12px;
  }

html[data-theme="dark"] body.dark-scope-dashboard .tile{
    min-height:112px;
  }

/* =========================================================
   Migrierte Dark-Regeln: artikel.css
   Zentralisiert aus der Seiten-CSS, per Body-Scope begrenzt.
   ========================================================= */
/* ############################# DARK MODE
##############################################*/

html[data-theme="dark"] body.dark-scope-artikel{
  background:#2d3743;
  color:#eef4fb;
}

html[data-theme="dark"] body.dark-scope-artikel .wrap{
  background:#2d3743;
}

html[data-theme="dark"] body.dark-scope-artikel .page-artikel,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit{
  color:#eef4fb;
}

html[data-theme="dark"] body.dark-scope-artikel .page-artikel h2,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel h3,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel h4,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit h2,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit h3,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit h4,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .header-left h2{
  color:#f8fafc;
}

html[data-theme="dark"] body.dark-scope-artikel .muted,
html[data-theme="dark"] body.dark-scope-artikel .hint,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .sub,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .hint,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .preview-meta,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .muted-inline,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .muted-empty,
html[data-theme="dark"] body.dark-scope-artikel .artikel-mobile-bottom{
  color:#aebccd !important;
}

html[data-theme="dark"] body.dark-scope-artikel .artikel-back-link,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .btn-link,
html[data-theme="dark"] body.dark-scope-artikel .toolbar-btn,
html[data-theme="dark"] body.dark-scope-artikel .toolbar-btn.ghost,
html[data-theme="dark"] body.dark-scope-artikel .count-pill,
html[data-theme="dark"] body.dark-scope-artikel .icon-btn,
html[data-theme="dark"] body.dark-scope-artikel .stammdaten-chev,
html[data-theme="dark"] body.dark-scope-artikel .form-chev{
  background:#223140;
  border-color:#405269;
  color:#eef4fb;
  box-shadow:none;
}

html[data-theme="dark"] body.dark-scope-artikel .artikel-back-link:hover,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .btn-link:hover,
html[data-theme="dark"] body.dark-scope-artikel .toolbar-btn:hover,
html[data-theme="dark"] body.dark-scope-artikel .count-pill:hover,
html[data-theme="dark"] body.dark-scope-artikel .icon-btn:hover{
  background:#2a3b4d;
  border-color:#53677f;
}

html[data-theme="dark"] body.dark-scope-artikel .toolbar-btn.primary{
  background:linear-gradient(135deg, #2f6bff 0%, #b83ad6 100%);
  border-color:rgba(255,255,255,.12);
  color:#ffffff;
  box-shadow:0 14px 30px rgba(70,105,255,.22);
}

html[data-theme="dark"] body.dark-scope-artikel .toolbar-btn.disabled,
html[data-theme="dark"] body.dark-scope-artikel .toolbar-btn-disabled{
  background:#273747;
  border-color:#3a4c61;
  color:#8392a5;
}

html[data-theme="dark"] body.dark-scope-artikel .acc,
html[data-theme="dark"] body.dark-scope-artikel .stammdaten-acc,
html[data-theme="dark"] body.dark-scope-artikel .form-acc,
html[data-theme="dark"] body.dark-scope-artikel .artikel-main-card,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .card,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .preview-panel,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .group-box,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .pfand-toggle{
  background:#172434;
  border-color:#33465d;
  box-shadow:none;
}

html[data-theme="dark"] body.dark-scope-artikel .acc .acc-body,
html[data-theme="dark"] body.dark-scope-artikel .stammdaten-body,
html[data-theme="dark"] body.dark-scope-artikel .form-body,
html[data-theme="dark"] body.dark-scope-artikel .artikel-toolbar,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .card-head,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .group-caption,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .history-table th,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .history-table td{
  border-color:#33465d;
}

html[data-theme="dark"] body.dark-scope-artikel .artikel-toolbar,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .card-head{
  background:#1b2a3a;
}

html[data-theme="dark"] body.dark-scope-artikel .stammdaten-card,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .preview-box,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .chart-wrap,
html[data-theme="dark"] body.dark-scope-artikel .quickbon-sync-box{
  background:#213143;
  border-color:#3c5068;
  box-shadow:none;
}

html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .group-box.stammdaten,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .group-box.preise,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .group-box.lieferanten,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .group-box.aktion{
  background:#1d2d3d;
  border-color:#3d526a;
}

html[data-theme="dark"] body.dark-scope-artikel input,
html[data-theme="dark"] body.dark-scope-artikel select,
html[data-theme="dark"] body.dark-scope-artikel textarea,
html[data-theme="dark"] body.dark-scope-artikel .artikel-search,
html[data-theme="dark"] body.dark-scope-artikel .stammdaten-form input,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .field input,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .field select,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .field textarea{
  background:#101b28 !important;
  border-color:#405269 !important;
  color:#eef4fb !important;
  box-shadow:none !important;
}

html[data-theme="dark"] body.dark-scope-artikel input::placeholder,
html[data-theme="dark"] body.dark-scope-artikel textarea::placeholder,
html[data-theme="dark"] body.dark-scope-artikel .artikel-search::placeholder{
  color:#7f8da0 !important;
}

html[data-theme="dark"] body.dark-scope-artikel input:focus,
html[data-theme="dark"] body.dark-scope-artikel select:focus,
html[data-theme="dark"] body.dark-scope-artikel textarea:focus,
html[data-theme="dark"] body.dark-scope-artikel .artikel-search:focus,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .field input:focus,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .field select:focus,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .field textarea:focus{
  border-color:#7fb2ff !important;
  box-shadow:0 0 0 4px rgba(73, 132, 255, .18) !important;
}

html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .field input[readonly]{
  background:#1b2938 !important;
  color:#95a3b5 !important;
}

html[data-theme="dark"] body.dark-scope-artikel .pill{
  background:#233346;
  border-color:#405269;
  color:#dbe7f5;
}

html[data-theme="dark"] body.dark-scope-artikel .pill:hover{
  background:#2a3b4d;
}

html[data-theme="dark"] body.dark-scope-artikel .count-pill.is-active{
  background:#26384c;
  border-color:#58708c;
  color:#ffffff;
}

html[data-theme="dark"] body.dark-scope-artikel .quickbon-sync-title,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .preview-label,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .preview-placeholder .big,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .field label,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .section-title,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .group-caption strong,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .chart-title,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .pfand-toggle-text strong,
html[data-theme="dark"] body.dark-scope-artikel .artikel-mobile-name,
html[data-theme="dark"] body.dark-scope-artikel .artikel-mobile-price{
  color:#f2f7fd;
}

html[data-theme="dark"] body.dark-scope-artikel .quickbon-sync-subtitle,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .preview-placeholder,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .preview-placeholder .small,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .group-caption span,
html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .pfand-toggle-text small{
  color:#aebccd;
}

html[data-theme="dark"] body.dark-scope-artikel .artikel-table-wrap{
  background:#172434;
}

html[data-theme="dark"] body.dark-scope-artikel #artikel_table thead th{
  background:#223246;
  border-bottom-color:#415773;
  color:#c6d3e3;
  box-shadow:none;
}

html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody td{
  color:#e7eef8;
  border-bottom-color:#2f4157;
  background:#172434 !important;
}

html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody tr:nth-child(even) td{
  background:#1b2938 !important;
}

html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody tr:hover{
  background:#26384c !important;
  box-shadow:none;
}

html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody tr:hover td{
  background:#26384c !important;
}

html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody td.col-ident,
html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody td.col-rohmarge,
html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody td.col-aufschlag{
  background:rgba(36, 52, 70, .92) !important;
}

html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody tr:nth-child(even) td.col-ident,
html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody tr:nth-child(even) td.col-rohmarge,
html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody tr:nth-child(even) td.col-aufschlag{
  background:rgba(41, 59, 78, .96) !important;
}

html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody td.col-actions{
  background:#26394d !important;
}

html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody tr:nth-child(even) td.col-actions{
  background:#2b4056 !important;
}

html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody tr:hover td.col-ident,
html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody tr:hover td.col-rohmarge,
html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody tr:hover td.col-aufschlag,
html[data-theme="dark"] body.dark-scope-artikel #artikel_table tbody tr:hover td.col-actions{
  background:#30465d !important;
}

html[data-theme="dark"] body.dark-scope-artikel #artikel_table thead th.sortable::after,
html[data-theme="dark"] body.dark-scope-artikel #artikel_table thead th.sort-asc::after,
html[data-theme="dark"] body.dark-scope-artikel #artikel_table thead th.sort-desc::after{
  color:#d9e5f3;
}

html[data-theme="dark"] body.dark-scope-artikel .artikel-thumb,
html[data-theme="dark"] body.dark-scope-artikel .artikel-mobile-thumb{
  border-color:#405269;
  background:#101b28;
}

html[data-theme="dark"] body.dark-scope-artikel .artikel-mobile-item{
  background:#1b2938;
  border-color:#35495f;
  box-shadow:none;
}

html[data-theme="dark"] body.dark-scope-artikel .artikel-mobile-noimage,
html[data-theme="dark"] body.dark-scope-artikel .stat-header-noimage{
  background:#101b28;
  border-color:#405269;
  color:#91a0b3;
}

html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .history-table thead tr{
  background:#223246;
}

html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .history-table th{
  color:#c6d3e3;
}

html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .history-table td{
  color:#e7eef8;
}

html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .change-up{
  color:#8ee26f;
}

html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .change-down{
  color:#ff8f8f;
}

html[data-theme="dark"] body.dark-scope-artikel .page-artikel-edit .change-flat{
  color:#aebccd;
}

html[data-theme="dark"] body.dark-scope-artikel .flash-msg{
  border-color:#415773 !important;
  background:#223246 !important;
  color:#f2f7fd !important;
}

html[data-theme="dark"] body.dark-scope-artikel .ean-dot{
  box-shadow:0 0 0 3px rgba(132,189,0,.12);
}

html[data-theme="dark"] body.dark-scope-artikel #editModalBackdrop,
html[data-theme="dark"] body.dark-scope-artikel #quickbon-log-modal{
  background:rgba(10,18,28,.68) !important;
}

html[data-theme="dark"] body.dark-scope-artikel #editModalBackdrop > div,
html[data-theme="dark"] body.dark-scope-artikel #quickbon-log-modal > div{
  background:#172434 !important;
  border-color:#33465d !important;
  box-shadow:0 30px 80px rgba(0,0,0,.28) !important;
  color:#eef4fb !important;
}

html[data-theme="dark"] body.dark-scope-artikel #editModalBackdrop [style*="border-bottom"],
html[data-theme="dark"] body.dark-scope-artikel #quickbon-log-modal [style*="border-bottom"]{
  border-bottom-color:#33465d !important;
}

html[data-theme="dark"] body.dark-scope-artikel #modalTitle,
html[data-theme="dark"] body.dark-scope-artikel #quickbon-log-modal [style*="color:#0f172a"],
html[data-theme="dark"] body.dark-scope-artikel #quickbon-log-modal [style*="color: #0f172a"]{
  color:#f8fafc !important;
}

html[data-theme="dark"] body.dark-scope-artikel #quickbon-log-modal [style*="color:#64748b"],
html[data-theme="dark"] body.dark-scope-artikel #quickbon-log-modal [style*="color: #64748b"]{
  color:#aebccd !important;
}

/* =========================================================
   Migrierte Dark-Regeln: artikel_statistik.css
   Zentralisiert aus der Seiten-CSS, per Body-Scope begrenzt.
   ========================================================= */
html[data-theme="dark"] body.dark-scope-artikel-statistik{
      background:#2d3743;
      color:#eef4fb;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .wrap{
      background:#2d3743;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit,
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit h2,
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit h3,
    html[data-theme="dark"] body.dark-scope-artikel-statistik .stat-header-title{
      color:#f8fafc;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .stat-header-card,
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .card,
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .chart-wrap,
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .group-box{
      background:#172434 !important;
      border-color:#33465d !important;
      box-shadow:none !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .card-head{
      background:#1b2a3a !important;
      border-color:#33465d !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .stat-header-sub,
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .sub,
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .muted-inline,
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .muted-empty{
      color:#aebccd !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .stat-header-thumb,
    html[data-theme="dark"] body.dark-scope-artikel-statistik .stat-header-noimage{
      background:#101b28 !important;
      border-color:#405269 !important;
      color:#91a0b3 !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .btn-link{
      background:#223140 !important;
      border-color:#405269 !important;
      color:#eef4fb !important;
      box-shadow:none !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .btn-link:hover{
      background:#2a3b4d !important;
      border-color:#53677f !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .history-table thead tr{
      background:#223246 !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .history-table th,
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .history-table td{
      border-color:#33465d !important;
      color:#e7eef8 !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .history-table th{
      color:#c6d3e3 !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .chart-title{
      color:#f2f7fd !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="background:#ffffff"],
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="background: #ffffff"],
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="background:#fff"],
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="background: #fff"],
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="background:#f8fafc"],
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="background: #f8fafc"]{
      background:#213143 !important;
      border-color:#3c5068 !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="background: linear-gradient"],
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="background:linear-gradient"]{
      background:#1d2d3d !important;
      border-color:#3d526a !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="border-top:1px solid #e5e7eb"]{
      border-top-color:#33465d !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="color:#0f172a"],
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="color: #0f172a"],
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="color:#334155"],
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="color: #334155"],
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="color:#374151"],
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="color: #374151"]{
      color:#f2f7fd !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="color:#6b7280"],
    html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit [style*="color: #6b7280"]{
      color:#aebccd !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .change-up{
      color:#8ee26f !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .change-down{
      color:#ff8f8f !important;
    }

html[data-theme="dark"] body.dark-scope-artikel-statistik .page-artikel-edit .change-flat{
      color:#aebccd !important;
    }

/* =========================================================
   Migrierte Dark-Regeln: verbrauch.css
   Zentralisiert aus der Seiten-CSS, per Body-Scope begrenzt.
   ========================================================= */
/* Dark Mode */
html[data-theme="dark"] body.dark-scope-verbrauch{
  background:#2d3743;
  color:#eef4fb;
}

html[data-theme="dark"] body.dark-scope-verbrauch .wrap{
  background:#2d3743;
}

html[data-theme="dark"] body.dark-scope-verbrauch .page{
  color:#eef4fb;
}

html[data-theme="dark"] body.dark-scope-verbrauch .header,
html[data-theme="dark"] body.dark-scope-verbrauch .card,
html[data-theme="dark"] body.dark-scope-verbrauch .logs-page-head,
html[data-theme="dark"] body.dark-scope-verbrauch .month-card,
html[data-theme="dark"] body.dark-scope-verbrauch .modal{
  background:#172434;
  border-color:#33465d;
  box-shadow:none;
}

html[data-theme="dark"] body.dark-scope-verbrauch .header{
  background:linear-gradient(180deg, #1f2e3f 0%, #172434 100%);
}

html[data-theme="dark"] body.dark-scope-verbrauch .fuel-form .card{
  background:linear-gradient(180deg, #1f2e3f 0%, #172434 100%);
}

html[data-theme="dark"] body.dark-scope-verbrauch .header-left h2,
html[data-theme="dark"] body.dark-scope-verbrauch .card h3,
html[data-theme="dark"] body.dark-scope-verbrauch .month-card-title,
html[data-theme="dark"] body.dark-scope-verbrauch .modal-title,
html[data-theme="dark"] body.dark-scope-verbrauch .print-modal-value,
html[data-theme="dark"] body.dark-scope-verbrauch .month-sum-row .month-liter-sum{
  color:#f8fafc;
}

html[data-theme="dark"] body.dark-scope-verbrauch .header-left .sub,
html[data-theme="dark"] body.dark-scope-verbrauch .field label,
html[data-theme="dark"] body.dark-scope-verbrauch .table-meta,
html[data-theme="dark"] body.dark-scope-verbrauch .muted,
html[data-theme="dark"] body.dark-scope-verbrauch .chart-label,
html[data-theme="dark"] body.dark-scope-verbrauch .line-chart-legend,
html[data-theme="dark"] body.dark-scope-verbrauch .modal-sub,
html[data-theme="dark"] body.dark-scope-verbrauch .print-modal-label{
  color:#aebccd;
}

html[data-theme="dark"] body.dark-scope-verbrauch .btn-link,
html[data-theme="dark"] body.dark-scope-verbrauch .btn,
html[data-theme="dark"] body.dark-scope-verbrauch .scan-link,
html[data-theme="dark"] body.dark-scope-verbrauch .icon-btn{
  background:#223140;
  border-color:#405269;
  color:#eef4fb;
  box-shadow:none;
}

html[data-theme="dark"] body.dark-scope-verbrauch .btn-link:hover,
html[data-theme="dark"] body.dark-scope-verbrauch .btn:hover,
html[data-theme="dark"] body.dark-scope-verbrauch .scan-link:hover,
html[data-theme="dark"] body.dark-scope-verbrauch .icon-btn:hover{
  background:#2a3b4d;
  border-color:#53677f;
}

html[data-theme="dark"] body.dark-scope-verbrauch .btn.primary{
  background:linear-gradient(135deg, #2f6bff 0%, #84bd00 100%);
  border-color:rgba(255,255,255,.14);
  color:#ffffff;
  box-shadow:0 14px 30px rgba(47,107,255,.18);
}

html[data-theme="dark"] body.dark-scope-verbrauch .btn-ghost{
  background:#223140;
}

html[data-theme="dark"] body.dark-scope-verbrauch .field input,
html[data-theme="dark"] body.dark-scope-verbrauch .field select,
html[data-theme="dark"] body.dark-scope-verbrauch .table-search{
  background:#101b28;
  border-color:#405269;
  color:#eef4fb;
}

html[data-theme="dark"] body.dark-scope-verbrauch .field input::placeholder,
html[data-theme="dark"] body.dark-scope-verbrauch .table-search::placeholder{
  color:#7f8da0;
}

html[data-theme="dark"] body.dark-scope-verbrauch .field input:focus,
html[data-theme="dark"] body.dark-scope-verbrauch .field select:focus,
html[data-theme="dark"] body.dark-scope-verbrauch .table-search:focus{
  border-color:#7fb2ff;
  box-shadow:0 0 0 4px rgba(73,132,255,.18);
}

html[data-theme="dark"] body.dark-scope-verbrauch .guard-card{
  background:linear-gradient(180deg, #3b2f19 0%, #2d2618 100%);
  border-color:#b7791f;
  box-shadow:none;
}

html[data-theme="dark"] body.dark-scope-verbrauch .guard-title{
  color:#ffe7a3;
}

html[data-theme="dark"] body.dark-scope-verbrauch .guard-text{
  color:#f8d88a;
}

html[data-theme="dark"] body.dark-scope-verbrauch .chart-header,
html[data-theme="dark"] body.dark-scope-verbrauch .month-card-head,
html[data-theme="dark"] body.dark-scope-verbrauch .modal-head{
  border-color:#33465d;
}

html[data-theme="dark"] body.dark-scope-verbrauch .chart-header,
html[data-theme="dark"] body.dark-scope-verbrauch .modal-head{
  background:#1b2a3a;
}

html[data-theme="dark"] body.dark-scope-verbrauch .chart-bar-wrap{
  background:#101b28;
}

html[data-theme="dark"] body.dark-scope-verbrauch .chart-bar{
  background:linear-gradient(90deg,#2f6bff,#84bd00);
}

html[data-theme="dark"] body.dark-scope-verbrauch .month-card-kicker{
  color:#93c5fd;
}

html[data-theme="dark"] body.dark-scope-verbrauch .month-card-badge{
  background:#223140;
  border-color:#405269;
  color:#dbeafe;
  box-shadow:none;
}

html[data-theme="dark"] body.dark-scope-verbrauch .month-table-wrap,
html[data-theme="dark"] body.dark-scope-verbrauch .print-modal-box,
html[data-theme="dark"] body.dark-scope-verbrauch .print-month-item{
  background:#101b28;
  border-color:#33465d;
}

html[data-theme="dark"] body.dark-scope-verbrauch .veh-table th,
html[data-theme="dark"] body.dark-scope-verbrauch .veh-table td{
  border-bottom-color:#2f4157;
}

html[data-theme="dark"] body.dark-scope-verbrauch .veh-table thead th,
html[data-theme="dark"] body.dark-scope-verbrauch .month-table thead th{
  background:#223246;
  color:#c6d3e3;
}

html[data-theme="dark"] body.dark-scope-verbrauch .veh-table tbody tr:nth-child(odd){
  background:#172434;
}

html[data-theme="dark"] body.dark-scope-verbrauch .veh-table tbody tr:nth-child(even){
  background:#1b2938;
}

html[data-theme="dark"] body.dark-scope-verbrauch .veh-table tbody tr:hover{
  background:#26384c;
}

html[data-theme="dark"] body.dark-scope-verbrauch .veh-table tbody tr.log-row-high,
html[data-theme="dark"] body.dark-scope-verbrauch .veh-table tbody tr.log-row-high:nth-child(odd){
  background:#3d2630 !important;
}

html[data-theme="dark"] body.dark-scope-verbrauch .veh-table tbody tr.log-row-high:hover{
  background:#4b2b38 !important;
}

html[data-theme="dark"] body.dark-scope-verbrauch .month-sum-row td{
  background:#223246;
  border-top-color:#405269;
}

html[data-theme="dark"] body.dark-scope-verbrauch .suggestions{
  background:#172434;
  border-color:#405269;
  box-shadow:0 18px 40px rgba(0,0,0,.24);
}

html[data-theme="dark"] body.dark-scope-verbrauch .suggestion-item{
  color:#eef4fb;
}

html[data-theme="dark"] body.dark-scope-verbrauch .suggestion-item:hover,
html[data-theme="dark"] body.dark-scope-verbrauch .suggestion-item.active{
  background:#26384c;
}

html[data-theme="dark"] body.dark-scope-verbrauch .modal-backdrop{
  background:rgba(10,18,28,.72);
}

html[data-theme="dark"] body.dark-scope-verbrauch .print-month-item-label{
  color:#eef4fb;
}

html[data-theme="dark"] body.dark-scope-verbrauch .chartjs-wrap canvas{
  filter:none;
}

/* =========================================================
   Migrierte Dark-Regeln: attendance.css
   Zentralisiert aus der Seiten-CSS, per Body-Scope begrenzt.
   ========================================================= */
html[data-theme="dark"]{
  --att-page:#2f3a46;
  --att-surface:#1e2a38;
  --att-surface-soft:#223143;
  --att-surface-subtle:#2b3b50;
  --att-border:#40546d;
  --att-border-strong:#536984;
  --att-text:#f3f7fb;
  --att-muted:#aab7c8;
  --att-soft-text:#d7dee8;
  --att-head:#14202d;
  --att-head-2:#1b2a3a;
  --att-accent:#60a5fa;
  --att-accent-2:#c084fc;
  --att-accent-soft:rgba(96,165,250,.16);
  --att-ring:rgba(96,165,250,.24);
  --att-shadow:0 22px 54px rgba(0,0,0,.22);
  --att-shadow-soft:0 12px 28px rgba(0,0,0,.18);
  --att-row:#1f2d3d;
  --att-row-alt:#243448;
  --att-row-hover:#2c4057;
  --att-input:#172332;
  --att-input-disabled:#2a394c;
  --att-weekend:#3a2730;
  --att-weekend-2:#432b34;
  --att-weekend-border:#76515b;
  --att-weekend-text:#fecdd3;
  --att-today:#213d5b;
  --att-today-ring:#7dd3fc;
  --att-ok:#86efac;
  --att-danger:#fca5a5;
  --att-warning:#fbbf24;
  --att-neutral:#cbd5e1;
  --att-info:#67e8f9;
}

html[data-theme="dark"] body.dark-scope-attendance,
html[data-theme="dark"] body.dark-scope-attendance .wrap{
  background:var(--att-page);
}

html[data-theme="dark"] body.dark-scope-attendance .page > .header{
  background:linear-gradient(135deg, #223142 0%, #1e2a38 100%);
}

html[data-theme="dark"] body.dark-scope-attendance .att-table thead th{
  border-bottom-color:#50647d;
}

html[data-theme="dark"] body.dark-scope-attendance .att-table td,
html[data-theme="dark"] body.dark-scope-attendance .att-table th{
  border-color:var(--att-border);
}

html[data-theme="dark"] body.dark-scope-attendance .page .btn.primary,
html[data-theme="dark"] body.dark-scope-attendance .month-pill__btn{
  color:#ffffff;
  box-shadow:0 12px 26px rgba(96,165,250,.16);
}

html[data-theme="dark"] body.dark-scope-attendance em{
  color:var(--att-muted);
}

/* =========================================================
   Dark-Feinschliff: hellerer, ruhigerer App-Dark-Mode
   ========================================================= */
html[data-theme="dark"]{
  --global-dark-bg:#344250;
  --global-dark-bg-soft:#3b4957;
  --global-dark-surface:#263646;
  --global-dark-surface-2:#304153;
  --global-dark-surface-3:#3b5065;
  --global-dark-border:#51677f;
  --global-dark-border-soft:#41566d;
  --global-dark-text:#f8fafc;
  --global-dark-muted:#c5cfdb;
  --global-dark-faint:#9caabc;
  --global-dark-shadow:0 18px 42px rgba(9,15,24,.18);
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme){
  --bg-1:#344250;
  --bg-2:#3b4957;
  --card:#263646;
  --card-2:#304153;
  --text:#f8fafc;
  --muted:#c5cfdb;
  --line:#51677f;
  --line-2:#41566d;
  background:
    radial-gradient(circle at 10% 0%, rgba(132,189,0,.08), transparent 35%),
    radial-gradient(circle at 88% 10%, rgba(96,165,250,.07), transparent 34%),
    linear-gradient(180deg, #3b4957 0%, #344250 100%) !important;
}

/* Statusfarben duerfen im Dark Mode nicht neutralisiert werden. */
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .badge-green,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .status-green,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .status-ok,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .status-active,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .pill.status-active{
  background:#dcfce7 !important;
  border-color:#86efac !important;
  color:#166534 !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .badge-yellow,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .badge-orange,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .status-yellow,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .status-orange,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .status-warn,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .warning{
  background:#fef3c7 !important;
  border-color:#fbbf24 !important;
  color:#92400e !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .badge-red,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .status-red,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .status-danger,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .status-error{
  background:#fee2e2 !important;
  border-color:#fca5a5 !important;
  color:#991b1b !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .badge-gray,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .status-gray,
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .status-inactive{
  background:#e2e8f0 !important;
  border-color:#cbd5e1 !important;
  color:#334155 !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .ping-green{ color:#86efac !important; }
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .ping-orange{ color:#fbbf24 !important; }
html[data-theme="dark"] body:not(.flyer-fixed-theme):not(.login-fixed-theme) .ping-red{ color:#fca5a5 !important; }

/* Reminder bewusst als ruhiges helles Dialogfenster lassen. */
html[data-theme="dark"] body:not(.flyer-fixed-theme) .reminder-overlay{
  top:74px;
  background:rgba(31,42,56,.28) !important;
  backdrop-filter:blur(5px) saturate(1.02);
}

html[data-theme="dark"] body:not(.flyer-fixed-theme) .reminder-box{
  max-width:640px;
  background:linear-gradient(180deg, #ffffff 0%, #f8fafc 100%) !important;
  border:1px solid rgba(15,23,42,.12) !important;
  color:#111827 !important;
  box-shadow:0 26px 72px rgba(15,23,42,.26) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme) .reminder-box *,
html[data-theme="dark"] body:not(.flyer-fixed-theme) .reminder-title{
  color:#111827 !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme) .reminder-status{
  background:#ffffff !important;
  border:1px solid #e2e8f0 !important;
  color:#111827 !important;
  box-shadow:0 5px 14px rgba(15,23,42,.06) !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme) #reminderMessage{
  color:#64748b !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme) .reminder-btn.btn-green{
  background:linear-gradient(135deg, #84bd00 0%, #16a34a 100%) !important;
  color:#ffffff !important;
}

html[data-theme="dark"] body:not(.flyer-fixed-theme) .reminder-btn.btn-gray{
  background:#e2e8f0 !important;
  color:#111827 !important;
}

/* =========================================================
   Urlaub: Hellmodus in ruhigen Dark Mode uebersetzen
   ========================================================= */
html[data-theme="dark"] body.dark-scope-urlaub,
html[data-theme="dark"] body.dark-scope-urlaub .wrap{
  background:
    radial-gradient(circle at 8% 0%, rgba(132,189,0,.07), transparent 34%),
    linear-gradient(180deg, #3b4957 0%, #344250 100%) !important;
}

html[data-theme="dark"] body.dark-scope-urlaub .page-head,
html[data-theme="dark"] body.dark-scope-urlaub .quick-months,
html[data-theme="dark"] body.dark-scope-urlaub .month-actions-bar,
html[data-theme="dark"] body.dark-scope-urlaub .card,
html[data-theme="dark"] body.dark-scope-urlaub .m-card,
html[data-theme="dark"] body.dark-scope-urlaub .tl-card{
  background:var(--global-dark-surface) !important;
  border-color:var(--global-dark-border) !important;
  color:var(--global-dark-text) !important;
  box-shadow:var(--global-dark-shadow) !important;
}

html[data-theme="dark"] body.dark-scope-urlaub .quick-month-btn{
  background:#f8fafc !important;
  border-color:#dbe2ea !important;
  color:#1e293b !important;
}

html[data-theme="dark"] body.dark-scope-urlaub .quick-month-btn.active{
  background:linear-gradient(135deg, #84bd00 0%, #6ca100 100%) !important;
  border-color:#84bd00 !important;
  color:#ffffff !important;
}

html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid,
html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid th,
html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid td{
  border-color:#52687f !important;
}

html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid thead th,
html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid th.sticky-left,
html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid td.sticky-left{
  background:#223142 !important;
  color:#f8fafc !important;
}

html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid th.sticky-metric,
html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid td.sticky-metric,
html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid th.m1,
html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid td.m1,
html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid th.m2,
html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid td.m2,
html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid th.m3,
html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid td.m3{
  background:#304153 !important;
  color:#eef4fb !important;
}

html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid th.day-total-col{
  background:#3b5065 !important;
  color:#f8fafc !important;
  border-bottom-color:#6b8199 !important;
}

html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid th.day-total-col .day-total-num{
  color:#f8fafc !important;
}

html[data-theme="dark"] body.dark-scope-urlaub th.we,
html[data-theme="dark"] body.dark-scope-urlaub td.we,
html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid th.we{
  background:#4b3340 !important;
  color:#fecdd3 !important;
}

html[data-theme="dark"] body.dark-scope-urlaub table.urlaub-grid th.we span{
  color:#fecdd3 !important;
}

html[data-theme="dark"] body.dark-scope-urlaub td.cell.is-empty{
  background:#f8fafc !important;
  color:#1e293b !important;
}

html[data-theme="dark"] body.dark-scope-urlaub td.cell.is-u,
html[data-theme="dark"] body.dark-scope-urlaub td.cell.st-u{
  background:#c9f2df !important;
  color:#064e3b !important;
}

html[data-theme="dark"] body.dark-scope-urlaub td.cell.is-f,
html[data-theme="dark"] body.dark-scope-urlaub td.cell.st-f{
  background:#cfe9ff !important;
  color:#0b4a6f !important;
}

html[data-theme="dark"] body.dark-scope-urlaub td.cell.is-k,
html[data-theme="dark"] body.dark-scope-urlaub td.cell.is-kk{
  background:#fde2e2 !important;
  color:#7f1d1d !important;
}

html[data-theme="dark"] body.dark-scope-urlaub td.cell.is-locked{
  background:#405267 !important;
  color:#dbe4ef !important;
}

html[data-theme="dark"] body.dark-scope-urlaub .hm-wd,
html[data-theme="dark"] body.dark-scope-urlaub .hm-legend,
html[data-theme="dark"] body.dark-scope-urlaub .tl-range{
  color:#c5cfdb !important;
}

html[data-theme="dark"] body.dark-scope-urlaub .hm-cell{
  background:#f8fafc !important;
  border-color:#dbe2ea !important;
}

html[data-theme="dark"] body.dark-scope-urlaub .hm-cell.is-empty{
  background:#51606f !important;
  border-color:#667789 !important;
}

html[data-theme="dark"] body.dark-scope-urlaub .hm-day{
  color:#111827 !important;
}

html[data-theme="dark"] body.dark-scope-urlaub .tl-name,
html[data-theme="dark"] body.dark-scope-urlaub .m-sheet-title,
html[data-theme="dark"] body.dark-scope-urlaub .m-row2 .n{
  color:#f8fafc !important;
}

html[data-theme="dark"] body.dark-scope-urlaub .hm-badge.u,
html[data-theme="dark"] body.dark-scope-urlaub .tl-status.u{ background:#c9f2df !important; color:#064e3b !important; }
html[data-theme="dark"] body.dark-scope-urlaub .hm-badge.f,
html[data-theme="dark"] body.dark-scope-urlaub .tl-status.f{ background:#cfe9ff !important; color:#0b4a6f !important; }
html[data-theme="dark"] body.dark-scope-urlaub .hm-badge.k,
html[data-theme="dark"] body.dark-scope-urlaub .tl-status.k{ background:#ffd6d6 !important; color:#7f1d1d !important; }
html[data-theme="dark"] body.dark-scope-urlaub .hm-badge.kk,
html[data-theme="dark"] body.dark-scope-urlaub .tl-status.kk{ background:#ffe9b5 !important; color:#854d0e !important; }

html[data-theme="dark"] body.dark-scope-urlaub .tl-card,
html[data-theme="dark"] body.dark-scope-urlaub .m-sheet,
html[data-theme="dark"] body.dark-scope-urlaub .m-sheet-head,
html[data-theme="dark"] body.dark-scope-urlaub .m-row2{
  background:var(--global-dark-surface-2) !important;
  border-color:var(--global-dark-border) !important;
}

/* =========================================================
   Filialen: Karten und Tabellen ruhiger im Dark Mode
   ========================================================= */
html[data-theme="dark"] body.dark-scope-filialen,
html[data-theme="dark"] body.dark-scope-filialen .wrap,
html[data-theme="dark"] body.dark-scope-filialen .fi-page{
  background:
    radial-gradient(circle at 12% 0%, rgba(132,189,0,.08), transparent 36%),
    linear-gradient(180deg, #3b4957 0%, #344250 100%) !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-header,
html[data-theme="dark"] body.dark-scope-filialen .fi-card,
html[data-theme="dark"] body.dark-scope-filialen .fi-section,
html[data-theme="dark"] body.dark-scope-filialen .fi-kpi,
html[data-theme="dark"] body.dark-scope-filialen .fi-tile,
html[data-theme="dark"] body.dark-scope-filialen .fi-empty{
  background:var(--global-dark-surface) !important;
  border-color:var(--global-dark-border) !important;
  color:var(--global-dark-text) !important;
  box-shadow:var(--global-dark-shadow) !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-card-head,
html[data-theme="dark"] body.dark-scope-filialen .fi-section-head{
  background:var(--global-dark-surface-2) !important;
  border-color:var(--global-dark-border) !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-tile:not(.active){
  background:#f8fafc !important;
  border-color:#e2e8f0 !important;
  color:#0f172a !important;
  box-shadow:0 8px 22px rgba(15,23,42,.10) !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-tile:not(.active) .fi-tile-name,
html[data-theme="dark"] body.dark-scope-filialen .fi-tile:not(.active) .fi-meta,
html[data-theme="dark"] body.dark-scope-filialen .fi-tile:not(.active) .fi-meta *,
html[data-theme="dark"] body.dark-scope-filialen .fi-tile:not(.active) .fi-tile-code{
  color:#1e293b !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-tile.active{
  background:linear-gradient(180deg, rgba(34,197,94,.16) 0%, rgba(34,197,94,.08) 100%) !important;
  border-color:#22c55e !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-kpi{
  background:#f8fafc !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-kpi-label,
html[data-theme="dark"] body.dark-scope-filialen .fi-kpi-note{
  color:#64748b !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-kpi-value{
  color:#0f172a !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-table{
  background:var(--global-dark-surface) !important;
  border-color:var(--global-dark-border) !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-table thead th{
  background:#223142 !important;
  color:#f8fafc !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-table tbody td{
  background:#263646 !important;
  color:#f8fafc !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-table tbody tr:nth-child(even) td{
  background:#304153 !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-table tbody tr:hover td{
  background:#3b5065 !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-badge{
  background:#dcfce7 !important;
  border-color:#86efac !important;
  color:#166534 !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-badge.warn{
  background:#fef3c7 !important;
  border-color:#fbbf24 !important;
  color:#92400e !important;
}

html[data-theme="dark"] body.dark-scope-filialen .fi-btn.primary{
  background:linear-gradient(135deg, #84bd00 0%, #16a34a 100%) !important;
  color:#ffffff !important;
}

/* =========================================================
   iPad-Status: Ampelfarben wie im Hellmodus erhalten
   ========================================================= */
html[data-theme="dark"] body.dark-scope-ipads .page-head,
html[data-theme="dark"] body.dark-scope-ipads .card,
html[data-theme="dark"] body.dark-scope-ipads .stat-card,
html[data-theme="dark"] body.dark-scope-ipads .refresh-card{
  background:var(--global-dark-surface) !important;
  border-color:var(--global-dark-border) !important;
}

html[data-theme="dark"] body.dark-scope-ipads .mobile-ipad-card{
  border-color:var(--global-dark-border) !important;
  background:var(--global-dark-surface) !important;
}

html[data-theme="dark"] body.dark-scope-ipads .badge-green{ background:#dcfce7 !important; color:#166534 !important; border-color:#86efac !important; }
html[data-theme="dark"] body.dark-scope-ipads .badge-yellow{ background:#fef9c3 !important; color:#854d0e !important; border-color:#fde047 !important; }
html[data-theme="dark"] body.dark-scope-ipads .badge-orange{ background:#ffedd5 !important; color:#9a3412 !important; border-color:#fdba74 !important; }
html[data-theme="dark"] body.dark-scope-ipads .badge-red{ background:#fee2e2 !important; color:#991b1b !important; border-color:#fca5a5 !important; }
html[data-theme="dark"] body.dark-scope-ipads .badge-gray{ background:#e2e8f0 !important; color:#334155 !important; border-color:#cbd5e1 !important; }
