/* ==========================
           MAGAZINE PAGE FINAL CSS
          ========================== */

/* Section BG */
.magazine-section {
    background: #f6f6f6;
}

.magazine-img {
    width: 95%;
    height: 593px;
    object-fit: cover;
}



/* Default (Desktop + Large Screens) */
.column-watermark {

    font-size: clamp(73px, 14vw, 125px);
    font-weight: 900;
    color: rgba(0, 0, 0, 0.05);
    pointer-events: none;
    user-select: none;
    opacity: 0.3;
    white-space: nowrap;
    z-index: 0;
    line-height: 1;
    overflow: hidden;
}




/* Tablets (768px - 1024px) */
@media (min-width: 1024px) and (max-width: 1180px) {
    .column-watermark {

        font-size: 64px;

    }
}

@media (max-width: 1024px) {
    .column-watermark {
        font-size: 64px;
    }
}

/* Mobile Large (576px - 768px) */
@media (max-width: 768px) {

    .magazine-img {
        height: 400px;
    }

    .column-watermark {
        font-size: 60px;
    }
}

/* Mobile Small (Below 576px) */
@media (max-width: 576px) {
    .column-watermark {
        font-size: 60px;
    }
}




/* Header Banner */
.magazine-header-banner {
    position: relative;
    padding: 60px 0;
    overflow: hidden;
    z-index: 5;
    text-align: left;
    width: 100%;
    padding-left: 15px;
}

@media (max-width: 768px) {
    .magazine-header-banner {
        padding-left: 5px;
    }

}

@media (max-width: 768px) {
    .magazine-header-banner {
        padding: 10px 0;
    }

}

.magazine-header-banner .title {
    font-size: 4rem;
    margin: 0;
    position: relative;
    z-index: 2;
}

.magazine-header-banner .date-subtitle {
    color: #777777;
    margin-top: 5px;
    font-size: 20px;
}

/* Edition label */
.mag-edition-title {
    border-top: 1px solid #777777;
    border-bottom: 1px solid #777777;
    padding: 10px 0px;
}


.mag-edition-label {
    padding: 10px 0px;
    border-radius: 4px;
    font-weight: 700;
}

@media (max-width: 768px) {
    .magazine-header-banner {
        padding: 5px 10px;
    }

    .magazine-header-banner .title {
        font-size: 3rem;
    }

    .magazine-header-banner .date-subtitle {

        margin-top: 0px;
        font-size: 15px;
    }

    .mv-gap {
        row-gap: 0 !important;
    }

}

/* Card wrapper */
.magazine-grid-container {
    display: grid;
    /* Defines 4 columns, each taking an equal fraction of the space (fr) */
    grid-template-columns: repeat(3, 1fr);
    /* Sets the gap between items */
    gap: 0rem;
}

@media (min-width: 1024px) and (max-width: 1180px) {
    .magazine-grid-container {
        display: grid;
        /* Defines 4 columns, each taking an equal fraction of the space (fr) */
        grid-template-columns: repeat(2, 1fr);
        /* Sets the gap between items */
        gap: 0rem;
    }
}

/* Optional: Add responsiveness with a media query */
@media (min-width: 769px) and (max-width: 1023px) {
    .magazine-grid-container {
        /* On small screens, switch to 2 items per row */
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

}

@media (max-width: 768px) {

    .magazine-grid-container {
        /* On small screens, switch to 2 items per row */
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }



}

.magazine-grid-item {
    width: 80%;
}


/* 1. Ensure the wrapper matches the image width EXACTLY */
.magazine-card-wrapper {
    display: inline-flex !important;
    flex-direction: column;
    width: fit-content !important;
    /* Shrinks the box to exactly 190px */
    text-align: left !important;
    padding: 0;
}

.mag-image-group>a:first-of-type {
    margin-top: 0.7rem !important;
    margin-bottom: 0.7rem !important;
    display: inline-block;
    /* ensures margin works */
}

/* 2. The images define the container width */
.mag-image-group {
    display: flex;
    flex-direction: column;
    width: 100%;
}

/* .magazine-card-wrapper>a:first-of-type {
    margin-top: 0.7rem !important;
    margin-bottom: 0.5rem !important;

} */


.magazine-card {
    margin: 0 !important;
}

/* Thumbnail */
.mag-thumb {
    width: 110px;
    height: auto;
    border-radius: 6px;
    border: 1px solid #ccc;
}

/* Main Cover Image */
.mag-cover-img {
    width: 190px;
    height: auto;
    display: block;
    margin: 0 !important;
}

/* FIX SPACING BETWEEN PILLS */
.mag-pill-row {
    display: flex !important;
    flex-direction: row !important;
    /* This pushes 'PROFILES' to the left and 'REGION' to the right */
    justify-content: space-between !important;
    align-items: center;
    width: 100% !important;
    /* Forces row to span the full 190px */
    margin-top: 0.7rem;
    gap: 0 !important;
    /* Space-between handles the spacing */
    font-family: 'CoreSanaC65Bold', Arial, sans-serif !important;
}

/* 4. PRESERVE YOUR BUTTON STYLES - DO NOT CHANGE PADDING/FONT */
.pill-profiles,
.pill-type-issue {
    /* Ensure they don't grow to fill space */
    width: auto;
    /* Keeps them inline for the gap property to work */
    display: inline-flex;
    align-items: center;
    /* justify-content: center; */
    padding: 6px 14px 4px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: bold;
    /* white-space: nowrap; */
    text-decoration: none;
}

/* PROFILES Pill */
.pill-profiles {
    background: #F7B926;
    color: #000;
}

/* USA / ASIA Pill */
/* USA / ASIA Pill */
.pill-type-issue {
    background: #f3f3f3;
    color: #333;
}

/* Tablet */
@media (max-width: 992px) {
    .mag-cover-img {
        max-width: 180px;
    }
}

/* Mobile */
@media (max-width: 576px) {
    .mag-cover-img {
        max-width: 160px;
    }

    .mag-pill-row {
        flex-direction: row;
        gap: 0rem;
        text-align: center;
    }

    .pill-profiles,
    .pill-type-issue {
        width: 100%;
        text-align: center;
        display: block;
    }
}

.small,
.small>a {
    color: #777777;
    font-family: 'CoreSanaC65Bold', Arial, sans-serif !important;
}

.line-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    /* show only 2 lines */
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.taghead-re>a {
    font-family: 'CoreSanaC65Bold', Arial, sans-serif;
}

.post-date,
.post-author {
    font-size: 0.7rem;
    font-family: 'CoreSanaC65Bold', Arial, sans-serif;
}

.img-fluid-cat-m {
    max-width: 100%;
    height: 155px;
    object-fit: cover;
}

@media (max-width: 768px) {
    .img-fluid-cat-m {
        height: auto;
    }

}

/* Right Sidebar */
.sticky-fix {
    align-self: flex-start !important;
}

.right-text {
    flex: 1;
}

.right-thumb img.post-img {
    width: 150px;
    height: 165px;
    object-fit: cover;
}

.right-excerpt {
    line-height: 1.2rem;
    color: #777777;
    font-family: 'CoreSanaC65Bold', Arial, sans-serif !important;
    font-size: 0.8rem;
}

.right-post {
    gap: 12px;
}

/* FORCE ALL MAGAZINE CARDS TO ALIGN LEFT — FINAL FIX */
.magazine-group-wrapper .row {
    display: flex !important;
    justify-content: flex-start !important;
    align-items: flex-start !important;
}

/* Apply border-right only to column */
.spot-card-col {
    border-right: 1px solid #dcdcdc;
    padding-right: 20px;
    /* spacing from border */
}

/* Remove border on every 4th card (last in row) */
.spot-card-col:nth-child(4n) {
    border-right: none;
}

/* Mobile/tablet: remove all vertical borders */
@media (max-width: 991px) {
    .spot-card-col {
        border-right: none;
    }
}



/* REMOVE ALL AUTO-CENTERING ON IMAGES */
/* Remove auto-centering images */

.mag-link {
    display: inline-block !important;
    width: auto !important;
    height: auto !important;
}


.mag-thumb {
    margin: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    display: block !important;
}

/* CARD WRAPPER MUST NOT CENTER */
.magazine-card-wrapper {
    text-align: left !important;
}

/* Apply margin-top only to cards that appear in row 2 and below */
.col-mag:nth-child(n + 4) .magazine-card-wrapper {
    margin-top: 0.7rem !important;
}

/* DELETE center alignment from Bootstrap column overrides */
.col-md-4,
.col-6 {
    text-align: left !important;
}