/* Ubicacion: frontend/css/speas-ui.css */

:root {
    --speas-bg: #eceff3;
    --speas-surface: #ffffff;
    --speas-surface-2: #f6f7f9;
    --speas-elevated: #ffffff;
    --speas-sidebar: #f8f9fb;
    --speas-sidebar-2: #ffffff;
    --speas-text: #14171d;
    --speas-muted: #6c7280;
    --speas-border: #d9dee7;
    --speas-border-strong: #bbc2ce;
    --speas-accent: #161a22;
    --speas-accent-2: #5d6673;
    --speas-danger: #dc2626;
    --speas-success: #16a34a;
    --speas-warning: #d97706;
    --speas-radius: 14px;
    --speas-radius-sm: 10px;
    --speas-shadow: 0 14px 40px rgba(15, 23, 42, 0.10);
    --speas-shadow-sm: 0 6px 18px rgba(15, 23, 42, 0.08);
    --speas-input-h: 38px;
    --speas-topbar-h: 58px;
    --speas-font: Inter, "Segoe UI", Arial, sans-serif;
}

html[data-speas-theme="oscuro"] {
    --speas-bg: #0f1115;
    --speas-surface: #171a21;
    --speas-surface-2: #20242d;
    --speas-elevated: #1d222b;
    --speas-sidebar: #090a0d;
    --speas-sidebar-2: #141821;
    --speas-text: #f4f7fb;
    --speas-muted: #a2adbd;
    --speas-border: #303846;
    --speas-border-strong: #465164;
    --speas-accent: #60a5fa;
    --speas-accent-2: #2dd4bf;
    --speas-shadow: 0 18px 46px rgba(0, 0, 0, 0.38);
    --speas-shadow-sm: 0 8px 22px rgba(0, 0, 0, 0.28);
}

html[data-speas-theme="suave"] {
    --speas-bg: #f7f4f7;
    --speas-surface: #ffffff;
    --speas-surface-2: #fbf7fa;
    --speas-elevated: #ffffff;
    --speas-sidebar: #211820;
    --speas-sidebar-2: #312633;
    --speas-text: #211820;
    --speas-muted: #7d6877;
    --speas-border: #eadde7;
    --speas-border-strong: #d9c6d3;
    --speas-accent: #be477f;
    --speas-accent-2: #7c6ee6;
    --speas-shadow: 0 14px 40px rgba(74, 35, 65, 0.12);
    --speas-shadow-sm: 0 6px 18px rgba(74, 35, 65, 0.09);
}

* {
    letter-spacing: 0;
}

body.speas-app {
    background:
        radial-gradient(circle at 24% 12%, rgba(255, 255, 255, 0.88), transparent 30%),
        linear-gradient(180deg, var(--speas-bg), color-mix(in srgb, var(--speas-bg) 88%, var(--speas-surface-2)));
    color: var(--speas-text);
    font-family: var(--speas-font);
}

body.speas-app .home,
body.speas-app .contenedor-modulo {
    background: var(--speas-bg);
    color: var(--speas-text);
}

body.speas-app .home {
    padding: 16px 22px 22px;
    overflow-y: auto;
}

body.speas-app .header-text {
    min-height: var(--speas-topbar-h);
    margin-bottom: 12px;
    padding: 0 12px 0 16px;
    border: 1px solid color-mix(in srgb, var(--speas-border) 82%, transparent);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.78);
    box-shadow: 0 18px 42px rgba(17, 24, 39, 0.08);
    backdrop-filter: blur(18px);
}

body.speas-app .home .text,
body.speas-app #titulo-modulo {
    color: var(--speas-text);
    font-size: 22px;
    font-weight: 700;
}

body.speas-app .sidebar {
    background:
        radial-gradient(circle at 34% 0%, rgba(255, 255, 255, 0.95), transparent 32%),
        linear-gradient(180deg, var(--speas-sidebar-2) 0%, var(--speas-sidebar) 100%);
    box-shadow: 10px 0 34px rgba(17, 24, 39, 0.08);
    border-right: 1px solid rgba(17, 24, 39, 0.08);
    padding-top: 14px;
}

body.speas-app .sidebar header {
    margin-bottom: 14px;
    padding: 0 12px 0 10px;
}

body.speas-app .sidebar .image-text {
    min-height: 54px;
}

body.speas-app .bottom-content {
    background: linear-gradient(180deg, rgba(17, 24, 39, 0.025), transparent);
    border-top-color: rgba(17, 24, 39, 0.08);
    padding-top: 12px;
}

body.speas-app .sidebar li {
    height: 48px;
    margin-top: 5px;
    padding: 0 10px;
}

body.speas-app .sidebar li a {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
}

body.speas-app .sidebar li a::before {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0;
    background: linear-gradient(90deg, rgba(17, 24, 39, 0.08), rgba(17, 24, 39, 0.035));
    transition: opacity 0.22s ease;
}

body.speas-app .sidebar li a:hover,
body.speas-app .sidebar li.active a {
    background: #151922;
    box-shadow: 0 14px 28px rgba(17, 24, 39, 0.14);
}

body.speas-app .sidebar li a:hover::before,
body.speas-app .sidebar li.active a::before {
    opacity: 1;
}

body.speas-app .sidebar li a:hover .icon,
body.speas-app .sidebar li a:hover .text,
body.speas-app .sidebar li.active .icon,
body.speas-app .sidebar li.active .text {
    color: #ffffff;
}

body.speas-app .sidebar li .icon,
body.speas-app .sidebar li .text {
    color: #626975;
}

body.speas-app .sidebar .text {
    position: relative;
    z-index: 1;
    font-size: 14px;
    font-weight: 680;
}

body.speas-app .sidebar li .icon {
    position: relative;
    z-index: 1;
    font-size: 21px;
    transition: transform 0.22s ease, color 0.22s ease;
}

body.speas-app .sidebar li a:hover .icon,
body.speas-app .sidebar li.active .icon {
    transform: translateX(2px) scale(1.04);
}

body.speas-app .sidebar .image .logo-icon,
body.speas-app .sidebar .toggle {
    color: var(--speas-accent-2);
}

body.speas-app .sidebar .image .logo-icon {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: #151922;
    box-shadow: 0 14px 24px rgba(17, 24, 39, 0.18);
    color: #ffffff;
    font-size: 30px;
}

body.speas-app .image-text .name {
    font-size: 20px;
    font-weight: 820;
    letter-spacing: 0;
    color: #151922;
}

body.speas-app .image-text .profession {
    color: #7a828e;
    font-size: 12px;
}

body.speas-app .sidebar .toggle {
    background: #151922;
    color: #ffffff;
    box-shadow: 0 10px 20px rgba(37, 99, 235, 0.28);
}

body.speas-app .profile-card,
body.speas-app .logout-box {
    border-radius: 14px;
}

body.speas-app .profile-card {
    background: #ffffff;
    border: 1px solid rgba(17, 24, 39, 0.08);
    box-shadow: 0 14px 28px rgba(17, 24, 39, 0.08);
}

body.speas-app .profile-card:hover {
    background: #f1f3f6;
}

body.speas-app .logout-box:hover {
    background: rgba(17, 24, 39, 0.06);
}

body.speas-app .profile-info .name {
    color: #151922;
}

body.speas-app .profile-info .role,
body.speas-app .logout-box .icon,
body.speas-app .logout-box .text {
    color: #626975;
}

.speas-top-search {
    width: min(340px, 28vw);
    height: 38px;
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 0 10px;
    border: 1px solid var(--speas-border);
    border-radius: 12px;
    background: var(--speas-surface-2);
    color: var(--speas-muted);
}

.speas-top-search i {
    font-size: 18px;
}

.speas-top-search input {
    width: 100%;
    min-height: 0;
    height: 32px;
    border: 0;
    padding: 0;
    background: transparent;
    color: var(--speas-text);
    font-size: 13px;
}

.speas-top-search input:focus {
    box-shadow: none;
}

.speas-top-search span {
    flex: 0 0 auto;
    padding: 2px 6px;
    border-radius: 7px;
    background: #ffffff;
    border: 1px solid var(--speas-border);
    color: #8a919d;
    font-size: 11px;
    font-weight: 700;
}

.speas-top-search + .speas-shell-actions {
    margin-left: 0;
}

html[data-speas-theme="oscuro"] body.speas-app .sidebar {
    background:
        radial-gradient(circle at 35% 0%, rgba(255, 255, 255, 0.07), transparent 30%),
        linear-gradient(180deg, #090a0d 0%, #141821 100%);
    border-right-color: rgba(255, 255, 255, 0.07);
}

html[data-speas-theme="oscuro"] body.speas-app .sidebar li .icon,
html[data-speas-theme="oscuro"] body.speas-app .sidebar li .text,
html[data-speas-theme="oscuro"] body.speas-app .logout-box .icon,
html[data-speas-theme="oscuro"] body.speas-app .logout-box .text {
    color: #a2adbd;
}

html[data-speas-theme="oscuro"] body.speas-app .image-text .name,
html[data-speas-theme="oscuro"] body.speas-app .profile-info .name {
    color: #f4f7fb;
}

html[data-speas-theme="oscuro"] body.speas-app .image-text .profession,
html[data-speas-theme="oscuro"] body.speas-app .profile-info .role {
    color: #a2adbd;
}

html[data-speas-theme="oscuro"] body.speas-app .profile-card {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(255, 255, 255, 0.08);
}

.speas-shell-actions {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 8px;
}

.speas-theme-switch {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    height: 34px;
    padding: 3px;
    border: 1px solid var(--speas-border);
    border-radius: 999px;
    background: color-mix(in srgb, var(--speas-surface) 86%, transparent);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
    backdrop-filter: blur(12px);
}

.speas-theme-btn {
    width: 28px;
    height: 28px;
    border: 0;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--speas-muted);
    background: transparent;
    transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.speas-theme-btn:hover {
    transform: translateY(-1px);
    color: var(--speas-text);
}

.speas-theme-btn.active {
    color: #ffffff;
    background: var(--speas-accent);
}

body.speas-app .contenedor-modulo {
    padding: 0;
}

body.speas-app .mobile-toggle {
    color: var(--speas-text);
}

body.speas-app .contenedor-modulo > h1,
body.speas-app .contenedor-modulo > p {
    margin-left: 2px;
}

body.speas-app .module-header,
body.speas-app .page-header,
body.speas-app .header-section,
body.speas-app .card,
body.speas-app .kpi-card,
body.speas-app .panel,
body.speas-app .table-container,
body.speas-app .filters-card,
body.speas-app .summary-card,
body.speas-app .analytics-container,
body.speas-app .facturas-container,
body.speas-app .inventory-container,
body.speas-app .crm-container {
    background: var(--speas-surface);
    color: var(--speas-text);
    border-color: var(--speas-border);
    border-radius: var(--speas-radius);
    box-shadow: var(--speas-shadow-sm);
}

body.speas-app table {
    border-collapse: collapse;
    color: var(--speas-text);
}

body.speas-app th {
    background: var(--speas-surface-2);
    color: var(--speas-muted);
    font-size: 12px;
    font-weight: 700;
    height: 42px;
}

body.speas-app td {
    color: var(--speas-text);
    font-size: 13px;
    border-color: var(--speas-border);
}

body.speas-app input,
body.speas-app select,
body.speas-app textarea {
    min-height: var(--speas-input-h);
    border-radius: var(--speas-radius-sm);
    border-color: var(--speas-border);
    background: var(--speas-surface);
    color: var(--speas-text);
}

body.speas-app input:focus,
body.speas-app select:focus,
body.speas-app textarea:focus {
    outline: none;
    border-color: var(--speas-accent);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--speas-accent) 18%, transparent);
}

body.speas-app button,
body.speas-app .btn,
body.speas-app .btn-primary,
body.speas-app .btn-secondary {
    border-radius: var(--speas-radius-sm);
}

.speas-module-enter {
    animation: speasModuleIn 0.26s ease both;
}

@keyframes speasModuleIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.speas-loader-overlay {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(12, 14, 18, 0.56);
    backdrop-filter: blur(12px);
}

.speas-loader-overlay.active {
    display: flex;
}

.speas-loader-panel {
    width: min(360px, calc(100vw - 36px));
    min-height: 300px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 14px;
    background: linear-gradient(180deg, rgba(25, 29, 38, 0.92), rgba(12, 14, 18, 0.92));
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
    position: relative;
    overflow: hidden;
    color: #ffffff;
    display: grid;
    grid-template-rows: 210px auto;
}

.speas-loader-canvas {
    width: 100%;
    height: 210px;
    position: relative;
}

.speas-loader-canvas canvas {
    width: 100%;
    height: 100%;
    display: block;
}

.speas-loader-fallback {
    width: 84px;
    height: 84px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.18);
    background:
        radial-gradient(circle at 50% 50%, rgba(20, 184, 166, 0.9), transparent 33%),
        conic-gradient(from 0deg, transparent, #60a5fa, #14b8a6, transparent);
    filter: drop-shadow(0 0 30px rgba(20, 184, 166, 0.34));
    animation: speasOrbSpin 1.2s linear infinite;
    position: absolute;
    top: 62px;
    left: calc(50% - 42px);
}

@keyframes speasOrbSpin {
    to { transform: rotate(360deg); }
}

.speas-loader-copy {
    padding: 0 28px 28px;
    text-align: center;
}

.speas-loader-title {
    font-size: 18px;
    font-weight: 750;
    margin-bottom: 6px;
}

.speas-loader-message {
    color: rgba(255, 255, 255, 0.68);
    font-size: 13px;
    line-height: 1.45;
}

body.speas-login {
    background: var(--speas-bg);
    color: var(--speas-text);
}

.speas-login .login-panel {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 249, 251, 0.98)),
        var(--speas-surface);
}

.speas-login .visual-panel {
    background:
        linear-gradient(135deg, #ffffff 0%, #f4f6f8 48%, #eef1f5 100%);
    isolation: isolate;
    padding-left: clamp(56px, 6vw, 100px);
    padding-right: clamp(48px, 5vw, 90px);
    color: #151922;
}

.speas-login #login-visual-3d {
    display: none;
}

.speas-login .dynamic-bg {
    background:
        radial-gradient(circle at 16% 22%, rgba(255, 255, 255, 0.96), transparent 28%),
        radial-gradient(circle at 78% 26%, rgba(203, 213, 225, 0.44), transparent 34%),
        radial-gradient(circle at 72% 82%, rgba(255, 255, 255, 0.82), transparent 32%),
        linear-gradient(135deg, #ffffff 0%, #f3f5f8 48%, #e9edf3 100%);
    background-size: 120% 120%;
    animation: speasAurora 16s ease-in-out infinite alternate;
}

.speas-login .visual-overlay {
    background-image:
        linear-gradient(90deg, rgba(255, 255, 255, 0.58) 0%, rgba(255, 255, 255, 0.26) 48%, rgba(255, 255, 255, 0.10) 100%),
        linear-gradient(115deg, transparent 0%, rgba(17, 24, 39, 0.045) 42%, transparent 58%),
        radial-gradient(rgba(17, 24, 39, 0.055) 1px, transparent 1px);
    background-size: auto, auto, 30px 30px;
}

.speas-login .visual-panel::before,
.speas-login .visual-panel::after {
    content: "";
    position: absolute;
    pointer-events: none;
    z-index: 2;
}

.speas-login .visual-panel::before {
    width: 420px;
    height: 420px;
    right: 10%;
    top: 22%;
    border-radius: 999px;
    background:
        radial-gradient(circle, rgba(17, 24, 39, 0.08), rgba(17, 24, 39, 0.035) 38%, transparent 68%),
        conic-gradient(from 140deg, rgba(17, 24, 39, 0.04), rgba(148, 163, 184, 0.18), rgba(255, 255, 255, 0.05), rgba(17, 24, 39, 0.04));
    filter: blur(1px);
    opacity: 0.86;
}

.speas-login .visual-panel::after {
    width: 58%;
    height: 1px;
    right: 5%;
    top: 50%;
    background: linear-gradient(90deg, transparent, rgba(17, 24, 39, 0.16), transparent);
    box-shadow:
        0 74px 0 rgba(255, 255, 255, 0.08),
        0 -92px 0 rgba(148, 163, 184, 0.08);
    transform: rotate(-8deg);
}

@keyframes speasAurora {
    from { background-position: 0% 28%; }
    to { background-position: 100% 72%; }
}

.speas-login .brand-container {
    z-index: 8;
}

.speas-login .brand-logo,
.speas-login .brand-logo i {
    color: #151922;
}

.speas-login .brand-message {
    max-width: min(58vw, 720px);
    padding-bottom: 18px;
}

.speas-login .brand-message h2 {
    max-width: 660px;
    font-size: clamp(34px, 2.8vw, 46px);
    line-height: 1.12;
    color: #151922;
    text-shadow: none;
}

.speas-login .brand-message p {
    max-width: 590px;
    color: #5f6876;
}

.speas-login .login-signal-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 28px;
}

.speas-login .login-signal-grid span {
    min-width: 102px;
    padding: 9px 13px;
    border: 1px solid rgba(17, 24, 39, 0.10);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.78);
    color: #4b5563;
    font-size: 12px;
    font-weight: 650;
    letter-spacing: 0;
    backdrop-filter: blur(12px);
}

.speas-login .system-status {
    max-width: 500px;
    background: rgba(255, 255, 255, 0.86);
    border-color: rgba(17, 24, 39, 0.12);
    box-shadow: 0 18px 42px rgba(17, 24, 39, 0.10);
}

.speas-login .status-indicator,
.speas-login .server-info p {
    color: #151922;
}

.speas-login .server-info p {
    opacity: 0.72;
}

.speas-login .login-content {
    max-width: 420px;
}

.speas-login .login-header {
    margin-bottom: 28px;
}

.speas-login .login-header h3 {
    font-size: 30px;
    letter-spacing: 0;
}

.speas-login .input-box input {
    height: 44px;
    border-radius: 8px;
}

.speas-login .btn-corporate {
    height: 44px;
    border-radius: 8px;
    background: #151922;
}

.speas-login .btn-corporate:hover {
    background: #000000;
}

@media (max-width: 768px) {
    .speas-top-search {
        display: none;
    }

    .speas-login #login-visual-3d,
    .speas-login .login-signal-grid {
        display: none;
    }

    body.speas-app .home {
        padding: 14px;
    }

    .speas-shell-actions {
        gap: 6px;
    }

    .speas-theme-switch {
        height: 32px;
    }
}

/* Speas enterprise redesign v4 */
:root {
    --speas-bg: #f3f5f8;
    --speas-surface: #ffffff;
    --speas-surface-2: #f7f9fb;
    --speas-elevated: #ffffff;
    --speas-sidebar: #ffffff;
    --speas-sidebar-2: #f8fafc;
    --speas-text: #111827;
    --speas-muted: #667085;
    --speas-border: #dce3ec;
    --speas-border-strong: #b9c3d0;
    --speas-accent: #0f766e;
    --speas-accent-2: #2563eb;
    --speas-danger: #dc2626;
    --speas-success: #059669;
    --speas-warning: #b45309;
    --speas-radius: 8px;
    --speas-radius-sm: 6px;
    --speas-shadow: 0 18px 42px rgba(15, 23, 42, 0.10);
    --speas-shadow-sm: 0 8px 22px rgba(15, 23, 42, 0.07);
    --speas-input-h: 34px;
    --speas-topbar-h: 52px;
}

html[data-speas-theme="oscuro"] {
    --speas-bg: #20252d;
    --speas-surface: #2b313b;
    --speas-surface-2: #343b47;
    --speas-elevated: #303744;
    --speas-sidebar: #262c36;
    --speas-sidebar-2: #2d3440;
    --speas-text: #f6f8fb;
    --speas-muted: #c1cad6;
    --speas-border: #46505f;
    --speas-border-strong: #5d6878;
    --speas-accent: #5eead4;
    --speas-accent-2: #93c5fd;
    --speas-shadow: 0 18px 46px rgba(0, 0, 0, 0.24);
    --speas-shadow-sm: 0 8px 22px rgba(0, 0, 0, 0.18);
}

html[data-speas-theme="suave"] {
    --speas-bg: #f8f7f9;
    --speas-surface: #ffffff;
    --speas-surface-2: #fbf8fa;
    --speas-elevated: #ffffff;
    --speas-sidebar: #fffafa;
    --speas-sidebar-2: #ffffff;
    --speas-text: #27212a;
    --speas-muted: #746775;
    --speas-border: #eadfe7;
    --speas-border-strong: #d9c8d3;
    --speas-accent: #b23a67;
    --speas-accent-2: #0f766e;
    --speas-shadow: 0 16px 40px rgba(68, 41, 58, 0.10);
    --speas-shadow-sm: 0 7px 20px rgba(68, 41, 58, 0.08);
}

html {
    font-size: 14px;
}

body.speas-app {
    background: var(--speas-bg);
}

body.speas-app .home {
    padding: 12px 16px 16px;
}

body.speas-app .header-text {
    min-height: var(--speas-topbar-h);
    border-radius: var(--speas-radius);
    background: color-mix(in srgb, var(--speas-surface) 94%, transparent);
    box-shadow: var(--speas-shadow-sm);
}

body.speas-app #titulo-modulo,
body.speas-app .home .text {
    font-size: 18px;
    font-weight: 760;
}

body.speas-app .sidebar {
    background: linear-gradient(180deg, var(--speas-sidebar-2), var(--speas-sidebar));
    border-right: 1px solid var(--speas-border);
    box-shadow: 8px 0 28px rgba(15, 23, 42, 0.06);
}

body.speas-app .sidebar li {
    height: 42px;
    margin-top: 4px;
}

body.speas-app .sidebar li a {
    border-radius: var(--speas-radius-sm);
}

body.speas-app .sidebar li .text {
    font-size: 13px;
    font-weight: 680;
}

body.speas-app .sidebar li .icon {
    font-size: 19px;
}

body.speas-app .sidebar li a:hover,
body.speas-app .sidebar li.active a {
    background: #111827;
    box-shadow: 0 10px 24px rgba(17, 24, 39, 0.13);
}

html[data-speas-theme="oscuro"] body.speas-app .sidebar li a:hover,
html[data-speas-theme="oscuro"] body.speas-app .sidebar li.active a {
    background: #3b4654;
}

html[data-speas-theme="suave"] body.speas-app .sidebar li a:hover,
html[data-speas-theme="suave"] body.speas-app .sidebar li.active a {
    background: #7f1d4c;
}

.speas-logo-mark {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 9px;
    background: #111827;
    color: #ffffff;
    font-size: 18px;
    font-weight: 850;
    letter-spacing: 0;
    line-height: 1;
    box-shadow: 0 12px 24px rgba(17, 24, 39, 0.18);
    position: relative;
    overflow: hidden;
}

.speas-logo-mark::after {
    content: "";
    position: absolute;
    left: 7px;
    right: 7px;
    top: 8px;
    height: 3px;
    border-radius: 999px;
    background: var(--speas-accent);
}

body.speas-app .sidebar .image .logo-icon {
    background: #111827;
    color: #ffffff;
    font-family: var(--speas-font);
    font-size: 18px;
}

body.speas-app .image-text .name {
    color: var(--speas-text);
    font-size: 18px;
    text-transform: none;
}

body.speas-app .image-text .profession {
    color: var(--speas-muted);
    font-size: 11px;
}

body.speas-app .sidebar .toggle {
    width: 24px;
    height: 24px;
    background: var(--speas-accent);
    box-shadow: 0 8px 18px color-mix(in srgb, var(--speas-accent) 28%, transparent);
}

.speas-top-search {
    height: 34px;
    border-radius: var(--speas-radius-sm);
}

.speas-top-search span {
    border-radius: 5px;
    background: var(--speas-surface);
    color: var(--speas-muted);
}

.speas-theme-switch {
    height: 32px;
    border-radius: var(--speas-radius-sm);
}

.speas-theme-btn {
    width: 26px;
    height: 26px;
    border-radius: 5px;
}

.speas-theme-btn.active {
    background: var(--speas-accent);
}

body.speas-app .contenedor-modulo {
    padding: 0;
}

body.speas-app .contenedor-modulo h1,
body.speas-app .contenedor-modulo h2,
body.speas-app .contenedor-modulo h3 {
    color: var(--speas-text);
    letter-spacing: 0;
}

body.speas-app .contenedor-modulo h1 {
    font-size: 22px;
}

body.speas-app .contenedor-modulo h2 {
    font-size: 18px;
}

body.speas-app .contenedor-modulo h3 {
    font-size: 15px;
}

body.speas-app .module-header,
body.speas-app .page-header,
body.speas-app .header-section,
body.speas-app .card,
body.speas-app .kpi-card,
body.speas-app .panel,
body.speas-app .table-container,
body.speas-app .filters-card,
body.speas-app .summary-card,
body.speas-app .analytics-container,
body.speas-app .facturas-container,
body.speas-app .inventory-container,
body.speas-app .crm-container,
body.speas-app .modal-content,
body.speas-app .modal-box,
body.speas-app .form-container,
body.speas-app .section-card {
    border-radius: var(--speas-radius);
    border: 1px solid var(--speas-border);
    background: var(--speas-surface);
    box-shadow: var(--speas-shadow-sm);
}

body.speas-app table {
    width: 100%;
    background: var(--speas-surface);
}

body.speas-app th {
    height: 36px;
    padding: 8px 10px;
    background: var(--speas-surface-2);
    color: var(--speas-muted);
    border-color: var(--speas-border);
    font-size: 11px;
    text-transform: uppercase;
}

body.speas-app td {
    padding: 8px 10px;
    font-size: 12.5px;
}

body.speas-app tbody tr {
    transition: background 0.16s ease, transform 0.16s ease;
}

body.speas-app tbody tr:hover {
    background: color-mix(in srgb, var(--speas-accent) 7%, var(--speas-surface));
}

body.speas-app input,
body.speas-app select,
body.speas-app textarea {
    min-height: var(--speas-input-h);
    border-radius: var(--speas-radius-sm);
    border: 1px solid var(--speas-border);
    background: var(--speas-surface);
    color: var(--speas-text);
    font-size: 13px;
}

body.speas-app textarea {
    min-height: 82px;
}

body.speas-app button,
body.speas-app .btn,
body.speas-app .btn-primary,
body.speas-app .btn-secondary,
body.speas-app .action-btn {
    min-height: 32px;
    border-radius: var(--speas-radius-sm);
    font-size: 12.5px;
    font-weight: 700;
    transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease, border-color 0.16s ease;
}

body.speas-app button:hover,
body.speas-app .btn:hover,
body.speas-app .action-btn:hover {
    transform: translateY(-1px);
}

body.speas-app .btn-primary,
body.speas-app button[type="submit"] {
    background: var(--speas-accent);
    border-color: var(--speas-accent);
    color: #ffffff;
}

body.speas-app .badge,
body.speas-app .status-badge,
body.speas-app .tag,
body.speas-app .chip {
    border-radius: 5px;
    font-weight: 750;
    letter-spacing: 0;
}

body.speas-app [style*="#6366f1"],
body.speas-app [style*="#4f46e5"],
body.speas-app [style*="#695CFE"],
body.speas-app [style*="#695cfe"] {
    border-color: var(--speas-accent) !important;
}

body.speas-app [style*="color:#6366f1"],
body.speas-app [style*="color: #6366f1"],
body.speas-app [style*="color:#695CFE"],
body.speas-app [style*="color: #695CFE"],
body.speas-app [style*="color:#695cfe"],
body.speas-app [style*="color: #695cfe"],
body.speas-app [style*="color:#4f46e5"],
body.speas-app [style*="color: #4f46e5"] {
    color: var(--speas-accent) !important;
}

body.speas-app [style*="background:#6366f1"],
body.speas-app [style*="background: #6366f1"],
body.speas-app [style*="background:#695CFE"],
body.speas-app [style*="background: #695CFE"],
body.speas-app [style*="background:#695cfe"],
body.speas-app [style*="background: #695cfe"],
body.speas-app [style*="background:#4f46e5"],
body.speas-app [style*="background: #4f46e5"] {
    background: var(--speas-accent) !important;
    color: #ffffff !important;
}

.speas-loader-overlay {
    background: color-mix(in srgb, var(--speas-bg) 62%, rgba(17, 24, 39, 0.42));
}

.speas-loader-panel {
    width: min(340px, calc(100vw - 32px));
    min-height: auto;
    grid-template-rows: none;
    gap: 14px;
    padding: 22px;
    border-radius: 10px;
    border: 1px solid var(--speas-border);
    background: var(--speas-surface);
    color: var(--speas-text);
    box-shadow: var(--speas-shadow);
}

.speas-loader-brand {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.speas-loader-bars {
    flex: 1;
    display: grid;
    gap: 6px;
}

.speas-loader-bars span,
.speas-loader-skeleton span {
    display: block;
    height: 8px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--speas-surface-2), color-mix(in srgb, var(--speas-accent) 16%, var(--speas-surface-2)), var(--speas-surface-2));
    background-size: 220% 100%;
    animation: speasShimmer 1.15s ease-in-out infinite;
}

.speas-loader-bars span:nth-child(1) { width: 86%; }
.speas-loader-bars span:nth-child(2) { width: 64%; animation-delay: 0.1s; }
.speas-loader-bars span:nth-child(3) { width: 76%; animation-delay: 0.18s; }

.speas-loader-track {
    height: 3px;
    border-radius: 999px;
    overflow: hidden;
    background: var(--speas-surface-2);
}

.speas-loader-track span {
    display: block;
    width: 44%;
    height: 100%;
    border-radius: inherit;
    background: var(--speas-accent);
    animation: speasProgress 1.05s ease-in-out infinite;
}

.speas-loader-skeleton {
    display: grid;
    gap: 8px;
    margin-top: 2px;
}

.speas-loader-skeleton span:nth-child(1) { width: 92%; }
.speas-loader-skeleton span:nth-child(2) { width: 70%; animation-delay: 0.12s; }
.speas-loader-skeleton span:nth-child(3) { width: 82%; animation-delay: 0.22s; }

.speas-loader-copy {
    padding: 0;
    text-align: left;
}

.speas-loader-title {
    color: var(--speas-text);
    font-size: 14px;
}

.speas-loader-message {
    color: var(--speas-muted);
    font-size: 12px;
}

.speas-loader-canvas,
.speas-loader-fallback {
    display: none;
}

@keyframes speasShimmer {
    0% { background-position: 120% 0; }
    100% { background-position: -120% 0; }
}

@keyframes speasProgress {
    0% { transform: translateX(-110%); }
    100% { transform: translateX(240%); }
}

body.speas-login .enterprise-layout {
    background: var(--speas-bg);
}

body.speas-login .visual-panel {
    flex: 1.05;
    background: #f5f7fa;
    color: var(--speas-text);
    padding: clamp(32px, 5vw, 72px);
}

body.speas-login .dynamic-bg {
    background:
        linear-gradient(135deg, rgba(255,255,255,0.98), rgba(242,246,250,0.92)),
        linear-gradient(90deg, rgba(15,118,110,0.08), rgba(37,99,235,0.08));
    animation: none;
}

body.speas-login .visual-overlay {
    background-image:
        linear-gradient(90deg, rgba(17,24,39,0.04) 1px, transparent 1px),
        linear-gradient(180deg, rgba(17,24,39,0.04) 1px, transparent 1px);
    background-size: 36px 36px;
}

body.speas-login .visual-panel::before,
body.speas-login .visual-panel::after {
    display: none;
}

body.speas-login .brand-logo {
    color: var(--speas-text);
    font-size: 22px;
    letter-spacing: 0;
    text-transform: none;
}

body.speas-login .brand-message h2 {
    font-size: clamp(30px, 3.4vw, 48px);
    letter-spacing: 0;
    max-width: 620px;
}

body.speas-login .brand-message p {
    font-size: 16px;
    line-height: 1.55;
}

body.speas-login .login-panel {
    background: var(--speas-surface);
}

body.speas-login .login-content {
    max-width: 390px;
}

body.speas-login .login-header h3 {
    font-size: 25px;
}

body.speas-login .form-group {
    margin-bottom: 18px;
}

body.speas-login .input-box input {
    height: 42px;
    border-radius: var(--speas-radius-sm);
}

body.speas-login .btn-corporate {
    height: 42px;
    background: #111827;
    border-radius: var(--speas-radius-sm);
}

body.speas-login .btn-corporate:hover {
    background: var(--speas-accent);
}

body.speas-login .loader {
    width: 18px;
    height: 3px;
    border: 0;
    border-radius: 999px;
    background: rgba(255,255,255,0.35);
    position: relative;
    overflow: hidden;
    animation: none;
}

body.speas-login .loader::after {
    content: "";
    display: block;
    width: 42%;
    height: 100%;
    background: #ffffff;
    border-radius: inherit;
    animation: speasProgress 0.9s ease-in-out infinite;
}

body.speas-login .security-notice {
    border-radius: var(--speas-radius);
}

@media (max-width: 1100px) {
    body.speas-login .enterprise-layout {
        min-height: 100vh;
        overflow-y: auto;
    }

    body.speas-login .visual-panel {
        min-height: 210px;
        height: auto;
    }
}

@media (max-width: 768px) {
    html {
        font-size: 13px;
    }

    body.speas-app .home {
        padding: 10px;
    }

    body.speas-app .header-text {
        padding: 0 8px;
    }

    body.speas-app #titulo-modulo {
        font-size: 16px;
    }
}

/* Speas visual polish v5 */
:root {
    --speas-bg: #eef2f6;
    --speas-surface: #ffffff;
    --speas-surface-2: #f8fafc;
    --speas-elevated: #ffffff;
    --speas-sidebar: #ffffff;
    --speas-sidebar-2: #f9fbfd;
    --speas-text: #0f172a;
    --speas-muted: #64748b;
    --speas-border: #d8e0ea;
    --speas-border-strong: #afbccb;
    --speas-accent: #0f766e;
    --speas-accent-2: #1d4ed8;
    --speas-accent-soft: #e6f7f4;
    --speas-danger: #dc2626;
    --speas-success: #059669;
    --speas-warning: #b45309;
    --speas-radius: 10px;
    --speas-radius-sm: 7px;
    --speas-shadow: 0 18px 46px rgba(15, 23, 42, 0.12);
    --speas-shadow-sm: 0 8px 24px rgba(15, 23, 42, 0.08);
    --speas-input-h: 36px;
    --speas-topbar-h: 54px;
}

html[data-speas-theme="oscuro"] {
    --speas-bg: #26303a;
    --speas-surface: #313b47;
    --speas-surface-2: #3a4653;
    --speas-elevated: #35404d;
    --speas-sidebar: #2a3440;
    --speas-sidebar-2: #303b48;
    --speas-text: #f8fafc;
    --speas-muted: #d2d9e4;
    --speas-border: #536173;
    --speas-border-strong: #6b7889;
    --speas-accent: #5eead4;
    --speas-accent-2: #93c5fd;
    --speas-accent-soft: rgba(94, 234, 212, 0.14);
    --speas-shadow: 0 18px 46px rgba(0, 0, 0, 0.22);
    --speas-shadow-sm: 0 8px 24px rgba(0, 0, 0, 0.16);
}

html[data-speas-theme="suave"] {
    --speas-bg: #f7f4f7;
    --speas-surface: #ffffff;
    --speas-surface-2: #fbf8fa;
    --speas-elevated: #ffffff;
    --speas-sidebar: #ffffff;
    --speas-sidebar-2: #fffafb;
    --speas-text: #251b24;
    --speas-muted: #746675;
    --speas-border: #eadde6;
    --speas-border-strong: #d7c3d0;
    --speas-accent: #b83267;
    --speas-accent-2: #0f766e;
    --speas-accent-soft: #fff0f6;
}

body.speas-app {
    background:
        linear-gradient(180deg, var(--speas-bg), color-mix(in srgb, var(--speas-bg) 82%, #ffffff));
    font-size: 13px;
}

body.speas-app .home {
    padding: 12px 16px 16px;
}

body.speas-app .header-text {
    min-height: var(--speas-topbar-h);
    padding: 0 10px 0 14px;
    border-radius: var(--speas-radius);
    border: 1px solid var(--speas-border);
    background: color-mix(in srgb, var(--speas-surface) 96%, transparent);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.07);
}

html[data-speas-theme="oscuro"] body.speas-app .header-text {
    background: color-mix(in srgb, var(--speas-surface) 92%, #000000);
}

body.speas-app #titulo-modulo,
body.speas-app .home .text {
    font-size: 17px;
    font-weight: 800;
}

body.speas-app .sidebar {
    background: linear-gradient(180deg, var(--speas-sidebar-2), var(--speas-sidebar));
    border-right: 1px solid var(--speas-border);
    box-shadow: 8px 0 30px rgba(15, 23, 42, 0.08);
}

html[data-speas-theme="oscuro"] body.speas-app .sidebar {
    background: linear-gradient(180deg, #222b36, #202832);
}

body.speas-app .sidebar li {
    height: 40px;
    margin-top: 3px;
    padding: 0 9px;
}

body.speas-app .sidebar li a {
    border-radius: 8px;
}

body.speas-app .sidebar li .icon {
    font-size: 18px;
}

body.speas-app .sidebar.close:not(:hover):not(.mobile-active) .menu {
    padding: 0 12px 20px !important;
    scrollbar-width: none !important;
}

body.speas-app .sidebar.close:not(:hover):not(.mobile-active) li {
    padding: 0 !important;
    justify-content: center !important;
}

body.speas-app .sidebar.close:not(:hover):not(.mobile-active) li a {
    width: 50px !important;
    min-width: 50px !important;
    max-width: 50px !important;
    margin: 0 auto !important;
    justify-content: center !important;
}

body.speas-app .sidebar.close:not(:hover):not(.mobile-active) li .icon {
    width: 50px !important;
    min-width: 0 !important;
    flex: 0 0 50px !important;
}

body.speas-app .sidebar.close:not(:hover):not(.mobile-active) .menu::-webkit-scrollbar {
    width: 0 !important;
    display: none !important;
}

body.speas-app .sidebar.close:not(:hover):not(.mobile-active) li .text {
    display: none !important;
}

body.speas-app .sidebar li .text {
    font-size: 12.8px;
    font-weight: 720;
}

body.speas-app .sidebar li a:hover,
body.speas-app .sidebar li.active a {
    background: linear-gradient(135deg, #0f172a, #1e293b);
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.16);
}

html[data-speas-theme="oscuro"] body.speas-app .sidebar li a:hover,
html[data-speas-theme="oscuro"] body.speas-app .sidebar li.active a {
    background: linear-gradient(135deg, #465363, #3b4654);
}

html[data-speas-theme="suave"] body.speas-app .sidebar li a:hover,
html[data-speas-theme="suave"] body.speas-app .sidebar li.active a {
    background: linear-gradient(135deg, #9f2859, #b83267);
}

.speas-logo-mark {
    background: linear-gradient(145deg, #0f172a, #172033);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.speas-logo-mark::after {
    background: #5eead4;
}

body.speas-app .profile-card {
    border-radius: 12px;
    background: var(--speas-surface);
    border: 1px solid var(--speas-border);
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.06);
}

html[data-speas-theme="oscuro"] body.speas-app .profile-card {
    background: color-mix(in srgb, var(--speas-surface) 80%, #000000);
}

.speas-top-search {
    width: min(360px, 30vw);
    height: 34px;
    border-radius: 8px;
    background: var(--speas-surface-2);
}

.speas-theme-switch {
    border-radius: 8px;
    background: var(--speas-surface);
}

.speas-theme-btn {
    border-radius: 6px;
}

body.speas-app .module-header,
body.speas-app .page-header,
body.speas-app .header-section,
body.speas-app .card,
body.speas-app .kpi-card,
body.speas-app .panel,
body.speas-app .table-container,
body.speas-app .filters-card,
body.speas-app .summary-card,
body.speas-app .analytics-container,
body.speas-app .facturas-container,
body.speas-app .inventory-container,
body.speas-app .crm-container,
body.speas-app .modal-content,
body.speas-app .modal-box,
body.speas-app .form-container,
body.speas-app .section-card {
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.07);
}

body.speas-app th {
    height: 34px;
    font-size: 11px;
}

body.speas-app td {
    padding: 7px 9px;
    font-size: 12.5px;
}

body.speas-app button,
body.speas-app .btn,
body.speas-app .btn-primary,
body.speas-app .btn-secondary,
body.speas-app .action-btn {
    min-height: 32px;
    border-radius: 7px;
}

body.speas-login .enterprise-layout {
    min-height: 100vh;
    background:
        linear-gradient(90deg, #f8fafc 0%, #eef2f6 52%, #ffffff 52%, #ffffff 100%);
}

body.speas-login .visual-panel {
    flex: 1.02;
    padding: clamp(38px, 5vw, 72px);
    background:
        linear-gradient(135deg, #f8fafc 0%, #eef4f8 100%);
    border-right: 1px solid #dce3ec;
}

body.speas-login .visual-overlay {
    opacity: 0.55;
    background-image:
        linear-gradient(90deg, rgba(15, 23, 42, 0.045) 1px, transparent 1px),
        linear-gradient(180deg, rgba(15, 23, 42, 0.045) 1px, transparent 1px);
    background-size: 40px 40px;
}

body.speas-login .dynamic-bg {
    background:
        linear-gradient(135deg, rgba(255,255,255,0.72), rgba(241,245,249,0.60)),
        linear-gradient(90deg, rgba(15,118,110,0.07), rgba(29,78,216,0.06));
}

body.speas-login .brand-logo {
    gap: 12px;
    font-size: 24px;
    font-weight: 850;
}

body.speas-login .brand-message {
    max-width: 680px;
}

body.speas-login .brand-message h2 {
    font-size: clamp(32px, 3.2vw, 50px);
    line-height: 1.04;
    max-width: 620px;
}

body.speas-login .brand-message p {
    max-width: 600px;
    color: #526071;
    font-size: 16px;
}

body.speas-login .login-signal-grid span {
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.82);
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
}

body.speas-login .system-status {
    border-radius: 10px;
}

body.speas-login .login-insights {
    width: min(640px, 88%);
    display: grid;
    gap: 14px;
    margin-top: 30px;
}

body.speas-login .insight-card {
    position: relative;
    min-height: 74px;
    padding: 16px;
    border: 1px solid rgba(203, 213, 225, 0.78);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.72);
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
    color: #0f172a;
    overflow: hidden;
}

body.speas-login .insight-card::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 3px;
    background: linear-gradient(90deg, #0f766e, #1d4ed8);
    opacity: 0.85;
}

body.speas-login .insight-main {
    min-height: 88px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background:
        linear-gradient(135deg, rgba(15, 23, 42, 0.95), rgba(30, 41, 59, 0.92));
    color: #ffffff;
}

body.speas-login .insight-main i {
    width: 46px;
    height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: rgba(94, 234, 212, 0.14);
    color: #5eead4;
    font-size: 26px;
    animation: speasPulseSoft 2.4s ease-in-out infinite;
}

body.speas-login .insight-label,
body.speas-login .insight-card span {
    display: block;
    color: #64748b;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

body.speas-login .insight-main .insight-label {
    color: rgba(255, 255, 255, 0.66);
}

body.speas-login .insight-card strong {
    display: block;
    margin-top: 6px;
    color: inherit;
    font-size: 17px;
    font-weight: 900;
}

body.speas-login .insight-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

body.speas-login .insight-grid .insight-card {
    min-height: 116px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

body.speas-login .insight-grid i {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: #e6f7f4;
    color: #0f766e;
    font-size: 22px;
}

body.speas-login .insight-flow {
    height: 74px;
    display: grid;
    grid-template-columns: 1.2fr 0.8fr 1fr;
    align-items: end;
    gap: 10px;
    padding: 14px;
    border: 1px solid rgba(203, 213, 225, 0.68);
    border-radius: 12px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0.28));
}

body.speas-login .insight-flow span {
    display: block;
    border-radius: 999px 999px 6px 6px;
    background: linear-gradient(180deg, rgba(94, 234, 212, 0.95), rgba(15, 118, 110, 0.72));
    box-shadow: 0 12px 24px rgba(15, 118, 110, 0.14);
    animation: speasBarRise 3s ease-in-out infinite;
}

body.speas-login .insight-flow span:nth-child(1) {
    height: 32px;
}

body.speas-login .insight-flow span:nth-child(2) {
    height: 46px;
    animation-delay: 0.25s;
}

body.speas-login .insight-flow span:nth-child(3) {
    height: 58px;
    animation-delay: 0.5s;
}

@keyframes speasPulseSoft {
    0%, 100% { transform: scale(1); opacity: 0.92; }
    50% { transform: scale(1.06); opacity: 1; }
}

@keyframes speasBarRise {
    0%, 100% { transform: scaleY(0.86); transform-origin: bottom; }
    50% { transform: scaleY(1); transform-origin: bottom; }
}

body.speas-login .login-panel {
    flex: 0.92;
    background: #ffffff;
}

body.speas-login .login-content {
    max-width: 392px;
    padding: 28px;
    border: 1px solid #dce3ec;
    border-radius: 14px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.10);
}

body.speas-login .login-header {
    margin-bottom: 24px;
    text-align: left;
}

body.speas-login .login-header h3 {
    font-size: 24px;
}

body.speas-login .input-box input {
    height: 42px;
    background: #f8fafc;
}

body.speas-login .btn-corporate {
    height: 42px;
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.14);
}

body.speas-login .security-notice {
    margin-top: 22px;
}

@media (min-width: 1600px) {
    body.speas-app .home {
        max-width: 1780px;
        margin: 0 auto;
        width: 100%;
    }

    body.speas-login .login-content {
        max-width: 420px;
    }
}

@media (max-width: 1100px) {
    body.speas-login .enterprise-layout {
        background: #ffffff;
    }

    body.speas-login .visual-panel {
        border-right: 0;
        border-bottom: 1px solid #dce3ec;
        padding: 28px 24px;
    }

    body.speas-login .login-panel {
        padding: 30px 20px;
    }

    body.speas-login .login-insights {
        display: none;
    }
}

/* Speas desktop login composition v10 */
@media (min-width: 1101px) {
    body.speas-login .visual-panel {
        padding: clamp(34px, 4vw, 64px) clamp(56px, 5vw, 90px);
    }

    body.speas-login .brand-container {
        max-width: 760px;
        min-height: 100%;
        display: grid;
        grid-template-rows: auto minmax(0, 1fr) auto;
        gap: clamp(22px, 3vh, 34px);
        justify-content: stretch;
    }

    body.speas-login .brand-logo {
        align-self: start;
        margin-bottom: 0;
    }

    body.speas-login .brand-message {
        align-self: center;
        max-width: 760px;
        display: grid;
        gap: 18px;
    }

    body.speas-login .brand-message h2 {
        max-width: 650px;
        font-size: clamp(44px, 4.2vw, 62px);
        line-height: 1.02;
        margin: 0;
    }

    body.speas-login .brand-message p {
        max-width: 640px;
        margin: 0;
        font-size: clamp(15px, 1vw, 18px);
    }

    body.speas-login .login-signal-grid {
        width: min(420px, 100%);
        margin-top: 4px;
    }

    body.speas-login .login-insights {
        width: min(620px, 100%);
        margin-top: 8px;
        gap: 12px;
    }

    body.speas-login .insight-main {
        min-height: 76px;
        padding: 14px 16px;
        border-radius: 11px;
    }

    body.speas-login .insight-main i {
        width: 42px;
        height: 42px;
        font-size: 24px;
    }

    body.speas-login .insight-grid {
        gap: 10px;
    }

    body.speas-login .insight-grid .insight-card {
        min-height: 104px;
        padding: 14px;
    }

    body.speas-login .insight-grid i {
        width: 34px;
        height: 34px;
        font-size: 20px;
    }

    body.speas-login .insight-card strong {
        font-size: 16px;
    }

    body.speas-login .insight-flow {
        height: 54px;
        padding: 10px 12px;
        border-radius: 11px;
    }

    body.speas-login .insight-flow span:nth-child(1) {
        height: 22px;
    }

    body.speas-login .insight-flow span:nth-child(2) {
        height: 32px;
    }

    body.speas-login .insight-flow span:nth-child(3) {
        height: 40px;
    }

    body.speas-login .system-status {
        align-self: end;
        width: min(500px, 100%);
        max-width: none;
        margin-top: 0;
        min-height: 56px;
        padding: 12px 16px;
        border-radius: 12px;
        box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
    }
}

@media (min-width: 1101px) and (max-height: 880px) {
    body.speas-login .visual-panel {
        padding-top: 30px;
        padding-bottom: 28px;
    }

    body.speas-login .brand-container {
        gap: 16px;
    }

    body.speas-login .brand-message {
        gap: 13px;
    }

    body.speas-login .brand-message h2 {
        font-size: clamp(40px, 3.6vw, 54px);
    }

    body.speas-login .login-insights {
        gap: 10px;
    }

    body.speas-login .insight-grid .insight-card {
        min-height: 92px;
    }

    body.speas-login .insight-flow {
        display: none;
    }
}

/* Speas wide login composition v11 */
@media (min-width: 1500px) {
    body.speas-login .visual-panel {
        padding: 42px clamp(56px, 5vw, 96px);
    }

    body.speas-login .brand-container {
        max-width: 880px;
        grid-template-columns: minmax(0, 1fr) minmax(310px, 0.82fr);
        grid-template-rows: auto minmax(0, 1fr) auto;
        grid-template-areas:
            "logo logo"
            "message insights"
            "status insights";
        column-gap: clamp(34px, 4vw, 60px);
        row-gap: 26px;
        align-items: center;
    }

    body.speas-login .brand-logo {
        grid-area: logo;
    }

    body.speas-login .brand-message {
        grid-area: message;
        align-self: center;
        gap: 20px;
    }

    body.speas-login .brand-message h2 {
        font-size: clamp(48px, 3.4vw, 64px);
        max-width: 560px;
    }

    body.speas-login .brand-message p {
        max-width: 560px;
    }

    body.speas-login .login-signal-grid {
        width: min(430px, 100%);
    }

    body.speas-login .login-insights {
        grid-area: insights;
        align-self: center;
        width: 100%;
        margin-top: 0;
        gap: 12px;
    }

    body.speas-login .insight-main {
        min-height: 82px;
    }

    body.speas-login .insight-grid {
        grid-template-columns: 1fr;
    }

    body.speas-login .insight-grid .insight-card {
        min-height: 78px;
        display: grid;
        grid-template-columns: auto 1fr;
        grid-template-rows: auto auto;
        column-gap: 12px;
        align-items: center;
        justify-content: start;
    }

    body.speas-login .insight-grid .insight-card i {
        grid-row: 1 / span 2;
    }

    body.speas-login .insight-grid .insight-card span,
    body.speas-login .insight-grid .insight-card strong {
        margin: 0;
    }

    body.speas-login .insight-flow {
        height: 66px;
    }

    body.speas-login .system-status {
        grid-area: status;
        align-self: end;
        width: min(500px, 100%);
    }
}

/* Speas dark modules compatibility v12 */
html[data-speas-theme="oscuro"] body.speas-app {
    --speas-dark-panel: #2f3a46;
    --speas-dark-panel-2: #354252;
    --speas-dark-panel-3: #25303b;
    --speas-dark-line: #53657a;
    --speas-dark-text: #f8fafc;
    --speas-dark-muted: #c6d1df;
}

html[data-speas-theme="oscuro"] body.speas-app .speas-top-search,
html[data-speas-theme="oscuro"] body.speas-app .speas-top-search input {
    background: #26313d !important;
    color: var(--speas-dark-text) !important;
    border-color: var(--speas-dark-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .speas-top-search input:-webkit-autofill,
html[data-speas-theme="oscuro"] body.speas-app input:-webkit-autofill,
html[data-speas-theme="oscuro"] body.speas-app textarea:-webkit-autofill,
html[data-speas-theme="oscuro"] body.speas-app select:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 1000px #26313d inset !important;
    -webkit-text-fill-color: var(--speas-dark-text) !important;
    caret-color: var(--speas-dark-text) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    .calendar-wrapper,
    .calendar-main-area,
    .calendar-sidebar,
    .pos-catalog,
    .cart-panel,
    .order-panel,
    .cart-sidebar,
    .scanner-card,
    .recent-card,
    .validation-card,
    .historial-card,
    .despacho-container,
    .despacho-panel,
    .terceros-container,
    .caja-container,
    .caja-chica-container,
    .modulo-container,
    .proveedores-container,
    .inventory-container,
    .inventario-container,
    .table-module-container,
    .table-responsive,
    .table-responsive-kardex,
    .table-container,
    .combo-list-container,
    .products-panel,
    .product-grid,
    .product-card,
    .summary-card,
    .kpi-card,
    .method-card-detail,
    .form-panel,
    .filters-panel,
    .filters-card,
    .panel-card,
    .section-card,
    .modal-content,
    .modal-content-custom,
    .modal-box,
    .simple-card,
    .data-card,
    .content-card
) {
    background: var(--speas-dark-panel) !important;
    color: var(--speas-dark-text) !important;
    border-color: var(--speas-dark-line) !important;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    .catalog-header,
    .catalog-title-bar,
    .header-acciones,
    .module-header,
    .section-header,
    .toolbar,
    .table-toolbar,
    .filters-toolbar,
    .pos-toolbar,
    .cart-header,
    .modal-header,
    .modal-footer,
    .pagination-container
) {
    background: transparent !important;
    color: var(--speas-dark-text) !important;
    border-color: var(--speas-dark-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    .calendar-sidebar,
    .cart-panel,
    .order-panel,
    .recent-card,
    .method-card-detail,
    .meta-pill,
    .period-tabs,
    .tabs-terceros,
    .category-tabs,
    .combo-results-list,
    .filter-bar,
    .search-panel,
    .detail-panel
) {
    background: var(--speas-dark-panel-2) !important;
    color: var(--speas-dark-text) !important;
    border-color: var(--speas-dark-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    h1, h2, h3, h4, h5,
    .catalog-title-bar h2,
    .header-titles h2,
    .desglose-title h3,
    .scanner-card h3,
    .modal-header h3,
    .table-custom td,
    .premium-table td,
    .simple-table td,
    .combo-table td,
    .fc-toolbar-title,
    .product-name,
    .product-card h3,
    .method-info h3,
    .summary-item strong,
    .kpi-card h3,
    .flow-card span
) {
    color: var(--speas-dark-text) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    p, small, label,
    .catalog-title-bar p,
    .header-titles p,
    .desglose-title small,
    .scanner-card p,
    .method-info span,
    .kpi-card span,
    .kpi-card small,
    .flow-card small,
    .empty-state-table,
    .pagination-container,
    .sidebar-section h4,
    .custom-checkbox,
    .fc-col-header-cell-cushion
) {
    color: var(--speas-dark-muted) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    input,
    select,
    textarea,
    .search-bar input,
    .search-box input,
    .select-sede-admin,
    .custom-select,
    .filter-select,
    .combo-option
) {
    background: var(--speas-dark-panel-3) !important;
    color: var(--speas-dark-text) !important;
    border-color: var(--speas-dark-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(input, textarea)::placeholder {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    table,
    .premium-table,
    .table-custom,
    .simple-table,
    .combo-table,
    .kardex-table
) {
    background: var(--speas-dark-panel) !important;
    color: var(--speas-dark-text) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    thead,
    thead tr,
    th,
    .premium-table th,
    .table-custom th,
    .simple-table th,
    .combo-table thead,
    .kardex-table th
) {
    background: #3b4858 !important;
    color: #eef4fb !important;
    border-color: var(--speas-dark-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    tbody tr,
    tbody td,
    .premium-table td,
    .table-custom td,
    .simple-table td,
    .combo-table td,
    .kardex-table td
) {
    background: var(--speas-dark-panel) !important;
    color: var(--speas-dark-text) !important;
    border-color: var(--speas-dark-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(tbody tr:hover, .premium-table tr:hover, .table-custom tr:hover, .simple-table tbody tr:hover, .combo-table tbody tr:hover) {
    background: #3a4655 !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    .fc,
    .fc-view-harness,
    .fc-scrollgrid,
    .fc-scrollgrid-section,
    .fc-daygrid-body,
    .fc-daygrid-day,
    .fc-col-header-cell
) {
    background: var(--speas-dark-panel) !important;
    border-color: var(--speas-dark-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(.fc-daygrid-day-number, .fc-event-title, .fc-event-time) {
    color: var(--speas-dark-text) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .fc-button {
    background: #344151 !important;
    border-color: #56667a !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .fc-button-active {
    background: #5eead4 !important;
    border-color: #5eead4 !important;
    color: #0f172a !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    .cat-btn,
    .tab-btn,
    .btn-outline,
    .btn-secondary,
    .btn-sm,
    .btn-cancel,
    .page-btn,
    .pagination-controls button,
    .filter-actions button,
    .action-btn,
    .btn-icon
) {
    background: #344151 !important;
    color: #f8fafc !important;
    border-color: #56667a !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(.cat-btn.active, .tab-btn.active, .btn-primary, .btn-success) {
    background: #5eead4 !important;
    color: #0f172a !important;
    border-color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    .product-card,
    .flow-card,
    .status,
    .badge,
    .badge-pago,
    .stock-badge,
    .role-badge,
    .category-badge,
    .estado-badge,
    .status-pill
) {
    border-color: rgba(191, 219, 254, 0.36) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(.badge, .status, .stock-badge, .category-badge, .role-badge, .estado-badge) {
    background: #dbeafe !important;
    color: #1e3a8a !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(.product-card img, .product-img, .product-image) {
    background: #e2e8f0 !important;
    border-color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(.toast, .mini-notif, .notification, .alert) {
    color: #0f172a;
}

html[data-speas-theme="oscuro"] body.speas-app [style*="background: white"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background:white"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background: #fff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background:#fff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background: #ffffff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background:#ffffff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color: white"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color:white"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color: #fff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color:#fff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color: #ffffff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color:#ffffff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background: #f8fafc"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background:#f8fafc"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color: #f8fafc"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color:#f8fafc"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background: #f1f5f9"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background:#f1f5f9"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color: #f1f5f9"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color:#f1f5f9"] {
    background: var(--speas-dark-panel-2) !important;
    color: var(--speas-dark-text) !important;
    border-color: var(--speas-dark-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app [style*="color: #fff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color:#fff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color: #ffffff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color:#ffffff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color: white"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color:white"] {
    color: var(--speas-dark-text) !important;
}

/* Speas dark module residue fixes v13 */
html[data-speas-theme="oscuro"] body.speas-app :is(
    .pos-ticket,
    .ticket-items,
    .ticket-header,
    .ticket-footer,
    .cart-item,
    .method-card .card-content,
    .history-card,
    .history-card li,
    .history-card li.success,
    .history-card li.error,
    .panel-acuerdos,
    .panel-carga,
    .lista-scrollable,
    .desglose-container,
    .desglose-grid,
    .method-card-detail,
    .kardex-filters,
    .form-grid,
    .form-section,
    .modal-body,
    .modal-footer
) {
    background: var(--speas-dark-panel) !important;
    color: var(--speas-dark-text) !important;
    border-color: var(--speas-dark-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    .pos-ticket .ticket-header,
    .pos-ticket .ticket-footer,
    .history-card .mini-pagination,
    .desglose-container .period-tabs,
    .method-card-detail,
    .cart-item,
    .combo-option,
    .kardex-filters
) {
    background: var(--speas-dark-panel-2) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    .ticket-header h3,
    .ticket-title,
    .ticket-subtitle,
    .cart-item *,
    .history-card h4,
    .history-card li,
    .panel-acuerdos *,
    .panel-carga *,
    .desglose-container *,
    .method-card-detail *,
    .kardex-filters *,
    .pos-ticket *
) {
    color: var(--speas-dark-text) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    .ticket-subtitle,
    .history-card .mini-pagination #txt-mini-page,
    .desglose-title small,
    .method-card-detail .method-info span
) {
    color: var(--speas-dark-muted) !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    .pos-ticket .total-amount,
    .pos-ticket .total-value,
    .ticket-footer strong,
    .desglose-container .amount,
    .method-card-detail .method-info h3
) {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    .method-card input:checked + .card-content,
    .method-card .card-content:hover,
    .cat-btn:hover,
    .tab-btn:hover
) {
    background: #405064 !important;
    color: #ffffff !important;
    border-color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app :is(
    .icon-bg-ticket,
    .ticket-icon,
    .payment-icon-container,
    .method-card-detail .icon-box
) {
    background: rgba(94, 234, 212, 0.13) !important;
    color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pos-ticket {
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.26) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .desglose-container {
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.20) !important;
}

/* Speas POS product cards dark contrast v14 */
html[data-speas-theme="oscuro"] body.speas-app .pos-catalog .product-card {
    background: #303b48 !important;
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pos-catalog .product-card .product-name {
    color: #ffffff !important;
    font-weight: 780 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pos-catalog .product-card .product-price {
    color: #f8fafc !important;
    text-shadow: 0 1px 0 rgba(0, 0, 0, 0.22);
}

html[data-speas-theme="oscuro"] body.speas-app .pos-catalog .product-card .product-category-chip,
html[data-speas-theme="oscuro"] body.speas-app .pos-catalog .product-card .product-footer-row span:first-child {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pos-catalog .product-card .badge-stock {
    background: #e5f0ff !important;
    color: #1e3a8a !important;
    border: 1px solid #bfdbfe !important;
}

/* Speas POS checkout dark contrast v15 */
html[data-speas-theme="oscuro"] body.speas-app .pos-ticket,
html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .ticket-header,
html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .ticket-items,
html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .ticket-footer {
    background: #303b48 !important;
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .ticket-header {
    border-bottom-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .ticket-footer {
    border-top-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .ticket-header h3,
html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .item-info h4,
html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .item-total,
html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .summary-row,
html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .summary-row.total,
html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .summary-row span,
html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .ticket-summary span {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .ticket-subtitle,
html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .item-info p,
html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .item-info small {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .cart-item {
    border-bottom-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .item-qty {
    background: #eef4ff !important;
    border: 2px solid #e6edf8 !important;
    box-shadow: 0 10px 24px rgba(2, 6, 23, 0.20);
}

html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .item-qty span {
    color: #172033 !important;
    min-width: 18px;
    text-align: center;
    font-weight: 900 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .qty-btn {
    background: #334155 !important;
    color: #ffffff !important;
    border: 1px solid #475569 !important;
    box-shadow: none !important;
    font-weight: 900 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pos-ticket .qty-btn:hover {
    background: #5eead4 !important;
    color: #0f172a !important;
    border-color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .modal-body,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .modal-footer {
    background: #303b48 !important;
    border-color: #5b6b80 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .modal-header h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro label,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .total-amount-display {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .assignment-section,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro #campos-factura,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro #opciones-joinnus,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro #opciones-tarjeta {
    background: #263241 !important;
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cobro select,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro input[type="text"],
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro input[type="number"] {
    background: #243140 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cobro select option {
    background: #243140 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .comprobante-btn,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .method-card .card-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .format-card .format-content {
    background: #263241 !important;
    border-color: #607187 !important;
    color: #dbeafe !important;
    box-shadow: 0 10px 24px rgba(2, 6, 23, 0.18) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .method-card .card-content i,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .format-card .format-content i,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .format-card .format-content span {
    color: #b9c7d8 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cobro input[type="radio"]:checked + .comprobante-btn,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .method-card input:checked + .card-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .format-card input[type="radio"]:checked + .format-content {
    background: #172033 !important;
    border-color: #5eead4 !important;
    color: #ffffff !important;
    box-shadow: 0 0 0 3px rgba(94, 234, 212, 0.16), 0 16px 30px rgba(2, 6, 23, 0.26) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .method-card input:checked + .card-content i,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .format-card input[type="radio"]:checked + .format-content i,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .format-card input[type="radio"]:checked + .format-content span {
    color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .format-card:hover .format-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-cobro .method-card:hover .card-content {
    background: #334155 !important;
    border-color: #7b8da4 !important;
}

/* Speas calendar reservation detail dark contrast v16 */
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal .modal-content {
    background: #303b48 !important;
    border: 1px solid #5b6b80 !important;
    color: #f8fafc !important;
    box-shadow: 0 24px 70px rgba(2, 6, 23, 0.55) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal .modal-content > div:nth-child(2) {
    background: #303b48 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal h4,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal strong,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal div {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal small,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal span,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal i {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal a {
    color: #38bdf8 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="background: #f8f9fa"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="background:#f8f9fa"] {
    background: #263241 !important;
    border: 1px solid #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="background: #fff3cd"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="background:#fff3cd"] {
    background: #263241 !important;
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="color: #856404"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="color:#856404"] {
    color: #fbbf24 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="color: #e74c3c"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="color:#e74c3c"] {
    color: #ff6b5f !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="color: #2ecc71"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="color:#2ecc71"] {
    color: #4ade80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="color: #25D366"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="color:#25D366"] {
    color: #4ade80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="color: #9b59b6"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal [style*="color:#9b59b6"] {
    color: #c084fc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal hr {
    border-top-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-cal button {
    background: rgba(15, 23, 42, 0.35) !important;
    color: #ffffff !important;
    border-radius: 10px !important;
}

/* Speas despacho web dark contrast v17 */
html[data-speas-theme="oscuro"] body.speas-app .despacho-container {
    background: #303b48 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-header,
html[data-speas-theme="oscuro"] body.speas-app .despacho-actions,
html[data-speas-theme="oscuro"] body.speas-app .despacho-container .table-responsive,
html[data-speas-theme="oscuro"] body.speas-app .despacho-container .paginacion-container > div {
    background: #263241 !important;
    border: 1px solid #53657a !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-title h2,
html[data-speas-theme="oscuro"] body.speas-app .despacho-table td,
html[data-speas-theme="oscuro"] body.speas-app .despacho-table td *,
html[data-speas-theme="oscuro"] body.speas-app .despacho-container .paginacion-container span {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-title p,
html[data-speas-theme="oscuro"] body.speas-app .despacho-table th,
html[data-speas-theme="oscuro"] body.speas-app .despacho-table td[colspan] {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-tabs {
    border-bottom-color: #6b7f97 !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-tabs::-webkit-scrollbar {
    width: 0 !important;
    height: 0 !important;
    display: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-tabs .tab-btn {
    background: #344151 !important;
    color: #f8fafc !important;
    border: 1px solid transparent !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-tabs .tab-btn:hover {
    background: #3b4a5d !important;
    border-color: #607187 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-tabs .tab-btn.active {
    background: #344151 !important;
    color: #ffffff !important;
    border-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-tabs .tab-btn.active::after {
    background-color: #a7c7ff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-container .search-box input {
    background: #1f2a36 !important;
    border-color: #5b6b80 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-container .search-box input::placeholder {
    color: #b9c7d8 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-container .search-box i {
    color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-table {
    background: #303b48 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-table thead {
    background: #3b4858 !important;
    border-bottom-color: #6b7f97 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-table td {
    border-bottom-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-table tbody tr:hover {
    background: #344151 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-container .btn-secondary {
    background: #344151 !important;
    color: #f8fafc !important;
    border-color: #607187 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-container .btn-secondary:hover {
    background: #3f4f62 !important;
    border-color: #7b8da4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-container .btn-excel {
    background: #344151 !important;
    color: #ffffff !important;
    border: 1px solid #607187 !important;
}

@media (max-width: 768px) {
    body.speas-login .visual-panel {
        min-height: 190px;
        padding: 28px 18px;
    }

    body.speas-login .brand-logo {
        font-size: 23px;
    }

    body.speas-login .login-panel {
        align-items: flex-start;
        padding: 30px 18px;
    }

    body.speas-login .login-content {
        max-width: none;
        padding: 26px 22px;
        border-radius: 14px;
    }

    body.speas-login .login-header {
        text-align: center;
    }

    body.speas-app .header-text {
        min-height: 50px;
        display: grid;
        grid-template-columns: auto minmax(0, 1fr) auto;
        align-items: center;
        gap: 10px;
        padding: 8px 10px;
    }

    body.speas-app .mobile-toggle {
        margin-right: 0;
    }

    body.speas-app .home .header-text > .text {
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        font-size: 18px;
        line-height: 1.2;
    }

    body.speas-app .speas-shell-actions {
        justify-self: end;
        min-width: max-content;
    }

    .speas-theme-switch {
        padding: 2px;
        flex: 0 0 auto;
    }
}

/* Speas dark/module compatibility v7 */
html[data-speas-theme="oscuro"] body.speas-app {
    --speas-module-panel: #303a46;
    --speas-module-panel-2: #28323d;
    --speas-module-line: #4f5d6e;
    --speas-module-text: #f3f6fa;
    --speas-module-muted: #bcc7d5;
    --speas-module-soft: #d9e2ee;
}

html[data-speas-theme="oscuro"] body.speas-app .contenedor-modulo,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container,
html[data-speas-theme="oscuro"] body.speas-app .module-container,
html[data-speas-theme="oscuro"] body.speas-app .module-card,
html[data-speas-theme="oscuro"] body.speas-app .card,
html[data-speas-theme="oscuro"] body.speas-app .panel,
html[data-speas-theme="oscuro"] body.speas-app .modal-content,
html[data-speas-theme="oscuro"] body.speas-app .table-responsive,
html[data-speas-theme="oscuro"] body.speas-app .premium-table,
html[data-speas-theme="oscuro"] body.speas-app .data-table {
    background: var(--speas-module-panel) !important;
    color: var(--speas-module-text) !important;
    border-color: var(--speas-module-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .module-header,
html[data-speas-theme="oscuro"] body.speas-app .modal-header,
html[data-speas-theme="oscuro"] body.speas-app .table-toolbar {
    border-color: var(--speas-module-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app h1,
html[data-speas-theme="oscuro"] body.speas-app h2,
html[data-speas-theme="oscuro"] body.speas-app h3,
html[data-speas-theme="oscuro"] body.speas-app h4,
html[data-speas-theme="oscuro"] body.speas-app .header-titles h2,
html[data-speas-theme="oscuro"] body.speas-app .section-title,
html[data-speas-theme="oscuro"] body.speas-app .title,
html[data-speas-theme="oscuro"] body.speas-app .premium-table td,
html[data-speas-theme="oscuro"] body.speas-app .premium-table td *,
html[data-speas-theme="oscuro"] body.speas-app .modal-content,
html[data-speas-theme="oscuro"] body.speas-app [style*="color:#333"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color: #333"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color:#1e293b"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color: #1e293b"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color:#0f172a"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color: #0f172a"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color:#334155"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color: #334155"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color:#475569"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color: #475569"] {
    color: var(--speas-module-text) !important;
}

html[data-speas-theme="oscuro"] body.speas-app p,
html[data-speas-theme="oscuro"] body.speas-app small,
html[data-speas-theme="oscuro"] body.speas-app label,
html[data-speas-theme="oscuro"] body.speas-app .header-titles p,
html[data-speas-theme="oscuro"] body.speas-app .subtitle,
html[data-speas-theme="oscuro"] body.speas-app .description,
html[data-speas-theme="oscuro"] body.speas-app .muted,
html[data-speas-theme="oscuro"] body.speas-app .premium-table th,
html[data-speas-theme="oscuro"] body.speas-app [style*="color:#666"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color: #666"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color:#64748b"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color: #64748b"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color:#94a3b8"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color: #94a3b8"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color:#aaa"],
html[data-speas-theme="oscuro"] body.speas-app [style*="color: #aaa"] {
    color: var(--speas-module-muted) !important;
}

html[data-speas-theme="oscuro"] body.speas-app input,
html[data-speas-theme="oscuro"] body.speas-app select,
html[data-speas-theme="oscuro"] body.speas-app textarea,
html[data-speas-theme="oscuro"] body.speas-app .search-box input,
html[data-speas-theme="oscuro"] body.speas-app .select-sede-admin,
html[data-speas-theme="oscuro"] body.speas-app [style*="background: white"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background:white"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color: white"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color:white"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background:#fff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background: #fff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background:#f8fafc"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background: #f8fafc"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background:#f1f5f9"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background: #f1f5f9"] {
    background: var(--speas-module-panel-2) !important;
    color: var(--speas-module-text) !important;
    border-color: var(--speas-module-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app input::placeholder,
html[data-speas-theme="oscuro"] body.speas-app textarea::placeholder {
    color: #98a7b9 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .premium-table th,
html[data-speas-theme="oscuro"] body.speas-app thead,
html[data-speas-theme="oscuro"] body.speas-app thead tr,
html[data-speas-theme="oscuro"] body.speas-app thead th {
    background: #3a4654 !important;
    color: #d9e2ee !important;
    border-color: var(--speas-module-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app tbody tr,
html[data-speas-theme="oscuro"] body.speas-app tbody td {
    background: var(--speas-module-panel) !important;
    border-color: var(--speas-module-line) !important;
}

html[data-speas-theme="oscuro"] body.speas-app tbody tr:hover,
html[data-speas-theme="oscuro"] body.speas-app .premium-table tr:hover {
    background: #364353 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .btn-secondary,
html[data-speas-theme="oscuro"] body.speas-app .btn-icon,
html[data-speas-theme="oscuro"] body.speas-app button:not(.speas-theme-btn):not(.btn-primary):not(.btn-danger) {
    background: #344151 !important;
    color: #eef4fb !important;
    border-color: #56667a !important;
}

html[data-speas-theme="oscuro"] body.speas-app .btn-secondary:hover,
html[data-speas-theme="oscuro"] body.speas-app .btn-icon:hover {
    background: #3d4b5c !important;
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .btn-secondary i,
html[data-speas-theme="oscuro"] body.speas-app .btn-icon i,
html[data-speas-theme="oscuro"] body.speas-app .search-box i {
    color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .badge,
html[data-speas-theme="oscuro"] body.speas-app .badge-pago,
html[data-speas-theme="oscuro"] body.speas-app [style*="background:#e0e7ff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background: #e0e7ff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color: #f3e8ff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color:#f3e8ff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color: #ecfeff"],
html[data-speas-theme="oscuro"] body.speas-app [style*="background-color:#ecfeff"] {
    background: #e7f0ff !important;
    color: #1f3a8a !important;
    border: 1px solid rgba(255, 255, 255, 0.4) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-responsive {
    scrollbar-color: #5eead4 #2a3440;
}

html[data-speas-theme="oscuro"] body.speas-app .table-responsive::-webkit-scrollbar {
    height: 10px;
}

html[data-speas-theme="oscuro"] body.speas-app .table-responsive::-webkit-scrollbar-track {
    background: #2a3440;
}

html[data-speas-theme="oscuro"] body.speas-app .table-responsive::-webkit-scrollbar-thumb {
    background: #5eead4;
    border-radius: 999px;
}

@media (max-width: 768px) {
    body.speas-app .contenedor-modulo {
        padding: 0;
    }

    body.speas-app .table-module-container {
        border-radius: 12px !important;
        padding: 10px !important;
    }

    body.speas-app .module-header {
        gap: 10px !important;
        margin-bottom: 14px !important;
    }

    body.speas-app .header-titles h2 {
        font-size: 20px !important;
        line-height: 1.18 !important;
    }

    body.speas-app .header-titles p {
        font-size: 13px !important;
    }

    body.speas-app .header-actions,
    body.speas-app .table-toolbar,
    body.speas-app .search-box,
    body.speas-app .filter-actions {
        width: 100% !important;
        max-width: none !important;
    }

    body.speas-app .header-actions,
    body.speas-app .filter-actions {
        display: grid !important;
        grid-template-columns: 1fr !important;
    }

    body.speas-app .table-responsive {
        position: relative;
        border-radius: 10px !important;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    body.speas-app .premium-table {
        min-width: 760px !important;
    }

    body.speas-app .premium-table th,
    body.speas-app .premium-table td {
        padding: 12px 10px !important;
        font-size: 12px !important;
        white-space: nowrap;
    }
}

html[data-speas-theme="oscuro"] body.speas-app .premium-table td [style*="background:#e0e7ff"],
html[data-speas-theme="oscuro"] body.speas-app .premium-table td [style*="background: #e0e7ff"],
html[data-speas-theme="oscuro"] body.speas-app .premium-table td [style*="background-color: #f3e8ff"],
html[data-speas-theme="oscuro"] body.speas-app .premium-table td [style*="background-color:#f3e8ff"],
html[data-speas-theme="oscuro"] body.speas-app .premium-table td [style*="background-color: #ecfeff"],
html[data-speas-theme="oscuro"] body.speas-app .premium-table td [style*="background-color:#ecfeff"],
html[data-speas-theme="oscuro"] body.speas-app .premium-table td .badge,
html[data-speas-theme="oscuro"] body.speas-app .premium-table td .badge-pago {
    background: #dbeafe !important;
    color: #1e3a8a !important;
    border-color: #bfdbfe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .premium-table td [style*="background:#e0e7ff"] *,
html[data-speas-theme="oscuro"] body.speas-app .premium-table td [style*="background: #e0e7ff"] *,
html[data-speas-theme="oscuro"] body.speas-app .premium-table td [style*="background-color: #f3e8ff"] *,
html[data-speas-theme="oscuro"] body.speas-app .premium-table td [style*="background-color:#f3e8ff"] *,
html[data-speas-theme="oscuro"] body.speas-app .premium-table td [style*="background-color: #ecfeff"] *,
html[data-speas-theme="oscuro"] body.speas-app .premium-table td [style*="background-color:#ecfeff"] *,
html[data-speas-theme="oscuro"] body.speas-app .premium-table td .badge *,
html[data-speas-theme="oscuro"] body.speas-app .premium-table td .badge-pago * {
    color: #1e3a8a !important;
}

/* Speas mobile login polish v8 */
@media (max-width: 768px) {
    body.speas-login {
        background:
            linear-gradient(180deg, #eef4f8 0%, #f8fafc 38%, #ffffff 100%) !important;
    }

    body.speas-login .enterprise-layout {
        min-height: 100svh;
        background:
            radial-gradient(circle at 18% 8%, rgba(94, 234, 212, 0.22), transparent 26%),
            radial-gradient(circle at 88% 12%, rgba(29, 78, 216, 0.12), transparent 24%),
            linear-gradient(180deg, #eef4f8 0%, #ffffff 56%) !important;
    }

    body.speas-login .visual-panel {
        min-height: 255px;
        padding: 24px 18px 78px;
        border-bottom: 0;
        background:
            linear-gradient(135deg, rgba(255, 255, 255, 0.78), rgba(239, 246, 255, 0.72)),
            linear-gradient(90deg, rgba(15, 118, 110, 0.08), rgba(29, 78, 216, 0.08)) !important;
        overflow: hidden;
    }

    body.speas-login .visual-panel::before {
        content: "";
        position: absolute;
        inset: 12px 14px auto;
        height: 190px;
        display: block;
        border: 1px solid rgba(148, 163, 184, 0.22);
        border-radius: 22px;
        background:
            linear-gradient(90deg, rgba(15, 23, 42, 0.035) 1px, transparent 1px),
            linear-gradient(180deg, rgba(15, 23, 42, 0.035) 1px, transparent 1px);
        background-size: 28px 28px;
        mask-image: linear-gradient(180deg, #000 0%, transparent 100%);
        pointer-events: none;
        z-index: 1;
    }

    body.speas-login .visual-panel::after {
        content: "";
        position: absolute;
        left: 50%;
        bottom: 24px;
        width: 72%;
        height: 1px;
        display: block;
        transform: translateX(-50%);
        background: linear-gradient(90deg, transparent, rgba(15, 118, 110, 0.40), transparent);
        z-index: 2;
    }

    body.speas-login .brand-container {
        position: relative;
        z-index: 3;
        gap: 14px;
        justify-content: flex-start;
        padding-top: 6px;
    }

    body.speas-login .brand-logo {
        width: 100%;
        justify-content: center;
        gap: 10px;
        margin-bottom: 0;
        color: #0f172a;
        text-shadow: none;
    }

    body.speas-login .brand-logo .speas-logo-mark {
        width: 48px;
        height: 48px;
        border-radius: 13px;
        box-shadow: 0 18px 36px rgba(15, 23, 42, 0.18);
    }

    body.speas-login .brand-logo span:last-child {
        font-size: 25px;
        font-weight: 900;
        color: #0f172a;
        opacity: 1;
    }

    body.speas-login .brand-message {
        display: block !important;
        max-width: 330px;
        margin: 0 auto;
        text-align: center;
    }

    body.speas-login .brand-message h2 {
        margin: 8px 0 8px;
        font-size: 22px;
        line-height: 1.08;
        letter-spacing: 0;
        color: #0f172a;
    }

    body.speas-login .brand-message p {
        display: none;
    }

    body.speas-login .login-signal-grid {
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
        margin-top: 14px;
    }

    body.speas-login .login-signal-grid span {
        min-height: 30px;
        padding: 0 8px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-radius: 999px;
        border: 1px solid rgba(15, 118, 110, 0.16);
        background: rgba(255, 255, 255, 0.82);
        color: #334155;
        font-size: 11px;
        font-weight: 800;
        box-shadow: 0 10px 24px rgba(15, 23, 42, 0.07);
    }

    body.speas-login .system-status {
        display: flex !important;
        width: min(310px, calc(100vw - 48px));
        min-height: 46px;
        margin: 14px auto 0;
        padding: 9px 12px;
        border: 1px solid rgba(15, 118, 110, 0.16);
        border-left: 3px solid #10b981;
        border-radius: 12px;
        background: rgba(255, 255, 255, 0.82);
        box-shadow: 0 14px 30px rgba(15, 23, 42, 0.08);
    }

    body.speas-login .status-indicator {
        color: #0f172a;
        font-size: 12px;
    }

    body.speas-login .server-info p {
        color: #64748b;
    }

    body.speas-login .login-panel {
        margin-top: -58px;
        padding: 0 18px 34px;
        align-items: flex-start;
        background: transparent !important;
        position: relative;
        z-index: 4;
    }

    body.speas-login .login-content {
        max-width: none;
        padding: 24px 22px 22px;
        border-radius: 18px;
        border: 1px solid rgba(203, 213, 225, 0.88);
        background:
            linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(255, 255, 255, 0.94));
        box-shadow: 0 24px 60px rgba(15, 23, 42, 0.15);
    }

    body.speas-login .login-header {
        margin-bottom: 20px;
        text-align: center;
    }

    body.speas-login .login-header h3 {
        font-size: 27px;
        line-height: 1.1;
    }

    body.speas-login .login-header p {
        max-width: 280px;
        margin: 8px auto 0;
        font-size: 14.5px;
        line-height: 1.45;
    }

    body.speas-login .form-group {
        margin-bottom: 16px;
    }

    body.speas-login .form-group label {
        font-size: 11px;
        letter-spacing: 0.08em;
    }

    body.speas-login .input-box input {
        height: 48px;
        border-radius: 10px;
        font-size: 14px;
        background: #f8fafc;
        border-color: #d9e2ec;
        box-shadow: inset 0 1px 0 rgba(15, 23, 42, 0.03);
    }

    body.speas-login .input-box i {
        color: #718096;
    }

    body.speas-login .btn-corporate {
        height: 50px;
        margin-top: 20px;
        border-radius: 10px;
        font-size: 14.5px;
        background: linear-gradient(135deg, #0f172a, #111827);
        box-shadow: 0 16px 32px rgba(15, 23, 42, 0.22);
    }

    body.speas-login .security-notice {
        margin-top: 20px;
        padding: 14px;
        border-radius: 14px;
        background: #f8fafc;
    }

    body.speas-login .security-notice i {
        width: 34px;
        height: 34px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-radius: 10px;
        background: #e6f7f4;
        color: #0f766e;
    }

    body.speas-login .login-footer {
        margin-top: 22px;
    }
}

html[data-speas-theme="oscuro"] body.speas-app .kpi-icon-wrapper,
html[data-speas-theme="oscuro"] body.speas-app .shortcut-item i,
html[data-speas-theme="oscuro"] body.speas-app .shortcut-card i,
html[data-speas-theme="oscuro"] body.speas-app .quick-action-card i,
html[data-speas-theme="oscuro"] body.speas-app .empty-state-widget i,
html[data-speas-theme="oscuro"] body.speas-app .date-widget i,
html[data-speas-theme="oscuro"] body.speas-app .speas-status-stack i,
html[data-speas-theme="oscuro"] body.speas-app .status-icon,
html[data-speas-theme="oscuro"] body.speas-app .module-icon {
    background: rgba(94, 234, 212, 0.12) !important;
    color: #5eead4 !important;
    border-color: rgba(94, 234, 212, 0.18) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .kpi-icon-wrapper i,
html[data-speas-theme="oscuro"] body.speas-app .shortcut-item i,
html[data-speas-theme="oscuro"] body.speas-app .shortcut-card i,
html[data-speas-theme="oscuro"] body.speas-app .quick-action-card i,
html[data-speas-theme="oscuro"] body.speas-app .empty-state-widget i {
    color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .kpi-content span,
html[data-speas-theme="oscuro"] body.speas-app .kpi-content small,
html[data-speas-theme="oscuro"] body.speas-app .kpi-card-modern span,
html[data-speas-theme="oscuro"] body.speas-app .kpi-card-modern small {
    color: #b9c7d8 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .kpi-content strong,
html[data-speas-theme="oscuro"] body.speas-app .kpi-card-modern strong {
    color: #f8fafc !important;
}

@media (max-width: 768px) {
    body.speas-app .sidebar.mobile-active,
    body.speas-app .sidebar.mobile-active.close {
        width: min(82vw, 300px) !important;
        padding: 14px 10px !important;
        background: linear-gradient(180deg, #202936, #1c2530) !important;
        border-right: 1px solid rgba(148, 163, 184, 0.20);
        box-shadow: 18px 0 50px rgba(2, 6, 23, 0.38) !important;
    }

    body.speas-app .sidebar.mobile-active header {
        min-height: 54px;
        padding: 0 6px 12px;
        border-bottom: 1px solid rgba(148, 163, 184, 0.14);
    }

    body.speas-app .sidebar.mobile-active .image-text {
        gap: 10px;
    }

    body.speas-app .sidebar.mobile-active .speas-logo-mark {
        width: 38px;
        height: 38px;
        border-radius: 10px;
        box-shadow: 0 12px 28px rgba(20, 184, 166, 0.20);
    }

    body.speas-app .sidebar.mobile-active .logo-text .name {
        color: #f8fafc !important;
        font-size: 18px;
        font-weight: 850;
    }

    body.speas-app .sidebar.mobile-active .logo-text .profession {
        color: #9fb0c4 !important;
        font-size: 11px;
        letter-spacing: 0.01em;
    }

    body.speas-app .sidebar.mobile-active .menu-links {
        padding: 10px 0 0 !important;
    }

    body.speas-app .sidebar.mobile-active li {
        height: auto;
        margin: 4px 0;
    }

    body.speas-app .sidebar.mobile-active li a {
        min-height: 42px;
        padding: 0 12px !important;
        border-radius: 8px;
        gap: 12px;
        color: #dbe4ef;
    }

    body.speas-app .sidebar.mobile-active li .icon {
        width: 34px !important;
        min-width: 34px !important;
        height: 34px;
        color: #b9c7d8 !important;
        font-size: 19px;
    }

    body.speas-app .sidebar.mobile-active li .text {
        color: #dbe4ef !important;
        font-size: 13.5px;
        font-weight: 720;
    }

    body.speas-app .sidebar.mobile-active li a:hover,
    body.speas-app .sidebar.mobile-active li.active a {
        background: linear-gradient(135deg, rgba(94, 234, 212, 0.20), rgba(148, 163, 184, 0.12)) !important;
        border: 1px solid rgba(94, 234, 212, 0.22);
        box-shadow: inset 3px 0 0 #5eead4;
    }

    body.speas-app .sidebar.mobile-active li a:hover .icon,
    body.speas-app .sidebar.mobile-active li.active .icon,
    body.speas-app .sidebar.mobile-active li a:hover .text,
    body.speas-app .sidebar.mobile-active li.active .text {
        color: #f8fafc !important;
    }

    body.speas-app .sidebar.mobile-active .bottom-content {
        border-top: 1px solid rgba(148, 163, 184, 0.14);
        padding-top: 10px;
    }

    body.speas-app .sidebar.mobile-active .profile-card {
        margin: 0 0 8px !important;
        padding: 10px !important;
        border-radius: 10px;
        background: rgba(255, 255, 255, 0.07) !important;
        border: 1px solid rgba(148, 163, 184, 0.16) !important;
    }

    body.speas-app .sidebar.mobile-active .profile-info .name {
        color: #f8fafc !important;
        font-weight: 780;
    }

    body.speas-app .sidebar.mobile-active .profile-info .role {
        color: #9fb0c4 !important;
    }

    body.speas-app .sidebar.mobile-active .logout-box {
        margin: 0 !important;
    }

    body.speas-app .sidebar.mobile-active .logout-box a {
        min-height: 40px;
        padding: 0 12px !important;
        border-radius: 8px;
    }
}

/* Speas terceros dark contrast v18 */
html[data-speas-theme="oscuro"] body.speas-app .custom-confirm-overlay .confirm-box,
html[data-speas-theme="oscuro"] body.speas-app .custom-alert-overlay .alert-box {
    background: #303b48 !important;
    border: 1px solid #5b6b80 !important;
    color: #f8fafc !important;
    box-shadow: 0 24px 70px rgba(2, 6, 23, 0.55) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .custom-confirm-overlay .confirm-title,
html[data-speas-theme="oscuro"] body.speas-app .custom-alert-overlay .alert-title {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .custom-confirm-overlay .confirm-desc,
html[data-speas-theme="oscuro"] body.speas-app .custom-alert-overlay .alert-desc {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .custom-confirm-overlay .confirm-icon,
html[data-speas-theme="oscuro"] body.speas-app .custom-confirm-overlay .confirm-icon i {
    color: #f59e0b !important;
}

html[data-speas-theme="oscuro"] body.speas-app .custom-confirm-overlay .btn-confirm-no,
html[data-speas-theme="oscuro"] body.speas-app .custom-alert-overlay .btn-alert-ok {
    background: #344151 !important;
    color: #f8fafc !important;
    border: 1px solid #607187 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .custom-confirm-overlay .btn-confirm-no:hover,
html[data-speas-theme="oscuro"] body.speas-app .custom-alert-overlay .btn-alert-ok:hover {
    background: #3f4f62 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .custom-confirm-overlay .btn-confirm-yes {
    background: #344151 !important;
    color: #ffffff !important;
    border: 1px solid #607187 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .custom-confirm-overlay .btn-confirm-yes:hover {
    background: #475569 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .terceros-container .result-box.error {
    background: #4a1f28 !important;
    border-color: #fb7185 !important;
    color: #ffe4e6 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .terceros-container .result-box.error .result-title,
html[data-speas-theme="oscuro"] body.speas-app .terceros-container .result-box.error .result-title i {
    color: #fecdd3 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .terceros-container .result-box.error p {
    color: #fecdd3 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .terceros-container .result-box.success {
    background: #163a2b !important;
    border-color: #34d399 !important;
    color: #dcfce7 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .terceros-container .result-box.success .result-title,
html[data-speas-theme="oscuro"] body.speas-app .terceros-container .result-box.success p {
    color: #dcfce7 !important;
}

/* Speas historial modal positioning and mail polish v19 */
body.speas-app #modal-detalle-venta.modal-overlay,
body.speas-app #modal-envio-correo.modal-overlay,
body.speas-app #modal-envio-whatsapp.modal-overlay {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    height: 100dvh !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 24px !important;
    z-index: 10020 !important;
}

body.speas-app #modal-detalle-venta.modal-overlay.active,
body.speas-app #modal-envio-correo.modal-overlay.active,
body.speas-app #modal-envio-whatsapp.modal-overlay.active {
    display: flex !important;
}

body.speas-app #modal-detalle-venta .modal-content,
body.speas-app #modal-envio-correo .modal-content,
body.speas-app #modal-envio-whatsapp .modal-content {
    margin: 0 !important;
    transform: none !important;
    width: min(92vw, 560px) !important;
    max-height: min(82dvh, 720px) !important;
    border-radius: 14px !important;
}

body.speas-app #modal-envio-correo .modal-content {
    max-width: 460px !important;
    padding: 0 !important;
    overflow: hidden !important;
}

body.speas-app #modal-envio-correo .modal-header {
    margin: 0 !important;
    padding: 20px 22px !important;
    border-bottom: 1px solid #dbe3ee !important;
}

body.speas-app #modal-envio-correo .modal-header h3 {
    color: #172033 !important;
    font-size: 18px !important;
    font-weight: 850 !important;
}

body.speas-app #modal-envio-correo .modal-header h3 i {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: #e6f7f4;
    color: #0f766e;
}

body.speas-app #modal-envio-correo .modal-body {
    padding: 22px !important;
}

body.speas-app #modal-envio-correo .modal-body p {
    margin: 0 0 12px !important;
    color: #64748b !important;
    font-weight: 650;
}

body.speas-app #modal-envio-correo .modal-body > div[style*="position: relative"] {
    margin-bottom: 22px !important;
}

body.speas-app #modal-envio-correo .modal-body input[type="email"] {
    min-height: 48px !important;
    border-radius: 10px !important;
    border: 1px solid #cbd5e1 !important;
    background: #f8fafc !important;
    color: #172033 !important;
    font-size: 15px !important;
}

body.speas-app #modal-envio-correo .modal-body input[type="email"]:focus {
    border-color: #14b8a6 !important;
    box-shadow: 0 0 0 4px rgba(20, 184, 166, 0.14) !important;
}

body.speas-app #modal-envio-correo .modal-body .btn-secondary,
body.speas-app #modal-envio-correo .modal-body .btn-primary {
    min-height: 42px;
    border-radius: 10px !important;
    padding: 0 18px !important;
    font-weight: 800 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-venta .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-envio-correo .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-envio-whatsapp .modal-content {
    background: #303b48 !important;
    border: 1px solid #5b6b80 !important;
    color: #f8fafc !important;
    box-shadow: 0 24px 70px rgba(2, 6, 23, 0.55) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-envio-correo .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-envio-whatsapp .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-venta .modal-header {
    background: #303b48 !important;
    border-bottom-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-envio-correo .modal-header h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-venta .modal-header h3 {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-envio-correo .modal-body p {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-envio-correo .modal-body input[type="email"] {
    background: #243140 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-envio-correo .modal-body input[type="email"]::placeholder {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-envio-correo .modal-body .btn-secondary {
    background: #344151 !important;
    color: #f8fafc !important;
    border-color: #607187 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-venta #detalle-venta-body table {
    background: #303b48 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-venta #detalle-venta-body thead,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-venta #detalle-venta-body th {
    background: #3b4858 !important;
    color: #f8fafc !important;
    border-bottom-color: #6b7f97 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-venta #detalle-venta-body td {
    color: #f8fafc !important;
    border-bottom-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalle-venta #detalle-venta-body td:nth-child(3) {
    color: #ffffff !important;
}

@media (max-width: 640px) {
    body.speas-app #modal-detalle-venta.modal-overlay,
    body.speas-app #modal-envio-correo.modal-overlay,
    body.speas-app #modal-envio-whatsapp.modal-overlay {
        padding: 14px !important;
    }

    body.speas-app #modal-envio-correo .modal-body > div:last-child {
        flex-direction: column !important;
    }

    body.speas-app #modal-envio-correo .modal-body .btn-secondary,
    body.speas-app #modal-envio-correo .modal-body .btn-primary {
        width: 100%;
        justify-content: center;
    }
}

/* Speas flujo de caja dark contrast v20 */
html[data-speas-theme="oscuro"] body.speas-app .caja-container .module-header,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .kpi-card,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .desglose-container,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .table-module-container {
    background: #303b48 !important;
    border-color: #5b6b80 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .kpi-card {
    border-top-color: #5b6b80 !important;
    border-right-color: #5b6b80 !important;
    border-bottom-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .header-titles h2,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .desglose-title h3,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .amount-big,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .method-card-detail .method-info h3,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td strong {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .header-titles p,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .kpi-card span,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .desglose-title small,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .method-card-detail .method-info span,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table th,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td small,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td div[style*="color:#666"],
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td div[style*="color: #666"],
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td small[style*="color:#666"],
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td small[style*="color: #666"] {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .period-tabs {
    background: #344151 !important;
    border: 1px solid #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .period-tabs .tab-btn {
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .period-tabs .tab-btn.active {
    background: #5eead4 !important;
    color: #0f172a !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .method-card-detail {
    background: #303b48 !important;
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .method-card-detail .icon-box,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .kpi-icon {
    background: rgba(94, 234, 212, 0.14) !important;
    color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .desglose-title i {
    background: #2d5960 !important;
    color: #9ff7ea !important;
    border: 1px solid rgba(94, 234, 212, 0.24) !important;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.22) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table thead,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table th {
    background: #3b4858 !important;
    border-bottom-color: #6b7f97 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td {
    border-bottom-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table tbody tr:hover {
    background: #344151 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .badge-soft-success,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .badge-ingreso {
    background: #dbeafe !important;
    color: #1e3a8a !important;
    border: 1px solid #bfdbfe !important;
    font-weight: 900 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .badge-soft-danger,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .badge-egreso {
    background: #fee2e2 !important;
    color: #991b1b !important;
    border: 1px solid #fecaca !important;
    font-weight: 900 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td span[style*="background:#f3f4f6"],
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td span[style*="background: #f3f4f6"],
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td span[style*="background:#e0e7ff"],
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td span[style*="background: #e0e7ff"] {
    background: #e8eef8 !important;
    color: #1e3a8a !important;
    border-color: #bfdbfe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td small[style*="color:#6366f1"],
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td small[style*="color: #6366f1"] {
    color: #f8fafc !important;
    font-weight: 800 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td span[style*="color:#a855f7"],
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td span[style*="color: #a855f7"] {
    color: #d8b4fe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td span[style*="color:#0ea5e9"],
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td span[style*="color: #0ea5e9"] {
    color: #7dd3fc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td[style*="color:#16a34a"],
html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table td[style*="color: #16a34a"] {
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .pagination-wrapper {
    background: #344151 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .pagination-wrapper span,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .pagination-wrapper button {
    color: #f8fafc !important;
}

/* Speas caja chica dark contrast and modal polish v22 */
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .module-header,
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .table-container {
    background: #303b48 !important;
    border-color: #5b6b80 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .module-header h2,
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .table-container h3,
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table td,
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table td div,
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table td strong {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .module-header p,
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .btn-action small,
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table th,
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table td div[style*="color:#9ca3af"],
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table td div[style*="color: #9ca3af"] {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .select-sede-admin,
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .btn-small {
    background: #263240 !important;
    border-color: #5b6b80 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .saldo-card {
    background: linear-gradient(135deg, #245c68 0%, #334b9a 100%) !important;
    border: 1px solid rgba(148, 163, 184, 0.32) !important;
    box-shadow: 0 22px 55px rgba(15, 23, 42, 0.36) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .saldo-icon {
    background: rgba(248, 250, 252, 0.14) !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .btn-action {
    background: #303b48 !important;
    border-color: #5b6b80 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .btn-action:hover {
    background: #344151 !important;
    border-color: #7dd3fc !important;
    box-shadow: 0 18px 38px rgba(15, 23, 42, 0.26) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .btn-action.ingreso .icon-circle {
    background: rgba(34, 197, 94, 0.16) !important;
    color: #86efac !important;
    border: 1px solid rgba(134, 239, 172, 0.25) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .btn-action.gasto .icon-circle {
    background: rgba(248, 113, 113, 0.16) !important;
    color: #fca5a5 !important;
    border: 1px solid rgba(252, 165, 165, 0.26) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table thead,
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table th {
    background: #3b4858 !important;
    border-bottom-color: #6b7f97 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table td {
    border-bottom-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table tbody tr:hover {
    background: #344151 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table .badge,
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table td span[style*="background:#f3f4f6"],
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table td span[style*="background: #f3f4f6"] {
    background: #e8eef8 !important;
    color: #12346b !important;
    border: 1px solid #c7d7ee !important;
    font-weight: 900 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table td[style*="color:#16a34a"],
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table td[style*="color: #16a34a"] {
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table td[style*="color:#dc2626"],
html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container .premium-table td[style*="color: #dc2626"] {
    color: #fecaca !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica.modal-overlay {
    align-items: center !important;
    justify-content: center !important;
    padding: 22px !important;
    background: rgba(8, 13, 22, 0.72) !important;
    backdrop-filter: blur(10px) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .modal-content.center-modal {
    display: block !important;
    text-align: left !important;
    width: min(94vw, 520px) !important;
    max-width: 520px !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: hidden !important;
    border-radius: 20px !important;
    background: #303b48 !important;
    border: 1px solid #607187 !important;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.36) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .modal-header {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 16px !important;
    margin: 0 !important;
    padding: 22px 24px !important;
    border-bottom: 1px solid #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .modal-header h3 {
    color: #f8fafc !important;
    font-size: 20px !important;
    line-height: 1.25 !important;
    margin: 0 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .btn-close {
    flex: 0 0 auto !important;
    width: 42px !important;
    height: 42px !important;
    border-radius: 12px !important;
    background: #344151 !important;
    color: #e2e8f0 !important;
    border: 1px solid #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .btn-close:hover {
    background: #3b4858 !important;
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .modal-body {
    padding: 24px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica #form-chica {
    display: grid !important;
    gap: 18px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica #tipo-badge-container {
    margin: 0 !important;
    text-align: left !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .badge-lg {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: auto !important;
    max-width: 100% !important;
    min-height: 42px !important;
    padding: 10px 16px !important;
    border-radius: 999px !important;
    font-size: 12px !important;
    letter-spacing: 0.08em !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .badge-ingreso {
    background: rgba(34, 197, 94, 0.16) !important;
    color: #86efac !important;
    border: 1px solid rgba(134, 239, 172, 0.38) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .badge-gasto {
    background: rgba(248, 113, 113, 0.16) !important;
    color: #fca5a5 !important;
    border: 1px solid rgba(252, 165, 165, 0.38) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .input-group {
    margin: 0 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .input-group label {
    color: #cbd5e1 !important;
    font-size: 12px !important;
    letter-spacing: 0.06em !important;
    margin-bottom: 8px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .input-group input,
html[data-speas-theme="oscuro"] body.speas-app #modal-chica .input-group select,
html[data-speas-theme="oscuro"] body.speas-app #modal-chica .input-group textarea {
    min-height: 50px !important;
    background: #263240 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
    border-radius: 14px !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .input-group input::placeholder,
html[data-speas-theme="oscuro"] body.speas-app #modal-chica .input-group textarea::placeholder {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .input-group input:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-chica .input-group select:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-chica .input-group textarea:focus {
    border-color: #5eead4 !important;
    box-shadow: 0 0 0 4px rgba(94, 234, 212, 0.16) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica #chica-monto {
    color: #f8fafc !important;
    font-size: 22px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .modal-footer {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 12px !important;
    margin-top: 6px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .btn-cancel,
html[data-speas-theme="oscuro"] body.speas-app #modal-chica .btn-primary {
    box-sizing: border-box !important;
    height: 54px !important;
    min-height: 54px !important;
    padding: 0 22px !important;
    margin: 0 !important;
    border-radius: 14px !important;
    font-size: 14px !important;
    font-weight: 800 !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .btn-cancel {
    flex: 0 0 145px !important;
    background: #344151 !important;
    color: #e2e8f0 !important;
    border: 1px solid #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .btn-primary {
    flex: 1 1 auto !important;
    background: linear-gradient(135deg, #5eead4 0%, #2dd4bf 100%) !important;
    color: #082f34 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-chica .btn-primary:disabled {
    opacity: 0.72 !important;
    cursor: wait !important;
}

@media (max-width: 640px) {
    html[data-speas-theme="oscuro"] body.speas-app #modal-chica .modal-footer {
        flex-direction: column-reverse !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-chica .btn-cancel,
    html[data-speas-theme="oscuro"] body.speas-app #modal-chica .btn-primary {
        width: 100% !important;
        flex: 0 0 auto !important;
    }
}

/* Speas inventario dark contrast and modal polish v23 */
html[data-speas-theme="oscuro"] body.speas-app .table-module-container {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .module-header,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .table-toolbar,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .table-responsive {
    background: #303b48 !important;
    border-color: #5b6b80 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .module-header h2,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .product-info h4,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .premium-table td,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .premium-table td h4 {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .module-header p,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .product-info .prod-code,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .premium-table th,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .page-info {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .tabs-container {
    border-bottom-color: #6b7f97 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .tab-btn {
    background: #344151 !important;
    border: 1px solid #3f5064 !important;
    color: #e2e8f0 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .tab-btn.active,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .tab-btn:hover {
    background: #3d4b66 !important;
    border-color: #5eead4 !important;
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .search-box input,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .date-filter,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container #filtro-sede-global,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container #filtro-categoria {
    background: #263240 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .search-box input::placeholder {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .search-box i,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .btn-icon i {
    color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .btn-icon,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .page-controls button,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .btn-action {
    background: #344151 !important;
    border: 1px solid #53657a !important;
    color: #e2e8f0 !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .premium-table thead,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .premium-table th {
    background: #3b4858 !important;
    border-bottom-color: #6b7f97 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .premium-table td {
    border-bottom-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .premium-table tbody tr:hover {
    background: #344151 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .badge-cat,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .badge-type {
    background: #e8eef8 !important;
    color: #12346b !important;
    border: 1px solid #c7d7ee !important;
    font-weight: 900 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container .product-icon-table {
    background: rgba(248, 250, 252, 0.10) !important;
    color: #f8fafc !important;
    border: 1px solid rgba(148, 163, 184, 0.25) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container td span[style*="color:#16a34a"],
html[data-speas-theme="oscuro"] body.speas-app .table-module-container td span[style*="color: #16a34a"] {
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container td span[style*="color:#d97706"],
html[data-speas-theme="oscuro"] body.speas-app .table-module-container td span[style*="color: #d97706"],
html[data-speas-theme="oscuro"] body.speas-app .table-module-container .texto-alerta-bajo {
    color: #fde68a !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container td span[style*="background-color: #fee2e2"],
html[data-speas-theme="oscuro"] body.speas-app .table-module-container td span[style*="background:#fee2e2"] {
    background: rgba(248, 113, 113, 0.16) !important;
    color: #fecaca !important;
    border-color: rgba(252, 165, 165, 0.42) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #stock-toast-container .stock-toast {
    background: #f8fafc !important;
    border-left-color: #ef4444 !important;
    border: 1px solid #fecaca !important;
    border-left-width: 5px !important;
    color: #0f172a !important;
    box-shadow: 0 18px 40px rgba(8, 13, 22, 0.28) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #stock-toast-container .stock-toast-content h4 {
    color: #991b1b !important;
}

html[data-speas-theme="oscuro"] body.speas-app #stock-toast-container .stock-toast-content p {
    color: #475569 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto.modal-overlay,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock.modal-overlay,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex.modal-overlay {
    background: rgba(8, 13, 22, 0.72) !important;
    backdrop-filter: blur(10px) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-content {
    background: #303b48 !important;
    border: 1px solid #607187 !important;
    color: #f8fafc !important;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.38) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-content.slide-in-right {
    width: min(620px, 92vw) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-footer,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .modal-footer,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-footer {
    background: #303b48 !important;
    border-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-header h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .modal-header h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-header h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-producto .form-subtitle,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .form-subtitle {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .form-subtitle,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .form-subtitle {
    border-bottom-color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .btn-close,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .btn-close,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .btn-close {
    width: 42px !important;
    height: 42px !important;
    border-radius: 12px !important;
    background: #344151 !important;
    color: #e2e8f0 !important;
    border: 1px solid #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .input-group,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .input-group {
    margin-bottom: 20px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .input-group input,
html[data-speas-theme="oscuro"] body.speas-app #modal-producto .input-group select,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .input-group input,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .input-group select,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .input-group textarea,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .date-filter {
    background: #263240 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .input-group input:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-producto .input-group select:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .input-group input:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .input-group select:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .input-group textarea:focus {
    border-color: #5eead4 !important;
    box-shadow: 0 0 0 4px rgba(94, 234, 212, 0.16) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .input-group label,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .input-group label {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .input-group input:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-producto .input-group input:not(:placeholder-shown) ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-producto .input-group select:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-producto .input-group select:valid ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-producto .input-group label.static,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .input-group input:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .input-group input:not(:placeholder-shown) ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .input-group select:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .input-group select:valid ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .input-group label.static {
    background: #303b48 !important;
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto #group-sede {
    background: rgba(59, 130, 246, 0.14) !important;
    border: 1px solid rgba(147, 197, 253, 0.32) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto #group-sede label {
    background: #303b48 !important;
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto #seccion-combo {
    background: #263240 !important;
    border-color: #607187 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-footer,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .modal-footer {
    align-items: center !important;
    gap: 12px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .btn-cancel,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .btn-cancel,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .btn-cancel {
    height: 48px !important;
    min-height: 48px !important;
    padding: 0 22px !important;
    background: #344151 !important;
    border: 1px solid #53657a !important;
    color: #e2e8f0 !important;
    border-radius: 12px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .btn-primary,
html[data-speas-theme="oscuro"] body.speas-app #modal-stock .btn-primary,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .btn-primary {
    height: 48px !important;
    min-height: 48px !important;
    padding: 0 24px !important;
    margin: 0 !important;
    border-radius: 12px !important;
    background: linear-gradient(135deg, #5eead4 0%, #2dd4bf 100%) !important;
    color: #082f34 !important;
    box-shadow: none !important;
    justify-content: center !important;
}

@media (max-width: 720px) {
    html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-content.slide-in-right {
        width: 100vw !important;
        max-width: 100vw !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-producto .row-grid {
        grid-template-columns: 1fr !important;
        gap: 0 !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-footer {
        flex-direction: column-reverse !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-producto .btn-cancel,
    html[data-speas-theme="oscuro"] body.speas-app #modal-producto .btn-primary {
        width: 100% !important;
    }
}

/* Speas proveedores dark responsive polish v24 */
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .module-header,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .table-toolbar,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .table-responsive {
    background: #303b48 !important;
    border-color: #5b6b80 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .module-header h2,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .premium-table td,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .premium-table td[style*="color:var(--text-color-main)"],
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .premium-table td[style*="color: var(--text-color-main)"],
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .client-contact span {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .module-header p,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .premium-table th,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .page-info,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .client-contact span[style*="font-size:11px"] {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .search-box input {
    background: #263240 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .search-box input::placeholder {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .search-box i,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .btn-icon i {
    color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .btn-icon,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .page-controls button,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .btn-action {
    background: #344151 !important;
    border: 1px solid #53657a !important;
    color: #e2e8f0 !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .premium-table thead,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .premium-table th {
    background: #3b4858 !important;
    border-bottom-color: #6b7f97 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .premium-table td {
    border-bottom-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .premium-table tbody tr:hover {
    background: #344151 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .status-badge,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .premium-table td span[style*="background:#f0f4ff"],
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .premium-table td span[style*="background: #f0f4ff"] {
    background: rgba(94, 234, 212, 0.14) !important;
    color: #ccfbf1 !important;
    border: 1px solid rgba(94, 234, 212, 0.32) !important;
    font-weight: 900 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .status-active {
    background: rgba(34, 197, 94, 0.16) !important;
    color: #86efac !important;
    border-color: rgba(134, 239, 172, 0.35) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container .status-inactive {
    background: rgba(248, 113, 113, 0.16) !important;
    color: #fecaca !important;
    border-color: rgba(252, 165, 165, 0.35) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor.modal-overlay,
html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b.modal-overlay,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-proveedor.modal-overlay,
html[data-speas-theme="oscuro"] body.speas-app #modal-copiar-datos.modal-overlay {
    background: rgba(8, 13, 22, 0.72) !important;
    backdrop-filter: blur(10px) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-proveedor .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-copiar-datos .modal-content {
    background: #303b48 !important;
    border: 1px solid #607187 !important;
    color: #f8fafc !important;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.38) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-footer {
    background: #303b48 !important;
    border-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-header h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .form-subtitle,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor h4,
html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-proveedor h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-copiar-datos h3 {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .form-subtitle,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor h4[style*="border-bottom"] {
    border-bottom-color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .btn-close {
    width: 42px !important;
    height: 42px !important;
    border-radius: 12px !important;
    background: #344151 !important;
    color: #e2e8f0 !important;
    border: 1px solid #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group input,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group select,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table input,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table select,
html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b input,
html[data-speas-theme="oscuro"] body.speas-app #copy-modal-content {
    background: #263240 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group input::placeholder,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table input::placeholder,
html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b input::placeholder {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group input:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group select:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table input:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table select:focus {
    border-color: #5eead4 !important;
    box-shadow: 0 0 0 4px rgba(94, 234, 212, 0.16) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group label {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group input:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group input:not(:placeholder-shown) ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group select:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group select:valid ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group label.static {
    background: #303b48 !important;
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table {
    background: #303b48 !important;
    border-color: #607187 !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table tr,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table td {
    background: #303b48 !important;
    border-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table button,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor button[onclick*="agregar"] {
    background: #344151 !important;
    color: #e2e8f0 !important;
    border: 1px solid #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table button[onclick*="eliminarFilaERP"] {
    background: rgba(248, 113, 113, 0.16) !important;
    color: #fecaca !important;
    border-color: rgba(252, 165, 165, 0.35) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-footer .btn-cancel,
html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b .btn-cancel,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-proveedor .btn-cancel,
html[data-speas-theme="oscuro"] body.speas-app #modal-copiar-datos .btn-cancel {
    height: 48px !important;
    min-height: 48px !important;
    padding: 0 22px !important;
    background: #344151 !important;
    border: 1px solid #53657a !important;
    color: #e2e8f0 !important;
    border-radius: 12px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-footer .btn-primary,
html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b .btn-primary,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-proveedor .btn-primary,
html[data-speas-theme="oscuro"] body.speas-app #modal-copiar-datos .btn-primary {
    height: 48px !important;
    min-height: 48px !important;
    padding: 0 24px !important;
    margin: 0 !important;
    border-radius: 12px !important;
    background: linear-gradient(135deg, #5eead4 0%, #2dd4bf 100%) !important;
    color: #082f34 !important;
    box-shadow: none !important;
    justify-content: center !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b p,
html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b label,
html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b small,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-proveedor p,
html[data-speas-theme="oscuro"] body.speas-app #modal-copiar-datos p {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-copiar-datos .modal-content div:has(#copy-modal-content) {
    background: #263240 !important;
    border-color: #607187 !important;
}

@media (max-width: 768px) {
    body.speas-app #module-content .table-module-container {
        gap: 14px !important;
    }

    body.speas-app #module-content .table-module-container .module-header {
        padding: 16px !important;
        border-radius: 14px !important;
        align-items: stretch !important;
    }

    body.speas-app #module-content .table-module-container .module-header h2 {
        font-size: 22px !important;
        line-height: 1.15 !important;
    }

    body.speas-app #module-content .table-module-container .module-header p {
        font-size: 14px !important;
        line-height: 1.35 !important;
    }

    body.speas-app #module-content .table-module-container .module-header > div:last-child {
        width: 100% !important;
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 10px !important;
    }

    body.speas-app #module-content .table-module-container .module-header .btn-secondary,
    body.speas-app #module-content .table-module-container .module-header .btn-primary {
        width: 100% !important;
        min-height: 48px !important;
        justify-content: center !important;
        padding: 0 12px !important;
        white-space: normal !important;
        text-align: center !important;
    }

    body.speas-app #module-content .table-module-container .table-toolbar {
        padding: 16px !important;
        border-radius: 14px !important;
        align-items: stretch !important;
    }

    body.speas-app #module-content .table-module-container .filter-actions {
        justify-content: flex-start !important;
    }

    body.speas-app #module-content .table-module-container .table-responsive {
        border-radius: 14px !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
    }

    body.speas-app #module-content .table-module-container .premium-table {
        min-width: 760px !important;
    }

    body.speas-app #module-content .table-module-container .premium-table th,
    body.speas-app #module-content .table-module-container .premium-table td {
        padding: 14px 16px !important;
        white-space: nowrap !important;
    }

    body.speas-app #module-content .table-module-container .pagination {
        justify-content: space-between !important;
        padding: 12px 4px !important;
    }

    body.speas-app #modal-proveedor.modal-overlay {
        align-items: stretch !important;
        justify-content: flex-end !important;
    }

    body.speas-app #modal-proveedor .modal-content {
        width: 100vw !important;
        max-width: 100vw !important;
        height: 100vh !important;
        max-height: 100vh !important;
    }

    body.speas-app #modal-proveedor .modal-header {
        padding: 18px 20px !important;
    }

    body.speas-app #modal-proveedor .modal-body {
        padding: 18px 20px 26px !important;
    }

    body.speas-app #modal-proveedor .row-grid {
        grid-template-columns: 1fr !important;
        gap: 0 !important;
    }

    body.speas-app #modal-proveedor .premium-table tr {
        display: grid !important;
        grid-template-columns: 1fr 44px !important;
        gap: 10px !important;
        padding: 14px !important;
    }

    body.speas-app #modal-proveedor .premium-table td {
        display: block !important;
        padding: 0 !important;
    }

    body.speas-app #modal-proveedor .premium-table td:not(:last-child) {
        grid-column: 1 / 2 !important;
    }

    body.speas-app #modal-proveedor .premium-table td:last-child {
        position: static !important;
        grid-column: 2 / 3 !important;
        grid-row: 1 / span 4 !important;
        align-self: start !important;
    }

    body.speas-app #modal-proveedor .premium-table input,
    body.speas-app #modal-proveedor .premium-table select {
        min-height: 46px !important;
        border: 1px solid #607187 !important;
        border-radius: 12px !important;
        padding: 0 14px !important;
    }

    body.speas-app #modal-proveedor .modal-footer {
        padding: 14px 20px !important;
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 10px !important;
    }

    body.speas-app #modal-proveedor .modal-footer .btn-cancel,
    body.speas-app #modal-proveedor .modal-footer .btn-primary {
        width: 100% !important;
    }
}

@media (max-width: 768px) {
    body.speas-app .table-module-container:has(#tabla-proveedores-body) .table-responsive > .premium-table {
        min-width: 720px !important;
        width: 100% !important;
        border-collapse: collapse !important;
        border-spacing: 0 !important;
    }

    body.speas-app .table-module-container:has(#tabla-proveedores-body) .table-responsive > .premium-table thead {
        display: table-header-group !important;
    }

    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body tr {
        display: table-row !important;
        padding: 0 !important;
        border: 0 !important;
        border-radius: 0 !important;
        background: #303b48 !important;
    }

    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td {
        display: table-cell !important;
        grid-template-columns: none !important;
        align-items: center !important;
        gap: 10px !important;
        padding: 13px 14px !important;
        border-bottom: 1px solid #53657a !important;
        white-space: nowrap !important;
        min-width: 0 !important;
    }

    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td:nth-child(3) .status-badge {
        justify-self: auto !important;
        min-width: 86px !important;
        max-width: 100% !important;
        text-align: center !important;
        background: rgba(94, 234, 212, 0.14) !important;
        color: #ccfbf1 !important;
        border: 1px solid rgba(94, 234, 212, 0.32) !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td:nth-child(5) {
        grid-template-columns: none !important;
        justify-content: initial !important;
        text-align: center !important;
    }

    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td:nth-child(5) small {
        margin-left: 4px !important;
        color: #cbd5e1 !important;
        font-size: 11px !important;
    }

    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td::before {
        color: #9fb0c4 !important;
        font-size: 11px !important;
        font-weight: 900 !important;
        letter-spacing: 0.06em !important;
        text-transform: uppercase !important;
    }

    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td:nth-child(1)::before,
    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td:nth-child(2)::before,
    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td:nth-child(3)::before,
    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td:nth-child(4)::before,
    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td:nth-child(5)::before,
    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td:nth-child(6)::before,
    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td:nth-child(7)::before {
        content: none !important;
        display: none !important;
    }

    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td::after,
    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body tr::before,
    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body tr::after {
        content: none !important;
        display: none !important;
    }

    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body .action-buttons {
        justify-content: flex-start !important;
        flex-wrap: wrap !important;
    }

    body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body .client-contact {
        display: grid !important;
        gap: 4px !important;
        min-width: 0 !important;
    }
}

/* Speas ordenes compra dark responsive polish v27 */
html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) {
    background: #303b48 !important;
    border-color: #5b6b80 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .header-acciones h2,
html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .table-custom td,
html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .table-custom td strong {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .table-responsive {
    background: #303b48 !important;
    border-color: #53657a !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .table-custom thead,
html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .table-custom th {
    background: #3b4858 !important;
    border-bottom-color: #6b7f97 !important;
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .table-custom td {
    border-bottom-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .table-custom tr:hover {
    background: #344151 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .form-control,
html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) #filtro-sede-oc {
    background: #263240 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .btn-excel {
    background: #344151 !important;
    border: 1px solid #53657a !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .btn-primary {
    background: linear-gradient(135deg, #5eead4 0%, #2dd4bf 100%) !important;
    color: #082f34 !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .page-info {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .pagination {
    border-top-color: #607187 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .page-controls button {
    background: #344151 !important;
    border-color: #53657a !important;
    color: #e2e8f0 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .status-badge {
    background: rgba(94, 234, 212, 0.14) !important;
    color: #ccfbf1 !important;
    border: 1px solid rgba(94, 234, 212, 0.32) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc.modal-overlay,
html[data-speas-theme="oscuro"] body.speas-app #modal-anular-oc.modal-overlay {
    background: rgba(8, 13, 22, 0.72) !important;
    backdrop-filter: blur(10px) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-anular-oc .modal-content {
    background: #303b48 !important;
    border: 1px solid #607187 !important;
    color: #f8fafc !important;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.38) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-anular-oc .modal-header {
    background: #303b48 !important;
    border-bottom-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .modal-header h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-anular-oc h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-anular-oc strong {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .modal-header i,
html[data-speas-theme="oscuro"] body.speas-app #modal-anular-oc .modal-header i {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group label {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group input,
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group select,
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group textarea,
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc #oc-sede-destino,
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc #oc-codigo {
    background: #263240 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group input::placeholder,
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group textarea::placeholder {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group input:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group select:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group textarea:focus {
    border-color: #5eead4 !important;
    box-shadow: 0 0 0 4px rgba(94, 234, 212, 0.16) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group div[style*="display: flex"][style*="border"] {
    background: #263240 !important;
    border-color: #607187 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group div[style*="display: flex"][style*="border"] span {
    background: #e8eef8 !important;
    color: #12346b !important;
    border-right-color: #607187 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group[style*="background: #eff6ff"],
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group[style*="background:#eff6ff"] {
    background: rgba(94, 234, 212, 0.12) !important;
    border-color: rgba(94, 234, 212, 0.36) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group[style*="background: #eff6ff"] p,
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .input-group[style*="background:#eff6ff"] p,
html[data-speas-theme="oscuro"] body.speas-app #modal-anular-oc p {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .btn-outline,
html[data-speas-theme="oscuro"] body.speas-app #modal-anular-oc button:first-of-type {
    background: #344151 !important;
    border-color: #53657a !important;
    color: #e2e8f0 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .btn-primary {
    background: linear-gradient(135deg, #5eead4 0%, #2dd4bf 100%) !important;
    color: #082f34 !important;
    box-shadow: none !important;
}

@media (max-width: 768px) {
    body.speas-app .modulo-container:has(#tabla-oc-interna) {
        padding: 14px !important;
        border-radius: 14px !important;
        overflow: hidden !important;
    }

    body.speas-app .modulo-container:has(#tabla-oc-interna) .header-acciones {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 14px !important;
        align-items: stretch !important;
    }

    body.speas-app .modulo-container:has(#tabla-oc-interna) .header-acciones h2 {
        font-size: 21px !important;
        line-height: 1.18 !important;
        min-width: 0 !important;
        overflow-wrap: anywhere !important;
    }

    body.speas-app .modulo-container:has(#tabla-oc-interna) .header-acciones > div {
        width: 100% !important;
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 10px !important;
        align-items: stretch !important;
    }

    body.speas-app .modulo-container:has(#tabla-oc-interna) #filtro-sede-oc {
        grid-column: 1 / -1 !important;
        width: 100% !important;
        min-height: 48px !important;
    }

    body.speas-app .modulo-container:has(#tabla-oc-interna) .btn-excel,
    body.speas-app .modulo-container:has(#tabla-oc-interna) .btn-primary {
        width: 100% !important;
        min-width: 0 !important;
        min-height: 52px !important;
        padding: 0 10px !important;
        justify-content: center !important;
        white-space: normal !important;
        text-align: center !important;
        line-height: 1.15 !important;
        overflow: hidden !important;
    }

    body.speas-app .modulo-container:has(#tabla-oc-interna) .table-responsive {
        width: 100% !important;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
    }

    body.speas-app .modulo-container:has(#tabla-oc-interna) .table-custom {
        min-width: 780px !important;
    }

    body.speas-app .modulo-container:has(#tabla-oc-interna) .pagination {
        align-items: center !important;
        gap: 12px !important;
    }

    body.speas-app #modal-crear-oc .modal-content {
        width: min(94vw, 560px) !important;
        max-height: 92vh !important;
    }

    body.speas-app #modal-crear-oc .modal-header {
        padding: 18px 20px !important;
    }

    body.speas-app #modal-crear-oc .modal-body {
        padding: 18px 20px !important;
    }

    body.speas-app #modal-crear-oc .form-grid {
        grid-template-columns: 1fr !important;
        gap: 18px !important;
    }

    body.speas-app #modal-crear-oc .input-group,
    body.speas-app #modal-crear-oc .input-group[style*="grid-column"] {
        grid-column: auto !important;
    }

    body.speas-app #modal-crear-oc .input-group input,
    body.speas-app #modal-crear-oc .input-group select,
    body.speas-app #modal-crear-oc .input-group textarea {
        min-height: 52px !important;
        font-size: 15px !important;
    }
}

/* Speas ordenes compra mobile modal viewport fix v28 */
@media (max-width: 768px) {
    body.speas-app #modal-crear-oc.modal-overlay:not(.hidden) {
        align-items: flex-start !important;
        justify-content: center !important;
        padding: 14px 12px calc(16px + env(safe-area-inset-bottom, 0px)) !important;
        overflow-y: auto !important;
    }

    body.speas-app #modal-crear-oc .modal-content {
        width: min(94vw, 560px) !important;
        max-height: calc(100dvh - 30px) !important;
        margin: 0 auto !important;
        border-radius: 16px !important;
        overflow: hidden !important;
    }

    body.speas-app #modal-crear-oc .modal-header {
        flex: 0 0 auto !important;
        min-height: 58px !important;
        padding: 14px 18px !important;
        gap: 10px !important;
    }

    body.speas-app #modal-crear-oc .modal-header h3 {
        display: flex !important;
        align-items: center !important;
        gap: 8px !important;
        min-width: 0 !important;
        margin: 0 !important;
        font-size: 16px !important;
        line-height: 1.25 !important;
        overflow: visible !important;
    }

    body.speas-app #modal-crear-oc .modal-header > i {
        flex: 0 0 auto !important;
        width: 38px !important;
        height: 38px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        border-radius: 12px !important;
        background: #344151 !important;
        border: 1px solid #53657a !important;
    }

    body.speas-app #modal-crear-oc .modal-body {
        flex: 1 1 auto !important;
        min-height: 0 !important;
        overflow-y: auto !important;
        padding-top: 18px !important;
    }
}

/* Speas ordenes compra mobile full viewport modal fix v29 */
@media (max-width: 768px) {
    body.speas-modal-open {
        overflow: hidden !important;
        touch-action: none !important;
    }

    body.speas-app #modal-crear-oc.modal-overlay {
        position: fixed !important;
        inset: 0 !important;
        width: 100vw !important;
        height: 100dvh !important;
        max-height: 100dvh !important;
        z-index: 9999 !important;
        box-sizing: border-box !important;
        background: rgba(8, 13, 22, 0.78) !important;
        backdrop-filter: blur(8px) !important;
        overflow: hidden !important;
    }

    body.speas-app #modal-crear-oc.modal-overlay:not(.hidden) {
        display: flex !important;
        align-items: stretch !important;
        justify-content: center !important;
        padding: 10px 12px 12px !important;
    }

    body.speas-app #modal-crear-oc .modal-content {
        width: min(94vw, 560px) !important;
        height: calc(100dvh - 22px) !important;
        max-height: calc(100dvh - 22px) !important;
        min-height: 0 !important;
        margin: 0 auto !important;
        display: flex !important;
        flex-direction: column !important;
        overflow: hidden !important;
        border-radius: 16px !important;
    }

    body.speas-app #modal-crear-oc .modal-header {
        position: relative !important;
        flex: 0 0 auto !important;
        min-height: 64px !important;
        padding: 14px 16px !important;
        background: #2e3a48 !important;
        border-bottom: 1px solid #526276 !important;
    }

    body.speas-app #modal-crear-oc .modal-header h3 {
        flex: 1 1 auto !important;
        font-size: clamp(15px, 4vw, 18px) !important;
        white-space: normal !important;
        word-break: normal !important;
    }

    body.speas-app #modal-crear-oc .modal-header > i:last-child {
        flex: 0 0 44px !important;
        width: 44px !important;
        height: 44px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        border-radius: 14px !important;
        background: #344151 !important;
        border: 1px solid #53657a !important;
        font-size: 24px !important;
    }

    body.speas-app #modal-crear-oc .modal-body {
        flex: 1 1 auto !important;
        min-height: 0 !important;
        height: auto !important;
        max-height: none !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch !important;
        overscroll-behavior: contain !important;
        padding: 18px 16px max(22px, env(safe-area-inset-bottom, 0px)) !important;
        background: #2e3a48 !important;
    }

    body.speas-app #modal-crear-oc .form-actions {
        position: static !important;
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 10px !important;
        margin: 18px 0 0 !important;
        padding: 0 0 max(10px, env(safe-area-inset-bottom, 0px)) !important;
        background: transparent !important;
        border-top: 0 !important;
    }

    body.speas-app #modal-crear-oc .form-actions .btn-outline,
    body.speas-app #modal-crear-oc .form-actions .btn-primary {
        width: 100% !important;
        min-height: 48px !important;
    }
}

/* Speas ordenes compra mobile form scroll refinement v30 */
@media (max-width: 768px) {
    body.speas-app #modal-crear-oc .modal-body {
        padding-bottom: max(22px, env(safe-area-inset-bottom, 0px)) !important;
    }

    body.speas-app #modal-crear-oc .form-actions {
        position: static !important;
        margin-top: 20px !important;
    }
}

/* Speas facturas dark responsive polish v31 */
html[data-speas-theme="oscuro"] body.speas-app .table-module-container {
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .module-header-tabs,
html[data-speas-theme="oscuro"] body.speas-app .table-toolbar,
html[data-speas-theme="oscuro"] body.speas-app .kpi-card,
html[data-speas-theme="oscuro"] body.speas-app .facturas-container {
    background: #2e3a48 !important;
    border: 1px solid #526276 !important;
    box-shadow: 0 18px 42px rgba(4, 9, 16, 0.18) !important;
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .module-header-tabs h2,
html[data-speas-theme="oscuro"] body.speas-app .module-header-tabs h3,
html[data-speas-theme="oscuro"] body.speas-app .header-titles h2,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container h2,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container h3,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container h4 {
    color: #ffffff !important;
    text-shadow: 0 1px 0 rgba(0, 0, 0, 0.08) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .module-header-tabs p,
html[data-speas-theme="oscuro"] body.speas-app .header-titles p,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container p,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container small,
html[data-speas-theme="oscuro"] body.speas-app .kpi-card span {
    color: #cbd6e3 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .tabs-wrapper {
    background: #344151 !important;
    border: 1px solid #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app .tab-btn {
    color: #d7e0ea !important;
    background: transparent !important;
}

html[data-speas-theme="oscuro"] body.speas-app .tab-btn:hover,
html[data-speas-theme="oscuro"] body.speas-app .tab-btn.active {
    background: #405064 !important;
    color: #ffffff !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-responsive {
    background: #2e3a48 !important;
    border-color: #526276 !important;
    box-shadow: 0 12px 30px rgba(4, 9, 16, 0.14) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .premium-table {
    background: #2e3a48 !important;
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .premium-table thead,
html[data-speas-theme="oscuro"] body.speas-app .premium-table th {
    background: #3a4859 !important;
    color: #e9f1fa !important;
    border-color: #607086 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .premium-table td {
    color: #f7fbff !important;
    border-color: #526276 !important;
    background: transparent !important;
}

html[data-speas-theme="oscuro"] body.speas-app .premium-table tr:hover {
    background: #344151 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .column-filter,
html[data-speas-theme="oscuro"] body.speas-app .search-box input,
html[data-speas-theme="oscuro"] body.speas-app .date-filter {
    background: #253140 !important;
    border-color: #607086 !important;
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .column-filter::placeholder,
html[data-speas-theme="oscuro"] body.speas-app .search-box input::placeholder {
    color: #aebbc9 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .btn-icon,
html[data-speas-theme="oscuro"] body.speas-app .btn-secondary,
html[data-speas-theme="oscuro"] body.speas-app .btn-small-text {
    background: #344151 !important;
    border-color: #607086 !important;
    color: #eaf2fb !important;
}

html[data-speas-theme="oscuro"] body.speas-app .btn-icon i {
    color: #55dfd0 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pagination-container {
    background: #2e3a48 !important;
    border-color: #526276 !important;
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pagination-container span {
    color: #cbd6e3 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .pagination-container button {
    background: #344151 !important;
    border-color: #607086 !important;
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura.modal-overlay,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver.modal-overlay,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago.modal-overlay,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-eliminar-doc.modal-overlay,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-flujo.modal-overlay {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    height: 100dvh !important;
    background: rgba(8, 13, 22, 0.78) !important;
    backdrop-filter: blur(9px) !important;
    overflow: hidden !important;
    z-index: 9998 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura.modal-overlay.active,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver.modal-overlay.active,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago.modal-overlay.active,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-eliminar-doc.modal-overlay.active,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-flujo.modal-overlay.active {
    display: flex !important;
    opacity: 1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-eliminar-doc .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-flujo .modal-content {
    background: #2e3a48 !important;
    border: 1px solid #526276 !important;
    color: #f7fbff !important;
    box-shadow: 0 28px 70px rgba(4, 9, 16, 0.46) !important;
    justify-content: flex-start !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-footer,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .modal-footer,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .modal-footer {
    background: #2e3a48 !important;
    border-color: #526276 !important;
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-header h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .modal-header h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .modal-header h3 {
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-body,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .modal-body,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .modal-body {
    background: #2e3a48 !important;
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .btn-close,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .btn-close,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .btn-close {
    background: #344151 !important;
    border: 1px solid #53657a !important;
    color: #f7fbff !important;
    border-radius: 14px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .form-subtitle,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .form-subtitle,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .form-subtitle {
    color: #f7fbff !important;
    border-color: #eaf2fb !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group input,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group select,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group textarea,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .input-group input,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .input-group select,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .input-group textarea {
    background: #253140 !important;
    border: 1px solid #607086 !important;
    color: #ffffff !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group input::placeholder,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group textarea::placeholder,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .input-group input::placeholder,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .input-group textarea::placeholder {
    color: #aebbc9 !important;
    opacity: 1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group label,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .input-group label {
    color: #cad5e1 !important;
    background: transparent !important;
    text-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group input:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group input:not(:placeholder-shown) ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group select:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group select:valid ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group label.static,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .input-group input:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .input-group input:not(:placeholder-shown) ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .input-group select:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .input-group select:valid ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .input-group label.static {
    top: -9px !important;
    left: 12px !important;
    display: inline-flex !important;
    align-items: center !important;
    max-width: calc(100% - 24px) !important;
    height: auto !important;
    min-height: 18px !important;
    padding: 2px 7px !important;
    border-radius: 6px !important;
    background: #2e3a48 !important;
    color: #eaf2fb !important;
    font-size: 11px !important;
    line-height: 1.1 !important;
    white-space: normal !important;
    z-index: 12 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group:has(select)::after,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .input-group:has(select)::after {
    color: #cbd6e3 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura [style*="background: #f1f5f9"],
html[data-speas-theme="oscuro"] body.speas-app #modal-factura [style*="background:#f1f5f9"],
html[data-speas-theme="oscuro"] body.speas-app #modal-factura [style*="background: #f8fafc"],
html[data-speas-theme="oscuro"] body.speas-app #modal-factura [style*="background:#f8fafc"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver [style*="background: #f8fafc"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver [style*="background:#f8fafc"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver [style*="background: #ffffff"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver [style*="background:#ffffff"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver [style*="background: #fdfdfd"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver [style*="background:#fdfdfd"] {
    background: #344151 !important;
    border-color: #607086 !important;
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver p,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver span,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver td,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver strong {
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver [style*="color: #475569"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver [style*="color:#475569"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver [style*="color: #64748b"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver [style*="color:#64748b"] {
    color: #cbd6e3 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver table,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver tr {
    background: transparent !important;
    border-color: #607086 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver tfoot tr {
    background: #3a4859 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .file-upload-zone {
    background: #344151 !important;
    border-color: #55dfd0 !important;
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .file-upload-zone p,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura .file-info {
    color: #eaf2fb !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura #fac-total-final {
    background: #1f2a37 !important;
    color: #ffffff !important;
    border-color: #55dfd0 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #loading-overlay {
    background: rgba(8, 13, 22, 0.76) !important;
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app #loading-overlay p {
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .toast,
html[data-speas-theme="oscuro"] body.speas-app .mini-notif {
    background: #ffffff !important;
    color: #334155 !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 18px 50px rgba(4, 9, 16, 0.22) !important;
}

@media (max-width: 768px) {
    html[data-speas-theme="oscuro"] body.speas-app #modal-factura.modal-overlay.active,
    html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver.modal-overlay.active {
        align-items: stretch !important;
        justify-content: center !important;
        padding: 10px 12px 12px !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-content,
    html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .modal-content {
        width: min(94vw, 560px) !important;
        max-width: min(94vw, 560px) !important;
        height: calc(100dvh - 22px) !important;
        max-height: calc(100dvh - 22px) !important;
        min-height: 0 !important;
        margin: 0 auto !important;
        border-radius: 16px !important;
        display: flex !important;
        flex-direction: column !important;
        overflow: hidden !important;
        transform: none !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-header,
    html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .modal-header {
        flex: 0 0 auto !important;
        min-height: 64px !important;
        padding: 14px 16px !important;
        border-radius: 16px 16px 0 0 !important;
        gap: 10px !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-header h3,
    html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .modal-header h3 {
        min-width: 0 !important;
        font-size: clamp(16px, 4.4vw, 20px) !important;
        line-height: 1.2 !important;
        white-space: normal !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-body,
    html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .modal-body {
        flex: 1 1 auto !important;
        min-height: 0 !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch !important;
        padding: 18px 16px max(22px, env(safe-area-inset-bottom, 0px)) !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-footer,
    html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .modal-footer {
        flex: 0 0 auto !important;
        border-radius: 0 0 16px 16px !important;
        display: grid !important;
        grid-template-columns: 1fr !important;
        padding: 12px 16px max(14px, env(safe-area-inset-bottom, 0px)) !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .row-grid,
    html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .row-grid,
    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .fila-adicional {
        grid-template-columns: 1fr !important;
        gap: 14px !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .fila-adicional {
        display: grid !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group,
    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group[style*="grid-column"] {
        grid-column: auto !important;
        margin-bottom: 16px !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group input,
    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group select,
    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group textarea {
        min-height: 52px !important;
        font-size: 15px !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura [style*="grid-template-columns: 1fr 1fr 1fr"] {
        grid-template-columns: 1fr !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura [style*="grid-template-columns: 2fr 1fr auto"] {
        grid-template-columns: 1fr !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .tabs-wrapper {
        padding: 0 12px !important;
        gap: 8px !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .tab-btn {
        font-size: 12px !important;
        padding: 12px 8px !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app .module-header-tabs {
        padding: 14px !important;
        border-radius: 14px !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app .module-header-tabs .tabs-wrapper {
        display: grid !important;
        grid-template-columns: 1fr !important;
        width: 100% !important;
        overflow: visible !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app .table-toolbar .actions {
        width: 100% !important;
        justify-content: center !important;
        flex-wrap: wrap !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app .table-responsive {
        border-radius: 14px !important;
        overflow-x: auto !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app .premium-table {
        min-width: 780px !important;
    }
}

@media (min-width: 769px) and (max-width: 1180px) {
    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-content.slide-in-right,
    html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .modal-content.slide-in-right {
        width: min(76vw, 760px) !important;
        max-width: min(76vw, 760px) !important;
    }
}

@media (min-width: 1600px) {
    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-content.slide-in-right,
    html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .modal-content.slide-in-right {
        width: min(44vw, 920px) !important;
        max-width: min(44vw, 920px) !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app .table-module-container {
        max-width: 1760px !important;
    }
}

/* Speas facturas dark modal refinements v32 */
html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group label,
html[data-speas-theme="oscuro"] body.speas-app #modal-pago .input-group label {
    top: -9px !important;
    left: 12px !important;
    transform: translateY(0) !important;
    display: inline-flex !important;
    align-items: center !important;
    max-width: calc(100% - 24px) !important;
    min-height: 18px !important;
    padding: 2px 7px !important;
    border-radius: 6px !important;
    background: #2e3a48 !important;
    color: #eaf2fb !important;
    font-size: 11px !important;
    line-height: 1.1 !important;
    font-weight: 800 !important;
    white-space: normal !important;
    z-index: 12 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group input::placeholder,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group textarea::placeholder {
    color: #aebbc9 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group input:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group select:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura .input-group textarea:focus {
    border-color: #55dfd0 !important;
    box-shadow: 0 0 0 3px rgba(85, 223, 208, 0.12) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura #fac-oc,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura #fac-total-final,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura #fac-igv,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura input[readonly] {
    background: #253140 !important;
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura #form-nueva-factura > div[style*="background"],
html[data-speas-theme="oscuro"] body.speas-app #modal-factura #form-nueva-factura div[style*="background: #f0fdf4"],
html[data-speas-theme="oscuro"] body.speas-app #modal-factura #form-nueva-factura div[style*="background:#f0fdf4"],
html[data-speas-theme="oscuro"] body.speas-app #modal-factura #form-nueva-factura div[style*="background: #f8fafc"],
html[data-speas-theme="oscuro"] body.speas-app #modal-factura #form-nueva-factura div[style*="background:#f8fafc"] {
    background: #344151 !important;
    border-color: #607086 !important;
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura #form-nueva-factura div[style*="background"] p,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura #form-nueva-factura div[style*="background"] label,
html[data-speas-theme="oscuro"] body.speas-app #modal-factura #form-nueva-factura div[style*="background"] span {
    color: #eaf2fb !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver #tab-ver-info .row-grid > div,
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver #tab-ver-info > div:not(.row-grid),
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver #tab-ver-info div[style*="background: #ffffff"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver #tab-ver-info div[style*="background:#ffffff"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver #tab-ver-info div[style*="background: #fdfdfd"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver #tab-ver-info div[style*="background:#fdfdfd"] {
    background: #344151 !important;
    border-color: #607086 !important;
    color: #f7fbff !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver #tab-ver-info div[style*="background: #f0fdf4"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver #tab-ver-info div[style*="background:#f0fdf4"] {
    background: #193c35 !important;
    border-color: rgba(85, 223, 208, 0.36) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver #tab-ver-info div[style*="background: #fef2f2"],
html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver #tab-ver-info div[style*="background:#fef2f2"] {
    background: #422b32 !important;
    border-color: rgba(248, 113, 113, 0.34) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver #tab-ver-info .form-subtitle {
    color: #eaf2fb !important;
    border-color: transparent !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver #ver-info-glosa {
    background: #253140 !important;
    color: #eaf2fb !important;
    border-left-color: #55dfd0 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .badge {
    background: #dbeafe !important;
    color: #1e3a8a !important;
}

@media (max-width: 768px) {
    body.speas-app #toast-container {
        top: 82px !important;
        left: 16px !important;
        right: 16px !important;
        width: auto !important;
        gap: 8px !important;
        z-index: 9997 !important;
    }

    body.speas-app .toast {
        min-width: 0 !important;
        width: 100% !important;
        padding: 10px 12px !important;
        border-radius: 12px !important;
        gap: 10px !important;
        transform: translateY(-140%) !important;
    }

    body.speas-app .toast.show {
        transform: translateY(0) !important;
    }

    body.speas-app .toast-title {
        font-size: 12px !important;
        margin: 0 !important;
    }

    body.speas-app .toast-msg {
        font-size: 12px !important;
        line-height: 1.25 !important;
    }
}

/* Speas facturas mobile modal scroll without bottom blocker v33 */
@media (max-width: 768px) {
    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-content {
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch !important;
        overscroll-behavior: contain !important;
        justify-content: flex-start !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-header,
    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-body,
    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-footer {
        flex: 0 0 auto !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-body {
        overflow: visible !important;
        min-height: auto !important;
        padding-bottom: 16px !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-footer {
        position: static !important;
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 10px !important;
        padding: 12px 16px max(18px, env(safe-area-inset-bottom, 0px)) !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-footer .btn-cancel,
    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-footer .btn-primary {
        width: 100% !important;
        min-height: 48px !important;
        justify-content: center !important;
    }
}

/* Speas facturas mobile modal spacing and provider accounts dark fix v34 */
html[data-speas-theme="oscuro"] body.speas-app #modal-factura #selector-cuentas-rapido {
    background: #344151 !important;
    border: 1px dashed #55dfd0 !important;
    border-radius: 14px !important;
    box-shadow: inset 0 0 0 1px rgba(85, 223, 208, 0.08) !important;
    color: #f7fbff !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura #selector-cuentas-rapido label {
    position: static !important;
    transform: none !important;
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    width: auto !important;
    max-width: 100% !important;
    min-height: 0 !important;
    margin: 0 0 10px !important;
    padding: 0 !important;
    background: transparent !important;
    color: #eaf2fb !important;
    font-size: 12px !important;
    line-height: 1.2 !important;
    letter-spacing: 0.04em !important;
    text-transform: uppercase !important;
    font-weight: 900 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura #selector-cuentas-rapido label i {
    color: #55dfd0 !important;
    font-size: 16px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura #select-cuenta-auto {
    width: 100% !important;
    min-height: 52px !important;
    padding: 0 44px 0 16px !important;
    border-radius: 12px !important;
    border: 1px solid #607086 !important;
    background: #253140 !important;
    color: #ffffff !important;
    font-weight: 800 !important;
    font-size: 15px !important;
    outline: none !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    text-overflow: ellipsis !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-factura #select-cuenta-auto option {
    background: #253140 !important;
    color: #ffffff !important;
}

@media (max-width: 768px) {
    html[data-speas-theme="oscuro"] body.speas-app #modal-factura.modal-overlay.active,
    html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver.modal-overlay.active {
        padding-top: 22px !important;
        padding-bottom: 16px !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura .modal-content,
    html[data-speas-theme="oscuro"] body.speas-app #modal-detalles-ver .modal-content {
        height: calc(100dvh - 38px) !important;
        max-height: calc(100dvh - 38px) !important;
    }

    html[data-speas-theme="oscuro"] body.speas-app #modal-factura #select-cuenta-auto {
        font-size: 14px !important;
        padding-left: 14px !important;
        padding-right: 34px !important;
    }
}

/* Speas caja chica compact movement type badge v35 */
body.speas-app .caja-chica-container #tabla-chica-body td:nth-child(2) {
    width: 112px !important;
}

body.speas-app .caja-chica-container #tabla-chica-body td:nth-child(2) .badge {
    width: auto !important;
    min-width: 82px !important;
    max-width: 96px !important;
    min-height: 28px !important;
    height: 28px !important;
    padding: 0 9px !important;
    border-radius: 8px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 3px !important;
    font-size: 12px !important;
    line-height: 1 !important;
    letter-spacing: 0 !important;
    white-space: nowrap !important;
    box-sizing: border-box !important;
}

body.speas-app .caja-chica-container #tabla-chica-body td:nth-child(2) .badge i {
    font-size: 12px !important;
    line-height: 1 !important;
    margin: 0 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container #tabla-chica-body td:nth-child(2) .badge {
    background: #dbeafe !important;
    color: #12346b !important;
    border: 1px solid #bcd0eb !important;
    box-shadow: none !important;
}

@media (max-width: 768px) {
    body.speas-app .caja-chica-container #tabla-chica-body td:nth-child(2) {
        width: 94px !important;
    }

    body.speas-app .caja-chica-container #tabla-chica-body td:nth-child(2) .badge {
        min-width: 74px !important;
        max-width: 84px !important;
        height: 26px !important;
        min-height: 26px !important;
        padding: 0 7px !important;
        font-size: 11px !important;
        border-radius: 7px !important;
    }

    body.speas-app .caja-chica-container #tabla-chica-body td:nth-child(2) .badge i {
        font-size: 11px !important;
    }
}

/* Speas inventario desktop tablet tv modal footer fix v36 */
body.speas-app #modal-producto.modal-overlay.active {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    height: 100dvh !important;
    align-items: stretch !important;
    justify-content: flex-end !important;
    overflow: hidden !important;
}

body.speas-app #modal-producto .modal-content.slide-in-right {
    display: grid !important;
    grid-template-rows: auto minmax(0, 1fr) auto !important;
    width: min(46vw, 780px) !important;
    min-width: 640px !important;
    max-width: calc(100vw - var(--sidebar-w, 96px) - 24px) !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    overflow: hidden !important;
}

body.speas-app #modal-producto .modal-header {
    flex: 0 0 auto !important;
    min-height: 96px !important;
    padding: 24px 38px !important;
}

body.speas-app #modal-producto .modal-body {
    min-height: 0 !important;
    height: auto !important;
    overflow-y: auto !important;
    padding: 28px 38px 32px !important;
    overscroll-behavior: contain !important;
}

body.speas-app #modal-producto .modal-footer {
    position: static !important;
    flex: 0 0 auto !important;
    min-height: 86px !important;
    margin: 0 !important;
    padding: 16px 38px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 14px !important;
    z-index: 2 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-content.slide-in-right {
    background: #303b48 !important;
    border-left: 1px solid #607187 !important;
    box-shadow: -28px 0 70px rgba(2, 6, 23, 0.5) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-footer {
    background: #303b48 !important;
    border-top: 1px solid #53657a !important;
    box-shadow: 0 -10px 24px rgba(15, 23, 42, 0.16) !important;
}

@media (min-width: 1600px) {
    body.speas-app #modal-producto .modal-content.slide-in-right {
        width: min(42vw, 860px) !important;
    }
}

@media (min-width: 721px) and (max-width: 1180px) {
    body.speas-app #modal-producto .modal-content.slide-in-right {
        width: min(78vw, 760px) !important;
        min-width: 0 !important;
        max-width: calc(100vw - 24px) !important;
    }

    body.speas-app #modal-producto .modal-header {
        min-height: 88px !important;
        padding: 22px 30px !important;
    }

    body.speas-app #modal-producto .modal-body {
        padding: 24px 30px 30px !important;
    }

    body.speas-app #modal-producto .modal-footer {
        min-height: 82px !important;
        padding: 14px 30px !important;
    }
}

@media (max-width: 720px) {
    body.speas-app #modal-producto.modal-overlay.active {
        justify-content: center !important;
        align-items: flex-start !important;
        height: 100dvh !important;
        padding: 12px 10px max(12px, env(safe-area-inset-bottom)) !important;
        overflow-y: auto !important;
    }

    body.speas-app #modal-producto .modal-content.slide-in-right {
        width: min(100%, 560px) !important;
        min-width: 0 !important;
        max-width: 100% !important;
        height: calc(100dvh - 24px - env(safe-area-inset-bottom)) !important;
        max-height: calc(100dvh - 24px - env(safe-area-inset-bottom)) !important;
        border-radius: 22px !important;
    }

    body.speas-app #modal-producto .modal-header {
        min-height: 82px !important;
        padding: 18px 22px !important;
    }

    body.speas-app #modal-producto .modal-body {
        padding: 20px 22px 24px !important;
    }

    body.speas-app #modal-producto .modal-footer {
        min-height: auto !important;
        padding: 14px 22px max(16px, env(safe-area-inset-bottom)) !important;
    }
}

@media (min-width: 721px) {
    body.speas-app #modal-producto.modal-overlay.active {
        top: -78px !important;
        left: calc(-1 * var(--sidebar-w, 96px)) !important;
        width: 100vw !important;
        height: 100dvh !important;
        max-height: 100dvh !important;
    }

    body.speas-app #modal-producto .modal-content.slide-in-right {
        height: 100dvh !important;
        max-height: 100dvh !important;
    }
}

@media (min-width: 721px) {
    html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-content.slide-in-right,
    body.speas-app #modal-producto .modal-content.slide-in-right {
        width: min(46vw, 780px) !important;
    }
}

@media (min-width: 1600px) {
    html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-content.slide-in-right,
    body.speas-app #modal-producto .modal-content.slide-in-right {
        width: min(42vw, 860px) !important;
        min-width: 760px !important;
    }
}

@media (min-width: 721px) and (max-width: 1180px) {
    html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-content.slide-in-right,
    body.speas-app #modal-producto .modal-content.slide-in-right {
        width: min(78vw, 760px) !important;
        min-width: 0 !important;
    }
}

/* Speas inventario dark modal scrollbar v37 */
html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-body {
    scrollbar-width: thin !important;
    scrollbar-color: #6f8197 #263240 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-body::-webkit-scrollbar {
    width: 12px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-body::-webkit-scrollbar-track {
    background: #263240 !important;
    border-left: 1px solid rgba(96, 113, 135, 0.32) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-body::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #7b8da3 0%, #586a80 100%) !important;
    border: 3px solid #263240 !important;
    border-radius: 999px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-body::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #8fa1b7 0%, #6a7c92 100%) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-producto .modal-body::-webkit-scrollbar-corner {
    background: #263240 !important;
}

/* Speas inventario kardex dark modal spacing and scrollbars v38 */
body.speas-app #modal-kardex.modal-overlay.active {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    height: 100dvh !important;
    padding: clamp(30px, 4dvh, 48px) clamp(18px, 3.5vw, 48px) !important;
    align-items: center !important;
    justify-content: center !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
}

body.speas-app #modal-kardex .modal-content.center-modal {
    display: grid !important;
    grid-template-rows: auto minmax(0, 1fr) !important;
    width: min(88vw, 1380px) !important;
    max-width: calc(100vw - 96px) !important;
    height: auto !important;
    max-height: calc(100dvh - clamp(60px, 8dvh, 96px)) !important;
    margin: 0 !important;
    overflow: hidden !important;
    border-radius: 14px !important;
}

body.speas-app #modal-kardex .modal-header {
    flex: 0 0 auto !important;
    min-height: 90px !important;
    padding: 24px 32px !important;
}

body.speas-app #modal-kardex .modal-body {
    min-height: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 16px !important;
    overflow: hidden !important;
    padding: 24px 32px 20px !important;
}

body.speas-app #modal-kardex .kardex-filters {
    flex: 0 0 auto !important;
    margin-bottom: 0 !important;
}

body.speas-app #modal-kardex .modal-body > div:nth-child(2) {
    flex: 1 1 auto !important;
    min-height: 260px !important;
    max-height: none !important;
    overflow: auto !important;
    padding-bottom: 0 !important;
    overscroll-behavior: contain !important;
}

body.speas-app #modal-kardex .pagination-container {
    flex: 0 0 auto !important;
    margin-top: 2px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-kardex.modal-overlay.active {
    background: rgba(8, 13, 22, 0.78) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-content.center-modal,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-body {
    background: #303b48 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-body > div:nth-child(2) {
    background: #263240 !important;
    border-color: #607187 !important;
    scrollbar-width: thin !important;
    scrollbar-color: #6f8197 #263240 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-body > div:nth-child(2)::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-body::-webkit-scrollbar {
    width: 12px !important;
    height: 12px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-body > div:nth-child(2)::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-body::-webkit-scrollbar-track {
    background: #263240 !important;
    border: 1px solid rgba(96, 113, 135, 0.24) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-body > div:nth-child(2)::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-body::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #7b8da3 0%, #586a80 100%) !important;
    border: 3px solid #263240 !important;
    border-radius: 999px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-body > div:nth-child(2)::-webkit-scrollbar-thumb:hover,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-body::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #8fa1b7 0%, #6a7c92 100%) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-body > div:nth-child(2)::-webkit-scrollbar-corner,
html[data-speas-theme="oscuro"] body.speas-app #modal-kardex .modal-body::-webkit-scrollbar-corner {
    background: #263240 !important;
}

@media (min-width: 721px) {
    body.speas-app #modal-kardex.modal-overlay.active {
        top: -78px !important;
        left: calc(-1 * var(--sidebar-w, 96px)) !important;
        width: 100vw !important;
        height: 100dvh !important;
    }
}

@media (max-width: 720px) {
    body.speas-app #modal-kardex.modal-overlay.active {
        padding: 12px 10px max(12px, env(safe-area-inset-bottom)) !important;
        align-items: flex-start !important;
        overflow-y: auto !important;
    }

    body.speas-app #modal-kardex .modal-content.center-modal {
        width: 100% !important;
        max-width: 100% !important;
        max-height: calc(100dvh - 24px - env(safe-area-inset-bottom)) !important;
        border-radius: 20px !important;
    }

    body.speas-app #modal-kardex .modal-header {
        min-height: 78px !important;
        padding: 18px 20px !important;
    }

    body.speas-app #modal-kardex .modal-body {
        padding: 18px 14px 16px !important;
    }
}

/* Speas inventario table spacing polish v39 */
body.speas-app .table-module-container:has(#tabla-productos-body) .table-responsive {
    padding: 0 10px 8px !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) .premium-table {
    border-collapse: separate !important;
    border-spacing: 0 !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) .premium-table thead th {
    padding: 16px 22px !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) .premium-table tbody td {
    padding: 14px 22px !important;
    line-height: 1.35 !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) .premium-table thead th:first-child,
body.speas-app .table-module-container:has(#tabla-productos-body) .premium-table tbody td:first-child {
    padding-left: 28px !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) .premium-table thead th:last-child,
body.speas-app .table-module-container:has(#tabla-productos-body) .premium-table tbody td:last-child {
    padding-right: 28px !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) .premium-table tbody tr {
    min-height: 68px !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) #tabla-productos-body td:nth-child(2) span,
body.speas-app .table-module-container:has(#tabla-productos-body) #tabla-productos-body td:nth-child(3) span,
body.speas-app .table-module-container:has(#tabla-productos-body) #tabla-productos-body .badge-cat,
body.speas-app .table-module-container:has(#tabla-productos-body) #tabla-productos-body .badge-type,
body.speas-app .table-module-container:has(#tabla-productos-body) #tabla-productos-body .status-badge,
body.speas-app .table-module-container:has(#tabla-productos-body) #tabla-productos-body .badge {
    display: inline-flex !important;
    align-items: center !important;
    min-height: 26px !important;
    padding: 4px 9px !important;
    border-radius: 8px !important;
    line-height: 1.15 !important;
    box-sizing: border-box !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-productos-body) .premium-table thead th {
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-productos-body) #tabla-productos-body td:nth-child(2) span,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-productos-body) #tabla-productos-body td:nth-child(3) span,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-productos-body) #tabla-productos-body .badge-cat,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-productos-body) #tabla-productos-body .badge-type,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-productos-body) #tabla-productos-body .status-badge,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-productos-body) #tabla-productos-body .badge {
    background: #dbeafe !important;
    color: #12346b !important;
    border: 1px solid #bcd0eb !important;
}

@media (max-width: 768px) {
    body.speas-app .table-module-container:has(#tabla-productos-body) .table-responsive {
        padding: 0 6px 8px !important;
    }

    body.speas-app .table-module-container:has(#tabla-productos-body) .premium-table thead th,
    body.speas-app .table-module-container:has(#tabla-productos-body) .premium-table tbody td {
        padding: 13px 16px !important;
    }

    body.speas-app .table-module-container:has(#tabla-productos-body) .premium-table thead th:first-child,
    body.speas-app .table-module-container:has(#tabla-productos-body) .premium-table tbody td:first-child {
        padding-left: 18px !important;
    }
}

/* Speas inventario header spacing polish v40 */
body.speas-app .table-module-container:has(#tabla-productos-body) {
    gap: 18px !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) > .module-header {
    padding: 22px 28px 18px !important;
    margin: 0 !important;
    align-items: center !important;
    border-radius: 12px 12px 0 0 !important;
    box-sizing: border-box !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) > .module-header .header-titles {
    min-width: 260px !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) > .module-header h2 {
    margin: 0 0 8px !important;
    line-height: 1.18 !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) > .module-header p {
    margin: 0 !important;
    line-height: 1.35 !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) > .tabs-container {
    padding: 16px 28px 18px !important;
    margin: 0 !important;
    border-radius: 0 !important;
    box-sizing: border-box !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) > .table-toolbar {
    margin: 0 28px !important;
    padding: 18px 20px !important;
    box-sizing: border-box !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) > .table-responsive {
    margin: 8px 28px 0 !important;
    width: auto !important;
}

body.speas-app .table-module-container:has(#tabla-productos-body) > .pagination {
    margin: 0 28px !important;
}

@media (max-width: 768px) {
    body.speas-app .table-module-container:has(#tabla-productos-body) > .module-header {
        padding: 18px 18px 16px !important;
        gap: 14px !important;
    }

    body.speas-app .table-module-container:has(#tabla-productos-body) > .tabs-container {
        padding: 14px 18px 16px !important;
    }

    body.speas-app .table-module-container:has(#tabla-productos-body) > .table-toolbar,
    body.speas-app .table-module-container:has(#tabla-productos-body) > .table-responsive,
    body.speas-app .table-module-container:has(#tabla-productos-body) > .pagination {
        margin-left: 18px !important;
        margin-right: 18px !important;
    }
}

/* Speas caja chica spacing polish v41 */
body.speas-app .caja-chica-container {
    max-width: min(100%, 1480px) !important;
    padding: 24px 28px 64px !important;
    box-sizing: border-box !important;
}

body.speas-app .caja-chica-container > .module-header {
    padding: 22px 28px 18px !important;
    margin: 0 0 28px !important;
    border-radius: 12px !important;
    box-sizing: border-box !important;
}

body.speas-app .caja-chica-container > .module-header h2 {
    margin: 0 0 8px !important;
    line-height: 1.18 !important;
}

body.speas-app .caja-chica-container > .module-header p {
    margin: 0 !important;
    line-height: 1.35 !important;
}

body.speas-app .caja-chica-container > .saldo-card-container {
    margin: 0 0 32px !important;
    gap: 24px !important;
}

body.speas-app .caja-chica-container .saldo-card {
    padding: 38px 42px !important;
}

body.speas-app .caja-chica-container .actions-grid .btn-action {
    padding: 30px 24px !important;
}

body.speas-app .caja-chica-container > .table-container {
    padding: 32px 34px 34px !important;
    margin: 0 !important;
    box-sizing: border-box !important;
}

body.speas-app .caja-chica-container .table-header-flex {
    padding: 0 4px !important;
    margin-bottom: 20px !important;
}

body.speas-app .caja-chica-container .table-responsive {
    padding: 0 8px 8px !important;
    box-sizing: border-box !important;
}

body.speas-app .caja-chica-container .premium-table th {
    padding: 16px 24px !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
}

body.speas-app .caja-chica-container .premium-table td {
    padding: 14px 24px !important;
    line-height: 1.35 !important;
}

body.speas-app .caja-chica-container .premium-table th:first-child,
body.speas-app .caja-chica-container .premium-table td:first-child {
    padding-left: 28px !important;
}

body.speas-app .caja-chica-container .premium-table th:last-child,
body.speas-app .caja-chica-container .premium-table td:last-child {
    padding-right: 28px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-chica-container > .module-header {
    background: #303b48 !important;
    border: 1px solid #5b6b80 !important;
}

@media (max-width: 980px) {
    body.speas-app .caja-chica-container {
        padding: 18px 18px 56px !important;
    }

    body.speas-app .caja-chica-container > .module-header {
        padding: 18px 18px 16px !important;
        gap: 14px !important;
    }

    body.speas-app .caja-chica-container > .saldo-card-container {
        gap: 18px !important;
    }

    body.speas-app .caja-chica-container .saldo-card,
    body.speas-app .caja-chica-container > .table-container {
        padding: 24px 20px !important;
    }
}

/* Speas flujo caja spacing polish v42 */
body.speas-app .caja-container {
    max-width: min(100%, 1680px) !important;
    padding: 24px 28px 64px !important;
    box-sizing: border-box !important;
}

body.speas-app .caja-container > .module-header {
    padding: 22px 28px 18px !important;
    margin: 0 0 28px !important;
    border-radius: 12px !important;
    box-sizing: border-box !important;
}

body.speas-app .caja-container > .module-header .header-titles {
    min-width: 260px !important;
}

body.speas-app .caja-container > .module-header h2 {
    margin: 0 0 8px !important;
    line-height: 1.18 !important;
}

body.speas-app .caja-container > .module-header p {
    margin: 0 !important;
    line-height: 1.35 !important;
}

body.speas-app .caja-container .kpi-grid-temporal {
    gap: 24px !important;
    margin: 0 0 32px !important;
}

body.speas-app .caja-container .kpi-card {
    padding: 26px 30px !important;
    min-height: 150px !important;
    box-sizing: border-box !important;
}

body.speas-app .caja-container .card-header-flex {
    margin-bottom: 20px !important;
}

body.speas-app .caja-container .amount-big {
    margin: 0 !important;
    line-height: 1.15 !important;
}

body.speas-app .caja-container .desglose-container {
    padding: 28px !important;
    margin: 0 0 32px !important;
    border-radius: 18px !important;
    box-sizing: border-box !important;
}

body.speas-app .caja-container .desglose-header {
    margin: 0 0 24px !important;
    gap: 18px !important;
}

body.speas-app .caja-container .desglose-title h3 {
    margin: 0 0 4px !important;
    line-height: 1.2 !important;
}

body.speas-app .caja-container .desglose-title small {
    display: block !important;
    line-height: 1.3 !important;
}

body.speas-app .caja-container .cards-methods-grid {
    gap: 18px !important;
}

body.speas-app .caja-container .method-card-detail {
    min-height: 82px !important;
    padding: 18px 20px !important;
    box-sizing: border-box !important;
}

body.speas-app .caja-container .method-card-detail .icon-box {
    flex: 0 0 48px !important;
}

body.speas-app .caja-container .table-module-container {
    padding: 32px 34px 34px !important;
    margin: 0 !important;
    border-radius: 18px !important;
    box-sizing: border-box !important;
}

body.speas-app .caja-container .table-responsive {
    padding: 0 8px 8px !important;
    box-sizing: border-box !important;
}

body.speas-app .caja-container .premium-table th {
    padding: 16px 24px !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
}

body.speas-app .caja-container .premium-table td {
    padding: 16px 24px !important;
    line-height: 1.35 !important;
}

body.speas-app .caja-container .premium-table th:first-child,
body.speas-app .caja-container .premium-table td:first-child {
    padding-left: 28px !important;
}

body.speas-app .caja-container .premium-table th:last-child,
body.speas-app .caja-container .premium-table td:last-child {
    padding-right: 28px !important;
}

body.speas-app .caja-container #caja-paginacion {
    margin: 22px 8px 0 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container > .module-header {
    background: #303b48 !important;
    border: 1px solid #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .kpi-card,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .desglose-container,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .table-module-container {
    background: #303b48 !important;
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .desglose-title i,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .method-card-detail .icon-box,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .kpi-icon {
    background: rgba(82, 224, 211, 0.16) !important;
    color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .desglose-title h3,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .amount-big,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .method-info h3 {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .desglose-title small,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .kpi-card span,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .method-info span {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .method-card-detail {
    background: #2b3643 !important;
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .period-tabs {
    background: #354253 !important;
    border: 1px solid #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .tab-btn {
    color: #dbe4ef !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .tab-btn.active {
    background: #52e0d3 !important;
    color: #0f172a !important;
    box-shadow: 0 10px 24px rgba(82, 224, 211, 0.18) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .premium-table th {
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .table-responsive::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .desglose-container::-webkit-scrollbar {
    width: 10px !important;
    height: 10px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .table-responsive::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .desglose-container::-webkit-scrollbar-track {
    background: #1f2a36 !important;
    border-radius: 999px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .caja-container .table-responsive::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app .caja-container .desglose-container::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #5eead4, #60a5fa) !important;
    border: 2px solid #1f2a36 !important;
    border-radius: 999px !important;
}

@media (max-width: 980px) {
    body.speas-app .caja-container {
        padding: 18px 18px 56px !important;
    }

    body.speas-app .caja-container > .module-header {
        padding: 18px 18px 16px !important;
        gap: 14px !important;
    }

    body.speas-app .caja-container .kpi-grid-temporal {
        gap: 18px !important;
        margin-bottom: 24px !important;
    }

    body.speas-app .caja-container .kpi-card,
    body.speas-app .caja-container .desglose-container,
    body.speas-app .caja-container .table-module-container {
        padding: 22px 20px !important;
    }
}

@media (max-width: 600px) {
    body.speas-app .caja-container {
        padding: 14px 14px 48px !important;
    }

    body.speas-app .caja-container > .module-header,
    body.speas-app .caja-container .kpi-card,
    body.speas-app .caja-container .desglose-container,
    body.speas-app .caja-container .table-module-container {
        padding: 18px 16px !important;
    }

    body.speas-app .caja-container .cards-methods-grid {
        grid-template-columns: 1fr !important;
    }

    body.speas-app .caja-container .method-card-detail {
        flex-direction: row !important;
        text-align: left !important;
    }

    body.speas-app .caja-container .premium-table th,
    body.speas-app .caja-container .premium-table td {
        padding: 14px 16px !important;
    }
}

/* Speas historial despacho calendario spacing polish v43 */
body.speas-app .table-module-container:has(#tabla-historial-body) {
    max-width: min(100%, 1680px) !important;
    padding: 24px 28px 64px !important;
    box-sizing: border-box !important;
}

body.speas-app .table-module-container:has(#tabla-historial-body) > .module-header {
    padding: 22px 28px 18px !important;
    margin: 0 0 28px !important;
    border-radius: 12px !important;
    box-sizing: border-box !important;
}

body.speas-app .table-module-container:has(#tabla-historial-body) > .module-header h2,
body.speas-app .calendar-module-container > .module-header h2,
body.speas-app .despacho-container .despacho-title h2 {
    margin: 0 0 8px !important;
    line-height: 1.18 !important;
}

body.speas-app .table-module-container:has(#tabla-historial-body) > .module-header p,
body.speas-app .calendar-module-container > .module-header p,
body.speas-app .despacho-container .despacho-title p {
    margin: 0 !important;
    line-height: 1.35 !important;
}

body.speas-app .table-module-container:has(#tabla-historial-body) > .table-toolbar {
    margin: 0 0 26px !important;
    padding: 18px 20px !important;
    border-radius: 14px !important;
    box-sizing: border-box !important;
}

body.speas-app .table-module-container:has(#tabla-historial-body) > .table-responsive {
    padding: 0 8px 8px !important;
    border-radius: 14px !important;
    box-sizing: border-box !important;
}

body.speas-app .table-module-container:has(#tabla-historial-body) .premium-table th {
    padding: 16px 24px !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
}

body.speas-app .table-module-container:has(#tabla-historial-body) .premium-table td {
    padding: 16px 24px !important;
    line-height: 1.35 !important;
}

body.speas-app .table-module-container:has(#tabla-historial-body) .premium-table th:first-child,
body.speas-app .table-module-container:has(#tabla-historial-body) .premium-table td:first-child {
    padding-left: 28px !important;
}

body.speas-app .table-module-container:has(#tabla-historial-body) .premium-table th:last-child,
body.speas-app .table-module-container:has(#tabla-historial-body) .premium-table td:last-child {
    padding-right: 28px !important;
}

body.speas-app .table-module-container:has(#tabla-historial-body) #historial-paginacion {
    margin: 22px 8px 0 !important;
}

body.speas-app .despacho-container {
    max-width: min(100%, 1680px) !important;
    padding: 24px 28px 64px !important;
    box-sizing: border-box !important;
}

body.speas-app .despacho-container .despacho-header {
    padding: 22px 28px 18px !important;
    margin: 0 0 24px !important;
    border-radius: 12px !important;
    box-sizing: border-box !important;
}

body.speas-app .despacho-container .despacho-tabs {
    padding: 0 0 18px !important;
    margin: 0 0 26px !important;
    gap: 12px !important;
}

body.speas-app .despacho-container .despacho-actions {
    padding: 18px 20px !important;
    margin: 0 0 24px !important;
    border-radius: 14px !important;
    box-sizing: border-box !important;
}

body.speas-app .despacho-container .table-responsive {
    padding: 0 8px 8px !important;
    border-radius: 14px !important;
    box-sizing: border-box !important;
}

body.speas-app .despacho-container .despacho-table th {
    padding: 16px 24px !important;
    line-height: 1.2 !important;
}

body.speas-app .despacho-container .despacho-table td {
    padding: 16px 24px !important;
    line-height: 1.35 !important;
}

body.speas-app .despacho-container .despacho-table th:first-child,
body.speas-app .despacho-container .despacho-table td:first-child {
    padding-left: 28px !important;
}

body.speas-app .despacho-container .despacho-table th:last-child,
body.speas-app .despacho-container .despacho-table td:last-child {
    padding-right: 28px !important;
}

body.speas-app .calendar-module-container {
    max-width: min(100%, 1680px) !important;
    height: auto !important;
    min-height: calc(100vh - 130px) !important;
    padding: 24px 28px 64px !important;
    gap: 26px !important;
    box-sizing: border-box !important;
}

body.speas-app .calendar-module-container > .module-header {
    padding: 22px 28px 18px !important;
    margin: 0 !important;
    border-radius: 12px !important;
    box-sizing: border-box !important;
}

body.speas-app .calendar-module-container .calendar-wrapper {
    margin: 0 !important;
    border-radius: 18px !important;
    min-height: 680px !important;
    box-sizing: border-box !important;
}

body.speas-app .calendar-module-container .calendar-sidebar {
    padding: 34px 30px !important;
    gap: 18px !important;
    box-sizing: border-box !important;
}

body.speas-app .calendar-module-container .calendar-main-area {
    padding: 26px !important;
    box-sizing: border-box !important;
}

body.speas-app .calendar-module-container .fc-toolbar {
    gap: 18px !important;
}

body.speas-app .calendar-module-container .fc-toolbar-title {
    line-height: 1.2 !important;
}

body.speas-app .calendar-module-container .fc-scrollgrid th,
body.speas-app .calendar-module-container .fc-scrollgrid td {
    padding-left: 10px !important;
    padding-right: 10px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-historial-body) > .module-header,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-historial-body) > .table-toolbar,
html[data-speas-theme="oscuro"] body.speas-app .despacho-container .despacho-header,
html[data-speas-theme="oscuro"] body.speas-app .despacho-container .despacho-actions,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container > .module-header {
    background: #303b48 !important;
    border: 1px solid #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-container,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container {
    background: transparent !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-container .table-responsive,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .calendar-wrapper,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .calendar-sidebar,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .calendar-main-area {
    background: #303b48 !important;
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-historial-body) .premium-table th,
html[data-speas-theme="oscuro"] body.speas-app .despacho-container .despacho-table th,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .fc-col-header-cell {
    color: #dbeafe !important;
    background: #3a4859 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-historial-body) .premium-table td,
html[data-speas-theme="oscuro"] body.speas-app .despacho-container .despacho-table td,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .fc-daygrid-day-number,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .fc-toolbar-title {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .mini-calendar-title,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .custom-checkbox,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .fc-col-header-cell-cushion {
    color: #dbe4ef !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-container .despacho-tabs {
    border-bottom-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-container .tab-btn,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .fc-button {
    background: #354253 !important;
    border: 1px solid #5b6b80 !important;
    color: #dbe4ef !important;
}

html[data-speas-theme="oscuro"] body.speas-app .despacho-container .tab-btn.active,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .fc-button-active {
    background: #52e0d3 !important;
    border-color: #52e0d3 !important;
    color: #0f172a !important;
}

html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .fc-scrollgrid,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .fc-theme-standard td,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .fc-theme-standard th {
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-historial-body) .table-responsive::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app .despacho-container .table-responsive::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app .despacho-container .despacho-tabs::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .calendar-main-area::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .fc-scroller::-webkit-scrollbar {
    width: 10px !important;
    height: 10px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-historial-body) .table-responsive::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app .despacho-container .table-responsive::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app .despacho-container .despacho-tabs::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .calendar-main-area::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .fc-scroller::-webkit-scrollbar-track {
    background: #1f2a36 !important;
    border-radius: 999px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-historial-body) .table-responsive::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app .despacho-container .table-responsive::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app .despacho-container .despacho-tabs::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .calendar-main-area::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app .calendar-module-container .fc-scroller::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #5eead4, #60a5fa) !important;
    border: 2px solid #1f2a36 !important;
    border-radius: 999px !important;
}

@media (max-width: 980px) {
    body.speas-app .table-module-container:has(#tabla-historial-body),
    body.speas-app .despacho-container,
    body.speas-app .calendar-module-container {
        padding: 18px 18px 56px !important;
    }

    body.speas-app .table-module-container:has(#tabla-historial-body) > .module-header,
    body.speas-app .despacho-container .despacho-header,
    body.speas-app .calendar-module-container > .module-header {
        padding: 18px 18px 16px !important;
        gap: 14px !important;
    }

    body.speas-app .despacho-container .despacho-actions,
    body.speas-app .table-module-container:has(#tabla-historial-body) > .table-toolbar {
        padding: 16px !important;
    }

    body.speas-app .calendar-module-container .calendar-wrapper {
        min-height: 620px !important;
    }
}

@media (max-width: 768px) {
    body.speas-app .calendar-module-container .calendar-wrapper {
        flex-direction: column !important;
        min-height: auto !important;
    }

    body.speas-app .calendar-module-container .calendar-sidebar {
        width: 100% !important;
        padding: 20px !important;
        border-right: 0 !important;
        border-bottom: 1px solid #5b6b80 !important;
    }

    body.speas-app .calendar-module-container .calendar-main-area {
        min-height: 620px !important;
        padding: 18px !important;
    }
}

@media (max-width: 600px) {
    body.speas-app .table-module-container:has(#tabla-historial-body),
    body.speas-app .despacho-container,
    body.speas-app .calendar-module-container {
        padding: 14px 14px 48px !important;
    }

    body.speas-app .table-module-container:has(#tabla-historial-body) > .module-header,
    body.speas-app .table-module-container:has(#tabla-historial-body) > .table-toolbar,
    body.speas-app .despacho-container .despacho-header,
    body.speas-app .despacho-container .despacho-actions,
    body.speas-app .calendar-module-container > .module-header {
        padding: 18px 16px !important;
    }

    body.speas-app .table-module-container:has(#tabla-historial-body) .premium-table th,
    body.speas-app .table-module-container:has(#tabla-historial-body) .premium-table td,
    body.speas-app .despacho-container .despacho-table th,
    body.speas-app .despacho-container .despacho-table td {
        padding: 14px 16px !important;
    }
}

/* Speas proveedores dark spacing and centered modals v44 */
body.speas-app .table-module-container:has(#tabla-proveedores-body) {
    max-width: min(100%, 1680px) !important;
    width: 100% !important;
    margin: 0 auto !important;
    padding: 24px 28px 34px !important;
    gap: 24px !important;
    min-height: 0 !important;
    box-sizing: border-box !important;
}

body.speas-app .table-module-container:has(#tabla-proveedores-body) > .module-header {
    padding: 22px 28px 18px !important;
    margin: 0 !important;
    border-radius: 12px !important;
    box-sizing: border-box !important;
}

body.speas-app .table-module-container:has(#tabla-proveedores-body) > .module-header h2 {
    margin: 0 0 8px !important;
    line-height: 1.18 !important;
}

body.speas-app .table-module-container:has(#tabla-proveedores-body) > .module-header p {
    margin: 0 !important;
    line-height: 1.35 !important;
}

body.speas-app .table-module-container:has(#tabla-proveedores-body) > .table-toolbar {
    padding: 18px 20px !important;
    margin: 0 !important;
    border-radius: 14px !important;
    box-sizing: border-box !important;
}

body.speas-app .table-module-container:has(#tabla-proveedores-body) > .table-responsive {
    padding: 0 8px 8px !important;
    border-radius: 14px !important;
    box-sizing: border-box !important;
    min-height: 0 !important;
}

body.speas-app .table-module-container:has(#tabla-proveedores-body) .premium-table th {
    padding: 16px 24px !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
}

body.speas-app .table-module-container:has(#tabla-proveedores-body) .premium-table td {
    padding: 16px 24px !important;
    line-height: 1.35 !important;
}

body.speas-app .table-module-container:has(#tabla-proveedores-body) .premium-table th:first-child,
body.speas-app .table-module-container:has(#tabla-proveedores-body) .premium-table td:first-child {
    padding-left: 28px !important;
}

body.speas-app .table-module-container:has(#tabla-proveedores-body) .premium-table th:last-child,
body.speas-app .table-module-container:has(#tabla-proveedores-body) .premium-table td:last-child {
    padding-right: 28px !important;
}

body.speas-app .table-module-container:has(#tabla-proveedores-body) > .pagination {
    margin: 0 !important;
    padding: 10px 8px 0 !important;
    min-height: 0 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-proveedores-body) > .module-header,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-proveedores-body) > .table-toolbar {
    background: #303b48 !important;
    border: 1px solid #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-proveedores-body) > .table-responsive {
    background: #303b48 !important;
    border: 1px solid #5b6b80 !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-proveedores-body) .premium-table thead,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-proveedores-body) .premium-table th {
    background: #3a4859 !important;
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-proveedores-body) .premium-table td {
    color: #f8fafc !important;
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-proveedores-body) .premium-table tr:hover {
    background: #354253 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-proveedores-body) .page-info {
    color: #dbe4ef !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-proveedores-body) .table-responsive::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-body::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-content::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app #copy-modal-content::-webkit-scrollbar {
    width: 10px !important;
    height: 10px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-proveedores-body) .table-responsive::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-body::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-content::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app #copy-modal-content::-webkit-scrollbar-track {
    background: #1f2a36 !important;
    border-radius: 999px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-proveedores-body) .table-responsive::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-body::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-content::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app #copy-modal-content::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #5eead4, #60a5fa) !important;
    border: 2px solid #1f2a36 !important;
    border-radius: 999px !important;
}

body.speas-app #modal-proveedor.modal-overlay {
    align-items: center !important;
    justify-content: center !important;
    padding: 48px 32px !important;
    box-sizing: border-box !important;
}

body.speas-app #modal-proveedor.modal-overlay.active,
body.speas-app #modal-proveedor.modal-overlay:not(.hidden) {
    display: flex !important;
}

body.speas-app #modal-proveedor .modal-content {
    width: min(1040px, calc(100vw - 96px)) !important;
    max-width: min(1040px, calc(100vw - 96px)) !important;
    height: auto !important;
    max-height: calc(100dvh - 96px) !important;
    margin: auto !important;
    border-radius: 18px !important;
    overflow: hidden !important;
    transform: none !important;
    box-shadow: 0 26px 70px rgba(3, 10, 20, 0.36) !important;
}

body.speas-app #modal-proveedor .modal-header {
    min-height: 78px !important;
    padding: 22px 38px !important;
    box-sizing: border-box !important;
}

body.speas-app #modal-proveedor .modal-body {
    max-height: calc(100dvh - 252px) !important;
    padding: 30px 38px 26px !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    box-sizing: border-box !important;
}

body.speas-app #modal-proveedor .modal-footer {
    position: sticky !important;
    bottom: 0 !important;
    padding: 22px 38px !important;
    gap: 14px !important;
    box-shadow: none !important;
    box-sizing: border-box !important;
}

body.speas-app #modal-proveedor .row-grid {
    gap: 18px !important;
}

body.speas-app #modal-proveedor .form-subtitle {
    margin: 28px 0 18px !important;
    padding-bottom: 8px !important;
    line-height: 1.2 !important;
}

body.speas-app #modal-proveedor .premium-table {
    margin: 0 0 26px !important;
    border-radius: 12px !important;
    overflow: hidden !important;
}

body.speas-app #modal-proveedor .premium-table td {
    padding: 10px 12px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-proveedor .modal-content,
html[data-speas-theme="oscuro"] body.speas-app #modal-copiar-datos .modal-content {
    background: #303b48 !important;
    border: 1px solid #5b6b80 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-footer {
    background: #354253 !important;
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-header h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .form-subtitle,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor label,
html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-proveedor h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-copiar-datos h3 {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .form-subtitle {
    border-color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor input,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor select,
html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b input {
    background: #263443 !important;
    color: #f8fafc !important;
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor input::placeholder,
html[data-speas-theme="oscuro"] body.speas-app #modal-acceso-b2b input::placeholder {
    color: #aebccd !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group label.static,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group input:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group input:not(:placeholder-shown) ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group select:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .input-group select:valid ~ label {
    background: #303b48 !important;
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table td {
    background: #303b48 !important;
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table input,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table select {
    background: #263443 !important;
    color: #f8fafc !important;
    border-color: #5b6b80 !important;
}

body.speas-app #modal-acceso-b2b,
body.speas-app #modal-confirmar-proveedor,
body.speas-app #modal-copiar-datos {
    align-items: center !important;
    justify-content: center !important;
    padding: 32px !important;
    box-sizing: border-box !important;
}

body.speas-app #modal-acceso-b2b .modal-content,
body.speas-app #modal-confirmar-proveedor .modal-content,
body.speas-app #modal-copiar-datos .modal-content {
    transform: none !important;
    margin: auto !important;
    border-radius: 18px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-confirmar-proveedor p,
html[data-speas-theme="oscuro"] body.speas-app #modal-copiar-datos p,
html[data-speas-theme="oscuro"] body.speas-app #b2b-proveedor-nombre {
    color: #dbe4ef !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-copiar-datos .modal-content div:has(#copy-modal-content) {
    background: #263443 !important;
    border-color: #5b6b80 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #copy-modal-content {
    color: #f8fafc !important;
}

@media (min-width: 1400px) {
    body.speas-app #modal-proveedor .modal-content {
        width: min(1120px, calc(100vw - 140px)) !important;
        max-width: min(1120px, calc(100vw - 140px)) !important;
    }
}

@media (max-width: 980px) {
    body.speas-app .table-module-container:has(#tabla-proveedores-body) {
        padding: 18px 18px 34px !important;
    }

    body.speas-app .table-module-container:has(#tabla-proveedores-body) > .module-header,
    body.speas-app .table-module-container:has(#tabla-proveedores-body) > .table-toolbar {
        padding: 18px 18px 16px !important;
        gap: 14px !important;
    }

    body.speas-app #modal-proveedor.modal-overlay {
        padding: 34px 24px !important;
    }

    body.speas-app #modal-proveedor .modal-content {
        width: min(920px, calc(100vw - 48px)) !important;
        max-width: min(920px, calc(100vw - 48px)) !important;
        max-height: calc(100dvh - 68px) !important;
    }
}

@media (max-width: 600px) {
    body.speas-app .table-module-container:has(#tabla-proveedores-body) {
        padding: 14px 14px 34px !important;
    }

    body.speas-app #modal-proveedor.modal-overlay {
        padding: 14px !important;
    }

    body.speas-app #modal-proveedor .modal-content {
        width: calc(100vw - 28px) !important;
        max-width: calc(100vw - 28px) !important;
        max-height: calc(100dvh - 28px) !important;
        border-radius: 16px !important;
    }

    body.speas-app #modal-proveedor .modal-header,
    body.speas-app #modal-proveedor .modal-body,
    body.speas-app #modal-proveedor .modal-footer {
        padding-left: 18px !important;
        padding-right: 18px !important;
    }
}

/* Speas proveedores viewport modal and scrollbar polish v45 */
body.speas-app #modal-proveedor.modal-overlay,
body.speas-app #modal-acceso-b2b,
body.speas-app #modal-confirmar-proveedor,
body.speas-app #modal-copiar-datos {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    height: 100dvh !important;
    min-height: 100dvh !important;
    z-index: 12000 !important;
    align-items: center !important;
    justify-content: center !important;
    overflow: hidden !important;
    background: rgba(8, 15, 26, 0.72) !important;
    backdrop-filter: blur(12px) saturate(120%) !important;
}

body.speas-app #modal-proveedor.modal-overlay {
    padding: 48px 32px !important;
}

body.speas-app #modal-acceso-b2b,
body.speas-app #modal-confirmar-proveedor,
body.speas-app #modal-copiar-datos {
    padding: 32px !important;
}

body.speas-app #modal-proveedor .modal-content {
    max-height: calc(100dvh - 96px) !important;
}

body.speas-app #modal-acceso-b2b .modal-content,
body.speas-app #modal-confirmar-proveedor .modal-content,
body.speas-app #modal-copiar-datos .modal-content {
    max-height: calc(100dvh - 64px) !important;
}

body.speas-app #modal-proveedor .modal-body,
body.speas-app #copy-modal-content {
    scrollbar-width: thin !important;
    scrollbar-color: #5eead4 #1f2a36 !important;
}

body.speas-app .table-module-container:has(#tabla-proveedores-body) > .table-responsive {
    height: auto !important;
    max-height: none !important;
}

body.speas-app .table-module-container:has(#tabla-proveedores-body) > .table-responsive > .premium-table {
    margin: 0 !important;
}

@media (min-width: 1800px) {
    body.speas-app .table-module-container:has(#tabla-proveedores-body) {
        max-width: min(100%, 1760px) !important;
    }
}

@media (max-width: 980px) {
    body.speas-app #modal-proveedor.modal-overlay {
        padding: 34px 24px !important;
    }

    body.speas-app #modal-proveedor .modal-content {
        max-height: calc(100dvh - 68px) !important;
    }
}

@media (max-width: 600px) {
    body.speas-app #modal-proveedor.modal-overlay,
    body.speas-app #modal-acceso-b2b,
    body.speas-app #modal-confirmar-proveedor,
    body.speas-app #modal-copiar-datos {
        padding: 14px !important;
    }

    body.speas-app #modal-proveedor .modal-content,
    body.speas-app #modal-acceso-b2b .modal-content,
    body.speas-app #modal-confirmar-proveedor .modal-content,
    body.speas-app #modal-copiar-datos .modal-content {
        max-height: calc(100dvh - 28px) !important;
    }
}

/* Speas proveedores true viewport centering v46 */
body.speas-app #modal-proveedor.modal-overlay,
body.speas-app #modal-acceso-b2b,
body.speas-app #modal-confirmar-proveedor,
body.speas-app #modal-copiar-datos {
    left: -96px !important;
    top: -78px !important;
    right: auto !important;
    bottom: auto !important;
}

@media (max-width: 600px) {
    body.speas-app #modal-proveedor.modal-overlay,
    body.speas-app #modal-acceso-b2b,
    body.speas-app #modal-confirmar-proveedor,
    body.speas-app #modal-copiar-datos {
        left: -16px !important;
        top: -74px !important;
    }
}

/* Speas proveedores side editor and category contrast v47 */
body.speas-app #modal-proveedor.modal-overlay {
    align-items: stretch !important;
    justify-content: flex-end !important;
    padding: 0 !important;
}

body.speas-app #modal-proveedor .modal-content.slide-in-right,
body.speas-app #modal-proveedor .modal-content {
    width: min(48vw, 920px) !important;
    min-width: 720px !important;
    max-width: calc(100vw - var(--sidebar-w, 96px) - 24px) !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    margin: 0 !important;
    border-radius: 18px 0 0 18px !important;
    display: grid !important;
    grid-template-rows: auto minmax(0, 1fr) auto !important;
    overflow: hidden !important;
    transform: none !important;
}

body.speas-app #modal-proveedor .modal-header {
    min-height: 96px !important;
    padding: 24px 38px !important;
}

body.speas-app #modal-proveedor .modal-body {
    min-height: 0 !important;
    height: auto !important;
    max-height: none !important;
    padding: 28px 38px 32px !important;
    overflow-y: auto !important;
    overscroll-behavior: contain !important;
}

body.speas-app #modal-proveedor .modal-footer {
    position: static !important;
    min-height: 86px !important;
    padding: 16px 38px !important;
    align-items: center !important;
    justify-content: flex-end !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-content.slide-in-right,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-content {
    background: #303b48 !important;
    border: 1px solid #607187 !important;
    border-right: 0 !important;
    box-shadow: -28px 0 70px rgba(2, 6, 23, 0.5) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .modal-footer {
    background: #303b48 !important;
    border-top: 1px solid #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td:nth-child(3) .status-badge,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container:has(#tabla-proveedores-body) #tabla-proveedores-body td:nth-child(3) .status-badge,
html[data-speas-theme="oscuro"] body.speas-app #module-content .table-module-container:has(#tabla-proveedores-body) .premium-table td:nth-child(3) span[style*="background:#f0f4ff"] {
    background: #dbeafe !important;
    color: #12346b !important;
    border: 1px solid #93c5fd !important;
    text-shadow: none !important;
    opacity: 1 !important;
}

@media (min-width: 1600px) {
    body.speas-app #modal-proveedor .modal-content.slide-in-right,
    body.speas-app #modal-proveedor .modal-content {
        width: min(44vw, 980px) !important;
    }
}

@media (min-width: 721px) and (max-width: 1180px) {
    body.speas-app #modal-proveedor .modal-content.slide-in-right,
    body.speas-app #modal-proveedor .modal-content {
        width: min(82vw, 820px) !important;
        min-width: 0 !important;
        max-width: calc(100vw - 24px) !important;
    }
}

@media (max-width: 720px) {
    body.speas-app #modal-proveedor.modal-overlay {
        align-items: stretch !important;
        justify-content: flex-end !important;
        padding: 0 !important;
    }

    body.speas-app #modal-proveedor .modal-content.slide-in-right,
    body.speas-app #modal-proveedor .modal-content {
        width: 100vw !important;
        min-width: 0 !important;
        max-width: 100vw !important;
        height: 100dvh !important;
        max-height: 100dvh !important;
        border-radius: 0 !important;
    }

    body.speas-app #modal-proveedor .modal-header,
    body.speas-app #modal-proveedor .modal-body,
    body.speas-app #modal-proveedor .modal-footer {
        padding-left: 20px !important;
        padding-right: 20px !important;
    }
}

/* Speas proveedores nested inputs dark borders v48 */
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table tr {
    background: rgba(38, 52, 67, 0.38) !important;
    border-color: rgba(96, 113, 135, 0.56) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table td {
    background: transparent !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table input,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table input[type="text"],
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table input[type="email"],
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table input[type="number"],
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table select {
    min-height: 46px !important;
    background: #263443 !important;
    color: #f8fafc !important;
    border: 1px solid #607187 !important;
    border-radius: 9px !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table input::placeholder {
    color: #aebccd !important;
    opacity: 1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table input:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table select:focus {
    border-color: #5eead4 !important;
    box-shadow: 0 0 0 3px rgba(94, 234, 212, 0.16) !important;
    outline: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-proveedor .premium-table input[type="checkbox"] {
    min-height: 20px !important;
    width: 20px !important;
    height: 20px !important;
    accent-color: #5eead4 !important;
    box-shadow: none !important;
}

/* Speas proveedores bank account field layout v49 */
body.speas-app #modal-proveedor #lista-banco-erp tr {
    display: grid !important;
    grid-template-columns: repeat(12, minmax(0, 1fr)) !important;
    gap: 12px !important;
    align-items: center !important;
    padding: 16px !important;
}

body.speas-app #modal-proveedor #lista-banco-erp td {
    display: block !important;
    width: auto !important;
    min-width: 0 !important;
    padding: 0 !important;
}

body.speas-app #modal-proveedor #lista-banco-erp td:nth-child(1) {
    grid-column: span 2 !important;
}

body.speas-app #modal-proveedor #lista-banco-erp td:nth-child(2) {
    grid-column: span 5 !important;
}

body.speas-app #modal-proveedor #lista-banco-erp td:nth-child(3) {
    grid-column: span 4 !important;
}

body.speas-app #modal-proveedor #lista-banco-erp td:nth-child(4) {
    grid-column: span 6 !important;
}

body.speas-app #modal-proveedor #lista-banco-erp td:nth-child(5) {
    grid-column: span 5 !important;
}

body.speas-app #modal-proveedor #lista-banco-erp td:nth-child(6) {
    grid-column: span 1 !important;
    display: flex !important;
    justify-content: center !important;
}

body.speas-app #modal-proveedor #lista-banco-erp [data-f="cuenta"],
body.speas-app #modal-proveedor #lista-banco-erp [data-f="cci"] {
    min-width: 0 !important;
    width: 100% !important;
    font-size: 14px !important;
}

@media (max-width: 900px) {
    body.speas-app #modal-proveedor #lista-banco-erp td:nth-child(1),
    body.speas-app #modal-proveedor #lista-banco-erp td:nth-child(2),
    body.speas-app #modal-proveedor #lista-banco-erp td:nth-child(3),
    body.speas-app #modal-proveedor #lista-banco-erp td:nth-child(4),
    body.speas-app #modal-proveedor #lista-banco-erp td:nth-child(5) {
        grid-column: span 12 !important;
    }

    body.speas-app #modal-proveedor #lista-banco-erp td:nth-child(6) {
        grid-column: span 12 !important;
        justify-content: flex-end !important;
    }
}

/* Speas ordenes compra side panel and dark scroll polish v50 */
body.speas-app .modulo-container:has(#tabla-oc-interna) {
    padding: 30px 32px 28px !important;
}

body.speas-app .modulo-container:has(#tabla-oc-interna) .header-acciones {
    margin: 0 0 28px !important;
    padding: 16px 0 4px !important;
    gap: 22px !important;
}

body.speas-app .modulo-container:has(#tabla-oc-interna) .header-acciones h2 {
    margin: 0 !important;
    padding: 0 !important;
    line-height: 1.25 !important;
}

body.speas-app .modulo-container:has(#tabla-oc-interna) .table-responsive {
    margin-top: 0 !important;
}

body.speas-app #modal-crear-oc.modal-overlay {
    align-items: stretch !important;
    justify-content: flex-end !important;
    padding: 0 !important;
}

body.speas-app #modal-crear-oc.modal-overlay:not(.hidden) {
    display: flex !important;
}

body.speas-app #modal-crear-oc .modal-content {
    width: min(52vw, 1000px) !important;
    min-width: 820px !important;
    max-width: calc(100vw - var(--sidebar-w, 96px) - 24px) !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    box-sizing: border-box !important;
    margin: 0 !important;
    border-radius: 18px 0 0 18px !important;
    display: grid !important;
    grid-template-rows: auto minmax(0, 1fr) !important;
    overflow: hidden !important;
    transform: none !important;
}

body.speas-app #modal-crear-oc .modal-header {
    min-height: 84px !important;
    padding: 24px 32px !important;
}

body.speas-app #modal-crear-oc .modal-body {
    min-height: 0 !important;
    height: auto !important;
    max-height: none !important;
    padding: 28px 32px 34px !important;
    overflow-y: auto !important;
    overscroll-behavior: contain !important;
    scrollbar-width: thin !important;
    scrollbar-color: #5eead4 #263240 !important;
}

body.speas-app #modal-crear-oc .form-grid {
    gap: 22px 24px !important;
}

body.speas-app #modal-crear-oc .form-actions {
    display: flex !important;
    justify-content: flex-end !important;
    gap: 12px !important;
    padding-top: 6px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) {
    background: #2e3a48 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .modal-content {
    background: #303b48 !important;
    border: 1px solid #607187 !important;
    border-right: 0 !important;
    box-shadow: -28px 0 70px rgba(2, 6, 23, 0.52) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .modal-header {
    background: #303b48 !important;
    border-bottom: 1px solid #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .modal-body {
    background: #303b48 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .table-responsive,
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .modal-body {
    scrollbar-width: thin !important;
    scrollbar-color: #5eead4 #263240 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .table-responsive::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .modal-body::-webkit-scrollbar {
    width: 10px !important;
    height: 10px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .table-responsive::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .modal-body::-webkit-scrollbar-track {
    background: #263240 !important;
    border-radius: 999px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .table-responsive::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .modal-body::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #5eead4, #38bdf8) !important;
    border: 2px solid #263240 !important;
    border-radius: 999px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .modulo-container:has(#tabla-oc-interna) .table-responsive::-webkit-scrollbar-corner,
html[data-speas-theme="oscuro"] body.speas-app #modal-crear-oc .modal-body::-webkit-scrollbar-corner {
    background: #263240 !important;
}

@media (min-width: 1600px) {
    body.speas-app #modal-crear-oc .modal-content {
        width: min(46vw, 1040px) !important;
    }
}

@media (min-width: 721px) and (max-width: 1180px) {
    body.speas-app #modal-crear-oc .modal-content {
        width: min(84vw, 860px) !important;
        min-width: 0 !important;
        max-width: calc(100vw - 24px) !important;
    }
}

@media (max-width: 720px) {
    body.speas-app .modulo-container:has(#tabla-oc-interna) {
        padding: 18px 16px 20px !important;
    }

    body.speas-app .modulo-container:has(#tabla-oc-interna) .header-acciones {
        padding-top: 8px !important;
    }

    body.speas-app #modal-crear-oc.modal-overlay:not(.hidden) {
        align-items: stretch !important;
        justify-content: flex-end !important;
        padding: 0 !important;
    }

    body.speas-app #modal-crear-oc .modal-content {
        width: 100vw !important;
        min-width: 0 !important;
        max-width: 100vw !important;
        height: 100dvh !important;
        max-height: 100dvh !important;
        border-radius: 0 !important;
    }

    body.speas-app #modal-crear-oc .modal-header,
    body.speas-app #modal-crear-oc .modal-body {
        padding-left: 20px !important;
        padding-right: 20px !important;
    }
}

/* Speas creditos dark spacing and side modal polish v51 */
body.speas-app .module-container:has(#tabla-creditos-body),
body.speas-app .module-container:has(#form-simulador-rapido) {
    padding: 26px 32px 30px !important;
}

body.speas-app .module-container:has(#tabla-creditos-body) .module-header-tabs {
    padding: 24px 26px !important;
    margin: 0 0 28px !important;
    gap: 22px !important;
}

body.speas-app .module-container:has(#tabla-creditos-body) .header-titles h2 {
    margin: 0 0 8px !important;
    line-height: 1.25 !important;
}

body.speas-app .module-container:has(#tabla-creditos-body) .header-titles p {
    margin: 0 !important;
}

body.speas-app .module-container:has(#tabla-creditos-body) .tabs-wrapper {
    width: auto !important;
    min-width: 374px !important;
    padding: 8px !important;
    gap: 8px !important;
    border-radius: 14px !important;
}

body.speas-app .module-container:has(#tabla-creditos-body) .tabs-wrapper .tab-btn {
    min-height: 48px !important;
    padding: 0 18px !important;
    border-radius: 10px !important;
    white-space: nowrap !important;
}

body.speas-app .module-container:has(#tabla-creditos-body) .kpi-resumen-bar {
    gap: 24px !important;
    margin: 0 0 28px !important;
}

body.speas-app .module-container:has(#tabla-creditos-body) .kpi-card {
    padding: 24px 26px !important;
}

body.speas-app .module-container:has(#tabla-creditos-body) .table-toolbar {
    padding: 20px !important;
    margin: 0 0 24px !important;
    gap: 18px !important;
    align-items: center !important;
}

body.speas-app .module-container:has(#tabla-creditos-body) .search-box {
    width: min(100%, 520px) !important;
    min-height: 50px !important;
}

body.speas-app .module-container:has(#tabla-creditos-body) .search-box input {
    min-height: 50px !important;
}

body.speas-app .module-container:has(#tabla-creditos-body) .actions-box .btn-primary {
    min-height: 50px !important;
    padding: 0 24px !important;
}

body.speas-app .module-container:has(#tabla-creditos-body) .table-responsive {
    margin-top: 0 !important;
}

body.speas-app .module-container:has(#form-simulador-rapido) .simulation-wrapper {
    padding: 26px !important;
    border-radius: 16px !important;
    box-shadow: none !important;
}

body.speas-app .module-container:has(#form-simulador-rapido) .simulation-wrapper h3 {
    margin-bottom: 24px !important;
    padding-bottom: 16px !important;
}

body.speas-app .module-container:has(#form-simulador-rapido) .grid-row {
    gap: 22px !important;
    margin-bottom: 20px !important;
}

body.speas-app #modal-credito.modal-overlay {
    align-items: stretch !important;
    justify-content: flex-end !important;
    padding: 0 !important;
}

body.speas-app #modal-credito.modal-overlay.active {
    display: flex !important;
}

body.speas-app #modal-credito .modal-content {
    width: min(54vw, 1040px) !important;
    min-width: 840px !important;
    max-width: calc(100vw - var(--sidebar-w, 96px) - 24px) !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    margin: 0 !important;
    border-radius: 18px 0 0 18px !important;
    display: grid !important;
    grid-template-rows: auto minmax(0, 1fr) auto !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
    transform: none !important;
}

body.speas-app #modal-credito .modal-header {
    min-height: 92px !important;
    padding: 24px 32px !important;
}

body.speas-app #modal-credito .modal-body {
    min-height: 0 !important;
    height: auto !important;
    max-height: none !important;
    padding: 28px 32px 34px !important;
    overflow-y: auto !important;
    overscroll-behavior: contain !important;
}

body.speas-app #modal-credito .modal-footer {
    position: static !important;
    min-height: 86px !important;
    padding: 16px 32px !important;
    display: flex !important;
    justify-content: flex-end !important;
    align-items: center !important;
    gap: 12px !important;
}

body.speas-app #modal-credito .flow-selector-container {
    gap: 24px !important;
    margin-bottom: 28px !important;
}

body.speas-app #modal-credito .flow-card {
    min-height: 132px !important;
    border-radius: 14px !important;
}

body.speas-app #modal-credito .grid-row {
    gap: 22px 24px !important;
}

body.speas-app #modal-credito .input-group input,
body.speas-app #modal-credito .input-group select {
    min-height: 52px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body),
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) {
    background: #2e3a48 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .module-header-tabs,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .table-toolbar,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) .simulation-wrapper {
    background: #303b48 !important;
    border: 1px solid #607187 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .tabs-wrapper {
    background: #263240 !important;
    border: 1px solid #53657a !important;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .tabs-wrapper .tab-btn {
    background: transparent !important;
    border: 1px solid transparent !important;
    color: #dbe7f3 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .tabs-wrapper .tab-btn:hover,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .tabs-wrapper .tab-btn.active {
    background: #344151 !important;
    border-color: #5f7289 !important;
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .header-titles h2,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .kpi-card h3,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) .simulation-wrapper h3 {
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .header-titles p,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .kpi-card small,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .kpi-card span {
    color: #d5dee8 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .search-box,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .search-box input,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) input,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) select {
    background: #263240 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) label {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .modal-content {
    background: #303b48 !important;
    border: 1px solid #607187 !important;
    border-right: 0 !important;
    color: #f8fafc !important;
    box-shadow: -28px 0 70px rgba(2, 6, 23, 0.52) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-credito .modal-footer {
    background: #303b48 !important;
    border-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .modal-body {
    background: #303b48 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .flow-card {
    background: #263240 !important;
    border: 1px solid #607187 !important;
    color: #eaf2fb !important;
    opacity: 1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .flow-card.received {
    background: rgba(239, 68, 68, 0.1) !important;
    border-color: rgba(248, 113, 113, 0.45) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .flow-card.given {
    background: rgba(94, 234, 212, 0.1) !important;
    border-color: rgba(94, 234, 212, 0.42) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .flow-card span,
html[data-speas-theme="oscuro"] body.speas-app #modal-credito .flow-card small,
html[data-speas-theme="oscuro"] body.speas-app #modal-credito .form-subtitle,
html[data-speas-theme="oscuro"] body.speas-app #modal-credito label {
    color: #eaf2fb !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .input-group input,
html[data-speas-theme="oscuro"] body.speas-app #modal-credito .input-group select {
    background: #263240 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .input-group input::placeholder {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .input-group input:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-credito .input-group select:focus,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) input:focus,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) select:focus {
    border-color: #5eead4 !important;
    box-shadow: 0 0 0 4px rgba(94, 234, 212, 0.16) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .divider,
html[data-speas-theme="oscuro"] body.speas-app #modal-credito .form-subtitle,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) .simulation-wrapper h3 {
    border-color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .simulation-box,
html[data-speas-theme="oscuro"] body.speas-app #modal-credito .table-mini-wrapper,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) #sim-tab-resultado {
    background: rgba(38, 50, 64, 0.78) !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .modal-body,
html[data-speas-theme="oscuro"] body.speas-app #modal-credito .table-mini-wrapper,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .table-responsive,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) .table-responsive {
    scrollbar-width: thin !important;
    scrollbar-color: #5eead4 #263240 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .modal-body::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app #modal-credito .table-mini-wrapper::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .table-responsive::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) .table-responsive::-webkit-scrollbar {
    width: 10px !important;
    height: 10px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .modal-body::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app #modal-credito .table-mini-wrapper::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .table-responsive::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) .table-responsive::-webkit-scrollbar-track {
    background: #263240 !important;
    border-radius: 999px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-credito .modal-body::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app #modal-credito .table-mini-wrapper::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#tabla-creditos-body) .table-responsive::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app .module-container:has(#form-simulador-rapido) .table-responsive::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #5eead4, #38bdf8) !important;
    border: 2px solid #263240 !important;
    border-radius: 999px !important;
}

@media (min-width: 1600px) {
    body.speas-app #modal-credito .modal-content {
        width: min(48vw, 1080px) !important;
    }
}

@media (min-width: 721px) and (max-width: 1180px) {
    body.speas-app #modal-credito .modal-content {
        width: min(84vw, 900px) !important;
        min-width: 0 !important;
        max-width: calc(100vw - 24px) !important;
    }
}

@media (max-width: 720px) {
    body.speas-app .module-container:has(#tabla-creditos-body),
    body.speas-app .module-container:has(#form-simulador-rapido) {
        padding: 18px 16px 22px !important;
    }

    body.speas-app .module-container:has(#tabla-creditos-body) .module-header-tabs {
        padding: 18px !important;
    }

    body.speas-app .module-container:has(#tabla-creditos-body) .tabs-wrapper {
        min-width: 0 !important;
        width: 100% !important;
        display: grid !important;
        grid-template-columns: 1fr !important;
    }

    body.speas-app .module-container:has(#tabla-creditos-body) .table-toolbar {
        display: grid !important;
        grid-template-columns: 1fr !important;
        padding: 16px !important;
    }

    body.speas-app .module-container:has(#tabla-creditos-body) .search-box,
    body.speas-app .module-container:has(#tabla-creditos-body) .actions-box .btn-primary {
        width: 100% !important;
    }

    body.speas-app #modal-credito.modal-overlay.active {
        align-items: stretch !important;
        justify-content: flex-end !important;
        padding: 0 !important;
    }

    body.speas-app #modal-credito .modal-content {
        width: 100vw !important;
        min-width: 0 !important;
        max-width: 100vw !important;
        height: 100dvh !important;
        max-height: 100dvh !important;
        border-radius: 0 !important;
    }

    body.speas-app #modal-credito .modal-header,
    body.speas-app #modal-credito .modal-body,
    body.speas-app #modal-credito .modal-footer {
        padding-left: 20px !important;
        padding-right: 20px !important;
    }

    body.speas-app #modal-credito .flow-selector-container,
    body.speas-app #modal-credito .grid-row {
        grid-template-columns: 1fr !important;
    }

    body.speas-app #modal-credito .modal-footer {
        display: grid !important;
        grid-template-columns: 1fr !important;
    }
}

/* Speas global dark viewport scrollbar v52 */
html[data-speas-theme="oscuro"],
html[data-speas-theme="oscuro"] body {
    scrollbar-width: thin !important;
    scrollbar-color: #6f8197 #1f2a36 !important;
}

html[data-speas-theme="oscuro"]::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body::-webkit-scrollbar {
    width: 12px !important;
    height: 12px !important;
}

html[data-speas-theme="oscuro"]::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body::-webkit-scrollbar-track {
    background: #1f2a36 !important;
    border-left: 1px solid rgba(96, 113, 135, 0.38) !important;
}

html[data-speas-theme="oscuro"]::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #6f8197, #4f6074) !important;
    border: 3px solid #1f2a36 !important;
    border-radius: 999px !important;
}

html[data-speas-theme="oscuro"]::-webkit-scrollbar-thumb:hover,
html[data-speas-theme="oscuro"] body::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #5eead4, #38bdf8) !important;
}

html[data-speas-theme="oscuro"]::-webkit-scrollbar-corner,
html[data-speas-theme="oscuro"] body::-webkit-scrollbar-corner {
    background: #1f2a36 !important;
}

/* Speas clientes dark spacing and side modal polish v53 */
body.speas-app .table-module-container:has(#tabla-clientes-body) {
    padding: 26px 32px 30px !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) > .module-header {
    padding: 22px 26px !important;
    margin-bottom: 24px !important;
    border-radius: 14px !important;
    gap: 16px !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) > .module-header .header-titles {
    min-width: 260px !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) > .module-header h2 {
    margin: 0 0 8px !important;
    line-height: 1.18 !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) > .module-header p {
    margin: 0 !important;
    line-height: 1.45 !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) > .table-toolbar {
    padding: 20px !important;
    margin-bottom: 24px !important;
    border-radius: 14px !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) > .table-toolbar .search-box {
    min-height: 50px !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) > .table-responsive {
    border-radius: 14px !important;
    overflow: auto !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table th,
body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table td {
    padding: 16px 20px !important;
    vertical-align: middle !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table th:first-child,
body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table td:first-child {
    padding-left: 24px !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table th:last-child,
body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table td:last-child {
    padding-right: 24px !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) > .pagination {
    padding: 20px 0 0 !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) .kid-info {
    display: inline-flex !important;
    align-items: center !important;
    gap: 10px !important;
    min-width: 118px !important;
    padding: 8px 12px !important;
    border-radius: 10px !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) .kid-icon {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    border-radius: 999px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) .kid-name,
body.speas-app .table-module-container:has(#tabla-clientes-body) .client-contact span {
    line-height: 1.35 !important;
}

body.speas-app .table-module-container:has(#tabla-clientes-body) .badge-cat {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-height: 30px !important;
    padding: 7px 14px !important;
    border-radius: 999px !important;
    font-size: 12px !important;
    font-weight: 800 !important;
    letter-spacing: 0 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) {
    background: #2c3744 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) > .module-header,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) > .table-toolbar,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) > .table-responsive {
    background: #303b48 !important;
    border: 1px solid #607187 !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) > .module-header h2,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table td,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table td div[style*="color:#333"],
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table td div[style*="color: #333"] {
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) > .module-header p,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table th,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .page-info,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table td div[style*="color:#888"],
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table td div[style*="color: #888"],
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table td span[style*="color:#888"],
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table td span[style*="color: #888"] {
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .search-box,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .search-box input {
    background: #263240 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .search-box input::placeholder {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .search-box i,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .btn-icon i {
    color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table thead,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table th {
    background: #3a4859 !important;
    border-bottom: 1px solid #72849a !important;
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table td {
    background: #303b48 !important;
    border-bottom: 1px solid #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table tbody tr:hover td {
    background: #354253 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .kid-info {
    background: rgba(236, 72, 153, 0.12) !important;
    border: 1px solid rgba(244, 114, 182, 0.28) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .kid-icon {
    background: #ec4899 !important;
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .kid-name {
    color: #fdf2f8 !important;
    font-weight: 800 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .badge-cat,
html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .cat-nuevo {
    background: #dbeafe !important;
    color: #0b356d !important;
    border: 1px solid rgba(147, 197, 253, 0.65) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .cat-frecuente {
    background: #dcfce7 !important;
    color: #14532d !important;
    border-color: rgba(134, 239, 172, 0.65) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .cat-vip {
    background: #fef3c7 !important;
    color: #7c2d12 !important;
    border-color: rgba(251, 191, 36, 0.65) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .table-responsive {
    scrollbar-width: thin !important;
    scrollbar-color: #5eead4 #263240 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .table-responsive::-webkit-scrollbar {
    width: 10px !important;
    height: 10px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .table-responsive::-webkit-scrollbar-track {
    background: #263240 !important;
    border-radius: 999px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .table-module-container:has(#tabla-clientes-body) .table-responsive::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #5eead4, #38bdf8) !important;
    border: 2px solid #263240 !important;
    border-radius: 999px !important;
}

body.speas-app #modal-cliente.modal-overlay {
    align-items: stretch !important;
    justify-content: flex-end !important;
    padding: 0 !important;
}

body.speas-app #modal-cliente.modal-overlay.active {
    display: flex !important;
}

body.speas-app #modal-cliente .modal-content.slide-in-right {
    width: min(46vw, 920px) !important;
    min-width: 620px !important;
    max-width: calc(100vw - 32px) !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    border-radius: 18px 0 0 18px !important;
    display: grid !important;
    grid-template-rows: auto 1fr auto !important;
    overflow: hidden !important;
}

body.speas-app #modal-cliente .modal-header {
    padding: 28px 38px !important;
}

body.speas-app #modal-cliente .modal-body {
    padding: 28px 38px 34px !important;
    overflow: auto !important;
}

body.speas-app #modal-cliente .modal-footer {
    padding: 22px 38px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 14px !important;
}

body.speas-app #modal-cliente .row-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 16px !important;
}

body.speas-app #modal-cliente .input-group {
    margin-bottom: 18px !important;
}

body.speas-app #modal-cliente .input-group input,
body.speas-app #modal-cliente .input-group select {
    min-height: 54px !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

body.speas-app #modal-cliente .form-subtitle {
    margin: 24px 0 18px !important;
    padding-bottom: 10px !important;
    line-height: 1.2 !important;
    letter-spacing: 0.02em !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .modal-content.slide-in-right {
    background: #303b48 !important;
    border: 1px solid #607187 !important;
    border-right: 0 !important;
    color: #f8fafc !important;
    box-shadow: -28px 0 70px rgba(2, 6, 23, 0.52) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .modal-footer {
    background: #303b48 !important;
    border-color: #53657a !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .modal-body {
    background: #303b48 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .modal-header h3,
html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .form-subtitle {
    color: #ffffff !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .form-subtitle {
    border-bottom: 2px solid #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .input-group input,
html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .input-group select {
    background: #263240 !important;
    border: 1px solid #607187 !important;
    color: #f8fafc !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .input-group input[readonly] {
    background: #22303d !important;
    color: #cbd5e1 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .input-group input::placeholder {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .input-group input:focus,
html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .input-group select:focus {
    border-color: #5eead4 !important;
    box-shadow: 0 0 0 4px rgba(94, 234, 212, 0.16) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .input-group label,
html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .input-group label.static {
    background: #303b48 !important;
    color: #dbeafe !important;
    font-weight: 800 !important;
    text-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .input-group button[type="button"] {
    color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .btn-close {
    background: #344151 !important;
    border: 1px solid #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .btn-cancel {
    background: #344151 !important;
    border: 1px solid #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .modal-body {
    scrollbar-width: thin !important;
    scrollbar-color: #5eead4 #263240 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .modal-body::-webkit-scrollbar {
    width: 10px !important;
    height: 10px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .modal-body::-webkit-scrollbar-track {
    background: #263240 !important;
    border-radius: 999px !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .modal-body::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #5eead4, #38bdf8) !important;
    border: 2px solid #263240 !important;
    border-radius: 999px !important;
}

@media (min-width: 1600px) {
    body.speas-app #modal-cliente .modal-content.slide-in-right {
        width: min(44vw, 980px) !important;
    }
}

@media (min-width: 721px) and (max-width: 1180px) {
    body.speas-app #modal-cliente .modal-content.slide-in-right {
        width: min(84vw, 900px) !important;
        min-width: 0 !important;
        max-width: calc(100vw - 24px) !important;
    }

    body.speas-app .table-module-container:has(#tabla-clientes-body) {
        padding: 22px 24px 28px !important;
    }
}

@media (max-width: 720px) {
    body.speas-app .table-module-container:has(#tabla-clientes-body) {
        padding: 18px 16px 22px !important;
    }

    body.speas-app .table-module-container:has(#tabla-clientes-body) > .module-header {
        padding: 18px !important;
        align-items: stretch !important;
    }

    body.speas-app .table-module-container:has(#tabla-clientes-body) > .module-header .btn-primary {
        width: 100% !important;
    }

    body.speas-app .table-module-container:has(#tabla-clientes-body) > .table-toolbar {
        display: grid !important;
        grid-template-columns: 1fr auto !important;
        padding: 16px !important;
    }

    body.speas-app .table-module-container:has(#tabla-clientes-body) > .table-responsive {
        max-width: 100% !important;
    }

    body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table {
        min-width: 760px !important;
    }

    body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table th,
    body.speas-app .table-module-container:has(#tabla-clientes-body) .premium-table td {
        padding: 14px 16px !important;
    }

    body.speas-app #modal-cliente.modal-overlay.active {
        align-items: stretch !important;
        justify-content: flex-end !important;
        padding: 0 !important;
    }

    body.speas-app #modal-cliente .modal-content.slide-in-right {
        width: 100vw !important;
        min-width: 0 !important;
        max-width: 100vw !important;
        height: 100dvh !important;
        max-height: 100dvh !important;
        border-radius: 0 !important;
    }

    body.speas-app #modal-cliente .modal-header,
    body.speas-app #modal-cliente .modal-body,
    body.speas-app #modal-cliente .modal-footer {
        padding-left: 20px !important;
        padding-right: 20px !important;
    }

    body.speas-app #modal-cliente .row-grid {
        grid-template-columns: 1fr !important;
        gap: 0 !important;
    }

    body.speas-app #modal-cliente .modal-footer {
        display: grid !important;
        grid-template-columns: 1fr !important;
    }
}

/* Speas clientes fixed viewport modal scroll v54 */
body.speas-app #modal-cliente.modal-overlay,
body.speas-app #modal-cliente.modal-overlay.active {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    height: 100dvh !important;
    min-height: 100vh !important;
    min-height: 100dvh !important;
    max-height: 100vh !important;
    max-height: 100dvh !important;
    margin: 0 !important;
    overflow: hidden !important;
    align-items: stretch !important;
    justify-content: flex-end !important;
    z-index: 10000 !important;
    overscroll-behavior: contain !important;
}

body.speas-app #modal-cliente .modal-content.slide-in-right,
body.speas-app #modal-cliente.modal-overlay.active .modal-content.slide-in-right {
    position: relative !important;
    top: 0 !important;
    right: 0 !important;
    bottom: auto !important;
    left: auto !important;
    align-self: stretch !important;
    margin: 0 !important;
    height: 100vh !important;
    height: 100dvh !important;
    min-height: 100vh !important;
    min-height: 100dvh !important;
    max-height: 100vh !important;
    max-height: 100dvh !important;
    transform: none !important;
    overflow: hidden !important;
}

body.speas-app #modal-cliente .modal-header,
body.speas-app #modal-cliente .modal-footer {
    flex: 0 0 auto !important;
    position: relative !important;
    z-index: 2 !important;
}

body.speas-app #modal-cliente .modal-body {
    min-height: 0 !important;
    max-height: none !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    overscroll-behavior: contain !important;
    scrollbar-gutter: stable !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente.modal-overlay {
    background: rgba(7, 12, 19, 0.76) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-cliente .modal-body::-webkit-scrollbar-corner {
    background: #263240 !important;
}

@media (min-width: 721px) {
    body.speas-app #modal-cliente .modal-content.slide-in-right,
    body.speas-app #modal-cliente.modal-overlay.active .modal-content.slide-in-right {
        border-radius: 18px 0 0 18px !important;
    }
}

@media (max-width: 720px) {
    body.speas-app #modal-cliente .modal-content.slide-in-right,
    body.speas-app #modal-cliente.modal-overlay.active .modal-content.slide-in-right {
        border-radius: 0 !important;
    }
}

/* Speas clientes modal safe gutter and responsive form v55 */
body.speas-app #modal-cliente.modal-overlay,
body.speas-app #modal-cliente.modal-overlay.active {
    width: 100% !important;
    max-width: 100% !important;
}

body.speas-app #modal-cliente .modal-content.slide-in-right,
body.speas-app #modal-cliente.modal-overlay.active .modal-content.slide-in-right {
    box-sizing: border-box !important;
    max-width: calc(100dvw - 28px) !important;
    margin-right: 0 !important;
}

body.speas-app #modal-cliente .modal-body {
    box-sizing: border-box !important;
    padding-right: max(46px, calc(38px + env(safe-area-inset-right))) !important;
}

body.speas-app #modal-cliente #form-cliente,
body.speas-app #modal-cliente .input-group,
body.speas-app #modal-cliente .row-grid {
    max-width: 100% !important;
    box-sizing: border-box !important;
}

body.speas-app #modal-cliente .input-group input,
body.speas-app #modal-cliente .input-group select {
    max-width: 100% !important;
}

@media (min-width: 981px) and (max-width: 1180px) {
    body.speas-app #modal-cliente .modal-content.slide-in-right,
    body.speas-app #modal-cliente.modal-overlay.active .modal-content.slide-in-right {
        width: min(88vw, 900px) !important;
        max-width: calc(100dvw - 28px) !important;
    }
}

@media (min-width: 721px) and (max-width: 980px) {
    body.speas-app #modal-cliente .modal-content.slide-in-right,
    body.speas-app #modal-cliente.modal-overlay.active .modal-content.slide-in-right {
        width: min(90vw, 760px) !important;
        min-width: 0 !important;
        max-width: calc(100dvw - 28px) !important;
        border-radius: 18px 0 0 18px !important;
    }

    body.speas-app #modal-cliente .modal-header,
    body.speas-app #modal-cliente .modal-footer {
        padding-left: 30px !important;
        padding-right: 34px !important;
    }

    body.speas-app #modal-cliente .modal-body {
        padding-left: 30px !important;
        padding-right: 48px !important;
    }

    body.speas-app #modal-cliente .row-grid {
        grid-template-columns: 1fr !important;
        gap: 0 !important;
    }
}

@media (max-width: 720px) {
    body.speas-app #modal-cliente .modal-content.slide-in-right,
    body.speas-app #modal-cliente.modal-overlay.active .modal-content.slide-in-right {
        max-width: 100dvw !important;
    }

    body.speas-app #modal-cliente .modal-body {
        padding-right: max(28px, calc(20px + env(safe-area-inset-right))) !important;
    }
}

/* Speas admin dark modules spacing pass v56 */
html[data-speas-theme="oscuro"] body.speas-app,
html[data-speas-theme="oscuro"] body.speas-app * {
    scrollbar-width: thin;
    scrollbar-color: #5eead4 #1d2733;
}

html[data-speas-theme="oscuro"] body.speas-app ::-webkit-scrollbar {
    width: 11px;
    height: 11px;
}

html[data-speas-theme="oscuro"] body.speas-app ::-webkit-scrollbar-track {
    background: #1d2733;
    border-radius: 999px;
}

html[data-speas-theme="oscuro"] body.speas-app ::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #5eead4 0%, #38bdf8 100%);
    border: 3px solid #1d2733;
    border-radius: 999px;
}

html[data-speas-theme="oscuro"] body.speas-app ::-webkit-scrollbar-corner {
    background: #1d2733;
}

body.speas-app .crm-container,
body.speas-app .analytics-container,
body.speas-app .control-container,
body.speas-app .config-container,
body.speas-app .profile-container-premium {
    box-sizing: border-box;
    width: 100%;
}

body.speas-app .crm-container,
body.speas-app .analytics-container,
body.speas-app .control-container {
    padding: clamp(18px, 2vw, 32px) !important;
    gap: 22px !important;
}

body.speas-app .config-container,
body.speas-app .profile-container-premium {
    padding: clamp(18px, 2.2vw, 34px) !important;
}

body.speas-app .crm-container .module-header,
body.speas-app .analytics-container .module-header,
body.speas-app .control-container .control-header,
body.speas-app .config-container .module-header {
    padding: clamp(20px, 1.8vw, 30px) !important;
    margin: 0 0 22px !important;
    border: 1px solid var(--speas-border) !important;
    border-radius: 18px !important;
}

body.speas-app .crm-container .header-left,
body.speas-app .analytics-container .title-wrapper,
body.speas-app .control-container .control-header,
body.speas-app .config-container .module-header > div {
    min-width: 0;
}

body.speas-app .crm-container h2,
body.speas-app .analytics-container h2,
body.speas-app .control-container h2,
body.speas-app .config-container h2,
body.speas-app .profile-container-premium h2,
body.speas-app .profile-container-premium h3 {
    color: var(--speas-text) !important;
    text-shadow: none !important;
}

body.speas-app .crm-container p,
body.speas-app .analytics-container p,
body.speas-app .control-container p,
body.speas-app .config-container p,
body.speas-app .profile-container-premium p {
    color: var(--speas-muted) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .crm-container,
html[data-speas-theme="oscuro"] body.speas-app .analytics-container,
html[data-speas-theme="oscuro"] body.speas-app .control-container,
html[data-speas-theme="oscuro"] body.speas-app .config-container,
html[data-speas-theme="oscuro"] body.speas-app .profile-container-premium {
    background: transparent !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .crm-container .module-header,
html[data-speas-theme="oscuro"] body.speas-app .analytics-container .module-header,
html[data-speas-theme="oscuro"] body.speas-app .control-container .control-header,
html[data-speas-theme="oscuro"] body.speas-app .config-container .module-header {
    background: #2d3846 !important;
    border-color: #52667d !important;
}

/* CRM / Leads */
body.speas-app .crm-container .header-actions {
    gap: 14px !important;
    flex-wrap: wrap !important;
}

body.speas-app .crm-container .table-responsive {
    min-height: 360px;
    border: 1px solid var(--speas-border) !important;
    border-radius: 18px !important;
    overflow: auto !important;
}

body.speas-app .crm-container .crm-table th,
body.speas-app .crm-container .crm-table td {
    padding: 14px 16px !important;
    border-color: var(--speas-border) !important;
}

body.speas-app .crm-container .crm-table th {
    white-space: nowrap;
}

html[data-speas-theme="oscuro"] body.speas-app .crm-container .table-responsive,
html[data-speas-theme="oscuro"] body.speas-app .crm-container .crm-table,
html[data-speas-theme="oscuro"] body.speas-app .crm-container .crm-table tbody tr {
    background: #2d3846 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .crm-container .crm-table thead th {
    background: #3a4a5e !important;
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .crm-container .crm-table td,
html[data-speas-theme="oscuro"] body.speas-app .crm-container .crm-table td .client-name,
html[data-speas-theme="oscuro"] body.speas-app .crm-container .crm-table td .client-hijo,
html[data-speas-theme="oscuro"] body.speas-app .crm-container .crm-table td .cell-contact,
html[data-speas-theme="oscuro"] body.speas-app .crm-container .crm-table td .cell-date {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .crm-container .crm-table tbody tr:hover {
    background: #344458 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .crm-container .search-box input,
html[data-speas-theme="oscuro"] body.speas-app .crm-container select,
html[data-speas-theme="oscuro"] body.speas-app #modal-lead input,
html[data-speas-theme="oscuro"] body.speas-app #modal-lead select,
html[data-speas-theme="oscuro"] body.speas-app #modal-lead textarea {
    background: #243241 !important;
    border: 1px solid #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .crm-container .search-box input::placeholder,
html[data-speas-theme="oscuro"] body.speas-app #modal-lead input::placeholder,
html[data-speas-theme="oscuro"] body.speas-app #modal-lead textarea::placeholder {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .crm-container .btn-icon {
    background: #344458 !important;
    border-color: #607187 !important;
    color: #5eead4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-lead.modal-overlay {
    background: rgba(7, 12, 19, 0.76) !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-lead .slide-in-right {
    background: #303b48 !important;
    border-left: 1px solid #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-lead .modal-header,
html[data-speas-theme="oscuro"] body.speas-app #modal-lead .modal-footer {
    background: #344151 !important;
    border-color: #607187 !important;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-lead .modal-body {
    background: #303b48 !important;
    scrollbar-gutter: stable;
}

html[data-speas-theme="oscuro"] body.speas-app #modal-lead .form-group label {
    color: #dbeafe !important;
}

/* Analitica */
body.speas-app .analytics-container .summary-cards-grid,
body.speas-app .analytics-container .charts-grid {
    gap: clamp(18px, 1.7vw, 28px) !important;
}

body.speas-app .analytics-container .toolbar-container,
body.speas-app .analytics-container .chart-card,
body.speas-app .analytics-container .table-responsive-modern {
    box-sizing: border-box !important;
    max-width: 100% !important;
    border-radius: 18px !important;
    padding: clamp(18px, 1.6vw, 26px) !important;
    border: 1px solid var(--speas-border) !important;
}

body.speas-app .analytics-container .table-responsive-modern {
    overflow: auto !important;
    -webkit-overflow-scrolling: touch !important;
}

body.speas-app .analytics-container .premium-table {
    min-width: 780px !important;
}

body.speas-app .analytics-container .modern-input,
body.speas-app .analytics-container .modern-select {
    box-sizing: border-box !important;
    max-width: 100% !important;
}

body.speas-app .analytics-container canvas {
    display: block !important;
    max-width: 100% !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .toolbar-container,
html[data-speas-theme="oscuro"] body.speas-app .analytics-container .chart-card,
html[data-speas-theme="oscuro"] body.speas-app .analytics-container .table-responsive-modern,
html[data-speas-theme="oscuro"] body.speas-app .analytics-container .pagination-wrapper {
    background: #2d3846 !important;
    border-color: #52667d !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .chart-header {
    border-color: #52667d !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .chart-header h4,
html[data-speas-theme="oscuro"] body.speas-app .analytics-container .section-title,
html[data-speas-theme="oscuro"] body.speas-app .analytics-container .data-big,
html[data-speas-theme="oscuro"] body.speas-app .analytics-container .premium-table td {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .input-group label {
    color: #c7d2e3 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .modern-input,
html[data-speas-theme="oscuro"] body.speas-app .analytics-container .modern-select {
    background: #243241 !important;
    border-color: #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .premium-table thead {
    background: #3a4a5e !important;
    border-color: #607187 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .premium-table th {
    background: #3a4a5e !important;
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .premium-table td[style*="#64748b"] {
    color: #c7d2e3 !important;
}

body.speas-app .analytics-container .pnl-pill {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-width: 96px !important;
    padding: 7px 12px !important;
    border-radius: 9px !important;
    font-size: 14px !important;
    font-weight: 800 !important;
    line-height: 1.15 !important;
    white-space: nowrap !important;
}

body.speas-app .analytics-container .pnl-pill.pnl-positive {
    background: #dcfce7 !important;
    border: 1px solid #bbf7d0 !important;
    color: #166534 !important;
}

body.speas-app .analytics-container .pnl-pill.pnl-negative {
    background: #fee2e2 !important;
    border: 1px solid #fecaca !important;
    color: #b91c1c !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .pnl-pill.pnl-positive {
    background: rgba(34, 197, 94, 0.16) !important;
    border-color: rgba(74, 222, 128, 0.42) !important;
    color: #86efac !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .pnl-pill.pnl-negative {
    background: rgba(248, 113, 113, 0.16) !important;
    border-color: rgba(248, 113, 113, 0.42) !important;
    color: #fecaca !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .page-info,
html[data-speas-theme="oscuro"] body.speas-app .analytics-container .page-info strong {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .pagi-btn {
    background: #344458 !important;
    border: 1px solid #607187 !important;
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .pagi-btn:disabled {
    background: #2b3745 !important;
    color: #7f8da0 !important;
    border-color: #52667d !important;
    opacity: 0.65 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .pagi-divider {
    background: #607187 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .analytics-container .premium-table tr:hover td {
    background: #344458 !important;
}

/* Auditoria */
body.speas-app .control-container .control-actions,
body.speas-app .control-container .audit-filters,
body.speas-app .control-container .audit-pagination {
    gap: 14px !important;
    flex-wrap: wrap !important;
}

body.speas-app .control-container .audit-panel {
    padding: clamp(18px, 1.8vw, 28px) !important;
    border-radius: 18px !important;
    border: 1px solid var(--speas-border) !important;
}

body.speas-app .control-container .audit-filters {
    padding: 18px !important;
    border-radius: 16px !important;
}

body.speas-app .control-container .table-wrap-control {
    border-radius: 16px !important;
    overflow: auto !important;
    border: 1px solid var(--speas-border) !important;
}

body.speas-app .control-container .table-wrap-control th,
body.speas-app .control-container .table-wrap-control td {
    padding: 13px 14px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .control-container .audit-panel,
html[data-speas-theme="oscuro"] body.speas-app .control-container .audit-filters,
html[data-speas-theme="oscuro"] body.speas-app .control-container .table-wrap-control {
    background: #2d3846 !important;
    border-color: #52667d !important;
}

html[data-speas-theme="oscuro"] body.speas-app .control-container .filter-field label,
html[data-speas-theme="oscuro"] body.speas-app .control-container .audit-summary {
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .control-container input,
html[data-speas-theme="oscuro"] body.speas-app .control-container select {
    background: #243241 !important;
    border: 1px solid #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .control-container th {
    background: #3a4a5e !important;
    color: #dbeafe !important;
}

/* Configuracion */
body.speas-app .config-container {
    max-width: min(1380px, 100%) !important;
}

body.speas-app .config-container .grid-layout {
    gap: 26px !important;
}

body.speas-app .config-container .card-block,
body.speas-app .config-container .full-width-card,
body.speas-app .config-container .sedes-list-card,
body.speas-app .config-container .sede-form-card {
    padding: clamp(22px, 1.8vw, 32px) !important;
    border-radius: 18px !important;
    border: 1px solid var(--speas-border) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .card-block,
html[data-speas-theme="oscuro"] body.speas-app .config-container .full-width-card,
html[data-speas-theme="oscuro"] body.speas-app .config-container .sedes-list-card,
html[data-speas-theme="oscuro"] body.speas-app .config-container .sede-form-card {
    background: #2d3846 !important;
    border-color: #52667d !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .card-block h3,
html[data-speas-theme="oscuro"] body.speas-app .config-container .user-table td,
html[data-speas-theme="oscuro"] body.speas-app .config-container .user-table td strong {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .card-block h3,
html[data-speas-theme="oscuro"] body.speas-app .config-container .form-actions {
    border-color: #52667d !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .input-group input,
html[data-speas-theme="oscuro"] body.speas-app .config-container .input-group select,
html[data-speas-theme="oscuro"] body.speas-app .config-container .search-box-simple input {
    background-color: #243241 !important;
    border: 1px solid #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .input-group input::placeholder,
html[data-speas-theme="oscuro"] body.speas-app .config-container .search-box-simple input::placeholder {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .input-group label,
html[data-speas-theme="oscuro"] body.speas-app .config-container .input-group label.static,
html[data-speas-theme="oscuro"] body.speas-app .config-container .input-group input:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app .config-container .input-group input:not(:placeholder-shown) ~ label,
html[data-speas-theme="oscuro"] body.speas-app .config-container .input-group select:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app .config-container .input-group select:valid ~ label {
    background: #2d3846 !important;
    color: #dbeafe !important;
    text-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .table-responsive,
html[data-speas-theme="oscuro"] body.speas-app .config-container .user-table {
    background: #2d3846 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .user-table thead th {
    background: #3a4a5e !important;
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .user-table td {
    border-color: #52667d !important;
}

body.speas-app .config-container .selected-row {
    box-shadow: inset 4px 0 0 #4de1d2 !important;
}

body.speas-app .config-container .salon-section-toolbar {
    align-items: center !important;
    gap: 18px !important;
    margin-bottom: 18px !important;
}

body.speas-app .config-container .salon-sede-selector {
    width: min(360px, 100%) !important;
    min-width: 260px !important;
    margin-bottom: 0 !important;
}

body.speas-app .config-container .salon-sede-selector select {
    min-height: 48px !important;
    padding-right: 46px !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    cursor: pointer !important;
}

body.speas-app .config-container .salon-sede-arrow {
    position: absolute !important;
    right: 16px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    color: #64748b !important;
    font-size: 1.35rem !important;
    pointer-events: none !important;
    transition: color 0.18s ease, transform 0.18s ease !important;
}

body.speas-app .config-container .salon-sede-selector:focus-within .salon-sede-arrow {
    color: #14b8a6 !important;
    transform: translateY(-50%) rotate(180deg) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .salon-sede-arrow {
    color: #8fe7dc !important;
}

body.speas-app .config-container .is-panel-focus {
    animation: speasPanelFocus 1.15s ease-out 1;
}

@keyframes speasPanelFocus {
    0% { box-shadow: 0 0 0 0 rgba(77, 225, 210, 0.45); }
    55% { box-shadow: 0 0 0 8px rgba(77, 225, 210, 0.18); }
    100% { box-shadow: 0 0 0 0 rgba(77, 225, 210, 0); }
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .selected-row {
    background: rgba(77, 225, 210, 0.08) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .muted-line,
html[data-speas-theme="oscuro"] body.speas-app .config-container .section-toolbar p {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .status-pill.active {
    background: rgba(34, 197, 94, 0.18) !important;
    color: #86efac !important;
    border: 1px solid rgba(74, 222, 128, 0.35) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .status-pill.inactive {
    background: rgba(248, 113, 113, 0.16) !important;
    color: #fecaca !important;
    border: 1px solid rgba(248, 113, 113, 0.35) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .role-tag,
html[data-speas-theme="oscuro"] body.speas-app .config-container .role-colab,
html[data-speas-theme="oscuro"] body.speas-app .config-container .role-logis {
    background: rgba(219, 234, 254, 0.11) !important;
    color: #dbeafe !important;
    border: 1px solid rgba(147, 197, 253, 0.22) !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .table-responsive::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app .config-container .sedes-admin-table::-webkit-scrollbar,
html[data-speas-theme="oscuro"] body.speas-app .config-container .salones-admin-table::-webkit-scrollbar {
    width: 10px !important;
    height: 10px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .table-responsive::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app .config-container .sedes-admin-table::-webkit-scrollbar-track,
html[data-speas-theme="oscuro"] body.speas-app .config-container .salones-admin-table::-webkit-scrollbar-track {
    background: #1f2b37 !important;
    border-radius: 999px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .table-responsive::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app .config-container .sedes-admin-table::-webkit-scrollbar-thumb,
html[data-speas-theme="oscuro"] body.speas-app .config-container .salones-admin-table::-webkit-scrollbar-thumb {
    background: #4de1d2 !important;
    border-radius: 999px !important;
    border: 2px solid #1f2b37 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .btn-action-mini {
    background: #344458 !important;
    border: 1px solid #52667d !important;
    color: #dbeafe !important;
}

html[data-speas-theme="oscuro"] body.speas-app .config-container .btn-action-mini:hover {
    border-color: #4de1d2 !important;
    color: #4de1d2 !important;
}

/* Perfil */
body.speas-app .profile-container-premium {
    max-width: min(1500px, 100%) !important;
    grid-template-columns: minmax(300px, 370px) minmax(0, 1fr) !important;
}

body.speas-app .profile-sidebar-card,
body.speas-app .profile-content-card {
    border: 1px solid var(--speas-border) !important;
    border-radius: 20px !important;
}

html[data-speas-theme="oscuro"] body.speas-app .profile-sidebar-card,
html[data-speas-theme="oscuro"] body.speas-app .profile-content-card {
    background: #2d3846 !important;
    border-color: #52667d !important;
    box-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .profile-avatar-section,
html[data-speas-theme="oscuro"] body.speas-app .profile-stats .stat-item,
html[data-speas-theme="oscuro"] body.speas-app .profile-content-card .card-header,
html[data-speas-theme="oscuro"] body.speas-app .profile-content-card .form-actions {
    border-color: #52667d !important;
}

html[data-speas-theme="oscuro"] body.speas-app .profile-sidebar-card .stat-item .label,
html[data-speas-theme="oscuro"] body.speas-app .profile-content-card .card-header p {
    color: #c7d2e3 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .profile-sidebar-card .stat-item .value,
html[data-speas-theme="oscuro"] body.speas-app .profile-avatar-section h2,
html[data-speas-theme="oscuro"] body.speas-app .profile-content-card .card-header h3 {
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .profile-content-card .input-group input,
html[data-speas-theme="oscuro"] body.speas-app .profile-content-card .input-group select {
    background: #243241 !important;
    border: 1px solid #607187 !important;
    color: #f8fafc !important;
}

html[data-speas-theme="oscuro"] body.speas-app .profile-content-card .input-group input::placeholder {
    color: #9fb0c4 !important;
}

html[data-speas-theme="oscuro"] body.speas-app .profile-content-card .input-group label,
html[data-speas-theme="oscuro"] body.speas-app .profile-content-card .input-group label.static,
html[data-speas-theme="oscuro"] body.speas-app .profile-content-card .input-group input:focus ~ label,
html[data-speas-theme="oscuro"] body.speas-app .profile-content-card .input-group input:not(:placeholder-shown) ~ label,
html[data-speas-theme="oscuro"] body.speas-app .profile-content-card .input-group select:focus ~ label {
    background: #2d3846 !important;
    color: #dbeafe !important;
    text-shadow: none !important;
}

html[data-speas-theme="oscuro"] body.speas-app .profile-content-card .readonly-input {
    background: #202c38 !important;
    color: #c7d2e3 !important;
}

@media (max-width: 1180px) {
    body.speas-app .crm-container .module-header,
    body.speas-app .analytics-container .module-header,
    body.speas-app .control-container .control-header,
    body.speas-app .config-container .module-header {
        align-items: flex-start !important;
    }

    body.speas-app .analytics-container .filters-wrapper,
    body.speas-app .analytics-container .actions-wrapper,
    body.speas-app .control-container .audit-filters {
        width: 100% !important;
    }

    body.speas-app .profile-container-premium {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 780px) {
    body.speas-app .crm-container,
    body.speas-app .analytics-container,
    body.speas-app .control-container,
    body.speas-app .config-container,
    body.speas-app .profile-container-premium {
        padding: 16px !important;
    }

    body.speas-app .crm-container .module-header,
    body.speas-app .analytics-container .module-header,
    body.speas-app .control-container .control-header,
    body.speas-app .config-container .module-header {
        padding: 18px !important;
    }

    body.speas-app .crm-container .header-actions,
    body.speas-app .analytics-container .toolbar-container,
    body.speas-app .analytics-container .filters-wrapper,
    body.speas-app .analytics-container .actions-wrapper,
    body.speas-app .config-container .form-row,
    body.speas-app .profile-container-premium .form-grid-row {
        display: grid !important;
        grid-template-columns: 1fr !important;
        width: 100% !important;
    }

    body.speas-app .crm-container .search-box,
    body.speas-app .analytics-container .modern-input,
    body.speas-app .analytics-container .modern-select,
    body.speas-app .config-container .search-box-simple {
        width: 100% !important;
        min-width: 0 !important;
    }

    body.speas-app .config-container .salon-section-toolbar {
        align-items: stretch !important;
    }

    body.speas-app .config-container .salon-sede-selector {
        width: 100% !important;
        min-width: 0 !important;
    }

    body.speas-app .analytics-container .charts-grid {
        grid-template-columns: 1fr !important;
    }

    body.speas-app .analytics-container .chart-body {
        height: 360px !important;
    }

    body.speas-app .config-container .grid-layout {
        grid-template-columns: 1fr !important;
        grid-template-areas: "photo" "info" "security" !important;
    }
}

/* Speas enterprise density v62 */
@media (min-width: 769px) {
    :root {
        --sidebar-width: 232px;
        --sidebar-close-width: 70px;
        --speas-input-h: 32px;
        --speas-topbar-h: 46px;
    }

    html {
        font-size: 13px;
    }

    body.speas-app {
        font-size: 12px !important;
    }

    body.speas-app .home {
        padding: 9px 14px 14px !important;
    }

    body.speas-app .header-text {
        min-height: var(--speas-topbar-h) !important;
        margin-bottom: 8px !important;
        padding: 0 10px 0 12px !important;
        border-radius: 10px !important;
    }

    body.speas-app #titulo-modulo,
    body.speas-app .home .text {
        font-size: 16px !important;
        line-height: 1.15 !important;
    }

    body.speas-app .speas-top-search {
        width: min(300px, 24vw) !important;
        height: 32px !important;
    }

    body.speas-app .speas-top-search input {
        font-size: 12px !important;
        height: 30px !important;
    }

    body.speas-app .speas-theme-switch {
        height: 32px !important;
    }

    body.speas-app .speas-theme-btn {
        width: 30px !important;
        height: 28px !important;
    }

    body.speas-app .sidebar {
        padding-top: 9px !important;
    }

    body.speas-app .sidebar header {
        margin-bottom: 8px !important;
    }

    body.speas-app .sidebar .image-text {
        min-height: 46px !important;
    }

    body.speas-app .sidebar .image .logo-icon {
        width: 36px !important;
        height: 36px !important;
        border-radius: 10px !important;
        font-size: 25px !important;
    }

    body.speas-app .sidebar li {
        height: 36px !important;
        margin-top: 3px !important;
    }

    body.speas-app .sidebar li .icon {
        font-size: 17px !important;
    }

    body.speas-app .sidebar li .text {
        font-size: 12px !important;
    }

    body.speas-app .sidebar.close:not(:hover):not(.mobile-active) .menu {
        padding: 0 10px 16px !important;
    }

    body.speas-app .sidebar.close:not(:hover):not(.mobile-active) li a {
        width: 44px !important;
        min-width: 44px !important;
        max-width: 44px !important;
    }

    body.speas-app .sidebar.close:not(:hover):not(.mobile-active) li .icon {
        width: 44px !important;
        flex-basis: 44px !important;
    }

    body.speas-app .profile-img {
        width: 34px !important;
        height: 34px !important;
        min-width: 34px !important;
    }

    body.speas-app .profile-card {
        padding: 9px 11px !important;
        margin-bottom: 8px !important;
    }

    body.speas-app .contenedor-modulo {
        font-size: 12px !important;
    }

    body.speas-app :is(input, select, textarea, button) {
        font-size: 12px;
    }

    body.speas-app :is(.btn, .btn-primary, .btn-secondary, .btn-excel, .action-btn, .cat-btn, .meta-pill, .status-pill) {
        min-height: 30px !important;
        padding-top: 6px !important;
        padding-bottom: 6px !important;
        font-size: 11.5px !important;
    }

    body.speas-app :is(.module-header, .control-header, .catalog-title-bar, .section-toolbar, .header-acciones, .toolbar-container) h1,
    body.speas-app :is(.module-header, .control-header, .catalog-title-bar, .section-toolbar, .header-acciones, .toolbar-container) h2,
    body.speas-app :is(.module-header, .control-header, .catalog-title-bar, .section-toolbar, .header-acciones, .toolbar-container) h3 {
        font-size: 16px !important;
        line-height: 1.2 !important;
    }

    body.speas-app :is(.module-header, .control-header, .catalog-title-bar, .section-toolbar, .header-acciones, .toolbar-container) p {
        font-size: 12px !important;
        line-height: 1.35 !important;
    }

    body.speas-app :is(table, .table-custom, .premium-table, .simple-table, .data-table) th,
    body.speas-app :is(table, .table-custom, .premium-table, .simple-table, .data-table) td {
        padding: 8px 10px !important;
        font-size: 12px !important;
        line-height: 1.28 !important;
    }

    body.speas-app :is(.status-badge, .status-pill, .badge, .chip, .role-tag, .method-badge) {
        font-size: 10.5px !important;
        padding: 4px 8px !important;
        min-height: 0 !important;
    }

    body.speas-app .pos-container {
        height: calc(100vh - 64px) !important;
        gap: 18px !important;
        padding-bottom: 6px !important;
    }

    body.speas-app .pos-catalog {
        padding: 18px !important;
        border-radius: 14px !important;
    }

    body.speas-app .catalog-header {
        gap: 11px !important;
        margin-bottom: 14px !important;
    }

    body.speas-app .catalog-title-bar h2 {
        font-size: 17px !important;
    }

    body.speas-app .catalog-title-bar p {
        font-size: 12px !important;
    }

    body.speas-app .search-bar input {
        min-height: 38px !important;
        padding: 9px 14px 9px 42px !important;
        border-radius: 10px !important;
        font-size: 12px !important;
    }

    body.speas-app .search-bar i {
        left: 14px !important;
        font-size: 17px !important;
    }

    body.speas-app .category-tabs {
        gap: 7px !important;
        padding-bottom: 4px !important;
    }

    body.speas-app .cat-btn {
        padding-left: 14px !important;
        padding-right: 14px !important;
        border-radius: 8px !important;
    }

    body.speas-app .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(145px, 1fr)) !important;
        gap: 14px !important;
        padding: 4px 8px 28px 4px !important;
    }

    body.speas-app .product-card {
        min-height: 122px !important;
        padding: 12px !important;
        gap: 8px !important;
        border-radius: 13px !important;
    }

    body.speas-app .product-icon {
        width: 38px !important;
        height: 38px !important;
        border-radius: 11px !important;
    }

    body.speas-app .product-icon i {
        font-size: 19px !important;
    }

    body.speas-app .product-name {
        font-size: 12.5px !important;
        line-height: 1.2 !important;
        height: 2.45em !important;
        margin-bottom: 5px !important;
    }

    body.speas-app .product-price {
        font-size: 15.5px !important;
        line-height: 1.1 !important;
    }

    body.speas-app .badge-stock {
        font-size: 10px !important;
        padding: 2px 7px !important;
    }

    body.speas-app .pos-ticket {
        width: 330px !important;
        border-radius: 14px !important;
    }

    body.speas-app .ticket-header {
        padding: 14px 16px !important;
        border-radius: 14px 14px 0 0 !important;
    }

    body.speas-app .ticket-icon {
        width: 30px !important;
        height: 30px !important;
        border-radius: 10px !important;
    }

    body.speas-app .ticket-header h3 {
        font-size: 14px !important;
    }

    body.speas-app .ticket-subtitle {
        font-size: 10.5px !important;
    }

    body.speas-app .ticket-items {
        padding: 16px !important;
    }

    body.speas-app .cart-item {
        margin-bottom: 11px !important;
        padding-bottom: 11px !important;
    }

    body.speas-app .item-info h4 {
        font-size: 12.5px !important;
    }

    body.speas-app .item-info p,
    body.speas-app .summary-row {
        font-size: 11.5px !important;
    }

    body.speas-app .qty-btn {
        width: 23px !important;
        height: 23px !important;
    }

    body.speas-app .item-total {
        font-size: 13px !important;
    }

    body.speas-app .ticket-footer {
        padding: 16px !important;
        border-radius: 0 0 14px 14px !important;
    }

    body.speas-app .summary-row.total {
        font-size: 16px !important;
        margin-top: 10px !important;
        padding-top: 10px !important;
    }

    body.speas-app .btn-checkout {
        padding: 11px !important;
        margin-top: 12px !important;
        border-radius: 10px !important;
        font-size: 12.5px !important;
    }
}

@media (min-width: 1440px) {
    body.speas-app .home {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }

    body.speas-app .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)) !important;
    }
}

/* Speas shell edge alignment v63 */
@media (min-width: 769px) {
    body.speas-app .home,
    body.speas-app .sidebar.close ~ .home,
    body.speas-app .sidebar.close:hover ~ .home {
        position: fixed !important;
        left: var(--sidebar-close-width) !important;
        right: 0 !important;
        width: auto !important;
        max-width: none !important;
        box-sizing: border-box !important;
    }

    body.speas-app .header-text,
    body.speas-app .contenedor-modulo {
        max-width: none !important;
    }
}

/* Speas global compact density v64 */
@media (min-width: 1024px) {
    :root {
        --sidebar-close-width: 64px;
        --speas-input-h: 30px;
        --speas-topbar-h: 40px;
        --speas-radius: 11px;
        --speas-radius-sm: 8px;
    }

    html {
        font-size: 12px;
    }

    body.speas-app {
        font-size: 11px !important;
    }

    body.speas-app .home {
        padding: 7px 11px 11px !important;
    }

    body.speas-app .header-text {
        min-height: 40px !important;
        margin-bottom: 7px !important;
        padding: 0 8px 0 10px !important;
        border-radius: 9px !important;
    }

    body.speas-app #titulo-modulo,
    body.speas-app .home .text {
        font-size: 14.5px !important;
        line-height: 1.1 !important;
    }

    body.speas-app .speas-top-search {
        width: min(270px, 22vw) !important;
        height: 29px !important;
        gap: 6px !important;
        padding: 0 8px !important;
        border-radius: 9px !important;
    }

    body.speas-app .speas-top-search i {
        font-size: 15px !important;
    }

    body.speas-app .speas-top-search input {
        height: 27px !important;
        font-size: 10.8px !important;
    }

    body.speas-app .speas-top-search span {
        padding: 1px 5px !important;
        font-size: 9.5px !important;
    }

    body.speas-app .speas-theme-switch {
        height: 29px !important;
        gap: 2px !important;
    }

    body.speas-app .speas-theme-btn {
        width: 26px !important;
        height: 25px !important;
    }

    body.speas-app .sidebar {
        padding-top: 7px !important;
    }

    body.speas-app .sidebar header {
        margin-bottom: 6px !important;
        padding-left: 7px !important;
        padding-right: 7px !important;
    }

    body.speas-app .sidebar .image-text {
        min-height: 40px !important;
    }

    body.speas-app .sidebar .image .logo-icon {
        width: 32px !important;
        height: 32px !important;
        border-radius: 9px !important;
        font-size: 22px !important;
    }

    body.speas-app .sidebar li {
        height: 32px !important;
        margin-top: 2px !important;
        padding-left: 7px !important;
        padding-right: 7px !important;
    }

    body.speas-app .sidebar li .icon {
        font-size: 15.5px !important;
    }

    body.speas-app .sidebar li .text {
        font-size: 11px !important;
    }

    body.speas-app .sidebar.close:not(:hover):not(.mobile-active) .menu {
        padding: 0 8px 12px !important;
    }

    body.speas-app .sidebar.close:not(:hover):not(.mobile-active) li a {
        width: 40px !important;
        min-width: 40px !important;
        max-width: 40px !important;
    }

    body.speas-app .sidebar.close:not(:hover):not(.mobile-active) li .icon {
        width: 40px !important;
        flex-basis: 40px !important;
    }

    body.speas-app .profile-img {
        width: 30px !important;
        height: 30px !important;
        min-width: 30px !important;
    }

    body.speas-app .profile-card {
        padding: 7px 8px !important;
        margin-bottom: 7px !important;
        border-radius: 10px !important;
    }

    body.speas-app .contenedor-modulo {
        font-size: 11px !important;
    }

    body.speas-app :is(.module-header, .page-header, .control-header, .catalog-title-bar, .section-toolbar, .toolbar-container, .header-acciones, .dashboard-hero, .dashboard-card, .card, .panel, .kpi-card, .metric-card, .summary-card, .table-container, .filters-card) {
        border-radius: 11px !important;
    }

    body.speas-app :is(.module-header, .page-header, .control-header, .section-toolbar, .toolbar-container, .header-acciones, .dashboard-hero) {
        padding: 12px 14px !important;
        margin-bottom: 10px !important;
    }

    body.speas-app :is(.card, .panel, .kpi-card, .metric-card, .summary-card, .table-container, .filters-card) {
        padding: 12px !important;
    }

    body.speas-app :is(.module-header, .page-header, .control-header, .catalog-title-bar, .section-toolbar, .toolbar-container, .header-acciones) h1,
    body.speas-app :is(.module-header, .page-header, .control-header, .catalog-title-bar, .section-toolbar, .toolbar-container, .header-acciones) h2,
    body.speas-app :is(.module-header, .page-header, .control-header, .catalog-title-bar, .section-toolbar, .toolbar-container, .header-acciones) h3,
    body.speas-app .contenedor-modulo h1,
    body.speas-app .contenedor-modulo h2 {
        font-size: 14.5px !important;
        line-height: 1.15 !important;
    }

    body.speas-app .contenedor-modulo h3 {
        font-size: 13px !important;
        line-height: 1.15 !important;
    }

    body.speas-app :is(.module-header, .page-header, .control-header, .catalog-title-bar, .section-toolbar, .toolbar-container, .header-acciones) p,
    body.speas-app .contenedor-modulo p,
    body.speas-app .muted-line {
        font-size: 10.8px !important;
        line-height: 1.3 !important;
    }

    body.speas-app :is(input, select, textarea) {
        min-height: 30px !important;
        padding-top: 6px !important;
        padding-bottom: 6px !important;
        font-size: 11px !important;
        border-radius: 8px !important;
    }

    body.speas-app textarea {
        min-height: 70px !important;
    }

    body.speas-app :is(button, .btn, .btn-primary, .btn-secondary, .btn-excel, .action-btn, .cat-btn, .meta-pill, .status-pill, .tab-btn, .filter-btn) {
        min-height: 28px !important;
        padding: 5px 10px !important;
        font-size: 10.8px !important;
        border-radius: 8px !important;
    }

    body.speas-app :is(table, .table-custom, .premium-table, .simple-table, .data-table) th,
    body.speas-app :is(table, .table-custom, .premium-table, .simple-table, .data-table) td {
        padding: 6px 8px !important;
        font-size: 11px !important;
        line-height: 1.22 !important;
    }

    body.speas-app :is(.status-badge, .status-pill, .badge, .chip, .role-tag, .method-badge) {
        font-size: 9.8px !important;
        padding: 3px 7px !important;
        border-radius: 7px !important;
    }

    body.speas-app :is(.stats-grid, .kpi-grid, .metrics-grid, .dashboard-grid, .charts-grid, .cards-grid, .quick-actions-grid) {
        gap: 10px !important;
    }

    body.speas-app :is(.pagination, .pagination-controls, .table-footer) {
        gap: 7px !important;
        font-size: 10.8px !important;
    }

    body.speas-app :is(.pagination button, .pagination-controls button) {
        width: 28px !important;
        height: 28px !important;
        min-height: 28px !important;
    }

    body.speas-app .modal-content,
    body.speas-app .side-modal,
    body.speas-app .drawer-modal {
        font-size: 11px !important;
    }

    body.speas-app .modal-header {
        padding: 12px 16px !important;
    }

    body.speas-app .modal-body {
        padding: 14px 16px !important;
    }

    body.speas-app .modal-footer {
        padding: 12px 16px !important;
    }

    body.speas-app .pos-container {
        height: calc(100vh - 54px) !important;
        gap: 14px !important;
    }

    body.speas-app .pos-catalog {
        padding: 14px !important;
        border-radius: 12px !important;
    }

    body.speas-app .catalog-header {
        gap: 9px !important;
        margin-bottom: 11px !important;
    }

    body.speas-app .search-bar input {
        min-height: 32px !important;
        padding: 7px 12px 7px 36px !important;
        font-size: 11px !important;
    }

    body.speas-app .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(126px, 1fr)) !important;
        gap: 11px !important;
        padding: 3px 6px 22px 3px !important;
    }

    body.speas-app .product-card {
        min-height: 104px !important;
        padding: 10px !important;
        gap: 6px !important;
        border-radius: 11px !important;
    }

    body.speas-app .product-icon {
        width: 32px !important;
        height: 32px !important;
        border-radius: 9px !important;
    }

    body.speas-app .product-icon i {
        font-size: 16px !important;
    }

    body.speas-app .product-name {
        font-size: 11px !important;
        height: 2.35em !important;
        margin-bottom: 3px !important;
    }

    body.speas-app .product-price {
        font-size: 13.5px !important;
    }

    body.speas-app .badge-stock {
        font-size: 9px !important;
        padding: 2px 6px !important;
    }

    body.speas-app .pos-ticket {
        width: 292px !important;
        border-radius: 12px !important;
    }

    body.speas-app .ticket-header,
    body.speas-app .ticket-items,
    body.speas-app .ticket-footer {
        padding: 12px !important;
    }

    body.speas-app .ticket-icon {
        width: 27px !important;
        height: 27px !important;
        border-radius: 8px !important;
    }

    body.speas-app .ticket-header h3 {
        font-size: 12.5px !important;
    }

    body.speas-app .ticket-subtitle {
        font-size: 9.5px !important;
    }

    body.speas-app .summary-row.total {
        font-size: 14px !important;
    }

    body.speas-app .btn-checkout {
        padding: 9px !important;
        font-size: 11px !important;
    }
}
