/**
 * Shared mobile-first responsive styles for all syllabus pages.
 * Load after exam-specific syllabus CSS (ssc-gd, mppsc, upsc, neet, jee, fso).
 * Includes .syllabus-* for template page (syllabus.html?exam=...).
 */

/* Hero sub — readable on small screens */
.mocks-syllabus-hero-ssc-gd .page-hero-sub,
.mocks-syllabus-hero.syllabus-hero .page-hero-sub,
.mppsc-hero .page-hero-sub,
.upsc-hero .page-hero-sub,
.neet-hero .page-hero-sub,
.jee-hero .page-hero-sub,
.fso-hero .page-hero-sub {
    font-size: 0.9rem;
    line-height: 1.45;
}

/* Back link — touch target */
.syllabus-back,
.ssc-gd-back, .mppsc-back, .upsc-back, .neet-back, .jee-back, .fso-back {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 0;
    min-height: 44px;
    -webkit-tap-highlight-color: transparent;
}

/* Main — mobile padding */
.syllabus-main,
.ssc-gd-main, .mppsc-main, .upsc-main, .neet-main, .jee-main, .fso-main {
    padding: 1rem 0 2rem;
}

/* PDF button — full width on mobile, touch-friendly */
.syllabus-pdf-btn,
.ssc-gd-pdf-btn, .mppsc-pdf-btn, .upsc-pdf-btn, .neet-pdf-btn, .jee-pdf-btn, .fso-pdf-btn {
    display: block;
    width: 100%;
    max-width: 20rem;
    margin: 0 auto;
    padding: 0.75rem 1.25rem;
    min-height: 48px;
    font-size: 1rem;
    -webkit-tap-highlight-color: transparent;
}

/* Ad grid — single column on mobile */
.syllabus-ad-grid,
.ssc-gd-ad-grid, .mppsc-ad-grid, .upsc-ad-grid, .neet-ad-grid, .jee-ad-grid, .fso-ad-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
}

.syllabus-ad-card,
.ssc-gd-ad-card, .mppsc-ad-card, .upsc-ad-card, .neet-ad-card, .jee-ad-card, .fso-ad-card {
    padding: 1.25rem;
}

.syllabus-ad-title,
.ssc-gd-ad-title, .mppsc-ad-title, .upsc-ad-title, .neet-ad-title, .jee-ad-title, .fso-ad-title {
    font-size: 1.1rem;
    margin: 0 0 1rem;
}

/* Blocks & typography */
.syllabus-block,
.ssc-gd-block, .mppsc-block, .upsc-block, .neet-block, .jee-block, .fso-block {
    margin-bottom: 1.5rem;
}

.syllabus-h2,
.ssc-gd-h2, .mppsc-h2, .upsc-h2, .neet-h2, .jee-h2, .fso-h2 {
    font-size: clamp(1.15rem, 4vw, 1.35rem);
    margin: 0 0 0.5rem;
    line-height: 1.3;
}

.syllabus-h3,
.ssc-gd-h3, .mppsc-h3, .upsc-h3, .neet-h3, .jee-h3, .fso-h3 {
    font-size: clamp(1rem, 2.5vw, 1.1rem);
    margin: 1rem 0 0.5rem;
}

.syllabus-overview,
.ssc-gd-overview, .mppsc-overview, .upsc-overview, .neet-overview, .jee-overview, .fso-overview {
    font-size: 0.9rem;
    margin: 0 0 0.75rem;
}

/* Guide */
.syllabus-guide,
.ssc-gd-guide, .mppsc-guide, .upsc-guide, .neet-guide, .jee-guide, .fso-guide {
    padding: 1rem;
    border-radius: 10px;
}

.syllabus-algorithm-list,
.ssc-gd-algorithm-list, .mppsc-algorithm-list, .upsc-algorithm-list,
.neet-algorithm-list, .jee-algorithm-list, .fso-algorithm-list {
    padding-left: 1.25rem;
    font-size: 0.9rem;
    margin: 0.5rem 0 0.75rem;
}

.syllabus-guide-note,
.ssc-gd-guide-note, .mppsc-guide-note, .upsc-guide-note, .neet-guide-note,
.jee-guide-note, .fso-guide-note {
    font-size: 0.9rem;
    padding: 0.65rem 0.85rem;
    margin: 0.75rem 0 0;
}

.syllabus-pattern-list,
.ssc-gd-pattern-list, .mppsc-pattern-list, .upsc-pattern-list,
.neet-pattern-list, .jee-pattern-list, .fso-pattern-list {
    font-size: 0.9rem;
    margin: 0 0 0.75rem;
}

/* Table wrap — touch scroll */
.syllabus-table-wrap,
.ssc-gd-table-wrap, .mppsc-table-wrap, .upsc-table-wrap,
.neet-table-wrap, .jee-table-wrap, .fso-table-wrap {
    margin: 0.75rem 0;
    border-radius: 8px;
    -webkit-overflow-scrolling: touch;
}

.syllabus-simple-table, .syllabus-topic-table,
.ssc-gd-simple-table, .ssc-gd-topic-table,
.mppsc-simple-table, .mppsc-topic-table,
.upsc-simple-table, .upsc-topic-table,
.neet-simple-table, .neet-topic-table,
.jee-simple-table, .jee-topic-table,
.fso-simple-table, .fso-topic-table {
    font-size: 0.8rem;
    min-width: 580px;
}

.syllabus-simple-table th, .syllabus-simple-table td, .syllabus-topic-table th, .syllabus-topic-table td,
.ssc-gd-simple-table th, .ssc-gd-simple-table td, .ssc-gd-topic-table th, .ssc-gd-topic-table td,
.mppsc-simple-table th, .mppsc-simple-table td, .mppsc-topic-table th, .mppsc-topic-table td,
.upsc-simple-table th, .upsc-simple-table td, .upsc-topic-table th, .upsc-topic-table td,
.neet-simple-table th, .neet-simple-table td, .neet-topic-table th, .neet-topic-table td,
.jee-simple-table th, .jee-simple-table td, .jee-topic-table th, .jee-topic-table td,
.fso-simple-table th, .fso-simple-table td, .fso-topic-table th, .fso-topic-table td {
    padding: 0.5rem 0.4rem;
}

/* Checkbox cell — touch target */
.syllabus-th-quest, .syllabus-td-quest,
.ssc-gd-th-quest, .ssc-gd-td-quest, .mppsc-th-quest, .mppsc-td-quest,
.upsc-th-quest, .upsc-td-quest, .neet-th-quest, .neet-td-quest,
.jee-th-quest, .jee-td-quest, .fso-th-quest, .fso-td-quest {
    min-width: 44px;
    padding: 0.5rem !important;
}

.syllabus-check,
.ssc-gd-check, .mppsc-check, .upsc-check, .neet-check, .jee-check, .fso-check {
    min-width: 44px;
    min-height: 44px;
    padding: 0.5rem;
    -webkit-tap-highlight-color: transparent;
}

.syllabus-checkbox,
.ssc-gd-checkbox, .mppsc-checkbox, .upsc-checkbox, .neet-checkbox, .jee-checkbox, .fso-checkbox {
    width: 44px;
    height: 44px;
}

.syllabus-heavy-lifting,
.ssc-gd-heavy-lifting, .mppsc-heavy-lifting, .upsc-heavy-lifting,
.neet-heavy-lifting, .jee-heavy-lifting, .fso-heavy-lifting {
    font-size: 1rem;
    margin: 1.5rem 0 0.5rem;
}

.syllabus-bottom-actions,
.ssc-gd-bottom-actions, .mppsc-bottom-actions, .upsc-bottom-actions,
.neet-bottom-actions, .jee-bottom-actions, .fso-bottom-actions {
    margin-bottom: 1.5rem;
}

/* Tablet: 600px+ */
@media (min-width: 600px) {
    .syllabus-ad-grid,
    .ssc-gd-ad-grid, .mppsc-ad-grid, .upsc-ad-grid, .neet-ad-grid, .jee-ad-grid, .fso-ad-grid {
        grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
        gap: 1.25rem;
    }

    .syllabus-ad-card,
    .ssc-gd-ad-card, .mppsc-ad-card, .upsc-ad-card, .neet-ad-card, .jee-ad-card, .fso-ad-card {
        padding: 1.5rem;
    }

    .syllabus-ad-title,
    .ssc-gd-ad-title, .mppsc-ad-title, .upsc-ad-title, .neet-ad-title, .jee-ad-title, .fso-ad-title {
        font-size: 1.25rem;
        margin: 0 0 1.25rem;
    }

    .syllabus-pdf-btn,
    .ssc-gd-pdf-btn, .mppsc-pdf-btn, .upsc-pdf-btn, .neet-pdf-btn, .jee-pdf-btn, .fso-pdf-btn {
        width: auto;
        max-width: none;
        display: inline-block;
    }
}

/* Desktop: 768px+ */
@media (min-width: 768px) {
    .syllabus-main,
    .ssc-gd-main, .mppsc-main, .upsc-main, .neet-main, .jee-main, .fso-main {
        padding: 2rem 0 3rem;
    }

    .syllabus-block,
    .ssc-gd-block, .mppsc-block, .upsc-block, .neet-block, .jee-block, .fso-block {
        margin-bottom: 2.5rem;
    }

    .syllabus-guide,
    .ssc-gd-guide, .mppsc-guide, .upsc-guide, .neet-guide, .jee-guide, .fso-guide {
        padding: 1.5rem;
        border-radius: 12px;
    }

    .syllabus-overview,
    .ssc-gd-overview, .mppsc-overview, .upsc-overview, .neet-overview, .jee-overview, .fso-overview {
        font-size: 0.95rem;
        margin: 0 0 1rem;
    }

    .syllabus-algorithm-list, .syllabus-pattern-list,
    .ssc-gd-algorithm-list, .mppsc-algorithm-list, .upsc-algorithm-list,
    .neet-algorithm-list, .jee-algorithm-list, .fso-algorithm-list,
    .ssc-gd-pattern-list, .mppsc-pattern-list, .upsc-pattern-list,
    .neet-pattern-list, .jee-pattern-list, .fso-pattern-list {
        font-size: 0.95rem;
    }

    .syllabus-guide-note,
    .ssc-gd-guide-note, .mppsc-guide-note, .upsc-guide-note, .neet-guide-note,
    .jee-guide-note, .fso-guide-note {
        font-size: 0.95rem;
        padding: 0.75rem 1rem;
    }

    .syllabus-simple-table, .syllabus-topic-table,
    .ssc-gd-simple-table, .ssc-gd-topic-table,
    .mppsc-simple-table, .mppsc-topic-table,
    .upsc-simple-table, .upsc-topic-table,
    .neet-simple-table, .neet-topic-table,
    .jee-simple-table, .jee-topic-table,
    .fso-simple-table, .fso-topic-table {
        font-size: 0.9rem;
        min-width: 0;
    }

    .syllabus-simple-table th, .syllabus-simple-table td, .syllabus-topic-table th, .syllabus-topic-table td,
    .ssc-gd-simple-table th, .ssc-gd-simple-table td, .ssc-gd-topic-table th, .ssc-gd-topic-table td,
    .mppsc-simple-table th, .mppsc-simple-table td, .mppsc-topic-table th, .mppsc-topic-table td,
    .upsc-simple-table th, .upsc-simple-table td, .upsc-topic-table th, .upsc-topic-table td,
    .neet-simple-table th, .neet-simple-table td, .neet-topic-table th, .neet-topic-table td,
    .jee-simple-table th, .jee-simple-table td, .jee-topic-table th, .jee-topic-table td,
    .fso-simple-table th, .fso-simple-table td, .fso-topic-table th, .fso-topic-table td {
        padding: 0.6rem 0.75rem;
    }

    .syllabus-th-quest, .syllabus-td-quest,
    .ssc-gd-th-quest, .ssc-gd-td-quest, .mppsc-th-quest, .mppsc-td-quest,
    .upsc-th-quest, .upsc-td-quest, .neet-th-quest, .neet-td-quest,
    .jee-th-quest, .jee-td-quest, .fso-th-quest, .fso-td-quest {
        min-width: 0;
        padding: 0.6rem 0.75rem !important;
    }

    .syllabus-check,
    .ssc-gd-check, .mppsc-check, .upsc-check, .neet-check, .jee-check, .fso-check {
        min-width: 0;
        min-height: 0;
        padding: 0;
    }

    .syllabus-checkbox,
    .ssc-gd-checkbox, .mppsc-checkbox, .upsc-checkbox, .neet-checkbox, .jee-checkbox, .fso-checkbox {
        width: 0;
        height: 0;
    }

    .syllabus-heavy-lifting,
    .ssc-gd-heavy-lifting, .mppsc-heavy-lifting, .upsc-heavy-lifting,
    .neet-heavy-lifting, .jee-heavy-lifting, .fso-heavy-lifting {
        font-size: 1.1rem;
        margin: 2rem 0 0.75rem;
    }

    .syllabus-bottom-actions,
    .ssc-gd-bottom-actions, .mppsc-bottom-actions, .upsc-bottom-actions,
    .neet-bottom-actions, .jee-bottom-actions, .fso-bottom-actions {
        margin-bottom: 2rem;
    }

    .mocks-syllabus-hero-ssc-gd .page-hero-sub,
    .mocks-syllabus-hero.syllabus-hero .page-hero-sub,
    .mppsc-hero .page-hero-sub,
    .upsc-hero .page-hero-sub,
    .neet-hero .page-hero-sub,
    .jee-hero .page-hero-sub,
    .fso-hero .page-hero-sub {
        font-size: 1rem;
    }
}
