:root {
    /* PALETA FERROSTOCK INDUSTRIAL */
    --primary-color: #D9232D;   /* Rojo herramienta (del logo) */
    --primary-dark: #B91C1C;    /* Rojo sangre seco para hover */
    --accent-color: #38BDF8;    /* Azul cian (chispa de soldadura) */
    --bg-dark: #0f172a;         /* Azul noche muy oscuro */
    --bg-card: rgba(30, 41, 59, 0.7); /* Gris azulado semitransparente */
    --text-white: #F8FAFC;
    --text-muted: #94A3B8;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    /* Fondo oscuro industrial con un degradado sutil */
    background: radial-gradient(circle at top right, #1e293b 0%, #0f172a 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    color: var(--text-white);
}

.login-container {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 20px;
}

.login-card {
    /* Efecto Cristal Ahumado (Dark Glassmorphism) */
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 3rem 2.5rem;
    border-radius: 24px;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    text-align: center;
    margin: 0 auto;
}

.logo-circle {
    /* Eliminamos cualquier fondo o borde del contenedor */
    background: transparent;
    width: 180px; 
    height: 180px;
    
    /* Centrado flex */
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    
    /* Sin sombras ni bordes */
    box-shadow: none;
    border: none;
    
    /* Filtro para dar un brillo sutil DETRÁS de la imagen (opcional) */
    filter: drop-shadow(0 0 15px rgba(217, 35, 45, 0.3)); 
}

/* Regla para asegurar que la imagen no tenga bordes forzados */
.logo-circle img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Muestra la imagen completa sin recortarla */
    border-radius: 0;    /* Elimina el redondeo forzado */
}

.login-header h2 { 
    margin: 0; 
    font-weight: 800; 
    font-size: 2rem; 
    letter-spacing: -0.5px;
    color: var(--text-white);
}

.login-header p { 
    margin: 8px 0 30px; 
    color: var(--text-muted); 
    font-size: 0.95rem; 
}

.input-group { text-align: left; margin-bottom: 1.5rem; }

.input-group label { 
    display: block; 
    font-size: 0.9rem; 
    margin-bottom: 8px; 
    font-weight: 600; 
    color: var(--text-muted);
    margin-left: 4px;
}

.input-group input {
    width: 100%;
    padding: 14px 16px;
    /* Inputs oscuros para mejor contraste */
    background: rgba(15, 23, 42, 0.6);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: var(--text-white);
    outline: none;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.input-group input::placeholder { color: rgba(255, 255, 255, 0.3); }

/* Foco con el color de la chispa (Cian) o Rojo */
.input-group input:focus {
    background: rgba(15, 23, 42, 0.9);
    border-color: var(--primary-color); 
    box-shadow: 0 0 0 4px rgba(217, 35, 45, 0.1);
}

.password-wrapper { position: relative; }

.toggle-password {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: var(--text-muted);
    transition: color 0.3s;
}
.toggle-password:hover { color: var(--text-white); }

.btn-login {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 12px;
    /* Botón Rojo Industrial */
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    font-weight: 700;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
    box-shadow: 0 4px 6px rgba(217, 35, 45, 0.2);
}

.btn-login:hover { 
    transform: translateY(-2px); 
    box-shadow: 0 10px 20px rgba(217, 35, 45, 0.3); 
    filter: brightness(1.1);
}

/* Botón de Instalación PWA - Estilo Metálico */
.btn-install {
    width: 100%;
    padding: 12px;
    margin-top: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    background: rgba(255,255,255,0.05);
    color: var(--text-white);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.3s ease;
}

.btn-install:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--text-white);
}

.login-footer { margin-top: 30px; font-size: 0.9rem; color: var(--text-muted); }
.login-footer a { 
    color: var(--accent-color); 
    text-decoration: none; 
    font-weight: 600; 
}
.login-footer a:hover { text-decoration: underline; }