/* التصميم العام */
body {
    font-family: 'Tajawal', sans-serif;
    background-color: #f8f9fa;
}

.landing-page {
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    color: white;
}

.auth-page {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
}

.card {
    border-radius: 15px;
    border: none;
    overflow: hidden;
    transition: transform 0.3s;
}

.card:hover {
    transform: translateY(-5px);
}

.shadow-lg {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.btn-primary {
    background-color: #4e73df;
    border-color: #4e73df;
}

.btn-primary:hover {
    background-color: #2e59d9;
    border-color: #2e59d9;
}

/* تصميم الصفحة الرئيسية */
.display-4 {
    font-weight: 700;
}

.lead {
    font-size: 1.5rem;
    font-weight: 300;
}

/* تصميم واجهة الإدارة والمعلم */
.sidebar {
    min-height: 100vh;
    background: linear-gradient(180deg, #4e73df 0%, #224abe 100%);
}

.sidebar .nav-link {
    color: rgba(255, 255, 255, 0.8);
    font-weight: 600;
    margin-bottom: 5px;
    border-radius: 5px;
}

.sidebar .nav-link:hover {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.1);
}

.sidebar .nav-link.active {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.2);
}

/* تصميم الجداول */
.table th {
    background-color: #f8f9fc;
    font-weight: 700;
}

/* تصميم الأسئلة */
.question-card {
    border-left: 4px solid #4e73df;
}

/* تصميم المسابقة */
.quiz-container {
    max-width: 1200px;
    margin: 0 auto;
}

.quiz-question {
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.quiz-option {
    padding: 10px 15px;
    margin-bottom: 10px;
    border-radius: 5px;
    background-color: #f8f9fa;
    cursor: pointer;
    transition: all 0.3s;
}

.quiz-option:hover {
    background-color: #e9ecef;
}

.quiz-option.selected {
    background-color: #4e73df;
    color: white;
}

/* تصميم النتائج المباشرة */
.live-results {
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    height: 500px;
    overflow-y: auto;
}

.participant-item {
    padding: 10px;
    border-bottom: 1px solid #eee;
    transition: all 0.3s;
}

.participant-item:hover {
    background-color: #f8f9fa;
}

.progress {
    height: 10px;
    border-radius: 5px;
}

/* تصميم متجاوب */
@media (max-width: 768px) {
    .sidebar {
        min-height: auto;
    }
}
/* أسئلة الأستاذ */
.custom-question {
    border-left: 4px solid #4e73df;
    background-color: rgba(78, 115, 223, 0.05);
}

/* علامة الأسئلة المخصصة */
.custom-badge {
    background-color: #4e73df;
    color: white;
    font-size: 0.7rem;
    margin-right: 5px;
}
/* تنسيق الصور في الأسئلة */
.question-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 15px 0;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* تنسيق حقل رفع الصورة */
.file-upload {
    border: 2px dashed #ddd;
    padding: 20px;
    text-align: center;
    border-radius: 8px;
    margin-bottom: 15px;
}

.file-upload:hover {
    border-color: #4e73df;
}
.qr-code {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 10px;
    background: white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.select2-container--bootstrap-5 .select2-selection {
    padding: 0.375rem 0.75rem;
    font-size: 1rem;
    line-height: 1.5;
    border: 1px solid #ced4da;
    border-radius: 0.375rem;
}

.select2-container--bootstrap-5 .select2-selection--single {
    height: auto;
    min-height: calc(1.5em + 0.75rem + 2px);
}

.select2-container--bootstrap-5 .select2-dropdown {
    border-color: #ced4da;
    border-radius: 0.375rem;
}

.select2-container--bootstrap-5 .select2-results__option--highlighted {
    background-color: #0d6efd;
    color: white;
}
/* تنسيقات نافذة اختيار الأسئلة */
#questionsModal .modal-body {
    max-height: 70vh;
    overflow-y: auto;
}

.question-item .card {
    cursor: pointer;
    transition: all 0.2s;
}

.question-item .card:hover {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.1);
}

.question-item .form-check-label {
    cursor: pointer;
    user-select: none;
}

/* تنسيقات الأسئلة المختارة */
.selected-question-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.75rem;
    background-color: #e9ecef;
    border-radius: 50rem;
    font-size: 0.875rem;
}

.selected-question-badge .btn-remove-question {
    background: none;
    border: none;
    padding: 0 0 0 0.5rem;
    color: #6c757d;
    line-height: 1;
}

.selected-question-badge .btn-remove-question:hover {
    color: #dc3545;
}

/* تبويب الأسئلة المختارة */
#selectedQuestionsContainer {
    min-height: 200px;
}

.selected-questions-area {
    background-color: #f8f9fa;
}
/* في ملف CSS الخاص بك */
.modal {
    z-index: 1060; /* تأكد من أنه أعلى من أي عنصر آخر */
}
.modal-backdrop {
    z-index: 1050;
}
.modal-content {
    border: none;
    box-shadow: 0 5px 15px rgba(0,0,0,0.5);
}
/* تأكيد أن المودال يظهر فوق كل المحتوى */
.modal {
    z-index: 1060 !important; /* القيمة الافتراضية في Bootstrap هي 1050 */
}

/* تأكيد أن خلفية المودال تغطي المحتوى */
.modal-backdrop {
    z-index: 1040 !important;
    background-color: rgba(0, 0, 0, 0.5) !important;
}

/* إذا كان الجدول يحتوي على z-index عالي */
.table-container {
    z-index: auto !important;
    position: relative;
}
/* في قسم الـ styles */
.btn-delete-quiz {
    transition: all 0.3s;
}
.btn-delete-quiz:hover {
    transform: scale(1.1);
    box-shadow: 0 0 5px rgba(0,0,0,0.2);
}