/* =====================================================
   ESTILOS PARA EL MODAL DE DATOS DE USUARIO
   ===================================================== */

.user-data-modal-content {
    max-width: 750px !important;
    max-height: 90vh;
    overflow-y: auto;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%) !important;
    border-radius: 20px !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3) !important;
    padding: 2.5rem !important;
}

/* ===== TABS DE NAVEGACIÓN ===== */
.user-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    border-bottom: 2px solid #e0e0e0;
}

.user-tab-btn {
    flex: 1;
    padding: 1rem 1.5rem;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.95rem;
    color: #7f8c8d;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.user-tab-btn:hover {
    color: var(--blue-light);
    background: rgba(0, 123, 255, 0.05);
}

.user-tab-btn.active {
    color: var(--blue-dark);
    border-bottom-color: var(--blue-light);
    background: rgba(0, 123, 255, 0.1);
}

/* ===== CONTENIDO DE LOS TABS ===== */
.user-tab-content {
    display: none;
    animation: fadeInTab 0.4s ease;
}

.user-tab-content.active {
    display: block;
}

@keyframes fadeInTab {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== FORMULARIOS ===== */
#userDataModal .form-group {
    margin-bottom: 1.5rem;
}

#userDataModal .form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--blue-dark);
    font-size: 0.95rem;
}

#userDataModal .form-group input,
#userDataModal .form-group textarea,
#userDataModal .form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    /* 💡 SOLUCIÓN TEMPORAL REFORZADA: Fondo azul más oscuro (30% de opacidad) */
    background: rgba(0, 123, 255, 0.3); 
    box-sizing: border-box;
}

#userDataModal .form-group input:focus,
#userDataModal .form-group textarea:focus,
#userDataModal .form-group select:focus {
    outline: none;
    border-color: var(--blue-light);
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

#userDataModal .form-group input:disabled {
    background: #f0f0f0;
    cursor: not-allowed;
    color: #999;
}

/* ===== FILA DE FORMULARIO (2 COLUMNAS) ===== */
.form-row {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1rem;
}

/* ===== BOTONES ===== */
#userDataModal .primary-btn {
    width: 100%;
    padding: 1rem;
    background: linear-gradient(135deg, var(--blue-light), var(--blue-medium));
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
    margin-top: 1rem;
}

#userDataModal .primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 123, 255, 0.4);
}

#userDataModal .primary-btn:active {
    transform: translateY(0);
}

/* ===== MENSAJES DE VALIDACIÓN ===== */
#userDataModal .error-message {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: block;
}

#userDataModal .success-message {
    color: #28a745;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: block;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .user-data-modal-content {
        width: 95% !important;
        padding: 1.5rem !important;
        margin: 2% auto !important;
    }

    .user-tabs {
        flex-direction: column;
        gap: 0;
    }

    .user-tab-btn {
        border-bottom: 1px solid #e0e0e0;
        text-align: left;
        padding: 1rem;
    }

    .user-tab-btn.active {
        border-left: 4px solid var(--blue-light);
        border-bottom: 1px solid #e0e0e0;
    }

    .form-row {
        grid-template-columns: 1fr;
    }
}

/* ===== SCROLL PERSONALIZADO ===== */
.user-data-modal-content::-webkit-scrollbar {
    width: 8px;
}

.user-data-modal-content::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 10px;
}

.user-data-modal-content::-webkit-scrollbar-thumb {
    background: var(--blue-light);
    border-radius: 10px;
}

.user-data-modal-content::-webkit-scrollbar-thumb:hover {
    background: var(--blue-medium);
}
} /* El corchete de cierre extra de tu archivo original se mantiene aquí */


/* =====================================================
   CORRECCIÓN FINAL: MÁXIMA ESPECIFICIDAD Y AUTOFILL FIX
   ===================================================== */

/* 1. Regla de máxima especificidad para el texto normal */
/* Usamos el contenedor más específico para garantizar la sobreescritura */
#userDataModal .user-data-modal-content .form-group input[type="text"],
#userDataModal .user-data-modal-content .form-group input[type="email"],
#userDataModal .user-data-modal-content .form-group input[type="tel"],
#userDataModal .user-data-modal-content .form-group input[type="password"],
#userDataModal .user-data-modal-content .form-group textarea,
#userDataModal .user-data-modal-content .form-group select {
    /* Color de texto oscuro que no se confunda con el fondo claro */
    color: #333333 !important; 
    
    /* Asegurar que Webkit no aplique su estilo predeterminado */
    -webkit-text-fill-color: #333333 !important; 
}


/* 2. SOLUCIÓN PARA EL AUTOCOMPLETADO (WebKit Autofill) */
/* Debe apuntar al input dentro del modal para que funcione la especificidad */
#userDataModal input:-webkit-autofill,
#userDataModal textarea:-webkit-autofill,
#userDataModal select:-webkit-autofill {
    /* Forzar el color del texto a oscuro en el campo autocompletado */
    -webkit-text-fill-color: #333333 !important; 
    
    /* CRÍTICO: Sobreescribir el fondo claro del autocompletado nativo 
       (Esto es necesario para que -webkit-text-fill-color funcione correctamente en algunos casos) */
    -webkit-box-shadow: 0 0 0 1000px white inset !important; 
    background-color: white !important; 
    transition: background-color 5000s ease-in-out 0s; 
}