/* ================================================================
   Adminit — Login diseño dos columnas (nuevo_diseno/login.css)
   ================================================================ */

*, *::before, *::after {
    box-sizing: border-box;
}

html, body {
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    background: #ffffff !important;
    background-image: none !important;
}

body.login-page {
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, sans-serif;
}

/* ---------------------------------------------------------------
   Layout de dos columnas — fondo cubre toda la pantalla
   --------------------------------------------------------------- */
.login-layout {
    display: flex;
    min-height: 100vh;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
}

/* ---------------------------------------------------------------
   Panel izquierdo — solo estructura, el fondo lo da .login-layout
   --------------------------------------------------------------- */
.login-panel-left {
    flex: 0 0 58%;
    position: relative;
    background: transparent;
    min-height: 100vh;
    overflow: hidden;
}

/* Logo flotante entre las franjas diagonales */
.login-brand-wrap {
    position: absolute;
    bottom: 16%;
    left: 46%;
    display: flex;
    align-items: center;
    gap: 14px;
    white-space: nowrap;
    transform: rotate(-40deg);
    transform-origin: center center;
}

.login-brand-logo {
    height: 82px;
    width: auto;
    object-fit: contain;
}

.login-brand-text {
    font-size: 28px;
    font-weight: 700;
    color: #5a6a7a;
    letter-spacing: 0.5px;
    font-family: 'Segoe UI', sans-serif;
}

/* ---------------------------------------------------------------
   Panel derecho — transparente, la tarjeta flota sobre el fondo
   --------------------------------------------------------------- */
.login-panel-right {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px;
    background: transparent;
}

/* ---------------------------------------------------------------
   Tarjeta de login
   --------------------------------------------------------------- */
.login-card {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 28px rgba(30, 60, 100, 0.10);
    padding: 40px 36px 32px;
    width: 100%;
    max-width: 350px;
    text-align: center;
}

/* Ícono candado */
.login-card-icon-wrap {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: #29b6f6;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.login-card-icon-wrap i {
    color: #ffffff;
    font-size: 22px;
    line-height: 1;
}

/* Título */
.login-card-title {
    font-size: 22px;
    font-weight: 700;
    color: #1a2a3a;
    margin: 0 0 10px;
}

/* Subtítulo */
.login-card-subtitle {
    font-size: 13px;
    color: #6b7a8d;
    margin: 0 0 24px;
    line-height: 1.55;
}

/* ---------------------------------------------------------------
   Formulario
   --------------------------------------------------------------- */
.login-form {
    text-align: left;
}

/* Inputs */
.login-input,
.login-form input.login-input {
    display: block;
    width: 100%;
    height: 46px;
    border: 1.5px solid #4caf50 !important;
    border-radius: 6px !important;
    padding: 8px 14px !important;
    font-size: 14px !important;
    color: #2c3e50 !important;
    background: #ffffff !important;
    box-shadow: none !important;
    margin-bottom: 16px;
    transition: border-color 0.18s ease, box-shadow 0.18s ease;
    outline: none !important;
}

.login-input:focus,
.login-form input.login-input:focus {
    border-color: #2e7d32 !important;
    box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.15) !important;
}

.login-input::placeholder {
    color: #a0b4c8 !important;
    font-size: 13px !important;
}

/* Campo contraseña con label flotante */
.login-field-password {
    position: relative;
    margin-bottom: 16px;
}

.login-field-password .login-input {
    padding-top: 18px !important;
    margin-bottom: 0;
}

.login-float-label {
    position: absolute;
    top: 7px;
    left: 14px;
    font-size: 10px;
    font-weight: 600;
    color: #888;
    pointer-events: none;
    line-height: 1;
    z-index: 1;
    display: block;
}

/* Checkbox recuérdame */
.login-remember {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
    font-size: 13px;
    color: #4a5568;
}

.login-remember input[type="checkbox"] {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    cursor: pointer;
    margin: 0;
    accent-color: #4caf50;
}

.login-remember label {
    margin: 0;
    cursor: pointer;
    font-weight: 400;
}

/* Botón de ingresar */
.login-btn-submit {
    display: block;
    width: 100%;
    height: 46px;
    background: #4caf50 !important;
    border: none !important;
    border-radius: 6px !important;
    color: #ffffff !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    letter-spacing: 1.5px !important;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.18s ease, box-shadow 0.18s ease;
    box-shadow: 0 3px 12px rgba(76, 175, 80, 0.30) !important;
    margin-bottom: 4px;
}

.login-btn-submit:hover {
    background: #388e3c !important;
    box-shadow: 0 5px 18px rgba(76, 175, 80, 0.42) !important;
}

/* Links (olvidé contraseña / cliente) */
.login-links {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    font-size: 12.5px;
    text-align: center;
}

.login-links a {
    color: #1565c0;
    text-decoration: none;
    transition: color 0.15s ease;
}

.login-links a:hover {
    color: #0d47a1;
    text-decoration: underline;
}

/* Versión */
.login-version {
    margin-top: 20px;
    font-size: 11px;
    color: #a0aec0;
    text-align: center;
}

.login-version p {
    margin: 0;
}

/* Alertas */
.login-card .alert {
    text-align: left;
    font-size: 13px;
    border-radius: 6px;
    margin-bottom: 16px;
    padding: 10px 14px;
}

/* ---------------------------------------------------------------
   Responsive
   --------------------------------------------------------------- */

/* Mobile landscape / tablet pequeño: apila en columna */
@media (max-width: 768px) {
    .login-layout {
        flex-direction: column;
    }

    /* Ocultar panel izquierdo en mobile */
    .login-panel-left {
        display: none;
    }

    /* Formulario ocupa toda la pantalla */
    .login-panel-right {
        flex: 1;
        min-height: 100vh;
        padding: 40px 20px 32px;
        background: rgba(255, 255, 255, 0.95);
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .login-card {
        width: 100%;
        max-width: 420px;
        box-shadow: none;
        padding: 24px 20px 20px;
    }

    .login-input,
    .login-form input.login-input {
        height: 48px;
        font-size: 15px !important;
    }

    .login-btn-submit {
        height: 50px;
        font-size: 14px !important;
    }

    .login-remember input[type="checkbox"] {
        width: 18px;
        height: 18px;
    }
}

/* Mobile portrait */
@media (max-width: 480px) {
    .login-panel-left {
        height: 140px;
    }

    .login-brand-logo {
        height: 60px;
    }

    .login-card {
        max-width: 100%;
        padding: 20px 16px 16px;
    }

    .login-card-title {
        font-size: 20px;
    }

    .login-card-subtitle {
        font-size: 12px;
    }

    .login-links {
        font-size: 12px;
    }
}

/* Mobile muy pequeño */
@media (max-width: 360px) {
    .login-panel-left {
        height: 120px;
    }

    .login-brand-logo {
        height: 50px;
    }

    .login-card {
        padding: 16px 12px;
    }
}
