/*
Theme Name: Medical Study
Theme URI: https://example.com/
Author: Medical Study
Description: Custom medical education WordPress theme.
Version: 1.0.0
Text Domain: medical-study
*/

/* =========================================================
   MEDICAL STUDY — DESIGN SYSTEM
   ========================================================= */

:root {

    --primary-navy: #102A43;
    --medical-blue: #1976D2;
    --dark-blue: #1259A5;

    --soft-blue: #EAF4FF;
    --pale-blue: #F5FAFF;

    --green: #167A55;
    --soft-green: #EAF8F2;

    --orange: #B85C00;
    --soft-orange: #FFF4E6;

    --red: #B42318;
    --soft-red: #FFF0EF;

    --purple: #6941C6;
    --soft-purple: #F5F1FF;

    --text: #17212B;
    --muted: #667085;
    --border: #E3EAF1;

    --page-bg: #F6F8FB;
    --white: #FFFFFF;

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 18px;
    --radius-xl: 24px;

    --shadow-sm:
        0 2px 8px rgba(16, 42, 67, .06);

    --shadow-md:
        0 10px 30px rgba(16, 42, 67, .09);
}


/* =========================================================
   GLOBAL RESET
   ========================================================= */

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;

    background: var(--page-bg);
    color: var(--text);

    font-family:
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Roboto,
        Helvetica,
        Arial,
        sans-serif;

    font-size: 16px;
    line-height: 1.6;
}

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

img {
    display: block;
    max-width: 100%;
    height: auto;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
textarea,
select {
    font: inherit;
}

button {
    cursor: pointer;
}


/* =========================================================
   SITE CONTAINER
   ========================================================= */

.site-container {
    width: min(1180px, calc(100% - 40px));
    margin: 0 auto;
}


/* =========================================================
   HEADER
   ========================================================= */

.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;

    background: rgba(255,255,255,.97);

    border-bottom: 1px solid var(--border);

    box-shadow:
        0 2px 12px rgba(16,42,67,.04);
}

.site-header-inner {
    width: min(1180px, calc(100% - 40px));
    min-height: 72px;

    margin: 0 auto;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 30px;
}


/* =========================================================
   LOGO
   ========================================================= */

.site-logo {
    display: inline-flex;
    align-items: center;

    gap: 10px;

    color: var(--primary-navy);

    font-weight: 800;

    white-space: nowrap;
}

.site-logo-mark {
    width: 40px;
    height: 40px;

    display: grid;
    place-items: center;

    border-radius: 11px;

    background:
        linear-gradient(
            135deg,
            var(--medical-blue),
            var(--dark-blue)
        );

    color: var(--white);

    font-size: 18px;
    font-weight: 800;
}

.site-logo-text {
    font-size: 18px;
}

.site-logo img {
    display: block;
    width: 280px;
    max-width: 100%;
    height: auto;
}

/* =========================================================
   NAVIGATION
   ========================================================= */

.site-navigation ul {
    display: flex;
    align-items: center;

    gap: 24px;

    margin: 0;
    padding: 0;

    list-style: none;
}

.site-navigation li {
    margin: 0;
    padding: 0;
}

.site-navigation a {
    display: inline-block;

    padding: 8px 0;

    color: var(--text);

    font-size: 14px;
    font-weight: 600;

    text-decoration: none;

    transition:
        color .2s ease;
}

.site-navigation a:hover {
    color: var(--medical-blue);
}


/* =========================================================
   GENERIC WORDPRESS CONTENT
   ========================================================= */

.site-main {
    min-height: 60vh;
    padding: 50px 0;
}

.page-content,
.single-study,
.study-card {
    width: min(900px, calc(100% - 40px));

    margin: 0 auto;

    padding: 35px;

    background: var(--white);

    border: 1px solid var(--border);
    border-radius: var(--radius-lg);

    box-shadow: var(--shadow-sm);
}

.page-content h1,
.single-study h1,
.study-card h1 {
    margin-top: 0;

    color: var(--primary-navy);
}


/* =========================================================
   FOOTER
   ========================================================= */

.site-footer {
    margin-top: 60px;

    background: var(--primary-navy);

    color: var(--white);
}

.site-footer-inner {
    width: min(1180px, calc(100% - 40px));

    margin: 0 auto;

    padding: 42px 0;

    display: flex;
    align-items: flex-start;
    justify-content: space-between;

    gap: 40px;
}

.site-footer strong {
    font-size: 18px;
}

.site-footer p {
    margin: 7px 0 0;

    color: rgba(255,255,255,.72);

    font-size: 13px;
}


/* =========================================================
   HOMEPAGE
   ========================================================= */

.medical-home {
    width: 100%;

    background: var(--page-bg);

    color: var(--text);
}

.medical-home .home-container {
    width: min(1180px, calc(100% - 40px));

    margin: 0 auto;
}


/* =========================================================
   HERO
   ========================================================= */

.medical-home .home-hero {
    position: relative;

    overflow: hidden;

    padding: 100px 0 115px;

    background:
        radial-gradient(
            circle at 85% 20%,
            rgba(25,118,210,.35),
            transparent 35%
        ),
        linear-gradient(
            135deg,
            #102A43 0%,
            #1259A5 55%,
            #1976D2 100%
        );

    color: var(--white);
}

.medical-home .home-hero::after {
    content: "";

    position: absolute;

    width: 320px;
    height: 320px;

    right: -120px;
    bottom: -180px;

    border-radius: 50%;

    background: rgba(255,255,255,.06);
}

.medical-home .hero-content {
    position: relative;
    z-index: 2;

    max-width: 780px;
}

.medical-home .hero-eyebrow {
    display: inline-flex;

    padding: 7px 13px;

    border:
        1px solid rgba(255,255,255,.25);

    border-radius: 999px;

    background:
        rgba(255,255,255,.10);

    color: var(--white);

    font-size: 12px;
    font-weight: 700;

    letter-spacing: .1em;
}

.medical-home .hero-content h1 {
    margin: 22px 0 20px;

    color: var(--white);

    font-size:
        clamp(42px, 6vw, 72px);

    line-height: 1.02;

    letter-spacing: -.035em;
}

.medical-home .hero-content p {
    max-width: 650px;

    margin: 0;

    color:
        rgba(255,255,255,.88);

    font-size: 19px;

    line-height: 1.7;
}

.medical-home .hero-actions {
    display: flex;
    flex-wrap: wrap;

    gap: 12px;

    margin-top: 32px;
}


/* =========================================================
   BUTTONS
   ========================================================= */

.medical-home .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 48px;

    padding: 0 22px;

    border-radius: 10px;

    font-weight: 700;

    text-decoration: none;

    transition:
        transform .2s ease,
        box-shadow .2s ease;
}

.medical-home .btn:hover {
    transform: translateY(-2px);
}

.medical-home .btn-primary {
    background: var(--medical-blue);

    color: var(--white);

    box-shadow:
        0 8px 20px
        rgba(25,118,210,.22);
}

.medical-home .home-hero .btn-primary {
    background: var(--white);

    color: var(--primary-navy);
}

.medical-home .btn-light {
    border:
        1px solid rgba(255,255,255,.3);

    background:
        rgba(255,255,255,.08);

    color: var(--white);
}


/* =========================================================
   SEARCH
   ========================================================= */

.medical-home .home-search-section {
    position: relative;
    z-index: 10;

    margin-top: -42px;
}

.medical-home .search-card {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 30px;

    padding: 25px 28px;

    background: var(--white);

    border:
        1px solid var(--border);

    border-radius:
        var(--radius-lg);

    box-shadow:
        var(--shadow-md);
}

.medical-home .search-heading {
    display: flex;
    align-items: center;

    gap: 14px;

    min-width: 250px;
}

.medical-home .search-icon {
    width: 46px;
    height: 46px;

    flex: 0 0 46px;

    display: grid;
    place-items: center;

    border-radius: 12px;

    background: var(--soft-blue);

    font-size: 20px;
}

.medical-home .search-heading h2 {
    margin: 0;

    color: var(--primary-navy);

    font-size: 18px;
}

.medical-home .search-heading p {
    margin: 2px 0 0;

    color: var(--muted);

    font-size: 13px;
}

.medical-home .study-search {
    flex: 1;

    display: flex;

    gap: 8px;
}

.medical-home .study-search input {
    flex: 1;

    min-width: 0;
    height: 48px;

    padding: 0 16px;

    border:
        1px solid var(--border);

    border-radius: 9px;

    outline: none;

    background: var(--pale-blue);

    color: var(--text);

    font-size: 14px;
}

.medical-home .study-search input:focus {
    border-color:
        var(--medical-blue);

    box-shadow:
        0 0 0 3px
        rgba(25,118,210,.10);
}

.medical-home .study-search button {
    height: 48px;

    padding: 0 20px;

    border: 0;

    border-radius: 9px;

    background: var(--medical-blue);

    color: var(--white);

    font-weight: 700;

    cursor: pointer;
}


/* =========================================================
   SECTIONS
   ========================================================= */

.medical-home .home-section {
    padding: 85px 0;
}

.medical-home .home-section-soft {
    background: var(--soft-blue);
}

.medical-home .section-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;

    gap: 30px;

    margin-bottom: 30px;
}

.medical-home .section-label {
    display: block;

    margin-bottom: 7px;

    color: var(--medical-blue);

    font-size: 12px;
    font-weight: 800;

    letter-spacing: .1em;
}

.medical-home .section-heading h2 {
    margin: 0;

    color: var(--primary-navy);

    font-size:
        clamp(28px, 4vw, 38px);

    line-height: 1.15;
}

.medical-home .section-heading > p {
    max-width: 400px;

    margin: 0;

    color: var(--muted);
}

.medical-home .section-link {
    color: var(--medical-blue);

    font-weight: 700;

    white-space: nowrap;
}


/* =========================================================
   SUBJECT CARDS
   ========================================================= */

.medical-home .subject-grid {
    display: grid;

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

    gap: 18px;
}

.medical-home .subject-card {
    position: relative;

    display: block;

    padding: 26px;

    background: var(--white);

    border:
        1px solid var(--border);

    border-radius:
        var(--radius-lg);

    box-shadow:
        var(--shadow-sm);

    overflow: hidden;

    color: var(--text);

    text-decoration: none;

    transition:
        transform .2s ease,
        box-shadow .2s ease,
        border-color .2s ease;
}

.medical-home .subject-card:hover {
    transform: translateY(-4px);

    border-color: #C8D8E8;

    box-shadow:
        var(--shadow-md);
}

.medical-home .subject-icon {
    width: 52px;
    height: 52px;

    display: grid;
    place-items: center;

    margin-bottom: 22px;

    border-radius: 14px;

    font-size: 15px;
    font-weight: 800;
}

.medical-home .subject-anatomy .subject-icon {
    background: var(--soft-blue);
    color: var(--medical-blue);
}

.medical-home .subject-physiology .subject-icon {
    background: var(--soft-green);
    color: var(--green);
}

.medical-home .subject-biochemistry .subject-icon {
    background: var(--soft-purple);
    color: var(--purple);
}

.medical-home .subject-dental .subject-icon {
    background: var(--soft-orange);
    color: var(--orange);
}

.medical-home .subject-histology .subject-icon {
    background: var(--soft-red);
    color: var(--red);
}

.medical-home .subject-number {
    color: var(--muted);

    font-size: 11px;
    font-weight: 800;

    letter-spacing: .08em;
}

.medical-home .subject-card h3 {
    margin: 7px 0 8px;

    color: var(--primary-navy);

    font-size: 22px;
}

.medical-home .subject-card p {
    margin: 0;

    color: var(--muted);

    font-size: 14px;

    line-height: 1.6;
}

.medical-home .card-link {
    display: inline-block;

    margin-top: 20px;

    color: var(--medical-blue);

    font-size: 13px;
    font-weight: 700;
}


/* =========================================================
   BODY REGION CARDS
   ========================================================= */

.medical-home .region-grid {
    display: grid;

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

    gap: 20px;
}

.medical-home .region-card {
    display: block;

    overflow: hidden;

    background: var(--white);

    border:
        1px solid var(--border);

    border-radius:
        var(--radius-lg);

    box-shadow:
        var(--shadow-sm);

    text-decoration: none;

    transition:
        transform .2s ease,
        box-shadow .2s ease;
}

.medical-home .region-card:hover {
    transform: translateY(-4px);

    box-shadow:
        var(--shadow-md);
}

.medical-home .region-image {
    height: 220px;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 15px;

    background: var(--white);
}

.medical-home .region-image img {
    width: 100%;
    height: 100%;

    object-fit: contain;

    border-radius: 10px;
}

.medical-home .region-content {
    padding: 20px 22px 23px;
}

.medical-home .region-content > span {
    color: var(--medical-blue);

    font-size: 11px;
    font-weight: 800;

    letter-spacing: .1em;
}

.medical-home .region-content h3 {
    margin: 5px 0 12px;

    color: var(--primary-navy);

    font-size: 22px;
}

.medical-home .region-content strong {
    color: var(--medical-blue);

    font-size: 13px;
}


/* =========================================================
   QUICK ACCESS
   ========================================================= */

.medical-home .quick-grid {
    display: grid;

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

    gap: 14px;
}

.medical-home .quick-card {
    display: flex;
    align-items: center;

    gap: 16px;

    padding: 19px;

    background: var(--white);

    border:
        1px solid var(--border);

    border-radius:
        var(--radius-md);

    box-shadow:
        var(--shadow-sm);

    text-decoration: none;

    transition:
        transform .2s ease,
        border-color .2s ease;
}

.medical-home .quick-card:hover {
    transform: translateY(-2px);

    border-color: #C8D8E8;
}

.medical-home .quick-icon {
    width: 44px;
    height: 44px;

    flex: 0 0 44px;

    display: grid;
    place-items: center;

    border-radius: 11px;

    font-weight: 800;
}

.medical-home .quick-icon.blue {
    background: var(--soft-blue);
    color: var(--medical-blue);
}

.medical-home .quick-icon.green {
    background: var(--soft-green);
    color: var(--green);
}

.medical-home .quick-icon.purple {
    background: var(--soft-purple);
    color: var(--purple);
}

.medical-home .quick-icon.orange {
    background: var(--soft-orange);
    color: var(--orange);
}

.medical-home .quick-card h3 {
    margin: 0 0 2px;

    color: var(--primary-navy);

    font-size: 16px;
}

.medical-home .quick-card p {
    margin: 0;

    color: var(--muted);

    font-size: 13px;
}

.medical-home .quick-arrow {
    margin-left: auto;

    color: var(--medical-blue);

    font-size: 20px;
}


/* =========================================================
   CTA
   ========================================================= */

.medical-home .home-cta {
    padding: 0 0 85px;
}

.medical-home .cta-card {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 30px;

    padding: 40px;

    border-radius:
        var(--radius-xl);

    background:
        linear-gradient(
            135deg,
            var(--primary-navy),
            var(--dark-blue)
        );

    color: var(--white);
}

.medical-home .cta-card > div {
    max-width: 650px;
}

.medical-home .cta-card span {
    font-size: 11px;
    font-weight: 800;

    letter-spacing: .1em;

    opacity: .75;
}

.medical-home .cta-card h2 {
    margin: 10px 0;

    color: var(--white);

    font-size:
        clamp(25px, 4vw, 36px);

    line-height: 1.2;
}

.medical-home .cta-card p {
    margin: 0;

    color:
        rgba(255,255,255,.78);
}


/* =========================================================
   RESPONSIVE — TABLET
   ========================================================= */

@media (max-width: 900px) {

    .medical-home .subject-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .medical-home .region-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .medical-home .search-card {
        align-items: stretch;

        flex-direction: column;
    }

    .medical-home .search-heading {
        min-width: 0;
    }

    .medical-home .study-search {
        width: 100%;
    }

    .site-navigation {
        display: none;
    }
}


/* =========================================================
   RESPONSIVE — MOBILE
   ========================================================= */

@media (max-width: 650px) {

    .site-container,
    .site-header-inner,
    .site-footer-inner,
    .medical-home .home-container {
        width:
            min(100% - 28px, 1180px);
    }

    .site-header-inner {
        min-height: 64px;
    }

    .medical-home .home-hero {
        padding: 70px 0 85px;
    }

    .medical-home .hero-content h1 {
        font-size: 43px;
    }

    .medical-home .hero-content p {
        font-size: 16px;
    }

    .medical-home .hero-actions {
        flex-direction: column;
    }

    .medical-home .hero-actions .btn {
        width: 100%;
    }

    .medical-home .home-section {
        padding: 60px 0;
    }

    .medical-home .section-heading {
        align-items: flex-start;

        flex-direction: column;

        gap: 12px;
    }

    .medical-home .subject-grid,
    .medical-home .region-grid,
    .medical-home .quick-grid {
        grid-template-columns: 1fr;
    }

    .medical-home .region-image {
        height: 240px;
    }

    .medical-home .cta-card {
        align-items: flex-start;

        flex-direction: column;

        padding: 28px;
    }

    .medical-home .cta-card .btn {
        width: 100%;
    }

    .medical-home .study-search {
        flex-direction: column;
    }

    .medical-home .study-search button {
        width: 100%;
    }

    .site-footer-inner {
        flex-direction: column;
    }
}