/* ========================================= */
        /* मौजूदा CSS */
        /* ========================================= */

        @import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Devanagari:wght@300;400;500;600;700&display=swap');

        :root {
            --primary-color: #6366f1;
            --secondary-color: #8b5cf6;
            --success-color: #10b981;
            --danger-color: #ef4444;
            --warning-color: #f59e0b;
            --light-color: #f8fafc;
            --dark-color: #1e293b;
            --border-radius: 8px;
        }

        body {
            font-family: 'Noto Sans Devanagari', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            background-color: #f5f5f5;
            margin: 0;
            padding: 0;
            line-height: 1.6;
        }

        .quiz-container {
            max-width: 700px;
            margin: 1rem auto;
            padding: 0 0.5rem;
            font-family: 'Noto Sans Devanagari', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            direction: ltr;
            text-rendering: optimizeLegibility;
            -webkit-font-smoothing: antialiased;
            -moz-osx-font-smoothing: grayscale;
            line-height: 1.6;
            font-feature-settings: 'liga' 1, 'clig' 1, 'calt' 1, 'kern' 1;
            hyphens: auto;
            -webkit-hyphens: auto;
            -ms-hyphens: auto;
            hyphens: auto;
            unicode-bidi: embed;
            text-align: left;
            border-radius: var(--border-radius); /* Added */
            overflow: hidden; /* Added to ensure children respect border-radius */
        }

        .quiz-container,
        .quiz-container * {
            font-feature-settings: 'liga' 1, 'clig' 1, 'calt' 1, 'kern' 1;
            word-break: break-word;
            overflow-wrap: break-word;
            hyphens: auto;
            -webkit-hyphens: auto;
            -ms-hyphens: auto;
        }
        
        /* ************************************** */
        /* संशोधित हेडर और प्रोग्रेस CSS */
        /* ************************************** */

        .quiz-header {
            background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
            color: white;
            padding: 1.2rem; /* हेडर की ऊँचाई को बहाल किया गया */
            border-radius: var(--border-radius) var(--border-radius) 0 0; /* Modified */
            text-align: center;
            margin-bottom: 0; /* अब स्ट्रिप कंटेनर मार्जिन को संभालेगा */
            box-shadow: 0 5px 15px rgba(99, 102, 241, 0.3);
            position: relative; 
            z-index: 10;
        }

        .quiz-header h1 {
            font-size: 1.8rem;
            margin-bottom: 0.3rem;
            font-weight: 700;
        }

        .quiz-header p {
            font-size: 0.9rem;
            opacity: 0.9;
            margin: 0;
        }

        /* नया प्रोग्रेस स्ट्रिप कंटेनर */
        .progress-strip-container {
            background-color: var(--light-color); /* हल्की पट्टी का बेस रंग */
            border-radius: 0 0 var(--border-radius) var(--border-radius); /* Modified */
            margin-bottom: 1rem;
            padding: 0.5rem 1rem; /* जानकारी के लिए पैडिंग */
            box-shadow: 0 3px 8px rgba(0, 0, 0, 0.05);
            margin-top: -5px; /* हेडर के साथ ओवरलैप करने के लिए */
            position: relative;
            z-index: 9;
        }

        .progress-bar-wrapper-strip {
            background: #e2e8f0;
            height: 6px; /* पट्टी की मोटाई */
            border-radius: 50px;
            overflow: hidden;
            margin-bottom: 0.5rem;
        }

        .progress-bar-strip {
            height: 100%;
            background: linear-gradient(90deg, #10b981, #f59e0b); /* सफलता और चेतावनी रंगों का मिश्रण */
            border-radius: 50px;
            transition: width 0.5s ease;
            width: 0%;
        }

        .progress-text {
            display: flex;
            justify-content: space-between;
            align-items: center;
            font-size: 0.8rem;
            color: var(--dark-color);
            margin-top: 0.5rem; /* प्रोग्रेस बार के नीचे की दूरी */
        }

        .timer {
            display: flex;
            align-items: center;
            gap: 0.3rem;
            font-size: 0.8rem;
            color: var(--dark-color);
        }

        .timer-icon {
            width: 16px;
            height: 16px;
            fill: var(--primary-color);
        }
        
        /* ************************************** */
        /* संशोधित हेडर और प्रोग्रेस CSS समाप्त */
        /* ************************************** */


        .question-container {
            background: white;
            border-radius: var(--border-radius);
            padding: 1.2rem;
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
            margin-bottom: 1rem;
            min-height: 200px;
            position: relative;
        }

        /* Question Timer Display */
        .question-timer-display {
            position: absolute;
            top: 5px;
            left: 50%;
            transform: translateX(-50%);
            background: linear-gradient(135deg, #667eea, #764ba2);
            color: white;
            padding: 4px 12px;
            border-radius: 20px;
            font-size: 0.7rem;
            font-weight: 600;
            box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
            z-index: 10;
            animation: timer-pulse 1s ease-in-out infinite;
        }

        .question-timer-display.low-time {
            background: linear-gradient(135deg, #ef4444, #dc2626);
            animation: timer-urgent 0.5s ease-in-out infinite;
        }

        @keyframes timer-pulse {
            0%, 100% { transform: translateX(-50%) scale(1); }
            50% { transform: translateX(-50%) scale(1.05); }
        }

        @keyframes timer-urgent {
            0%, 100% {
                transform: translateX(-50%) scale(1);
                box-shadow: 0 2px 8px rgba(239, 68, 68, 0.5);
            }
            50% {
                transform: translateX(-50%) scale(1.1);
                box-shadow: 0 4px 12px rgba(239, 68, 68, 0.8);
            }
        }
        
        /* प्रश्न संख्या और विषय टैग के लिए कंटेनर */
        .question-header-row {
            display: flex;
            justify-content: space-between; /* प्रश्न संख्या को बाएं और विषय टैग को दाएं रखें */
            align-items: center;
            margin-bottom: 0.5rem;
            margin-top: 35px; /* Space for question timer above */
        }

        .question-number {
            display: inline-block;
            background: var(--primary-color);
            color: white;
            padding: 0.3rem 0.8rem;
            border-radius: 50px;
            font-size: 0.8rem;
            font-weight: 600;
        }
        
        /* नया विषय टैग CSS */
        .subject-tag {
            background-color: var(--warning-color);
            color: white;
            padding: 0.3rem 0.8rem;
            border-radius: 50px;
            font-size: 0.75rem;
            font-weight: 500;
            line-height: 1; 
            white-space: nowrap;
        }
        /* नया CSS समाप्त */


        .question-text {
            font-size: 1rem;
            color: var(--dark-color);
            margin-bottom: 1.2rem;
            line-height: 1.5;
            font-weight: 500;
            word-break: break-word;
            overflow-wrap: break-word;
            unicode-bidi: embed;
            text-align: left;
        }

        .options-container {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 0.6rem;
        }

        .option {
            background: var(--light-color);
            border: 2px solid transparent;
            border-radius: var(--border-radius);
            padding: 0.8rem;
            cursor: pointer;
            transition: all 0.3s ease;
            display: flex;
            align-items: center;
            position: relative;
            overflow: hidden;
            word-break: break-word;
            overflow-wrap: break-word;
            unicode-bidi: embed;
            text-align: left;
        }

        .option:hover {
            background: #f1f5f9;
            transform: translateY(-1px);
            box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
        }

        .option.selected {
            background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(139, 92, 246, 0.1));
            border-color: var(--primary-color);
        }

        .option.correct {
            background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(16, 185, 129, 0.2));
            border-color: var(--success-color);
        }

        .option.incorrect {
            background: linear-gradient(135deg, rgba(239, 68, 68, 0.1), rgba(239, 68, 68, 0.2));
            border-color: var(--danger-color);
        }

        .option-indicator {
            width: 20px;
            height: 20px;
            border: 2px solid #cbd5e1;
            border-radius: 50%;
            margin-right: 0.8rem;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: all 0.3s ease;
            flex-shrink: 0;
        }

        .option.selected .option-indicator {
            border-color: var(--primary-color);
            background: var(--primary-color);
        }

        .option.correct .option-indicator {
            border-color: var(--success-color);
            background: var(--success-color);
        }

        .option.incorrect .option-indicator {
            border-color: var(--danger-color);
            background: var(--danger-color);
        }

        .option-indicator::after {
            content: '';
            width: 6px;
            height: 6px;
            background: white;
            border-radius: 50%;
            opacity: 0;
            transform: scale(0);
            transition: all 0.3s ease;
        }

        .option.selected .option-indicator::after,
        .option.correct .option-indicator::after,
        .option.incorrect .option-indicator::after {
            opacity: 1;
            transform: scale(1);
        }

        .option-text {
            font-size: 0.9rem;
            color: var(--dark-color);
            line-height: 1.4;
            word-break: break-word;
            overflow-wrap: break-word;
            unicode-bidi: embed;
            text-align: left;
        }

        .feedback {
            margin-top: 0.8rem;
            padding: 0.6rem;
            border-radius: var(--border-radius);
            font-size: 0.85rem;
            display: none;
            word-break: break-word;
            overflow-wrap: break-word;
            unicode-bidi: embed;
            text-align: left;
        }

        .feedback.correct {
            background: rgba(16, 185, 129, 0.1);
            color: var(--success-color);
            border: 1px solid rgba(16, 185, 129, 0.2);
        }

        .feedback.incorrect {
            background: rgba(239, 68, 68, 0.1);
            color: var(--danger-color);
            border: 1px solid rgba(239, 68, 68, 0.2);
        }

        .navigation-buttons {
            display: flex;
            justify-content: space-between;
            gap: 0.8rem;
            margin-top: 1rem;
        }

        .btn {
            padding: 0.6rem 1.5rem;
            border: none;
            border-radius: var(--border-radius); /* Added */
            font-size: 0.9rem;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.3s ease;
            text-decoration: none;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            min-width: 100px;
            word-break: break-word;
            overflow-wrap: break-word;
            flex: 1;
        }

/* Auto-advance countdown styles */
.auto-next-countdown {
    margin-top: 10px;
    padding: 8px 12px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 6px;
    color: #2563eb;
    font-weight: 500;
    text-align: center;
    animation: pulse-countdown 1s infinite;
}

@keyframes pulse-countdown {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Tournament-specific styles */

.tournament-header {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    position: relative;
}

.tournament-header::before {
    content: '🏆';
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 2rem;
    opacity: 0.8;
}

/* Tournament Pre-Start Screen */
.tournament-prestart {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    z-index: 9999;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    color: white;
    padding: 20px;
    box-sizing: border-box;
    /* Removed overflow-y: auto to prevent scrolling */
    /* Ensure full viewport coverage on mobile */
    min-height: 100vh;
    min-height: -webkit-fill-available;
    /* Adjust alignment for better mobile positioning */
}

.prestart-content {
    max-width: 500px;
    width: 90%;
    padding-top: 40px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.3);
    text-align: center;
    color: #333;
    box-sizing: border-box;
    margin: 20px auto 0 auto;
    /* Removed max-height and overflow-y: auto to prevent scrolling */
    /* Centered using flexbox on parent container */
    /* Ensure content doesn't get cut off */
    position: relative;
    z-index: 1;
}

.prestart-header h1 {
font-size: 1.8rem;
margin-bottom: 8px;
background: linear-gradient(135deg, #667eea, #764ba2);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
background-clip: text;
}

.tournament-badge {
display: inline-block;
background: linear-gradient(135deg, #ff6b6b, #ee5a24);
color: white;
padding: 4px 12px;
border-radius: 15px;
font-size: 0.7rem;
font-weight: bold;
margin-bottom: 20px;
}

.tournament-details {
display: grid;
gap: 15px;
margin-bottom: 20px;
}

.detail-item {
background: white;
padding: 12px;
border-radius: 10px;
box-shadow: 0 3px 12px rgba(0,0,0,0.1);
border-left: 3px solid #667eea;
}

.detail-item.user-prize {
border-left-color: #ffd700;
background: linear-gradient(135deg, #fff8dc 0%, #f5f0dc 100%);
}

.detail-icon {
font-size: 2rem;
margin-bottom: 10px;
display: block;
}

.detail-content h3 {
margin: 0 0 6px 0;
color: #333;
font-size: 1rem;
}

.detail-content p {
margin: 0;
color: #666;
font-size: 0.9rem;
}

.prize-amount {
font-size: 1.5rem;
font-weight: bold;
color: #28a745;
}

.user-amount {
color: #ffd700;
text-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
}

.rules-list {
text-align: left;
padding-left: 20px;
}

.rules-list li {
margin-bottom: 8px;
line-height: 1.4;
}

.countdown-section {
margin-top: 20px;
}

.countdown-section h3 {
margin-bottom: 15px;
color: #333;
font-size: 1.3rem;
}

.countdown-timer {
background: linear-gradient(135deg, #667eea, #764ba2);
color: white;
padding: 15px 30px;
border-radius: 10px;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
margin: 0 auto 12px;
box-shadow: 0 6px 20px rgba(0,0,0,0.2);
min-width: 180px;
}

.countdown-number {
font-size: 2.5rem;
font-weight: bold;
line-height: 1;
}

.countdown-label {
font-size: 0.9rem;
opacity: 0.9;
margin-top: 4px;
}

.countdown-message {
font-style: italic;
color: #666;
font-size: 0.9rem;
}

/* Tournament Final Leaderboard */
.tournament-final-leaderboard {
margin-top: 2rem;
padding: 20px;
background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
border-radius: 12px;
border: 2px solid #dee2e6;
}

.tournament-final-leaderboard h3 {
color: #495057;
margin-bottom: 20px;
text-align: center;
}

.tournament-final-leaderboard-table {
max-width: 100%;
}

.user-rank-highlight {
background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
border: 2px solid #ffc107;
border-radius: 10px;
padding: 20px;
margin-bottom: 25px;
text-align: center;
}

.user-rank-highlight h4 {
margin: 0 0 10px 0;
color: #856404;
font-size: 1.3rem;
}

.user-rank-details {
display: flex;
justify-content: center;
gap: 20px;
flex-wrap: wrap;
}

.user-rank-details span {
background: white;
padding: 8px 16px;
border-radius: 20px;
font-weight: 600;
box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.user-score {
color: #28a745;
}

.user-time {
color: #6c757d;
}

.user-prize {
color: #ffd700;
font-size: 1.1rem;
}

.leaderboard-entry {
display: flex;
align-items: center;
background: white;
margin-bottom: 8px;
padding: 15px 20px;
border-radius: 8px;
box-shadow: 0 2px 8px rgba(0,0,0,0.08);
transition: transform 0.2s ease;
}

.leaderboard-entry:hover {
transform: translateY(-2px);
}

.leaderboard-entry.current-user {
border: 2px solid #007bff;
background: linear-gradient(135deg, #e7f3ff 0%, #d4edff 100%);
}

.leaderboard-entry.gold {
border-left: 4px solid #ffd700;
background: linear-gradient(135deg, #fff8dc 0%, #f5f0e8 100%);
}

.leaderboard-entry.silver {
border-left: 4px solid #c0c0c0;
background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.leaderboard-entry.bronze {
border-left: 4px solid #cd7f32;
background: linear-gradient(135deg, #f5f0e8 0%, #e6d7c3 100%);
}

.rank {
font-size: 1.5rem;
font-weight: bold;
margin-right: 15px;
min-width: 50px;
text-align: center;
}

.user-info {
flex: 1;
}

.user-name {
font-weight: 600;
color: #495057;
margin-bottom: 2px;
}

.user-details {
color: #6c757d;
font-size: 0.9rem;
}

.prize {
font-weight: bold;
color: #28a745;
font-size: 1.1rem;
margin-left: 15px;
}

@media (max-width: 768px) {
    .tournament-prestart {
        padding: 15px;
        align-items: flex-start;
        padding-top: 40px;
        /* Ensure full height on tablets */
        min-height: 100vh;
        min-height: -webkit-fill-available;
    }

    .prestart-content {
        margin: 0 auto;
        padding: 20px 15px;
        max-width: none;
        width: 95%;
        border-radius: 12px;
        /* Ensure content is fully visible */
        max-height: calc(100vh - 60px);
        overflow-y: auto;
    }

    .prestart-header h1 {
        font-size: 1.5rem;
    }

    .tournament-details {
        gap: 15px;
    }

    .detail-item {
        padding: 15px;
    }

    .user-rank-details {
        flex-direction: column;
        gap: 10px;
    }

    .leaderboard-entry {
        padding: 12px 15px;
    }

    .rank {
        min-width: 40px;
        font-size: 1.3rem;
    }
}

@media (max-width: 480px) {
    .tournament-prestart {
        
        align-items: flex-start;
        padding-top: 40%;
        /* Ensure full height on mobile */
        min-height: 100vh;
        min-height: -webkit-fill-available;
    }

    .prestart-content {
        margin: 0 auto;
        
        border-radius: 8px;
        width: 98%;
        /* Ensure content is fully visible on small screens */
        
        overflow-y: auto;
    }

    .prestart-header h1 {
        font-size: 1.3rem;
    }

    .tournament-badge {
        font-size: 0.6rem;
        padding: 3px 8px;
    }

    .tournament-details {
        gap: 8px;
    }

    .detail-item {
        padding: 10px;
    }

    .detail-icon {
        font-size: 1.3rem;
    }

    .detail-content h3 {
        font-size: 0.9rem;
    }

    .detail-content p {
        font-size: 0.8rem;
    }

    .countdown-timer {
        min-width: 160px;
        padding: 12px 25px;
    }

    .countdown-number {
        font-size: 2rem;
    }

    .countdown-label {
        font-size: 0.8rem;
    }

    .countdown-message {
        font-size: 0.8rem;
    }
}

.tournament-info {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 15px;
    justify-content: center;
}

.tournament-prize,
.tournament-deadline,
.tournament-fee {
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
    color: white;
    backdrop-filter: blur(10px);
}

.tournament-results {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border: 2px solid #f59e0b;
}

.tournament-certificate {
    border: 5px solid #f59e0b;
    background: linear-gradient(145deg, #ffffff, #fef3c7);
}

.tournament-certificate .certificate-header {
    color: #d97706;
}

.tournament-certificate .certificate-seal {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
}

        .btn-primary {
            background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
            color: white;
        }

        .btn-primary:hover {
            transform: translateY(-2px);
            box-shadow: 0 5px 15px rgba(99, 102, 241, 0.3);
        }

        .btn-secondary {
            background: var(--light-color);
            color: var(--dark-color);
            border: 2px solid #e2e8f0;
        }

        .btn-secondary:hover {
            background: #f1f5f9;
            transform: translateY(-2px);
        }

        .btn:disabled {
            opacity: 0.5;
            cursor: not-allowed;
            transform: none !important;
        }

        .results-container {
            background: white;
            border-radius: var(--border-radius); /* Added */
            padding: 1.5rem;
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
            text-align: center;
            display: none;
        }

        .score-display {
            font-size: 2.2rem;
            font-weight: 700;
            color: var(--primary-color);
            margin-bottom: 0.8rem;
        }

        .score-message {
            font-size: 1rem;
            color: var(--dark-color);
            margin-bottom: 1.5rem;
            word-break: break-word;
            overflow-wrap: break-word;
            unicode-bidi: embed;
            text-align: center;
        }

        .score-details {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
            gap: 0.8rem;
            margin-bottom: 1.5rem;
        }

        .score-item {
            background: var(--light-color);
            padding: 0.8rem;
            border-radius: var(--border-radius);
        }

        .score-item-label {
            font-size: 0.8rem;
            color: #64748b;
            margin-bottom: 0.3rem;
            word-break: break-word;
            overflow-wrap: break-word;
            unicode-bidi: embed;
            text-align: center;
        }

        .score-item-value {
            font-size: 1.2rem;
            font-weight: 700;
            color: var(--dark-color);
        }

        .question-navigation {
            display: flex;
            flex-wrap: wrap;
            gap: 0.3rem;
            margin-top: 1rem; /* दूरी बनाए रखी */
            margin-bottom: 1rem; /* दूरी बनाए रखी */
            justify-content: center;
        }

        .nav-dot {
            width: 10px;
            height: 10px;
            border-radius: 50%;
            background: #e2e8f0;
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .nav-dot.active {
            background: var(--primary-color);
            transform: scale(1.2);
        }

        .nav-dot.answered {
            background: var(--success-color);
        }

        .nav-dot.current {
            background: var(--warning-color);
            animation: pulse 1.5s infinite;
        }

        @keyframes pulse {
            0% {
                box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.7);
            }
            70% {
                box-shadow: 0 0 0 8px rgba(245, 158, 11, 0);
            }
            100% {
                box-shadow: 0 0 0 0 rgba(245, 158, 11, 0);
            }
        }

        /* ========================================= */
        /* प्रमाण पत्र (Certificate) CSS */
        /* ========================================= */
        .certificate-container {
            display: none; /* Initially hidden */
            max-width: 650px;
            margin: 1rem auto;
            padding: 2.5rem;
            background: linear-gradient(145deg, #ffffff, #f7f7ff);
            border: 10px solid var(--primary-color); /* Main border */
            border-radius: var(--border-radius); /* Added */
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
            text-align: center;
            position: relative;
            overflow: hidden;
        }

        .certificate-container::before {
            content: '&#127942;'; /* 🏆 */
            position: absolute;
            top: 10px;
            right: 10px;
            font-size: 3rem;
            opacity: 0.1;
        }

        .certificate-header {
            font-size: 2.5rem;
            font-weight: 700;
            color: var(--primary-color);
            margin-bottom: 0.5rem;
            text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
        }

        .certificate-subtext {
            font-size: 1.2rem;
            color: #475569;
            margin-bottom: 1.5rem;
        }

        .certificate-seal {
            font-size: 1.5rem;
            font-weight: 600;
            color: var(--success-color);
            margin: 1.5rem 0;
            padding: 0.5rem 1.5rem;
            border: 3px solid var(--success-color);
            display: inline-block;
            border-radius: 5px;
        }

        .certificate-score {
            font-size: 3rem;
            font-weight: 800;
            color: var(--danger-color);
            margin: 1rem 0;
            display: block;
        }

        .certificate-score span {
            font-size: 1.5rem;
            font-weight: 500;
            color: var(--dark-color);
        }

        .certificate-details-table {
            width: 100%;
            margin: 1.5rem 0;
            border-collapse: collapse;
        }

        .certificate-details-table td {
            padding: 0.8rem;
            border: 1px solid #e2e8f0;
            font-size: 1rem;
            text-align: left;
        }

        .certificate-details-table td:first-child {
            background-color: var(--light-color);
            font-weight: 600;
            width: 50%;
        }

        /* ========================================= */
        /* समीक्षा सूची (Review List) CSS */
        /* ========================================= */
        .review-item {
            background: #f8f8f8;
            border: 1px solid #e0e0e0;
            border-left: 5px solid var(--primary-color);
            border-radius: var(--border-radius); /* Added */
            padding: 1rem;
            margin-bottom: 1rem;
            box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
            text-align: left;
        }
        .review-item.correct-answer-item {
            border-left: 5px solid var(--success-color);
        }
        .review-item.incorrect-answer-item {
            border-left: 5px solid var(--danger-color);
        }
        .review-question-text {
            font-weight: 600;
            color: var(--dark-color);
            margin-bottom: 0.5rem;
            font-size: 1rem;
        }
        .review-correct, .review-user-answer {
            padding: 0.4rem;
            border-radius: 4px;
            font-size: 0.9rem;
            margin-top: 0.3rem;
            display: block;
        }
        .review-correct {
            background: rgba(16, 185, 129, 0.1); /* success-color */
            color: var(--success-color);
            border: 1px solid var(--success-color);
            font-weight: 500;
        }
        .review-user-answer {
            font-weight: 500;
            border: 1px solid #ccc;
            background: #fff;
            color: var(--dark-color);
        }
        .review-user-answer.incorrect-choice {
            background: rgba(239, 68, 68, 0.1); /* danger-color */
            color: var(--danger-color);
            border: 1px solid var(--danger-color);
        }
        .review-explanation {
            font-size: 0.85rem;
            color: #475569;
            margin-top: 0.8rem;
            border-top: 1px dashed #e2e8f0;
            padding-top: 0.5rem;
        }


        /* ========================================= */
        /* मीडिया क्वैरी (Media Queries) */
        /* ========================================= */
        /* Custom Dialog Styles */
        .custom-dialog-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.6);
            backdrop-filter: blur(4px);
            z-index: 99999;
            display: flex;
            align-items: center;
            justify-content: center;
            animation: fadeIn 0.3s ease;
        }

        @keyframes fadeIn {
            from { opacity: 0; }
            to { opacity: 1; }
        }

        .custom-dialog {
            background: white;
            border-radius: 16px;
            padding: 30px;
            max-width: 450px;
            width: 90%;
            box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
            animation: slideUp 0.3s ease;
            text-align: center;
        }

        @keyframes slideUp {
            from { transform: translateY(50px); opacity: 0; }
            to { transform: translateY(0); opacity: 1; }
        }

        .dialog-icon {
            font-size: 3rem;
            margin-bottom: 15px;
        }

        .dialog-title {
            font-size: 1.5rem;
            font-weight: 700;
            color: var(--dark-color);
            margin-bottom: 10px;
        }

        .dialog-message {
            font-size: 1rem;
            color: #64748b;
            margin-bottom: 25px;
            line-height: 1.5;
        }

        .dialog-input {
            width: 100%;
            padding: 12px;
            border: 2px solid #e2e8f0;
            border-radius: 8px;
            font-size: 1rem;
            margin-bottom: 20px;
            box-sizing: border-box;
            transition: border-color 0.3s ease;
        }

        .dialog-input:focus {
            outline: none;
            border-color: var(--primary-color);
        }

        .dialog-buttons {
            display: flex;
            gap: 10px;
            justify-content: center;
        }

        .dialog-btn {
            padding: 12px 30px;
            border: none;
            border-radius: 8px;
            font-size: 1rem;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.3s ease;
            min-width: 100px;
        }

        .dialog-btn.primary {
            background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
            color: white;
        }

        .dialog-btn.primary:hover {
            transform: translateY(-2px);
            box-shadow: 0 5px 15px rgba(99, 102, 241, 0.3);
        }

        .dialog-btn.secondary {
            background: var(--light-color);
            color: var(--dark-color);
            border: 2px solid #e2e8f0;
        }

        .dialog-btn.secondary:hover {
            background: #f1f5f9;
        }

        .custom-dialog.success .dialog-icon {
            color: var(--success-color);
        }

        .custom-dialog.error .dialog-icon {
            color: var(--danger-color);
        }

        .custom-dialog.warning .dialog-icon {
            color: var(--warning-color);
        }

        .custom-dialog.info .dialog-icon {
            color: var(--primary-color);
        }

        @media (max-width: 768px) {
            .quiz-header h1 {
                font-size: 1.5rem;
            }

            .question-text {
                font-size: 0.9rem;
            }

            .navigation-buttons {
                flex-direction: row;
                justify-content: space-between;
                gap: 0.5rem;
            }

            .btn {
                width: auto;
                min-width: 80px;
                font-size: 0.8rem;
                padding: 0.5rem 1rem;
                flex: 1;
                max-width: none;
            }

            .score-display {
                font-size: 1.8rem;
            }

            .options-container {
                /* 2x2 लेआउट बनाए रखें */
                gap: 0.4rem;
            }

            .option {
                padding: 0.6rem;
                font-size: 0.85rem;
            }

            .option-indicator {
                width: 16px;
                height: 16px;
                margin-right: 0.6rem;
            }

            .option-indicator::after {
                width: 5px;
                height: 5px;
            }

            .certificate-header {
                font-size: 2rem;
            }

            .certificate-subtext {
                font-size: 1rem;
            }

            .certificate-score {
                font-size: 2.5rem;
            }
            .subject-tag {
                font-size: 0.65rem;
                padding: 0.2rem 0.6rem;
            }

            .custom-dialog {
                padding: 20px;
                max-width: 90%;
            }

            .dialog-title {
                font-size: 1.3rem;
            }

            .dialog-icon {
                font-size: 2.5rem;
            }
        }
    