/* ==========================================================================
   ESTILOS APEX DARK LOGIN — SISTEMA ERP WINIE
   ========================================================================== */

:root {
    --color-bg-main: #090a0f;
    --color-bg-card: #13141c;
    --color-bg-card-header: #0f1016;
    --color-primary: #00e676;
    --color-accent: #00b0ff;
    --color-warning: #ffb74d;
    --color-danger: #ff5252;
    --color-text-main: #f8fafc;
    --color-text-muted: #94a3b8;
    --color-border: rgba(255, 255, 255, 0.08);
    --fuente-principal: 'Inter', system-ui, -apple-system, sans-serif;
}

body {
    min-height: 100vh;
    background-color: var(--color-bg-main);
    color: var(--color-text-main);
    font-family: var(--fuente-principal);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    padding: 20px;
    position: relative;
    overflow-x: hidden;
}

/* ─── FONDOS CON GLOW NEÓN ANIMADOS ────── */
body::before {
    content: '';
    position: absolute;
    top: -10%;
    left: -10%;
    width: 450px;
    height: 450px;
    background: radial-gradient(circle, rgba(0, 230, 118, 0.12) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
    animation: orbFloat 10s ease-in-out infinite alternate;
}

body::after {
    content: '';
    position: absolute;
    bottom: -10%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(0, 176, 255, 0.12) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
    animation: orbFloat 12s ease-in-out infinite alternate-reverse;
}

@keyframes orbFloat {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(30px, -20px) scale(1.1); }
    100% { transform: translate(-20px, 30px) scale(0.95); }
}

/* ─── CONTENEDOR LOGIN ────── */
.login-shell {
    width: 100%;
    max-width: 440px;
    position: relative;
    z-index: 1;
}

.login-card {
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: 20px;
    padding: 36px 32px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 30px rgba(0, 230, 118, 0.05);
    backdrop-filter: blur(16px);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.login-card:hover {
    border-color: rgba(255, 255, 255, 0.14);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6), 0 0 35px rgba(0, 230, 118, 0.08);
}

/* ─── LOGO Y ENCABEZADO APEX ────── */
.login-logo-block {
    text-align: center;
    margin-bottom: 28px;
}

.login-logo-badge {
    width: 62px;
    height: 62px;
    border-radius: 18px;
    background: linear-gradient(135deg, #00e676 0%, #00b0ff 100%);
    color: #090a0f;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    box-shadow: 0 10px 25px rgba(0, 230, 118, 0.3);
    margin-bottom: 14px;
}

.login-logo-text {
    font-size: 1.55rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -0.02em;
    margin-bottom: 2px;
}

.login-logo-text span {
    color: var(--color-primary);
}

.login-logo-sub {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* ─── CAMPOS DE FORMULARIO APEX ────── */
.login-label {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
    display: block;
}

.login-input-group {
    position: relative;
    margin-bottom: 20px;
}

.login-input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--color-text-muted);
    font-size: 1.15rem;
    transition: color 0.15s ease;
    pointer-events: none;
    z-index: 2;
}

.login-input {
    width: 100%;
    min-height: 48px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    padding: 10px 42px 10px 44px;
    color: #ffffff;
    font-size: 0.95rem;
    font-weight: 600;
    outline: none;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.login-input::placeholder {
    color: rgba(148, 163, 184, 0.5);
    font-weight: 400;
}

.login-input:focus {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(0, 230, 118, 0.15);
}

.login-input-group:focus-within .login-input-icon {
    color: var(--color-primary);
}

/* Botón Ojo Toggle Password */
.login-eye-btn {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: var(--color-text-muted);
    font-size: 1.15rem;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3;
    transition: color 0.15s ease;
}

.login-eye-btn:hover {
    color: #ffffff;
}

/* Enlace Olvidaste Contraseña */
.login-forgot-wrap {
    display: flex;
    justify-content: flex-end;
    margin-top: -10px;
    margin-bottom: 22px;
}

.login-forgot-link {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--color-accent);
    text-decoration: none;
    transition: color 0.15s ease;
}

.login-forgot-link:hover {
    color: var(--color-primary);
    text-decoration: underline;
}

/* ─── BOTÓN PRINCIPAL NEÓN ────── */
.btn-login-apex {
    width: 100%;
    min-height: 48px;
    background: linear-gradient(135deg, #00e676 0%, #00b0ff 100%);
    border: none;
    border-radius: 12px;
    color: #090a0f;
    font-weight: 800;
    font-size: 0.95rem;
    letter-spacing: 0.04em;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(0, 230, 118, 0.25);
    transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.btn-login-apex:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 28px rgba(0, 230, 118, 0.35);
    filter: brightness(1.05);
}

.btn-login-apex:active {
    transform: translateY(1px);
    box-shadow: 0 4px 12px rgba(0, 230, 118, 0.2);
}

/* ─── ALERTAS Y ERRORES APEX ────── */
.login-alert-danger {
    background: rgba(255, 82, 82, 0.1);
    border: 1px solid rgba(255, 82, 82, 0.25);
    color: #ff5252;
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.login-alert-success {
    background: rgba(0, 230, 118, 0.1);
    border: 1px solid rgba(0, 230, 118, 0.25);
    color: #00e676;
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.login-alert-warning {
    background: rgba(255, 183, 77, 0.1);
    border: 1px solid rgba(255, 183, 77, 0.25);
    color: #ffb74d;
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* BORDES ROJOS PARA CAMPOS INVÁLIDOS */
.login-input.is-invalid-apex {
    border-color: #ff5252 !important;
    background-color: rgba(255, 82, 82, 0.08) !important;
    box-shadow: 0 0 0 3px rgba(255, 82, 82, 0.2) !important;
}

.login-feedback-err {
    color: #ff5252;
    font-size: 0.76rem;
    font-weight: 600;
    margin-top: 5px;
    margin-left: 10px;
    display: none;
}

/* ─── PIE DE PÁGINA ────── */
.login-footer-text {
    text-align: center;
    margin-top: 24px;
    font-size: 0.78rem;
    color: var(--color-text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}
