/* =========================================================
   HindiGKBook - Modern Global CSS
   Pure HTML + CSS
========================================================= */

/* -------------------------
   ROOT
------------------------- */

:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #eff6ff;

    --dark: #0f172a;
    --dark-2: #1e293b;

    --text: #334155;
    --muted: #64748b;

    --white: #ffffff;
    --light: #f8fafc;
    --light-blue: #f1f5ff;

    --border: #e2e8f0;
    --border-light: #eef2f7;

    --success: #16a34a;
    --warning: #f59e0b;
    --danger: #dc2626;

    --radius-sm: 8px;
    --radius: 14px;
    --radius-lg: 20px;

    --shadow-sm:
        0 2px 8px rgba(15, 23, 42, 0.04);

    --shadow:
        0 8px 25px rgba(15, 23, 42, 0.07);

    --shadow-lg:
        0 18px 45px rgba(15, 23, 42, 0.10);

    --container: 1180px;
}


/* -------------------------
   RESET
------------------------- */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}


html {
    scroll-behavior: smooth;
}


body {
    font-family:
        "Noto Sans Devanagari",
        "Nirmala UI",
        "Mangal",
        Arial,
        sans-serif;

    background: var(--white);

    color: var(--text);

    line-height: 1.7;

    font-size: 16px;

    -webkit-font-smoothing: antialiased;
}


img {
    max-width: 100%;
    height: auto;
    display: block;
}


a {
    color: inherit;
    text-decoration: none;
}


button,
input,
textarea,
select {
    font: inherit;
}


button {
    cursor: pointer;
}


ul,
ol {
    padding-left: 22px;
}


/* -------------------------
   CONTAINER
------------------------- */

.container {
    width: min(
        calc(100% - 32px),
        var(--container)
    );

    margin-inline: auto;
}


/* -------------------------
   HEADER
------------------------- */

.site-header {
    position: sticky;

    top: 0;

    z-index: 1000;

    background:
        rgba(255, 255, 255, 0.94);

    backdrop-filter: blur(16px);

    -webkit-backdrop-filter: blur(16px);

    border-bottom:
        1px solid rgba(226, 232, 240, .85);
}


.header-inner {
    min-height: 76px;

    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 25px;
}


/* LOGO */

.site-logo {
    display: flex;

    align-items: center;

    gap: 11px;

    flex-shrink: 0;
}


.logo-icon {
    width: 43px;
    height: 43px;

    display: grid;

    place-items: center;

    border-radius: 12px;

    background:
        linear-gradient(
            135deg,
            #2563eb,
            #4f46e5
        );

    color: #fff;

    font-size: 22px;

    box-shadow:
        0 6px 16px rgba(37, 99, 235, .22);
}


.logo-text {
    display: flex;

    flex-direction: column;

    line-height: 1.2;
}


.logo-text strong {
    color: var(--dark);

    font-size: 19px;

    font-weight: 800;

    letter-spacing: -.3px;
}


.logo-text small {
    color: var(--muted);

    font-size: 10px;

    margin-top: 3px;
}


/* NAV */

.main-nav {
    display: flex;

    align-items: center;

    gap: 4px;
}


.main-nav a {
    position: relative;

    padding: 9px 12px;

    color: #475569;

    font-size: 14px;

    font-weight: 600;

    border-radius: 8px;

    transition:
        color .2s ease,
        background .2s ease;
}


.main-nav a:hover {
    color: var(--primary);

    background: var(--primary-light);
}


.main-nav a.active {
    color: var(--primary);

    background: var(--primary-light);
}


.menu-toggle {
    display: none;

    width: 42px;
    height: 42px;

    border: 1px solid var(--border);

    border-radius: 10px;

    background: #fff;

    color: var(--dark);

    font-size: 21px;
}


/* -------------------------
   HERO
------------------------- */

.page-hero,
.article-hero {
    position: relative;

    overflow: hidden;

    border-bottom:
        1px solid var(--border);
}


.page-hero {
    padding: 72px 0;

    background:
        radial-gradient(
            circle at 90% 20%,
            rgba(59, 130, 246, .12),
            transparent 35%
        ),

        linear-gradient(
            135deg,
            #eff6ff 0%,
            #ffffff 60%
        );
}


.article-hero {
    padding: 58px 0;

    background:
        radial-gradient(
            circle at 85% 20%,
            rgba(37, 99, 235, .10),
            transparent 30%
        ),

        #f8fafc;
}


/* -------------------------
   BREADCRUMB
------------------------- */

.breadcrumb {
    display: flex;

    flex-wrap: wrap;

    align-items: center;

    gap: 7px;

    margin-bottom: 22px;

    color: var(--muted);

    font-size: 13px;
}


.breadcrumb a {
    color: var(--primary);

    font-weight: 600;
}


.breadcrumb a:hover {
    color: var(--primary-dark);

    text-decoration: underline;
}


/* -------------------------
   HERO TYPOGRAPHY
------------------------- */

.page-hero h1,
.article-hero h1 {
    color: var(--dark);

    font-weight: 850;

    letter-spacing: -.7px;

    line-height: 1.25;
}


.page-hero h1 {
    font-size: clamp(
        32px,
        5vw,
        48px
    );

    margin-bottom: 14px;
}


.page-hero h1 span,
.article-hero h1 span {
    color: var(--primary);
}


.page-hero p {
    max-width: 760px;

    color: var(--muted);

    font-size: 17px;
}


.article-hero h1 {
    max-width: 900px;

    font-size: clamp(
        31px,
        5vw,
        45px
    );

    margin-bottom: 17px;
}


.article-hero h1 span {
    display: block;

    margin-top: 5px;

    font-size: .62em;

    letter-spacing: 0;
}


.article-intro {
    max-width: 820px;

    color: #475569;

    font-size: 17px;

    line-height: 1.85;
}


.article-label {
    display: inline-flex;

    align-items: center;

    gap: 7px;

    margin-bottom: 14px;

    padding: 6px 12px;

    border-radius: 30px;

    background: #dbeafe;

    color: #1d4ed8;

    font-size: 12px;

    font-weight: 800;
}


.article-meta {
    display: flex;

    flex-wrap: wrap;

    gap: 9px;

    margin-top: 22px;
}


.article-meta span {
    padding: 6px 11px;

    border-radius: 7px;

    background: #fff;

    border: 1px solid var(--border);

    color: var(--muted);

    font-size: 12px;

    font-weight: 600;
}


/* -------------------------
   SECTIONS
------------------------- */

.section {
    padding: 75px 0;
}


.section-light {
    background: var(--light);
}


.section-heading {
    max-width: 720px;

    margin-bottom: 35px;
}


.section-heading > span {
    display: inline-block;

    margin-bottom: 8px;

    color: var(--primary);

    font-size: 13px;

    font-weight: 800;

    text-transform: uppercase;

    letter-spacing: .5px;
}


.section-heading h2 {
    color: var(--dark);

    font-size: clamp(
        26px,
        4vw,
        34px
    );

    line-height: 1.3;

    margin-bottom: 9px;

    letter-spacing: -.4px;
}


.section-heading p {
    color: var(--muted);

    font-size: 15px;
}


/* -------------------------
   SUBJECT CARDS
------------------------- */

.subjects-page-grid {
    display: grid;

    grid-template-columns:
        repeat(3, 1fr);

    gap: 20px;
}


.subject-large-card {
    position: relative;

    display: flex;

    flex-direction: column;

    min-height: 290px;

    padding: 27px;

    background: #fff;

    border: 1px solid var(--border);

    border-radius: var(--radius);

    overflow: hidden;

    transition:
        transform .25s ease,
        box-shadow .25s ease,
        border-color .25s ease;
}


.subject-large-card::before {
    content: "";

    position: absolute;

    top: 0;
    left: 0;
    right: 0;

    height: 3px;

    background:
        linear-gradient(
            90deg,
            #2563eb,
            #6366f1
        );

    transform: scaleX(0);

    transform-origin: left;

    transition: transform .25s ease;
}


.subject-large-card:hover {
    transform: translateY(-6px);

    border-color: #bfdbfe;

    box-shadow: var(--shadow-lg);
}


.subject-large-card:hover::before {
    transform: scaleX(1);
}


.subject-large-icon {
    width: 56px;
    height: 56px;

    display: grid;

    place-items: center;

    margin-bottom: 18px;

    border-radius: 14px;

    background:
        linear-gradient(
            135deg,
            #eff6ff,
            #eef2ff
        );

    font-size: 27px;
}


.subject-large-card h2 {
    color: var(--dark);

    font-size: 20px;

    margin-bottom: 8px;

    line-height: 1.4;
}


.subject-large-card p {
    color: var(--muted);

    font-size: 14px;

    line-height: 1.75;

    margin-bottom: 20px;
}


.chapter-info {
    display: flex;

    justify-content: space-between;

    align-items: center;

    gap: 10px;

    margin-top: auto;

    padding-top: 15px;

    border-top: 1px solid var(--border-light);

    font-size: 12px;
}


.chapter-info span {
    color: var(--muted);
}


.chapter-info strong,
.subject-link {
    color: var(--primary);
}


.subject-link {
    display: inline-block;

    margin-top: 13px;

    font-size: 13px;

    font-weight: 800;
}


/* -------------------------
   HISTORY CHAPTERS
------------------------- */

.history-section {
    margin-bottom: 58px;
}


.history-section-title {
    margin-bottom: 21px;

    padding-bottom: 16px;

    border-bottom: 1px solid var(--border);
}


.history-section-title > div {
    display: flex;

    align-items: center;

    gap: 14px;
}


.history-section-title > div > span {
    width: 51px;
    height: 51px;

    display: grid;

    place-items: center;

    flex-shrink: 0;

    border-radius: 13px;

    background:
        linear-gradient(
            135deg,
            #eff6ff,
            #eef2ff
        );

    font-size: 25px;
}


.history-section-title h2 {
    color: var(--dark);

    font-size: 24px;

    line-height: 1.3;
}


.history-section-title p {
    color: var(--muted);

    font-size: 13px;
}


.chapter-list {
    display: grid;

    grid-template-columns:
        repeat(2, 1fr);

    gap: 15px;
}


.chapter-card {
    display: flex;

    align-items: flex-start;

    gap: 16px;

    padding: 21px;

    background: #fff;

    border: 1px solid var(--border);

    border-radius: 13px;

    transition:
        transform .2s ease,
        border-color .2s ease,
        box-shadow .2s ease;
}


.chapter-card:hover {
    transform: translateY(-3px);

    border-color: #bfdbfe;

    box-shadow: var(--shadow);
}


.chapter-number {
    width: 42px;
    height: 42px;

    display: grid;

    place-items: center;

    flex-shrink: 0;

    border-radius: 10px;

    background: var(--primary-light);

    color: var(--primary);

    font-size: 12px;

    font-weight: 900;
}


.chapter-content {
    min-width: 0;
}


.chapter-content h3 {
    color: var(--dark);

    font-size: 17px;

    line-height: 1.45;

    margin-bottom: 5px;
}


.chapter-content p {
    color: var(--muted);

    font-size: 13px;

    line-height: 1.7;

    margin-bottom: 7px;
}


.read-link {
    color: var(--primary);

    font-size: 13px;

    font-weight: 800;
}


/* -------------------------
   ARTICLE LAYOUT
------------------------- */

.article-layout {
    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        280px;

    gap: 50px;

    padding-top: 55px;

    padding-bottom: 75px;
}


.notes-content {
    min-width: 0;
}


.notes-content section {
    margin-bottom: 48px;
}


.notes-content h2 {
    position: relative;

    color: var(--dark);

    font-size: 26px;

    line-height: 1.4;

    margin-bottom: 16px;

    padding-left: 15px;
}


.notes-content h2::before {
    content: "";

    position: absolute;

    left: 0;
    top: 5px;

    width: 4px;

    height: 27px;

    border-radius: 5px;

    background:
        linear-gradient(
            #2563eb,
            #6366f1
        );
}


.notes-content h3 {
    color: var(--dark);

    font-size: 19px;

    margin-top: 25px;

    margin-bottom: 10px;
}


.notes-content p {
    color: #475569;

    font-size: 16px;

    line-height: 1.9;

    margin-bottom: 15px;
}


.notes-content ul {
    margin-top: 10px;

    margin-bottom: 15px;

    padding-left: 23px;
}


.notes-content li {
    color: #475569;

    margin-bottom: 9px;

    line-height: 1.8;
}


.notes-content li::marker {
    color: var(--primary);
}


/* -------------------------
   TABLE
------------------------- */

.info-table-wrapper {
    width: 100%;

    overflow-x: auto;

    margin: 20px 0;

    border: 1px solid var(--border);

    border-radius: 12px;
}


.notes-table {
    width: 100%;

    min-width: 600px;

    border-collapse: collapse;

    background: #fff;
}


.notes-table th {
    padding: 14px 16px;

    background: #f1f5f9;

    color: var(--dark);

    text-align: left;

    font-size: 14px;

    font-weight: 800;

    border-bottom: 1px solid var(--border);
}


.notes-table td {
    padding: 13px 16px;

    color: #475569;

    font-size: 14px;

    border-bottom: 1px solid var(--border-light);
}


.notes-table tbody tr:last-child td {
    border-bottom: none;
}


.notes-table tbody tr:hover {
    background: #f8fafc;
}


/* -------------------------
   EXAM POINTS
------------------------- */

.exam-points {
    padding: 28px;

    background:
        linear-gradient(
            135deg,
            #eff6ff,
            #f8fafc
        );

    border: 1px solid #bfdbfe;

    border-radius: 18px;
}


.exam-points-heading {
    display: flex;

    align-items: center;

    gap: 14px;

    margin-bottom: 20px;

    padding-bottom: 17px;

    border-bottom: 1px solid #dbeafe;
}


.exam-points-heading > span {
    width: 48px;
    height: 48px;

    display: grid;

    place-items: center;

    flex-shrink: 0;

    border-radius: 12px;

    background: #fff;

    font-size: 23px;

    box-shadow: var(--shadow-sm);
}


.exam-points-heading h2 {
    padding: 0;

    margin: 0;

    color: #1e3a8a;

    font-size: 22px;
}


.exam-points-heading h2::before {
    display: none;
}


.exam-points-heading p {
    margin: 0;

    color: #64748b;

    font-size: 13px;
}


.exam-points ul {
    padding-left: 21px;

    margin: 0;
}


.exam-points li {
    color: #334155;

    margin-bottom: 11px;

    font-size: 14px;

    line-height: 1.75;
}


.exam-points li::marker {
    color: var(--primary);

    font-weight: bold;
}


/* -------------------------
   SIDEBAR
------------------------- */

.notes-sidebar {
    position: sticky;

    top: 100px;

    align-self: start;
}


.sidebar-card {
    margin-bottom: 20px;

    padding: 21px;

    background: #fff;

    border: 1px solid var(--border);

    border-radius: 14px;

    box-shadow: var(--shadow-sm);
}


.sidebar-card h2 {
    color: var(--dark);

    font-size: 17px;

    margin-bottom: 13px;
}


.sidebar-card > a:not(.sidebar-button) {
    display: block;

    padding: 8px 0;

    color: var(--muted);

    font-size: 13px;

    border-bottom: 1px solid var(--border-light);

    transition: color .2s ease;
}


.sidebar-card > a:last-child {
    border-bottom: none;
}


.sidebar-card > a:hover {
    color: var(--primary);

    padding-left: 4px;
}


.sidebar-blue {
    background:
        linear-gradient(
            145deg,
            #eff6ff,
            #ffffff
        );

    border-color: #bfdbfe;
}


.sidebar-blue > span {
    display: block;

    font-size: 27px;

    margin-bottom: 10px;
}


.sidebar-blue h2 {
    color: #1e3a8a;
}


.sidebar-blue p {
    color: var(--muted);

    font-size: 13px;

    line-height: 1.7;

    margin-bottom: 12px;
}


.sidebar-blue a {
    color: var(--primary) !important;

    font-weight: 800;
}


/* -------------------------
   CHAPTER NAVIGATION
------------------------- */

.chapter-navigation {
    display: flex;

    justify-content: space-between;

    gap: 15px;

    margin-top: 40px;

    padding-top: 25px;

    border-top: 1px solid var(--border);
}


.chapter-nav-btn {
    display: inline-flex;

    align-items: center;

    min-height: 44px;

    padding: 9px 15px;

    border: 1px solid var(--border);

    border-radius: 9px;

    background: #fff;

    color: #475569;

    font-size: 13px;

    font-weight: 700;

    transition: .2s ease;
}


.chapter-nav-btn:hover {
    color: var(--primary);

    border-color: #93c5fd;

    background: var(--primary-light);
}


.chapter-nav-btn.next {
    color: #fff;

    background: var(--primary);

    border-color: var(--primary);
}


.chapter-nav-btn.next:hover {
    background: var(--primary-dark);

    border-color: var(--primary-dark);

    color: #fff;
}


/* -------------------------
   SEO CONTENT
------------------------- */

.seo-content {
    max-width: 900px;
}


.seo-content h2 {
    color: var(--dark);

    font-size: 25px;

    margin-bottom: 16px;
}


.seo-content p {
    color: var(--muted);

    font-size: 15px;

    line-height: 1.9;

    margin-bottom: 14px;
}


/* -------------------------
   FOOTER
------------------------- */

.site-footer {
    background: #0f172a;

    color: #cbd5e1;

    margin-top: 0;
}


.footer-grid {
    display: grid;

    grid-template-columns:
        1.5fr
        1fr
        1fr
        1fr;

    gap: 45px;

    padding-top: 55px;

    padding-bottom: 45px;
}


.footer-logo {
    display: inline-block;

    color: #fff;

    font-size: 19px;

    font-weight: 800;

    margin-bottom: 12px;
}


.footer-about p {
    max-width: 300px;

    color: #94a3b8;

    font-size: 13px;

    line-height: 1.8;
}


.footer-grid h3 {
    color: #fff;

    font-size: 15px;

    margin-bottom: 14px;
}


.footer-grid > div:not(.footer-about) a {
    display: block;

    width: fit-content;

    margin-bottom: 8px;

    color: #94a3b8;

    font-size: 13px;

    transition: color .2s ease;
}


.footer-grid > div:not(.footer-about) a:hover {
    color: #60a5fa;
}


.footer-bottom {
    border-top:
        1px solid rgba(255,255,255,.08);

    padding: 18px 0;

    text-align: center;
}


.footer-bottom p {
    color: #64748b;

    font-size: 12px;
}


/* -------------------------
   FOCUS ACCESSIBILITY
------------------------- */

a:focus-visible,
button:focus-visible {
    outline: 3px solid rgba(37, 99, 235, .35);

    outline-offset: 3px;
}


/* -------------------------
   MOBILE
------------------------- */

@media (max-width: 1050px) {

    .main-nav {
        gap: 0;
    }

    .main-nav a {
        padding: 8px 9px;

        font-size: 13px;
    }

    .subjects-page-grid {
        grid-template-columns:
            repeat(2, 1fr);
    }

    .article-layout {
        grid-template-columns:
            minmax(0, 1fr);
    }

    .notes-sidebar {
        position: static;

        order: 2;
    }

}


@media (max-width: 800px) {

    .menu-toggle {
        display: grid;

        place-items: center;
    }


    .main-nav {
        position: absolute;

        top: 76px;

        left: 16px;
        right: 16px;

        display: none;

        flex-direction: column;

        align-items: stretch;

        padding: 8px;

        background: #fff;

        border: 1px solid var(--border);

        border-radius: 13px;

        box-shadow: var(--shadow-lg);
    }


    .main-nav.show {
        display: flex;
    }


    .main-nav a {
        padding: 11px 13px;

        border-radius: 8px;
    }


    .footer-grid {
        grid-template-columns:
            repeat(2, 1fr);

        gap: 30px;
    }

}


@media (max-width: 650px) {

    body {
        font-size: 15px;
    }


    .container {
        width:
            min(
                calc(100% - 24px),
                var(--container)
            );
    }


    .header-inner {
        min-height: 68px;
    }


    .main-nav {
        top: 68px;

        left: 12px;
        right: 12px;
    }


    .logo-icon {
        width: 39px;
        height: 39px;

        font-size: 19px;
    }


    .logo-text strong {
        font-size: 17px;
    }


    .logo-text small {
        display: none;
    }


    .page-hero {
        padding: 48px 0;
    }


    .article-hero {
        padding: 42px 0;
    }


    .section {
        padding: 55px 0;
    }


    .subjects-page-grid,
    .chapter-list {
        grid-template-columns: 1fr;
    }


    .subject-large-card {
        min-height: auto;

        padding: 23px;
    }


    .chapter-card {
        padding: 18px;
    }


    .chapter-content h3 {
        font-size: 16px;
    }


    .article-layout {
        padding-top: 38px;

        padding-bottom: 55px;

        gap: 30px;
    }


    .notes-content h2 {
        font-size: 22px;
    }


    .notes-content p {
        font-size: 15px;

        line-height: 1.85;
    }


    .exam-points {
        padding: 21px;
    }


    .chapter-navigation {
        flex-direction: column;
    }


    .chapter-nav-btn {
        justify-content: center;

        width: 100%;
    }


    .footer-grid {
        grid-template-columns: 1fr;

        gap: 27px;

        padding-top: 40px;

        padding-bottom: 35px;
    }

}


/* -------------------------
   SMALL DEVICES
------------------------- */

@media (max-width: 400px) {

    .page-hero h1 {
        font-size: 30px;
    }


    .article-hero h1 {
        font-size: 28px;
    }


    .article-intro {
        font-size: 15px;
    }


    .chapter-card {
        gap: 12px;
    }


    .chapter-number {
        width: 38px;
        height: 38px;

        font-size: 11px;
    }

}
