/* â”€â”€â”€ Exam Page Wrapper â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€ */
.exam-page-wrapper {
    background: var(--bg-primary);
    min-height: 100vh;
}

/* â”€â”€â”€ Modern Hero Section â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€ */
.exam-hero {
    background: var(--bg-card);
    padding: clamp(3rem, 6vw, 5rem) 0;
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid var(--border-color);
}

.exam-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: 
        radial-gradient(circle at 15% 50%, rgba(90, 93, 233, 0.04) 0%, transparent 25%),
        radial-gradient(circle at 85% 30%, rgba(90, 93, 233, 0.06) 0%, transparent 25%);
    pointer-events: none;
}

.exam-hero-inner {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 3rem;
}

.exam-hero-content {
    max-width: 650px;
    flex: 1;
}

.exam-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--bg-secondary);
    color: var(--primary);
    padding: 0.5rem 1rem;
    border-radius: 99px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(90, 93, 233, 0.1);
    box-shadow: var(--shadow-sm);
}

.exam-hero-title {
    font-family: 'Outfit', var(--font-family);
    font-size: clamp(2.25rem, 5vw, 3.5rem);
    font-weight: 800;
    line-height: 1.15;
    margin: 0 0 1rem;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

.exam-hero-title .text-primary {
    color: var(--primary);
    display: block;
}

.exam-hero-subtitle {
    font-size: clamp(1.125rem, 2vw, 1.25rem);
    color: var(--text-secondary);
    margin: 0 0 2rem;
    line-height: 1.6;
    max-width: 580px;
}

.exam-hero-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.exam-stat {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: var(--bg-primary);
    padding: 1rem 1.25rem;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    flex: 1;
    min-width: 140px;
}

.exam-stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: var(--bg-secondary);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.exam-stat-info {
    display: flex;
    flex-direction: column;
}

.exam-stat-val {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1.2;
    font-family: 'Outfit', var(--font-family);
}

.exam-stat-label {
    font-size: 0.8125rem;
    color: var(--text-muted);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 0.25rem;
}

/* Geometric Illustration */
.exam-hero-illustration {
    flex: 1;
    position: relative;
    height: 400px;
    max-width: 450px;
    display: none;
}

@media (min-width: 992px) {
    .exam-hero-illustration {
        display: block;
    }
}

.hero-shape {
    position: absolute;
    border-radius: 24px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-lg);
}

.shape-1 {
    width: 250px;
    height: 280px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-5deg);
    z-index: 2;
    background: linear-gradient(135deg, var(--primary-50), var(--bg-card));
    border-color: var(--primary-200);
}

.shape-2 {
    width: 220px;
    height: 250px;
    top: 50%;
    left: 50%;
    transform: translate(-30%, -60%) rotate(10deg);
    z-index: 1;
    opacity: 0.6;
}

.shape-3 {
    width: 180px;
    height: 180px;
    bottom: 20px;
    left: 10px;
    border-radius: 50%;
    transform: rotate(45deg);
    z-index: 3;
    background: linear-gradient(135deg, var(--bg-card), var(--bg-primary));
}

/* â”€â”€â”€ Category Navigation â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€ */
.exam-hub {
    padding: clamp(3rem, 5vw, 5rem) 0;
}

.exam-hub-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.exam-hub-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    font-family: 'Outfit', var(--font-family);
    margin: 0 0 0.5rem;
}

.exam-hub-desc {
    color: var(--text-secondary);
    font-size: 1.125rem;
    margin: 0;
}

.exam-category-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 3.5rem;
}

.exam-cat-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    border-radius: 99px;
    font-size: 0.9375rem;
    font-weight: 600;
    text-decoration: none;
    color: var(--text-secondary);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    white-space: nowrap;
}

.exam-cat-pill .pill-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    transition: color 0.3s ease;
}

.exam-cat-pill:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    color: var(--primary);
}

.exam-cat-pill:hover .pill-icon {
    color: var(--primary);
}

.exam-cat-pill.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    box-shadow: 0 8px 16px rgba(90, 93, 233, 0.25);
}

.exam-cat-pill.active .pill-icon {
    color: #fff;
}

.exam-cat-pill .pill-count {
    background: var(--bg-primary);
    color: var(--text-secondary);
    padding: 0.125rem 0.5rem;
    border-radius: 99px;
    font-size: 0.75rem;
    font-weight: 700;
    margin-left: 0.25rem;
    transition: all 0.3s ease;
}

.exam-cat-pill.active .pill-count {
    background: rgba(255,255,255,0.2);
    color: #fff;
}

/* â”€â”€â”€ Category Sections â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€ */
.exam-category-section {
    margin-bottom: 4rem;
    scroll-margin-top: 100px;
    background: var(--bg-card);
    border-radius: 24px;
    padding: clamp(1.5rem, 3vw, 2.5rem);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
}

.exam-category-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.exam-category-header-inner {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.exam-category-icon {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.exam-category-title-group h2 {
    font-family: 'Outfit', var(--font-family);
    font-size: 1.75rem;
    font-weight: 800;
    margin: 0 0 0.375rem;
    color: var(--text-primary);
}

.exam-category-title-group p {
    margin: 0;
    font-size: 1rem;
    color: var(--text-secondary);
}

.exam-view-all {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: var(--primary);
    text-decoration: none;
    font-size: 0.9375rem;
    padding: 0.5rem 1rem;
    border-radius: 99px;
    background: var(--bg-primary);
    transition: all 0.2s ease;
}

.exam-view-all:hover {
    background: var(--primary-50);
    transform: translateX(4px);
}

/* â”€â”€â”€ Exam Cards Grid â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€â”€ */
.exam-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
    gap: 1.5rem;
}

.exam-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
}

.exam-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-200);
}

.exam-card-image {
    aspect-ratio: 16 / 9;
    overflow: hidden;
    position: relative;
    background: var(--bg-primary);
}

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

.exam-card:hover .exam-card-image img {
    transform: scale(1.08);
}

.exam-card-image-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.5s ease;
}

.exam-card:hover .exam-card-image-placeholder {
    transform: scale(1.08);
}

.exam-card-badge-wrap {
    position: absolute;
    top: 16px;
    left: 16px;
    z-index: 2;
}

.exam-card-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    box-shadow: var(--shadow-sm);
    backdrop-filter: blur(4px);
}

.exam-card-body {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    background: var(--bg-card);
}

.exam-card-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
    font-weight: 500;
}

.exam-card-meta time {
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.exam-card-title {
    font-size: 1.125rem;
    font-weight: 700;
    line-height: 1.4;
    margin: 0 0 0.75rem;
    font-family: 'Outfit', var(--font-family);
}

.exam-card-title a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.2s ease;
}

.exam-card-title a:hover {
    color: var(--primary);
}

.exam-card-title a::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
}

.exam-card-desc {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 0 0 1.5rem;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.exam-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1.25rem;
    border-top: 1px solid var(--border-color);
}

.exam-card-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: var(--primary);
    text-decoration: none;
    font-size: 0.9375rem;
    position: relative;
    z-index: 2;
    transition: color 0.2s ease;
}

.exam-card-link .link-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--primary-50);
    transition: all 0.3s ease;
}

.exam-card:hover .exam-card-link .link-icon {
    background: var(--primary);
    color: #fff;
    transform: translateX(4px);
}

/* ─── Empty State ────────────────────────────────────────────── */
.exam-empty {
    text-align: center;
    padding: 5rem 2rem;
    background: var(--bg-card);
    border-radius: 24px;
    border: 2px dashed var(--border-color);
    max-width: 600px;
    margin: 0 auto;
}

.exam-empty-icon {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    display: inline-flex;
    padding: 1.5rem;
    background: var(--bg-primary);
    border-radius: 24px;
}

.exam-empty h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 0.75rem;
    color: var(--text-primary);
    font-family: 'Outfit', var(--font-family);
}

.exam-empty p {
    color: var(--text-secondary);
    margin: 0 0 1.5rem;
    font-size: 1.0625rem;
}

/* ─── Exam Index Page Mobile Enhancements ─── */
@media (max-width: 768px) {
    .exam-hero {
        padding: 2.5rem 0 2rem;
        text-align: center;
        background: linear-gradient(180deg, var(--bg-card) 0%, rgba(90, 93, 233, 0.03) 100%);
    }

    .exam-hero-inner {
        flex-direction: column;
        gap: 1.5rem;
    }

    .exam-hero-content {
        display: flex;
        flex-direction: column;
        align-items: center;
        max-width: 100%;
        margin: 0 auto;
    }

    .exam-hero-badge {
        margin-bottom: 1rem;
        font-size: 0.75rem;
        padding: 0.375rem 0.875rem;
    }

    .exam-hero-title {
        font-size: 2.125rem;
        margin-bottom: 0.75rem;
    }
    
    .exam-hero-subtitle {
        font-size: 1rem;
        margin-bottom: 2rem;
        padding: 0 1rem;
    }

    .exam-hero-stats {
        width: 100%;
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
        padding: 0 0.5rem;
    }

    .exam-stat {
        padding: 1.25rem 1rem;
        min-width: 0;
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
        border-radius: 20px;
        background: rgba(255, 255, 255, 0.5);
        backdrop-filter: blur(10px);
    }
    
    [data-theme="dark"] .exam-stat {
        background: rgba(30, 41, 59, 0.5);
    }

    .exam-stat:last-child {
        grid-column: 1 / -1;
        flex-direction: row;
        padding: 1rem;
    }
    
    .exam-stat:last-child .exam-stat-icon {
        margin: 0;
    }
    
    .exam-stat:last-child .exam-stat-info {
        text-align: left;
    }

    .exam-stat-icon {
        margin: 0 auto;
        width: 40px;
        height: 40px;
    }
    
    .exam-stat-icon svg {
        width: 20px;
        height: 20px;
    }

    .exam-stat-val {
        font-size: 1.25rem;
    }

    .exam-hub {
        padding: 2rem 0;
    }

    .exam-hub-header {
        margin-bottom: 1.5rem;
    }

    .exam-hub-title {
        font-size: 1.75rem;
    }
    
    .exam-hub-desc {
        font-size: 0.9375rem;
    }

    /* Scrollable Category Nav */
    .exam-category-nav {
        flex-wrap: nowrap;
        overflow-x: auto;
        justify-content: flex-start;
        padding-bottom: 1rem;
        margin-bottom: 2rem;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: 0.625rem;
        margin-inline: -15px; /* Assuming container padding is 15px */
        padding-inline: 15px;
    }

    .exam-category-nav::-webkit-scrollbar {
        display: none;
    }

    .exam-cat-pill {
        flex-shrink: 0;
        padding: 0.625rem 1rem;
        font-size: 0.875rem;
    }
    
    .exam-cat-pill .pill-icon svg {
        width: 16px;
        height: 16px;
    }

    /* Category Section Header */
    .exam-category-section {
        padding: 1.25rem;
        border-radius: 20px;
        margin-bottom: 1.5rem;
        background: transparent;
        border: none;
        box-shadow: none;
    }

    .exam-category-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
        margin-bottom: 1.25rem;
        padding-bottom: 1.25rem;
    }

    .exam-category-header-inner {
        width: 100%;
        gap: 1rem;
    }
    
    .exam-category-icon {
        width: 48px;
        height: 48px;
        border-radius: 12px;
    }
    
    .exam-category-icon svg {
        width: 24px;
        height: 24px;
    }
    
    .exam-category-title-group h2 {
        font-size: 1.25rem;
    }
    
    .exam-category-title-group p {
        font-size: 0.875rem;
        line-height: 1.4;
    }

    .exam-view-all {
        align-self: stretch;
        justify-content: center;
        background: var(--bg-card);
        border: 1px solid var(--border-color);
        box-shadow: var(--shadow-sm);
        margin-top: 0;
    }

    /* Card Grid Adjustments */
    .exam-cards-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    /* Horizontal Card Style for Mobile */
    .exam-card {
        flex-direction: row;
        border-radius: 16px;
        background: var(--bg-card);
        box-shadow: var(--shadow-sm);
    }
    
    .exam-card-image {
        width: 110px;
        aspect-ratio: 1; /* Square */
        border-radius: 16px 0 0 16px;
        flex-shrink: 0;
    }
    
    .exam-card-image-placeholder svg {
        width: 32px;
        height: 32px;
    }
    
    .exam-card-badge-wrap {
        display: none; /* Hide floating badge to save space */
    }

    .exam-card-body {
        padding: 0.875rem 1rem;
        justify-content: space-between;
    }

    .exam-card-meta {
        margin-bottom: 0.375rem;
        font-size: 0.75rem;
    }

    .exam-card-title {
        font-size: 1rem;
        margin-bottom: 0.375rem;
        line-height: 1.3;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .exam-card-desc {
        display: none; /* Hide desc on mobile */
    }

    .exam-card-footer {
        padding-top: 0.5rem;
        border-top: none;
        margin-top: auto;
    }
    
    .exam-card-link {
        font-size: 0.8125rem;
    }
    
    .exam-card-link .link-icon {
        width: 20px;
        height: 20px;
    }
    
    .exam-card-link .link-icon svg {
        width: 12px;
        height: 12px;
    }
    
    .exam-empty {
        padding: 3rem 1.5rem;
    }
    
    .exam-empty-icon {
        padding: 1rem;
    }
    
    .exam-empty-icon svg {
        width: 48px;
        height: 48px;
    }
}

/* ─── Exam Detail Page ─── */

/* ─── Exam Detail Page Modernized ─── */
:root {
    --glass-bg: rgba(255, 255, 255, 0.08);
    --glass-border: rgba(255, 255, 255, 0.15);
    --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.15);
    --modern-radius: 24px;
    --anim-spring: cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.exam-detail-wrapper {
    background: var(--bg-primary);
    overflow: hidden;
}

/* ─── Hero Section ─── */
.exam-detail-hero {
    position: relative;
    padding: clamp(4rem, 8vw, 7rem) 0 clamp(6rem, 10vw, 9rem) 0;
    background: var(--gray-900);
    color: var(--white);
    overflow: hidden;
    isolation: isolate;
}

.exam-detail-hero.has-image {
    padding: clamp(5rem, 10vw, 8rem) 0 clamp(7rem, 12vw, 10rem) 0;
}

.exam-detail-hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0.25;
    z-index: 0;
    filter: blur(4px) saturate(1.2);
}

.exam-detail-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(15,23,42,0.85) 0%, rgba(15,23,42,0.95) 100%);
    z-index: 1;
}

/* Modern Decorative Blobs */
.hero-decoration {
    position: absolute;
    z-index: 1;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.5;
    pointer-events: none;
    animation: floatBlob 10s infinite alternate ease-in-out;
}

@keyframes floatBlob {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(30px, -30px) scale(1.1); }
}

.hero-decoration.shape-1 {
    width: 450px;
    height: 450px;
    top: -100px;
    right: -100px;
    background: var(--primary);
}

.hero-decoration.shape-2 {
    width: 350px;
    height: 350px;
    bottom: -50px;
    left: -100px;
    background: #0ea5e9; /* Light blue accent */
    animation-delay: -5s;
}

.exam-detail-hero-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
    max-width: 900px;
    animation: fadeUp 0.8s var(--anim-spring) forwards;
}

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

/* Breadcrumb */
.exam-breadcrumb-wrapper {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    margin-bottom: 0.5rem;
}
.exam-breadcrumb-wrapper::-webkit-scrollbar { display: none; }

.exam-breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
    white-space: nowrap;
}

.exam-breadcrumb a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.2s ease;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
}

.exam-breadcrumb a:hover {
    color: var(--white);
    background: rgba(255,255,255,0.1);
}

.exam-breadcrumb .separator {
    opacity: 0.5;
    display: flex;
    align-items: center;
}

.exam-breadcrumb span[aria-current="page"] {
    color: var(--white);
    font-weight: 600;
    padding-left: 0.25rem;
}

/* Glass Badge */
.exam-detail-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: var(--white);
    padding: 0.625rem 1.25rem;
    border-radius: 99px;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
}

.exam-detail-badge .icon-wrapper {
    color: var(--badge-color, var(--primary-300));
    display: flex;
    align-items: center;
}

/* Title */
.exam-detail-hero h1 {
    font-family: 'Outfit', var(--font-family);
    font-size: clamp(2rem, 5vw, 4rem);
    font-weight: 800;
    line-height: 1.15;
    margin: 0;
    color: var(--white);
    letter-spacing: -0.02em;
    text-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.exam-detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    font-size: 0.9375rem;
    color: rgba(255, 255, 255, 0.85);
    margin-top: 0.5rem;
    background: var(--glass-bg);
    padding: 0.75rem 1.25rem;
    border-radius: 12px;
    backdrop-filter: blur(8px);
    border: 1px solid var(--glass-border);
}

.meta-item {
    display: inline-flex;
    align-items: center;
    gap: 0.625rem;
    font-weight: 500;
}

.meta-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-300);
}

/* ─── Layout ─── */
.exam-detail-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: clamp(2rem, 4vw, 3rem);
    padding: 0 0 clamp(4rem, 8vw, 8rem) 0;
    align-items: start;
    margin-top: -4rem; /* Overlap the hero section */
    position: relative;
    z-index: 10;
}

.exam-detail-main {
    min-width: 0;
}

/* ─── Main Content Card ─── */
.exam-content-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--modern-radius);
    padding: clamp(1.5rem, 4vw, 3.5rem);
    box-shadow: 0 10px 40px -10px rgba(0,0,0,0.08);
    position: relative;
    overflow: hidden;
}

/* Soft accent line at top of card */
.exam-content-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), #0ea5e9);
}

/* Modern Callout Box */
.exam-lead-box {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    background: var(--primary-50);
    border: 1px solid var(--primary-100);
    border-radius: 16px;
    padding: 1.75rem;
    margin-bottom: 3rem;
    position: relative;
}

@media (min-width: 640px) {
    .exam-lead-box {
        flex-direction: row;
        align-items: flex-start;
    }
}

.lead-icon {
    color: var(--primary);
    flex-shrink: 0;
    background: var(--white);
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(var(--primary-rgb, 79,70,229), 0.15);
}

.exam-lead {
    font-size: 1.125rem;
    color: var(--gray-800);
    margin: 0;
    line-height: 1.7;
    font-weight: 500;
}

/* Rich Text Styles Enhancement */
.rich-text-content {
    font-size: 1.0625rem;
    line-height: 1.85;
    color: var(--text-secondary);
}

.rich-text-content h2,
.rich-text-content h3,
.rich-text-content h4 {
    color: var(--text-primary);
    font-family: 'Outfit', var(--font-family);
    margin-top: 2.5rem;
    margin-bottom: 1.25rem;
    font-weight: 700;
    line-height: 1.3;
}

.rich-text-content h2 { 
    font-size: clamp(1.5rem, 3vw, 1.875rem); 
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}
.rich-text-content h3 { font-size: clamp(1.25rem, 2vw, 1.5rem); }

.rich-text-content p {
    margin-bottom: 1.5rem;
}

.rich-text-content a {
    color: var(--primary);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 4px;
    transition: all 0.2s ease;
}

.rich-text-content a:hover {
    color: var(--primary-700);
    text-decoration-thickness: 2px;
}

.rich-text-content img {
    max-width: 100%;
    height: auto;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    margin: 2rem 0;
}

.rich-text-content table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin: 2rem 0;
    font-size: 0.9375rem;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: 0 2px 10px rgba(0,0,0,0.02);
}

.rich-text-content table th,
.rich-text-content table td {
    border-bottom: 1px solid var(--border-color);
    padding: 1.25rem 1rem;
    text-align: left;
}

.rich-text-content table th:last-child,
.rich-text-content table td:last-child { border-right: none; }
.rich-text-content table tr:last-child td { border-bottom: none; }

.rich-text-content table th {
    background: var(--bg-primary);
    font-weight: 700;
    color: var(--text-primary);
    text-transform: uppercase;
    font-size: 0.8125rem;
    letter-spacing: 0.05em;
}

.rich-text-content table tr:hover td {
    background: rgba(0,0,0,0.01);
}

.rich-text-content ul, 
.rich-text-content ol {
    padding-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.rich-text-content li {
    margin-bottom: 0.75rem;
    position: relative;
}

.rich-text-content ul li::marker {
    color: var(--primary);
}

/* ─── Sidebar ─── */
.exam-sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    position: sticky;
    top: 100px;
}

.exam-sidebar-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--modern-radius);
    padding: 1.75rem;
    box-shadow: 0 4px 20px rgba(0,0,0,0.04);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.exam-sidebar-card:hover {
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.sidebar-card-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.header-icon-box {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--bg-primary);
    color: var(--text-secondary);
}

.sidebar-card-header h3 {
    font-size: 1.125rem;
    font-weight: 700;
    margin: 0;
    font-family: 'Outfit', var(--font-family);
    color: var(--text-primary);
}

/* Share Buttons */
.exam-share-btns {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}

.btn-share {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 54px;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    background: var(--bg-primary);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.btn-share:hover {
    border-color: transparent;
}

.btn-share.share-wa:hover { background: #25D366; color: #fff; transform: translateY(-4px); box-shadow: 0 8px 20px rgba(37, 211, 102, 0.3); }
.btn-share.share-tw:hover { background: #1DA1F2; color: #fff; transform: translateY(-4px); box-shadow: 0 8px 20px rgba(29, 161, 242, 0.3); }
.btn-share.share-cp:hover { background: var(--primary); color: #fff; transform: translateY(-4px); box-shadow: 0 8px 20px rgba(var(--primary-rgb, 79,70,229), 0.3); }

/* Related Links */
.exam-related-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.related-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    border-radius: 12px;
    background: var(--bg-primary);
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9375rem;
    transition: all 0.3s var(--anim-spring);
    border: 1px solid transparent;
}

.related-item:hover {
    background: var(--white);
    border-color: var(--primary-200);
    color: var(--primary);
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transform: translateX(6px);
}

.related-arrow {
    color: var(--text-muted);
    transition: all 0.3s var(--anim-spring);
    opacity: 0;
    transform: translateX(-10px);
}

.related-item:hover .related-arrow {
    color: var(--primary);
    opacity: 1;
    transform: translateX(0);
}

/* Action Card */
.action-card {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    background: linear-gradient(145deg, var(--bg-card), var(--bg-primary));
}

.btn-sidebar-action {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    height: 54px;
    border-radius: 16px;
    font-weight: 600;
    font-size: 0.9375rem;
    text-decoration: none;
    transition: all var(--transition-fast);
}

.btn-sidebar-action.outline {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-sidebar-action.outline:hover {
    border-color: var(--primary-300);
    color: var(--primary);
    background: var(--primary-50);
}

.btn-sidebar-action.primary {
    background: var(--primary);
    color: var(--white);
    border: 1px solid transparent;
    box-shadow: 0 4px 15px rgba(var(--primary-rgb, 79,70,229), 0.3);
}

.btn-sidebar-action.primary:hover {
    background: var(--primary-700);
    box-shadow: 0 6px 20px rgba(var(--primary-rgb, 79,70,229), 0.4);
    transform: translateY(-2px);
}

/* ─── Responsive Adjustments ─── */
@media (max-width: 1024px) {
    .exam-detail-layout {
        grid-template-columns: 1fr;
    }

    .exam-sidebar {
        position: static;
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
    
    .action-card {
        grid-column: 1 / -1;
        flex-direction: row;
    }
    
    .action-card .btn-sidebar-action {
        flex: 1;
    }
}

@media (max-width: 640px) {
    .exam-detail-hero {
        padding: 4rem 0 6rem 0;
    }
    
    .exam-detail-hero.has-image {
        padding: 4rem 0 6rem 0;
    }
    
    .exam-detail-layout {
        margin-top: -2.5rem;
    }
    
    .exam-content-card {
        border-radius: 20px;
    }
    
    .exam-detail-meta {
        flex-direction: column;
        gap: 0.75rem;
        align-items: flex-start;
        width: 100%;
    }
    
    .exam-sidebar {
        grid-template-columns: 1fr;
    }
    
    .action-card {
        flex-direction: column;
    }
    
    .rich-text-content table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
}

