/* Archivo: public/css/style.css */

:root {
    /* 🎨 COLORES CORPORATIVOS CODESS */
    --codess-primary: #003865;     /* Azul institucional CODESS (Barra superior y botones) */
    --codess-secondary: #005691;   /* Azul más claro (Al pasar el mouse por botones) */
    --codess-accent: #8CC63F;      /* Verde CODESS (Para mensajes de éxito) */
    --codess-danger: #dc2626;      /* Rojo (Para errores en el login) */
    
    /* Colores de fondo y texto generales */
    --bg-light: #f4f7f6;
    --bg-white: #ffffff;
    --text-dark: #2c3e50;
    --text-muted: #7f8c8d;
    --border-color: #e2e8f0;
}

/* --- ESTILOS GENERALES DEL SISTEMA --- */
body {
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
}

/* --- ESTILOS DEL LOGIN --- */
.login-wrapper {
    background: linear-gradient(135deg, var(--bg-light) 0%, #dbe6f6 100%);
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-card {
    background: var(--bg-white);
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    position: relative;
    width: 100%;
    max-width: 400px;
    padding: 20px;
    box-sizing: border-box;
}

.login-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 6px;
    background: var(--codess-primary);
}

.login-header {
    padding: 40px 30px 20px;
    text-align: center;
}

.login-header img {
    max-width: 180px;
    height: auto;
    margin-bottom: 15px;
}

.login-header h2 {
    margin: 0;
    color: var(--codess-primary);
    font-size: 22px;
    font-weight: 600;
}

.login-header p {
    margin: 5px 0 0;
    color: var(--text-muted);
    font-size: 14px;
}

.login-body {
    padding: 0 30px 40px;
}

/* Alertas */
.alert {
    display: flex;
    align-items: center;
    background-color: #fee2e2;
    color: var(--codess-danger);
    padding: 12px 15px;
    border-radius: 6px;
    font-size: 14px;
    margin-bottom: 20px;
    border-left: 4px solid var(--codess-danger);
}

.alert i {
    margin-right: 10px;
    font-size: 16px;
}

/* Campos de formulario */
.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-dark);
    font-size: 14px;
    font-weight: 600;
}

.input-icon-wrapper {
    position: relative;
}

.input-icon-wrapper i.icon-left {
    position: absolute;
    top: 50%;
    left: 15px;
    transform: translateY(-50%);
    color: #a0aec0;
    font-size: 16px;
    transition: color 0.3s;
}

.form-control {
    width: 100%;
    padding: 12px 15px 12px 45px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 15px;
    color: var(--text-dark);
    box-sizing: border-box;
    background-color: #f8fafc;
    transition: all 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--codess-primary);
    background-color: var(--bg-white);
    box-shadow: 0 0 0 3px rgba(0, 74, 152, 0.1);
}

.form-control:focus + i.icon-left,
.input-icon-wrapper:focus-within i.icon-left {
    color: var(--codess-primary);
}

.toggle-password {
    position: absolute;
    top: 50%;
    right: 15px;
    transform: translateY(-50%);
    cursor: pointer;
    color: #a0aec0;
    transition: color 0.3s;
}

.toggle-password:hover {
    color: var(--codess-primary);
}

/* Botones */
.btn-submit {
    width: 100%;
    background: var(--codess-primary);
    color: var(--bg-white);
    border: none;
    padding: 14px;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s, transform 0.1s;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.btn-submit:hover {
    background: var(--codess-secondary);
}

.btn-submit:active {
    transform: scale(0.98);
}

.btn-submit.loading {
    background: #94a3b8;
    cursor: not-allowed;
}