.error-modal-overlay {
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
}


.loader-mini {
    width: 84px !important;
    height: 20px !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: linear-gradient(90deg, #eef2f7 25%, #f8fafc 40%, #eef2f7 60%) !important;
    background-size: 400% 100% !important;
    background-position: 100% 0;
}


.stat-value.anim-skel {
    color: transparent !important;
    width: 64px;
    border-radius: 8px;
    background: linear-gradient(90deg, #eef2f7 25%, #f8fafc 40%, #eef2f7 60%);
    background-size: 400% 100%;
    background-position: 100% 0;
}


.anim-ink {
    position: absolute;
    left: 0;
    top: 0;
    z-index: 0;
    pointer-events: none;
    box-sizing: border-box;
    opacity: 0;
}

.anim-ink-pill {
    background: var(--active-primary-solid, #0f2c47);
    border-radius: 10px;
}

.anim-ink-nav {
    background: var(--active-primary-solid, #0f2c47);
    border-bottom: 3px solid #fff;
}

.anim-ink-ready > .anim-ink { opacity: 1; }
.anim-ink-ready > .tab,
.anim-ink-ready > .topbarLink { position: relative; z-index: 1; }

.anim-ink-ready > .tab.tab-active {
    background: transparent !important;
    border-color: transparent !important;
}

.anim-ink-ready > .topbarLink.active {
    background: transparent !important;
    border-bottom-color: transparent !important;
}


.footer-items.anim-acc {
    display: flex !important;
    overflow: hidden;
}

.footer-card:not(.expanded) .footer-items.anim-acc {
    margin-top: 0 !important;
}


#animToasts {
    position: fixed;
    top: 124px;
    right: 20px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
    width: min(380px, calc(100vw - 32px));
}

.anim-toast {
    pointer-events: auto;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: #fff;
    border: 1px solid #e7ebf2;
    border-left: 4px solid #1d84b5;
    border-radius: 12px;
    padding: 13px 16px;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.16);
    font-family: var(--base-font, inherit);
    font-size: 13.5px;
    font-weight: 500;
    line-height: 1.4;
    color: #0f172a;
    cursor: pointer;
    word-break: break-word;
}

.anim-toast i {
    font-size: 16px;
    margin-top: 1px;
    color: #1d84b5;
    flex-shrink: 0;
}

.anim-toast-ok { border-left-color: #16a34a; }
.anim-toast-ok i { color: #16a34a; }
.anim-toast-error { border-left-color: #dc2626; }
.anim-toast-error i { color: #dc2626; }

.anim-toast-out {
    opacity: 0;
    transform: translateX(16px);
    transition: opacity 0.22s ease, transform 0.22s ease;
}

@media screen and (max-width: 600px) {
    #animToasts {
        top: 12px;
        right: 16px;
        left: 16px;
        width: auto;
    }
}

/* Botones de Control: enviando / listo / error */
.anim-btn-busy {
    pointer-events: none;
    cursor: progress;
    opacity: 0.85;
}

.anim-btn-ok {
    background: #16a34a !important;
    border-color: #16a34a !important;
    color: #fff !important;
}

.anim-btn-err {
    background: #dc2626 !important;
    border-color: #dc2626 !important;
    color: #fff !important;
}

/* Login: codigo de 6 casilleros */
.anim-otp {
    position: relative;
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 6px;
}

.anim-otp-box {
    position: relative;
    flex: 1 1 0;
    max-width: 54px;
    height: 56px;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--base-font, inherit);
    font-size: 22px;
    font-weight: 700;
    color: #0f172a;
    text-transform: uppercase;
    box-sizing: border-box;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.anim-otp-box.is-filled {
    border-color: #94a3b8;
}

.anim-otp-box.is-active {
    border-color: #1d84b5;
    box-shadow: 0 0 0 3px rgba(29, 132, 181, 0.15);
}

.anim-otp.is-error .anim-otp-box {
    border-color: #dc2626;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.12);
}

.anim-otp.is-disabled .anim-otp-box {
    background: #f8fafc;
    color: #94a3b8;
}

.anim-otp-input {
    position: absolute !important;
    left: 0 !important;
    top: 0 !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    opacity: 0 !important;
    font-size: 16px !important;
    color: transparent !important;
    caret-color: transparent !important;
    background: transparent !important;
    z-index: 2;
    cursor: text;
}




body .footer-alerts {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
    width: 100%;
    min-width: 0;
    /* espacio para que la barra flotante "Actualizado" nunca
       tape la ultima tarjeta */
    margin-bottom: 96px !important;
}

body .footer-alerts *:not(i):not([class*="fa-"]),
body .error-modal-overlay,
body .error-modal-overlay *:not(i):not([class*="fa-"]) {
    font-family: var(--base-font, 'Sora', sans-serif) !important;
}

/* ---- Tarjeta ---- */
body .footer-alerts .footer-card {
    position: relative;
    background: #fff !important;
    border: 1px solid #e7ebf2 !important;
    border-radius: 14px !important;
    padding: 14px 18px !important;
    margin: 0 !important;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04) !important;
    box-sizing: border-box !important;
    width: 100% !important;
    overflow: hidden;
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

body .footer-alerts .footer-card::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: transparent;
    transition: background 0.2s ease;
}

body .footer-alerts .footer-card-errors.has-alerts::before { background: #dc2626; }
body .footer-alerts .footer-card-warnings.has-alerts::before { background: #f59e0b; }

body .footer-alerts .footer-card:hover {
    border-color: #dde4ee !important;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.06) !important;
}

body .footer-alerts .footer-card-head {
    display: flex !important;
    align-items: center !important;
    gap: 14px !important;
    padding: 0 !important;
    margin: 0 !important;
    cursor: pointer;
    user-select: none;
}

body .footer-alerts .footer-ico {
    width: 38px !important;
    height: 38px !important;
    border-radius: 10px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 15px !important;
    flex-shrink: 0 !important;
    margin: 0 !important;
}

body .footer-alerts .footer-card-errors .footer-ico { background: #fef2f2 !important; color: #dc2626 !important; }
body .footer-alerts .footer-card-warnings .footer-ico { background: #fffbeb !important; color: #d97706 !important; }
body .footer-alerts .footer-card:not(.has-alerts) .footer-ico { background: #f1f5f9 !important; color: #94a3b8 !important; }

body .footer-alerts .footer-card-title {
    font-size: 15px !important;
    font-weight: 700 !important;
    color: #0f172a !important;
    letter-spacing: -0.1px !important;
    line-height: 1.25 !important;
    margin: 0 !important;
    text-transform: none !important;
}

body .footer-alerts .footer-card-title span {
    font-weight: 700 !important;
    color: inherit !important;
}

body .footer-alerts .footer-card-sub {
    font-size: 12.5px !important;
    font-weight: 500 !important;
    color: #64748b !important;
    margin: 2px 0 0 0 !important;
    line-height: 1.35 !important;
    font-variant-numeric: tabular-nums;
}

body .footer-alerts .footer-chevron {
    margin-left: auto !important;
    font-size: 12px !important;
    color: #cbd5e1 !important;
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), color 0.2s ease !important;
}

body .footer-alerts .footer-card-head:hover .footer-chevron { color: #64748b !important; }
body .footer-alerts .footer-card.expanded .footer-chevron { transform: rotate(90deg) !important; }

/* ---- Lista ---- */
body .footer-alerts .footer-items {
    flex-direction: column !important;
    gap: 8px !important;
    width: 100% !important;
    padding: 0 !important;
}

body .footer-alerts .footer-card.expanded .footer-items {
    margin-top: 14px !important;
}

body .footer-alerts .error-item {
    background: #fff !important;
    border: 1px solid #eef1f6 !important;
    border-radius: 10px !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
    min-height: 0 !important;
    height: auto !important;
    box-sizing: border-box !important;
    box-shadow: none !important;
    overflow: hidden;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

body .footer-alerts .error-item:hover {
    border-color: #dbe3ee !important;
    background: #fbfcfe !important;
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.05) !important;
}

body .footer-alerts .error-main {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    padding: 10px 14px !important;
    margin: 0 !important;
    min-height: 0 !important;
    height: auto !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    cursor: pointer;
}

body .footer-alerts .error-code {
    display: inline-flex !important;
    align-items: center !important;
    gap: 7px !important;
    font-size: 12.5px !important;
    font-weight: 700 !important;
    letter-spacing: 0.2px !important;
    line-height: 1.3 !important;
    padding: 4px 10px !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 7px !important;
    box-shadow: none !important;
    background: #f1f5f9 !important;
    color: #0f172a !important;
    text-transform: none !important;
    white-space: nowrap;
}

body .footer-alerts .error-code::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
    flex-shrink: 0;
}

body .footer-alerts .footer-card-errors .error-code { background: #fef2f2 !important; color: #b91c1c !important; }
body .footer-alerts .footer-card-warnings .error-code { background: #fffbeb !important; color: #b45309 !important; }

body .footer-alerts .error-date {
    margin-left: auto !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    color: #94a3b8 !important;
    letter-spacing: 0.2px !important;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

body .footer-alerts .error-caret {
    margin-left: 4px !important;
    font-size: 10px !important;
    color: #cbd5e1 !important;
    transition: transform 0.2s ease, color 0.2s ease !important;
}

body .footer-alerts .error-item:hover .error-caret {
    color: #64748b !important;
    transform: translateX(3px);
}

/* ---- Ventana de detalle ---- */
body .error-modal-overlay {
    background: rgba(15, 23, 42, 0.45) !important;
    z-index: 1000 !important;
    /* Oculta SIEMPRE hasta que la pagina la abra (.open), aunque
       el CSS propio de la pagina todavia no haya cargado o una
       animacion intente mostrarla. */
    position: fixed !important;
    inset: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 20px !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transition: opacity 0.22s ease, visibility 0s linear 0.22s !important;
}

body .error-modal-overlay.open {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transition: opacity 0.22s ease, visibility 0s linear 0s !important;
}

body .error-modal {
    background: #fff !important;
    border: 0 !important;
    border-radius: 16px !important;
    padding: 0 !important;
    width: min(460px, calc(100vw - 32px)) !important;
    max-width: none !important;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.25) !important;
    overflow: hidden !important;
}

body .error-modal-head {
    display: flex !important;
    align-items: center !important;
    gap: 14px !important;
    padding: 18px 20px !important;
    margin: 0 !important;
    background: #fff !important;
    border-bottom: 1px solid #f1f5f9 !important;
}

body .error-modal-ico {
    width: 44px !important;
    height: 44px !important;
    border-radius: 12px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 18px !important;
    flex-shrink: 0 !important;
}

body .error-modal-ico.modal-error { background: #fef2f2 !important; color: #dc2626 !important; }
body .error-modal-ico.modal-warning { background: #fffbeb !important; color: #d97706 !important; }

body .error-modal-titles {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 5px !important;
    min-width: 0;
}

body .error-modal-code {
    font-size: 17px !important;
    font-weight: 700 !important;
    letter-spacing: -0.2px !important;
    color: #0f172a !important;
    line-height: 1.2 !important;
    background: none !important;
    border: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
}

body .error-modal-tag {
    display: inline-block !important;
    font-size: 10.5px !important;
    font-weight: 700 !important;
    letter-spacing: 0.6px !important;
    text-transform: uppercase !important;
    padding: 3px 9px !important;
    border-radius: 999px !important;
    background: #f1f5f9 !important;
    color: #475569 !important;
    margin: 0 !important;
}

body .error-modal-head:has(.modal-error) .error-modal-tag { background: #fef2f2 !important; color: #b91c1c !important; }
body .error-modal-head:has(.modal-warning) .error-modal-tag { background: #fffbeb !important; color: #b45309 !important; }

body .error-modal-close {
    margin-left: auto !important;
    width: 34px !important;
    height: 34px !important;
    border-radius: 9px !important;
    border: 0 !important;
    background: #f8fafc !important;
    color: #64748b !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 14px !important;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.15s ease, color 0.15s ease, transform 0.2s ease;
}

body .error-modal-close:hover {
    background: #f1f5f9 !important;
    color: #0f172a !important;
}

body .error-modal-body {
    padding: 18px 20px 20px !important;
    margin: 0 !important;
}

body .error-modal-desc {
    font-size: 14px !important;
    font-weight: 500 !important;
    line-height: 1.55 !important;
    color: #334155 !important;
    margin: 0 !important;
}

/* Datos extra que cada pagina agregue en el detalle */
body .error-modal-body > *:not(.error-modal-desc):not(.error-modal-meta) {
    font-size: 13px !important;
    line-height: 1.5 !important;
    color: #334155 !important;
}

body .error-modal-meta {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    margin: 14px 0 0 0 !important;
    padding-top: 12px !important;
    border-top: 1px dashed #e7ebf2 !important;
    font-size: 12.5px !important;
    font-weight: 500 !important;
    color: #64748b !important;
    font-variant-numeric: tabular-nums;
}

@media screen and (max-width: 600px) {
    body .footer-alerts .footer-card { padding: 12px 14px !important; }
    body .footer-alerts .error-main { padding: 9px 12px !important; gap: 10px !important; }
    body .footer-alerts .error-date { font-size: 11.5px !important; }
}

/* =========================================================
   MOVIMIENTO
   ========================================================= */

@media (prefers-reduced-motion: no-preference) {

    /* ---------- Keyframes ---------- */

    @keyframes anim-view-in {
        from { opacity: 0; transform: translateY(8px); }
        to   { opacity: 1; transform: none; }
    }

    @keyframes anim-rise {
        from { opacity: 0; transform: translateY(10px); }
        to   { opacity: 1; transform: none; }
    }

    @keyframes anim-fade-up {
        from { opacity: 0; transform: translateY(4px); }
        to   { opacity: 1; transform: none; }
    }

    @keyframes anim-shimmer {
        from { background-position: 100% 0; }
        to   { background-position: 0 0; }
    }

    @keyframes anim-ring-ok {
        0%   { transform: scale(1);   opacity: 0.55; }
        80%  { transform: scale(2.8); opacity: 0; }
        100% { transform: scale(2.8); opacity: 0; }
    }

    @keyframes anim-pulse-ring-red {
        0%   { box-shadow: 0 0 0 0 rgba(220, 38, 38, 0.38); }
        70%  { box-shadow: 0 0 0 9px rgba(220, 38, 38, 0); }
        100% { box-shadow: 0 0 0 0 rgba(220, 38, 38, 0); }
    }

    @keyframes anim-soft-blink {
        0%, 100% { opacity: 1; }
        50%      { opacity: 0.4; }
    }

    @keyframes anim-flash-ok {
        0%, 25% { background-color: rgba(22, 163, 74, 0.14); }
    }

    @keyframes anim-flash-error {
        0%, 25% { background-color: rgba(220, 38, 38, 0.14); }
    }

    @keyframes anim-flash-off {
        0%, 25% { background-color: rgba(100, 116, 139, 0.14); }
    }

    @keyframes anim-tick {
        0%   { background-color: rgba(29, 132, 181, 0.18); color: #1d84b5; }
        100% { background-color: rgba(29, 132, 181, 0); }
    }

    @keyframes anim-shake {
        0%, 100% { transform: translateX(0); }
        15%      { transform: translateX(-7px); }
        30%      { transform: translateX(6px); }
        45%      { transform: translateX(-5px); }
        60%      { transform: translateX(4px); }
        75%      { transform: translateX(-2px); }
    }

    @keyframes anim-toast-in {
        from { opacity: 0; transform: translateX(24px) scale(0.98); }
        to   { opacity: 1; transform: none; }
    }

    @keyframes anim-caret {
        0%, 100% { opacity: 1; }
        50%      { opacity: 0; }
    }

    @keyframes anim-busy-stripes {
        from { background-position: 0 0; }
        to   { background-position: 28px 0; }
    }

    /* ---------- Transicion entre vistas ---------- */

    #main.anim-view-in > *:not(.spinner-container):not(link):not(style):not(script):not(.error-modal-overlay):not([class*="modal"]):not([class*="overlay"]) {
        animation: anim-view-in 0.32s cubic-bezier(0.16, 1, 0.3, 1) both;
    }

    #main.anim-view-in .stat-card {
        animation: anim-rise 0.45s cubic-bezier(0.16, 1, 0.3, 1) both;
    }
    #main.anim-view-in .stat-card:nth-child(2) { animation-delay: 0.05s; }
    #main.anim-view-in .stat-card:nth-child(3) { animation-delay: 0.10s; }
    #main.anim-view-in .stat-card:nth-child(4) { animation-delay: 0.15s; }
    #main.anim-view-in .stat-card:nth-child(5) { animation-delay: 0.20s; }

    #main.anim-view-in .m-card,
    #main.anim-view-in .op-card,
    #main.anim-view-in .footer-card {
        animation: anim-rise 0.45s cubic-bezier(0.16, 1, 0.3, 1) both;
    }
    #main.anim-view-in .m-card:nth-child(2) { animation-delay: 0.04s; }
    #main.anim-view-in .m-card:nth-child(3) { animation-delay: 0.08s; }
    #main.anim-view-in .m-card:nth-child(4) { animation-delay: 0.12s; }
    #main.anim-view-in .m-card:nth-child(5) { animation-delay: 0.16s; }
    #main.anim-view-in .m-card:nth-child(6) { animation-delay: 0.20s; }

    /* Barra resumen de la maquina (aparece una vez) */
    #machineHeader {
        animation: anim-rise 0.4s cubic-bezier(0.16, 1, 0.3, 1) both;
    }

    /* Filas / tarjetas que entran escalonadas (la clase la pone anim.js) */
    .anim-row-in {
        animation: anim-fade-up 0.36s cubic-bezier(0.16, 1, 0.3, 1) both;
    }

    /* Sub-formularios de Control (Temperaturas / Compresores / ...) */
    [id^="divOp_"] > * {
        animation: anim-fade-up 0.25s ease both;
    }

    /* ---------- Esqueletos ---------- */

    .loader-mini {
        animation: anim-shimmer 1.2s linear infinite !important;
    }

    .stat-value.anim-skel {
        animation: anim-shimmer 1.2s linear infinite;
    }

    .conn-unknown {
        animation: anim-soft-blink 1.2s ease-in-out infinite;
    }

    /* ---------- Indicadores en vivo ---------- */

    #updateStatus .dot,
    .machine-indicator,
    .stat-refresh-state .fa-circle,
    .cp-gen-dot {
        position: relative;
    }

    #updateStatus.status-ok .dot::after,
    .machine-indicator.indicator-ok::after,
    .stat-refresh-state .fa-circle::after,
    .cp-gen-dot.cp-gen-ok::after {
        content: "";
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        height: 100%;
        border-radius: 50%;
        background: var(--success-color, #16a34a);
        animation: anim-ring-ok 2.2s cubic-bezier(0.2, 0.6, 0.4, 1) infinite;
        pointer-events: none;
    }

    .stat-refresh-state .fa-circle::after {
        width: 7px;
        height: 7px;
        top: 50%;
        margin-top: -3.5px;
    }

    /* Errores activos: late lento */
    .footer-card-errors.has-alerts .footer-ico,
    .machine-indicator.indicator-error,
    .cp-gen-dot.cp-gen-error {
        animation: anim-pulse-ring-red 2s ease-out infinite;
    }

    .conn-error,
    .cp-dot-error {
        animation: anim-soft-blink 1.8s ease-in-out infinite;
    }

    /* ---------- Destello al cambiar de estado ---------- */

    .anim-flash-ok    { animation: anim-flash-ok 1.6s ease-out; }
    .anim-flash-error { animation: anim-flash-error 1.6s ease-out; }
    .anim-flash-off   { animation: anim-flash-off 1.6s ease-out; }

    /* Valor que cambio en la pagina de la maquina */
    .anim-tick {
        border-radius: 4px;
        animation: anim-tick 1s ease-out;
    }

    /* ---------- Pestanas deslizantes ---------- */

    .anim-ink {
        transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
                    width 0.3s cubic-bezier(0.16, 1, 0.3, 1),
                    height 0.3s cubic-bezier(0.16, 1, 0.3, 1),
                    opacity 0.2s ease;
    }

    .anim-ink.anim-ink-instant {
        transition: none;
    }

    .anim-ink-ready > .tab {
        transition: color 0.2s ease 0.06s, border-color 0.2s ease, background 0.2s ease;
    }

    /* ---------- Acordeon ---------- */

    .footer-items.anim-acc {
        transition: max-height 0.34s cubic-bezier(0.16, 1, 0.3, 1),
                    opacity 0.25s ease,
                    margin-top 0.34s cubic-bezier(0.16, 1, 0.3, 1);
    }

    /* ---------- Ventana de detalle ---------- */

    .error-modal-overlay {
        transition: opacity 0.22s ease, -webkit-backdrop-filter 0.22s ease, backdrop-filter 0.22s ease;
    }

    /* ---------- Avisos ---------- */

    .anim-toast {
        animation: anim-toast-in 0.32s cubic-bezier(0.16, 1, 0.3, 1) both;
    }

    /* ---------- Botones de Control ---------- */

    .anim-btn-busy {
        background-image: linear-gradient(135deg, rgba(255,255,255,0.18) 25%, transparent 25%, transparent 50%, rgba(255,255,255,0.18) 50%, rgba(255,255,255,0.18) 75%, transparent 75%, transparent) !important;
        background-size: 28px 28px !important;
        animation: anim-busy-stripes 0.6s linear infinite;
    }

    .anim-btn-ok,
    .anim-btn-err {
        transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
    }

    .anim-shake {
        animation: anim-shake 0.45s cubic-bezier(0.36, 0.07, 0.19, 0.97);
    }

    /* ---------- Paneles de errores y advertencias ---------- */

    body .error-modal-overlay .error-modal {
        transform: translateY(10px) scale(0.97);
        transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1) !important;
    }

    body .error-modal-overlay.open .error-modal {
        transform: none;
    }

    body .error-modal-close:hover {
        transform: rotate(90deg);
    }

    .footer-card.anim-items-in .error-item {
        animation: anim-fade-up 0.3s cubic-bezier(0.16, 1, 0.3, 1) both;
    }
    .footer-card.anim-items-in .error-item:nth-child(2) { animation-delay: 0.03s; }
    .footer-card.anim-items-in .error-item:nth-child(3) { animation-delay: 0.06s; }
    .footer-card.anim-items-in .error-item:nth-child(4) { animation-delay: 0.09s; }
    .footer-card.anim-items-in .error-item:nth-child(5) { animation-delay: 0.12s; }
    .footer-card.anim-items-in .error-item:nth-child(6) { animation-delay: 0.15s; }
    .footer-card.anim-items-in .error-item:nth-child(n+7) { animation-delay: 0.18s; }

    /* ---------- Login ---------- */

    .login-card {
        animation: anim-rise 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
    }

    .login-left-content {
        animation: anim-view-in 0.7s cubic-bezier(0.16, 1, 0.3, 1) both;
    }

    .anim-otp-box.is-active.is-empty::after {
        content: "";
        position: absolute;
        width: 2px;
        height: 22px;
        border-radius: 2px;
        background: #1d84b5;
        animation: anim-caret 1s steps(1) infinite;
    }

    .anim-otp-box.is-pop {
        animation: anim-fade-up 0.18s ease;
    }
}

/* Sin animaciones: igual se ve el cursor en el casillero activo */
@media (prefers-reduced-motion: reduce) {
    .anim-otp-box.is-active.is-empty::after {
        content: "";
        position: absolute;
        width: 2px;
        height: 22px;
        background: #1d84b5;
    }
}
