﻿/* CUMPLE! - Estilos personalizados con paleta Compliance Green */

:root {
    /* Paleta solicitada */
    --primary: #235D59;
    --primary-foreground: #FFFFFF;
    --accent: #486A68;
    --accent-foreground: #FFFFFF;
    --background: #FFFFFF;
    --foreground: #171717;
    --secondary: #F5F5F5;
    --secondary-foreground: #171717;
    --muted: #F5F5F5;
    --muted-foreground: #757575;
    --destructive: #EE4343;
    --destructive-foreground: #FFFFFF;
    --border: #E6E6E6;
    --input: #E6E6E6;
}

/* Estilos generales */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--foreground);
    background: var(--background);
    line-height: 1.6;
}

/* Tipografías: Hedvig para títulos y subtítulos */
h1, h2, h3, h4, h5, h6, .display-1, .display-2, .display-3, .display-4 {
    font-family: 'Hedvig Letters Serif', Georgia, 'Times New Roman', serif;
}

.login-body {
    background: var(--light);
    min-height: 100vh;
}

/* Panel izquierdo con gradiente */
.login-left-panel {
    background: var(--primary);
    position: relative;
    overflow: hidden;
}

.login-left-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="white" opacity="0.1"/><circle cx="75" cy="75" r="1" fill="white" opacity="0.1"/><circle cx="50" cy="10" r="0.5" fill="white" opacity="0.05"/><circle cx="10" cy="60" r="0.5" fill="white" opacity="0.05"/><circle cx="90" cy="40" r="0.5" fill="white" opacity="0.05"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
}

.login-content {
    position: relative;
    z-index: 2;
    padding: 3rem;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.feature-item {
    text-align: center;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.feature-item i {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    display: block;
}

/* Contenedor del formulario */
.login-form-container {
    background: white;
    padding: 3rem;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
    border: 1px solid var(--light-gray);
}

/* Botones personalizados */
.btn-primary {
    background: var(--primary);
    border: none;
    border-radius: 12px;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.12);
    background: var(--primary);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-outline-primary {
    border: 2px solid var(--primary);
    color: var(--primary);
    border-radius: 12px;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-outline-primary:hover {
    background: var(--primary);
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

/* Formularios */
.form-control {
    border: 2px solid var(--input);
    border-radius: 12px;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: var(--background);
}

.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(35, 93, 89, 0.15);
    background: #FFFFFF;
}

.form-control-lg {
    padding: 1rem 1.25rem;
    font-size: 1.1rem;
}

/* Alertas personalizadas */
.alert {
    border: none;
    border-radius: 12px;
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
}

.alert-danger {
    background: #FEF2F2;
    color: var(--destructive);
    border-left: 4px solid var(--destructive);
}

.alert-success {
    background: #F0FDF4;
    color: #059669;
    border-left: 4px solid #059669;
}

/* Input group personalizado */
.input-group .btn {
    border: 2px solid var(--input);
    border-left: none;
    background: var(--background);
    color: var(--muted-foreground);
    transition: all 0.3s ease;
}

.input-group .btn:hover {
    background: var(--accent);
    color: var(--accent-foreground);
    border-color: var(--accent);
}

.input-group .form-control:focus + .btn {
    border-color: var(--primary);
}

/* Checkbox personalizado */
.form-check-input:checked {
    background-color: var(--primary);
    border-color: var(--primary);
}

.form-check-input:focus {
    box-shadow: 0 0 0 0.2rem rgba(35, 93, 89, 0.15);
}

/* Enlaces */
a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--accent);
}

/* Títulos */
.text-primary {
    color: var(--primary) !important;
}

/* Efectos de hover para cards */
.login-form-container {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.login-form-container:hover {
    transform: translateY(-5px);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.15);
}

/* Responsive */
@media (max-width: 991.98px) {
    .login-left-panel {
        display: none !important;
    }
    
    .login-form-container {
        margin: 2rem 0;
        padding: 2rem;
    }
    
    .features {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

@media (max-width: 575.98px) {
    .login-form-container {
        padding: 1.5rem;
        margin: 1rem;
    }
    
    .btn-lg {
        padding: 0.75rem 1rem;
        font-size: 1rem;
    }
}

/* Animaciones */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-form-container {
    animation: fadeInUp 0.6s ease-out;
}

/* Efectos de carga */
.btn-primary:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.btn-primary:disabled:hover {
    transform: none;
    box-shadow: none;
}

/* Estilos para el toggle de contraseña */
#togglePassword {
    border-top-right-radius: 12px;
    border-bottom-right-radius: 12px;
}

/* Mejoras de accesibilidad */
.form-control:focus,
.btn:focus {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Estilos para validación */
.is-invalid {
    border-color: var(--error) !important;
}

.is-valid {
    border-color: var(--success) !important;
}

.invalid-feedback {
    color: var(--error);
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

.valid-feedback {
    color: var(--success);
    font-size: 0.875rem;
    margin-top: 0.5rem;
}
