/* WP-specific overrides — restore flex shrinking the legacy CSS relied on */
body.article-page .content-whole .article-content .article-section > .container,
body.article-page .content-whole .article-content .article-section > .container.p-0,
.category-content .category-section > .container,
.category-content .category-section > .container.p-0,
.social-aggregator-content .social-aggregator-section > .container,
.social-aggregator-content .social-aggregator-section > .container.p-0 {
    min-width: 0 !important;
}

/* Responsive 16:9 wrapper for embedded videos in article body
   (YouTube + Facebook embeds injected by the legacy importer) */
body.article-page .kh-video-embed {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    margin: 0 0 1.5rem;
    background: #000;
}
body.article-page .kh-video-embed iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* Category-page tabs — restore the original underline style.
   Bootstrap nav-tabs default adds bordered/rounded active state we don't want. */
.category-content .filter .swiper.nav-tabs {
    border-bottom: none;
}
.category-content .filter .swiper-wrapper {
    display: flex;
    gap: 4rem;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    padding-bottom: .4rem;
    border-bottom: 1px solid #e5e5e5;
}
.category-content .filter .swiper-wrapper::-webkit-scrollbar { display: none; }
.category-content .filter .swiper-slide {
    flex: 0 0 auto;
    width: auto !important;
}
.category-content .filter .nav-link {
    background: transparent !important;
    border: 0 !important;
    border-bottom: 3px solid transparent !important;
    border-radius: 0 !important;
    color: #000 !important;
    font-size: 1.6rem;
    font-weight: 500;
    padding: 0 0 .8rem !important;
    transition: none;
}
.category-content .filter .nav-link:hover {
    border-bottom-color: #aeff00 !important;
}
.category-content .filter .nav-link.active {
    color: #000 !important;
    font-weight: 700;
    border-bottom-color: #aeff00 !important;
}

/* Highlight section: video slide — use plain iframe (legacy theme expected lite-youtube web component). */
.highlightSection .sectionContent .swiper .swiper-slide.highlightVideo .video {
    flex: none;
    width: 550px; height: 100%;
    overflow: hidden;
    border-top-left-radius: 1rem;
    border-bottom-left-radius: 1rem;
    background: #000;
    position: relative;
}
.highlightSection .sectionContent .swiper .swiper-slide.highlightVideo .video iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

/* Highlight section: 2-slide layout (composite first slide + text card second slide)
   First slide contains the 3 columns visible together; second slide is the title/desc card. */

.highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage {
    width: 100% !important;
    margin-right: 0 !important;
}
.highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .highlightFirstPageInner {
    gap: 20px;
    width: 100%;
}
.highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .surveyCol {
    flex: 0 0 auto;
    width: 240px;
}

/* No title truncation in the Highlight composite slide. */
.highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .surveyCol .surveyItem .surveyContent p,
.highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .brandChallengeCol .brandTitle {
    display: block;
    -webkit-line-clamp: unset;
    -webkit-box-orient: initial;
    overflow: visible;
    text-overflow: clip;
}
.highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .brandChallengeCol {
    flex: 0 0 auto;
    width: 370px;
}
.highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .highlightVideo {
    flex: 0 0 auto;
    width: 400px;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.mainContent .section.highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .highlightVideo .videoMeta {
    padding: 0 4px;
}
.mainContent .section.highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .highlightVideo .videoMeta h5 {
    font-size: 1.6rem;
    font-weight: 600;
    line-height: 22px;
    margin: 0;
    color: #111827;
}
.mainContent .section.highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .highlightVideo .videoMeta p {
    color: #808190;
    font-size: 1.3rem;
    line-height: 20px;
    margin: 6px 0 0 0;
}
.mainContent .section.highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .highlightVideo .video {
    width: 100%;
    flex: none;
    aspect-ratio: 16 / 9;
    border-radius: 1rem;
    overflow: hidden;
    background: #000;
}
.mainContent .section.highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .highlightVideo .video iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}


@media (max-width: 991.98px) {
    .highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .surveyCol { width: 220px; }
    .highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .brandChallengeCol { width: 340px; }
}
@media (max-width: 767.98px) {
    .highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .highlightFirstPageInner {
        flex-direction: column;
    }
    .highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .surveyCol,
    .highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .brandChallengeCol,
    .highlightSection .sectionContent .swiper .swiper-slide.highlightFirstPage .highlightVideo {
        width: 100%;
    }
}

/* HALALtuju list section (new, below Review) — mirrors review section margins */
.halalTujuListSection {
    margin-block: 6rem;
}
.halalTujuListSection .sectionHeading {
    margin-inline: 7.1% 7.889%;
}
.halalTujuListSection .sectionHeading .sectionTitle {
    gap: 1.34rem;
}
.halalTujuListSection .sectionHeading .sectionTitle img {
    width: 41.27px;
}
.halalTujuListSection .sectionContent {
    margin-inline: 7.1% 7.889%;
    margin-top: 1.5rem;
}
.halalTujuListSection .sectionContent .reviewItem {
    background: #fff;
    border-radius: 1rem;
    position: relative;
}
.halalTujuListSection .sectionContent .reviewItem .reviewImg {
    background: #fff;
    border-radius: 1rem;
    box-shadow: 0 4px 15px 0 rgba(0,0,0,.1);
    cursor: pointer;
    padding: 5px;
}
.halalTujuListSection .sectionContent .reviewItem .reviewImg div {
    border-radius: 1rem;
    overflow: hidden;
}
.halalTujuListSection .sectionContent .reviewItem .reviewImg img {
    aspect-ratio: 3.1 / 2;
    border-radius: .5rem;
    object-fit: cover;
    transition: transform .5s ease;
    width: 100%;
}
.halalTujuListSection .sectionContent .reviewItem .reviewImg img:hover {
    transform: scale(1.1);
}
.halalTujuListSection .sectionContent .reviewItem .reviewContent {
    padding-block: 2rem 0;
    padding-inline: 20px;
}
.halalTujuListSection .sectionContent .reviewItem .reviewContent .date {
    color: #808190;
    font-size: 12px;
    font-weight: 500;
    line-height: 24px;
}
.halalTujuListSection .sectionContent .reviewItem .reviewContent .reviewDesc {
    color: #000;
    display: -webkit-box;
    font-size: 16px;
    font-weight: 500;
    line-height: 24px;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: normal;
    word-break: break-word;
    -webkit-line-clamp: 3;
    cursor: pointer;
    margin-block: .5rem 0;
}
@media (max-width: 991.98px) {
    .halalTujuListSection .sectionContent {
        margin-inline: 0;
    }
    .halalTujuListSection .sectionContent .swiper {
        padding-inline: 2rem;
    }
}

/* Newsletter card embedded inside HALALtuju left panel (beside green box) */
.halalTujuSection .sectionContent .HALALtujuContainer.halalTujuLeftPanel {
    display: flex;
    align-items: center;
}
.halalTujuSection .inlineNewsletter {
    width: 100%;
}
.halalTujuSection .inlineNewsletter .newsletterCard {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 1.5rem;
    padding: 3.2rem 3.2rem 2.9rem;
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 2.4rem;
    overflow: hidden;
}
.halalTujuSection .inlineNewsletter .newsletterCard::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -1px;
    width: 220px;
    height: 139px;
    background-image: url('../img/newsletter/letter-bg.vut9WBOM.png');
    background-repeat: no-repeat;
    background-size: 101%;
    opacity: .35;
    pointer-events: none;
}
.halalTujuSection .inlineNewsletter .title {
    gap: 1.78rem !important;
}
.halalTujuSection .inlineNewsletter .title-icon {
    background-color: #4b28b8;
    flex: none;
    height: 7.4rem;
    width: 7.4rem;
}
.halalTujuSection .inlineNewsletter .title-icon img {
    height: 36.83px;
    width: 46.38px;
}
.halalTujuSection .inlineNewsletter .title-heading h5 {
    font-size: 2.4rem;
    line-height: 3rem;
}
.halalTujuSection .inlineNewsletter .title-heading p {
    font-size: 1.4rem;
    line-height: 2rem;
    word-break: break-word;
    color: #555;
}
.halalTujuSection .inlineNewsletter .newsletterForm {
    width: 100%;
}
.halalTujuSection .inlineNewsletter .subscribe-email .input-group {
    display: flex;
    gap: 0;
    width: 100%;
}
.halalTujuSection .inlineNewsletter .subscribe-email input {
    border: 1px solid #ced0d3;
    border-radius: 1rem 0 0 1rem;
    padding: 1.2rem 2rem;
    font-size: 1.4rem;
    flex: 1 1 auto;
    min-width: 0;
}
.halalTujuSection .inlineNewsletter .subscribe-email input::placeholder {
    color: #000;
    font-weight: 300;
}
.halalTujuSection .inlineNewsletter .subscribe-email .btn-join-now {
    background-color: #4b28b8;
    border-radius: 0 1rem 1rem 0;
    font-size: 1.4rem;
    line-height: 2.1rem;
    padding: 1.2rem 2.5rem;
    flex: 0 0 auto;
}

@media (max-width: 991.98px) {
    .halalTujuSection .inlineNewsletter .newsletterCard {
        padding: 2.4rem;
    }
    .halalTujuSection .inlineNewsletter .title-icon {
        height: 6rem;
        width: 6rem;
    }
}

/* Trim green box height to roughly match the newsletter card height */
.mainContent .section.halalTujuSection .sectionContent .featuredVideo {
    padding: 0 30px 24px !important;
}
.mainContent .section.halalTujuSection .sectionContent .featuredVideo .thumbnailImage {
    margin-top: -30px;
}
.mainContent .section.halalTujuSection .sectionContent .featuredVideo .featuredVideoContent {
    margin-top: 1.4rem;
    margin-right: 0;
    max-height: none;
    min-height: 0;
    padding-inline: .5rem;
}
.mainContent .section.halalTujuSection .sectionContent .featuredVideo .featuredVideoContent p {
    font-size: 1.5rem;
    line-height: 2rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Widen the Brand Collaboration nav item so the label fits on two lines */
.homeHeader nav > div .header-action .browse .browseSection > a.social {
    width: 132px;
}
.innerHeader nav > div .header-action .browse .browseSection > a.social {
    width: 132px;
}

/* Mobile sidebar (offcanvas) backdrop + scroll lock */
.kh-sidebar-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1040;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease-in-out;
}
.kh-sidebar-backdrop.show {
    opacity: 1;
    visibility: visible;
}
body.kh-no-scroll {
    overflow: hidden;
}

/* Sidebar visual polish — match original look */
.sidebar-offcanvas-mb .sidebar-box .divider {
    border-top: 1px solid #e5e5e5;
    margin: 1.6rem 0;
}
.sidebar-offcanvas-mb .sidebar-box .sidebar-menu-item.home {
    background: #4b28b8;
}
.sidebar-offcanvas-mb .sidebar-box .sidebar-menu-item.home p {
    color: #fff;
    font-size: 1.4rem;
    font-weight: 600;
    margin: 0 0 0 12px;
}
.sidebar-offcanvas-mb .sidebar-box .sidebar-menu-item.home .sidebar-menu-item-box img {
    width: 20px;
    filter: brightness(0) invert(1);
}
.sidebar-offcanvas-mb .sidebar-box .social-share .social-share-item {
    margin-bottom: 1.2rem;
}
.sidebar-offcanvas-mb .sidebar-box .social-share .social-share-item p {
    font-size: 1.4rem;
    font-weight: 500;
    margin: 0 0 0 8px;
}
.sidebar-offcanvas-mb .sidebar-box .social-share .share-white-img {
    width: 13px;
}
.sidebar-offcanvas-mb .sidebar-box .social-share .social-share-box {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 8px;
}
.sidebar-offcanvas-mb .sidebar-box .social-share .social-share-box button {
    background: transparent;
    border: 0;
    padding: 0;
}
.sidebar-offcanvas-mb .sidebar-box .social-share .social-icon {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.sidebar-offcanvas-mb .sidebar-box .social-share .social-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}
.sidebar-offcanvas-mb .sidebar-box .social-share .social-icon.copy {
    background: #f1f1f1;
    border-radius: 500px;
}
.sidebar-offcanvas-mb .sidebar-box .social-share .social-icon.copy img {
    width: 18px;
    height: 18px;
}

/* Frosted glass sidebar — keep the page visible behind so user stays in context */
.sidebar-offcanvas-mb .offcanvas-body .sidebar-box {
    background: rgba(255, 255, 255, 0.65);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
    backdrop-filter: blur(18px) saturate(140%);
    border-right: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 8px 32px rgba(31, 38, 135, 0.12);
}
.kh-sidebar-backdrop {
    background: rgba(0, 0, 0, 0.15);
}

/* Sidebar top row: close on left, logo on right */
.sidebar-offcanvas-mb .sidebar-box .sidebar-top {
    margin: -2rem -2rem 2rem;
    padding: 1.2rem 2rem;
    gap: 1rem;
    background: rgba(0, 0, 0, 0.85);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
    backdrop-filter: blur(18px) saturate(140%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.sidebar-offcanvas-mb .sidebar-box .sidebar-close-btn {
    background: transparent;
    border: 0;
    padding: 0;
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.sidebar-offcanvas-mb .sidebar-box .sidebar-close-btn {
    color: #fff;
}
.sidebar-offcanvas-mb .sidebar-box .sidebar-close-btn svg {
    width: 30px;
    height: 30px;
}
.sidebar-offcanvas-mb .sidebar-box .sidebar-logo {
    display: inline-flex;
    align-items: center;
}
.sidebar-offcanvas-mb .sidebar-box .sidebar-logo img {
    height: 48px;
    width: auto;
}
