/* ========================================
   SINGLE QUIZ PAGE STYLING
   ======================================== */

/* Wrapper */
.tty-single-quiz-wrapper {
    position: relative;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 20px 100px;
}

/* Breadcrumbs - Modern Style (matching blog) */
.quiz-breadcrumbs-modern {
    animation: fadeInUp 0.6s ease-out;
}

.tty-single-quiz-wrapper::before {
  content: '';
  position: absolute;
  top: 0;
  left: 9%;
  width: 40%;
  height: 100%;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M30 5v10m0 30v10m-20-25h10m30 0h10' stroke='%23005F5F' stroke-width='1'/%3E%3Ccircle cx='30' cy='30' r='5' fill='%23005F5F'/%3E%3Ccircle cx='30' cy='15' r='2' fill='%23005F5F'/%3E%3Ccircle cx='30' cy='45' r='2' fill='%23005F5F'/%3E%3Ccircle cx='20' cy='30' r='2' fill='%23005F5F'/%3E%3Ccircle cx='40' cy='30' r='2' fill='%23005F5F'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
}

.quiz-breadcrumbs-modern ol {
    display: flex;
    align-items: center;
    gap: 30px;
    list-style: none;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
}

.quiz-breadcrumbs-modern li {
    position: relative;
    font-size: 14px;
}

.quiz-breadcrumbs-modern li:not(:last-child)::after {
    content: '';
    position: absolute;
    right: -16px;
    top: 50%;
    width: 6px;
    height: 6px;
    border-top: 2px solid #6c757d;
    border-right: 2px solid #6c757d;
    transform: translateY(-50%) rotate(45deg);
    opacity: 0.5;
}

.quiz-breadcrumbs-modern a {
    color: var(--tty-text-secondary);
    text-decoration: none;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.quiz-breadcrumbs-modern a:hover {
    color: var(--tty-secondary-dark);
}

.quiz-breadcrumbs-modern .current a {
    opacity: .4;
    font-weight: 600;
    max-width: 8ch;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: block;
}

.quiz-breadcrumbs-modern .sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Breadcrumb Animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Dark Theme - Breadcrumbs */
[data-theme="dark"] .quiz-breadcrumbs-modern a {
    color: #adb5bd;
}

[data-theme="dark"] .quiz-breadcrumbs-modern a:hover {
    color: #fff;
}

[data-theme="dark"] .quiz-breadcrumbs-modern .current {
    color: #adb5bd;
}

[data-theme="dark"] .quiz-breadcrumbs-modern li:not(:last-child)::after {
    border-color: #6c757d;
}



/* Quiz Header */
.tty-single-quiz-header {
    margin-bottom: 30px;
}

.tty-quiz-meta-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    padding: 10px;
    background: var(--tty-bg-secondary);
    border-radius: 30px;
    animation: fadeInUp 0.6s ease-out 0.2s both;
}

.tty-quiz-meta-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tty-quiz-meta-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 20px;
    background: rgba(0, 95, 95, 0.1);
    color: var(--tty-primary);
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}

.tty-quiz-meta-stats {
    display: flex;
    gap: 40px;
    margin-right: 15px;
}

.tty-quiz-meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: #666;
}

.tty-quiz-meta-item i {
    color: var(--tty-primary);
}

/* Quiz Content Area */
.tty-single-quiz-content {
    /* Remove any extra margins from the quiz container */
}

/* No Questions State */
.tty-quiz-no-questions {
    text-align: center;
    padding: 60px 30px;
    background: var(--tty-bg-secondary);
    border-radius: 20px;
}

.tty-quiz-no-questions p {
    color: #666;
    font-size: 16px;
}

/* Hide default WordPress title if theme shows it */
.tty-single-quiz .entry-title,
.tty-single-quiz .page-title,
.tty-single-quiz > .tty-single-quiz-wrapper > h1 {
    display: none;
}

/* Dark Theme */
[data-theme="dark"] .tty-quiz-meta-bar {
    background: var(--tty-bg-tertiary);
}

[data-theme="dark"] .tty-breadcrumb-current,
[data-theme="dark"] .tty-quiz-meta-item {
    color: #aaa;
}

[data-theme="dark"] .tty-quiz-meta-tag {
    background: rgba(0, 95, 95, 0.2);
}

/* Responsive */
@media (max-width: 768px) {
    .tty-quiz-meta-bar {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    /* Compact horizontal stats bar - like global stats */
    .tty-quiz-meta-stats {
        display: flex;
        flex-wrap: nowrap;
        gap: 0;
        margin-right: 0;
        width: 100%;
        background: linear-gradient(135deg, var(--tty-text-light, #fff) 0%, rgba(255, 255, 255, 0.95) 100%);
        border-radius: 16px;
        padding: 12px 8px;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
        border: 1px solid rgba(0, 95, 95, 0.1);
    }
    
    .tty-quiz-meta-item {
        flex: 1;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
        font-size: 12px;
        gap: 2px;
        padding: 4px 2px;
    }
    
    /* Dividers between stats */
    .tty-quiz-meta-item:not(:last-child) {
        border-right: 1px solid rgba(0, 95, 95, 0.15);
    }
    
    .tty-quiz-meta-item i {
        font-size: 14px;
        margin-bottom: 2px;
    }
    
    .tty-quiz-breadcrumb {
        font-size: 13px;
    }
    
    .quiz-breadcrumbs-modern ol {
        gap: 20px;
    }
    
    .quiz-breadcrumbs-modern li:not(:last-child)::after {
        right: -12px;
    }
}

@media (max-width: 576px) {
    .tty-single-quiz-wrapper {
        padding: 15px 15px 40px;
    }
    
    .tty-quiz-meta-bar {
        background: none;
        padding: 0px;
    }
    
    .tty-quiz-meta-stats {
        padding: 10px 4px;
    }
    
    .tty-quiz-meta-item {
        font-size: 11px;
    }
    
    .tty-quiz-meta-item i {
        font-size: 12px;
    }
    
    .tty-quiz-meta-categories {
        margin-bottom: 10px;
    }
}

/* Quiz Title (H1) */
.tty-single-quiz-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--tty-primary);
    margin: 0 0 20px 0;
    line-height: 1.3;
}

/* Category tags as links */
a.tty-quiz-meta-tag {
    text-decoration: none;
    transition: all 0.3s ease;
}

a.tty-quiz-meta-tag:hover {
    background: rgba(0, 95, 95, 0.2);
    transform: translateY(-1px);
}

/* New quiz badge */
.tty-quiz-meta-item.tty-quiz-new {
    color: var(--tty-primary);
    font-weight: 600;
}

/* Back navigation */
.tty-quiz-back-nav {
    margin-top: 40px;
}

.tty-quiz-back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--tty-primary);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.tty-quiz-back-link:hover {
    gap: 12px;
}

/* Screen reader only */
.sr-only,
.screen-reader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Dark Theme */
[data-theme="dark"] .tty-single-quiz-title {
    color: var(--tty-text-light);
}

[data-theme="dark"] .tty-quiz-back-nav {
    border-top-color: rgba(255, 255, 255, 0.1);
}

/* Responsive */
@media (max-width: 768px) {
    .tty-single-quiz-title {
        font-size: 26px;
    }
}

@media (max-width: 576px) {
    .tty-single-quiz-title {
        font-size: 22px;
    }
    
    .tty-single-quiz-intro {
        padding: 12px 15px;
    }
}

/* =====================================================
   SINGLE QUIZ PAGE - COMPLETE STYLES
   ===================================================== */

/* Quiz Title (H1) */
.tty-single-quiz-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--tty-primary);
    margin: 0 0 15px 0;
    line-height: 1.3;
}

/* Quiz Introduction */
.tty-single-quiz-intro {
    margin-bottom: 20px;
    padding: 15px 20px;
    background: rgba(0, 95, 95, 0.05);
    border-left: 4px solid var(--tty-primary);
    border-radius: 0 8px 8px 0;
}

.tty-single-quiz-intro p {
    margin: 0;
    font-size: 16px;
    line-height: 1.6;
    color: var(--tty-text-secondary);
}

/* Category tags as links */
a.tty-quiz-meta-tag {
    text-decoration: none;
    transition: all 0.3s ease;
}

a.tty-quiz-meta-tag:hover {
    background: rgba(0, 95, 95, 0.2);
    transform: translateY(-1px);
}

/* New quiz badge */
.tty-quiz-meta-item.tty-quiz-new {
    color: var(--tty-primary);
    font-weight: 600;
}

/* Quiz Summary Section */
.tty-quiz-summary {
    margin-top: 140px;
    padding: 25px;
    background: var(--tty-bg-secondary);
    border-radius: 30px;
    border: 1px solid rgba(0, 95, 95, 0.1);
}

.tty-quiz-summary-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

.tty-quiz-summary-item {
    text-align: center;
    padding: 15px;
    background: var(--tty-bg-primary, #fff);
    border-radius: 12px;
    z-index: 1;
}

.tty-summary-label {
    display: block;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--tty-text-secondary);
    margin-bottom: 5px;
}

.tty-summary-value {
    display: block;
    font-size: 24px;
    font-weight: 700;
    color: var(--tty-primary);
}

.tty-quiz-topics {
    font-size: 14px;
}

.tty-topics-label {
    font-weight: 600;
    color: var(--tty-text-secondary);
    margin-right: 8px;
}

.tty-topics-list {
    color: var(--tty-text-primary);
}

/* No Questions State */
.tty-quiz-no-questions {
    text-align: center;
    padding: 60px 20px;
    background: var(--tty-bg-secondary);
    border-radius: 12px;
}

.tty-quiz-no-questions i {
    font-size: 48px;
    color: var(--tty-primary);
    opacity: 0.5;
    margin-bottom: 15px;
}


.tty-quiz-back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--tty-primary);
    text-decoration: none;
    font-weight: 600;
    padding: 12px 20px;
    background: rgba(0, 95, 95, 0.05);
    border-radius: 30px;
    transition: all 0.3s ease;
}

.tty-quiz-back-link:hover {
    gap: 12px;
    background: rgba(0, 95, 95, 0.1);
}

/* Screen reader only */
.sr-only,
.screen-reader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* =====================================================
   DARK THEME
   ===================================================== */
[data-theme="dark"] .tty-single-quiz-title {
    color: var(--tty-text-light);
}

[data-theme="dark"] .tty-single-quiz-intro {
    background: rgba(255, 255, 255, 0.05);
    border-left-color: var(--tty-accent, #4fd1c5);
}

[data-theme="dark"] .tty-single-quiz-intro p {
    color: var(--tty-text-light);
}

[data-theme="dark"] .tty-quiz-summary {
    background: var(--tty-bg-tertiary);
    border-color: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .tty-quiz-summary-item {
    background: var(--tty-bg-secondary);
}

[data-theme="dark"] .tty-summary-value {
    color: var(--tty-accent, #4fd1c5);
}

[data-theme="dark"] .tty-quiz-topics {
    border-top-color: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .tty-quiz-back-nav {
    border-top-color: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .tty-quiz-back-link {
    background: rgba(255, 255, 255, 0.05);
    color: var(--tty-accent, #4fd1c5);
}

[data-theme="dark"] .tty-quiz-back-link:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* =====================================================
   RESPONSIVE
   ===================================================== */
@media (max-width: 992px) {
    .tty-quiz-summary-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .tty-single-quiz-title {
        font-size: 26px;
    }
    
    .tty-quiz-summary {
        padding: 20px;
    }
    
    .tty-quiz-summary-grid {
        gap: 15px;
    }
    
    .tty-summary-value {
        font-size: 20px;
    }
}

@media (max-width: 576px) {
    .tty-single-quiz-title {
        font-size: 22px;
    }
    
    .tty-single-quiz-intro {
        padding: 12px 15px;
    }
    
    .tty-quiz-summary {
        padding: 15px;
        margin-top: 30px;
    }
    
    .tty-quiz-summary-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .tty-quiz-summary-item {
        padding: 12px 10px;
    }
    
    .tty-summary-label {
        font-size: 10px;
    }
    
    .tty-summary-value {
        font-size: 18px;
    }
    
    .tty-quiz-back-nav {
        margin-top: 30px;
        padding-top: 20px;
    }
    
    .tty-quiz-back-link {
        width: 100%;
        justify-content: center;
    }
}

