
/* =====================================================
   XMATHEMATICS.COM
   COMPLETE EXAMPLES STYLESHEET

   Bestand: /stylesheets/examples.css

   Voor:
   - topic.php
   - example.php

   Inclusief:
   - Zes categoriekleuren
   - Responsive topic listings
   - Individuele example pagina's
   - Navigatie Previous / Next
   - Desktop, tablet en mobiel
   ===================================================== */


/* =====================================================
   1. BASIS
   ===================================================== */

:root {
    --xm-navy: #092f52;
    --xm-blue: #0b70b6;
    --xm-text: #142b43;
    --xm-muted: #61758a;
    --xm-border: #d5e2ee;
    --xm-pale: #edf6fd;
    --xm-shadow: 0 5px 20px rgba(11, 53, 92, .07);
}

.xm-page {
    /* Standaardkleur: Arithmetic */
    --cat-light: #daeeff;
    --cat-mid: #a4d0f5;
    --cat-dark: #075fa5;

    width: min(1120px, 94%);
    margin: 0 auto;
    padding: 24px 0 65px;

    color: var(--xm-text);
}

.xm-page *,
.xm-page *::before,
.xm-page *::after {
    box-sizing: border-box;
}

.xm-page a {
    text-decoration: none;
}


/* =====================================================
   2. CATEGORIEKLEUREN
   Dezelfde kleurindeling als home.css
   ===================================================== */

/* Arithmetic - Blauw */

.xm-page.theme-blue {
    --cat-light: #daeeff;
    --cat-mid: #a4d0f5;
    --cat-dark: #075fa5;
}

/* Algebra - Groen */

.xm-page.theme-green {
    --cat-light: #def2e5;
    --cat-mid: #aedac1;
    --cat-dark: #20734d;
}

/* Geometry - Goud */

.xm-page.theme-gold {
    --cat-light: #fff1d4;
    --cat-mid: #f2d497;
    --cat-dark: #a7781e;
}

/* Calculus - Paars */

.xm-page.theme-purple {
    --cat-light: #ece6fc;
    --cat-mid: #cbbbef;
    --cat-dark: #6650a8;
}

/* Statistics - Turquoise */

.xm-page.theme-teal {
    --cat-light: #d5f2ef;
    --cat-mid: #96d6d0;
    --cat-dark: #147f7d;
}

/* Trigonometry - Zandgoud */

.xm-page.theme-sand {
    --cat-light: #fff0ce;
    --cat-mid: #efcf8b;
    --cat-dark: #a87619;
}


/* =====================================================
   3. BREADCRUMB
   ===================================================== */

.xm-breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 9px;

    margin: 0 0 22px;
    padding: 0;

    color: var(--xm-muted);
    font-size: 13px;
}

.xm-breadcrumb a {
    color: var(--cat-dark);
    font-weight: 600;
}

.xm-breadcrumb a:hover {
    text-decoration: underline;
}

.xm-breadcrumb strong {
    color: var(--xm-text);
    font-weight: 800;
}

.xm-breadcrumb > span {
    color: #9aafc0;
}


/* =====================================================
   4. BLAUWE TOPIC HERO
   ===================================================== */

.xm-topic-hero {
    position: relative;
    overflow: hidden;

    display: flex;
    align-items: center;

    min-height: 215px;
    padding: 35px 42px;

    border-radius: 18px;

    border-bottom: 5px solid var(--cat-mid);

    color: #ffffff;

    background:
        radial-gradient(
            ellipse at 90% 100%,
            #155e93 0%,
            transparent 55%
        ),
        linear-gradient(
            115deg,
            #082b4d 0%,
            #0a4775 100%
        );

    box-shadow: 0 5px 18px rgba(10, 48, 85, .12);
}

.xm-hero-content {
    position: relative;
    z-index: 2;

    max-width: 760px;
    min-width: 0;
}

.xm-hero-category {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 9px;

    margin-bottom: 12px;

    color: var(--cat-light);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 1.8px;
}

.xm-small-dot {
    width: 9px;
    height: 9px;
    flex-shrink: 0;

    border-radius: 50%;
    background: var(--cat-mid);
}

.xm-topic-hero h1 {
    margin: 0 0 13px;

    color: #ffffff;
    font-size: clamp(30px, 4vw, 47px);
    font-weight: 800;
    letter-spacing: -.8px;
    line-height: 1.15;
}

.xm-topic-hero p {
    max-width: 690px;
    margin: 0;

    color: #deeffa;
    font-size: 15px;
    line-height: 1.7;
}

.xm-hero-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 23px;
}

.xm-hero-tags span {
    display: inline-flex;
    align-items: center;

    padding: 8px 14px;

    border: 1px solid rgba(255,255,255,.23);
    border-radius: 25px;

    background: rgba(255,255,255,.10);
    color: #ffffff;

    font-size: 12px;
    font-weight: 600;
}


/* Decoratieve wiskundesymbolen */

.xm-hero-decoration {
    position: absolute;
    top: 5px;
    right: 25px;

    width: 250px;
    height: 210px;

    opacity: .15;
    pointer-events: none;

    font-family: Georgia, serif;
}

.xm-hero-decoration span {
    position: absolute;
    color: #bce8ff;
    font-weight: 700;
}

.xm-hero-decoration span:nth-child(1) {
    top: 20px;
    right: 5px;
    font-size: 38px;
    transform: rotate(-12deg);
}

.xm-hero-decoration span:nth-child(2) {
    top: 55px;
    left: 20px;
    font-size: 80px;
    transform: rotate(15deg);
}

.xm-hero-decoration span:nth-child(3) {
    bottom: -15px;
    right: 35px;
    font-size: 95px;
}


/* =====================================================
   5. INTRODUCTIE
   ===================================================== */

.xm-intro {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;

    margin: 36px 0 23px;
}

.xm-intro > div:first-child {
    flex: 1;
    min-width: 0;
}

.xm-section-label {
    margin-bottom: 8px;

    color: var(--cat-dark);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.6px;
}

.xm-intro h2 {
    margin: 0 0 9px;

    color: #102b47;
    font-size: clamp(24px, 2.6vw, 30px);
    font-weight: 800;
}

.xm-intro p {
    max-width: 750px;
    margin: 0;

    color: #5c7186;
    font-size: 14px;
    line-height: 1.7;
}


/* Voorbeeldenteller */

.xm-example-counter {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    min-width: 112px;
    padding: 13px 19px;

    background: var(--cat-light);
    border: 1px solid var(--cat-mid);
    border-radius: 13px;
}

.xm-example-counter strong {
    color: var(--cat-dark);
    font-size: 29px;
    font-weight: 800;
    line-height: 1.2;
}

.xm-example-counter span {
    margin-top: 3px;
    color: #60778a;
    font-size: 12px;
}


/* =====================================================
   6. LISTING - EXAMPLE 1 T/M 10
   ===================================================== */

.xm-examples-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.xm-example-card {
    display: flex;
    align-items: center;
    gap: 17px;

    min-width: 0;
    min-height: 89px;
    padding: 18px 20px;

    background: #ffffff;

    border: 1px solid #d1e0ed;
    border-radius: 14px;

    box-shadow: var(--xm-shadow);

    color: var(--xm-text);

    transition:
        transform .2s ease,
        background .2s ease,
        border-color .2s ease,
        box-shadow .2s ease;
}

.xm-example-card:hover {
    background: var(--cat-light);
    border-color: var(--cat-mid);

    transform: translateY(-2px);

    box-shadow: 0 8px 19px rgba(10,48,85,.12);
}


/* Nummerblokjes */

.xm-example-number {
    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    width: 50px;
    height: 50px;

    background: linear-gradient(
        135deg,
        var(--cat-light),
        var(--cat-mid)
    );

    border: 1px solid var(--cat-mid);
    border-radius: 11px;

    color: var(--cat-dark);

    font-size: 18px;
    font-weight: 800;
}


/* Tekst */

.xm-example-text {
    flex: 1;
    min-width: 0;
}

.xm-example-text h3 {
    margin: 0 0 5px;

    color: var(--xm-text);
    font-size: 17px;
    font-weight: 800;
}

.xm-example-text p {
    margin: 0;

    color: #65798c;
    font-size: 12px;
    line-height: 1.4;
}


/* Pijltje rechts */

.xm-example-arrow {
    display: grid;
    place-items: center;

    flex-shrink: 0;

    width: 31px;
    height: 31px;

    border-radius: 50%;
    background: var(--cat-light);
    color: var(--cat-dark);

    font-size: 26px;
    line-height: 1;
}

.xm-example-card:hover .xm-example-arrow {
    background: var(--cat-dark);
    color: #ffffff;
}


/* =====================================================
   7. STUDIETIP
   ===================================================== */

.xm-info-box {
    display: flex;
    align-items: flex-start;
    gap: 18px;

    margin-top: 34px;
    padding: 24px 27px;

    border: 1px solid #bbd8e9;
    border-left: 4px solid var(--cat-dark);
    border-radius: 13px;

    background: linear-gradient(
        120deg,
        #f7fbfe,
        var(--cat-light)
    );
}

.xm-info-icon {
    display: grid;
    place-items: center;

    flex-shrink: 0;

    width: 40px;
    height: 40px;

    border-radius: 50%;
    background: var(--cat-light);
    color: var(--cat-dark);

    font-size: 24px;
    font-weight: 800;
}

.xm-info-box h2 {
    margin: 0 0 8px;

    color: #103551;
    font-size: 19px;
    font-weight: 800;
}

.xm-info-box p {
    margin: 0;

    color: #405a70;
    font-size: 14px;
    line-height: 1.7;
}


/* =====================================================
   8. GERELATEERDE ONDERWERPEN
   ===================================================== */

.xm-related {
    margin-top: 39px;
}

.xm-related h2 {
    margin: 0 0 17px;

    color: #102b47;
    font-size: 23px;
    font-weight: 800;
}

.xm-related-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.xm-related-card {
    display: flex;
    align-items: center;
    gap: 16px;

    min-width: 0;
    padding: 18px 20px;

    background: #ffffff;

    border: 1px solid #d1e0ed;
    border-radius: 13px;

    box-shadow: var(--xm-shadow);

    transition:
        background .2s ease,
        border-color .2s ease,
        transform .2s ease;
}

.xm-related-card:hover {
    background: var(--cat-light);
    border-color: var(--cat-mid);
    transform: translateY(-2px);
}

.xm-related-symbol {
    display: grid;
    place-items: center;

    flex-shrink: 0;

    width: 48px;
    height: 48px;

    border-radius: 11px;
    background: var(--cat-light);
    color: var(--cat-dark);

    font-family: Georgia, serif;
    font-size: 25px;
    font-weight: 800;
}

.xm-related-text {
    flex: 1;
    min-width: 0;
}

.xm-related-card strong {
    display: block;

    color: var(--xm-text);
    font-size: 16px;
    font-weight: 800;
}

.xm-related-card small {
    display: block;
    margin-top: 4px;

    color: #64798c;
    font-size: 12px;
}

.xm-related-arrow {
    margin-left: auto;
    color: var(--cat-dark);
    font-size: 26px;
}


/* =====================================================
   9. INDIVIDUELE EXAMPLE PAGINA
   ===================================================== */

.xm-solution-panel {
    margin: 30px 0 24px;
    padding: 30px;

    background: #ffffff;
    border: 1px solid var(--cat-mid);
    border-radius: 17px;

    box-shadow: var(--xm-shadow);
}

.xm-solution-panel h2 {
    margin: 0 0 22px;

    color: #103451;
    font-size: clamp(21px, 3vw, 29px);
    line-height: 1.3;
}

.xm-solution-placeholder {
    padding: 40px 25px;
    text-align: center;

    background: linear-gradient(
        135deg,
        #ffffff,
        var(--cat-light)
    );

    border: 1px dashed var(--cat-mid);
    border-radius: 14px;
}

.xm-coming-icon {
    display: grid;
    place-items: center;

    width: 65px;
    height: 65px;
    margin: 0 auto 18px;

    background: var(--cat-light);
    border-radius: 17px;

    color: var(--cat-dark);
    font-family: Georgia, serif;
    font-size: 39px;
}

.xm-solution-placeholder h3 {
    margin: 0 0 13px;

    color: #103451;
    font-size: 23px;
}

.xm-solution-placeholder p {
    max-width: 540px;
    margin: 9px auto;

    color: #536e83;
    font-size: 14px;
    line-height: 1.7;
}

.xm-coming-label {
    display: inline-block;

    margin-top: 18px;
    padding: 8px 19px;

    border-radius: 25px;

    background: var(--cat-light);
    color: var(--cat-dark);

    font-size: 12px;
    font-weight: 800;
}


/* =====================================================
   10. VORIGE / VOLGENDE / ALLE VOORBEELDEN
   ===================================================== */

.xm-example-navigation {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 12px;

    margin: 25px 0;
}

.xm-example-navigation > div:first-child {
    text-align: left;
}

.xm-example-navigation > div:last-child {
    text-align: right;
}

.xm-example-navigation a {
    display: inline-block;
    padding: 11px 17px;

    border: 1px solid var(--cat-mid);
    border-radius: 10px;

    background: #ffffff;
    color: var(--cat-dark);

    font-size: 13px;
    font-weight: 700;

    transition:
        background .2s ease,
        border-color .2s ease;
}

.xm-example-navigation a:hover {
    background: var(--cat-light);
    border-color: var(--cat-dark);
}

.xm-example-navigation .xm-back-examples {
    background: var(--cat-dark);
    border-color: var(--cat-dark);
    color: #ffffff;
    text-align: center;
}

.xm-example-navigation .xm-back-examples:hover {
    filter: brightness(.9);
    color: #ffffff;
}


/* =====================================================
   11. TABLET
   ===================================================== */

@media (max-width: 900px) {

    .xm-page {
        width: 94%;
    }

    .xm-topic-hero {
        min-height: 200px;
        padding: 30px;
    }

    .xm-hero-decoration {
        opacity: .08;
    }
}


/* =====================================================
   12. MOBIEL
   ===================================================== */

@media (max-width: 650px) {

    .xm-page {
        padding-top: 16px;
        padding-bottom: 45px;
    }

    /* Breadcrumb */

    .xm-breadcrumb {
        gap: 6px;
        margin-bottom: 16px;
        font-size: 12px;
    }

    /* Titelbalk */

    .xm-topic-hero {
        min-height: auto;
        padding: 26px 21px;
        border-radius: 15px;
    }

    .xm-topic-hero h1 {
        font-size: 32px;
    }

    .xm-topic-hero p {
        font-size: 13px;
        line-height: 1.6;
    }

    .xm-hero-tags {
        gap: 7px;
        margin-top: 18px;
    }

    .xm-hero-tags span {
        padding: 6px 10px;
        font-size: 10px;
    }

    .xm-hero-decoration {
        display: none;
    }

    /* Introductie */

    .xm-intro {
        align-items: flex-start;
        gap: 12px;
        margin: 27px 0 19px;
    }

    .xm-intro h2 {
        font-size: 23px;
    }

    .xm-intro p {
        font-size: 13px;
    }

    .xm-example-counter {
        min-width: 72px;
        padding: 10px 8px;
    }

    .xm-example-counter strong {
        font-size: 23px;
    }

    .xm-example-counter span {
        font-size: 10px;
    }

    /* Listings - 1 kolom */

    .xm-examples-grid {
        grid-template-columns: 1fr;
        gap: 11px;
    }

    .xm-example-card {
        min-height: 73px;
        padding: 13px 14px;
        gap: 13px;
    }

    .xm-example-number {
        width: 44px;
        height: 44px;
        font-size: 16px;
    }

    .xm-example-text h3 {
        font-size: 15px;
    }

    .xm-example-text p {
        font-size: 11px;
    }

    /* Studietip */

    .xm-info-box {
        padding: 19px;
        gap: 13px;
    }

    .xm-info-icon {
        width: 33px;
        height: 33px;
        font-size: 19px;
    }

    .xm-info-box h2 {
        font-size: 17px;
    }

    .xm-info-box p {
        font-size: 12px;
    }

    /* Gerelateerd */

    .xm-related {
        margin-top: 30px;
    }

    .xm-related h2 {
        font-size: 21px;
    }

    .xm-related-grid {
        grid-template-columns: 1fr;
        gap: 11px;
    }

    .xm-related-card {
        padding: 15px;
    }

    /* Uitwerking */

    .xm-solution-panel {
        padding: 18px;
        margin-top: 20px;
    }

    .xm-solution-panel h2 {
        font-size: 22px;
    }

    .xm-solution-placeholder {
        padding: 30px 14px;
    }

    .xm-solution-placeholder h3 {
        font-size: 20px;
    }

    .xm-solution-placeholder p {
        font-size: 13px;
    }

    /* Navigatie */

    .xm-example-navigation {
        grid-template-columns:
            minmax(0, 1fr) minmax(0, 1fr);
        gap: 10px;
    }

    .xm-example-navigation .xm-back-examples {
        grid-column: 1 / -1;
        grid-row: 1;
    }

    .xm-example-navigation a {
        font-size: 12px;
        padding: 10px;
    }
}


/* =====================================================
   13. EXTRA KLEINE TELEFOONS
   ===================================================== */

@media (max-width: 360px) {

    .xm-intro {
        flex-direction: column;
    }

    .xm-example-counter {
        width: 100%;
        flex-direction: row;
        gap: 7px;
    }

    .xm-example-text h3 {
        font-size: 14px;
    }

    .xm-example-card {
        padding: 12px;
    }

    .xm-example-navigation a {
        font-size: 11px;
        padding: 9px 6px;
    }
}
