/* ============================================================
   North Point Coaching Classes — Resources Hub
   Shared stylesheet for /resources, class & subject pages
   Palette matches site: cream bg, deep purple, yellow accent
   ============================================================ */

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --bg: #F6F6EB;
    --bg-white: #FFFFFF;
    --ink: #10284B;
    --ink-soft: #33415C;
    --text-secondary: #555555;
    --text-muted: #9CA3AF;
    --yellow: #FEDB63;
    --yellow-soft: rgba(254, 219, 99, 0.28);
    --purple: #381FD1;
    --purple-deep: #24108F;
    --purple-soft: #ECE9FC;
    --border: #E2E2D6;
    --card-shadow: 0 2px 8px rgba(0,0,0,0.05);
    --card-shadow-hover: 0 18px 44px rgba(24, 12, 90, 0.14);
    --radius: 16px;
    --radius-sm: 10px;
    --max-width: 1180px;
    --font-display: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; overflow-x: hidden; }

body {
    font-family: var(--font-body);
    background: var(--bg);
    color: var(--ink);
    line-height: 1.55;
    overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: var(--purple); }
h1, h2, h3, h4 { font-family: var(--font-display); letter-spacing: -0.02em; line-height: 1.15; }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }
.container-wide { max-width: 1320px; margin: 0 auto; padding: 0 24px; }

/* ===== Progress bar ===== */
.progress-bar {
    position: fixed; top: 0; left: 0; height: 3px; width: 0%;
    background: linear-gradient(90deg, var(--purple), var(--yellow));
    z-index: 3000; transition: width 0.1s linear;
}

/* ===== Navigation ===== */
.nav {
    position: sticky; top: 0; z-index: 1200;
    background: rgba(246, 246, 235, 0.9);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(16, 40, 75, 0.06);
    transition: box-shadow 0.25s ease;
}
.nav.scrolled { box-shadow: 0 10px 30px rgba(16, 40, 75, 0.08); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.nav-logo { display: flex; align-items: center; text-decoration: none; color: var(--ink); font-family: var(--font-display); font-weight: 800; font-size: 1.3rem; letter-spacing: -0.03em; }
.nav-logo img { height: 40px; width: auto; }
.nav-links { display: flex; align-items: center; gap: 26px; list-style: none; }
.nav-links a {
    text-decoration: none; color: var(--text-secondary); font-weight: 500;
    font-size: 0.875rem; transition: color 0.2s ease; padding: 6px 2px;
}
.nav-links a:hover, .nav-links a.active { color: var(--purple); }
.nav-links a.active { font-weight: 700; }
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; flex-direction: column; gap: 5px; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--ink); border-radius: 1px; transition: all 0.3s ease; }

/* ===== Buttons ===== */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    text-decoration: none; font-family: var(--font-display); font-weight: 700;
    font-size: 0.95rem; padding: 13px 26px; border-radius: 999px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    border: none; cursor: pointer; white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--purple); color: #fff; box-shadow: 0 10px 26px rgba(56, 31, 209, 0.32); }
.btn-primary:hover { background: var(--purple-deep); }
.btn-yellow { background: var(--yellow); color: var(--ink); box-shadow: 0 10px 24px rgba(203, 158, 16, 0.28); }
.btn-yellow:hover { background: #fbd34b; }
.btn-outline { background: transparent; color: var(--purple); border: 2px solid rgba(56, 31, 209, 0.35); }
.btn-outline:hover { background: var(--purple-soft); }
.btn-ghost { background: rgba(16, 40, 75, 0.07); color: var(--text-secondary); cursor: default; }
.btn-ghost:hover { transform: none; }
.btn-small { padding: 9px 18px; font-size: 0.82rem; }
.nav-cta { padding: 9px 20px; font-size: 0.82rem; }

/* ===== Hero ===== */
.page-hero {
    position: relative; overflow: hidden;
    background: radial-gradient(1100px 520px at 85% -10%, rgba(254, 219, 99, 0.35), transparent 60%),
                radial-gradient(900px 520px at -10% 110%, rgba(56, 31, 209, 0.12), transparent 55%),
                var(--bg);
    padding: 84px 0 70px;
}
.page-hero::after {
    content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0.5;
    background-image: radial-gradient(rgba(56, 31, 209, 0.10) 1px, transparent 1px);
    background-size: 26px 26px;
    mask-image: radial-gradient(600px 300px at 50% 0%, #000 30%, transparent 75%);
    -webkit-mask-image: radial-gradient(600px 300px at 50% 0%, #000 30%, transparent 75%);
}
.page-hero-content { position: relative; z-index: 1; max-width: 880px; }

.breadcrumb {
    display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
    font-size: 0.8rem; font-weight: 600; color: var(--text-muted);
    margin-bottom: 22px;
}
.breadcrumb a { color: var(--purple); text-decoration: none; transition: color 0.2s; }
.breadcrumb a:hover { color: var(--purple-deep); text-decoration: underline; }
.breadcrumb .sep { color: #c9c9ba; }

.page-hero-eyebrow {
    display: inline-flex; align-items: center; gap: 8px;
    background: var(--yellow-soft); color: var(--purple-deep);
    font-weight: 800; font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase;
    padding: 8px 16px; border-radius: 999px; margin-bottom: 18px;
    border: 1px solid rgba(254, 219, 99, 0.5);
}
.page-hero h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); font-weight: 800; margin-bottom: 18px; }
.page-hero h1 .accent { color: var(--purple); }
.page-hero h1 .hl { position: relative; white-space: nowrap; }
.page-hero h1 .hl::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: 6px; height: 12px;
    background: var(--yellow); opacity: 0.55; z-index: -1; border-radius: 4px;
}
.page-hero-description { font-size: 1.1rem; color: var(--text-secondary); max-width: 640px; margin-bottom: 30px; }
.page-hero-stats { display: flex; gap: 40px; flex-wrap: wrap; margin-top: 34px; }
.page-hero-stat .val { font-family: var(--font-display); font-size: 1.7rem; font-weight: 800; color: var(--ink); }
.page-hero-stat .val em { font-style: normal; color: var(--purple); }
.page-hero-stat .lbl { font-size: 0.82rem; color: var(--text-muted); font-weight: 600; }

/* ===== Section ===== */
.section { padding: 76px 0; }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 48px; }
.section-eyebrow {
    display: inline-block; color: var(--purple); font-weight: 800;
    font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 12px;
}
.section-head h2 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); font-weight: 800; margin-bottom: 14px; }
.section-head p { color: var(--text-secondary); font-size: 1.02rem; }

/* ===== Class cards (landing) ===== */
.class-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 22px; }
.class-card {
    position: relative; display: flex; flex-direction: column; justify-content: space-between;
    background: var(--bg-white); border-radius: var(--radius); padding: 30px 26px;
    text-decoration: none; color: var(--ink); min-height: 210px;
    box-shadow: var(--card-shadow); border: 1px solid var(--border);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    overflow: hidden;
}
.class-card::before {
    content: ""; position: absolute; top: 0; left: 0; right: 0; height: 5px;
    background: linear-gradient(90deg, var(--purple), var(--yellow));
    opacity: 0; transition: opacity 0.25s ease;
}
.class-card:hover { transform: translateY(-6px); box-shadow: var(--card-shadow-hover); }
.class-card:hover::before { opacity: 1; }
.class-card .cc-num {
    font-family: var(--font-display); font-size: 3.4rem; font-weight: 800; line-height: 1;
    color: var(--purple); letter-spacing: -0.04em;
}
.class-card .cc-label { font-size: 0.95rem; font-weight: 600; color: var(--text-secondary); margin-top: 4px; }
.class-card .cc-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 18px; }
.class-card .cc-meta { font-size: 0.78rem; color: var(--text-muted); font-weight: 700; }
.class-card .cc-arrow {
    width: 36px; height: 36px; border-radius: 50%; background: var(--purple-soft);
    color: var(--purple); display: flex; align-items: center; justify-content: center;
    font-size: 1.1rem; font-weight: 800; transition: transform 0.25s ease, background 0.25s ease, color 0.25s ease;
}
.class-card:hover .cc-arrow { background: var(--purple); color: #fff; transform: translateX(3px); }

/* ===== Subject cards (class pages) ===== */
.subject-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 22px; }
.subject-card {
    position: relative; display: flex; flex-direction: column;
    background: var(--bg-white); border-radius: var(--radius); padding: 30px 28px;
    text-decoration: none; color: var(--ink);
    box-shadow: var(--card-shadow); border: 1px solid var(--border);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.subject-card:hover { transform: translateY(-6px); box-shadow: var(--card-shadow-hover); }
.subject-icon {
    width: 54px; height: 54px; border-radius: 14px; margin-bottom: 18px;
    display: flex; align-items: center; justify-content: center; font-size: 1.5rem;
}
.sc-science { background: #E4F2FF; }
.sc-maths { background: #FFF0D2; }
.sc-english { background: #E7F6E7; }
.sc-sst { background: #F3E8FF; }
.subject-card h3 { font-size: 1.25rem; font-weight: 800; margin-bottom: 6px; }
.subject-card p { font-size: 0.88rem; color: var(--text-secondary); margin-bottom: 16px; flex: 1; }
.subject-card .subject-chapters { font-size: 0.78rem; font-weight: 700; color: var(--text-muted); }
.subject-card .subject-go {
    display: inline-flex; align-items: center; gap: 6px; margin-top: 14px;
    font-family: var(--font-display); font-weight: 700; font-size: 0.85rem; color: var(--purple);
}
.subject-card:hover .subject-go { text-decoration: underline; }

/* ===== Chapter list (subject pages) ===== */
.chapter-list { list-style: none; display: flex; flex-direction: column; gap: 14px; }
.chapter-item {
    display: flex; align-items: center; gap: 20px;
    background: var(--bg-white); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 18px 22px; box-shadow: var(--card-shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}
.chapter-item:hover { transform: translateY(-3px); box-shadow: var(--card-shadow-hover); border-color: rgba(56, 31, 209, 0.35); }
.chapter-num {
    flex: 0 0 52px; height: 52px; border-radius: 12px;
    background: var(--purple-soft); color: var(--purple);
    font-family: var(--font-display); font-weight: 800; font-size: 1.05rem;
    display: flex; align-items: center; justify-content: center;
}
.chapter-info { flex: 1; min-width: 0; }
.chapter-info h3 { font-size: 1.02rem; font-weight: 700; margin-bottom: 3px; }
.chapter-info .chapter-meta { font-size: 0.78rem; color: var(--text-muted); font-weight: 600; }
.chapter-badge {
    display: inline-flex; align-items: center; gap: 5px; font-size: 0.72rem; font-weight: 800;
    padding: 3px 10px; border-radius: 999px; margin-left: 8px; vertical-align: middle;
}
.badge-live { background: #E7F6E7; color: #1B7A3D; }
.badge-soon { background: #FFF0D2; color: #9A6B00; }

/* ===== Grouped chapters (units) ===== */
.unit-block { margin-bottom: 42px; }
.unit-title {
    display: flex; align-items: center; gap: 12px;
    font-family: var(--font-display); font-size: 1.15rem; font-weight: 800;
    color: var(--ink); margin-bottom: 16px;
}
.unit-title::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.unit-title .unit-icon { font-size: 1.2rem; }

/* ===== SEO text block ===== */
.seo-block {
    background: var(--bg-white); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 40px; box-shadow: var(--card-shadow);
}
.seo-block h2 { font-size: 1.5rem; font-weight: 800; margin-bottom: 16px; }
.seo-block h3 { font-size: 1.15rem; font-weight: 700; margin: 26px 0 10px; color: var(--purple-deep); }
.seo-block p, .seo-block li { color: var(--text-secondary); font-size: 0.98rem; margin-bottom: 12px; }
.seo-block ul { padding-left: 22px; }
.seo-block strong { color: var(--ink); }
.seo-block .key-list { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 10px; margin-top: 14px; }
.seo-block .key-list li { background: var(--bg); border-radius: 10px; padding: 12px 16px; font-size: 0.9rem; font-weight: 600; display: flex; gap: 10px; align-items: flex-start; }
.seo-block .key-list li::before { content: "✓"; color: #1B7A3D; font-weight: 900; }

/* ===== FAQ ===== */
.faq-list { max-width: 800px; margin: 0 auto; display: flex; flex-direction: column; gap: 14px; }
.faq-item { background: var(--bg-white); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.faq-item summary {
    cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center;
    padding: 20px 24px; font-family: var(--font-display); font-weight: 700; font-size: 1.02rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; font-size: 1.4rem; color: var(--purple); font-weight: 800; transition: transform 0.2s ease; }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item .faq-a { padding: 0 24px 22px; color: var(--text-secondary); font-size: 0.95rem; }

/* ===== Steps (landing) ===== */
.steps-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 22px; }
.step-card {
    background: var(--bg-white); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 30px 26px; box-shadow: var(--card-shadow); position: relative;
}
.step-num {
    width: 44px; height: 44px; border-radius: 50%; background: var(--yellow);
    color: var(--ink); font-family: var(--font-display); font-weight: 800; font-size: 1.1rem;
    display: flex; align-items: center; justify-content: center; margin-bottom: 16px;
}
.step-card h3 { font-size: 1.08rem; font-weight: 800; margin-bottom: 8px; }
.step-card p { font-size: 0.9rem; color: var(--text-secondary); }

/* ===== CTA ===== */
.cta-band {
    background: linear-gradient(120deg, var(--purple-deep), var(--purple) 70%);
    border-radius: 24px; padding: 54px 44px; text-align: center; position: relative; overflow: hidden;
}
.cta-band::before {
    content: ""; position: absolute; inset: 0; opacity: 0.35;
    background-image: radial-gradient(rgba(255,255,255,0.25) 1px, transparent 1px);
    background-size: 22px 22px;
}
.cta-band h2 { color: #fff; font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 800; margin-bottom: 12px; position: relative; }
.cta-band p { color: rgba(255,255,255,0.85); max-width: 560px; margin: 0 auto 26px; font-size: 1rem; position: relative; }
.cta-band .btn { position: relative; }

/* ===== Footer ===== */
.footer {
    background: var(--ink); color: rgba(255,255,255,0.85); padding: 64px 0 30px; margin-top: 90px;
}
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; }
.footer h4 { color: var(--yellow); font-size: 0.95rem; font-weight: 800; margin-bottom: 16px; }
.footer-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.footer-brand img { height: 46px; width: auto; }
.footer-brand-name { font-family: var(--font-display); font-weight: 800; color: #fff; font-size: 1.15rem; }
.footer-desc { font-size: 0.88rem; color: rgba(255,255,255,0.6); max-width: 300px; margin-bottom: 18px; }
.footer-col-list { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-col-list a { color: rgba(255,255,255,0.72); text-decoration: none; font-size: 0.88rem; transition: color 0.2s; }
.footer-col-list a:hover { color: var(--yellow); }
.footer-bottom {
    margin-top: 44px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,0.12);
    display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 14px;
    font-size: 0.8rem; color: rgba(255,255,255,0.5);
}
.footer-social { display: flex; gap: 18px; }
.footer-social a { color: rgba(255,255,255,0.6); text-decoration: none; font-size: 0.82rem; }
.footer-social a:hover { color: var(--yellow); }

/* ===== Responsive ===== */
@media (max-width: 900px) {
    .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
    .section { padding: 56px 0; }
    .page-hero { padding: 60px 0 52px; }
    .nav-inner { position: relative; }
    .nav-links {
        display: none; position: absolute; top: calc(100% + 10px); left: 0; right: 0;
        background: var(--bg-white); flex-direction: column; gap: 4px; z-index: 999;
        padding: 14px; border-radius: var(--radius); box-shadow: 0 14px 40px rgba(16,40,75,0.14);
        border: 1px solid var(--border);
    }
    .nav-links.active { display: flex; }
    .nav-links a { padding: 12px 16px; border-radius: var(--radius-sm); font-size: 0.95rem; display: block; width: 100%; }
    .nav-links a:hover { background: var(--bg); }
    .nav-links .nav-cta { margin-top: 6px; text-align: center; width: 100%; }
    .nav-toggle { display: flex; }
    .chapter-item { flex-wrap: wrap; gap: 12px; }
    .chapter-info { flex: 1 1 100%; order: 3; }
    .chapter-num { flex-basis: 44px; height: 44px; font-size: 0.95rem; }
    .seo-block { padding: 26px 22px; }
    .cta-band { padding: 40px 24px; }
    .footer-grid { grid-template-columns: 1fr; gap: 30px; }
}


/* Search-friendly resource explanations remain readable and useful on every device. */
.ncert-seo-section {
    padding-top: 0;
}
.ncert-seo-card {
    background: var(--surface, #ffffff);
    border: 1px solid var(--border, #e5e7eb);
    border-radius: 20px;
    padding: clamp(24px, 4vw, 44px);
    box-shadow: 0 12px 34px rgba(31, 41, 55, 0.06);
}
.ncert-seo-card h2 {
    margin-top: 0;
    margin-bottom: 12px;
}
.ncert-seo-card p {
    max-width: 850px;
    color: var(--text-muted, #667085);
    line-height: 1.75;
}
.ncert-seo-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
    margin-top: 24px;
}
.ncert-seo-links a {
    display: block;
    padding: 14px 16px;
    border: 1px solid var(--border, #e5e7eb);
    border-radius: 12px;
    color: var(--text-dark, #172554);
    font-weight: 700;
    text-decoration: none;
    transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.ncert-seo-links a:hover,
.ncert-seo-links a:focus-visible {
    transform: translateY(-2px);
    border-color: var(--purple, #381fd1);
    box-shadow: 0 8px 20px rgba(56, 31, 209, 0.12);
}
.ncert-seo-note {
    font-size: .9rem;
    margin-bottom: 0;
}

        .chapter-actions {
            display: flex;
            flex-wrap: wrap;
            justify-content: flex-end;
            align-items: center;
            gap: 8px;
            flex-shrink: 0;
        }
        .chapter-actions .btn {
            white-space: nowrap;
        }
        .btn-notes {
            background: #fff7d6;
            color: #7c4a03;
            border: 1px solid #f2c94c;
        }
        .btn-notes:hover,
        .btn-notes:focus-visible {
            background: #fef0b2;
            color: #5f3700;
            border-color: #d9a514;
        }
        @media (max-width: 640px) {
            .chapter-actions {
                width: 100%;
                justify-content: stretch;
            }
            .chapter-actions .btn {
                flex: 1 1 140px;
                text-align: center;
            }
        }
