/* Question Flow Styles */

.flow-progress {
    margin-bottom: 2rem;
}

.flow-progress .progress {
    height: 25px;
    background-color: #e9ecef;
    border-radius: 12.5px;
    overflow: hidden;
    box-shadow: inset 0 1px 2px rgba(0,0,0,.1);
}

.flow-progress .progress-bar {
    background: linear-gradient(45deg, #007bff, #0056b3);
    transition: width 0.6s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 0.875rem;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.flow-progress small {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: #6c757d;
}

/* Question block enhancements for flow */
.question-block {
    position: relative;
}

.question-block .conclusion-logic-container {
    margin-bottom: 1rem;
}

/* Enhanced next button styling */
.nextq {
    transition: all 0.3s ease;
}

.nextq.disabled-link {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.nextq:not(.disabled-link):hover {
    transform: translateX(5px);
}

/* Flow completion styles */
.alert-success {
    border: none;
    border-radius: 10px;
    padding: 2rem;
    background: linear-gradient(135deg, #d4edda, #c3e6cb);
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.alert-success h3 {
    color: #155724;
    margin-bottom: 1rem;
}

.alert-success .btn {
    margin-top: 1rem;
    padding: 0.75rem 2rem;
    border-radius: 25px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .flow-progress .progress {
        height: 20px;
    }
    
    .flow-progress .progress-bar {
        font-size: 0.75rem;
    }
    
    .alert-success {
        padding: 1.5rem;
    }
}

/* Animation for question transitions */
.question-block {
    animation: fadeInUp 0.5s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Loading state for AJAX requests */
.loading {
    position: relative;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
