/* =========================================================
   TUPS EDUCATION HUB — MODULES CSS
   ---------------------------------------------------------
   Sidebar / Education Hub module styling only.
   Education News full-page styling remains in style.css.
========================================================= */


/* =========================================================
   BASE MODULE
========================================================= */

.hub-module {
    --module-bg: #f5f7f9;
    --module-accent: #176b91;

    position: relative;
    overflow: hidden;

    background: var(--module-bg);
    border: 1px solid rgba(0, 0, 0, 0.09);
    border-radius: 10px;

    box-shadow: 3px 3px 0 rgba(0, 0, 0, 0.07);

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}


/* Left identity strip */

.hub-module::before {
    content: "";

    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;

    width: 4px;

    background: var(--module-accent);
}


/* Subtle hover effect */

.hub-module:hover {
    transform: translateY(-2px);

    box-shadow:
        5px 5px 0 rgba(0, 0, 0, 0.09);
}


/* =========================================================
   MODULE IDENTITY COLORS
========================================================= */

/* Partner Schools */

.partner-module {
    --module-bg: #f3f7fb;
    --module-accent: #176b91;
}


/* Education News */

.news-module {
    --module-bg: #f1f6fb;
    --module-accent: #315f89;
}


/* School Gist */

.gist-module {
    --module-bg: #fbf8f0;
    --module-accent: #a87524;
}


/* Abuja School Jobs */

.jobs-module {
    --module-bg: #eef8f5;
    --module-accent: #247866;
}


/* Teacher Resources */

.teacher-module {
    --module-bg: #f5f2fa;
    --module-accent: #715b91;
}


/* Student Zone */

.student-module {
    --module-bg: #eef7fc;
    --module-accent: #287aa6;
}


/* TUPS Tools */

.tools-module {
    --module-bg: #f3f4f5;
    --module-accent: #343a40;
}


/* TUPS Play Zone */

.play-module {
    --module-bg: #edf9fc;
    --module-accent: #0098bd;
}


/* Opportunities */

.opportunities-module {
    --module-bg: #faf6eb;
    --module-accent: #967326;
}


/* =========================================================
   MODULE HEADING
========================================================= */

.hub-module-heading {
    display: flex;
    align-items: center;
    gap: 10px;

    padding: 15px 15px 8px 18px;
}


.hub-module-heading h2 {
    margin: 0;

    font-size: 1rem;
    line-height: 1.2;

    color: #1b2730;
    font-weight: 800;
}


.hub-module-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    flex: 0 0 34px;

    width: 34px;
    height: 34px;

    border-radius: 8px;

    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(0, 0, 0, 0.08);

    color: var(--module-accent);

    font-size: 0.95rem;
}


/* =========================================================
   MODULE DESCRIPTION
========================================================= */

.hub-module-description {
    margin: 0;

    padding: 0 15px 13px 18px;

    color: #5d6871;

    font-size: 0.82rem;
    line-height: 1.5;
}


/* =========================================================
   MODULE PREVIEW
========================================================= */

.hub-preview {
    margin: 0 14px 13px 18px;
}


.hub-preview-item {
    padding: 10px 11px;

    background: rgba(255, 255, 255, 0.68);

    border: 1px solid rgba(0, 0, 0, 0.07);
    border-radius: 7px;
}


.hub-preview-item strong {
    display: block;

    color: #27343d;

    font-size: 0.78rem;
    line-height: 1.4;
}


.hub-preview-item span {
    display: block;

    margin-top: 4px;

    color: #7a858d;

    font-size: 0.7rem;
}


/* =========================================================
   LINK GRID
========================================================= */

.hub-link-grid {
    display: grid;

    grid-template-columns: repeat(2, minmax(0, 1fr));

    gap: 7px;

    padding: 0 14px 14px 18px;
}


.hub-link-grid button {
    width: 100%;

    padding: 9px 8px;

    background: rgba(255, 255, 255, 0.72);

    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 7px;

    color: #39454d;

    font-family: inherit;
    font-size: 0.73rem;
    font-weight: 700;

    cursor: pointer;

    transition:
        background 0.18s ease,
        border-color 0.18s ease,
        transform 0.18s ease;
}


.hub-link-grid button:hover {
    background: #ffffff;

    border-color: var(--module-accent);

    transform: translateY(-1px);
}


.hub-link-grid button:focus-visible {
    outline: 2px solid var(--module-accent);
    outline-offset: 2px;
}


/* =========================================================
   MORE / ACTION BUTTON
========================================================= */

.hub-more-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;

    margin: 0 14px 15px 18px;
    padding: 8px 11px;

    background: rgba(255, 255, 255, 0.72);

    border: 1px solid rgba(0, 0, 0, 0.09);
    border-radius: 7px;

    color: var(--module-accent);

    font-family: inherit;
    font-size: 0.74rem;
    font-weight: 800;

    cursor: pointer;

    transition:
        background 0.18s ease,
        border-color 0.18s ease,
        transform 0.18s ease;
}


.hub-more-button:hover {
    background: #ffffff;

    border-color: var(--module-accent);

    transform: translateX(2px);
}


.hub-more-button:focus-visible {
    outline: 2px solid var(--module-accent);
    outline-offset: 2px;
}


.hub-more-button i {
    font-size: 0.68rem;
}


/* =========================================================
   ABUJA / FCT BADGE
========================================================= */

.hub-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;

    margin: 0 14px 13px 18px;
    padding: 5px 9px;

    background: rgba(255, 255, 255, 0.72);

    border: 1px solid rgba(36, 120, 102, 0.2);
    border-radius: 999px;

    color: #247866;

    font-size: 0.68rem;
    font-weight: 800;
}


.hub-badge i {
    font-size: 0.65rem;
}


/* =========================================================
   PLAY ZONE MINI LINKS
========================================================= */

.play-mini-links {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;

    padding: 0 14px 13px 18px;
}


.play-mini-links button {
    display: inline-flex;
    align-items: center;
    gap: 5px;

    padding: 7px 9px;

    background: rgba(255, 255, 255, 0.72);

    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 7px;

    color: #39454d;

    font-family: inherit;
    font-size: 0.7rem;
    font-weight: 700;

    cursor: pointer;

    transition:
        background 0.18s ease,
        border-color 0.18s ease,
        transform 0.18s ease;
}


.play-mini-links button:hover {
    background: #ffffff;

    border-color: var(--module-accent);

    transform: translateY(-1px);
}


.play-mini-links button:focus-visible {
    outline: 2px solid var(--module-accent);
    outline-offset: 2px;
}


.play-mini-links i {
    color: var(--module-accent);
}


/* =========================================================
   PARTNER SCHOOLS
   ---------------------------------------------------------
   Existing school-item styling can coexist with the module.
========================================================= */

.partner-module .partner-schools {
    padding: 0 14px 15px 18px;
}


.partner-module .school-item {
    width: 100%;

    display: flex;
    align-items: center;
    gap: 10px;

    padding: 9px;

    margin-bottom: 7px;

    background: rgba(255, 255, 255, 0.68);

    border: 1px solid rgba(0, 0, 0, 0.07);
    border-radius: 7px;

    color: #39454d;

    font-family: inherit;
    font-size: 0.74rem;
    font-weight: 700;

    text-align: left;

    cursor: pointer;

    transition:
        background 0.18s ease,
        border-color 0.18s ease,
        transform 0.18s ease;
}


.partner-module .school-item:last-child {
    margin-bottom: 0;
}


.partner-module .school-item:hover {
    background: #ffffff;

    border-color: var(--module-accent);

    transform: translateX(2px);
}


.partner-module .school-item:focus-visible {
    outline: 2px solid var(--module-accent);
    outline-offset: 2px;
}


.partner-module .school-logo-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;

    flex: 0 0 32px;

    width: 32px;
    height: 32px;

    background: #ffffff;

    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 7px;

    color: var(--module-accent);

    font-size: 0.68rem;
    font-weight: 900;
}


/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 600px) {

    .hub-module-heading {
        padding-top: 14px;
        padding-bottom: 7px;
    }

    .hub-module-heading h2 {
        font-size: 0.94rem;
    }

    .hub-module-icon {
        flex-basis: 32px;

        width: 32px;
        height: 32px;
    }

    .hub-module-description {
        font-size: 0.8rem;
    }

    .hub-link-grid {
        gap: 6px;
    }

    .hub-link-grid button {
        padding: 8px 6px;

        font-size: 0.7rem;
    }

    .hub-more-button {
        width: calc(100% - 32px);
    }

}


/* =========================================================
   REDUCED MOTION
========================================================= */

@media (prefers-reduced-motion: reduce) {

    .hub-module,
    .hub-link-grid button,
    .hub-more-button,
    .play-mini-links button,
    .partner-module .school-item {
        transition: none;
    }

    .hub-module:hover,
    .hub-link-grid button:hover,
    .hub-more-button:hover,
    .play-mini-links button:hover,
    .partner-module .school-item:hover {
        transform: none;
    }

}
