/* =========================================================
   APEX AGED CARE SERVICES — BLOG PAGE
   Homepage-Matched Navy + Gold
========================================================= */

.apex-blog-page {
    --apex-navy: #073461;
    --apex-navy-dark: #05294d;

    --apex-gold: #b99252;
    --apex-gold-dark: #98733f;
    --apex-gold-light: #d8bf91;

    --apex-white: #ffffff;

    --apex-cream: #f8f4ec;
    --apex-cream-light: #fcfaf6;

    --apex-text: #253746;
    --apex-text-light: #64717a;

    --apex-border: #e8e2d8;
}


/* =========================================
   WORDPRESS / ELEMENTOR CLEANUP
========================================= */

.entry-title,
.page-header,
.site-main > header,
.elementor-page-title,
h1.entry-title {
    display: none !important;
}

.apex-blog-page,
.apex-blog-page * {
    box-sizing: border-box;
}

.apex-blog-page {
    position: relative;

    left: 50%;

    width: 100vw;
    max-width: 100vw;

    margin-left: -50vw;

    overflow: hidden;

    background: var(--apex-white);

    color: var(--apex-text);

    font-family: Arial, sans-serif;
}

.apex-blog-page a {
    text-decoration: none;
}

.apex-blog-page img {
    display: block;

    max-width: 100%;
}

.apex-blog-container {
    width: 100%;
    max-width: 1120px;

    margin: 0 auto;

    padding-left: 24px;
    padding-right: 24px;
}


/* =========================================
   HERO
========================================= */

.apex-blog-hero {
    position: relative;

    min-height: 320px;

    overflow: hidden;

    display: flex;
    align-items: center;
    justify-content: center;

    background: var(--apex-navy-dark);
}

.apex-blog-hero-bg {
    position: absolute;

    inset: 0;
}

.apex-blog-hero-bg img {
    width: 100%;
    height: 100%;

    object-fit: cover;

    object-position: 35% 38%;
}

.apex-blog-hero-overlay {
    position: absolute;

    inset: 0;

    z-index: 1;

    background:
        linear-gradient(
            90deg,
            rgba(5, 41, 77, .88) 0%,
            rgba(7, 52, 97, .76) 50%,
            rgba(7, 52, 97, .62) 100%
        );
}

.apex-blog-hero-content {
    position: relative;

    z-index: 2;

    padding-top: 55px;
    padding-bottom: 55px;

    text-align: center;

    color: #ffffff;
}

.apex-blog-hero-label {
    display: inline-block;

    margin-bottom: 9px;

    color: var(--apex-gold-light);

    font-size: 12px;
    font-weight: 700;

    letter-spacing: 1.4px;
}

.apex-blog-hero h1 {
    margin: 0 0 13px;

    color: #ffffff;

    font-size: clamp(42px, 4vw, 58px);
    font-weight: 800;

    line-height: 1.05;
}

.apex-blog-hero-content > p {
    max-width: 640px;

    margin: 0 auto 18px;

    color: rgba(255, 255, 255, .88);

    font-size: 15px;
    line-height: 1.7;
}


/* Breadcrumb */

.apex-blog-breadcrumb {
    display: flex;

    align-items: center;
    justify-content: center;

    gap: 10px;

    color: rgba(255, 255, 255, .94);

    font-size: 13px;
    font-weight: 700;
}

.apex-blog-breadcrumb a {
    color: #ffffff;
}

.apex-blog-breadcrumb a:hover {
    color: var(--apex-gold-light);
}

.apex-blog-breadcrumb > span[aria-hidden="true"] {
    color: var(--apex-gold);

    font-size: 20px;
}


/* =========================================
   BLOG SECTION
========================================= */

.apex-blog-section {
    padding: 64px 0 75px;

    background: var(--apex-cream-light);
}

.apex-blog-heading {
    max-width: 720px;

    margin: 0 auto 40px;

    text-align: center;
}

.apex-blog-eyebrow {
    display: inline-flex;

    align-items: center;

    gap: 9px;

    margin-bottom: 8px;

    color: var(--apex-gold-dark);

    font-size: 12px;
    font-weight: 700;

    letter-spacing: 1.25px;
}

.apex-blog-eyebrow::before,
.apex-blog-eyebrow::after {
    content: "";

    width: 28px;
    height: 1px;

    background: var(--apex-gold);
}

.apex-blog-heading h2 {
    margin: 0 0 13px;

    color: var(--apex-navy);

    font-size: clamp(30px, 3vw, 42px);
    font-weight: 800;

    line-height: 1.12;
}

.apex-blog-heading p {
    max-width: 650px;

    margin: 0 auto;

    color: var(--apex-text-light);

    font-size: 15px;
    line-height: 1.7;
}


/* =========================================
   DYNAMIC BLOG GRID
========================================= */

.apex-blog-grid {
    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    gap: 24px;
}


/* =========================================
   BLOG CARD
========================================= */

.apex-blog-card {
    min-width: 0;

    overflow: hidden;

    display: flex;
    flex-direction: column;

    background: #ffffff;

    border:
        1px solid
        var(--apex-border);

    border-radius: 15px;

    box-shadow:
        0 8px 24px
        rgba(7, 52, 97, .05);

    transition:
        transform .25s ease,
        box-shadow .25s ease,
        border-color .25s ease;
}

.apex-blog-card:hover {
    transform: translateY(-5px);

    border-color:
        rgba(185, 146, 82, .45);

    box-shadow:
        0 16px 36px
        rgba(7, 52, 97, .10);
}


/* Image */

.apex-blog-image {
    position: relative;

    width: 100%;
    height: 205px;

    overflow: hidden;

    display: block;

    background: var(--apex-cream);
}

.apex-blog-image img {
    width: 100%;
    height: 100%;

    object-fit: cover;

    transition:
        transform .4s ease;
}

.apex-blog-card:hover
.apex-blog-image img {
    transform: scale(1.04);
}


/* Placeholder */

.apex-blog-placeholder {
    width: 100%;
    height: 100%;

    display: flex;

    align-items: center;
    justify-content: center;

    background:
        linear-gradient(
            135deg,
            var(--apex-navy),
            var(--apex-navy-dark)
        );

    color: var(--apex-gold-light);

    font-size: 16px;
    font-weight: 700;
}


/* Card Content */

.apex-blog-card-content {
    flex: 1;

    padding: 20px;

    display: flex;
    flex-direction: column;
}


/* Meta */

.apex-blog-meta {
    margin-bottom: 10px;

    display: flex;

    align-items: center;
    flex-wrap: wrap;

    gap: 7px;
}

.apex-blog-date {
    color: var(--apex-text-light);

    font-size: 11px;
    font-weight: 600;
}

.apex-blog-category {
    padding: 4px 9px;

    border-radius: 20px;

    color: var(--apex-navy);

    background: var(--apex-cream);

    font-size: 10px;
    font-weight: 700;
}


/* Title */

.apex-blog-card-title {
    margin: 0 0 10px;

    font-size: 19px;
    line-height: 1.3;

    font-weight: 800;
}

.apex-blog-card-title a {
    color: var(--apex-navy);

    transition:
        color .2s ease;
}

.apex-blog-card-title a:hover {
    color: var(--apex-gold-dark);
}


/* Excerpt */

.apex-blog-excerpt {
    margin: 0 0 17px;

    color: var(--apex-text-light);

    font-size: 13px;
    line-height: 1.65;
}


/* Read More */

.apex-blog-read-more {
    width: fit-content;

    margin-top: auto;

    display: inline-flex;

    align-items: center;

    gap: 7px;

    color: var(--apex-navy);

    font-size: 12px;
    font-weight: 700;
}

.apex-blog-read-more span {
    color: var(--apex-gold);

    font-size: 16px;

    transition:
        transform .2s ease;
}

.apex-blog-read-more:hover span {
    transform:
        translateX(4px);
}


/* =========================================
   PAGINATION
========================================= */

.apex-blog-pagination {
    margin-top: 45px;

    display: flex;

    align-items: center;
    justify-content: center;

    flex-wrap: wrap;

    gap: 10px;
}

.apex-blog-pagination-numbers {
    display: flex;

    align-items: center;

    gap: 7px;
}

.apex-blog-pagination a,
.apex-blog-pagination-current {
    min-width: 38px;
    height: 38px;

    padding: 0 11px;

    display: inline-flex;

    align-items: center;
    justify-content: center;

    border:
        1px solid
        var(--apex-border);

    border-radius: 50px;

    background: #ffffff;

    color: var(--apex-navy);

    font-size: 12px;
    font-weight: 700;

    transition:
        background .2s ease,
        color .2s ease,
        border-color .2s ease;
}

.apex-blog-pagination a:hover,
.apex-blog-pagination-current {
    border-color:
        var(--apex-navy);

    background:
        var(--apex-navy);

    color:
        #ffffff;
}

.apex-blog-pagination-arrow {
    padding-left: 16px !important;
    padding-right: 16px !important;
}


/* =========================================
   NO POSTS
========================================= */

.apex-blog-no-posts {
    padding: 45px 25px;

    border:
        1px solid
        var(--apex-border);

    border-radius: 15px;

    background:
        #ffffff;

    text-align: center;
}

.apex-blog-no-posts h2 {
    margin: 0 0 10px;

    color: var(--apex-navy);

    font-size: 25px;
}

.apex-blog-no-posts p {
    margin: 0;

    color:
        var(--apex-text-light);

    font-size: 14px;
}


/* =========================================
   FINAL CTA
========================================= */

.apex-blog-cta {
    padding: 55px 0;

    background: var(--apex-navy-dark);
}

.apex-blog-cta-inner {
    display: flex;

    align-items: center;
    justify-content: space-between;

    gap: 45px;
}

.apex-blog-cta-content {
    max-width: 650px;
}

.apex-blog-cta-content > span {
    color: var(--apex-gold-light);

    font-size: 11px;
    font-weight: 700;

    letter-spacing: 1.25px;
}

.apex-blog-cta h2 {
    margin: 7px 0 9px;

    color: #ffffff;

    font-size: clamp(28px, 3vw, 38px);

    line-height: 1.15;
}

.apex-blog-cta p {
    margin: 0;

    color:
        rgba(255, 255, 255, .78);

    font-size: 14px;

    line-height: 1.7;
}

.apex-blog-cta-actions {
    display: flex;

    align-items: center;

    gap: 12px;
}

.apex-blog-cta-primary,
.apex-blog-cta-secondary {
    min-height: 43px;

    padding: 0 21px;

    display: inline-flex;

    align-items: center;
    justify-content: center;

    border-radius: 30px;

    font-size: 12px;
    font-weight: 700;

    white-space: nowrap;
}

.apex-blog-cta-primary {
    background: var(--apex-gold);

    color: #ffffff !important;
}

.apex-blog-cta-primary:hover {
    background:
        var(--apex-gold-dark);
}

.apex-blog-cta-secondary {
    border:
        1px solid
        rgba(255, 255, 255, .65);

    color:
        #ffffff !important;
}

.apex-blog-cta-secondary:hover {
    background:
        #ffffff;

    color:
        var(--apex-navy) !important;
}


/* =========================================
   TABLET
========================================= */

@media (max-width: 900px) {

    .apex-blog-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .apex-blog-hero-bg img {
        object-position: 42% 38%;
    }

    .apex-blog-cta-inner {
        flex-direction: column;

        text-align: center;
    }

}


/* =========================================
   MOBILE
========================================= */

@media (max-width: 650px) {

    .apex-blog-container {
        padding-left: 18px;
        padding-right: 18px;
    }


    .apex-blog-hero {
        min-height: 240px;
    }

    .apex-blog-hero-bg img {
        object-position: 50% 38%;
    }

    .apex-blog-hero-content {
        padding-top: 45px;
        padding-bottom: 45px;
    }

    .apex-blog-hero h1 {
        font-size: 38px;
    }


    .apex-blog-section {
        padding:
            50px 0 55px;
    }


    .apex-blog-heading {
        margin-bottom: 30px;
    }

    .apex-blog-heading h2 {
        font-size: 28px;
    }


    .apex-blog-grid {
        grid-template-columns: 1fr;
    }

    .apex-blog-image {
        height: 220px;
    }


    .apex-blog-pagination {
        margin-top: 35px;
    }

    .apex-blog-pagination-arrow {
        width: 100%;

        max-width: 150px;
    }


    .apex-blog-cta {
        padding: 48px 0;
    }

    .apex-blog-cta h2 {
        font-size: 28px;
    }

    .apex-blog-cta-actions {
        width: 100%;

        flex-direction: column;
    }

    .apex-blog-cta-primary,
    .apex-blog-cta-secondary {
        width: 100%;

        max-width: 320px;
    }

}