/* ============================================
   FORMULARIO DE CONTACTO - VALIDACIÓN
   ============================================ */

/* Campos con error */
.contact-form input.error,
.contact-form select.error,
.contact-form textarea.error {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1) !important;
}

.contact-form input.error:focus,
.contact-form select.error:focus,
.contact-form textarea.error:focus {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2) !important;
}

/* Mensaje de error del campo */
.field-error {
    display: block;
    color: #ef4444;
    font-size: 0.8rem;
    margin-top: 6px;
    padding-left: 2px;
    animation: fieldErrorIn 0.2s ease;
}

@keyframes fieldErrorIn {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Checkbox con error */
.form-checkbox .field-error {
    margin-top: 8px;
    margin-left: 0;
}

/* Nombre de archivo con error */
.file-name.error {
    color: #ef4444 !important;
}

/* ============================================
   NOTIFICACIONES DEL FORMULARIO
   ============================================ */

.contact-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    max-width: 420px;
    min-width: 320px;
    padding: 16px 20px;
    border-radius: 12px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    transform: translateX(calc(100% + 40px));
    transition: transform 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    z-index: 10001;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.contact-notification.show {
    transform: translateX(0);
}

.contact-notification-content {
    flex: 1;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.contact-notification-content i {
    font-size: 1.3rem;
    margin-top: 2px;
    flex-shrink: 0;
}

.contact-notification-content span {
    line-height: 1.5;
    font-size: 0.95rem;
}

/* Tipos de notificación */
.contact-notification-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.contact-notification-error {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
}

.contact-notification-warning {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
}

.contact-notification-info {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
}

/* Botón cerrar */
.contact-notification-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, transform 0.2s;
    flex-shrink: 0;
}

.contact-notification-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.contact-notification-close:active {
    transform: scale(0.95);
}

/* ============================================
   BOTÓN DE ENVÍO - ESTADO LOADING
   ============================================ */

.contact-form button[type="submit"] {
    position: relative;
    transition: all 0.3s ease;
}

.contact-form button[type="submit"]:disabled {
    opacity: 0.8;
    cursor: not-allowed;
    transform: none !important;
}

.contact-form button[type="submit"] .fa-spinner {
    margin-right: 8px;
}

/* Animación del spinner */
@keyframes spin {
    to { transform: rotate(360deg); }
}

.fa-spin {
    animation: spin 1s linear infinite;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 576px) {
    .contact-notification {
        left: 10px;
        right: 10px;
        max-width: none;
        min-width: auto;
    }
}