/* Form Validation Styles */
.form input.error,
.form textarea.error {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25) !important;
}

.form input.error:focus,
.form textarea.error:focus {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25) !important;
}

/* Success Message Styles */
.reply-group.success-message {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 0.375rem;
    padding: 1rem;
    margin-bottom: 1rem;
}

.reply-group.success-message .reply-group__icon {
    color: #155724;
}

.reply-group.success-message .reply-group__title {
    color: #155724;
}

.reply-group.success-message .reply-group__text {
    color: #155724;
}

/* Error Message Styles */
.reply-group.error-message {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 0.375rem;
    padding: 1rem;
    margin-bottom: 1rem;
}

.reply-group.error-message .reply-group__icon {
    color: #721c24;
}

.reply-group.error-message .reply-group__title {
    color: #721c24;
}

.reply-group.error-message .reply-group__text {
    color: #721c24;
}

/* Button disabled state */
.button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Form animation */
.form input,
.form textarea {
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

/* Loading state for buttons */
.button.loading {
    position: relative;
    pointer-events: none;
}

.button.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin-top: -10px;
    margin-left: -10px;
    border: 2px solid transparent;
    border-top: 2px solid #ffffff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Hide reply groups by default */
.reply-group {
    display: none;
}

/* Show reply groups when they have content */
.reply-group.show {
    display: block;
}

/* Responsive form improvements */
@media (max-width: 768px) {
    .form input,
    .form textarea {
        font-size: 16px; /* Prevent zoom on iOS */
    }
    
    .reply-group {
        padding: 0.75rem;
        font-size: 0.9rem;
    }
} 