@charset "UTF-8";
/* Modo oscuro — azul eléctrico.
   El claro no se toca: estas reglas solo aplican con html[data-theme="dark"].
   La especificidad está armada para ganarles a los !important del tema claro. */

html[data-theme="dark"] {
    --pastel-bg: #070d18;
    --pastel-bg-2: #0c1424;
    --pastel-surface: #101c30;
    --pastel-surface-2: #15263c;
    --pastel-border: rgba(148, 163, 184, 0.12);
    --pastel-border-strong: rgba(148, 163, 184, 0.2);
    --pastel-rose: #3ec5ff;
    --pastel-rose-light: #123056;
    --pastel-rose-deep: #5ad4ff;
    --pastel-sage: #3ec5ff;
    --pastel-sage-light: #10283a;
    --pastel-sage-deep: #2f7dff;
    --pastel-peach: #16324f;
    --pastel-lavender: #152844;
    --pastel-text: #e7f2ff;
    --pastel-text-muted: #8eb0d4;
    --pastel-text-light: #6d8eaf;
    --pastel-success-bg: #0e2c28;
    --pastel-warning-bg: #2a2410;
    --pastel-danger-bg: #3a1820;
    --pastel-info-bg: #102844;
    --dt-body: #0e1726;
    --dt-head: #163a86;
    --dt-head-b: rgba(148, 163, 184, 0.08);
    --dt-row: #0e1726;
    --dt-row-zebra: #122033;
    --dt-row-zebra2: #101c2e;
    --dt-row-hover: #183456;
    --dt-row-selected: 24, 64, 120;
    --dt-row-selected-text: 231, 242, 255;
    --dt-row-selected-link: 94, 210, 255;
    --dt-text: #e7f2ff;
    --dt-input: #0a1220;
    --dt-input-b: rgba(148, 163, 184, 0.16);
    --dt-pag-bg: #101c30;
    --dt-pag-active: #2f7dff;
    --rp-dt-bg: #0e1726;
    --rp-dt-border: rgba(148, 163, 184, 0.1);
    --rp-dt-head: #1a4fd0;
    --rp-dt-head-text: #f4f8ff;
    --rp-dt-row-a: #0e1726;
    --rp-dt-row-b: #122033;
    --rp-dt-hover: #183456;
    --rp-dt-selected: #1a3f78;
    --rp-dt-selected-strong: #1e4d92;
    --rp-dt-accent: #3ec5ff;
    --rp-dt-pag-active: #2f7dff;
    --kyo-text: #e7f2ff;
    --kyo-text-muted: #8eb0d4;
    --kyo-border: rgba(148, 163, 184, 0.12);
    --text: #e7f2ff;
    --muted: #8eb0d4;
    --bg: #070d18;
    --panel: #101c30;
    color-scheme: dark;
}

html[data-theme="dark"] body {
    background:
        radial-gradient(ellipse 70% 50% at 0% 0%, rgba(47, 125, 255, 0.16) 0%, transparent 52%),
        radial-gradient(ellipse 55% 40% at 100% 0%, rgba(62, 197, 255, 0.1) 0%, transparent 48%),
        linear-gradient(180deg, #070d18 0%, #0a1222 55%, #08101c 100%) !important;
    color: #e7f2ff !important;
}

html[data-theme="dark"] :is(h1, h2, h3, h4, h5, h6, .form-label, .rp-label) {
    color: #e7f2ff;
}

/* ---- Superficies generales ---- */
html[data-theme="dark"] :is(
    .card, .card-body, .card-header, .card-footer,
    .card-glass, .list-group-item, .accordion-item, .accordion-button,
    .offcanvas, .toast, .popover, .dropdown-menu
) {
    background-color: #101c30 !important;
    color: #e7f2ff !important;
    border-color: rgba(110, 186, 255, 0.16) !important;
}
html[data-theme="dark"] .accordion-button:not(.collapsed) {
    background: #163056 !important;
    color: #7ad7ff !important;
}
html[data-theme="dark"] :is(.bg-white, .bg-light, .bg-body) {
    background-color: #101c30 !important;
    color: #e7f2ff !important;
}
html[data-theme="dark"] :is(.text-dark, .text-body, .text-muted, .text-muted-cc) {
    color: #8eb0d4 !important;
}

html[data-theme="dark"] :is(
    .form-control, .form-select, .rp-input, .form-control:focus, .form-select:focus,
    input[type="text"], input[type="search"], input[type="number"], input[type="email"],
    input[type="password"], input[type="date"], textarea, select
) {
    background-color: #0a1220 !important;
    color: #e7f2ff !important;
    border-color: rgba(110, 186, 255, 0.28) !important;
}
html[data-theme="dark"] :is(.form-control, input, textarea)::placeholder { color: #6d8eaf; }

html[data-theme="dark"] :is(.cc-header, .cc-stat, .cc-badge, [class*="-hero"], .cc-header-link) {
    background: linear-gradient(135deg, #101c30 0%, #163056 55%, #10283a 100%) !important;
    color: #e7f2ff !important;
    border-color: rgba(62, 197, 255, 0.28) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] :is(.cc-header, .cc-header-link, [class*="-hero"]) :is(h1, h2, h3, h4, p, .cc-header-link-title) {
    color: #e7f2ff !important;
}
html[data-theme="dark"] .cc-header-link-sub,
html[data-theme="dark"] .cc-stat .label { color: #8eb0d4 !important; }
html[data-theme="dark"] .cc-stat .value,
html[data-theme="dark"] .cc-badge { color: #7ad7ff !important; }
html[data-theme="dark"] .cc-header-link-chevron {
    background: #0e1726 !important;
    color: #7ad7ff !important;
    border-color: rgba(62, 197, 255, 0.3) !important;
}
html[data-theme="dark"] .btn-new,
html[data-theme="dark"] .btn-new:hover {
    background: linear-gradient(135deg, #2f7dff, #1a4fd0) !important;
    color: #fff !important;
    box-shadow: 0 6px 18px rgba(47, 125, 255, 0.35) !important;
}

html[data-theme="dark"] .ts-page,
html[data-theme="dark"] .ts-modal,
html[data-theme="dark"] .kyo-hub {
    --oa-ink: #e7f2ff;
    --oa-muted: #8eb0d4;
    --oa-surface: #101c30;
    --oa-cream: #0c1424;
    --oa-border: rgba(110, 186, 255, 0.16);
    --oa-gold: #3ec5ff;
    --oa-gold-soft: #123056;
    --oa-gold-deep: #7ad7ff;
    --oa-sage: #2f7dff;
    --oa-sage-soft: #10283a;
    --oa-sage-mid: #1a4a78;
}

html[data-theme="dark"] :is(
    .ts-card, .ts-panel, .ts-kpi, .ts-tile, .ts-box, .ts-note,
    .rp-data-card, .cg-data-card, .rp-config-card, .rp-list-item,
    .rp-edit-panel, .rp-search-box, .rp-config-view-section
) {
    background: #101c30 !important;
    color: #e7f2ff !important;
    border-color: rgba(110, 186, 255, 0.16) !important;
}
html[data-theme="dark"] .rp-config-sub { color: #8eb0d4; }
html[data-theme="dark"] .rp-config-card:hover,
html[data-theme="dark"] .rp-config-card.is-active,
html[data-theme="dark"] .rp-config-view-card.is-active {
    background: #163056 !important;
    border-color: rgba(62, 197, 255, 0.4) !important;
}

/* ---- Grillas: el bloque blanco, el encabezado rosa y los filtros ---- */
html[data-theme="dark"] .dt-dark-wrap,
html[data-theme="dark"] .rp-table-wrap,
html[data-theme="dark"] .rp-grid-panel,
html[data-theme="dark"] .dataTables_wrapper,
html[data-theme="dark"] .dt-dark-wrap > .dataTables_wrapper,
html[data-theme="dark"] .rp-table-wrap > .dataTables_wrapper {
    background: #0e1726 !important;
    color: #e7f2ff !important;
    border: 0 !important;
    border-color: transparent !important;
    box-shadow: none !important;
}

html[data-theme="dark"] .dt-dark thead tr:first-child th,
html[data-theme="dark"] .dt-dark thead th,
html[data-theme="dark"] .dt-dark thead td,
html[data-theme="dark"] table.dataTable thead th,
html[data-theme="dark"] table.dataTable.dt-dark thead > tr:first-child > th,
html[data-theme="dark"] table.dataTable thead > tr > th {
    background: linear-gradient(180deg, #1d5bff 0%, #123a9a 100%) !important;
    color: #f4f8ff !important;
    border-color: rgba(90, 180, 255, 0.35) !important;
}
html[data-theme="dark"] .dt-dark thead tr.filters th,
html[data-theme="dark"] table.dataTable thead tr.filters th,
html[data-theme="dark"] table.dataTable.dt-dark thead tr.filters th {
    background: #0c1628 !important;
    color: #8eb0d4 !important;
    border-bottom-color: rgba(110, 186, 255, 0.16) !important;
}

html[data-theme="dark"] table.dataTable.display tbody tr td,
html[data-theme="dark"] table.dataTable.stripe tbody tr td,
html[data-theme="dark"] table.dt-dark tbody tr td,
html[data-theme="dark"] .dt-dark tbody td,
html[data-theme="dark"] table.dataTable tbody td,
html[data-theme="dark"] .ts-page table.dt-dark tbody td,
html[data-theme="dark"] .ts-page table.dataTable tbody td,
html[data-theme="dark"] .ts-page table.dt-dark tbody tr:nth-child(odd) td,
html[data-theme="dark"] .ts-page table.dt-dark tbody tr:nth-child(even) td {
    background: #0e1726 !important;
    background-color: #0e1726 !important;
    color: #e7f2ff !important;
    border-color: rgba(110, 186, 255, 0.08) !important;
}
html[data-theme="dark"] table.dataTable.display tbody tr:nth-child(even) td,
html[data-theme="dark"] table.dataTable.stripe tbody tr.even td,
html[data-theme="dark"] table.dt-dark tbody tr:nth-child(even) td,
html[data-theme="dark"] .dt-dark.display tbody tr:nth-child(even) td,
html[data-theme="dark"] table.dataTable.display tbody tr > .sorting_1,
html[data-theme="dark"] table.dataTable.display tbody tr > .sorting_2,
html[data-theme="dark"] table.dataTable.display tbody tr > .sorting_3 {
    background: #122033 !important;
    background-color: #122033 !important;
}
html[data-theme="dark"] table.dataTable tbody tr:hover td,
html[data-theme="dark"] table.dt-dark tbody tr:hover td,
html[data-theme="dark"] .dt-dark tbody tr:hover td,
html[data-theme="dark"] .ts-page table.dataTable tbody tr:hover td {
    background: #183456 !important;
    background-color: #183456 !important;
}
html[data-theme="dark"] table.dt-dark tbody tr.dt-row-selected > *,
html[data-theme="dark"] table.dataTable tbody tr.dt-row-selected > *,
html[data-theme="dark"] table.dataTable tbody tr.selected > *,
html[data-theme="dark"] table.dataTable tbody tr.seleccionada > *,
html[data-theme="dark"] table.dataTable tbody tr.dt-row-selected td,
html[data-theme="dark"] table.dataTable tbody tr.selected td,
html[data-theme="dark"] .dt-dark tbody tr.selected td {
    background: #1a3f78 !important;
    background-color: #1a3f78 !important;
    color: #e7f2ff !important;
    box-shadow: none !important;
}

html[data-theme="dark"] .dt-dark thead tr.filters th input,
html[data-theme="dark"] .dt-dark thead tr.filters th select,
html[data-theme="dark"] table.dataTable thead tr.filters th input,
html[data-theme="dark"] table.dataTable thead tr.filters th select,
html[data-theme="dark"] .rp-filter-thead,
html[data-theme="dark"] .kyo-col-filter,
html[data-theme="dark"] .dt-dark thead tr.filters th input:focus,
html[data-theme="dark"] .rp-filter-thead:focus,
html[data-theme="dark"] .kyo-col-filter:focus,
html[data-theme="dark"] .dataTables_wrapper .dataTables_length select {
    background: #0a1220 !important;
    color: #e7f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .dataTables_wrapper .dataTables_filter label,
html[data-theme="dark"] .dataTables_wrapper .dataTables_length label,
html[data-theme="dark"] .dataTables_wrapper .dataTables_info {
    color: #8eb0d4 !important;
}

html[data-theme="dark"] .dataTables_wrapper .dt-buttons .dt-button,
html[data-theme="dark"] .dataTables_wrapper .dt-buttons.btn-group > .dt-button,
html[data-theme="dark"] .dataTables_wrapper .dt-buttons .dt-button:hover,
html[data-theme="dark"] .dataTables_wrapper .dt-buttons .dt-button:focus,
html[data-theme="dark"] div.dt-button-collection {
    background: #152238 !important;
    color: #e7f2ff !important;
    border-color: rgba(110, 186, 255, 0.28) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] div.dt-button-collection .dt-button:hover {
    background: #1a3f78 !important;
    color: #7ad7ff !important;
}

html[data-theme="dark"] .dataTables_wrapper .dataTables_paginate {
    background: #101c30 !important;
    border-color: rgba(110, 186, 255, 0.16) !important;
}
html[data-theme="dark"] .dataTables_wrapper .dataTables_paginate .paginate_button {
    color: #c5daf2 !important;
    background: transparent !important;
}
html[data-theme="dark"] .dataTables_wrapper .dataTables_paginate .paginate_button:hover {
    background: #163056 !important;
    color: #7ad7ff !important;
    border-color: transparent !important;
}
html[data-theme="dark"] .dataTables_wrapper .dataTables_paginate .paginate_button.current,
html[data-theme="dark"] .paginate_button.current {
    background: linear-gradient(135deg, #2f7dff, #1a4fd0) !important;
    color: #fff !important;
    border-color: transparent !important;
    box-shadow: none !important;
}

/* Acciones de fila e id — skin unificado vive en kyo-grid.css */
html[data-theme="dark"] .rp-grid-id {
    color: #8af0c0 !important;
    background: #12382c !important;
    border: 0 !important;
}

/* Select2 y menú de columnas */
html[data-theme="dark"] .select2-container--default .select2-selection--single,
html[data-theme="dark"] .select2-container--default .select2-selection--multiple,
html[data-theme="dark"] .dt-dark thead tr.filters th .select2-container--default .select2-selection--single,
html[data-theme="dark"] table.dataTable thead tr.filters th .select2-container--default .select2-selection--single,
html[data-theme="dark"] .select2-dropdown,
html[data-theme="dark"] .select2-search__field {
    background: #0a1220 !important;
    color: #e7f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .select2-container--default .select2-selection--single .select2-selection__rendered {
    color: #e7f2ff !important;
}
html[data-theme="dark"] .select2-container--default .select2-results__option {
    background: #101c30;
    color: #e7f2ff;
}
html[data-theme="dark"] .select2-container--default .select2-results__option--highlighted[aria-selected] {
    background: #1a3f78 !important;
    color: #7ad7ff !important;
}
/* Chips multi-select: anulan el rosa claro de kyo-theme.css */
html[data-theme="dark"] .select2-container--default .select2-selection--multiple .select2-selection__choice,
html[data-theme="dark"] .select2-container .select2-selection--multiple .select2-selection__choice {
    background: #163056 !important;
    border: 1px solid rgba(62, 197, 255, 0.4) !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .select2-container--default .select2-selection--multiple .select2-selection__choice__remove,
html[data-theme="dark"] .select2-container .select2-selection--multiple .select2-selection__choice__remove {
    color: #8eb0d4 !important;
}
html[data-theme="dark"] .select2-container--default .select2-selection--multiple .select2-selection__choice__remove:hover,
html[data-theme="dark"] .select2-container .select2-selection--multiple .select2-selection__choice__remove:hover {
    color: #ff8f9f !important;
}
html[data-theme="dark"] .select2-container .select2-selection--multiple .select2-search--inline .select2-search__field,
html[data-theme="dark"] .select2-container--default .select2-selection--multiple .select2-search--inline .select2-search__field {
    background: transparent !important;
    background-color: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    color: #e8f2ff !important;
    -webkit-text-fill-color: #e8f2ff !important;
}
html[data-theme="dark"] .select2-container .select2-selection--multiple .select2-search--inline .select2-search__field::placeholder {
    color: #8eb0d4 !important;
    -webkit-text-fill-color: #8eb0d4 !important;
    opacity: 0.9 !important;
}
html[data-theme="dark"] .rp-col-config-menu,
html[data-theme="dark"] .rp-col-config-head,
html[data-theme="dark"] .rp-col-config-list,
html[data-theme="dark"] .rp-col-config-item {
    background: #101c30 !important;
    color: #e7f2ff !important;
    border-color: rgba(110, 186, 255, 0.18) !important;
}

/* Tabs, modales, botones claros */
html[data-theme="dark"] .nav-tabs { border-color: rgba(110, 186, 255, 0.16); }
html[data-theme="dark"] .nav-tabs .nav-link,
html[data-theme="dark"] .rp-tabs-modern .nav-link { color: #8eb0d4 !important; }
html[data-theme="dark"] .nav-tabs .nav-link.active,
html[data-theme="dark"] .rp-tabs-modern .nav-link.active,
html[data-theme="dark"] .rp-tabs-shell {
    background: #101c30 !important;
    color: #7ad7ff !important;
    border-color: rgba(110, 186, 255, 0.2) !important;
}

html[data-theme="dark"] .modal-content,
html[data-theme="dark"] .modal-body,
html[data-theme="dark"] .modal-header,
html[data-theme="dark"] .modal-footer,
html[data-theme="dark"] .modal-footer-cc,
html[data-theme="dark"] .footer-Modales,
html[data-theme="dark"] .rp-modal .modal-content,
html[data-theme="dark"] .rp-modal-content,
html[data-theme="dark"] .rp-modal-footer,
html[data-theme="dark"] .ts-modal .modal-body {
    background: #101c30 !important;
    color: #e7f2ff !important;
    border-color: rgba(110, 186, 255, 0.18) !important;
}
html[data-theme="dark"] .colorEncabezado,
html[data-theme="dark"] .colorEncabezadoModales,
html[data-theme="dark"] .rp-modal-header,
html[data-theme="dark"] .kyo-modal-system--error .modal-header,
html[data-theme="dark"] .kyo-modal-system--success .modal-header,
html[data-theme="dark"] .kyo-modal-system--warn .modal-header,
html[data-theme="dark"] .kyo-modal-system--confirm .modal-header {
    background: linear-gradient(135deg, #12356e 0%, #0e2748 100%) !important;
    color: #e7f2ff !important;
    border-color: rgba(62, 197, 255, 0.28) !important;
}
html[data-theme="dark"] .colorEncabezado .modal-title,
html[data-theme="dark"] .colorEncabezadoModales .modal-title,
html[data-theme="dark"] .rp-modal-title,
html[data-theme="dark"] .modal-header.colorEncabezado .modal-title.text-white {
    color: #e7f2ff !important;
}
html[data-theme="dark"] .rp-modal-subtitle,
html[data-theme="dark"] .kyo-modal-msg { color: #e8f2ff !important; }

html[data-theme="dark"] .rp-btn-secondary,
html[data-theme="dark"] .rp-btn-soft,
html[data-theme="dark"] .rp-icon-btn,
html[data-theme="dark"] .btn-light,
html[data-theme="dark"] .btn-outline-secondary,
html[data-theme="dark"] .btn-secondary {
    background: #152238 !important;
    color: #e7f2ff !important;
    border-color: rgba(110, 186, 255, 0.28) !important;
}
html[data-theme="dark"] .alert-danger { background: #3a1820 !important; color: #ffb4be !important; }
html[data-theme="dark"] .alert-warning { background: #2a2410 !important; color: #ffe0a3 !important; }
html[data-theme="dark"] .alert-success { background: #0e2c28 !important; color: #9cf0c8 !important; }
html[data-theme="dark"] .alert-info,
html[data-theme="dark"] .alert-primary,
html[data-theme="dark"] .alert-secondary,
html[data-theme="dark"] .alert-light {
    background: #101c30 !important;
    color: #e8f2ff !important;
    border-color: rgba(110, 186, 255, 0.28) !important;
}

html[data-theme="dark"] .rp-session-timer {
    background: #101c30;
    color: #e7f2ff;
    border-color: rgba(110, 186, 255, 0.22);
}
html[data-theme="dark"] .rp-user-pill {
    background: #163056 !important;
    color: #e7f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .rp-user-name { color: #e7f2ff !important; }
html[data-theme="dark"] .rp-presence-dock {
    background: rgba(14, 23, 38, 0.96);
    border-color: rgba(110, 186, 255, 0.2);
}
html[data-theme="dark"] .dropdown-item,
html[data-theme="dark"] .rp-nav-item { color: #e7f2ff !important; }
html[data-theme="dark"] .dropdown-item:hover,
html[data-theme="dark"] .rp-nav-item:hover {
    background: #163056 !important;
    color: #7ad7ff !important;
}
html[data-theme="dark"] .btn-close { filter: invert(1) grayscale(1) brightness(1.4); }
html[data-theme="dark"] .kyo-toast {
    background: #101c30 !important;
    color: #e7f2ff !important;
    border-color: rgba(110, 186, 255, 0.2) !important;
}

html[data-theme="dark"] .stk-tipo--insumo { background: #0e2c28; color: #9cf0c8; }
html[data-theme="dark"] .stk-tipo--receta { background: #123056; color: #7ad7ff; }
html[data-theme="dark"] .stk-tipo--subreceta { background: #2a2410; color: #ffe0a3; }

html[data-theme="dark"] .table {
    --bs-table-bg: #0e1726;
    --bs-table-color: #e7f2ff;
    --bs-table-striped-bg: #122033;
    --bs-table-hover-bg: #183456;
    --bs-table-border-color: rgba(110, 186, 255, 0.12);
    color: #e7f2ff;
}
html[data-theme="dark"] .card {
    --bs-card-bg: #101c30;
    --bs-card-color: #e7f2ff;
    --bs-card-border-color: rgba(110, 186, 255, 0.16);
    --bs-card-cap-bg: #122033;
}

/* ============================================================
   Barrido: nada de blanco, rosa o violeta lavado en oscuro.
   Especificidad html[data-theme="dark"] + !important para
   ganarle a kyo-theme / kyo-modals / páginas.
   ============================================================ */

html[data-theme="dark"] .form-label,
html[data-theme="dark"] .filter-bar .form-label,
html[data-theme="dark"] .pg-form-grid .form-label,
html[data-theme="dark"] .pa-field label,
html[data-theme="dark"] .modal .form-label,
html[data-theme="dark"] .modal label {
    color: #b7cbe6 !important;
}

/* ---- Botones: primario azul, secundario navy (no rosa) ---- */
html[data-theme="dark"] .btn-primary,
html[data-theme="dark"] .btn-primary:hover,
html[data-theme="dark"] .btn-primary:focus,
html[data-theme="dark"] .filter-bar .btn-primary,
html[data-theme="dark"] .modal-footer .btn-primary,
html[data-theme="dark"] .modal-footer .btn-new,
html[data-theme="dark"] .kyo-modal-system .modal-footer .btn-primary,
html[data-theme="dark"] .pa-btn-primary,
html[data-theme="dark"] .pa-btn-primary:hover,
html[data-theme="dark"] .ts-modal .modal-footer .ts-btn--primary,
html[data-theme="dark"] .ts-modal .modal-footer .ts-btn--in,
html[data-theme="dark"] .ts-modal .modal-footer .btn-new {
    background: linear-gradient(135deg, #2f7dff, #1a4fd0) !important;
    background-image: linear-gradient(135deg, #2f7dff, #1a4fd0) !important;
    color: #fff !important;
    border-color: transparent !important;
    box-shadow: 0 6px 18px rgba(47, 125, 255, 0.35) !important;
}

html[data-theme="dark"] .btn-outline-primary,
html[data-theme="dark"] .btn-outline-primary:hover,
html[data-theme="dark"] .btn-outline-primary:focus,
html[data-theme="dark"] .btn-outline-secondary,
html[data-theme="dark"] .btn-outline-secondary:hover,
html[data-theme="dark"] .btn-outline-light,
html[data-theme="dark"] .btn-outline-light:hover,
html[data-theme="dark"] .btn-secondary,
html[data-theme="dark"] .btn-secondary:hover,
html[data-theme="dark"] .modal-footer .btn-secondary,
html[data-theme="dark"] .modal-footer .btn-secondary:hover,
html[data-theme="dark"] .pg-back-link,
html[data-theme="dark"] .pg-hub .pg-back-link,
html[data-theme="dark"] .pg-hub .pg-back-link:hover,
html[data-theme="dark"] .filter-bar .btn-outline-secondary,
html[data-theme="dark"] .ts-btn--ghost,
html[data-theme="dark"] .ts-btn--ghost:hover,
html[data-theme="dark"] .ts-modal .modal-footer .ts-btn--ghost,
html[data-theme="dark"] .ts-modal .modal-footer .ts-btn--ghost:hover,
html[data-theme="dark"] .ts-modal .modal-footer .btn-secondary,
html[data-theme="dark"] .ts-modal .modal-footer .btn-secondary:hover {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.35) !important;
    box-shadow: none !important;
}

/* ---- Filtros de grilla + export (Insumos por proveedor y el resto) ---- */
html[data-theme="dark"] .filter-bar,
html[data-theme="dark"] .page-99 .filter-bar,
html[data-theme="dark"] #formFiltrosProvIns.filter-bar,
html[data-theme="dark"] .ts-filters {
    background: #0e1c36 !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border: 1px solid rgba(90, 170, 255, 0.22) !important;
    box-shadow: none !important;
}

html[data-theme="dark"] .filter-bar .form-control,
html[data-theme="dark"] .filter-bar .form-select,
html[data-theme="dark"] .page-99 .dataTables_wrapper .dataTables_length select,
html[data-theme="dark"] .dt-input-dark,
html[data-theme="dark"] .dt-input-dark:focus {
    background: #07111f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.35) !important;
    box-shadow: none !important;
}

html[data-theme="dark"] button.dt-button,
html[data-theme="dark"] a.dt-button,
html[data-theme="dark"] div.dt-button,
html[data-theme="dark"] .dataTables_wrapper .dt-buttons .dt-button,
html[data-theme="dark"] .dataTables_wrapper .dt-buttons.btn-group > .dt-button,
html[data-theme="dark"] .dataTables_wrapper .dt-buttons .dt-button:hover,
html[data-theme="dark"] .dataTables_wrapper .dt-buttons .dt-button:focus,
html[data-theme="dark"] .buttons-html5,
html[data-theme="dark"] .buttons-print,
html[data-theme="dark"] .buttons-collection,
html[data-theme="dark"] .buttons-page-length,
html[data-theme="dark"] div.dt-button-collection,
html[data-theme="dark"] div.dt-button-collection .dt-button {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.28) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .dataTables_wrapper .dt-buttons .dt-button:hover,
html[data-theme="dark"] div.dt-button-collection .dt-button:hover {
    background: #163056 !important;
    color: #3ec5ff !important;
    border-color: rgba(62, 197, 255, 0.45) !important;
}

/* ---- Columnas visibles ---- */
html[data-theme="dark"] .rp-col-config-btn,
html[data-theme="dark"] .rp-col-config-btn:hover,
html[data-theme="dark"] .rp-col-config-btn:focus,
html[data-theme="dark"] .rp-col-config-btn.show {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .rp-col-config-btn-icon {
    background: #163056 !important;
    background-image: none !important;
    color: #3ec5ff !important;
}
html[data-theme="dark"] .rp-col-config-menu,
html[data-theme="dark"] .dropdown-menu.rp-col-config-menu {
    background: #0e1c36 !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border: 1px solid rgba(90, 170, 255, 0.28) !important;
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45) !important;
}
html[data-theme="dark"] .rp-col-config-head,
html[data-theme="dark"] .rp-col-config-toolbar,
html[data-theme="dark"] .rp-col-config-foot,
html[data-theme="dark"] .rp-col-config-list,
html[data-theme="dark"] .rp-col-config-item,
html[data-theme="dark"] .rp-col-config-empty {
    background: #0e1c36 !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.18) !important;
}
html[data-theme="dark"] .rp-col-config-head {
    background: #12243f !important;
}
html[data-theme="dark"] .rp-col-config-head-icon {
    background: #163056 !important;
    color: #3ec5ff !important;
}
html[data-theme="dark"] .rp-col-config-title { color: #e8f2ff !important; }
html[data-theme="dark"] .rp-col-config-sub,
html[data-theme="dark"] .rp-col-config-foot,
html[data-theme="dark"] .rp-col-config-empty { color: #b7cbe6 !important; }
html[data-theme="dark"] .rp-col-config-search {
    background: #07111f !important;
    border: 1px solid rgba(62, 197, 255, 0.45) !important;
}
html[data-theme="dark"] .rp-col-config-search i { color: #3ec5ff !important; }
html[data-theme="dark"] .rp-col-config-search-input,
html[data-theme="dark"] .rp-col-config-search-input::placeholder {
    color: #e8f2ff !important;
    background: transparent !important;
}
html[data-theme="dark"] .rp-col-config-search-input::placeholder { color: #9eb4d4 !important; }
html[data-theme="dark"] .rp-col-config-quick-btn,
html[data-theme="dark"] .rp-col-config-quick-btn:hover {
    background: #12243f !important;
    color: #e8f2ff !important;
    border: 1px solid rgba(90, 170, 255, 0.35) !important;
}
html[data-theme="dark"] .rp-col-config-quick-btn:hover {
    border-color: rgba(62, 197, 255, 0.55) !important;
    color: #3ec5ff !important;
}
html[data-theme="dark"] .rp-col-config-label { color: #e8f2ff !important; }
html[data-theme="dark"] .rp-col-config-item:hover { background: #163056 !important; }
html[data-theme="dark"] .rp-col-config-box {
    background: #07111f !important;
    border-color: rgba(62, 197, 255, 0.45) !important;
}
html[data-theme="dark"] .rp-col-config-check:checked + .rp-col-config-box {
    background: linear-gradient(135deg, #3ec5ff, #2f7dff) !important;
    border-color: #2f7dff !important;
}

/* ---- Modales: shell, headers, cuerpo, drop zones ---- */
html[data-theme="dark"] .modal-content,
html[data-theme="dark"] .modal-dialog .modal-content,
html[data-theme="dark"] .modal-body,
html[data-theme="dark"] .modal-header,
html[data-theme="dark"] .modal-footer,
html[data-theme="dark"] .modal-footer-cc,
html[data-theme="dark"] .footer-Modales,
html[data-theme="dark"] .cc-modal,
html[data-theme="dark"] .cc-modal .modal-body,
html[data-theme="dark"] .cc-modal-header,
html[data-theme="dark"] .cc-modal-footer,
html[data-theme="dark"] .rp-modal .modal-content,
html[data-theme="dark"] .rp-modal-content,
html[data-theme="dark"] .rp-modal-header,
html[data-theme="dark"] .rp-modal-footer,
html[data-theme="dark"] .rp-session-renew-modal,
html[data-theme="dark"] .ts-modal .modal-content,
html[data-theme="dark"] .ts-modal .modal-header,
html[data-theme="dark"] .ts-modal .modal-header.colorEncabezado,
html[data-theme="dark"] .ts-modal .modal-body,
html[data-theme="dark"] .ts-modal .modal-footer,
html[data-theme="dark"] .kyo-modal-system .modal-content,
html[data-theme="dark"] .kyo-modal-system .modal-header,
html[data-theme="dark"] .kyo-modal-system .modal-body,
html[data-theme="dark"] .kyo-modal-system .modal-footer,
html[data-theme="dark"] .kyo-modal-system--error .modal-header,
html[data-theme="dark"] .kyo-modal-system--success .modal-header,
html[data-theme="dark"] .kyo-modal-system--warn .modal-header,
html[data-theme="dark"] .kyo-modal-system--confirm .modal-header,
html[data-theme="dark"] .colorEncabezado,
html[data-theme="dark"] .colorEncabezadoModales,
html[data-theme="dark"] #historialModal .modal-content,
html[data-theme="dark"] #historialModal .modal-header,
html[data-theme="dark"] #historialModal .modal-body,
html[data-theme="dark"] #historialModal .modal-footer {
    background: #0e1c36 !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.22) !important;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45) !important;
}

/* ===== Historial: pills/chips/badges en dark (evita fondos claros + texto blanco) ===== */
html[data-theme="dark"] .kyo-hist-empty {
    color: #8eb0d4 !important;
}

html[data-theme="dark"] .kyo-hist-card {
    background: linear-gradient(165deg, #15263c 0%, #101c30 100%) !important;
    border-color: rgba(110, 186, 255, 0.16) !important;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.28) !important;
    color: #e7f2ff !important;
}

html[data-theme="dark"] .kyo-hist-card--create::before {
    background: linear-gradient(180deg, #4ade80, #22c55e) !important;
}
html[data-theme="dark"] .kyo-hist-card--update::before {
    background: linear-gradient(180deg, #3ec5ff, #2f7dff) !important;
}
html[data-theme="dark"] .kyo-hist-card--delete::before {
    background: linear-gradient(180deg, #f87171, #ef4444) !important;
}

html[data-theme="dark"] .kyo-hist-badge--create {
    background: rgba(34, 197, 94, 0.16) !important;
    color: #86efac !important;
    border-color: rgba(74, 222, 128, 0.35) !important;
}
html[data-theme="dark"] .kyo-hist-badge--update {
    background: rgba(62, 197, 255, 0.14) !important;
    color: #7dd3fc !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .kyo-hist-badge--delete {
    background: rgba(239, 68, 68, 0.16) !important;
    color: #fca5a5 !important;
    border-color: rgba(248, 113, 113, 0.35) !important;
}

html[data-theme="dark"] .kyo-hist-time,
html[data-theme="dark"] .kyo-hist-user {
    color: #8eb0d4 !important;
}
html[data-theme="dark"] .kyo-hist-user i {
    color: #3ec5ff !important;
}
html[data-theme="dark"] .kyo-hist-resumo {
    color: #e7f2ff !important;
}

html[data-theme="dark"] .kyo-hist-origen {
    background: rgba(110, 186, 255, 0.1) !important;
    color: #a8c6e8 !important;
}
html[data-theme="dark"] .kyo-hist-origen--import {
    background: rgba(47, 125, 255, 0.18) !important;
    color: #93c5fd !important;
}

html[data-theme="dark"] .kyo-hist-chip--diff {
    background: rgba(22, 50, 79, 0.85) !important;
    border-color: rgba(212, 168, 75, 0.28) !important;
    box-shadow: none !important;
    color: #e7f2ff !important;
}
html[data-theme="dark"] .kyo-hist-chip--info,
html[data-theme="dark"] .kyo-hist-chip--upd {
    background: rgba(62, 197, 255, 0.1) !important;
    border-color: rgba(62, 197, 255, 0.22) !important;
    color: #b8d4f0 !important;
}
html[data-theme="dark"] .kyo-hist-chip--add {
    background: rgba(34, 197, 94, 0.14) !important;
    border-color: rgba(74, 222, 128, 0.28) !important;
    color: #86efac !important;
}
html[data-theme="dark"] .kyo-hist-chip--del {
    background: rgba(239, 68, 68, 0.14) !important;
    border-color: rgba(248, 113, 113, 0.28) !important;
    color: #fca5a5 !important;
}

html[data-theme="dark"] .kyo-hist-field {
    color: #8eb0d4 !important;
}
html[data-theme="dark"] .kyo-hist-val {
    color: #e7f2ff !important;
}
html[data-theme="dark"] .kyo-hist-old {
    background: rgba(239, 68, 68, 0.16) !important;
    color: #fca5a5 !important;
}
html[data-theme="dark"] .kyo-hist-new {
    background: rgba(34, 197, 94, 0.16) !important;
    color: #86efac !important;
}
html[data-theme="dark"] .kyo-hist-arrow {
    color: #3ec5ff !important;
}

html[data-theme="dark"] .kyo-hist-price-row {
    background: rgba(7, 17, 31, 0.72) !important;
    border-color: rgba(110, 186, 255, 0.14) !important;
}
html[data-theme="dark"] .kyo-hist-price-label {
    color: #8eb0d4 !important;
}
html[data-theme="dark"] .kyo-hist-price-val {
    color: #e7f2ff !important;
}

html[data-theme="dark"] .kyo-hist-var--up {
    background: rgba(239, 68, 68, 0.18) !important;
    color: #fca5a5 !important;
}
html[data-theme="dark"] .kyo-hist-var--down {
    background: rgba(34, 197, 94, 0.18) !important;
    color: #86efac !important;
}
html[data-theme="dark"] .kyo-hist-var--flat {
    background: rgba(110, 186, 255, 0.1) !important;
    color: #8eb0d4 !important;
}

html[data-theme="dark"] body .kyo-hist-card.kyo-hist-card--price-up {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22), inset 0 0 0 1px rgba(248, 113, 113, 0.28) !important;
}
html[data-theme="dark"] body .kyo-hist-card.kyo-hist-card--price-down {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22), inset 0 0 0 1px rgba(74, 222, 128, 0.28) !important;
}
html[data-theme="dark"] .modal-header,
html[data-theme="dark"] .cc-modal-header,
html[data-theme="dark"] .rp-modal-header,
html[data-theme="dark"] .colorEncabezado,
html[data-theme="dark"] .colorEncabezadoModales,
html[data-theme="dark"] .ts-modal .modal-header,
html[data-theme="dark"] .kyo-modal-system .modal-header {
    background: #12243f !important;
    border-bottom: 1px solid rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .modal-footer,
html[data-theme="dark"] .cc-modal-footer,
html[data-theme="dark"] .rp-modal-footer,
html[data-theme="dark"] .ts-modal .modal-footer,
html[data-theme="dark"] .footer-Modales {
    background: #12243f !important;
    border-top: 1px solid rgba(90, 170, 255, 0.22) !important;
}
html[data-theme="dark"] .modal-title,
html[data-theme="dark"] .colorEncabezado .modal-title,
html[data-theme="dark"] .colorEncabezadoModales .modal-title,
html[data-theme="dark"] .modal-header.colorEncabezado .modal-title.text-white,
html[data-theme="dark"] .cc-modal-header .modal-title,
html[data-theme="dark"] .rp-modal-title,
html[data-theme="dark"] .ts-modal-title,
html[data-theme="dark"] .ts-modal .modal-title,
html[data-theme="dark"] .kyo-modal-system .modal-title,
html[data-theme="dark"] .vt-drop-title {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .rp-modal-subtitle,
html[data-theme="dark"] .ts-modal-sub,
html[data-theme="dark"] .kyo-modal-msg,
html[data-theme="dark"] .kyo-modal-system--error .kyo-modal-msg,
html[data-theme="dark"] .kyo-modal-system--success .kyo-modal-msg,
html[data-theme="dark"] .kyo-modal-system--warn .kyo-modal-msg,
html[data-theme="dark"] .kyo-modal-system--confirm .kyo-modal-msg,
html[data-theme="dark"] .modal .text-muted,
html[data-theme="dark"] .modal .form-text,
html[data-theme="dark"] .modal small,
html[data-theme="dark"] .vt-drop-hint {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pg-form-section {
    color: #f0a8bc;
}

html[data-theme="dark"] .pg-form-hint {
    color: #8eb0d4;
}

html[data-theme="dark"] .modal .form-control,
html[data-theme="dark"] .modal .form-select,
html[data-theme="dark"] .rp-modal .rp-input,
html[data-theme="dark"] .rp-modal .rp-search-input,
html[data-theme="dark"] .ts-modal .form-control,
html[data-theme="dark"] .ts-modal .form-select,
html[data-theme="dark"] .cc-modal .form-control,
html[data-theme="dark"] .cc-modal .form-select,
html[data-theme="dark"] .pg-form-grid .form-control,
html[data-theme="dark"] .pg-form-grid .form-control:focus,
html[data-theme="dark"] .pg-pago-form-shell .form-control,
html[data-theme="dark"] .pg-pago-form-shell .form-select {
    background: #07111f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.35) !important;
}
html[data-theme="dark"] .rp-modal .rp-config-card,
html[data-theme="dark"] .rp-modal .rp-config-card:hover,
html[data-theme="dark"] .rp-modal .rp-config-card.is-active,
html[data-theme="dark"] .rp-modal .rp-config-view-card.is-active,
html[data-theme="dark"] .rp-modal .rp-list-item,
html[data-theme="dark"] .rp-modal .rp-config-view-section {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.28) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .rp-modal .rp-config-card.is-active,
html[data-theme="dark"] .rp-modal .rp-config-view-card.is-active {
    border-color: rgba(62, 197, 255, 0.55) !important;
}
html[data-theme="dark"] .rp-modal .rp-config-sub { color: #b7cbe6 !important; }
html[data-theme="dark"] .modal .select2-dropdown,
html[data-theme="dark"] .modal .select2-results__option {
    background: #0e1c36 !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .modal .select2-results__option--highlighted {
    background: #1a3f78 !important;
    color: #3ec5ff !important;
}
html[data-theme="dark"] .modal table.dataTable thead th,
html[data-theme="dark"] .modal .colorEncabezadoTabla,
html[data-theme="dark"] .modal thead.colorEncabezadoTabla th,
html[data-theme="dark"] .colorEncabezadoTabla,
html[data-theme="dark"] .colorEncabezadoTabla th,
html[data-theme="dark"] #vistaPrevia thead th {
    background: linear-gradient(180deg, #1d5bff 0%, #123a9a 100%) !important;
    background-image: linear-gradient(180deg, #1d5bff 0%, #123a9a 100%) !important;
    color: #f4f8ff !important;
    border-color: rgba(90, 180, 255, 0.35) !important;
}
html[data-theme="dark"] .modal table.dataTable tbody td,
html[data-theme="dark"] .modal table.dataTable.display tbody tr td,
html[data-theme="dark"] .modal table.dataTable.display tbody tr:nth-child(even) td,
html[data-theme="dark"] .fila-sin-cambios {
    background: #0e1c36 !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .fila-modificada {
    background: #2a2414 !important;
    color: #ffe0a3 !important;
}
html[data-theme="dark"] .fila-nueva-insumo {
    background: #10281f !important;
    color: #9cf0c8 !important;
}
html[data-theme="dark"] #modalImportar .modal-content,
html[data-theme="dark"] #resumenImportacion {
    background: #0e1c36 !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}

html[data-theme="dark"] .vt-drop-zone,
html[data-theme="dark"] .card-glass.vt-drop-zone,
html[data-theme="dark"] .vt-drop-inner,
html[data-theme="dark"] .vt-drop-zone.is-dragover .vt-drop-inner {
    background: #0e1c36 !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border: 2px dashed rgba(62, 197, 255, 0.55) !important;
    box-shadow: inset 0 0 0 1px rgba(47, 125, 255, 0.15) !important;
}
html[data-theme="dark"] .vt-drop-zone.is-dragover .vt-drop-inner {
    background: #12243f !important;
    border-color: #3ec5ff !important;
}
html[data-theme="dark"] .vt-drop-icon {
    background: #12243f !important;
    background-image: none !important;
    color: #3ec5ff !important;
    border: 1px solid rgba(62, 197, 255, 0.45) !important;
}
html[data-theme="dark"] .vt-file-card,
html[data-theme="dark"] .vt-step,
html[data-theme="dark"] .vt-step.is-active {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.28) !important;
}

/* ---- Stock: pastillas navy, marcas rojo/verde legibles ---- */
html[data-theme="dark"] .stk-pill {
    background: #12243f !important;
    color: #e8f2ff !important;
    border: 1px solid rgba(90, 170, 255, 0.35) !important;
}
html[data-theme="dark"] .stk-pill--sin { background: #2a1520 !important; border-color: rgba(255, 120, 140, 0.45) !important; }
html[data-theme="dark"] .stk-pill--sin,
html[data-theme="dark"] .stk-pill--sin i { color: #ff8d9a !important; }
html[data-theme="dark"] .stk-pill--ok { background: #10281f !important; border-color: rgba(90, 220, 150, 0.45) !important; }
html[data-theme="dark"] .stk-pill--ok,
html[data-theme="dark"] .stk-pill--ok i { color: #7dffa0 !important; }
html[data-theme="dark"] .stk-pill--bajo { background: #2a2414 !important; border-color: rgba(224, 170, 70, 0.45) !important; }
html[data-theme="dark"] .stk-pill--bajo,
html[data-theme="dark"] .stk-pill--bajo i { color: #ffd27a !important; }
html[data-theme="dark"] #stkSwitchSentido button,
html[data-theme="dark"] #stkSwitchSentido button.active {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.35) !important;
}
html[data-theme="dark"] #stkSwitchSentido button.active {
    color: #3ec5ff !important;
    border-color: #3ec5ff !important;
}

/* ---- Finanzas: franjas de sección ---- */
html[data-theme="dark"] .ts-panel,
html[data-theme="dark"] .ts-panel-body,
html[data-theme="dark"] .ts-cuenta,
html[data-theme="dark"] .ts-cuenta.is-active {
    background: #0e1c36 !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.22) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .ts-panel-head {
    background: #12243f !important;
    background-image: none !important;
    border-bottom: 1px solid rgba(90, 170, 255, 0.22) !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .ts-panel-head h2,
html[data-theme="dark"] .ts-panel-head h3,
html[data-theme="dark"] .ts-cuenta-nombre,
html[data-theme="dark"] .ts-cuenta-saldo {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .ts-panel-head p,
html[data-theme="dark"] .ts-cuenta-tipo,
html[data-theme="dark"] .ts-legend,
html[data-theme="dark"] .ts-legend span {
    color: #b7cbe6 !important;
}
html[data-theme="dark"] .ts-panel-head h2 i,
html[data-theme="dark"] .ts-panel-head h3 i { color: #3ec5ff !important; }
html[data-theme="dark"] .ts-kpi-icon,
html[data-theme="dark"] .ts-kpi--gold .ts-kpi-icon,
html[data-theme="dark"] .ts-kpi--rose .ts-kpi-icon,
html[data-theme="dark"] .ts-kpi--sage .ts-kpi-icon,
html[data-theme="dark"] .ts-kpi--sky .ts-kpi-icon,
html[data-theme="dark"] .ts-kpi--amber .ts-kpi-icon,
html[data-theme="dark"] .ts-kpi--violet .ts-kpi-icon {
    background: #163056 !important;
    color: #3ec5ff !important;
}

/* ---- Proveedor gestión (ficha) ---- */
html[data-theme="dark"] .pg-hub,
html[data-theme="dark"] .pg-tabs-card,
html[data-theme="dark"] .pg-tab-content,
html[data-theme="dark"] .pg-tabs-nav,
html[data-theme="dark"] .pg-hub .tab-content,
html[data-theme="dark"] .pg-hub .tab-pane,
html[data-theme="dark"] .pg-resumen-row,
html[data-theme="dark"] .pg-panel-hero,
html[data-theme="dark"] .pg-panel-hero--pago,
html[data-theme="dark"] .pg-panel-hero--analisis,
html[data-theme="dark"] .pg-precios-hero,
html[data-theme="dark"] .pg-pago-form-shell,
html[data-theme="dark"] .pg-pago-saldo-chip {
    background: #0e1c36 !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.22) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .pg-kpi-mini,
html[data-theme="dark"] .pg-kpi-mini.pg-kpi-sage,
html[data-theme="dark"] .pg-kpi-mini.pg-kpi-sky {
    background: #12243f !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.28) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .pg-kpi-mini .pg-kpi-label { color: #b7cbe6 !important; }
html[data-theme="dark"] .pg-kpi-mini .pg-kpi-value { color: #3ec5ff !important; }
html[data-theme="dark"] .pg-kpi-mini.pg-kpi-sage .pg-kpi-value { color: #8ee07a !important; }
html[data-theme="dark"] .pg-kpi-mini.pg-kpi-sky .pg-kpi-value { color: #7ad7ff !important; }
html[data-theme="dark"] .pg-tab-pill,
html[data-theme="dark"] .pg-tab-pill:hover:not(.active):not(:disabled) {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.32) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .pg-tab-pill:hover:not(.active):not(:disabled) {
    color: #3ec5ff !important;
    border-color: rgba(62, 197, 255, 0.5) !important;
}
html[data-theme="dark"] .pg-tab-pill.active,
html[data-theme="dark"] .pg-tab-pill.active i {
    background: linear-gradient(135deg, #2f7dff, #1a4fd0) !important;
    background-image: linear-gradient(135deg, #2f7dff, #1a4fd0) !important;
    color: #fff !important;
    border-color: transparent !important;
    box-shadow: 0 4px 14px rgba(47, 125, 255, 0.35) !important;
}
html[data-theme="dark"] .pg-precios-hero-title,
html[data-theme="dark"] .pg-precios-count {
    color: #e8f2ff !important;
    background: transparent !important;
}
html[data-theme="dark"] .pg-precios-hero-sub,
html[data-theme="dark"] .pg-pago-saldo-label { color: #b7cbe6 !important; }
html[data-theme="dark"] .pg-precios-count {
    background: #12243f !important;
    border-color: rgba(62, 197, 255, 0.4) !important;
    color: #3ec5ff !important;
}

/* ---- Análisis del proveedor (solapa) ---- */
html[data-theme="dark"] .pg-ax-panel,
html[data-theme="dark"] .pg-ax-body,
html[data-theme="dark"] .pg-ax-verdict,
html[data-theme="dark"] .pg-ax-kpi,
html[data-theme="dark"] .pg-ax-card,
html[data-theme="dark"] .pg-ax-item,
html[data-theme="dark"] .pg-ax-chart,
html[data-theme="dark"] .pg-ax-chart--sm {
    background: #0e1c36 !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.22) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .pg-ax-kpi { background: #12243f !important; }
html[data-theme="dark"] .pg-ax-card { background: #12243f !important; }
html[data-theme="dark"] .pg-ax-verdict-text h4,
html[data-theme="dark"] .pg-ax-kpi strong,
html[data-theme="dark"] .pg-ax-card h6,
html[data-theme="dark"] .pg-ax-item strong,
html[data-theme="dark"] .pg-ax-resumen,
html[data-theme="dark"] .pg-ax-reco p,
html[data-theme="dark"] .pg-ax-col ul {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pg-ax-kpi span,
html[data-theme="dark"] .pg-ax-kpi em,
html[data-theme="dark"] .pg-ax-score-ring span,
html[data-theme="dark"] .pg-ax-col .pg-ax-empty-mini,
html[data-theme="dark"] .pg-ax-empty { color: #b7cbe6 !important; }
html[data-theme="dark"] .pg-ax-score-ring::before { background: #0e1c36 !important; }
html[data-theme="dark"] .pg-ax-score-ring strong { color: #e8f2ff !important; }
html[data-theme="dark"] .pg-ax-verdict .pg-ax-score-ring,
html[data-theme="dark"] .pg-ax-verdict.is-excelente .pg-ax-score-ring,
html[data-theme="dark"] .pg-ax-verdict.is-buena .pg-ax-score-ring,
html[data-theme="dark"] .pg-ax-verdict.is-regular .pg-ax-score-ring,
html[data-theme="dark"] .pg-ax-verdict.is-mala .pg-ax-score-ring {
    background: conic-gradient(#3ec5ff var(--pg-ax-deg, 0deg), #1a3054 0) !important;
}
html[data-theme="dark"] .pg-ax-verdict.is-excelente .pg-ax-score-ring { background: conic-gradient(#7dffa0 var(--pg-ax-deg, 0deg), #1a3054 0) !important; }
html[data-theme="dark"] .pg-ax-verdict.is-regular .pg-ax-score-ring { background: conic-gradient(#ffd27a var(--pg-ax-deg, 0deg), #1a3054 0) !important; }
html[data-theme="dark"] .pg-ax-verdict.is-mala .pg-ax-score-ring { background: conic-gradient(#ff8d9a var(--pg-ax-deg, 0deg), #1a3054 0) !important; }
html[data-theme="dark"] .pg-ax-badge,
html[data-theme="dark"] .pg-ax-verdict.is-excelente .pg-ax-badge,
html[data-theme="dark"] .pg-ax-verdict.is-buena .pg-ax-badge,
html[data-theme="dark"] .pg-ax-verdict.is-regular .pg-ax-badge,
html[data-theme="dark"] .pg-ax-verdict.is-mala .pg-ax-badge {
    background: #163056 !important;
    color: #3ec5ff !important;
}
html[data-theme="dark"] .pg-ax-reco {
    background: rgba(47, 125, 255, 0.14) !important;
    border: 1px solid rgba(62, 197, 255, 0.4) !important;
}
html[data-theme="dark"] .pg-ax-reco-label { color: #3ec5ff !important; }
html[data-theme="dark"] .pg-ax-col { background: #12243f !important; border-color: rgba(90, 170, 255, 0.22) !important; }
html[data-theme="dark"] .pg-ax-col--ok {
    background: rgba(46, 180, 120, 0.12) !important;
    border-color: rgba(90, 220, 160, 0.35) !important;
}
html[data-theme="dark"] .pg-ax-col--warn {
    background: rgba(224, 161, 90, 0.12) !important;
    border-color: rgba(224, 161, 90, 0.38) !important;
}
html[data-theme="dark"] .pg-ax-col--ok h5 { color: #8ee07a !important; }
html[data-theme="dark"] .pg-ax-col--warn h5 { color: #ffd27a !important; }
html[data-theme="dark"] .pg-ax-item { background: #12243f !important; }
html[data-theme="dark"] .pg-ax-kpi .pg-ax-bad { color: #ff8d9a !important; }
html[data-theme="dark"] .pg-ax-kpi .pg-ax-good { color: #8ee07a !important; }

/* ---- Hub Análisis de proveedores ---- */
html[data-theme="dark"] .pa-dash {
    --pa-rose: #3ec5ff;
    --pa-rose-soft: #2f7dff;
    --pa-rose-deep: #7ad7ff;
    --pa-ink: #e8f2ff;
    --pa-muted: #b7cbe6;
    --pa-border: rgba(90, 170, 255, 0.22);
    --pa-surface: #0e1c36;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pa-hero,
html[data-theme="dark"] .pa-toolbar,
html[data-theme="dark"] .pa-nav,
html[data-theme="dark"] .pa-kpi,
html[data-theme="dark"] .pa-panel,
html[data-theme="dark"] .pa-chart-wrap,
html[data-theme="dark"] .pa-rank-item {
    background-color: #0e1c36;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.22) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .pa-toolbar,
html[data-theme="dark"] .pa-kpi,
html[data-theme="dark"] .pa-panel,
html[data-theme="dark"] .pa-nav,
html[data-theme="dark"] .pa-rank-item {
    background: #0e1c36 !important;
    background-image: none !important;
}
html[data-theme="dark"] .pa-kpi,
html[data-theme="dark"] .pa-panel,
html[data-theme="dark"] .pa-nav-link.active {
    background: #12243f !important;
}
html[data-theme="dark"] .pa-hero {
    background: linear-gradient(135deg, #0e1c36 0%, #12243f 55%, #10283a 100%) !important;
    border: 1px solid rgba(62, 197, 255, 0.28) !important;
}
html[data-theme="dark"] .pa-sub,
html[data-theme="dark"] .pa-eyebrow,
html[data-theme="dark"] .pa-section-head p,
html[data-theme="dark"] .pa-kpi-label,
html[data-theme="dark"] .pa-kpi-hint,
html[data-theme="dark"] .pa-rank-meta { color: #b7cbe6 !important; }
html[data-theme="dark"] .pa-kpi-value,
html[data-theme="dark"] .pa-rank-name,
html[data-theme="dark"] .pa-rank-meta strong { color: #e8f2ff !important; }
html[data-theme="dark"] .pa-period-pill,
html[data-theme="dark"] .pa-chip,
html[data-theme="dark"] .pa-chip:hover,
html[data-theme="dark"] .pa-nav-link,
html[data-theme="dark"] .pa-nav-link:hover {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.32) !important;
}
html[data-theme="dark"] .pa-chip.active,
html[data-theme="dark"] .pa-nav-link.active {
    background: #163056 !important;
    color: #3ec5ff !important;
    border-color: rgba(62, 197, 255, 0.55) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .pa-title,
html[data-theme="dark"] .pa-section-head h2,
html[data-theme="dark"] .pa-panel-head h3 { color: #e8f2ff !important; background: transparent !important; }
html[data-theme="dark"] .pa-period-pill i,
html[data-theme="dark"] .pa-section-head h2 i,
html[data-theme="dark"] .pa-panel-head h3 i,
html[data-theme="dark"] .pa-dot { color: #3ec5ff !important; }
html[data-theme="dark"] .pa-kpi-icon,
html[data-theme="dark"] .pa-kpi--rose .pa-kpi-icon,
html[data-theme="dark"] .pa-kpi--sage .pa-kpi-icon,
html[data-theme="dark"] .pa-kpi--sky .pa-kpi-icon,
html[data-theme="dark"] .pa-kpi--amber .pa-kpi-icon {
    background: #163056 !important;
    color: #3ec5ff !important;
}
html[data-theme="dark"] .pa-back {
    background: #12243f !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.35) !important;
}
html[data-theme="dark"] .pa-table thead th {
    background: #12243f !important;
    color: #b7cbe6 !important;
    border-bottom-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .pa-table tbody td { color: #e8f2ff !important; border-color: rgba(90, 170, 255, 0.12) !important; }
html[data-theme="dark"] .pa-table tbody tr:hover td { background: #163056 !important; }
html[data-theme="dark"] .pa-alert-item,
html[data-theme="dark"] .pa-alert-item.is-up,
html[data-theme="dark"] .pa-alert-item.is-down {
    background: #12243f !important;
    color: #e8f2ff !important;
    border-color: rgba(90, 170, 255, 0.28) !important;
}
html[data-theme="dark"] .pa-rank-bar { background: #1a3054 !important; }
html[data-theme="dark"] .pa-rank-bar > span {
    background: linear-gradient(90deg, #3ec5ff, #2f7dff) !important;
}
html[data-theme="dark"] .pa-hero-glow { opacity: 0.25 !important; }

/* ============================================================
   Mensajes sobre navy: cuerpo #e8f2ff, título blanco, cierre claro.
   Los hijos de .kyo-toast fijan color propio y pisan la herencia.
   ============================================================ */
html[data-theme="dark"] .kyo-toast__title,
html[data-theme="dark"] .swal2-title {
    color: #ffffff !important;
}
html[data-theme="dark"] .toast-header {
    background: #12243f !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .kyo-toast__msg,
html[data-theme="dark"] .kyo-toast__body,
html[data-theme="dark"] .kyo-toast--success .kyo-toast__msg,
html[data-theme="dark"] .kyo-toast--error .kyo-toast__msg,
html[data-theme="dark"] .kyo-toast--warn .kyo-toast__msg,
html[data-theme="dark"] .kyo-toast--info .kyo-toast__msg,
html[data-theme="dark"] .kyo-toast--confirm .kyo-toast__msg,
html[data-theme="dark"] .toast-body,
html[data-theme="dark"] .swal2-html-container,
html[data-theme="dark"] .swal2-content {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .kyo-toast__close,
html[data-theme="dark"] .kyo-toast__close i,
html[data-theme="dark"] .swal2-close {
    color: #d5e6ff !important;
}
html[data-theme="dark"] .kyo-toast__close:hover,
html[data-theme="dark"] .kyo-toast__close:focus,
html[data-theme="dark"] .kyo-toast__close:hover i,
html[data-theme="dark"] .swal2-close:hover {
    color: #ffffff !important;
    background: rgba(232, 242, 255, 0.1) !important;
}
html[data-theme="dark"] .kyo-toast__btn--ghost {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .kyo-toast__btn--ghost:hover {
    color: #ffffff !important;
}
/* X de cierre: blanca, circular, con el acento celeste del tema.
   Pisa filter:none y el SVG negro de Bootstrap en todos los modales. */
html[data-theme="dark"] .modal .btn-close,
html[data-theme="dark"] .modal .rp-btn-close,
html[data-theme="dark"] .offcanvas .btn-close {
    --kyo-close-x: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M4 4l8 8M12 4L4 12'/%3E%3C/svg%3E");
    box-sizing: border-box !important;
    width: 2.15rem !important;
    height: 2.15rem !important;
    padding: 0 !important;
    margin: 0 0 0 auto !important;
    flex: 0 0 auto;
    opacity: 1 !important;
    filter: none !important;
    border: 1px solid rgba(170, 220, 255, 0.72) !important;
    border-radius: 999px !important;
    background-color: #163056 !important;
    background-image: var(--kyo-close-x) !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
    background-size: 0.85rem 0.85rem !important;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.16),
        0 0 0 1px rgba(0, 0, 0, 0.35),
        0 0 14px rgba(62, 197, 255, 0.22) !important;
    transition: background-color .16s ease, border-color .16s ease, box-shadow .16s ease, transform .16s ease !important;
}
html[data-theme="dark"] .modal .btn-close:hover,
html[data-theme="dark"] .modal .btn-close:focus,
html[data-theme="dark"] .modal .rp-btn-close:hover,
html[data-theme="dark"] .modal .rp-btn-close:focus,
html[data-theme="dark"] .offcanvas .btn-close:hover,
html[data-theme="dark"] .offcanvas .btn-close:focus {
    opacity: 1 !important;
    filter: none !important;
    outline: none !important;
    background-color: rgba(62, 197, 255, 0.2) !important;
    border-color: rgba(214, 242, 255, 0.95) !important;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        0 0 0 3px rgba(62, 197, 255, 0.18),
        0 0 18px rgba(62, 197, 255, 0.38) !important;
    transform: scale(1.06);
}
html[data-theme="dark"] .modal .btn-close:active,
html[data-theme="dark"] .modal .rp-btn-close:active,
html[data-theme="dark"] .offcanvas .btn-close:active {
    transform: scale(0.96);
}
html[data-theme="dark"] .swal2-popup {
    background: #101c30 !important;
    color: #e8f2ff !important;
}

/* ============================================================
   Filtros de grilla: texto y placeholder blancos. Fondo navy intacto.
   Pisa #a89bb0 !important de RpDataTable / DisenoPantallas.
   ============================================================ */
html[data-theme="dark"] .dt-dark thead tr.filters th input,
html[data-theme="dark"] .dt-dark thead tr.filters th input:focus,
html[data-theme="dark"] .dt-dark thead tr.filters th select,
html[data-theme="dark"] .dt-dark thead tr.filters th select:focus,
html[data-theme="dark"] table.dataTable thead tr.filters th input,
html[data-theme="dark"] table.dataTable thead tr.filters th input:focus,
html[data-theme="dark"] table.dataTable thead tr.filters th select,
html[data-theme="dark"] table.dataTable thead tr.filters th select:focus,
html[data-theme="dark"] table.dataTable.dt-dark thead tr.filters th input,
html[data-theme="dark"] table.dataTable.dt-dark thead tr.filters th select,
html[data-theme="dark"] .rp-filter-thead,
html[data-theme="dark"] .rp-filter-thead:focus,
html[data-theme="dark"] .kyo-col-filter,
html[data-theme="dark"] .kyo-col-filter:focus,
html[data-theme="dark"] .dt-input-dark,
html[data-theme="dark"] .dt-input-dark:focus,
html[data-theme="dark"] .dataTables_wrapper .dataTables_filter input,
html[data-theme="dark"] .dataTables_wrapper .dataTables_filter input:focus,
html[data-theme="dark"] .page-99 .dataTables_wrapper .dataTables_filter input,
html[data-theme="dark"] .page-99 .dataTables_wrapper .dataTables_filter input:focus {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}
html[data-theme="dark"] .dt-dark thead tr.filters th input::placeholder,
html[data-theme="dark"] table.dataTable thead tr.filters th input::placeholder,
html[data-theme="dark"] table.dataTable.dt-dark thead tr.filters th input::placeholder,
html[data-theme="dark"] .rp-filter-thead::placeholder,
html[data-theme="dark"] .kyo-col-filter::placeholder,
html[data-theme="dark"] .dt-input-dark::placeholder,
html[data-theme="dark"] .dataTables_wrapper .dataTables_filter input::placeholder,
html[data-theme="dark"] .page-99 .dataTables_wrapper .dataTables_filter input::placeholder {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    opacity: 1 !important;
}
html[data-theme="dark"] thead.filters .select2-container--default .select2-selection--single .select2-selection__rendered,
html[data-theme="dark"] tr.filters .select2-container--default .select2-selection--single .select2-selection__rendered,
html[data-theme="dark"] .dt-dark thead tr.filters th .select2-container--default .select2-selection--single .select2-selection__rendered,
html[data-theme="dark"] table.dataTable thead tr.filters th .select2-container--default .select2-selection--single .select2-selection__rendered,
html[data-theme="dark"] thead.filters .select2-selection__placeholder,
html[data-theme="dark"] tr.filters .select2-selection__placeholder,
html[data-theme="dark"] .dt-dark thead tr.filters .select2-selection__placeholder,
html[data-theme="dark"] table.dataTable thead tr.filters .select2-selection__placeholder,
html[data-theme="dark"] thead.filters .select2-container--default .select2-selection--single .select2-selection__placeholder,
html[data-theme="dark"] tr.filters .select2-container--default .select2-selection--single .select2-selection__placeholder,
html[data-theme="dark"] .dt-dark thead tr.filters .select2-container--default .select2-selection--single .select2-selection__placeholder,
html[data-theme="dark"] table.dataTable thead tr.filters .select2-container--default .select2-selection--single .select2-selection__placeholder {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}

/* ============================================================
   Scrollbars: el pulgar rosa #f4a4b8 es del modo claro.
   ============================================================ */
html[data-theme="dark"],
html[data-theme="dark"] body,
html[data-theme="dark"] * {
    scrollbar-width: thin;
    scrollbar-color: #3ec5ff transparent !important;
}
html[data-theme="dark"] *::-webkit-scrollbar { width: 10px; height: 10px; }
html[data-theme="dark"] *::-webkit-scrollbar-track {
    background: transparent !important;
}
html[data-theme="dark"] *::-webkit-scrollbar-thumb {
    background: #3ec5ff !important;
    border-radius: 8px;
    border: 2px solid transparent !important;
}
html[data-theme="dark"] .kyo-dt-scroll,
html[data-theme="dark"] .dataTables_scrollBody,
html[data-theme="dark"] .dataTables_wrapper .dataTables_scrollBody,
html[data-theme="dark"] .rp-side-nav,
html[data-theme="dark"] .pg-cc-proveedor-list,
html[data-theme="dark"] .ax-rank-list,
html[data-theme="dark"] .dt-dark-wrap thead .filters .select2-selection--multiple .select2-selection__rendered {
    scrollbar-color: #3ec5ff transparent !important;
}
html[data-theme="dark"] .kyo-dt-scroll::-webkit-scrollbar-thumb,
html[data-theme="dark"] .dataTables_scrollBody::-webkit-scrollbar-thumb,
html[data-theme="dark"] .dataTables_wrapper .dataTables_scrollBody::-webkit-scrollbar-thumb,
html[data-theme="dark"] .pg-cc-proveedor-list::-webkit-scrollbar-thumb,
html[data-theme="dark"] .dt-dark-wrap thead .filters .select2-selection__rendered::-webkit-scrollbar-thumb {
    background: #3ec5ff !important;
    border-color: #0e1c36 !important;
}
html[data-theme="dark"] .kyo-dt-scroll::-webkit-scrollbar-track,
html[data-theme="dark"] .dataTables_scrollBody::-webkit-scrollbar-track,
html[data-theme="dark"] .dataTables_wrapper .dataTables_scrollBody::-webkit-scrollbar-track,
html[data-theme="dark"] .pg-cc-proveedor-list::-webkit-scrollbar-track {
    background: #0e1c36 !important;
}

/* ============================================================
   Select2: opciones en blanco. El resaltado sigue azul.
   ============================================================ */
html[data-theme="dark"] .select2-dropdown,
html[data-theme="dark"] .select2-container--default .select2-dropdown {
    background: #0e1c36 !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .select2-container--default .select2-results__option,
html[data-theme="dark"] .select2-dropdown .select2-results__option,
html[data-theme="dark"] .select2-results__option,
html[data-theme="dark"] .modal .select2-results__option,
html[data-theme="dark"] .select2-container--default .select2-results__option[aria-selected="true"],
html[data-theme="dark"] .select2-container--default .select2-results__option[aria-selected="false"],
html[data-theme="dark"] select option {
    background: #0e1c36 !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .select2-container--default .select2-results__option--highlighted,
html[data-theme="dark"] .select2-container--default .select2-results__option--highlighted[aria-selected],
html[data-theme="dark"] .select2-results__option--highlighted,
html[data-theme="dark"] .modal .select2-results__option--highlighted {
    background: #2f7dff !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .select2-search__field,
html[data-theme="dark"] .select2-search--dropdown .select2-search__field,
html[data-theme="dark"] .select2-container--default .select2-selection--single .select2-selection__rendered,
html[data-theme="dark"] .select2-selection__placeholder {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}
html[data-theme="dark"] .select2-search__field::placeholder,
html[data-theme="dark"] .select2-search--dropdown .select2-search__field::placeholder {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    opacity: 1 !important;
}
/* Buscador dentro de la lista: caja fina del mismo tono que la lista (kyo-theme.css le pone una sombra clara grande). */
html[data-theme="dark"] .select2-container--default .select2-search--dropdown {
    background: transparent !important;
    padding: 8px !important;
}
html[data-theme="dark"] .select2-container--default .select2-search--dropdown .select2-search__field {
    background: #13274a !important;
    border: 1px solid rgba(110, 186, 255, 0.22) !important;
    border-radius: 8px !important;
    box-shadow: none !important;
    outline: 0 !important;
    padding: 6px 10px !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}
html[data-theme="dark"] .select2-container--default .select2-search--dropdown .select2-search__field:focus {
    border-color: #2f7dff !important;
    box-shadow: 0 0 0 3px rgba(47, 125, 255, 0.22) !important;
}

/* ============================================================
   Barra superior de carga (rojo → verde)
   ============================================================ */
html[data-theme="dark"] .kyo-table-loading-bar {
    background: linear-gradient(90deg, #ff4d4f 0%, #f5a623 42%, #2ecc71 100%) !important;
    background-size: 100vw 100% !important;
    box-shadow: 0 0 12px rgba(255, 77, 79, 0.4), 0 0 8px rgba(46, 204, 113, 0.35) !important;
}

/* Panel boot de tablas */
html[data-theme="dark"] .kyo-grid-boot-spin {
    border-color: rgba(62, 197, 255, 0.18) !important;
    border-top-color: #3ec5ff !important;
    border-right-color: #60a5fa !important;
    box-shadow: 0 0 0 6px rgba(62, 197, 255, 0.08), 0 0 18px rgba(62, 197, 255, 0.16) !important;
}
html[data-theme="dark"] .kyo-grid-boot-label {
    color: #e7f2ff !important;
}
html[data-theme="dark"] .kyo-grid-boot-hint {
    color: #8eb0d4 !important;
}

/* ============================================================
   Mis datos (perfil)
   ============================================================ */
html[data-theme="dark"] .rp-perfil-block,
html[data-theme="dark"] .rp-perfil-footer,
html[data-theme="dark"] .rp-perfil-hero {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .rp-perfil-hero-title,
html[data-theme="dark"] .rp-perfil-block-head h2 { color: #ffffff !important; }
html[data-theme="dark"] .rp-perfil-kicker,
html[data-theme="dark"] .rp-perfil-hero-sub,
html[data-theme="dark"] .rp-perfil-block-head p,
html[data-theme="dark"] .rp-perfil-label,
html[data-theme="dark"] .rp-perfil-hint { color: #b7cbe6 !important; }
html[data-theme="dark"] .rp-perfil-block-head,
html[data-theme="dark"] .rp-perfil-hero-sub {
    border-color: rgba(62, 197, 255, 0.28) !important;
}
html[data-theme="dark"] .rp-perfil-block-icon.blue {
    background: linear-gradient(135deg, #3ec5ff, #2f7dff) !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .rp-perfil-btn--ghost,
html[data-theme="dark"] .rp-perfil-btn--ghost:hover,
html[data-theme="dark"] .rp-avatar-upload-btn,
html[data-theme="dark"] .rp-avatar-remove-btn {
    background: #12243f !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .rp-perfil-btn--ghost:hover { background: #163056 !important; }
html[data-theme="dark"] .rp-perfil-btn--primary,
html[data-theme="dark"] .rp-perfil-btn--primary:hover {
    background: linear-gradient(135deg, #3ec5ff, #2f7dff) !important;
    color: #ffffff !important;
    border-color: transparent !important;
}
html[data-theme="dark"] .rp-avatar-icon-btn:not(.is-active),
html[data-theme="dark"] .rp-avatar-icon-btn:not(.is-active):hover {
    background: #12243f !important;
    color: #3ec5ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .rp-avatar-icon-btn.is-active {
    color: #ffffff !important;
    border-color: #3ec5ff !important;
}
html[data-theme="dark"] .rp-avatar-photo-note {
    background: #163056 !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .rp-perfil-field .form-control,
html[data-theme="dark"] .rp-perfil-field .form-control:focus {
    background: #07111f !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .rp-perfil-field .form-control::placeholder { color: #ffffff !important; opacity: 1 !important; }
html[data-theme="dark"] .rp-perfil-field > i.fa { color: #3ec5ff !important; }
html[data-theme="dark"] .rp-perfil-meta-item--user,
html[data-theme="dark"] .rp-perfil-pill,
html[data-theme="dark"] .rp-perfil-pill:hover,
html[data-theme="dark"] .rp-modal-switch-btn {
    background: #0e1c36 !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .rp-perfil-pill span,
html[data-theme="dark"] .rp-perfil-pill.is-active span { color: #ffffff !important; }
html[data-theme="dark"] .rp-perfil-pill small { color: #b7cbe6 !important; }
html[data-theme="dark"] .rp-perfil-pill.is-active,
html[data-theme="dark"] .rp-modal-switch-btn.is-active {
    background: #2f7dff !important;
    color: #ffffff !important;
    border-color: #3ec5ff !important;
}
html[data-theme="dark"] .rp-nav-preview,
html[data-theme="dark"] .rp-perfil-pill.is-active .rp-nav-preview {
    background: #07111f !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .rp-nav-preview > span { background: #3ec5ff !important; }

/* ============================================================
   Análisis de datos
   ============================================================ */
html[data-theme="dark"] .ax-toolbar,
html[data-theme="dark"] .ax-nav-sticky,
html[data-theme="dark"] .ax-kpi-card,
html[data-theme="dark"] .ax-chart-card,
html[data-theme="dark"] .ax-chart-body,
html[data-theme="dark"] .ax-loading,
html[data-theme="dark"] .cg-data-card,
html[data-theme="dark"] .ax-rank-item,
html[data-theme="dark"] .ax-rank-item:hover {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .ax-chart-body { background: #0e1c36 !important; }
html[data-theme="dark"] .ax-chip,
html[data-theme="dark"] .ax-chip:hover,
html[data-theme="dark"] .pa-chip,
html[data-theme="dark"] .vt-ax-chip,
html[data-theme="dark"] .vt-ax-chip:hover,
html[data-theme="dark"] .ts-chip,
html[data-theme="dark"] .ts-chip:hover {
    background: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .ax-chip.active,
html[data-theme="dark"] .pa-chip.active,
html[data-theme="dark"] .vt-ax-chip.active,
html[data-theme="dark"] .ts-chip.active {
    background: #2f7dff !important;
    color: #ffffff !important;
    border-color: #2f7dff !important;
}
html[data-theme="dark"] .ax-nav-link,
html[data-theme="dark"] .ax-nav-link:hover,
html[data-theme="dark"] .pa-nav-link,
html[data-theme="dark"] .vt-ax-nav-link,
html[data-theme="dark"] .vt-ax-nav,
html[data-theme="dark"] .vt-ax-toolbar {
    background: transparent !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .ax-nav-sticky,
html[data-theme="dark"] .pa-nav,
html[data-theme="dark"] .vt-ax-nav {
    background: #0e1c36 !important;
}
html[data-theme="dark"] .ax-nav-link.active,
html[data-theme="dark"] .pa-nav-link.active,
html[data-theme="dark"] .vt-ax-nav-link.active {
    background: transparent !important;
    color: #3ec5ff !important;
    box-shadow: inset 0 -2px 0 #2f7dff !important;
}
html[data-theme="dark"] .ax-kpi-label,
html[data-theme="dark"] .ax-kpi-meta,
html[data-theme="dark"] .ax-section-head p,
html[data-theme="dark"] .ax-date-field label { color: #b7cbe6 !important; }
html[data-theme="dark"] .ax-kpi-value,
html[data-theme="dark"] .ax-chart-head h3,
html[data-theme="dark"] .ax-section-head h2,
html[data-theme="dark"] .ax-rank-name,
html[data-theme="dark"] .ax-rank-val { color: #e8f2ff !important; }
html[data-theme="dark"] .ax-section-head h2 i,
html[data-theme="dark"] .ax-chart-head h3 i { color: #3ec5ff !important; }
html[data-theme="dark"] .ax-rank-bar-wrap { background: #1a3054 !important; }
/* Callout "¿Querés el detalle Ideal vs Real?" */
html[data-theme="dark"] .ax-callout {
    background: linear-gradient(135deg, #12243f 0%, #0e1c36 100%) !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .ax-callout strong { color: #e8f2ff !important; }
html[data-theme="dark"] .ax-callout p { color: #b7cbe6 !important; }
html[data-theme="dark"] .ax-callout .btn,
html[data-theme="dark"] .ax-callout .btn-new {
    background: #2f7dff !important;
    border-color: #2f7dff !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .ax-callout .btn:hover,
html[data-theme="dark"] .ax-callout .btn-new:hover {
    background: #4a90ff !important;
    border-color: #4a90ff !important;
}
html[data-theme="dark"] .vt-ax,
html[data-theme="dark"] .vt-page,
html[data-theme="dark"] .pd-page {
    --oa-ink: #e8f2ff;
    --oa-muted: #b7cbe6;
    --oa-surface: #12243f;
    --oa-cream: #0e1c36;
    --oa-border: rgba(62, 197, 255, 0.35);
    color: #e8f2ff;
}
html[data-theme="dark"] .vt-ax-kpi,
html[data-theme="dark"] .vt-ax-card,
html[data-theme="dark"] .vt-ax-loading,
html[data-theme="dark"] .vt-kpi,
html[data-theme="dark"] .vt-hero,
html[data-theme="dark"] .vt-file-card,
html[data-theme="dark"] .vt-step,
html[data-theme="dark"] .pd-panel,
html[data-theme="dark"] .pd-kpi,
html[data-theme="dark"] .pd-hero,
html[data-theme="dark"] .ts-cuenta,
html[data-theme="dark"] .ts-panel,
html[data-theme="dark"] .ts-kpi,
html[data-theme="dark"] .ts-hero,
html[data-theme="dark"] .ts-toolbar,
html[data-theme="dark"] .fg-tabs,
html[data-theme="dark"] .pg-tabs-nav,
html[data-theme="dark"] .pg-tab-content,
html[data-theme="dark"] .pg-pago-card,
html[data-theme="dark"] .pg-pago-form-shell,
html[data-theme="dark"] .pg-panel-hero,
html[data-theme="dark"] .rm-page .rm-hero,
html[data-theme="dark"] .rm-page .rm-tabs-wrap,
html[data-theme="dark"] .oc-card-item,
html[data-theme="dark"] .oc-page .oc-hero {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}

/* ============================================================
   Cuenta corriente de proveedores
   ============================================================ */
html[data-theme="dark"] .pg-cc-page .cc-header,
html[data-theme="dark"] .pg-cc-page .cc-stat,
html[data-theme="dark"] .pg-cc-page .card-glass,
html[data-theme="dark"] .pg-cc-master-head,
html[data-theme="dark"] .pg-cc-detail-head,
html[data-theme="dark"] .pg-cc-master-filters,
html[data-theme="dark"] .pg-cc-filters,
html[data-theme="dark"] .pg-cc-proveedor-item,
html[data-theme="dark"] .pg-cc-proveedor-item:hover,
html[data-theme="dark"] .pg-cc-page .dataTables_wrapper .dataTables_paginate {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .pg-cc-page .card-glass,
html[data-theme="dark"] .pg-cc-filters { background: #0e1c36 !important; }
html[data-theme="dark"] .pg-cc-proveedor-item.is-active {
    background: #163056 !important;
    border-left: 4px solid #3ec5ff !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .pg-cc-proveedor-item--todos {
    margin: 0.55rem 0.55rem 0.45rem;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    border-left: 4px solid #3ec5ff !important;
    border-radius: 12px;
    background:
        linear-gradient(135deg, rgba(62, 197, 255, 0.22) 0%, rgba(47, 125, 255, 0.12) 45%, #12243f 100%) !important;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.28) !important;
}
html[data-theme="dark"] .pg-cc-proveedor-item--todos:hover {
    background:
        linear-gradient(135deg, rgba(62, 197, 255, 0.3) 0%, rgba(47, 125, 255, 0.16) 50%, #152a48 100%) !important;
    border-color: rgba(62, 197, 255, 0.5) !important;
}
html[data-theme="dark"] .pg-cc-proveedor-item--todos.is-active {
    background:
        linear-gradient(135deg, rgba(62, 197, 255, 0.34) 0%, rgba(47, 125, 255, 0.18) 45%, #163056 100%) !important;
    border-color: rgba(62, 197, 255, 0.55) !important;
    border-left-color: #5ad4ff !important;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35), inset 0 0 0 1px rgba(62, 197, 255, 0.18) !important;
}
html[data-theme="dark"] .pg-cc-todos-ico {
    background: linear-gradient(145deg, #3ec5ff, #2f7dff) !important;
    color: #04101f !important;
    box-shadow: 0 3px 10px rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .pg-cc-proveedor-item--todos .pg-cc-nombre {
    color: #9fe7ff !important;
}
html[data-theme="dark"] .pg-cc-proveedor-item--todos .pg-cc-cuit {
    color: #8eb0d4 !important;
}
html[data-theme="dark"] .pg-cc-proveedor-item--todos .pg-cc-saldo {
    background: rgba(62, 197, 255, 0.14) !important;
}
html[data-theme="dark"] .pg-cc-master-head h6,
html[data-theme="dark"] .pg-cc-detail-head h6,
html[data-theme="dark"] .pg-cc-nombre,
html[data-theme="dark"] .pg-cc-page .cc-header h2,
html[data-theme="dark"] .pg-cc-kpi-name { color: #ffffff !important; }
html[data-theme="dark"] .pg-cc-master-head i { color: #3ec5ff !important; }
html[data-theme="dark"] .pg-cc-detail-title-icon {
    background: linear-gradient(135deg, #3ec5ff, #2f7dff) !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .pg-cc-cuit,
html[data-theme="dark"] .pg-cc-detail-sub,
html[data-theme="dark"] .pg-cc-field-label,
html[data-theme="dark"] .pg-cc-empty,
html[data-theme="dark"] .pg-cc-master-filters .form-check-label,
html[data-theme="dark"] .pg-cc-page .cc-stat .label { color: #b7cbe6 !important; }
html[data-theme="dark"] .pg-cc-page .cc-stat .value { color: #e8f2ff !important; }
html[data-theme="dark"] .pg-cc-saldo,
html[data-theme="dark"] .pg-cc-saldo.positivo,
html[data-theme="dark"] .pg-cc-saldo.negativo,
html[data-theme="dark"] .pg-cc-saldo.cero {
    background: #163056 !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35);
}
/* Debe / Haber / Saldo de los movimientos: sin grises violáceos en oscuro */
html[data-theme="dark"] .cc-amt--debe { color: #ff8a8a !important; }
html[data-theme="dark"] .cc-amt--haber { color: #5ce6a0 !important; }
html[data-theme="dark"] .cc-amt--saldo { color: #e8f2ff !important; }
html[data-theme="dark"] .cc-amt--saldo.is-positivo { color: #ff8a8a !important; }
html[data-theme="dark"] .cc-amt--saldo.is-negativo { color: #5ce6a0 !important; }
html[data-theme="dark"] .cc-amt--muted { color: #8fb0d6 !important; }

/* Sin violetas en modo oscuro (iconos/etiquetas "purple" de otras pantallas) */
html[data-theme="dark"] .rp-perfil-block-icon.purple,
html[data-theme="dark"] .rp-config-icon.purple {
    background: #163056 !important;
    color: #3ec5ff !important;
}
html[data-theme="dark"] .rp-data-card--purple,
html[data-theme="dark"] .cg-data-card--purple { border-color: rgba(62, 197, 255, 0.3) !important; }
html[data-theme="dark"] .ts-badge--violet {
    background: #163056 !important;
    color: #3ec5ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .ts-kpi--violet { border-top-color: #3ec5ff !important; }
html[data-theme="dark"] .usr-donde-empty {
    color: #6d8eaf !important;
    opacity: 0.7;
}
html[data-theme="dark"] .usr-donde-pill {
    color: #cfe6ff !important;
    background: linear-gradient(135deg, rgba(47, 125, 255, 0.22), rgba(62, 197, 255, 0.08)) !important;
    border: 1px solid rgba(96, 165, 250, 0.22) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] a.usr-donde-pill:hover {
    color: #ffffff !important;
    background: linear-gradient(135deg, rgba(47, 125, 255, 0.36), rgba(62, 197, 255, 0.14)) !important;
    border-color: rgba(96, 165, 250, 0.4) !important;
}
html[data-theme="dark"] .usr-donde-ico { color: #7ad7ff !important; opacity: 1; }
html[data-theme="dark"] .usr-donde-go { color: #9ec6ea !important; }
html[data-theme="dark"] a.usr-donde-pill:hover .usr-donde-go { color: #ffffff !important; }
html[data-theme="dark"] .usr-presence-label.is-online {
    color: #4ade80 !important;
    background: rgba(74, 222, 128, 0.12) !important;
    border-color: rgba(74, 222, 128, 0.28) !important;
}
html[data-theme="dark"] .usr-presence-label.is-offline {
    color: #8eb0d4 !important;
    background: rgba(148, 163, 184, 0.08) !important;
    border-color: rgba(148, 163, 184, 0.14) !important;
}
html[data-theme="dark"] .usr-user-name { color: #e8f2ff !important; }
html[data-theme="dark"] .rp-modal-preview-sheet { background: linear-gradient(180deg, #2f7dff, #3ec5ff) !important; }

/* saldo del proveedor: rojo = les debemos, verde = nos deben */
html[data-theme="dark"] .pg-cc-saldo.positivo {
    background: rgba(255, 90, 90, 0.16) !important;
    color: #ff8a8a !important;
    border: 1px solid rgba(255, 110, 110, 0.55);
}
html[data-theme="dark"] .pg-cc-saldo.negativo {
    background: rgba(61, 206, 122, 0.16) !important;
    color: #5ce6a0 !important;
    border: 1px solid rgba(61, 206, 122, 0.55);
}
html[data-theme="dark"] .pg-cc-page .dt-dark thead th,
html[data-theme="dark"] .pg-cc-page table.dataTable thead th {
    background: linear-gradient(180deg, #1d5bff 0%, #123a9a 100%) !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .pg-cc-page table.dataTable tbody td,
html[data-theme="dark"] .pg-cc-page table.dataTable.display tbody tr:nth-child(odd) td,
html[data-theme="dark"] .pg-cc-page table.dataTable.display tbody tr:nth-child(even) td {
    background: #0e1c36 !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pg-cc-page table.dataTable tbody tr:hover td {
    background: #163056 !important;
}
html[data-theme="dark"] #pccBuscar,
html[data-theme="dark"] #pccBuscar::placeholder {
    color: #ffffff !important;
    opacity: 1 !important;
}

html[data-theme="dark"] .pg-cc-btn-pago {
    background: rgba(62, 197, 255, 0.12) !important;
    border-color: rgba(62, 197, 255, 0.45) !important;
    color: #3ec5ff !important;
}
html[data-theme="dark"] .pcc-pago-saldo,
html[data-theme="dark"] .pcc-pago-hint {
    color: #9fb3c8;
}
html[data-theme="dark"] .pg-cc-btn-masivo {
    background: linear-gradient(135deg, #3ec5ff, #2f7dff) !important;
    color: #fff !important;
}
html[data-theme="dark"] .pcc-masivo-scrim { background: rgba(4, 10, 22, 0.72); }
html[data-theme="dark"] .pcc-masivo-panel,
html[data-theme="dark"] .pcc-masivo-foot,
html[data-theme="dark"] .pcc-masivo-card,
html[data-theme="dark"] .pcc-masivo-compra,
html[data-theme="dark"] .pcc-masivo-x,
html[data-theme="dark"] .pcc-masivo-bar-actions button,
html[data-theme="dark"] .pcc-masivo-chips span,
html[data-theme="dark"] .pcc-masivo-field input,
html[data-theme="dark"] .pcc-masivo-field select,
html[data-theme="dark"] .pcc-masivo-importe {
    background: #0e1c36 !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .pcc-masivo-head {
    background: #12243f !important;
    border-color: rgba(62, 197, 255, 0.28) !important;
}
html[data-theme="dark"] .pcc-masivo-head h2,
html[data-theme="dark"] .pcc-masivo-check strong,
html[data-theme="dark"] .pcc-masivo-card-nums b,
html[data-theme="dark"] .pcc-masivo-meta-chip b,
html[data-theme="dark"] .pcc-masivo-foot-total { color: #ffffff !important; }
html[data-theme="dark"] .pcc-masivo-head p,
html[data-theme="dark"] .pcc-masivo-check small,
html[data-theme="dark"] .pcc-masivo-field span,
html[data-theme="dark"] .pcc-masivo-card-nums span,
html[data-theme="dark"] .pcc-masivo-compra-meta,
html[data-theme="dark"] .pcc-masivo-meta-chip,
html[data-theme="dark"] .pcc-masivo-apagar span,
html[data-theme="dark"] .pcc-masivo-foot-kicker,
html[data-theme="dark"] .pcc-masivo-empty { color: #b7cbe6 !important; }
html[data-theme="dark"] .pcc-masivo-meta-chip {
    background: rgba(62, 197, 255, 0.1) !important;
}
html[data-theme="dark"] .pcc-masivo-meta-chip.is-pend {
    background: rgba(62, 197, 255, 0.16) !important;
    color: #9fd6ff !important;
}
html[data-theme="dark"] .pcc-masivo-meta-chip.is-pend b {
    color: #7dd3fc !important;
}
html[data-theme="dark"] .pcc-masivo-compra.is-on {
    background: #163056 !important;
    border-color: #3ec5ff !important;
}
html[data-theme="dark"] .pcc-masivo-otros {
    background: #2a2414 !important;
    color: #f3d48a !important;
}
html[data-theme="dark"] .pcc-masivo-importe { color: #b6f5c2 !important; }
html[data-theme="dark"] .pcc-masivo-pagar {
    background: linear-gradient(135deg, #1b8f4a, #2f7dff) !important;
}
html[data-theme="dark"] .pcc-masivo-tipo {
    background: #0e1c36 !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .pcc-masivo-tipo button {
    background: transparent !important;
    color: #8eb0d4 !important;
}
html[data-theme="dark"] .pcc-masivo-tipo button.is-on {
    background: rgba(62, 197, 255, 0.22) !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pcc-masivo-badge--compra {
    background: rgba(62, 197, 255, 0.18) !important;
    color: #9ec1ff !important;
}
html[data-theme="dark"] .pcc-masivo-badge--fd {
    background: rgba(232, 168, 56, 0.2) !important;
    color: #f0c878 !important;
}
html[data-theme="dark"] .pcc-masivo-compra.is-fd {
    border-color: rgba(232, 168, 56, 0.35) !important;
    background: linear-gradient(90deg, rgba(232, 168, 56, 0.12), #0e1c36 42%) !important;
}
html[data-theme="dark"] .pcc-masivo-compra.is-fd.is-on {
    background: #163056 !important;
}

/* ---- Cuenta corriente / modales: nada violeta, rosa ni gris malva en oscuro ----
   Solo restos de las reglas del tema claro que se filtraban (focos rosa, sombras magenta,
   textos gris-malva, accent-color magenta). */
html[data-theme="dark"] .pg-cc-page {
    --cc-panel-border: rgba(62, 197, 255, 0.35);
    --cc-panel-shadow: none;
    --cc-accent: #3ec5ff;
    --cc-accent-soft: #163056;
    --cc-head-bg: #12243f;
}

/* Anillo de foco azul (en claro es rosa y no tenía override de box-shadow en oscuro) */
html[data-theme="dark"] :is(.form-control, .form-select, .rp-input, .rp-search-input, textarea, select,
    input[type="text"], input[type="search"], input[type="number"], input[type="date"], input[type="email"], input[type="password"]):focus,
html[data-theme="dark"] .modal :is(.form-control, .form-select):focus,
html[data-theme="dark"] .rp-modal :is(.rp-input, .rp-search-input):focus,
html[data-theme="dark"] .pg-pago-form-shell :is(.form-control, .form-select):focus,
html[data-theme="dark"] .pg-cc-master-filters .form-control:focus,
html[data-theme="dark"] .pg-cc-filters :is(.form-control, .form-select):focus,
html[data-theme="dark"] .pcc-masivo-field :is(input, select):focus,
html[data-theme="dark"] .filter-bar :is(.form-control, .form-select):focus,
html[data-theme="dark"] .dt-dark thead tr.filters th :is(input, select):focus,
html[data-theme="dark"] :is(.rp-filter-thead, .kyo-col-filter):focus {
    border-color: #3ec5ff !important;
    box-shadow: 0 0 0 3px rgba(62, 197, 255, 0.22) !important;
    outline: none !important;
}
html[data-theme="dark"] .rp-col-config-check:focus-visible + .rp-col-config-box {
    outline: 2px solid rgba(62, 197, 255, 0.55) !important;
    outline-offset: 2px;
}

/* Header y botones */
html[data-theme="dark"] .pg-cc-btn-masivo,
html[data-theme="dark"] .pg-cc-btn-masivo:hover {
    box-shadow: 0 6px 16px rgba(47, 125, 255, 0.35) !important;
}
html[data-theme="dark"] .pg-cc-detail-title-icon {
    box-shadow: 0 4px 12px rgba(47, 125, 255, 0.35) !important;
}
html[data-theme="dark"] .pg-cc-search-wrap > i { color: #8eb0d4; }

/* Grilla de movimientos: borde y línea del encabezado en azul */
html[data-theme="dark"] .pg-cc-page .dt-dark-wrap {
    border-color: rgba(62, 197, 255, 0.28) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .pg-cc-page .dt-dark thead th,
html[data-theme="dark"] .pg-cc-page table.dataTable thead th {
    border-bottom: 2px solid rgba(62, 197, 255, 0.45) !important;
}

/* Modal "Registrar pago a proveedor" */
html[data-theme="dark"] .pg-pago-modal-intro,
html[data-theme="dark"] .pg-pago-hint,
html[data-theme="dark"] .pg-pago-modal .pcc-pago-hint { color: #b7cbe6; }
html[data-theme="dark"] .pg-input-money-prefix { color: #8eb0d4; }
html[data-theme="dark"] .pg-input-money-wrap .pg-input-money { color: #e8f2ff; }
html[data-theme="dark"] .pg-req { color: #ff8a8a; }
html[data-theme="dark"] .pg-form-section { color: #7ad7ff; }
html[data-theme="dark"] .pg-pago-modal .pg-pago-form-shell {
    border: 1px solid rgba(62, 197, 255, 0.28) !important;
    background: #0e1c36 !important;
}
html[data-theme="dark"] .pg-pago-modal .select2-container--default .select2-selection--single .select2-selection__rendered,
html[data-theme="dark"] .pg-pago-modal .select2-container .select2-selection--single .select2-selection__rendered {
    padding-left: 0.9rem !important;
    padding-right: 2.1rem !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .pg-pago-modal .pg-pago-form-shell .form-control,
html[data-theme="dark"] .pg-pago-modal .pg-pago-form-shell .form-select {
    padding: 0.55rem 0.9rem !important;
}
html[data-theme="dark"] .pg-pago-modal .pg-pago-form-shell .pg-input-money-wrap .pg-input-money {
    padding-left: 1.85rem !important;
}

/* Panel "Pago masivo" */
html[data-theme="dark"] .pcc-masivo-check input { accent-color: #3ec5ff; }
html[data-theme="dark"] .pcc-masivo-panel { box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6) !important; }
html[data-theme="dark"] .pcc-masivo-card,
html[data-theme="dark"] .pcc-masivo-x { box-shadow: none !important; }
html[data-theme="dark"] .pcc-masivo-pagar:disabled {
    background: #1a2c4a !important;
    color: #7f98b8 !important;
    box-shadow: none !important;
}

/* ============================================================
   Heroes: la barra y el bloque del título son el mismo navy.
   [class*="-hero"] pintaba también -hero-left y dejaba un recorte.
   ============================================================ */
html[data-theme="dark"] .vt-ax-hero,
html[data-theme="dark"] .pd-hero,
html[data-theme="dark"] .pa-hero,
html[data-theme="dark"] .ax-hero,
html[data-theme="dark"] .ts-hero,
html[data-theme="dark"] .cc-kpi,
html[data-theme="dark"] .cc-kpi.cc-card,
html[data-theme="dark"] .rm-page .rm-hero {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-ax-hero-left,
html[data-theme="dark"] .vt-ax-hero-right,
html[data-theme="dark"] .vt-ax-hero-inner,
html[data-theme="dark"] .vt-ax-hero-pattern,
html[data-theme="dark"] .vt-ax-title,
html[data-theme="dark"] .vt-ax-sub,
html[data-theme="dark"] .vt-ax-eyebrow,
html[data-theme="dark"] .pd-hero-left,
html[data-theme="dark"] .pd-hero-inner,
html[data-theme="dark"] .pd-hero-actions,
html[data-theme="dark"] .pd-hero-title,
html[data-theme="dark"] .pd-hero-sub,
html[data-theme="dark"] .pd-eyebrow,
html[data-theme="dark"] .pa-hero-left,
html[data-theme="dark"] .pa-hero-right,
html[data-theme="dark"] .pa-hero-inner,
html[data-theme="dark"] .pa-hero-pattern,
html[data-theme="dark"] .ax-hero-left,
html[data-theme="dark"] .ax-hero-right,
html[data-theme="dark"] .ax-hero-inner,
html[data-theme="dark"] .ts-hero-left,
html[data-theme="dark"] .ts-hero-right,
html[data-theme="dark"] .ts-hero-inner,
html[data-theme="dark"] .ts-hero-pattern,
html[data-theme="dark"] .ts-title,
html[data-theme="dark"] .ts-sub,
html[data-theme="dark"] .ts-eyebrow {
    background: transparent !important;
    background-image: none !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-ax-hero-glow,
html[data-theme="dark"] .pd-hero-glow,
html[data-theme="dark"] .pa-hero-glow,
html[data-theme="dark"] .ts-hero-glow {
    display: none !important;
}
html[data-theme="dark"] .vt-ax-title,
html[data-theme="dark"] .pd-hero-title,
html[data-theme="dark"] .pa-title,
html[data-theme="dark"] .ax-hero-title,
html[data-theme="dark"] .ts-title,
html[data-theme="dark"] .cc-kpi-title {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .vt-ax-sub,
html[data-theme="dark"] .pd-hero-sub,
html[data-theme="dark"] .pa-sub,
html[data-theme="dark"] .ax-hero-sub,
html[data-theme="dark"] .ts-sub,
html[data-theme="dark"] .cc-kpi .cc-muted,
html[data-theme="dark"] .vt-ax-eyebrow,
html[data-theme="dark"] .pd-eyebrow,
html[data-theme="dark"] .ts-eyebrow {
    color: #b7cbe6 !important;
}
html[data-theme="dark"] .vt-ax-hero-mark,
html[data-theme="dark"] .pa-hero-mark,
html[data-theme="dark"] .ts-hero-mark,
html[data-theme="dark"] .pd-hero-icon,
html[data-theme="dark"] .ax-hero-icon,
html[data-theme="dark"] .cc-kpi-icon {
    background: #163056 !important;
    background-image: none !important;
    color: #3ec5ff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}

/* Volver: cuadrado navy, flecha blanca, mismo alto que las acciones */
html[data-theme="dark"] .vt-ax-back,
html[data-theme="dark"] .vt-ax-back:hover,
html[data-theme="dark"] .pd-back,
html[data-theme="dark"] .pd-back:hover,
html[data-theme="dark"] .pa-back,
html[data-theme="dark"] .pa-back:hover,
html[data-theme="dark"] .ts-back,
html[data-theme="dark"] .ts-back:hover,
html[data-theme="dark"] .cg-btn-back,
html[data-theme="dark"] .cg-btn-back:hover,
html[data-theme="dark"] .rm-page .rm-btn-back,
html[data-theme="dark"] .rm-page .rm-btn-back:hover,
html[data-theme="dark"] .cc-kpi .btn-outline-light,
html[data-theme="dark"] .cc-kpi .btn-outline-light:hover {
    background: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-ax-back,
html[data-theme="dark"] .pd-back,
html[data-theme="dark"] .pa-back,
html[data-theme="dark"] .ts-back,
html[data-theme="dark"] .pd-hero-icon {
    width: 42px !important;
    height: 42px !important;
    min-height: 42px !important;
}

/* Píldora de período (Personalizado / Este mes) y Actualizar */
html[data-theme="dark"] .vt-ax-period-pill,
html[data-theme="dark"] .ax-hero-period,
html[data-theme="dark"] .pa-period-pill,
html[data-theme="dark"] .ts-pill {
    background: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
    min-height: 42px;
}
html[data-theme="dark"] .vt-ax-period-pill i,
html[data-theme="dark"] .ax-hero-period i,
html[data-theme="dark"] .ts-pill i,
html[data-theme="dark"] .ts-pill strong,
html[data-theme="dark"] .pa-period-pill i {
    color: #ffffff !important;
}
html[data-theme="dark"] .vt-ax-btn-primary,
html[data-theme="dark"] .vt-ax-btn-primary:hover,
html[data-theme="dark"] .pa-btn-primary,
html[data-theme="dark"] .pa-btn-primary:hover,
html[data-theme="dark"] .ax-btn-refresh,
html[data-theme="dark"] .ax-btn-refresh:hover,
html[data-theme="dark"] .ts-btn--primary,
html[data-theme="dark"] .ts-btn--primary:hover {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: #2f7dff !important;
    box-shadow: none !important;
    min-height: 42px;
}

/* Nuevo pedido: Anular ghost, Emitir azul, Guardar verde sólido */
html[data-theme="dark"] .pd-btn--ghost,
html[data-theme="dark"] .pd-btn--ghost:hover {
    background: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
    height: 42px;
}
html[data-theme="dark"] .pd-btn--sage,
html[data-theme="dark"] .pd-btn--sage:hover {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: #2f7dff !important;
    box-shadow: none !important;
    height: 42px;
}
html[data-theme="dark"] .pd-btn--primary,
html[data-theme="dark"] .pd-btn--primary:hover {
    background: #1f8f4e !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: #1f8f4e !important;
    box-shadow: none !important;
    height: 42px;
}

/* Stock / Finanzas: tab activa y Ajuste de stock, Transferir outline */
html[data-theme="dark"] .fg-tabs {
    background: #12243f !important;
    background-image: none !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .fg-tab,
html[data-theme="dark"] .fg-tab:hover {
    background: transparent !important;
    background-image: none !important;
    color: #b7cbe6 !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .fg-tab.active,
html[data-theme="dark"] .fg-tab.active:hover {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .ts-btn--ghost,
html[data-theme="dark"] .ts-btn--ghost:hover {
    background: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}

/* ============================================================
   Orden de compra / Nueva compra — fichas y bandas
   ============================================================ */
html[data-theme="dark"] .cc-card,
html[data-theme="dark"] .oc-page .cc-section.cc-card,
html[data-theme="dark"] .compras-wrapper .cc-card,
html[data-theme="dark"] .cc-table,
html[data-theme="dark"] .oc-actions-bar {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .cc-titlebar,
html[data-theme="dark"] .compras-step-label {
    background: #163056 !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .cc-titlebar h3,
html[data-theme="dark"] .cc-titlebar h3 i {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .cc-titlebar h3 i { color: #3ec5ff !important; }
html[data-theme="dark"] .oc-page label.form-label,
html[data-theme="dark"] .cc-container-xxl label.form-label,
html[data-theme="dark"] .oc-page .cc-muted,
html[data-theme="dark"] .compras-wrapper .text-muted-cc,
html[data-theme="dark"] .oc-page .oc-label {
    color: #b7cbe6 !important;
}
html[data-theme="dark"] .oc-page .oc-costo .form-control,
html[data-theme="dark"] .oc-page #CostoTotal,
html[data-theme="dark"] #CostoTotal {
    background: #12243f !important;
    background-image: none !important;
    color: #3ec5ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .compras-total-final { color: #3ec5ff !important; }
html[data-theme="dark"] .oc-banner--green,
html[data-theme="dark"] .oc-banner--yellow {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    border-left: 4px solid #1f8f4e !important;
}
html[data-theme="dark"] .oc-banner--yellow { border-left-color: #e0b15a !important; }
html[data-theme="dark"] .oc-banner--green i { color: #3dce7a !important; }
html[data-theme="dark"] .oc-banner-title,
html[data-theme="dark"] .oc-banner-text { color: #e8f2ff !important; }
html[data-theme="dark"] .oc-banner-text a,
html[data-theme="dark"] .oc-banner-text button { color: #3ec5ff !important; }
html[data-theme="dark"] .compras-detalle-table thead th,
html[data-theme="dark"] .detalle-table thead th,
html[data-theme="dark"] .cc-table table.dataTable thead th,
html[data-theme="dark"] .oc-page .cc-table table.dataTable thead th {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: transparent !important;
}
html[data-theme="dark"] .compras-detalle-table tbody td,
html[data-theme="dark"] .compras-detalle-table tbody tr,
html[data-theme="dark"] .compras-detalle-table tbody tr:nth-child(odd),
html[data-theme="dark"] .compras-detalle-table tbody tr:nth-child(even),
html[data-theme="dark"] .compras-detalle-table tbody tr:hover,
html[data-theme="dark"] .detalle-table tbody tr,
html[data-theme="dark"] .detalle-table tbody td,
html[data-theme="dark"] .oc-page .cc-table table.dataTable tbody td,
html[data-theme="dark"] .cc-table table.dataTable tbody tr:nth-child(odd) td,
html[data-theme="dark"] .cc-table table.dataTable tbody tr:nth-child(even) td,
html[data-theme="dark"] .cc-table table.dataTable tbody tr:hover td {
    background: #0e1c36 !important;
    background-color: #0e1c36 !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .compras-insumo-nombre,
html[data-theme="dark"] .cell-insumo .insumo-main,
html[data-theme="dark"] .oc-card-title,
html[data-theme="dark"] .oc-value { color: #e8f2ff !important; }
html[data-theme="dark"] .compras-insumo-extra,
html[data-theme="dark"] .oc-card-sub { color: #b7cbe6 !important; }

/* Factura / documentos — adjuntos: sin blanco ni violeta en oscuro */
html[data-theme="dark"] .compras-adjuntos-ayuda {
    color: #8eb0d4 !important;
}
html[data-theme="dark"] .compras-adjuntos-ayuda strong {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .compras-adjunto-card {
    background: #0e1c36 !important;
    background-image: none !important;
    border-color: rgba(62, 197, 255, 0.28) !important;
    color: #e8f2ff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .compras-adjunto-thumb {
    background: #12243f !important;
    border: 1px solid rgba(62, 197, 255, 0.2);
}
html[data-theme="dark"] .compras-adjunto-icon {
    background: #163056 !important;
    color: #3ec5ff !important;
}
html[data-theme="dark"] .compras-adjunto-nombre {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .compras-adjunto-nombre:hover {
    color: #7ad7ff !important;
}
html[data-theme="dark"] .compras-adjunto-meta {
    color: #8eb0d4 !important;
}
html[data-theme="dark"] .compras-adjunto-del {
    color: #f87171 !important;
}
html[data-theme="dark"] .compras-adjunto-del:hover {
    color: #fca5a5 !important;
}
html[data-theme="dark"] .compras-adjuntos-actions .btn-new,
html[data-theme="dark"] .compras-adjuntos-actions .btn-new:hover {
    background: linear-gradient(135deg, #2f7dff, #1a4fd0) !important;
    color: #fff !important;
    box-shadow: 0 2px 8px rgba(47, 125, 255, 0.22) !important;
}

/* ============================================================
   Receta y SubReceta (mismas clases .rm-page)
   ============================================================ */
html[data-theme="dark"] .rm-page .rm-cost-card,
html[data-theme="dark"] .rm-page .rm-cost-card--highlight,
html[data-theme="dark"] .rm-page .rm-cost-card--accent,
html[data-theme="dark"] .rm-page .rm-panel,
html[data-theme="dark"] .rm-page .rm-panel-body,
html[data-theme="dark"] .rm-page .rm-table-wrap,
html[data-theme="dark"] .rm-page .dataTables_wrapper,
html[data-theme="dark"] .rm-page .rm-action-bar {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .rm-page .rm-cost-label,
html[data-theme="dark"] .rm-page .rm-panel-head h3,
html[data-theme="dark"] .rm-page .rm-table-toolbar-title { color: #ffffff !important; }
html[data-theme="dark"] .rm-page .rm-cost-input,
html[data-theme="dark"] .rm-page .rm-cost-card--accent .rm-cost-input,
html[data-theme="dark"] .rm-page .rm-panel-head h3 i,
html[data-theme="dark"] .rm-page .rm-table-toolbar-title i {
    color: #3ec5ff !important;
    background: transparent !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .rm-page .rm-panel-head,
html[data-theme="dark"] .rm-page .rm-tabs-wrap,
html[data-theme="dark"] .rm-page .rm-table-toolbar {
    background: #163056 !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .rm-page .rm-tabs .nav-link,
html[data-theme="dark"] .rm-page .rm-tabs .nav-link:hover {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .rm-page .rm-tabs .nav-link.active,
html[data-theme="dark"] .rm-page .rm-tabs .nav-link.active:hover {
    background: #2f7dff !important;
    color: #ffffff !important;
    border-color: #2f7dff !important;
}
html[data-theme="dark"] .rm-page label.form-label,
html[data-theme="dark"] .rm-page .rm-form-grid .form-label {
    color: #b7cbe6 !important;
}
html[data-theme="dark"] .rm-page table.dataTable tbody td,
html[data-theme="dark"] .rm-page table.dataTable.display tbody tr:nth-child(odd) td,
html[data-theme="dark"] .rm-page table.dataTable.display tbody tr:nth-child(even) td,
html[data-theme="dark"] .rm-page table.dataTable tbody tr:hover td,
html[data-theme="dark"] .rm-page td.dataTables_empty {
    background: #12243f !important;
    background-color: #12243f !important;
    color: #b7cbe6 !important;
}
html[data-theme="dark"] .rm-page .dataTables_wrapper .dataTables_info,
html[data-theme="dark"] .rm-page .dataTables_wrapper .dataTables_paginate {
    color: #b7cbe6 !important;
    background: transparent !important;
}
html[data-theme="dark"] .rm-page .dataTables_wrapper .dataTables_paginate .paginate_button {
    color: #e8f2ff !important;
    background: transparent !important;
}
html[data-theme="dark"] .rm-page .dataTables_wrapper .dataTables_paginate .paginate_button.current,
html[data-theme="dark"] .rm-page .dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
    background: #2f7dff !important;
    color: #ffffff !important;
    border-color: #2f7dff !important;
}
html[data-theme="dark"] .rm-page .btnacciones,
html[data-theme="dark"] .rm-page .btnacciones:hover {
    background: #163056 !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .modal .cc-modal {
    background: #12243f !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .modal .cc-modal-header {
    background: #163056 !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .modal .cc-modal-footer {
    background: #0e1c36 !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}

/* Selects con [+] (Unidad de Medida, Categoría) y Select2 de modales */
html[data-theme="dark"] .input-plus,
html[data-theme="dark"] .input-group.input-plus {
    background: #07111f !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .input-plus.input-plus .select2-container .select2-selection--single,
html[data-theme="dark"] .input-plus.input-plus .select2-container--default .select2-selection--single,
html[data-theme="dark"] .input-plus.input-plus > .form-select,
html[data-theme="dark"] .input-plus.input-plus > .form-control,
html[data-theme="dark"] .input-plus.input-plus > select:not(.select2-hidden-accessible),
html[data-theme="dark"] .modal .select2-container .select2-selection--single,
html[data-theme="dark"] .modal .select2-container .select2-selection--multiple,
html[data-theme="dark"] .modal .select2-container--default .select2-selection--single,
html[data-theme="dark"] .rm-page .select2-container--default .select2-selection--single,
html[data-theme="dark"] .rm-page .select2-container .select2-selection--single {
    background: #07111f !important;
    background-color: #07111f !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .input-plus.input-plus .select2-selection--single .select2-selection__rendered,
html[data-theme="dark"] .modal .select2-container--default .select2-selection--single .select2-selection__rendered,
html[data-theme="dark"] .modal .select2-container .select2-selection__rendered,
html[data-theme="dark"] .rm-page .select2-container--default .select2-selection--single .select2-selection__rendered {
    color: #ffffff !important;
}
html[data-theme="dark"] .input-plus .btn-plus,
html[data-theme="dark"] .input-plus.input-plus .btn-plus {
    color: #22c55e !important;
    background: rgba(34, 197, 94, 0.16) !important;
    border-left-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .input-plus:focus-within,
html[data-theme="dark"] .input-plus:has(.select2-container--open) {
    border-color: #3ec5ff !important;
    box-shadow: 0 0 0 3px rgba(62, 197, 255, 0.22) !important;
}

/* Invalid Select2 / input-plus: rojo gana a borde/foco azul de arriba */
html[data-theme="dark"] .input-plus.is-invalid,
html[data-theme="dark"] .input-plus:has(.is-invalid),
html[data-theme="dark"] .input-group.input-plus.is-invalid,
html[data-theme="dark"] .input-group.input-plus:has(.is-invalid),
html[data-theme="dark"] .input-plus.is-invalid:focus-within,
html[data-theme="dark"] .input-plus:has(.is-invalid):focus-within,
html[data-theme="dark"] .input-plus.is-invalid:has(.select2-container--open),
html[data-theme="dark"] .input-plus:has(.is-invalid):has(.select2-container--open) {
    border-color: var(--kyo-invalid, #ff6b6b) !important;
    background-color: rgba(255, 107, 107, 0.08) !important;
    box-shadow:
        0 0 0 3px var(--kyo-invalid-soft, rgba(255, 107, 107, 0.28)),
        0 0 18px rgba(224, 72, 72, 0.28) !important;
}
html[data-theme="dark"] .modal .select2-container .select2-selection.is-invalid,
html[data-theme="dark"] .modal .select2-container--focus .select2-selection.is-invalid,
html[data-theme="dark"] .modal .select2-container--open .select2-selection.is-invalid,
html[data-theme="dark"] .modal .select2-container--default .select2-selection--single.is-invalid,
html[data-theme="dark"] .modal select.is-invalid + .select2-container .select2-selection,
html[data-theme="dark"] .adm-modal .select2-container--default .select2-selection--single.is-invalid {
    border-color: var(--kyo-invalid, #ff6b6b) !important;
    background-color: rgba(255, 107, 107, 0.08) !important;
    box-shadow:
        0 0 0 3px var(--kyo-invalid-soft, rgba(255, 107, 107, 0.28)),
        0 0 18px rgba(224, 72, 72, 0.28) !important;
}

/* ============================================================
   Cierre: heroes, Finanzas y modal de accesos.
   Selectores con id / cadena larga para ganarle a #modalEdicion
   y a los gradientes pastel sin !important de cada página.
   ============================================================ */
html[data-theme="dark"] .vt-ax .vt-ax-hero,
html[data-theme="dark"] #vtAxDashboard .vt-ax-hero,
html[data-theme="dark"] .pd-page .pd-hero,
html[data-theme="dark"] .ts-page .ts-hero,
html[data-theme="dark"] #fgHub .ts-hero {
    background: #12243f !important;
    background-color: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-ax .vt-ax-hero .vt-ax-hero-left,
html[data-theme="dark"] .vt-ax .vt-ax-hero .vt-ax-hero-inner,
html[data-theme="dark"] .vt-ax .vt-ax-hero .vt-ax-hero-right,
html[data-theme="dark"] .vt-ax .vt-ax-hero .vt-ax-hero-pattern,
html[data-theme="dark"] .vt-ax .vt-ax-hero .vt-ax-title,
html[data-theme="dark"] .vt-ax .vt-ax-hero .vt-ax-sub,
html[data-theme="dark"] .vt-ax .vt-ax-hero .vt-ax-eyebrow,
html[data-theme="dark"] .pd-page .pd-hero .pd-hero-left,
html[data-theme="dark"] .pd-page .pd-hero .pd-hero-inner,
html[data-theme="dark"] .pd-page .pd-hero .pd-hero-actions,
html[data-theme="dark"] .pd-page .pd-hero .pd-hero-title,
html[data-theme="dark"] .pd-page .pd-hero .pd-hero-sub,
html[data-theme="dark"] .pd-page .pd-hero .pd-eyebrow,
html[data-theme="dark"] .ts-page .ts-hero .ts-hero-left,
html[data-theme="dark"] .ts-page .ts-hero .ts-hero-inner,
html[data-theme="dark"] .ts-page .ts-hero .ts-hero-right,
html[data-theme="dark"] .ts-page .ts-hero .ts-hero-pattern,
html[data-theme="dark"] .ts-page .ts-hero .ts-title,
html[data-theme="dark"] .ts-page .ts-hero .ts-sub,
html[data-theme="dark"] .ts-page .ts-hero .ts-eyebrow {
    background: transparent !important;
    background-color: transparent !important;
    background-image: none !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-ax .vt-ax-title,
html[data-theme="dark"] .pd-page .pd-hero-title,
html[data-theme="dark"] .ts-page .ts-title { color: #ffffff !important; }
html[data-theme="dark"] .vt-ax .vt-ax-sub,
html[data-theme="dark"] .vt-ax .vt-ax-eyebrow,
html[data-theme="dark"] .pd-page .pd-hero-sub,
html[data-theme="dark"] .pd-page .pd-eyebrow,
html[data-theme="dark"] .ts-page .ts-sub,
html[data-theme="dark"] .ts-page .ts-eyebrow { color: #b7cbe6 !important; }
html[data-theme="dark"] .vt-ax .vt-ax-hero a.vt-ax-back,
html[data-theme="dark"] .vt-ax .vt-ax-hero a.vt-ax-back:hover,
html[data-theme="dark"] .pd-page .pd-hero a.pd-back,
html[data-theme="dark"] .pd-page .pd-hero a.pd-back:hover,
html[data-theme="dark"] .ts-page .ts-hero a.ts-back,
html[data-theme="dark"] .ts-page .ts-hero a.ts-back:hover {
    background: #12243f !important;
    background-color: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
    width: 42px !important;
    height: 42px !important;
}
html[data-theme="dark"] .vt-ax .vt-ax-hero a.vt-ax-back i,
html[data-theme="dark"] .pd-page .pd-hero a.pd-back i,
html[data-theme="dark"] .ts-page .ts-hero a.ts-back i { color: #ffffff !important; }
html[data-theme="dark"] .vt-ax .vt-ax-hero .vt-ax-period-pill,
html[data-theme="dark"] .ts-page .ts-hero .ts-pill,
html[data-theme="dark"] #fgHub .ts-pill {
    background: #12243f !important;
    background-color: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-ax .vt-ax-hero .vt-ax-period-pill i,
html[data-theme="dark"] .vt-ax .vt-ax-hero .vt-ax-period-pill span,
html[data-theme="dark"] .ts-page .ts-pill i,
html[data-theme="dark"] .ts-page .ts-pill strong { color: #ffffff !important; }
html[data-theme="dark"] .vt-ax .vt-ax-hero .vt-ax-btn-primary,
html[data-theme="dark"] .vt-ax .vt-ax-hero .vt-ax-btn-primary:hover,
html[data-theme="dark"] .vt-ax .vt-ax-hero #btnAplicar,
html[data-theme="dark"] .pd-page .pd-hero .pd-btn--sage,
html[data-theme="dark"] .pd-page .pd-hero .pd-btn--sage:hover {
    background: #2f7dff !important;
    background-color: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: #2f7dff !important;
    box-shadow: none !important;
    filter: none !important;
}
html[data-theme="dark"] .pd-page .pd-hero .pd-btn--ghost,
html[data-theme="dark"] .pd-page .pd-hero .pd-btn--ghost:hover {
    background: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .pd-page .pd-hero .pd-btn--primary,
html[data-theme="dark"] .pd-page .pd-hero .pd-btn--primary:hover {
    background: #1f8f4e !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: #1f8f4e !important;
}

/* Finanzas / Stock: tabs, primario, fechas y selects */
html[data-theme="dark"] #fgTabs,
html[data-theme="dark"] #stkTabs,
html[data-theme="dark"] .ts-page .fg-tabs {
    background: #12243f !important;
    background-image: none !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] #fgTabs .fg-tab,
html[data-theme="dark"] #stkTabs .fg-tab,
html[data-theme="dark"] .ts-page .fg-tabs .fg-tab,
html[data-theme="dark"] #fgTabs .fg-tab:hover,
html[data-theme="dark"] #stkTabs .fg-tab:hover {
    background: transparent !important;
    background-image: none !important;
    color: #ffffff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] #fgTabs .fg-tab.active,
html[data-theme="dark"] #stkTabs .fg-tab.active,
html[data-theme="dark"] .ts-page .fg-tabs .fg-tab.active,
html[data-theme="dark"] #fgTabs .fg-tab.active:hover,
html[data-theme="dark"] #stkTabs .fg-tab.active:hover {
    background: #2f7dff !important;
    background-color: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] #fgHub .ts-btn.ts-btn--primary,
html[data-theme="dark"] #fgHub a.ts-btn.ts-btn--primary,
html[data-theme="dark"] .ts-page .ts-filters .ts-btn.ts-btn--primary,
html[data-theme="dark"] .ts-page #tsBtnBuscar,
html[data-theme="dark"] .ts-page #stkBtnAjuste,
html[data-theme="dark"] .ts-page .ts-btn.ts-btn--primary,
html[data-theme="dark"] .ts-page .ts-btn.ts-btn--primary:hover {
    background: #2f7dff !important;
    background-color: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: #2f7dff !important;
    box-shadow: none !important;
    filter: none !important;
}
html[data-theme="dark"] .ts-page .ts-btn.ts-btn--ghost,
html[data-theme="dark"] .ts-page .ts-btn.ts-btn--ghost:hover,
html[data-theme="dark"] #fgHub .ts-btn.ts-btn--ghost {
    background: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .ts-page .ts-field .form-control,
html[data-theme="dark"] .ts-page .ts-field .form-select,
html[data-theme="dark"] .ts-page .ts-field input[type="date"],
html[data-theme="dark"] .ts-page .ts-filters .form-control,
html[data-theme="dark"] .ts-page .ts-filters .form-select,
html[data-theme="dark"] .ts-page #tsDesde,
html[data-theme="dark"] .ts-page #tsHasta,
html[data-theme="dark"] .ts-page .form-control,
html[data-theme="dark"] .ts-page .form-select {
    background: #07111f !important;
    background-color: #07111f !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    color-scheme: dark !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .ts-page input[type="date"]::-webkit-calendar-picker-indicator {
    filter: invert(1) brightness(1.4);
}
html[data-theme="dark"] .ts-page .ts-field label,
html[data-theme="dark"] .ts-page .ts-form-label { color: #b7cbe6 !important; }
html[data-theme="dark"] .ts-page .ts-field .input-plus,
html[data-theme="dark"] .ts-page .ts-field .input-group.input-plus,
html[data-theme="dark"] .ts-page .ts-field .select2-container .select2-selection--single,
html[data-theme="dark"] .ts-page .ts-field .select2-container--default .select2-selection--single,
html[data-theme="dark"] .ts-page .input-plus.input-plus .select2-container .select2-selection--single,
html[data-theme="dark"] .ts-page .input-plus.input-plus > .form-select,
html[data-theme="dark"] .ts-page .input-plus.input-plus > select {
    background: #07111f !important;
    background-color: #07111f !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .ts-page .ts-field .select2-selection__rendered,
html[data-theme="dark"] .ts-page .input-plus .select2-selection__rendered { color: #ffffff !important; }
html[data-theme="dark"] .ts-page .input-plus .btn-plus,
html[data-theme="dark"] .ts-page .input-plus.input-plus .btn-plus,
html[data-theme="dark"] .input-plus.input-plus .btn-plus {
    background: #2f7dff !important;
    color: #ffffff !important;
    border-left-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .ts-page .ts-chips .ts-chip.active,
html[data-theme="dark"] .ts-page .ts-chip.active {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: #2f7dff !important;
}

/* Editar Usuario — pestaña Accesos (#modalEdicion gana por id) */
html[data-theme="dark"] #modalEdicion .cc-tabs .nav-link,
html[data-theme="dark"] #modalEdicion .cc-tabs .nav-link:hover {
    background: transparent !important;
    color: #b7cbe6 !important;
    border: 0 !important;
}
html[data-theme="dark"] #modalEdicion .cc-tabs .nav-link.active,
html[data-theme="dark"] #modalEdicion .cc-tabs .nav-link.active:hover {
    background: transparent !important;
    color: #3ec5ff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] #modalEdicion .cc-tabs .nav-link.active::after {
    background: #3ec5ff !important;
    background-image: none !important;
}
html[data-theme="dark"] #modalEdicion .form-label,
html[data-theme="dark"] #modalEdicion .acc-shell-sub,
html[data-theme="dark"] #modalEdicion .acc-panel-hint,
html[data-theme="dark"] #modalEdicion .acc-chip .acc-chip-detail { color: #b7cbe6 !important; }
html[data-theme="dark"] #modalEdicion .form-control,
html[data-theme="dark"] #modalEdicion .form-select,
html[data-theme="dark"] #modalEdicion input.form-control,
html[data-theme="dark"] #modalEdicion select.form-control {
    background: #07111f !important;
    background-color: #07111f !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] #modalEdicion .btn-outline-secondary,
html[data-theme="dark"] #modalEdicion .btn-outline-secondary:hover {
    background: #12243f !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] #modalEdicion .acc-shell-title,
html[data-theme="dark"] #modalEdicion .acc-panel-title,
html[data-theme="dark"] #modalEdicion .acc-unit-name,
html[data-theme="dark"] #modalEdicion .acc-unit-name span,
html[data-theme="dark"] #modalEdicion .acc-local-row,
html[data-theme="dark"] #modalEdicion .acc-selectall-label,
html[data-theme="dark"] #modalEdicion .acc-chip { color: #ffffff !important; }
html[data-theme="dark"] #modalEdicion .acc-shell-title i,
html[data-theme="dark"] #modalEdicion .acc-unit-name i,
html[data-theme="dark"] #modalEdicion .acc-resumen-head,
html[data-theme="dark"] #modalEdicion .acc-resumen-head i,
html[data-theme="dark"] #modalEdicion .acc-chip strong,
html[data-theme="dark"] #modalEdicion .acc-locales-title-highlight { color: #3ec5ff !important; }
html[data-theme="dark"] #modalEdicion .acc-panel,
html[data-theme="dark"] #modalEdicion .acc-unit-row,
html[data-theme="dark"] #modalEdicion .acc-locales-list,
html[data-theme="dark"] #modalEdicion .acc-resumen,
html[data-theme="dark"] #modalEdicion .acc-chip,
html[data-theme="dark"] #modalEdicion .acc-selectall-wrap {
    background: #12243f !important;
    background-image: none !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
    color: #ffffff !important;
}
html[data-theme="dark"] #modalEdicion .acc-locales-list,
html[data-theme="dark"] #modalEdicion .acc-resumen,
html[data-theme="dark"] #modalEdicion .acc-unit-row.unit-active { background: #0e1c36 !important; }
html[data-theme="dark"] #modalEdicion .acc-unit-row:hover,
html[data-theme="dark"] #modalEdicion .acc-local-row:hover,
html[data-theme="dark"] #modalEdicion .acc-unit-row.unit-active {
    background: #163056 !important;
    background-image: none !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    color: #ffffff !important;
}
html[data-theme="dark"] #modalEdicion .acc-local-row {
    background: transparent !important;
    border-bottom-color: rgba(62, 197, 255, 0.2) !important;
}
html[data-theme="dark"] #modalEdicion .acc-panel-icon,
html[data-theme="dark"] #modalEdicion .acc-panel-icon--unit,
html[data-theme="dark"] #modalEdicion .acc-panel-icon--local {
    background: #163056 !important;
    background-image: none !important;
    color: #3ec5ff !important;
}
html[data-theme="dark"] #modalEdicion .acc-badge--on {
    background: #1f8f4e !important;
    color: #ffffff !important;
    border-color: #1f8f4e !important;
}
html[data-theme="dark"] #modalEdicion .acc-badge--off {
    background: #163056 !important;
    color: #b7cbe6 !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] #modalEdicion .acc-btn-danger,
html[data-theme="dark"] #modalEdicion .acc-btn-danger:hover {
    background: #c4364a !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: #c4364a !important;
}
html[data-theme="dark"] #modalEdicion .acc-btn-ghost,
html[data-theme="dark"] #modalEdicion .acc-btn-ghost:hover {
    background: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] #modalEdicion .acc-local-row .form-check-input { accent-color: #2f7dff !important; }
html[data-theme="dark"] #modalEdicion .acc-chip .x,
html[data-theme="dark"] #modalEdicion .acc-chip .x:hover { color: #ffffff !important; }

/* Login — solo si ya eligió modo oscuro (rp_theme). El claro no se toca. */
html[data-theme="dark"] .login-page {
    background:
        radial-gradient(ellipse 70% 50% at 0% 0%, rgba(47, 125, 255, 0.16) 0%, transparent 52%),
        radial-gradient(ellipse 55% 40% at 100% 100%, rgba(62, 197, 255, 0.08) 0%, transparent 48%),
        linear-gradient(165deg, #07111f 0%, #0b1730 100%) !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .login-container {
    background: #0e1c36 !important;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .login-brand,
html[data-theme="dark"] .login-form-panel {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .login-brand { border-right: 1px solid rgba(62, 197, 255, 0.35); }
html[data-theme="dark"] .login-brand::before,
html[data-theme="dark"] .login-brand::after { display: none !important; }
html[data-theme="dark"] .login-logo {
    filter: drop-shadow(0 12px 28px rgba(47, 125, 255, 0.35)) !important;
}
html[data-theme="dark"] .login-brand-tagline,
html[data-theme="dark"] .login-subtitle,
html[data-theme="dark"] .login-checkbox-label { color: #b7cbe6 !important; }
html[data-theme="dark"] .login-title,
html[data-theme="dark"] .login-label { color: #e8f2ff !important; }
html[data-theme="dark"] .login-brand-dots span,
html[data-theme="dark"] .login-brand-dots span:nth-child(2),
html[data-theme="dark"] .login-brand-dots span:nth-child(3) {
    background: #2f7dff !important;
    opacity: 1 !important;
}
html[data-theme="dark"] .login-brand-dots span:nth-child(2) { background: #3ec5ff !important; }
html[data-theme="dark"] .login-input,
html[data-theme="dark"] .login-input:focus {
    background: #07111f !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .login-input:focus {
    border-color: #3ec5ff !important;
    box-shadow: 0 0 0 3px rgba(62, 197, 255, 0.22) !important;
}
html[data-theme="dark"] .login-input::placeholder { color: #b7cbe6 !important; }
html[data-theme="dark"] .login-input-icon,
html[data-theme="dark"] .login-input-wrap:focus-within .login-input-icon,
html[data-theme="dark"] .login-toggle-pwd,
html[data-theme="dark"] .login-toggle-pwd:hover { color: #b7cbe6 !important; }
html[data-theme="dark"] .login-toggle-pwd:hover { background: #163056 !important; color: #ffffff !important; }
html[data-theme="dark"] .login-checkbox-box {
    background: #07111f !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .login-checkbox:checked + .login-checkbox-box {
    background: #2f7dff !important;
    background-image: none !important;
    border-color: #2f7dff !important;
}
html[data-theme="dark"] .login-checkbox-wrap:hover .login-checkbox-box { border-color: #3ec5ff !important; }
html[data-theme="dark"] .login-error {
    background: #2a1218 !important;
    color: #ffd5dc !important;
    border-color: rgba(196, 54, 74, 0.55) !important;
}
html[data-theme="dark"] .login-btn,
html[data-theme="dark"] .login-btn:hover:not(:disabled),
html[data-theme="dark"] .login-btn:disabled,
html[data-theme="dark"] .login-btn.is-loading {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    box-shadow: none !important;
}

/* Sección activa del menú lateral */
html[data-theme="dark"] .rp-side-link.is-active,
html[data-theme="dark"] .rp-side-link.active,
html[data-theme="dark"] body.rp-app[data-side="icons"] .rp-side-link.is-active,
html[data-theme="dark"] body.rp-app[data-side="icons"] .rp-side-link.active {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    box-shadow: inset 3px 0 0 #3ec5ff !important;
}
html[data-theme="dark"] .rp-side-link.is-active .fa,
html[data-theme="dark"] .rp-side-link.active .fa,
html[data-theme="dark"] .rp-side-link.is-active .rp-side-text small,
html[data-theme="dark"] .rp-side-link.active .rp-side-text small { color: #ffffff !important; }
html[data-theme="dark"] .rp-side-group.is-module-active > .rp-side-label,
html[data-theme="dark"] .rp-side-group.is-open > .rp-side-label {
    color: #7ad7ff !important;
    background: rgba(62, 197, 255, 0.16) !important;
    box-shadow: inset 3px 0 0 #3ec5ff;
}
html[data-theme="dark"] .rp-side-group.is-module-active > .rp-side-label {
    color: #ffffff !important;
    background: #163056 !important;
}
html[data-theme="dark"] .rp-side-label:hover {
    color: #7ad7ff !important;
    background: rgba(62, 197, 255, 0.14) !important;
}
html[data-theme="dark"] .rp-tabbar a.is-on,
html[data-theme="dark"] .rp-tabbar button.is-on {
    background: #2f7dff !important;
    color: #ffffff !important;
}

/* Confirmaciones (kyo-confirm y el cascade de borrado) */
html[data-theme="dark"] .kyo-confirm__scrim,
html[data-theme="dark"] .kyo-cascade__scrim {
    background: rgba(4, 10, 22, 0.72) !important;
}
html[data-theme="dark"] .kyo-confirm__card,
html[data-theme="dark"] #kyoConfirmRoot.is-open .kyo-confirm__card,
html[data-theme="dark"] #kyoPromptRoot.is-open .kyo-confirm__card,
html[data-theme="dark"] .kyo-cascade__card,
html[data-theme="dark"] #kyoCascadeRoot.is-open .kyo-cascade__card {
    background: #12243f !important;
    background-image: none !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45) !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .kyo-confirm__shine,
html[data-theme="dark"] .kyo-cascade__shine {
    background: #3ec5ff !important;
    background-image: none !important;
    box-shadow: none !important;
    animation: none !important;
}
html[data-theme="dark"] .kyo-confirm__badge,
html[data-theme="dark"] .kyo-cascade__badge {
    background: #163056 !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 2px solid #3ec5ff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .kyo-confirm__title,
html[data-theme="dark"] .kyo-cascade__title,
html[data-theme="dark"] .kyo-confirm__list-item strong,
html[data-theme="dark"] .kyo-cascade__dep strong,
html[data-theme="dark"] .kyo-cascade__choice strong { color: #ffffff !important; }
html[data-theme="dark"] .kyo-confirm__msg,
html[data-theme="dark"] .kyo-cascade__msg,
html[data-theme="dark"] .kyo-confirm__list-item,
html[data-theme="dark"] .kyo-confirm__list-item span,
html[data-theme="dark"] .kyo-cascade__dep span,
html[data-theme="dark"] .kyo-cascade__choice small { color: #e8f2ff !important; }
html[data-theme="dark"] .kyo-confirm__list,
html[data-theme="dark"] .kyo-cascade__dep,
html[data-theme="dark"] .kyo-cascade__choice,
html[data-theme="dark"] .kyo-cascade__choice--ghost {
    background: #0e1c36 !important;
    background-image: none !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    color: #e8f2ff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .kyo-confirm__btn--ghost,
html[data-theme="dark"] .kyo-confirm__btn--ghost:hover {
    background: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .kyo-confirm__btn--primary,
html[data-theme="dark"] .kyo-confirm__btn--primary:hover,
html[data-theme="dark"] .kyo-cascade__choice--danger,
html[data-theme="dark"] .kyo-cascade__choice--danger:hover {
    background: #c4364a !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: #c4364a !important;
    box-shadow: none !important;
    filter: none !important;
}
html[data-theme="dark"] .kyo-confirm__input {
    background: #0e1c36 !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .kyo-confirm__input:focus {
    border-color: #3ec5ff !important;
    box-shadow: 0 0 0 3px rgba(62, 197, 255, 0.18) !important;
}
html[data-theme="dark"] .kyo-cascade__choice--danger i,
html[data-theme="dark"] .kyo-cascade__choice i { color: #ffffff !important; }

/* ============================================================
   Heroes: una sola barra. [class*="-hero"] también pintaba
   -hero-actions / -hero-left y armaba un segundo recuadro.
   ============================================================ */
html[data-theme="dark"] .vt-hero,
html[data-theme="dark"] .vt-ax-hero,
html[data-theme="dark"] .pd-hero,
html[data-theme="dark"] .pa-hero,
html[data-theme="dark"] .ax-hero,
html[data-theme="dark"] .ts-hero,
html[data-theme="dark"] .rm-page .rm-hero,
html[data-theme="dark"] .cc-header,
html[data-theme="dark"] .cc-kpi,
html[data-theme="dark"] .cc-kpi.cc-card {
    background: #12243f !important;
    background-image: none !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
    color: #e8f2ff !important;
    overflow: visible !important;
}
html[data-theme="dark"] [class*="-hero"] [class*="-hero"],
html[data-theme="dark"] .cc-header .cc-header-actions,
html[data-theme="dark"] .cc-header .cc-stat,
html[data-theme="dark"] .vt-hero .vt-kpi,
html[data-theme="dark"] .vt-hero .vt-kpi-row,
html[data-theme="dark"] .ts-hero .ts-kpi {
    background: transparent !important;
    background-image: none !important;
    border: 0 !important;
    box-shadow: none !important;
    overflow: visible !important;
}
html[data-theme="dark"] .vt-hero-glow,
html[data-theme="dark"] .vt-ax-hero-glow,
html[data-theme="dark"] .pd-hero-glow,
html[data-theme="dark"] .pa-hero-glow,
html[data-theme="dark"] .ts-hero-glow,
html[data-theme="dark"] .ax-hero-glow { display: none !important; }
html[data-theme="dark"] .vt-hero-inner,
html[data-theme="dark"] .vt-hero-actions,
html[data-theme="dark"] .vt-hero-left,
html[data-theme="dark"] .vt-ax-hero-inner,
html[data-theme="dark"] .vt-ax-hero-right,
html[data-theme="dark"] .vt-ax-hero-left,
html[data-theme="dark"] .pd-hero-inner,
html[data-theme="dark"] .pd-hero-actions,
html[data-theme="dark"] .ts-hero-inner,
html[data-theme="dark"] .ts-hero-right,
html[data-theme="dark"] .ts-hero-left,
html[data-theme="dark"] .cc-header-actions,
html[data-theme="dark"] .pa-hero-inner,
html[data-theme="dark"] .pa-hero-right {
    display: flex;
    flex-wrap: wrap !important;
    align-items: center;
    min-width: 0 !important;
    max-width: 100% !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-hero-title,
html[data-theme="dark"] .vt-ax-title,
html[data-theme="dark"] .pd-hero-title,
html[data-theme="dark"] .cc-header h2,
html[data-theme="dark"] .ts-title { color: #ffffff !important; }
html[data-theme="dark"] .vt-hero-sub,
html[data-theme="dark"] .vt-ax-sub,
html[data-theme="dark"] .pd-hero-sub,
html[data-theme="dark"] .ts-sub,
html[data-theme="dark"] .cc-header .text-muted-cc { color: #b7cbe6 !important; }
html[data-theme="dark"] .vt-hero-icon,
html[data-theme="dark"] .pd-hero-icon,
html[data-theme="dark"] .ts-hero-mark,
html[data-theme="dark"] .vt-ax-hero-mark,
html[data-theme="dark"] .cc-badge {
    background: #163056 !important;
    background-image: none !important;
    color: #3ec5ff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .cc-header-link,
html[data-theme="dark"] .cc-header-link:hover,
html[data-theme="dark"] a.cc-header-link--analisis,
html[data-theme="dark"] a.cc-header-link--compact {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 0 !important;
    box-shadow: none !important;
    transform: none !important;
    overflow: visible !important;
    min-height: 0 !important;
    height: auto !important;
    align-self: center !important;
}
html[data-theme="dark"] .cc-header-link::before { display: none !important; }
html[data-theme="dark"] .cc-header-link-icon,
html[data-theme="dark"] .cc-header-link--analisis .cc-header-link-icon,
html[data-theme="dark"] .cc-header-link--compact .cc-header-link-icon,
html[data-theme="dark"] .cc-header-link-chevron,
html[data-theme="dark"] .cc-header-link:hover .cc-header-link-chevron {
    background: transparent !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 0 !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .cc-header-link-title,
html[data-theme="dark"] .cc-header-link-sub,
html[data-theme="dark"] .cc-header-link i { color: #ffffff !important; }
html[data-theme="dark"] .vt-hero .vt-kpi .label,
html[data-theme="dark"] .cc-stat .label,
html[data-theme="dark"] .cc-header .cc-stat .label { color: #b7cbe6 !important; }
html[data-theme="dark"] .vt-hero .vt-kpi .value,
html[data-theme="dark"] .vt-hero .vt-kpi--warn .value,
html[data-theme="dark"] .vt-hero .vt-kpi--sage .value,
html[data-theme="dark"] .cc-stat .value,
html[data-theme="dark"] .cc-header .cc-stat .value { color: #3ec5ff !important; }
html[data-theme="dark"] .vt-step,
html[data-theme="dark"] .vt-step.is-active {
    background: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-step-num,
html[data-theme="dark"] .vt-step.is-active .vt-step-num {
    background: transparent !important;
    background-image: none !important;
    color: #3ec5ff !important;
    box-shadow: none !important;
}

/* Importaciones: grilla de líneas, nota, badges y barra de confirmar */
html[data-theme="dark"] .vt-page .vt-lines-wrap {
    background: #0e1c36 !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .vt-page .vt-lines-wrap thead th {
    background: #2f7dff !important;
    color: #ffffff !important;
    border-color: transparent !important;
}
html[data-theme="dark"] .vt-page .vt-lines-wrap tbody tr,
html[data-theme="dark"] .vt-page .vt-lines-wrap tbody td,
html[data-theme="dark"] .vt-page .vt-lines-wrap tr:not(.excluir) td {
    background: #12243f !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.15) !important;
}
html[data-theme="dark"] .vt-page .vt-lines-wrap tr.excluir,
html[data-theme="dark"] .vt-page .vt-lines-wrap tr.excluir td {
    background: #0e1c36 !important;
    color: #b7cbe6 !important;
}
html[data-theme="dark"] .vt-page .vt-lines-wrap .form-control,
html[data-theme="dark"] .vt-page .vt-lines-wrap input.form-control-sm,
html[data-theme="dark"] .vt-page .vt-lines-wrap .form-control:focus {
    background: #07111f !important;
    background-color: #07111f !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-page .vt-lines-wrap .form-control::placeholder { color: #b7cbe6 !important; opacity: 1 !important; }
html[data-theme="dark"] .vt-page .vt-lines-wrap .form-check-input {
    background-color: #07111f !important;
    border-color: rgba(62, 197, 255, 0.55) !important;
}
html[data-theme="dark"] .vt-page .vt-lines-wrap .form-check-input:checked {
    background-color: #2f7dff !important;
    border-color: #2f7dff !important;
}
html[data-theme="dark"] .vt-page .vt-lines-wrap .form-check-input:focus {
    box-shadow: 0 0 0 0.2rem rgba(62, 197, 255, 0.25) !important;
}
html[data-theme="dark"] .vt-lines-hint {
    color: #e8f2ff !important;
    background: #12243f !important;
    border: 1px solid rgba(62, 197, 255, 0.28);
    border-radius: 10px;
    padding: 0.4rem 0.7rem;
}
html[data-theme="dark"] .vt-lines-hint i { color: #3ec5ff !important; }
html[data-theme="dark"] .vt-lines-hint .vt-badge-ok,
html[data-theme="dark"] .vt-lines-hint .vt-badge-insumo,
html[data-theme="dark"] .vt-lines-hint .vt-badge-miss {
    background: #163056 !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.55) !important;
}
html[data-theme="dark"] .vt-lines-wrap .vt-badge-ok {
    background: #1f8f4e !important;
    color: #ffffff !important;
    border: 0 !important;
}
html[data-theme="dark"] .vt-lines-wrap .vt-badge-insumo {
    background: #2f7dff !important;
    color: #ffffff !important;
    border: 0 !important;
}
html[data-theme="dark"] .vt-lines-wrap .vt-badge-miss {
    background: #163056 !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.55) !important;
}
html[data-theme="dark"] .vt-lines-wrap .vt-del,
html[data-theme="dark"] .vt-lines-wrap .btn-outline-danger,
html[data-theme="dark"] .vt-lines-wrap .vt-del i {
    background: #c4364a !important;
    color: #ffffff !important;
    border-color: #c4364a !important;
}
html[data-theme="dark"] .vt-confirm-shell {
    background: #12243f !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45) !important;
}
html[data-theme="dark"] .vt-confirm-chip,
html[data-theme="dark"] .vt-confirm-chip--money {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-confirm-chip .lbl { color: #b7cbe6 !important; }
html[data-theme="dark"] .vt-confirm-chip .num { color: #ffffff !important; }
html[data-theme="dark"] .vt-confirm-chip--money .num { color: #3ec5ff !important; }
html[data-theme="dark"] #btnConfirmarImport,
html[data-theme="dark"] #btnConfirmarImport:hover {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: #2f7dff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-confirm-replace {
    background: #163056 !important;
    background-image: none !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .vt-confirm-replace-body strong,
html[data-theme="dark"] .vt-confirm-replace-body p,
html[data-theme="dark"] .vt-replace-toggle { color: #e8f2ff !important; }
html[data-theme="dark"] .vt-replace-toggle,
html[data-theme="dark"] .vt-confirm-replace-icon {
    background: #12243f !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    color: #3ec5ff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-file-card,
html[data-theme="dark"] .vt-file-card.is-error,
html[data-theme="dark"] .vt-file-card.is-dup,
html[data-theme="dark"] .vt-meta-item,
html[data-theme="dark"] .vt-meta-item--accent,
html[data-theme="dark"] .vt-meta-item--money,
html[data-theme="dark"] .vt-dup-banner,
html[data-theme="dark"] .vt-dup-banner--info {
    background: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-file-name,
html[data-theme="dark"] .vt-meta-item .val { color: #ffffff !important; }
html[data-theme="dark"] .vt-meta-item--money .val { color: #3ec5ff !important; }
html[data-theme="dark"] .vt-meta-item label,
html[data-theme="dark"] .vt-meta-item .val-meta,
html[data-theme="dark"] .vt-form-row label { color: #b7cbe6 !important; }
html[data-theme="dark"] .vt-form-row .form-control,
html[data-theme="dark"] .vt-form-row .form-select,
html[data-theme="dark"] .vt-form-row .form-control:focus,
html[data-theme="dark"] .vt-form-row .form-select:focus {
    background: #07111f !important;
    background-color: #07111f !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-page .dataTables_wrapper .dataTables_length,
html[data-theme="dark"] .vt-page .dataTables_wrapper .dataTables_length label,
html[data-theme="dark"] .vt-page .dataTables_wrapper .dataTables_filter,
html[data-theme="dark"] .vt-page .dataTables_wrapper .dataTables_filter label,
html[data-theme="dark"] .vt-page .dataTables_wrapper .dataTables_info {
    color: #b7cbe6 !important;
    background: transparent !important;
}
html[data-theme="dark"] .vt-page .dataTables_wrapper .dataTables_length select,
html[data-theme="dark"] .vt-page .dataTables_wrapper .dataTables_filter input,
html[data-theme="dark"] .vt-page .dataTables_wrapper .dataTables_filter input:focus {
    background-color: #07111f !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .vt-page .dataTables_wrapper .dataTables_filter input::placeholder {
    color: #b7cbe6 !important;
    opacity: 1 !important;
}

/* Pedidos: misma gama navy / azul / verde que el resto de los ABM. Sin rosa ni violeta. */
html[data-theme="dark"] .pd-page .pd-panel-head h2,
html[data-theme="dark"] .pd-page .pd-line-name,
html[data-theme="dark"] .pd-page .pd-subtotal,
html[data-theme="dark"] .pd-page .pd-kpi strong {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pd-page .pd-panel-head h2 i,
html[data-theme="dark"] .pd-page .pd-kpi--sage strong {
    color: #3ec5ff !important;
}
html[data-theme="dark"] .pd-page .pd-panel-head p,
html[data-theme="dark"] .pd-page .pd-field label,
html[data-theme="dark"] .pd-page .pd-line-meta,
html[data-theme="dark"] .pd-page .pd-line label,
html[data-theme="dark"] .pd-page .pd-facts em,
html[data-theme="dark"] .pd-page .pd-empty {
    color: #b7cbe6 !important;
}

/* Chips Stock / Teórico / Pedido local: fondos navy (no blancos) + texto legible */
html[data-theme="dark"] .pd-page .pd-metric {
    background: #12243f !important;
    background-image: none !important;
    border-color: rgba(62, 197, 255, 0.28) !important;
    box-shadow: none !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pd-page .pd-metric em {
    color: #8eb0d4 !important;
}
html[data-theme="dark"] .pd-page .pd-metric b {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pd-page .pd-metric--stock {
    background: #163056 !important;
    background-image: none !important;
    border-color: rgba(47, 125, 255, 0.55) !important;
}
html[data-theme="dark"] .pd-page .pd-metric--stock em {
    color: #7eb6ff !important;
}
html[data-theme="dark"] .pd-page .pd-metric--stock b {
    color: #ffffff !important;
}
html[data-theme="dark"] .pd-page .pd-metric--teo {
    background: #0e1c36 !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .pd-page .pd-metric--teo em {
    color: #3ec5ff !important;
}
html[data-theme="dark"] .pd-page .pd-metric--teo b {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pd-page .pd-metric--local {
    background: #0f2a22 !important;
    background-image: none !important;
    border-color: rgba(52, 211, 153, 0.4) !important;
}
html[data-theme="dark"] .pd-page .pd-metric--local em {
    color: #6ee7b7 !important;
}
html[data-theme="dark"] .pd-page .pd-metric--local b {
    color: #d1fae5 !important;
}
html[data-theme="dark"] .pd-page .pd-metric--sug {
    background: #0a1628 !important;
    border-color: rgba(142, 176, 212, 0.25) !important;
    opacity: 0.85;
}
html[data-theme="dark"] .pd-page .pd-metric--sug em {
    color: #8eb0d4 !important;
}
html[data-theme="dark"] .pd-page .pd-metric--sug b {
    color: #b7cbe6 !important;
}
html[data-theme="dark"] .pd-page .pd-toggle-sug {
    color: #b7cbe6 !important;
}
html[data-theme="dark"] .pd-page .pd-motivo--req input {
    background: #1a1520 !important;
    border-color: rgba(251, 146, 60, 0.55) !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .pd-page .pd-line--ajustado,
html[data-theme="dark"] .pd-page .pd-line--ajustado:nth-child(even) {
    background: #1a1520 !important;
    box-shadow: inset 3px 0 0 #fb923c !important;
}
html[data-theme="dark"] .pd-page .pd-cmp-table th.pd-col-pri,
html[data-theme="dark"] .pd-page .pd-cmp-table td.pd-col-pri {
    background: #163056 !important;
}
html[data-theme="dark"] .pd-page .pd-cmp-table td.pd-col-pri b {
    color: #7eb6ff !important;
}
html[data-theme="dark"] .pd-page .pd-cmp-table .pd-col-sug {
    color: #8eb0d4 !important;
}
html[data-theme="dark"] .pd-page .pd-row-ajustado td {
    background: #1a1520 !important;
}
html[data-theme="dark"] .pd-page .pd-motivo-cell {
    color: #b7cbe6 !important;
}
html[data-theme="dark"] .pd-page .pd-pill-estado {
    background: #163056 !important;
    color: #7eb6ff !important;
}
html[data-theme="dark"] .pd-page .pd-panel-head {
    border-bottom-color: rgba(62, 197, 255, 0.18) !important;
}
/* Locales / selects Pedidos: sin doble borde (search interno transparente) */
html[data-theme="dark"] .pd-page .pd-field .select2-container .select2-selection--single,
html[data-theme="dark"] .pd-page .pd-field .select2-container .select2-selection--multiple {
    background: #0a1220 !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .pd-page .pd-field .select2-container .select2-selection--single .select2-selection__rendered,
html[data-theme="dark"] .pd-page .pd-field .select2-container .select2-selection__placeholder {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pd-page .pd-field .select2-container .select2-selection--multiple .select2-selection__choice {
    background: #163056 !important;
    border-color: rgba(62, 197, 255, 0.4) !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pd-page .pd-field .select2-search--inline,
html[data-theme="dark"] .pd-page .pd-field .select2-container .select2-search--inline .select2-search__field {
    background: transparent !important;
    background-color: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    color: #e8f2ff !important;
    -webkit-text-fill-color: #e8f2ff !important;
}
html[data-theme="dark"] .pd-page .pd-field .select2-container .select2-search--inline .select2-search__field::placeholder {
    color: #8eb0d4 !important;
    -webkit-text-fill-color: #8eb0d4 !important;
    opacity: 0.9 !important;
}
html[data-theme="dark"] .pd-page .pd-total {
    background: #12243f !important;
    border-color: rgba(62, 197, 255, 0.28) !important;
}
html[data-theme="dark"] .pd-page .pd-total span { color: #8eb0d4 !important; }
html[data-theme="dark"] .pd-page .pd-total strong { color: #e8f2ff !important; }
html[data-theme="dark"] .pd-page .pd-total--main {
    background: #163056 !important;
    border-color: rgba(47, 125, 255, 0.45) !important;
}
html[data-theme="dark"] .pd-page .pd-total--main strong { color: #ffffff !important; }
html[data-theme="dark"] .pd-page .pd-empty-icon {
    background: #163056 !important;
    color: #3ec5ff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .pd-page .pd-table th {
    background: #2f7dff !important;
    color: #ffffff !important;
    border-color: transparent !important;
}
html[data-theme="dark"] .pd-page .pd-table td,
html[data-theme="dark"] .pd-page .pd-table tbody tr:hover td {
    background: #0e1c36 !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.2) !important;
}
html[data-theme="dark"] .pd-page .pd-prov,
html[data-theme="dark"] .pd-page .pd-line,
html[data-theme="dark"] .pd-page .pd-line:nth-child(even) {
    background: #0e1c36 !important;
    border-color: rgba(62, 197, 255, 0.2) !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pd-page .pd-prov-head {
    background: #163056 !important;
    background-image: none !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .pd-page .pd-prov-head span { color: #3ec5ff !important; }
html[data-theme="dark"] .pd-page .pd-facts > span {
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pd-page .pd-line input,
html[data-theme="dark"] .pd-page .pd-avisos {
    background: #07111f !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .pd-page .pd-line input:focus,
html[data-theme="dark"] .pd-page .pd-field .form-control:focus,
html[data-theme="dark"] .pd-page .pd-field .form-select:focus {
    border-color: #3ec5ff !important;
    box-shadow: 0 0 0 3px rgba(62, 197, 255, 0.22) !important;
}
html[data-theme="dark"] .pd-page .pd-estado {
    background: #163056 !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .pd-page .pd-open,
html[data-theme="dark"] .pd-page .pd-open:hover {
    background: #12243f !important;
    color: #3ec5ff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .pd-page .pd-del {
    background: #12243f !important;
    color: #ff8b9a !important;
    border-color: rgba(255, 139, 154, 0.4) !important;
}

/* Rubros sin alta (importación de ventas) */
html[data-theme="dark"] #modalRubrosFaltantes .vt-modal-icon {
    background: #163056 !important;
    background-image: none !important;
    color: #3ec5ff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] #modalRubrosFaltantes .vt-modal-icon i { color: #3ec5ff !important; }
html[data-theme="dark"] #modalRubrosFaltantes .vt-rubros-faltantes-list {
    background: #0e1c36 !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] #modalRubrosFaltantes .vt-rubro-chip {
    background: #163056 !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] #modalRubrosFaltantes .vt-rubro-chip i { color: #3ec5ff !important; }

/* Análisis de ventas — matriz mensual y restos beige/menta */
html[data-theme="dark"] .vt-ax-mes-chip,
html[data-theme="dark"] .vt-ax-mes-chip:hover,
html[data-theme="dark"] .vt-ax-matriz-tab,
html[data-theme="dark"] .vt-ax-matriz-tab:hover {
    background: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-ax-mes-chip.active,
html[data-theme="dark"] .vt-ax-matriz-tab.active {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: #2f7dff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-ax-matriz-tab .vt-ax-tab-count {
    background: #163056 !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .vt-ax-link-btn,
html[data-theme="dark"] .vt-ax-link-btn:hover { color: #3ec5ff !important; }
html[data-theme="dark"] .vt-ax-matriz-toolbar {
    border-bottom-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .vt-ax-matriz-meta,
html[data-theme="dark"] .vt-ax-section-head p,
html[data-theme="dark"] .vt-ax-kpi-label,
html[data-theme="dark"] .vt-ax-kpi-meta { color: #b7cbe6 !important; }
html[data-theme="dark"] .vt-ax-section-head h2,
html[data-theme="dark"] .vt-ax-kpi-value,
html[data-theme="dark"] .vt-ax-card-head h3 { color: #ffffff !important; }
html[data-theme="dark"] .vt-ax-section-head h2 i,
html[data-theme="dark"] .vt-ax-card-head h3 i { color: #3ec5ff !important; }
html[data-theme="dark"] .vt-ax-matriz-wrap,
html[data-theme="dark"] .vt-ax-matriz,
html[data-theme="dark"] .vt-ax-matriz tbody,
html[data-theme="dark"] .vt-ax-matriz tbody tr,
html[data-theme="dark"] .vt-ax-matriz tbody td {
    background: #0e1c36 !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.15) !important;
}
html[data-theme="dark"] .vt-ax-matriz thead th,
html[data-theme="dark"] .vt-ax-matriz thead th:nth-child(1),
html[data-theme="dark"] .vt-ax-matriz thead th:nth-child(2) {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: transparent !important;
}
html[data-theme="dark"] .vt-ax-matriz tbody td:nth-child(1),
html[data-theme="dark"] .vt-ax-matriz tbody td:nth-child(2) {
    background: #12243f !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .vt-ax-matriz .vt-ax-cell,
html[data-theme="dark"] .vt-ax-matriz .vt-ax-cell--heat-1 {
    background: #12243f !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .vt-ax-matriz .vt-ax-cell--heat-2 { background: #163056 !important; color: #e8f2ff !important; }
html[data-theme="dark"] .vt-ax-matriz .vt-ax-cell--heat-3 { background: #1d4fad !important; color: #ffffff !important; }
html[data-theme="dark"] .vt-ax-matriz .vt-ax-cell--heat-4 { background: #2f7dff !important; color: #ffffff !important; }
html[data-theme="dark"] .vt-ax-matriz .vt-ax-prom {
    background: #163056 !important;
    color: #3ec5ff !important;
}
html[data-theme="dark"] .vt-ax-matriz .vt-ax-dow {
    background: #163056 !important;
    color: #e8f2ff !important;
}
html[data-theme="dark"] .vt-ax-empty,
html[data-theme="dark"] .vt-ax-empty p,
html[data-theme="dark"] .vt-ax-empty i {
    background: transparent !important;
    color: #b7cbe6 !important;
    opacity: 1 !important;
}
html[data-theme="dark"] .vt-ax-kpi--gold,
html[data-theme="dark"] .vt-ax-kpi--sage,
html[data-theme="dark"] .vt-ax-kpi--peach,
html[data-theme="dark"] .vt-ax-kpi--coral,
html[data-theme="dark"] .vt-ax-kpi--sky,
html[data-theme="dark"] .vt-ax-kpi--mint { border-top-color: #2f7dff !important; }
html[data-theme="dark"] .vt-ax-kpi-icon,
html[data-theme="dark"] .vt-ax-kpi--gold .vt-ax-kpi-icon,
html[data-theme="dark"] .vt-ax-kpi--sage .vt-ax-kpi-icon,
html[data-theme="dark"] .vt-ax-kpi--peach .vt-ax-kpi-icon,
html[data-theme="dark"] .vt-ax-kpi--coral .vt-ax-kpi-icon,
html[data-theme="dark"] .vt-ax-kpi--sky .vt-ax-kpi-icon,
html[data-theme="dark"] .vt-ax-kpi--mint .vt-ax-kpi-icon {
    background: #163056 !important;
    color: #3ec5ff !important;
}
html[data-theme="dark"] .vt-ax-badge,
html[data-theme="dark"] .vt-ax-badge--sage {
    background: #163056 !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .vt-ax-table thead th {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: transparent !important;
}
html[data-theme="dark"] .vt-ax-table tbody td {
    background: #12243f !important;
    color: #e8f2ff !important;
    border-color: rgba(62, 197, 255, 0.15) !important;
}
html[data-theme="dark"] .vt-ax-table tbody tr:hover td { background: #163056 !important; }
html[data-theme="dark"] .vt-ax-rank,
html[data-theme="dark"] .vt-ax-rank--1,
html[data-theme="dark"] .vt-ax-rank--2,
html[data-theme="dark"] .vt-ax-rank--3 {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
}
html[data-theme="dark"] .vt-ax-field .form-control,
html[data-theme="dark"] .vt-ax-field .form-select,
html[data-theme="dark"] .vt-ax-field .form-control:focus,
html[data-theme="dark"] .vt-ax-field .form-select:focus,
html[data-theme="dark"] .vt-ax-anio-wrap input {
    background: #07111f !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .vt-ax-anio-btn,
html[data-theme="dark"] .vt-ax-anio-btn:hover {
    background: #12243f !important;
    color: #ffffff !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}

/* ============================================================
   DataTables en oscuro: dos navies, sin pastillas blancas.
   La franja clara del primer pintado es thead tr.filters:
   sus inputs y el select2 "Todos" quedan #fff en kyo-theme /
   RpSelect2 hasta que termina html.kyo-pending.
   ============================================================ */
html[data-theme="dark"] .dt-dark-wrap,
html[data-theme="dark"] .dataTables_wrapper,
html[data-theme="dark"] .dataTables_scroll,
html[data-theme="dark"] .dataTables_scrollHead,
html[data-theme="dark"] .dataTables_scrollHeadInner,
html[data-theme="dark"] .dataTables_scrollBody {
    background: #0e1c36 !important;
    background-color: #0e1c36 !important;
}
html[data-theme="dark"] table.dataTable thead > tr:first-child > th,
html[data-theme="dark"] table.dataTable.dt-dark thead > tr:first-child > th,
html[data-theme="dark"] .dataTables_scrollHead table thead > tr:first-child > th,
html[data-theme="dark"] .dt-dark thead tr:first-child th {
    background: #2f7dff !important;
    background-image: none !important;
    color: #ffffff !important;
    border-color: transparent !important;
}
html[data-theme="dark"] table.dataTable thead tr.filters th,
html[data-theme="dark"] table.dataTable.dt-dark thead tr.filters th,
html[data-theme="dark"] .dt-dark thead tr.filters th,
html[data-theme="dark"] .dataTables_scrollHead thead tr.filters th,
html[data-theme="dark"] thead.filters th {
    background: #0e1c36 !important;
    background-color: #0e1c36 !important;
    background-image: none !important;
    color: #b7cbe6 !important;
    border-color: rgba(62, 197, 255, 0.2) !important;
}
html[data-theme="dark"] table.dataTable thead tr.filters th input,
html[data-theme="dark"] table.dataTable thead tr.filters th select,
html[data-theme="dark"] table.dataTable.dt-dark thead tr.filters th input,
html[data-theme="dark"] table.dataTable.dt-dark thead tr.filters th select,
html[data-theme="dark"] .dt-dark thead tr.filters th input,
html[data-theme="dark"] .dt-dark thead tr.filters th select,
html[data-theme="dark"] select.rp-filter-thead,
html[data-theme="dark"] select.kyo-col-filter,
html[data-theme="dark"] .rp-filter-thead,
html[data-theme="dark"] .kyo-col-filter,
html[data-theme="dark"] .rp-filter-thead:focus,
html[data-theme="dark"] .kyo-col-filter:focus,
html[data-theme="dark"] thead.filters .select2-container--default .select2-selection--single,
html[data-theme="dark"] tr.filters .select2-container--default .select2-selection--single,
html[data-theme="dark"] .dataTables_scrollHead thead.filters .select2-container--default .select2-selection--single,
html[data-theme="dark"] .dataTables_scrollHead tr.filters .select2-container--default .select2-selection--single {
    background: #07111f !important;
    background-color: #07111f !important;
    background-image: none !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] thead.filters .select2-selection__rendered,
html[data-theme="dark"] tr.filters .select2-selection__rendered,
html[data-theme="dark"] thead.filters .select2-container--default .select2-selection--single .select2-selection__rendered,
html[data-theme="dark"] tr.filters .select2-container--default .select2-selection--single .select2-selection__rendered {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}
html[data-theme="dark"] table.dataTable tbody tr.odd,
html[data-theme="dark"] table.dataTable tbody tr.odd > td,
html[data-theme="dark"] table.dataTable tbody tr.odd > .sorting_1,
html[data-theme="dark"] table.dataTable tbody tr.odd > .sorting_2,
html[data-theme="dark"] table.dataTable tbody tr.odd > .sorting_3,
html[data-theme="dark"] table.dataTable.display tbody tr:nth-child(odd) > td,
html[data-theme="dark"] table.dataTable.stripe tbody tr.odd > td,
html[data-theme="dark"] table.dt-dark tbody tr:nth-child(odd) > td {
    background: #0e1c36 !important;
    background-color: #0e1c36 !important;
    background-image: none !important;
    color: #e8f2ff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] table.dataTable tbody tr.even,
html[data-theme="dark"] table.dataTable tbody tr.even > td,
html[data-theme="dark"] table.dataTable tbody tr.even > .sorting_1,
html[data-theme="dark"] table.dataTable tbody tr.even > .sorting_2,
html[data-theme="dark"] table.dataTable tbody tr.even > .sorting_3,
html[data-theme="dark"] table.dataTable.display tbody tr:nth-child(even) > td,
html[data-theme="dark"] table.dataTable.stripe tbody tr.even > td,
html[data-theme="dark"] table.dt-dark tbody tr:nth-child(even) > td {
    background: #12243f !important;
    background-color: #12243f !important;
    background-image: none !important;
    color: #e8f2ff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] table.dataTable tbody tr:hover > td,
html[data-theme="dark"] table.dataTable tbody tr:hover > .sorting_1,
html[data-theme="dark"] table.dataTable tbody tr:hover > .sorting_2,
html[data-theme="dark"] table.dataTable tbody tr:hover > .sorting_3,
html[data-theme="dark"] table.dt-dark tbody tr:hover > td {
    background: #163056 !important;
    background-color: #163056 !important;
    color: #ffffff !important;
}
html[data-theme="dark"] button.dt-button,
html[data-theme="dark"] a.dt-button,
html[data-theme="dark"] div.dt-button,
html[data-theme="dark"] .dataTables_wrapper .dt-buttons .dt-button,
html[data-theme="dark"] .dataTables_wrapper .dt-buttons.btn-group > .dt-button,
html[data-theme="dark"] .dataTables_wrapper .dt-buttons .dt-button:hover,
html[data-theme="dark"] .dataTables_wrapper .dt-buttons .dt-button:focus,
html[data-theme="dark"] div.dt-button-collection,
html[data-theme="dark"] div.dt-button-collection .dt-button,
html[data-theme="dark"] div.dt-button-collection .dt-button:hover {
    background: #12243f !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .dataTables_wrapper .dataTables_filter input,
html[data-theme="dark"] .dataTables_wrapper .dataTables_filter input:focus,
html[data-theme="dark"] .dataTables_wrapper .dataTables_length select,
html[data-theme="dark"] .dataTables_wrapper .dataTables_length select:focus {
    background-color: #07111f !important;
    color: #ffffff !important;
    border: 1px solid rgba(62, 197, 255, 0.35) !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .dataTables_wrapper .dataTables_filter label,
html[data-theme="dark"] .dataTables_wrapper .dataTables_length label,
html[data-theme="dark"] .dataTables_wrapper .dataTables_info,
html[data-theme="dark"] .dataTables_wrapper .dataTables_paginate .paginate_button {
    color: #b7cbe6 !important;
}
html[data-theme="dark"] .dataTables_wrapper .dataTables_paginate {
    background: #0e1c36 !important;
    border-color: rgba(62, 197, 255, 0.35) !important;
}
html[data-theme="dark"] .dataTables_wrapper .dataTables_paginate .paginate_button.current,
html[data-theme="dark"] .dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
    background: #2f7dff !important;
    color: #ffffff !important;
    border-color: #2f7dff !important;
}
/* Acciones (rp-act): no tocar — kyo-grid.css define cuadrados sólidos */
html[data-theme="dark"] .rp-grid-id,
html[data-theme="dark"] table .rp-grid-id,
html[data-theme="dark"] .rp-grid-id-hash {
    background: transparent !important;
    color: #e8f2ff !important;
    border: 0 !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .stk-pill,
html[data-theme="dark"] .stk-pill--ok,
html[data-theme="dark"] .stk-pill--bajo,
html[data-theme="dark"] .stk-pill--sin,
html[data-theme="dark"] .stk-pill--cero {
    background: transparent !important;
    background-image: none !important;
    border: 0 !important;
    box-shadow: none !important;
}
html[data-theme="dark"] .stk-pill--ok,
html[data-theme="dark"] .stk-pill--ok i,
html[data-theme="dark"] .stk-pill--bajo,
html[data-theme="dark"] .stk-pill--bajo i { color: #e8f2ff !important; }
html[data-theme="dark"] .stk-pill--sin,
html[data-theme="dark"] .stk-pill--sin i { color: #ff8b8b !important; }
html[data-theme="dark"] .stk-pill--cero,
html[data-theme="dark"] .stk-pill--cero i { color: #b7cbe6 !important; }
html[data-theme="dark"] .dataTables_scrollBody,
html[data-theme="dark"] .kyo-dt-scroll {
    scrollbar-color: #3ec5ff transparent !important;
}

/* La zebra (odd/even) y el hover se declaran después del seleccionado y lo tapan.
   Este azul es más claro que la fila (#0e1c36 / #12243f) y que el hover (#163056). */
html[data-theme="dark"] :is(table.dataTable, table.dt-dark, table.pd-table) tbody tr:is(.selected, .dt-row-selected, .seleccionada, .row-selected) > td,
html[data-theme="dark"] :is(table.dataTable, table.dt-dark, table.pd-table) tbody tr:is(.selected, .dt-row-selected, .seleccionada, .row-selected) > *,
html[data-theme="dark"] :is(.pg-cc-page, .cc-table, .rm-page, .ts-page, .modal, .pd-page, .vt-page) :is(table.dataTable, table.dt-dark) tbody tr:is(.selected, .dt-row-selected, .seleccionada, .row-selected):nth-child(n) > td {
    background: #1a4fd0 !important;
    background-color: #1a4fd0 !important;
    background-image: none !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    box-shadow: none !important;
}
html[data-theme="dark"] :is(table.dataTable, table.dt-dark, table.pd-table) tbody tr:is(.selected, .dt-row-selected, .seleccionada, .row-selected) > td:first-child,
html[data-theme="dark"] :is(table.dataTable, table.dt-dark, table.pd-table) tbody tr:is(.selected, .dt-row-selected, .seleccionada, .row-selected) > *:first-child {
    box-shadow: inset 4px 0 0 #7ad7ff !important;
}
html[data-theme="dark"] :is(table.dataTable, table.dt-dark, table.pd-table) tbody tr:is(.selected, .dt-row-selected, .seleccionada, .row-selected):hover > td,
html[data-theme="dark"] :is(table.dataTable, table.dt-dark, table.pd-table) tbody tr:is(.selected, .dt-row-selected, .seleccionada, .row-selected):hover > * {
    background: #2f7dff !important;
    background-color: #2f7dff !important;
    color: #ffffff !important;
}

/* Buscador global de las grillas: pastilla navy. El shorthand background
   de más arriba borra el ícono; este bloque va último y lo restaura. */
html[data-theme="dark"] body .dataTables_wrapper .dataTables_filter label,
html[data-theme="dark"] body .page-99 .dataTables_wrapper .dataTables_filter label,
html[data-theme="dark"] body .vt-page .dataTables_wrapper .dataTables_filter label {
    background: transparent !important;
    color: transparent !important;
    font-size: 0 !important;
}
html[data-theme="dark"] body .dataTables_wrapper .dataTables_filter input,
html[data-theme="dark"] body .page-99 .dataTables_wrapper .dataTables_filter input,
html[data-theme="dark"] body .vt-page .dataTables_wrapper .dataTables_filter input,
html[data-theme="dark"] body .dataTables_wrapper .dataTables_filter input:focus,
html[data-theme="dark"] body .page-99 .dataTables_wrapper .dataTables_filter input:focus,
html[data-theme="dark"] body .vt-page .dataTables_wrapper .dataTables_filter input:focus {
    appearance: none !important;
    -webkit-appearance: none !important;
    color-scheme: dark;
    width: 11.5rem;
    height: 34px;
    margin: 0 !important;
    padding: 0 0.85rem 0 2.15rem !important;
    font-size: 0.82rem !important;
    line-height: 34px !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    background-color: #07111f !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239ec6ea' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='6.5'/%3E%3Cpath d='M16.2 16.2 20.5 20.5'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: 0.7rem center !important;
    background-size: 14px 14px !important;
    border: 1px solid rgba(62, 197, 255, 0.4) !important;
    border-radius: 999px !important;
    box-shadow: none !important;
    outline: none !important;
}
html[data-theme="dark"] body .dataTables_wrapper .dataTables_filter input:focus,
html[data-theme="dark"] body .page-99 .dataTables_wrapper .dataTables_filter input:focus,
html[data-theme="dark"] body .vt-page .dataTables_wrapper .dataTables_filter input:focus {
    border-color: #3ec5ff !important;
    box-shadow: 0 0 0 3px rgba(62, 197, 255, 0.22) !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237ad7ff' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='6.5'/%3E%3Cpath d='M16.2 16.2 20.5 20.5'/%3E%3C/svg%3E") !important;
}
html[data-theme="dark"] body .dataTables_wrapper .dataTables_filter input::placeholder,
html[data-theme="dark"] body .page-99 .dataTables_wrapper .dataTables_filter input::placeholder,
html[data-theme="dark"] body .vt-page .dataTables_wrapper .dataTables_filter input::placeholder {
    color: #d5e6f8 !important;
    -webkit-text-fill-color: #d5e6f8 !important;
    opacity: 1 !important;
}
html[data-theme="dark"] body .dataTables_wrapper .dataTables_filter input::-webkit-search-cancel-button {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    cursor: pointer;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239ec6ea' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M6 6l12 12M18 6 6 18'/%3E%3C/svg%3E") center / 12px 12px no-repeat;
}

/* ============================================================
   Sistema de tarjetas oscuro
   Superficie neutra, contraste real y azul sólo como acento.
   Este bloque queda al final para corregir colores claros que
   algunos módulos declaran con mayor especificidad.
   ============================================================ */
html[data-theme="dark"] {
    --kyo-card-bg: #111a28;
    --kyo-card-bg-raised: #162235;
    --kyo-card-bg-hover: #19283d;
    --kyo-card-border: rgba(148, 163, 184, 0.18);
    --kyo-card-border-hover: rgba(96, 165, 250, 0.48);
    --kyo-card-text: #f1f5f9;
    --kyo-card-muted: #9fb0c3;
    --kyo-card-accent: #60a5fa;
    --kyo-card-shadow: 0 8px 24px rgba(0, 0, 0, 0.22);
    --kyo-card-shadow-hover: 0 14px 34px rgba(0, 0, 0, 0.32);
}

html[data-theme="dark"] body :is(
    .card, .card-glass,
    .rp-data-card, .cg-data-card,
    .ts-card, .ts-panel, .ts-kpi, .ts-tile, .ts-box,
    .rp-config-card, .rp-config-view-card, .rp-list-item,
    .pg-kpi-mini, .pg-ax-kpi, .pg-ax-card, .pg-pago-card,
    .pa-kpi, .pa-panel, .pa-rank-item,
    .ax-kpi-card, .ax-chart-card, .ax-rank-item,
    .vt-kpi, .vt-file-card, .vt-ax-kpi, .vt-ax-card,
    .pd-kpi, .pd-panel,
    .cc-card, .cc-kpi, .oc-card-item,
    .rm-cost-card, .kyo-hist-card,
    .kyo-empty-card, .pg-precios-empty-card
) {
    background: linear-gradient(145deg, var(--kyo-card-bg-raised) 0%, var(--kyo-card-bg) 100%) !important;
    background-color: var(--kyo-card-bg) !important;
    color: var(--kyo-card-text) !important;
    border-color: var(--kyo-card-border) !important;
    box-shadow: var(--kyo-card-shadow) !important;
}

html[data-theme="dark"] body :is(
    .rp-data-card, .cg-data-card,
    .rp-config-card, .rp-config-view-card,
    .ts-card, .ts-kpi, .ts-tile,
    .pg-kpi-mini, .pg-ax-kpi, .pg-ax-card, .pg-pago-card,
    .pa-kpi, .pa-panel, .pa-rank-item,
    .ax-kpi-card, .ax-chart-card, .ax-rank-item,
    .vt-kpi, .vt-file-card, .vt-ax-kpi, .vt-ax-card,
    .pd-kpi, .cc-card, .cc-kpi, .oc-card-item,
    .rm-cost-card, .kyo-hist-card
):hover {
    background: linear-gradient(145deg, var(--kyo-card-bg-hover) 0%, #131f30 100%) !important;
    border-color: var(--kyo-card-border-hover) !important;
    box-shadow: var(--kyo-card-shadow-hover) !important;
}

html[data-theme="dark"] body :is(
    .card-header, .card-footer,
    .rp-data-card-head, .cg-data-card-head,
    .rp-data-card-foot, .cg-data-card-foot,
    .vt-ax-card-head, .ax-chart-head
) {
    background: rgba(7, 13, 24, 0.2) !important;
    background-image: none !important;
    color: var(--kyo-card-text) !important;
    border-color: var(--kyo-card-border) !important;
}

html[data-theme="dark"] body :is(
    .rp-data-card-title, .cg-data-card-title,
    .rp-data-card__title, .cg-data-card__title,
    .rp-card-field strong, .cg-card-field strong,
    .oc-card-title, .kyo-hist-resumo,
    .ts-kpi-value, .pa-kpi-value, .ax-kpi-value,
    .vt-kpi-value, .vt-ax-kpi-value, .pd-kpi strong,
    .pg-kpi-mini .pg-kpi-value,
    .card-title, .card h1, .card h2, .card h3,
    .card h4, .card h5, .card h6
) {
    color: var(--kyo-card-text) !important;
    -webkit-text-fill-color: var(--kyo-card-text) !important;
    opacity: 1 !important;
}

html[data-theme="dark"] body :is(
    .rp-data-card-sub, .cg-data-card-sub,
    .rp-data-card__meta, .cg-data-card__meta,
    .rp-card-field span, .cg-card-field span,
    .oc-card-sub, .cc-muted,
    .ts-kpi-label, .ts-kpi-hint,
    .pa-kpi-label, .pa-kpi-hint,
    .ax-kpi-label, .ax-kpi-meta,
    .vt-kpi-label, .vt-ax-kpi-label, .vt-ax-kpi-meta,
    .pg-kpi-mini .pg-kpi-label,
    .card-subtitle, .card-text.text-muted
) {
    color: var(--kyo-card-muted) !important;
    -webkit-text-fill-color: var(--kyo-card-muted) !important;
    opacity: 1 !important;
}

html[data-theme="dark"] body :is(.rp-data-card-badge, .cg-data-card-badge) {
    background: rgba(96, 165, 250, 0.12) !important;
    color: #bfdbfe !important;
    border-color: rgba(96, 165, 250, 0.28) !important;
}

html[data-theme="dark"] body :is(.rp-data-card, .cg-data-card).is-selected {
    background: linear-gradient(145deg, #1b3150 0%, #142238 100%) !important;
    border-color: rgba(96, 165, 250, 0.7) !important;
    box-shadow:
        inset 4px 0 0 var(--kyo-card-accent),
        0 0 0 1px rgba(96, 165, 250, 0.18),
        var(--kyo-card-shadow-hover) !important;
}

html[data-theme="dark"] body :is(
    .ts-kpi-icon, .pa-kpi-icon, .vt-ax-kpi-icon,
    .cc-kpi-icon, .vt-hero-icon, .pd-hero-icon
) {
    background: rgba(96, 165, 250, 0.12) !important;
    color: #93c5fd !important;
    border-color: rgba(96, 165, 250, 0.22) !important;
    box-shadow: none !important;
}

html[data-theme="dark"] body .rp-cards-pager {
    background: #111a28 !important;
    color: #9fb0c3 !important;
    border-color: rgba(148, 163, 184, 0.18) !important;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2) !important;
}

html[data-theme="dark"] body .rp-cards-pager-info,
html[data-theme="dark"] body .rp-cards-page-size {
    color: #9fb0c3 !important;
}

html[data-theme="dark"] body .rp-cards-pager-info strong {
    color: #f1f5f9 !important;
}

html[data-theme="dark"] body .rp-cards-page,
html[data-theme="dark"] body .rp-cards-page-length {
    background: #162235 !important;
    color: #cbd5e1 !important;
    border-color: rgba(148, 163, 184, 0.2) !important;
    box-shadow: none !important;
}

html[data-theme="dark"] body .rp-cards-page:hover:not(:disabled):not(.is-active) {
    background: #1e3048 !important;
    color: #bfdbfe !important;
    border-color: rgba(96, 165, 250, 0.48) !important;
}

html[data-theme="dark"] body .rp-cards-page.is-active {
    background: #2563eb !important;
    color: #fff !important;
    border-color: #3b82f6 !important;
}

html[data-theme="dark"] body .rp-cards-page-gap {
    color: #718399 !important;
}

html[data-theme="dark"] body .rp-card-select-mark {
    background: #0d1726 !important;
    color: transparent !important;
    border-color: rgba(148, 163, 184, 0.38) !important;
}

html[data-theme="dark"] body .rp-card-select:hover .rp-card-select-mark {
    border-color: #60a5fa !important;
}

html[data-theme="dark"] body .rp-card-select-input:checked + .rp-card-select-mark {
    background: #2563eb !important;
    color: #fff !important;
    border-color: #60a5fa !important;
}

/* Modal de historial de conexiones (Usuarios): las tarjetas tenian fondo blanco fijo */
html[data-theme="dark"] .usr-conn-item {
    background: linear-gradient(145deg, #111a28 0%, #0d1726 100%);
    border-color: var(--kyo-border);
    color: var(--kyo-text);
}

html[data-theme="dark"] .usr-conn-item.is-in .usr-conn-icon {
    background: rgba(74, 222, 128, 0.14);
    color: #4ade80;
}

html[data-theme="dark"] .usr-conn-item.is-out .usr-conn-icon {
    background: rgba(248, 113, 113, 0.14);
    color: #f87171;
}

html[data-theme="dark"] .usr-conn-item.is-exp .usr-conn-icon {
    background: rgba(251, 191, 36, 0.16);
    color: #fbbf24;
}

html[data-theme="dark"] .usr-conn-kpi {
    background: rgba(110, 186, 255, 0.05);
    border-color: var(--kyo-border);
}

/* Modal "Nuevo insumo" (Proveedores > Gestion): el campo calculado y el badge del proveedor tenian fondo claro fijo */
html[data-theme="dark"] .pg-insumo-modal #pgInsCostoUnitario {
    background: #0a1728 !important;
    border-color: rgba(90, 170, 255, 0.35) !important;
    color: #7ad7ff !important;
}

html[data-theme="dark"] .pg-insumo-prov-badge {
    background: linear-gradient(135deg, #123056, #152844);
    border-color: rgba(110, 186, 255, 0.28);
    color: #cfe6ff;
}

/* ============================================================
   DataTables en oscuro — bordes suaves (sin líneas blancas).
   El CDN de DataTables y skins claros dejan #111 / #ddd / cyan
   brillante; acá se apagan y se deja sólo un separador sutil.
   ============================================================ */
html[data-theme="dark"] .dt-dark-wrap,
html[data-theme="dark"] .rp-table-wrap,
html[data-theme="dark"] .rp-grid-panel {
    border: 1px solid rgba(148, 163, 184, 0.1) !important;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.28) !important;
    background: #0e1c36 !important;
}

html[data-theme="dark"] .dt-dark-wrap > .dataTables_wrapper,
html[data-theme="dark"] .rp-table-wrap > .dataTables_wrapper,
html[data-theme="dark"] .dataTables_wrapper,
html[data-theme="dark"] .dataTables_scroll,
html[data-theme="dark"] .dataTables_scrollHead,
html[data-theme="dark"] .dataTables_scrollHeadInner,
html[data-theme="dark"] .dataTables_scrollBody,
html[data-theme="dark"] .dataTables_scrollFoot {
    border: 0 !important;
    box-shadow: none !important;
    outline: none !important;
}

html[data-theme="dark"] table.dataTable,
html[data-theme="dark"] table.dataTable.no-footer,
html[data-theme="dark"] table.dataTable.display,
html[data-theme="dark"] table.dataTable.stripe,
html[data-theme="dark"] table.dataTable.hover,
html[data-theme="dark"] table.dataTable.order-column,
html[data-theme="dark"] table.dt-dark {
    border: 0 !important;
    border-bottom: 0 !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    outline: none !important;
}

html[data-theme="dark"] table.dataTable thead > tr > th,
html[data-theme="dark"] table.dataTable thead > tr > td,
html[data-theme="dark"] table.dataTable.dt-dark thead > tr:first-child > th,
html[data-theme="dark"] .dataTables_scrollHead table thead > tr:first-child > th {
    border: 0 !important;
    border-right: 0 !important;
    border-left: 0 !important;
    border-bottom: 0 !important;
    box-shadow: none !important;
}

html[data-theme="dark"] table.dataTable thead tr.filters th,
html[data-theme="dark"] table.dataTable.dt-dark thead tr.filters th,
html[data-theme="dark"] .dataTables_scrollHead thead tr.filters th,
html[data-theme="dark"] thead.filters th {
    border: 0 !important;
    border-bottom: 1px solid rgba(148, 163, 184, 0.08) !important;
    box-shadow: none !important;
}

html[data-theme="dark"] table.dataTable tbody td,
html[data-theme="dark"] table.dataTable tbody th,
html[data-theme="dark"] table.dt-dark tbody td,
html[data-theme="dark"] table.dataTable.display tbody tr td,
html[data-theme="dark"] table.dataTable.stripe tbody tr td {
    border: 0 !important;
    border-top: 0 !important;
    border-right: 0 !important;
    border-left: 0 !important;
    border-bottom: 1px solid rgba(148, 163, 184, 0.06) !important;
    box-shadow: none !important;
}

html[data-theme="dark"] table.dataTable tbody tr:last-child > td,
html[data-theme="dark"] table.dt-dark tbody tr:last-child > td {
    border-bottom-color: transparent !important;
}

html[data-theme="dark"] table.dataTable thead tr.filters th input,
html[data-theme="dark"] table.dataTable thead tr.filters th select,
html[data-theme="dark"] table.dataTable.dt-dark thead tr.filters th input,
html[data-theme="dark"] table.dataTable.dt-dark thead tr.filters th select,
html[data-theme="dark"] .dt-dark thead tr.filters th input,
html[data-theme="dark"] .dt-dark thead tr.filters th select,
html[data-theme="dark"] .rp-filter-thead,
html[data-theme="dark"] .kyo-col-filter,
html[data-theme="dark"] thead.filters .select2-container--default .select2-selection--single,
html[data-theme="dark"] tr.filters .select2-container--default .select2-selection--single,
html[data-theme="dark"] .dataTables_scrollHead thead.filters .select2-container--default .select2-selection--single,
html[data-theme="dark"] .dataTables_scrollHead tr.filters .select2-container--default .select2-selection--single {
    border: 1px solid rgba(148, 163, 184, 0.14) !important;
    box-shadow: none !important;
    background: #0a1424 !important;
}

html[data-theme="dark"] table.dataTable thead tr.filters th input:focus,
html[data-theme="dark"] table.dataTable thead tr.filters th select:focus,
html[data-theme="dark"] .rp-filter-thead:focus,
html[data-theme="dark"] .kyo-col-filter:focus {
    border-color: rgba(96, 165, 250, 0.45) !important;
    box-shadow: 0 0 0 2px rgba(47, 125, 255, 0.16) !important;
}

html[data-theme="dark"] .dataTables_wrapper .dt-buttons .dt-button,
html[data-theme="dark"] .dataTables_wrapper .dt-buttons.btn-group > .dt-button,
html[data-theme="dark"] button.dt-button,
html[data-theme="dark"] a.dt-button,
html[data-theme="dark"] div.dt-button {
    border: 1px solid rgba(148, 163, 184, 0.14) !important;
    box-shadow: none !important;
}

html[data-theme="dark"] .dataTables_wrapper .dataTables_length select,
html[data-theme="dark"] .dataTables_wrapper .dataTables_filter input,
html[data-theme="dark"] body .dataTables_wrapper .dataTables_filter input,
html[data-theme="dark"] body .page-99 .dataTables_wrapper .dataTables_filter input,
html[data-theme="dark"] body .vt-page .dataTables_wrapper .dataTables_filter input {
    border: 1px solid rgba(148, 163, 184, 0.16) !important;
    box-shadow: none !important;
}

html[data-theme="dark"] body .dataTables_wrapper .dataTables_filter input:focus,
html[data-theme="dark"] body .page-99 .dataTables_wrapper .dataTables_filter input:focus,
html[data-theme="dark"] body .vt-page .dataTables_wrapper .dataTables_filter input:focus {
    border-color: rgba(96, 165, 250, 0.5) !important;
    box-shadow: 0 0 0 3px rgba(47, 125, 255, 0.16) !important;
}

html[data-theme="dark"] .dataTables_wrapper .dataTables_paginate {
    border: 1px solid rgba(148, 163, 184, 0.1) !important;
    background: #0f1a2e !important;
    box-shadow: none !important;
}

html[data-theme="dark"] .dataTables_wrapper .dataTables_paginate .paginate_button {
    border: 0 !important;
    box-shadow: none !important;
}

html[data-theme="dark"] .dataTables_wrapper .dataTables_paginate .paginate_button.current,
html[data-theme="dark"] .dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
    border: 0 !important;
    box-shadow: 0 2px 10px rgba(47, 125, 255, 0.28) !important;
}

/* Acciones finales: defer a kyo-grid.css */

html[data-theme="dark"] .rp-grid-id,
html[data-theme="dark"] table .rp-grid-id,
html[data-theme="dark"] .rp-grid-id-hash {
    border: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
}

/* Separador sutil entre toolbar DT y la tabla */
html[data-theme="dark"] .dataTables_wrapper .dataTables_scroll,
html[data-theme="dark"] .kyo-dt-scroll {
    border-top: 1px solid rgba(148, 163, 184, 0.08) !important;
}
