/*
|--------------------------------------------------------------------------
| WebMingles Frontend Blog Listing
|--------------------------------------------------------------------------
|
| Premium, responsive and reusable styles for the public blog listing page.
| All classes use the wm-blog prefix to avoid conflicts with existing CSS.
|
*/


/* ==========================================================
   Page Base
========================================================== */

.wm-blog-page {
    position: relative;
    overflow: hidden;
    color: #18212f;
    background: #ffffff;
}

.wm-blog-page *,
.wm-blog-page *::before,
.wm-blog-page *::after {
    box-sizing: border-box;
}

.wm-blog-page a {
    text-decoration: none;
}

.wm-blog-page img {
    display: block;
    max-width: 100%;
}


/* ==========================================================
   Blog Hero
========================================================== */

.wm-blog-hero {
    position: relative;
    padding: 105px 0 95px;
    overflow: hidden;
    background:
        radial-gradient(
            circle at 10% 20%,
            rgba(255, 108, 34, 0.16),
            transparent 34%
        ),
        radial-gradient(
            circle at 90% 15%,
            rgba(255, 167, 38, 0.13),
            transparent 30%
        ),
        linear-gradient(
            135deg,
            #fff8f3 0%,
            #ffffff 48%,
            #fff4ec 100%
        );
}

.wm-blog-hero::before {
    position: absolute;
    top: -130px;
    right: -90px;
    width: 330px;
    height: 330px;
    content: "";
    border: 1px solid rgba(255, 108, 34, 0.13);
    border-radius: 50%;
}

.wm-blog-hero::after {
    position: absolute;
    bottom: -150px;
    left: -100px;
    width: 310px;
    height: 310px;
    content: "";
    border: 1px solid rgba(255, 108, 34, 0.12);
    border-radius: 50%;
}

.wm-blog-hero__content {
    position: relative;
    z-index: 2;
    max-width: 850px;
    margin: 0 auto;
    text-align: center;
}

.wm-blog-hero__eyebrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 20px;
    padding: 9px 16px;
    color: #f26522;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    background: rgba(242, 101, 34, 0.09);
    border: 1px solid rgba(242, 101, 34, 0.18);
    border-radius: 999px;
}

.wm-blog-hero__eyebrow::before {
    width: 7px;
    height: 7px;
    content: "";
    background: #f26522;
    border-radius: 50%;
    box-shadow: 0 0 0 4px rgba(242, 101, 34, 0.12);
}

.wm-blog-hero__title {
    max-width: 790px;
    margin: 0 auto 22px;
    color: #152033;
    font-size: clamp(38px, 5vw, 64px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -1.8px;
}

.wm-blog-hero__description {
    max-width: 700px;
    margin: 0 auto;
    color: #667085;
    font-size: 18px;
    line-height: 1.8;
}


/* ==========================================================
   Search Form
========================================================== */

.wm-blog-search {
    display: flex;
    align-items: center;
    gap: 12px;
    max-width: 680px;
    margin: 38px auto 0;
    padding: 8px;
    background: #ffffff;
    border: 1px solid rgba(16, 24, 40, 0.08);
    border-radius: 18px;
    box-shadow:
        0 16px 45px rgba(16, 24, 40, 0.08),
        0 2px 8px rgba(16, 24, 40, 0.04);
}

.wm-blog-search__field {
    position: relative;
    flex: 1;
}

.wm-blog-search__field i {
    position: absolute;
    top: 50%;
    left: 18px;
    color: #98a2b3;
    font-size: 16px;
    transform: translateY(-50%);
    pointer-events: none;
}

.wm-blog-search__field input {
    width: 100%;
    min-height: 54px;
    padding: 13px 16px 13px 48px;
    color: #1d2939;
    font-family: inherit;
    font-size: 15px;
    line-height: 1.4;
    background: transparent;
    border: 0;
    border-radius: 12px;
    outline: none;
}

.wm-blog-search__field input::placeholder {
    color: #98a2b3;
}

.wm-blog-search__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 118px;
    min-height: 54px;
    padding: 13px 24px;
    color: #ffffff;
    font-family: inherit;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.2;
    cursor: pointer;
    background: linear-gradient(135deg, #f26522, #ff8a3d);
    border: 0;
    border-radius: 12px;
    box-shadow: 0 10px 24px rgba(242, 101, 34, 0.24);
    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease,
        background 0.25s ease;
}

.wm-blog-search__button:hover {
    color: #ffffff;
    background: linear-gradient(135deg, #dc5415, #f5752a);
    box-shadow: 0 14px 30px rgba(242, 101, 34, 0.3);
    transform: translateY(-2px);
}


/* ==========================================================
   Blog Content Section
========================================================== */

.wm-blog-content {
    position: relative;
    padding: 85px 0 100px;
    background: #ffffff;
}


/* ==========================================================
   Category Navigation
========================================================== */

.wm-blog-categories {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 42px;
    padding-bottom: 4px;
    overflow-x: auto;
    scrollbar-width: none;
}

.wm-blog-categories::-webkit-scrollbar {
    display: none;
}

.wm-blog-category {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 10px 17px;
    color: #475467;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
    background: #f8fafc;
    border: 1px solid #eaecf0;
    border-radius: 999px;
    transition:
        color 0.25s ease,
        background 0.25s ease,
        border-color 0.25s ease,
        transform 0.25s ease;
}

.wm-blog-category span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    color: #667085;
    font-size: 11px;
    font-weight: 700;
    background: #ffffff;
    border-radius: 999px;
}

.wm-blog-category:hover {
    color: #f26522;
    background: #fff8f3;
    border-color: rgba(242, 101, 34, 0.25);
    transform: translateY(-2px);
}

.wm-blog-category.is-active {
    color: #ffffff;
    background: linear-gradient(135deg, #f26522, #ff8840);
    border-color: #f26522;
    box-shadow: 0 8px 22px rgba(242, 101, 34, 0.2);
}

.wm-blog-category.is-active span {
    color: #f26522;
    background: #ffffff;
}


/* ==========================================================
   Results Bar
========================================================== */

.wm-blog-results-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 28px;
    padding: 15px 18px;
    background: #fffaf7;
    border: 1px solid rgba(242, 101, 34, 0.12);
    border-radius: 14px;
}

.wm-blog-results-bar p {
    margin: 0;
    color: #667085;
    font-size: 14px;
    line-height: 1.5;
}

.wm-blog-results-bar p strong {
    color: #1d2939;
    font-weight: 700;
}

.wm-blog-results-bar a {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #f26522;
    font-size: 14px;
    font-weight: 700;
    transition: color 0.25s ease;
}

.wm-blog-results-bar a:hover {
    color: #d85216;
}


/* ==========================================================
   Blog Grid
========================================================== */

.wm-blog-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 30px;
}


/* ==========================================================
   Blog Card
========================================================== */

.wm-blog-card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid #eaecf0;
    border-radius: 22px;
    box-shadow: 0 8px 30px rgba(16, 24, 40, 0.05);
    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease,
        border-color 0.3s ease;
}

.wm-blog-card:hover {
    border-color: rgba(242, 101, 34, 0.22);
    box-shadow: 0 22px 50px rgba(16, 24, 40, 0.11);
    transform: translateY(-8px);
}

.wm-blog-card__image-link {
    position: relative;
    display: block;
    overflow: hidden;
    background: #f2f4f7;
    aspect-ratio: 16 / 10;
}

.wm-blog-card__image-link::after {
    position: absolute;
    inset: 0;
    content: "";
    background: linear-gradient(
        180deg,
        transparent 58%,
        rgba(15, 23, 42, 0.12) 100%
    );
    pointer-events: none;
}

.wm-blog-card__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.55s ease;
}

.wm-blog-card:hover .wm-blog-card__image {
    transform: scale(1.06);
}

.wm-blog-card__body {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 26px 25px 24px;
}

.wm-blog-card__category {
    display: inline-flex;
    align-self: flex-start;
    align-items: center;
    min-height: 30px;
    margin-bottom: 15px;
    padding: 7px 12px;
    color: #f26522;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.3px;
    text-transform: uppercase;
    background: rgba(242, 101, 34, 0.09);
    border-radius: 999px;
    transition:
        color 0.25s ease,
        background 0.25s ease;
}

.wm-blog-card__category:hover {
    color: #ffffff;
    background: #f26522;
}

.wm-blog-card__title {
    margin: 0 0 14px;
    font-size: 23px;
    font-weight: 750;
    line-height: 1.35;
    letter-spacing: -0.35px;
}

.wm-blog-card__title a {
    display: -webkit-box;
    overflow: hidden;
    color: #18212f;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    transition: color 0.25s ease;
}

.wm-blog-card__title a:hover {
    color: #f26522;
}

.wm-blog-card__excerpt {
    display: -webkit-box;
    min-height: 78px;
    margin: 0 0 20px;
    overflow: hidden;
    color: #667085;
    font-size: 15px;
    line-height: 1.75;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.wm-blog-card__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 18px;
    margin-top: auto;
    padding: 16px 0;
    color: #7d8998;
    font-size: 13px;
    line-height: 1.4;
    border-top: 1px solid #f0f2f5;
    border-bottom: 1px solid #f0f2f5;
}

.wm-blog-card__meta span {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.wm-blog-card__meta i {
    color: #f26522;
    font-size: 13px;
}

.wm-blog-card__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding-top: 18px;
}

.wm-blog-card__author {
    display: block;
    min-width: 0;
    overflow: hidden;
    color: #667085;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.4;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.wm-blog-card__read-more {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 8px;
    color: #f26522;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.2;
    transition:
        color 0.25s ease,
        gap 0.25s ease;
}

.wm-blog-card__read-more i {
    font-size: 12px;
    transition: transform 0.25s ease;
}

.wm-blog-card__read-more:hover {
    gap: 11px;
    color: #d85216;
}

.wm-blog-card__read-more:hover i {
    transform: translateX(2px);
}


/* ==========================================================
   Pagination
========================================================== */

.wm-blog-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin-top: 55px;
}

.wm-blog-pagination__numbers {
    display: flex;
    align-items: center;
    gap: 8px;
}

.wm-blog-pagination__numbers a,
.wm-blog-pagination__numbers span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 42px;
    padding: 0 10px;
    color: #475467;
    font-size: 14px;
    font-weight: 700;
    line-height: 1;
    background: #ffffff;
    border: 1px solid #e4e7ec;
    border-radius: 11px;
}

.wm-blog-pagination__numbers a {
    transition:
        color 0.25s ease,
        background 0.25s ease,
        border-color 0.25s ease,
        transform 0.25s ease;
}

.wm-blog-pagination__numbers a:hover {
    color: #f26522;
    background: #fff8f3;
    border-color: rgba(242, 101, 34, 0.25);
    transform: translateY(-2px);
}

.wm-blog-pagination__numbers span.is-active {
    color: #ffffff;
    background: linear-gradient(135deg, #f26522, #ff8840);
    border-color: #f26522;
    box-shadow: 0 8px 20px rgba(242, 101, 34, 0.2);
}

.wm-blog-pagination__numbers span:not(.is-active) {
    min-width: auto;
    padding: 0 4px;
    background: transparent;
    border-color: transparent;
}

.wm-blog-pagination__arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 42px;
    padding: 10px 16px;
    color: #344054;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.2;
    background: #ffffff;
    border: 1px solid #e4e7ec;
    border-radius: 11px;
    transition:
        color 0.25s ease,
        background 0.25s ease,
        border-color 0.25s ease,
        transform 0.25s ease;
}

.wm-blog-pagination__arrow:hover {
    color: #f26522;
    background: #fff8f3;
    border-color: rgba(242, 101, 34, 0.25);
    transform: translateY(-2px);
}


/* ==========================================================
   Empty State
========================================================== */

.wm-blog-empty {
    max-width: 640px;
    margin: 0 auto;
    padding: 65px 35px;
    text-align: center;
    background: linear-gradient(180deg, #ffffff 0%, #fffaf7 100%);
    border: 1px solid #eaecf0;
    border-radius: 24px;
    box-shadow: 0 16px 40px rgba(16, 24, 40, 0.06);
}

.wm-blog-empty__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 76px;
    height: 76px;
    margin: 0 auto 24px;
    color: #f26522;
    font-size: 30px;
    background: rgba(242, 101, 34, 0.1);
    border-radius: 50%;
}

.wm-blog-empty h2 {
    margin: 0 0 12px;
    color: #18212f;
    font-size: 30px;
    font-weight: 750;
    line-height: 1.3;
}

.wm-blog-empty p {
    max-width: 470px;
    margin: 0 auto 26px;
    color: #667085;
    font-size: 15px;
    line-height: 1.75;
}


/* ==========================================================
   Tablet
========================================================== */

@media (max-width: 1199px) {

    .wm-blog-hero {
        padding: 90px 0 82px;
    }

    .wm-blog-content {
        padding: 75px 0 90px;
    }

    .wm-blog-grid {
        gap: 24px;
    }

    .wm-blog-card__body {
        padding: 23px 21px 22px;
    }

    .wm-blog-card__title {
        font-size: 21px;
    }

}

@media (max-width: 991px) {

    .wm-blog-hero {
        padding: 80px 0 72px;
    }

    .wm-blog-hero__title {
        font-size: 46px;
        letter-spacing: -1.2px;
    }

    .wm-blog-hero__description {
        font-size: 17px;
    }

    .wm-blog-content {
        padding: 68px 0 80px;
    }

    .wm-blog-categories {
        justify-content: flex-start;
        margin-right: -12px;
        margin-left: -12px;
        padding-right: 12px;
        padding-left: 12px;
    }

    .wm-blog-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

}


/* ==========================================================
   Mobile
========================================================== */

@media (max-width: 767px) {

    .wm-blog-hero {
        padding: 65px 0 58px;
    }

    .wm-blog-hero::before {
        top: -110px;
        right: -140px;
        width: 270px;
        height: 270px;
    }

    .wm-blog-hero::after {
        bottom: -130px;
        left: -150px;
        width: 260px;
        height: 260px;
    }

    .wm-blog-hero__eyebrow {
        margin-bottom: 17px;
        padding: 8px 13px;
        font-size: 11px;
        letter-spacing: 0.9px;
    }

    .wm-blog-hero__title {
        margin-bottom: 18px;
        font-size: 36px;
        line-height: 1.16;
        letter-spacing: -0.8px;
    }

    .wm-blog-hero__description {
        font-size: 15px;
        line-height: 1.75;
    }

    .wm-blog-search {
        flex-direction: column;
        gap: 9px;
        margin-top: 30px;
        padding: 8px;
        border-radius: 16px;
    }

    .wm-blog-search__field {
        width: 100%;
    }

    .wm-blog-search__field input {
        min-height: 50px;
    }

    .wm-blog-search__button {
        width: 100%;
        min-height: 50px;
    }

    .wm-blog-content {
        padding: 55px 0 68px;
    }

    .wm-blog-categories {
        margin-bottom: 30px;
    }

    .wm-blog-category {
        min-height: 40px;
        padding: 9px 14px;
        font-size: 13px;
    }

    .wm-blog-results-bar {
        align-items: flex-start;
        margin-bottom: 22px;
        padding: 14px;
    }

    .wm-blog-grid {
        grid-template-columns: 1fr;
        gap: 22px;
    }

    .wm-blog-card {
        border-radius: 19px;
    }

    .wm-blog-card__body {
        padding: 22px 20px 21px;
    }

    .wm-blog-card__title {
        font-size: 21px;
    }

    .wm-blog-card__excerpt {
        min-height: auto;
    }

    .wm-blog-pagination {
        flex-wrap: wrap;
        gap: 12px;
        margin-top: 42px;
    }

    .wm-blog-pagination__numbers {
        order: 1;
        width: 100%;
        justify-content: center;
    }

    .wm-blog-pagination__arrow {
        order: 2;
    }

    .wm-blog-empty {
        padding: 48px 22px;
        border-radius: 20px;
    }

    .wm-blog-empty h2 {
        font-size: 26px;
    }

}


/* ==========================================================
   Small Mobile
========================================================== */

@media (max-width: 479px) {

    .wm-blog-hero {
        padding: 58px 0 52px;
    }

    .wm-blog-hero__title {
        font-size: 31px;
    }

    .wm-blog-hero__description {
        font-size: 14px;
    }

    .wm-blog-results-bar {
        flex-direction: column;
        gap: 8px;
    }

    .wm-blog-card__footer {
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
    }

    .wm-blog-card__author {
        width: 100%;
    }

    .wm-blog-pagination__numbers {
        gap: 5px;
    }

    .wm-blog-pagination__numbers a,
    .wm-blog-pagination__numbers span {
        min-width: 36px;
        height: 38px;
        padding: 0 8px;
        font-size: 13px;
        border-radius: 9px;
    }

    .wm-blog-pagination__arrow {
        min-height: 40px;
        padding: 9px 13px;
        font-size: 13px;
    }

}


/* ==========================================================
   Accessibility
========================================================== */

.wm-blog-search__field input:focus-visible,
.wm-blog-search__button:focus-visible,
.wm-blog-category:focus-visible,
.wm-blog-card a:focus-visible,
.wm-blog-pagination a:focus-visible {
    outline: 3px solid rgba(242, 101, 34, 0.28);
    outline-offset: 3px;
}


/* ==========================================================
   Reduced Motion
========================================================== */

@media (prefers-reduced-motion: reduce) {

    .wm-blog-page *,
    .wm-blog-page *::before,
    .wm-blog-page *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }

}

/*
|--------------------------------------------------------------------------
| Blog Listing Spacing & Card Improvements
|--------------------------------------------------------------------------
*/


/* ==========================================================
   Hero Spacing
========================================================== */

.wm-blog-hero {
    padding-top: 78px;
    padding-bottom: 65px;
}

.wm-blog-search {
    margin-top: 28px;
}


/* ==========================================================
   Content Section Spacing
========================================================== */

.wm-blog-content {
    padding-top: 55px;
    padding-bottom: 65px;
}

.wm-blog-categories {
    margin-bottom: 28px;
}


/* ==========================================================
   Blog Grid
========================================================== */

.wm-blog-grid {
    align-items: start;
    gap: 26px;
}


/* ==========================================================
   Blog Card
========================================================== */

.wm-blog-card {
    height: auto;
    min-height: 0;
}

.wm-blog-card__image-link {
    height: 260px;
    aspect-ratio: auto;
}

.wm-blog-card__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
}

.wm-blog-card__body {
    min-height: 265px;
    padding: 22px 21px 20px;
}

.wm-blog-card__category {
    margin-bottom: 12px;
}

.wm-blog-card__title {
    margin-bottom: 9px;
    font-size: 21px;
    line-height: 1.3;
}

.wm-blog-card__excerpt {
    min-height: 48px;
    margin-bottom: 15px;
    line-height: 1.6;
    -webkit-line-clamp: 2;
}

.wm-blog-card__meta {
    margin-top: auto;
    padding: 13px 0;
}

.wm-blog-card__footer {
    padding-top: 14px;
}


/* ==========================================================
   Last Row & Pagination
========================================================== */

.wm-blog-pagination {
    margin-top: 38px;
}


/* ==========================================================
   Desktop Adjustments
========================================================== */

@media (min-width: 1200px) {

    .wm-blog-content .container {
        max-width: 1140px;
    }

    .wm-blog-card__image-link {
        height: 270px;
    }

}


/* ==========================================================
   Tablet
========================================================== */

@media (max-width: 991px) {

    .wm-blog-hero {
        padding-top: 68px;
        padding-bottom: 58px;
    }

    .wm-blog-content {
        padding-top: 45px;
        padding-bottom: 58px;
    }

    .wm-blog-card__image-link {
        height: 245px;
    }

    .wm-blog-card__body {
        min-height: 250px;
    }

}


/* ==========================================================
   Mobile
========================================================== */

@media (max-width: 767px) {

    .wm-blog-hero {
        padding-top: 52px;
        padding-bottom: 48px;
    }

    .wm-blog-search {
        margin-top: 24px;
    }

    .wm-blog-content {
        padding-top: 38px;
        padding-bottom: 50px;
    }

    .wm-blog-categories {
        margin-bottom: 22px;
    }

    .wm-blog-grid {
        gap: 20px;
    }

    .wm-blog-card__image-link {
        height: 280px;
    }

    .wm-blog-card__body {
        min-height: 0;
        padding: 20px 18px 18px;
    }

    .wm-blog-card__excerpt {
        min-height: 0;
    }

}


/* ==========================================================
   Small Mobile
========================================================== */

@media (max-width: 479px) {

    .wm-blog-card__image-link {
        height: 240px;
    }

}