/* custom-forms.css - Styles for custom question forms */

/* Custom Questions Container */
#customQuestionsContainer {
    margin: 1.5rem 0;
}

.custom-question {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    position: relative;
    transition: all 0.3s ease;
}

.custom-question:hover {
    border-color: #cbd5e0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.question-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e2e8f0;
}

.question-header h5 {
    margin: 0;
    color: #2d3748;
    font-size: 1rem;
    font-weight: 600;
}

.remove-question-btn {
    background: #fed7d7;
    color: #c53030;
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.remove-question-btn:hover {
    background: #fc8181;
    color: white;
    transform: scale(1.1);
}

.add-question-controls {
    display: flex;
    gap: 1rem;
    align-items: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

.question-type-select {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.95rem;
    background: white;
    cursor: pointer;
}

.add-question-controls .btn-secondary {
    padding: 0.75rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
}

.custom-questions-description {
    color: #718096;
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

/* Options styling */
.options-container {
    background: white;
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    margin: 1rem 0;
}

.options-container textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-family: inherit;
    font-size: 0.95rem;
    resize: vertical;
}

/* Radio and Checkbox groups */
.radio-group,
.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.radio-option,
.checkbox-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem;
    border-radius: 6px;
    transition: background-color 0.2s ease;
}

.radio-option:hover,
.checkbox-option:hover {
    background-color: #f7fafc;
}

.radio-option input[type="radio"],
.checkbox-option input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.radio-option label,
.checkbox-option label {
    cursor: pointer;
    color: #2d3748;
    font-size: 0.95rem;
    flex: 1;
}

.other-specify {
    margin-top: 0.5rem;
    padding-left: 34px; /* Align with radio buttons */
}

.other-specify input {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 0.95rem;
}

/* Checkbox label styling */
.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    font-size: 0.95rem;
    color: #4a5568;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* File question specific */
.file-accept,
.file-description {
    font-size: 0.95rem;
}

/* Application form custom questions */
#customQuestionsSection {
    animation: fadeIn 0.3s ease-in-out;
}

#customQuestionsForm .form-group {
    margin-bottom: 1.5rem;
}

#customQuestionsForm .radio-group,
#customQuestionsForm .checkbox-group {
    max-height: 200px;
    overflow-y: auto;
    padding: 0.5rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .add-question-controls {
        flex-direction: column;
    }
    
    .question-type-select,
    .add-question-controls .btn-secondary {
        width: 100%;
    }
    
    .custom-question {
        padding: 1rem;
    }
    
    .radio-option,
    .checkbox-option {
        padding: 0.5rem 0.25rem;
    }
}

/* Animation for dynamic content */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}