/**=====================
     Quiz Pages Custom CSS
     Respecting App Design System
==========================**/

:root {
    --quiz-primary: #0da487;
    --quiz-primary-dark: #0e947a;
    --quiz-success: #28a745;
    --quiz-danger: #ff4f4f;
    --quiz-warning: #ffc107;
    --quiz-info: #17a2b8;
    --quiz-light: #f8f9fa;
    --quiz-dark: #222222;
    --quiz-border: #ececec;
    --quiz-shadow: 0 4px 12px rgba(13, 164, 135, 0.15);
    --quiz-shadow-hover: 0 8px 25px rgba(13, 164, 135, 0.25);
}

/* =====================
    Quiz Cards & Layout (NO BLOG CLASSES)
========================= */

.quiz-section {
    position: relative;
}

.quiz-card {
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    height: 100%;
    display: flex;
    flex-direction: column;
    border: 1px solid #f0f0f0;
}

.quiz-card-image {
    position: relative;
    overflow: hidden;
    height: 220px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.quiz-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.quiz-card:hover .quiz-card-image img {
    transform: scale(1.1) rotate(1deg);
}

.quiz-card-content {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.quiz-card-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--quiz-dark);
    margin-bottom: 12px;
    line-height: 1.3;
    transition: color 0.3s ease;
    text-decoration: none;
    display: block;
}

.quiz-card-title:hover {
    color: var(--quiz-primary);
    text-decoration: none;
}

.quiz-card-description {
    color: #6c757d;
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 16px;
    flex-grow: 1;
}

/* =====================
    Quiz Labels & Meta Info
========================= */

.quiz-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 16px;
    align-items: center;
}

.quiz-meta-item {
    display: flex;
    align-items: center;
    font-size: 13px;
    color: #6c757d;
    gap: 6px;
    background: #f8f9fa;
    padding: 6px 12px;
    border-radius: 20px;
    font-weight: 500;
}

.quiz-meta-item svg {
    width: 16px;
    height: 16px;
}

.quiz-meta-item.author {
    color: var(--quiz-primary);
    background: rgba(13, 164, 135, 0.1);
}

/* Difficulty Badges */
.badge {
    padding: 4px 8px;
    font-size: 11px;
    font-weight: 600;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge.badge-success {
    background: linear-gradient(90deg, #28a745 0%, #20c997 100%);
    color: white;
}

.badge.badge-warning {
    background: linear-gradient(90deg, #ffc107 0%, #fd7e14 100%);
    color: white;
}

.badge.badge-danger {
    background: linear-gradient(90deg, #dc3545 0%, #c82333 100%);
    color: white;
}

.badge.badge-info {
    background: linear-gradient(90deg, #17a2b8 0%, #138496 100%);
    color: white;
}

/* =====================
    Quiz Stats
========================= */

.quiz-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.quiz-stats small {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    color: #6c757d;
}

.quiz-stats small svg {
    width: 12px;
    height: 12px;
}

/* =====================
    Quiz Buttons
========================= */

.quiz-btn {
    display: inline-flex;
    align-items: center;
    padding: 12px 24px;
    background: linear-gradient(135deg, var(--quiz-primary) 0%, var(--quiz-primary-dark) 100%);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.4s ease;
    margin-top: auto;
    gap: 10px;
    border: none;
    cursor: pointer;
}

.quiz-btn:hover {
    color: white;
    text-decoration: none;
}

.quiz-btn.secondary {
    background: red;
}

.quiz-btn.success {
    background: linear-gradient(135deg, var(--quiz-success) 0%, #20c997 100%);
}

.quiz-btn.danger {
    background: linear-gradient(135deg, var(--quiz-danger) 0%, #c82333 100%);
}

/* =====================
    Quiz Detail Page
========================= */

.quiz-detail-image {
    height: 350px;
    overflow: hidden;
    border-radius: 12px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.quiz-detail-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.quiz-detail-content {
    padding: 35px;
}

.quiz-detail-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--quiz-dark);
    margin-bottom: 20px;
    line-height: 1.2;
}

/* =====================
    CKEditor Content Styles
========================= */

.quiz-description {
    font-size: 16px;
    line-height: 1.7;
    color: #4a5568;
    margin-bottom: 25px;
}

.quiz-description h1,
.quiz-description h2,
.quiz-description h3,
.quiz-description h4,
.quiz-description h5,
.quiz-description h6 {
    color: var(--quiz-dark);
    font-weight: 600;
    margin-top: 25px;
    margin-bottom: 15px;
    line-height: 1.3;
}

.quiz-description h1 { font-size: 28px; }
.quiz-description h2 { font-size: 24px; }
.quiz-description h3 { font-size: 20px; }
.quiz-description h4 { font-size: 18px; }
.quiz-description h5 { font-size: 16px; }
.quiz-description h6 { font-size: 14px; }

.quiz-description p {
    margin-bottom: 16px;
    line-height: 1.7;
}

.quiz-description ul,
.quiz-description ol {
    margin-bottom: 20px;
    padding-left: 30px;
}

.quiz-description li {
    margin-bottom: 8px;
    line-height: 1.6;
}

.quiz-description blockquote {
    background: #f8f9fa;
    border-left: 4px solid var(--quiz-primary);
    padding: 20px 25px;
    margin: 25px 0;
    font-style: italic;
    border-radius: 0 8px 8px 0;
}

.quiz-description strong {
    font-weight: 600;
    color: var(--quiz-dark);
}

.quiz-description a {
    color: var(--quiz-primary);
    text-decoration: none;
    font-weight: 500;
}

.quiz-description a:hover {
    color: var(--quiz-primary-dark);
    text-decoration: underline;
}

.quiz-description img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 20px 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.quiz-description table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.quiz-description table th,
.quiz-description table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #e9ecef;
}

.quiz-description table th {
    background: #f8f9fa;
    font-weight: 600;
    color: var(--quiz-dark);
}

.quiz-description pre {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 20px 0;
    border: 1px solid #e9ecef;
}

.quiz-description code {
    background: #f8f9fa;
    padding: 3px 6px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    color: #e83e8c;
}

/* =====================
    Instructions & Explanations
========================= */

.quiz-instructions-content,
.quiz-explanation .explanation-content {
    font-size: 14px;
    line-height: 1.6;
    color: #4a5568;
}

.quiz-instructions-content h1,
.quiz-instructions-content h2,
.quiz-instructions-content h3,
.quiz-instructions-content h4,
.quiz-instructions-content h5,
.quiz-instructions-content h6,
.quiz-explanation .explanation-content h1,
.quiz-explanation .explanation-content h2,
.quiz-explanation .explanation-content h3,
.quiz-explanation .explanation-content h4,
.quiz-explanation .explanation-content h5,
.quiz-explanation .explanation-content h6 {
    color: var(--quiz-dark);
    font-weight: 600;
    margin-top: 15px;
    margin-bottom: 10px;
    line-height: 1.3;
}

.quiz-instructions-content p,
.quiz-explanation .explanation-content p {
    margin-bottom: 12px;
    line-height: 1.6;
}

.quiz-instructions-content ul,
.quiz-instructions-content ol,
.quiz-explanation .explanation-content ul,
.quiz-explanation .explanation-content ol {
    margin-bottom: 15px;
    padding-left: 25px;
}

.quiz-instructions-content li,
.quiz-explanation .explanation-content li {
    margin-bottom: 6px;
    line-height: 1.5;
}

.quiz-instructions-content blockquote,
.quiz-explanation .explanation-content blockquote {
    background: #f8f9fa;
    border-left: 3px solid var(--quiz-primary);
    padding: 15px 20px;
    margin: 15px 0;
    font-style: italic;
    border-radius: 0 6px 6px 0;
}

.quiz-instructions-content strong,
.quiz-explanation .explanation-content strong {
    font-weight: 600;
    color: var(--quiz-dark);
}

.quiz-instructions-content a,
.quiz-explanation .explanation-content a {
    color: var(--quiz-primary);
    text-decoration: none;
    font-weight: 500;
}

.quiz-instructions-content a:hover,
.quiz-explanation .explanation-content a:hover {
    color: var(--quiz-primary-dark);
    text-decoration: underline;
}

.quiz-instructions-content img,
.quiz-explanation .explanation-content img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    margin: 15px 0;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.quiz-instructions-content code,
.quiz-explanation .explanation-content code {
    background: #f8f9fa;
    padding: 2px 4px;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    color: #e83e8c;
}

.quiz-instructions-content pre,
.quiz-explanation .explanation-content pre {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 6px;
    overflow-x: auto;
    margin: 15px 0;
    border: 1px solid #e9ecef;
}

.quiz-explanation {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 0;
    overflow: hidden;
}

.quiz-explanation .explanation-content {
    padding: 15px;
    margin: 0;
}

/* =====================
    Quiz Modal Question Content
========================= */

.question-text {
    font-size: 18px;
    font-weight: 600;
    color: var(--quiz-dark);
    margin-bottom: 20px;
    line-height: 1.4;
}

.question-text h1,
.question-text h2,
.question-text h3,
.question-text h4,
.question-text h5,
.question-text h6 {
    color: var(--quiz-dark);
    font-weight: 600;
    margin-top: 10px;
    margin-bottom: 10px;
    line-height: 1.3;
}

.question-text h1 { font-size: 20px; }
.question-text h2 { font-size: 19px; }
.question-text h3 { font-size: 18px; }
.question-text h4 { font-size: 17px; }
.question-text h5 { font-size: 16px; }
.question-text h6 { font-size: 15px; }

.question-text p {
    margin-bottom: 12px;
    line-height: 1.5;
}

.question-text ul,
.question-text ol {
    margin-bottom: 15px;
    padding-left: 20px;
}

.question-text li {
    margin-bottom: 5px;
    line-height: 1.4;
}

.question-text strong {
    font-weight: 700;
    color: var(--quiz-dark);
}

.question-text em {
    font-style: italic;
    color: #6c757d;
}

.question-text a {
    color: var(--quiz-primary);
    text-decoration: none;
    font-weight: 500;
}

.question-text a:hover {
    color: var(--quiz-primary-dark);
    text-decoration: underline;
}

.question-text code {
    background: #f8f9fa;
    padding: 2px 4px;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    color: #e83e8c;
}

.question-text blockquote {
    background: #f8f9fa;
    border-left: 3px solid var(--quiz-primary);
    padding: 10px 15px;
    margin: 10px 0;
    font-style: italic;
    border-radius: 0 4px 4px 0;
}

.question-text img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin: 10px 0;
}

/* =====================
    Quiz Info Card
========================= */

.quiz-info-card .card {
    border: 1px solid var(--quiz-border);
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.quiz-info-card .card-header {
    background: linear-gradient(90deg, var(--quiz-primary) 0%, var(--quiz-primary-dark) 100%);
    color: white;
    border-bottom: none;
    border-radius: 10px 10px 0 0 !important;
    font-weight: 600;
}

.quiz-info-card .card-body ul li {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-size: 14px;
}

.quiz-info-card .card-body ul li svg {
    width: 16px;
    height: 16px;
    color: var(--quiz-primary);
}

/* =====================
    Quiz Attempts Table
========================= */

.quiz-attempts-card .card {
    border: 1px solid var(--quiz-border);
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.quiz-attempts-card .card-header {
    background: #f8f9fa;
    border-bottom: 1px solid var(--quiz-border);
    font-weight: 600;
    color: var(--quiz-dark);
}

.quiz-attempts-card .table {
    margin-bottom: 0;
}

.quiz-attempts-card .table th {
    background: #f8f9fa;
    border-top: none;
    font-weight: 600;
    color: var(--quiz-dark);
    font-size: 13px;
    padding: 12px;
}

.quiz-attempts-card .table td {
    padding: 12px;
    vertical-align: middle;
    font-size: 14px;
}

/* =====================
    Quiz Start Section
========================= */

.quiz-start-section {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 10px;
    margin: 20px 0;
}

.quiz-start-section .btn {
    padding: 12px 30px;
    font-size: 16px;
    font-weight: 600;
}

/* =====================
    Quiz Instructions
========================= */

.quiz-instructions .card {
    border: 1px solid #dee2e6;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.quiz-instructions .card-body {
    background: #f8f9fa;
    font-size: 14px;
    line-height: 1.6;
}

/* =====================
    Quiz Modal
========================= */

.quiz-modal .modal-dialog {
    max-width: 900px;
}

.quiz-modal .modal-header {
    background: linear-gradient(90deg, var(--quiz-primary) 0%, var(--quiz-primary-dark) 100%);
    color: white;
    border-bottom: none;
}

.quiz-modal .quiz-timer {
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 14px;
}

.quiz-modal .question-block .card {
    border: 1px solid var(--quiz-border);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.quiz-modal .question-block .card-header {
    background: #f8f9fa;
    border-bottom: 1px solid var(--quiz-border);
}

.quiz-modal .question-block .progress {
    height: 6px;
    background: #e9ecef;
}

.quiz-modal .question-block .progress-bar {
    background: linear-gradient(90deg, var(--quiz-primary) 0%, var(--quiz-primary-dark) 100%);
}

.quiz-modal .form-check {
    padding: 12px 15px;
    margin: 0;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.quiz-modal .form-check:hover {
    background: #f8f9fa;
}

.quiz-modal .form-check-input:checked {
    background-color: var(--quiz-primary);
    border-color: var(--quiz-primary);
}

/* =====================
    Quiz Results Page
========================= */

.quiz-results-summary {
    text-align: center;
    padding: 30px;
    border-radius: 15px;
    margin-bottom: 30px;
}

.quiz-results-summary.success {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
}

.quiz-results-summary.failed {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    color: white;
}

.quiz-results-summary h2 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 10px;
}

.quiz-results-summary .stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.quiz-results-summary .stat-item {
    text-align: center;
}

.quiz-results-summary .stat-item h5 {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 5px;
}

.quiz-results-summary .stat-item small {
    opacity: 0.9;
    font-size: 12px;
}

/* =====================
    Question Results
========================= */

.question-result {
    margin-bottom: 20px;
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.question-result.correct {
    background: rgba(40, 167, 69, 0.05);
}

.question-result.incorrect {
    background: rgba(220, 53, 69, 0.05);
}

.answer-feedback {
    padding: 12px 15px;
    border-radius: 6px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.answer-feedback.correct {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.answer-feedback.incorrect {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.answer-feedback.not-answered {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

.answer-feedback svg {
    width: 18px;
    height: 18px;
}

/* =====================
    My Attempts Page
========================= */

.attempts-filters {
    background: white;
    border-radius: 10px;
    box-shadow: var(--quiz-shadow);
    margin-bottom: 30px;
}

.attempts-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    border-radius: 10px;
    box-shadow: var(--quiz-shadow);
    padding: 20px;
    text-align: center;
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--quiz-shadow-hover);
}

.stat-card h4 {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 5px;
}

.stat-card.primary h4 {
    color: var(--quiz-primary);
}

.stat-card.success h4 {
    color: #28a745;
}

.stat-card.info h4 {
    color: #17a2b8;
}

.stat-card small {
    color: #6c757d;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* =====================
    Sidebar Styles
========================= */

.left-sidebar-box .left-search-box .search-box input {
    border: 1px solid var(--quiz-border);
    border-radius: 25px;
    padding: 10px 20px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.left-sidebar-box .left-search-box .search-box input:focus {
    border-color: var(--quiz-primary);
    box-shadow: 0 0 0 0.2rem rgba(13, 164, 135, 0.25);
}

.left-sidebar-box .accordion-button {
    background: #f8f9fa;
    color: var(--quiz-dark);
    font-weight: 600;
    border: none;
    border-radius: 8px !important;
}

.left-sidebar-box .accordion-button:not(.collapsed) {
    background: var(--quiz-primary);
    color: white;
}

/* =====================
    Responsive Design
========================= */

@media (max-width: 768px) {
    .quiz-box .blog-image {
        height: 180px;
    }

    .quiz-detail-box .blog-detail {
        padding: 20px;
    }

    .quiz-detail-box .blog-detail h3 {
        font-size: 22px;
    }

    .quiz-modal .modal-dialog {
        margin: 10px;
        max-width: calc(100% - 20px);
    }

    .quiz-results-summary {
        padding: 20px;
    }

    .quiz-results-summary h2 {
        font-size: 36px;
    }

    .attempts-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    .stat-card {
        padding: 15px;
    }

    .stat-card h4 {
        font-size: 24px;
    }
}

@media (max-width: 480px) {
    .quiz-box .blog-contain {
        padding: 15px;
    }

    .quiz-detail-box .blog-detail {
        padding: 15px;
    }

    .quiz-info-card .card-body ul li {
        font-size: 13px;
    }

    .attempts-stats {
        grid-template-columns: 1fr;
    }

    .quiz-results-summary .stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
}

/* =====================
    Animation Classes
========================= */

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.quiz-box {
    animation: slideInUp 0.6s ease forwards;
}

.quiz-box:nth-child(even) {
    animation-delay: 0.1s;
}

.quiz-box:nth-child(odd) {
    animation-delay: 0.2s;
}

/* =====================
    Loading States
========================= */

.quiz-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.quiz-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--quiz-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* =====================
    Quiz Custom Toasts
========================= */

.quiz-toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    max-width: 350px;
}

.quiz-toast {
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.15);
    margin-bottom: 10px;
    overflow: hidden;
    transform: translateX(400px);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    border-left: 4px solid var(--quiz-primary);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.quiz-toast.show {
    transform: translateX(0);
}

.quiz-toast.hide {
    transform: translateX(400px);
    opacity: 0;
}

.quiz-toast-header {
    display: flex;
    align-items: center;
    padding: 15px 20px 10px 20px;
    gap: 10px;
}

.quiz-toast-icon {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.quiz-toast-icon svg {
    width: 14px;
    height: 14px;
    color: white;
}

.quiz-toast.success {
    border-left-color: var(--quiz-success);
}

.quiz-toast.success .quiz-toast-icon {
    background: var(--quiz-success);
}

.quiz-toast.error {
    border-left-color: var(--quiz-danger);
}

.quiz-toast.error .quiz-toast-icon {
    background: var(--quiz-danger);
}

.quiz-toast.warning {
    border-left-color: var(--quiz-warning);
}

.quiz-toast.warning .quiz-toast-icon {
    background: var(--quiz-warning);
}

.quiz-toast.info {
    border-left-color: var(--quiz-info);
}

.quiz-toast.info .quiz-toast-icon {
    background: var(--quiz-info);
}

.quiz-toast-title {
    font-weight: 600;
    font-size: 14px;
    color: var(--quiz-dark);
    margin: 0;
}

.quiz-toast-close {
    margin-left: auto;
    background: none;
    border: none;
    color: #6c757d;
    cursor: pointer;
    padding: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.quiz-toast-close:hover {
    background: #f8f9fa;
    color: var(--quiz-dark);
}

.quiz-toast-body {
    padding: 0 20px 15px 54px;
    font-size: 13px;
    color: #6c757d;
    line-height: 1.4;
}

.quiz-toast-progress {
    height: 3px;
    background: #f8f9fa;
    overflow: hidden;
}

.quiz-toast-progress-bar {
    height: 100%;
    background: var(--quiz-primary);
    width: 100%;
    animation: toastProgress 4s linear forwards;
}

.quiz-toast.success .quiz-toast-progress-bar {
    background: var(--quiz-success);
}

.quiz-toast.error .quiz-toast-progress-bar {
    background: var(--quiz-danger);
}

.quiz-toast.warning .quiz-toast-progress-bar {
    background: var(--quiz-warning);
}

.quiz-toast.info .quiz-toast-progress-bar {
    background: var(--quiz-info);
}

@keyframes toastProgress {
    from {
        width: 100%;
    }
    to {
        width: 0%;
    }
}

/* Quiz Timer Toast (Special Style) */
.quiz-timer-toast {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(135deg, var(--quiz-danger) 0%, #c82333 100%);
    color: white;
    padding: 20px 30px;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    z-index: 10000;
    box-shadow: 0 10px 40px rgba(220, 53, 69, 0.4);
    animation: pulseWarning 1s ease-in-out infinite;
}

@keyframes pulseWarning {
    0%, 100% {
        transform: translate(-50%, -50%) scale(1);
    }
    50% {
        transform: translate(-50%, -50%) scale(1.05);
    }
}

/* =====================
    Theme Integration
========================= */

[data-theme="dark"] .quiz-card,
[data-theme="dark"] .quiz-detail-container,
[data-theme="dark"] .stat-card {
    background: #2d3748;
    color: #e2e8f0;
    border-color: #4a5568;
}

[data-theme="dark"] .quiz-card-title,
[data-theme="dark"] .quiz-detail-title {
    color: #e2e8f0;
}

[data-theme="dark"] .quiz-info-card .card,
[data-theme="dark"] .quiz-attempts-card .card {
    background: #2d3748;
    border-color: #4a5568;
}

[data-theme="dark"] .quiz-info-card .card-body,
[data-theme="dark"] .quiz-attempts-card .card-body {
    color: #e2e8f0;
}

[data-theme="dark"] .quiz-toast {
    background: #2d3748;
    border-color: #4a5568;
    color: #e2e8f0;
}

[data-theme="dark"] .quiz-toast-title {
    color: #e2e8f0;
}

[data-theme="dark"] .quiz-toast-close:hover {
    background: #4a5568;
    color: #e2e8f0;
}
