/* ==========================================================================
   TPV Papelería y Librería - Hoja de Estilos Base Estática Anti-Distorsión
   Garantiza visualización instantánea y sin distorsión en PCs, Tablets y Celulares
   incluso sin conexión a Internet o en navegadores móviles antiguos.
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html, body {
    margin: 0;
    padding: 0;
    height: 100%;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    color: #1e293b;
}
[x-cloak], .hidden { display: none !important; }

/* Protección estricta contra íconos SVG gigantes en tablets y celulares */
svg {
    width: 1.25rem;
    height: 1.25rem;
    max-width: 100%;
    display: inline-block;
    vertical-align: middle;
    flex-shrink: 0;
}
svg.h-3, svg.w-3 { width: 0.75rem; height: 0.75rem; }
svg.h-3\.5, svg.w-3\.5 { width: 0.875rem; height: 0.875rem; }
svg.h-4, svg.w-4 { width: 1rem; height: 1rem; }
svg.h-5, svg.w-5 { width: 1.25rem; height: 1.25rem; }
svg.h-6, svg.w-6 { width: 1.5rem; height: 1.5rem; }
svg.h-7, svg.w-7 { width: 1.75rem; height: 1.75rem; }
svg.h-8, svg.w-8 { width: 2rem; height: 2rem; }
svg.h-10, svg.w-10 { width: 2.5rem; height: 2.5rem; }
img { max-width: 100%; height: auto; display: block; }

/* Estilos base garantizados para la Pantalla de Inicio de Sesión (Login) en Tablets y Móviles */
body.tpv-login-body {
    background: linear-gradient(135deg, #020617 0%, #1e1b4b 50%, #2e1065 100%);
    min-height: 100vh;
    color: #1e293b;
}
.tpv-login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    position: relative;
    z-index: 10;
}
.tpv-login-card {
    width: 100%;
    max-width: 56rem;
    border-radius: 1.5rem;
    overflow: hidden;
    background: #ffffff;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.55);
    display: flex;
    flex-direction: column;
}
@media (min-width: 1024px) {
    .tpv-login-card {
        flex-direction: row;
    }
    .tpv-login-left {
        width: 42%;
    }
    .tpv-login-right {
        width: 58%;
    }
}
.tpv-login-left {
    background: linear-gradient(135deg, #2563eb 0%, #4338ca 50%, #5b21b6 100%);
    color: #ffffff;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}
.tpv-login-logo-box {
    width: 100%;
    max-width: 240px;
    border-radius: 1.25rem;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.3);
    margin: 1rem auto;
    background: rgba(255, 255, 255, 0.1);
}
.tpv-login-logo-box img {
    width: 100%;
    height: auto;
    max-height: 180px;
    object-fit: contain;
    margin: 0 auto;
}
.tpv-login-right {
    background: #ffffff;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.tpv-login-form-box {
    width: 100%;
    max-width: 26rem;
    margin: 0 auto;
}
.tpv-input-group {
    position: relative;
    margin-bottom: 1rem;
}
.tpv-input {
    width: 100%;
    border-radius: 1rem;
    border: 1px solid #cbd5e1;
    background-color: #f8fafc;
    padding: 0.75rem 1rem 0.75rem 2.75rem;
    font-size: 0.925rem;
    color: #0f172a;
    outline: none;
}
.tpv-input:focus {
    border-color: #4f46e5;
    background-color: #ffffff;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
}
.tpv-btn-submit {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    border: none;
    border-radius: 1rem;
    background: linear-gradient(90deg, #2563eb 0%, #4f46e5 50%, #7c3aed 100%);
    color: #ffffff;
    padding: 0.875rem 1.25rem;
    font-size: 0.95rem;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 10px 15px -3px rgba(79, 70, 229, 0.3);
}
.tpv-btn-submit:hover {
    opacity: 0.95;
}

/* Utilidades estructurales base para el panel principal */
.flex { display: flex; }
.inline-flex { display: inline-flex; }
.grid { display: grid; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.flex-col { flex-direction: column; }
.flex-1 { flex: 1 1 0%; }
.w-full { width: 100%; }
.h-full { height: 100%; }
.relative { position: relative; }
.absolute { position: absolute; }
.fixed { position: fixed; }
.inset-0 { top: 0; right: 0; bottom: 0; left: 0; }
.overflow-hidden { overflow: hidden; }
.overflow-x-auto { overflow-x: auto; }
.overflow-y-auto { overflow-y: auto; }
table { width: 100%; border-collapse: collapse; }
a { text-decoration: none; }
