html,
body {
    width: 100vw;
    max-width: 100vw;
    overflow-x: hidden;
    margin: 0;
    padding: 0
}

body {
    min-height: 100vh;
    background-color: var(--lphs-accent-1);
    background-image:
        radial-gradient(ellipse 90% 60% at 0% 0%, rgba(var(--lphs-primary-rgb), 0.14) 0%, transparent 58%),
        radial-gradient(ellipse 80% 55% at 100% 8%, rgba(var(--lphs-secondary-rgb), 0.12) 0%, transparent 55%),
        radial-gradient(ellipse 70% 50% at 50% 100%, rgba(var(--lphs-primary-rgb), 0.10) 0%, transparent 60%),
        repeating-linear-gradient(60deg, rgba(var(--lphs-primary-rgb), 0.04) 0 1px, transparent 1px 20px),
        repeating-linear-gradient(-60deg, rgba(var(--lphs-accent-2-rgb), 0.04) 0 1px, transparent 1px 20px),
        repeating-linear-gradient(0deg, rgba(var(--lphs-primary-rgb), 0.03) 0 1px, transparent 1px 20px);
    background-attachment: fixed;
}

:root {
    /* Nota Tema LPHS — rujuk tema.md
     * Primary   Teal Gelap   #14505B
     * Secondary Gold         #C2922F
     * Accent 1  Krim/Lembut  #F3E8D0
     * Accent 2  Slate Grey   #5E6B73
     */
    --lphs-primary: #14505B;
    --lphs-primary-dark: #0e3a44;
    --lphs-primary-rgb: 20, 80, 91;
    --lphs-secondary: #C2922F;
    --lphs-secondary-rgb: 194, 146, 47;
    --lphs-accent-1: #F3E8D0;
    --lphs-accent-1-rgb: 243, 232, 208;
    --lphs-accent-2: #5E6B73;
    --lphs-accent-2-rgb: 94, 107, 115;

    --portal-header-height: 96px;
    --slide-carousel-height: 560px;
    --slide-carousel-height-with-services: 780px;
    --slide-navbar-clearance: 88px;
    --slide-services-clearance: 300px;
    --services-overlay-bottom: 24px;
}

/* Header portal rasmi */
.portal-top-header {
    background: #fff;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    position: relative;
    z-index: 10000;
}

.portal-top-header-logo {
    height: 68px;
    width: auto;
    max-width: 210px;
    object-fit: contain;
}

.portal-top-header-inner {
    min-height: var(--portal-header-height);
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: center;
    gap: .75rem;
    max-width: 1400px;
    margin: 0 auto;
}

.portal-top-header-brand {
    grid-column: 1;
    justify-self: start;
}

.portal-top-header-title {
    grid-column: 2;
    justify-self: center;
    text-align: center;
    color: var(--lphs-primary);
    font-family: 'Montserrat', Arial, sans-serif;
    line-height: 1.25;
    padding: 0 .25rem;
    width: max-content;
    max-width: min(560px, 46vw);
}

.portal-top-header-title-top,
.portal-top-header-title-main {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: .35px;
}

/* SPLASK SEO: brand H1 on homepage keeps header styling */
h1.portal-top-header-title-main {
    margin: 0;
    line-height: inherit;
}


.portal-top-header-tools {
    grid-column: 3;
    justify-self: end;
    display: flex;
    align-items: stretch;
    flex-shrink: 0;
}

.portal-top-header-tool {
    display: flex;
    align-items: center;
}

.portal-top-header-tool+.portal-top-header-tool {
    border-left: 1px solid #d9dee3;
    margin-left: .2rem;
    padding-left: .2rem;
}

.portal-top-header-tool-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #333;
    min-width: 52px;
    padding: .15rem .2rem;
    gap: .12rem;
}

.portal-top-header-tool-link:hover {
    color: var(--lphs-primary);
}

.portal-top-header-tool-static {
    cursor: default;
}

.portal-top-header-tool-icon {
    height: 22px;
    width: auto;
    max-width: 28px;
    object-fit: contain;
}

.portal-top-header-tool-label {
    font-size: .74rem;
    line-height: 1.15;
    text-align: center;
    max-width: 78px;
}

@media (max-width: 1199.98px) {
    :root {
        --portal-header-height: 74px;
    }

    .portal-top-header-logo {
        height: 56px;
        max-width: 170px;
    }

    .portal-top-header-title-top,
    .portal-top-header-title-main {
        font-size: .9rem;
    }

    .portal-top-header-title {
        max-width: min(480px, 42vw);
    }

    .portal-top-header-tool-link {
        min-width: 46px;
        padding: .12rem .15rem;
    }

    .portal-top-header-tool-icon {
        height: 20px;
        max-width: 24px;
    }

    .portal-top-header-tool-label {
        font-size: .68rem;
        max-width: 70px;
    }
}

@media (max-width: 991.98px) {
    :root {
        --portal-header-height: auto;
    }

    .portal-top-header-inner {
        grid-template-columns: 1fr;
        justify-items: center;
        padding-top: .55rem;
        padding-bottom: .55rem;
        gap: .45rem;
    }

    .portal-top-header-brand,
    .portal-top-header-title,
    .portal-top-header-tools {
        grid-column: 1;
        justify-self: center;
    }

    .portal-top-header-brand {
        order: 1;
    }

    .portal-top-header-title {
        order: 2;
        max-width: 100%;
        padding-top: 0;
    }

    .portal-top-header-tools {
        order: 3;
        justify-self: center;
        overflow-x: auto;
        max-width: 100%;
        -webkit-overflow-scrolling: touch;
    }

    .portal-top-header-logo {
        height: 50px;
    }
}

@media (max-width: 575.98px) {
    .portal-top-header-title-top,
    .portal-top-header-title-main {
        font-size: .8rem;
    }

    .portal-top-header-tool-link {
        min-width: 42px;
    }
}

@media (min-width: 768px) and (max-width: 991.98px) {
    .menu-wrapper {
        top: 128px;
    }

    .menu-wrapper.sticky {
        top: 0;
    }
}

@media (max-width: 767.98px) {
    :root {
        --portal-header-height: 102px;
        --slide-navbar-clearance: 12px;
        --slide-services-clearance: 0;
    }

    .portal-top-header-tools {
        display: none !important;
    }

    .portal-top-header-inner {
        position: relative;
        padding-bottom: .35rem;
        gap: .3rem;
        padding-right: 3rem;
    }

    .portal-mobile-nav-toggle {
        position: absolute;
        top: 50%;
        right: .75rem;
        transform: translateY(-50%);
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 42px;
        height: 42px;
        padding: 0;
        border: 1px solid rgba(var(--lphs-primary-rgb), 0.22);
        border-radius: .65rem;
        background: #fff;
        color: var(--lphs-primary);
        box-shadow: 0 2px 8px rgba(var(--lphs-primary-rgb), 0.12);
        z-index: 2;
    }

    .portal-mobile-nav-toggle:focus-visible {
        outline: 2px solid var(--lphs-secondary);
        outline-offset: 2px;
    }

    .portal-mobile-nav-icon,
    .portal-mobile-nav-icon::before,
    .portal-mobile-nav-icon::after {
        display: block;
        width: 18px;
        height: 2px;
        border-radius: 1px;
        background: currentColor;
        position: relative;
    }

    .portal-mobile-nav-icon::before,
    .portal-mobile-nav-icon::after {
        content: "";
        position: absolute;
        left: 0;
    }

    .portal-mobile-nav-icon::before {
        top: -6px;
    }

    .portal-mobile-nav-icon::after {
        top: 6px;
    }

    /* Mobile: tiada pill nav — carousel penuh di bawah header */
    section.navbarUtama {
        position: static;
        height: 0;
        overflow: visible;
        margin: 0;
        padding: 0;
    }

    .menu-wrapper:not(.sticky) {
        position: fixed;
        top: var(--portal-header-height, 102px);
        left: 0;
        right: 0;
        width: 100%;
        max-width: 100%;
        transform: none;
        margin: 0;
        padding: 0;
        z-index: 10001;
        pointer-events: none;
    }

    .menu-wrapper:not(.sticky) .custom-navbar {
        background: transparent;
        border: none;
        box-shadow: none;
        padding: 0;
        max-width: 100%;
        pointer-events: none;
    }

    .menu-wrapper:not(.sticky) .navbar-brand,
    .menu-wrapper:not(.sticky) .portal-sticky-nav-toggle {
        display: none !important;
    }

    .menu-wrapper:not(.sticky) .navbar-collapse.show,
    .menu-wrapper:not(.sticky) .navbar-collapse.collapsing {
        pointer-events: auto;
        position: fixed;
        top: var(--portal-header-height, 102px);
        left: 0;
        right: 0;
        margin: 0;
        max-height: calc(100vh - var(--portal-header-height, 102px));
        overflow-y: auto;
        z-index: 10002;
    }

    .menu-wrapper.sticky {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        transform: none;
        width: 100%;
        max-width: 100%;
        margin: 0;
        padding: 0;
        z-index: 10001;
        pointer-events: auto;
    }

    .menu-wrapper.sticky .navbar-brand {
        display: none !important;
    }

    .menu-wrapper.sticky .portal-sticky-nav-toggle {
        display: inline-flex !important;
        margin-left: auto;
    }

    section#slideUtama {
        margin-top: 0;
    }

    .slide-utama-carousel-item,
    section#slideUtama.has-services-overlay .slide-utama-carousel-item {
        background-position: center 40%;
    }

    section#slideUtama > #slideUtamaCarousel {
        height: 255px;
    }
}



.slideUtama-item {
    background-size: cover;
    background-position: center;
    position: relative
}

.hero-overlay {
    height: 100%;
    width: 100%;
    position: relative;
    color: #fff;
    text-align: left
}

.hero-overlay>div {
    position: absolute;
    top: calc(var(--slide-navbar-clearance) + 20px);
    left: 0;
    right: 0;
    padding-left: 15px;
    padding-right: 15px;
    max-width: 1200px;
    margin: 0 auto
}

@media(max-width:1366px) {
    .hero-overlay>div {
        top: calc(var(--slide-navbar-clearance) + 12px);
        max-width: 1140px
    }
}

@media(max-width:991.98px) {
    .hero-overlay {
        padding: 0
    }

    .hero-overlay>div {
        top: calc(var(--slide-navbar-clearance) + 8px);
        padding-left: 15px;
        padding-right: 15px;
        max-width: 100%
    }
}

@media (min-width: 768px) {
    .menu-wrapper {
        position: absolute;
        top: calc(var(--portal-header-height, 86px) + 12px);
        left: 50%;
        transform: translateX(-50%);
        width: 80%;
        z-index: 9999;
        transition: .3s
    }

    .menu-wrapper.sticky {
        position: fixed;
        top: 0;
        left: 50%;
        transform: translateX(-50%);
        width: 100vw;
        background: transparent;
        box-shadow: none;
        padding: 0;
        z-index: 10001;
    }

    .menu-wrapper.sticky .custom-navbar {
        max-width: 100vw;
        background: var(--lphs-primary);
        height: 60px;
        justify-content: space-between;
        padding: 0 5px;
        display: flex;
        align-items: center;
        border-radius: 0 !important;
        transition: border-radius 0.22s, top 0.22s;
    }
}

.custom-navbar {
    margin: 0 auto;
    border-radius: 2rem;
    background: #fff;
    border: 1px solid rgba(var(--lphs-primary-rgb), 0.14);
    box-shadow: 0 4px 18px rgba(var(--lphs-primary-rgb), 0.12);
    padding: .5rem 1rem;
    max-width: 1200px;
    transition: .3s
}

/* Panel menu collapse (mobile) — background sama dengan navbar */
@media (max-width: 767.98px) {

    .custom-navbar .navbar-collapse.show,
    .custom-navbar .navbar-collapse.collapsing {
        background: #fff;
        border-radius: 0 0 1rem 1rem;
        padding: .5rem .75rem;
        margin: 0 -.5rem -.25rem -.5rem;
        max-height: 70vh;
        overflow-y: auto;
    }

    .menu-wrapper.sticky .custom-navbar .navbar-collapse.show,
    .menu-wrapper.sticky .custom-navbar .navbar-collapse.collapsing {
        background: var(--lphs-primary);
        border-radius: 0 0 1.5rem 1.5rem;
    }

    /* Teks nav-link dalam collapse sticky jadi putih */
    .menu-wrapper.sticky .custom-navbar .navbar-collapse .nav-link {
        color: #fff !important;
    }
}

@media(max-width:1366px) {
    .custom-navbar {
        max-width: 1140px;
        padding: .4rem .8rem
    }
}

/* Desktop: dropdown li perlu position:relative supaya menu boleh centre */
@media (min-width: 768px) {
    .navbar-nav .dropdown.position-static {
        position: relative
    }
}

.dropdown-menu {
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 1rem;
    margin-top: 8px;
    padding: 1rem;
    display: none;
    transition: .2s;
    min-width: 250px;
    max-width: 90vw;
    white-space: normal
}

.dropdown-menu:empty {
    padding: 0 !important;
    margin: 0 !important;
    min-height: 0 !important;
    border: none !important;
    box-shadow: none !important;
    display: none !important
}

.dropdown-menu .container {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem
}

.dropdown-menu .container>div {
    flex: 1 1 250px
}

.dropdown-menu h6 {
    font-size: .9rem;
    font-weight: 700;
    text-transform: uppercase
}

.dropdown-menu a.dropdown-item {
    padding: .25rem 0;
    display: block;
    white-space: normal !important;
    overflow-wrap: break-word;
    word-break: break-word
}

.navbar-nav .nav-link {
    text-transform: uppercase;
    font-weight: 600;
    color: var(--lphs-primary);
}

.navbar-nav .dropdown.hover-active .dropdown-menu {
    display: block
}

.slideUtama-indicators {
    position: absolute;
    top: 120px;
    left: 160px;
    right: auto;
    bottom: auto;
    margin: 0;
    z-index: 20;
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    align-items: center;
    gap: 8px;
    pointer-events: auto
}

#heroCarousel .carousel-item>a[style*="position:absolute"] {
    z-index: 10 !important
}

@media(max-width:767.98px) {
    .slideUtama-indicators {
        top: 12px;
        left: 12px;
        gap: 5px
    }

    .menu-wrapper.sticky .custom-navbar {
        height: 56px;
        padding: 0 2px
    }

    .custom-navbar {
        padding: .25rem .5rem;
        border-radius: 1rem
    }

    .carousel-item {
        min-height: unset
    }

    .content {
        margin-top: 0
    }

    .dropdown-menu {
        position: static !important;
        width: 100% !important;
        max-width: 100% !important;
        transform: none !important;
        box-shadow: none !important;
        border: 1px solid rgba(0, 0, 0, .08) !important;
        border-radius: .75rem !important;
        margin: .25rem 0 .5rem 0 !important;
        padding: .5rem !important;
        background: #fff !important;
    }

    .dropdown-menu .container {
        flex-direction: column;
        gap: .5rem
    }
}

.dropdown-menu .dropdown-flex-row {
    display: flex;
    flex-wrap: nowrap;
    gap: 1.5rem;
    width: auto;
    min-width: 0
}

.dropdown-menu .dropdown-flex-col {
    min-width: 180px;
    width: auto
}

@media(max-width:767.98px) {
    .dropdown-menu .dropdown-flex-row {
        flex-direction: column;
        gap: .5rem
    }
}

.dropdown-menu .dropdown-flex-row.four-cols {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto
}

@media(max-width:1200px) {
    .dropdown-menu .dropdown-flex-row.four-cols {
        max-width: 100vw;
        width: 100vw
    }
}

.service-card {
    transition: .2s;
    border-radius: 1rem;
    background: #fff;
    text-align: center
}

.service-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, .12), 0 1.5px 6px rgba(0, 128, 105, .12);
    transform: translateY(-6px) scale(1.03)
}

.service-title {
    font-family: Montserrat, Arial, Helvetica, sans-serif !important;
    font-size: .75rem;
    letter-spacing: .5px;
    font-weight: 600
}

@media(max-width:767.98px) {
    .service-title {
        font-size: .68rem
    }
}

.service-card .card-img-top {
    border-radius: 1rem 1rem 0 0;
    overflow: hidden;
    height: 110px;
    position: relative;
    padding: 0
}

.service-img-container {
    width: 100%;
    height: 110px;
    position: relative;
    justify-content: center;
    align-items: center;
    display: flex;
    overflow: hidden
}

.image-container {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
    display: block;
    margin: 0 auto
}

.middle-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: .2s;
    pointer-events: none
}

.service-card:hover .middle-container {
    opacity: 1;
    pointer-events: auto
}

.text-container {
    background: transparent !important;
    color: #fff;
    font-size: 2.2rem;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    box-shadow: none !important
}

@media(max-width:767.98px) {
    .service-title {
        font-size: .85rem
    }

    .service-img-container,
    .service-card .card-img-top {
        height: 70px
    }

    .image-container {
        height: 50% !important
    }

    .text-container {
        width: 36px;
        height: 36px;
        font-size: 1.3rem
    }
}

.service-card:hover .image-container {
    filter: blur(2.5px) brightness(.85);
    transition: .2s
}

#activityCarousel .card-title {
    font-size: 1rem;
    font-weight: 700
}

#activityCarousel .card-text {
    font-size: .95rem
}

#activityCarousel .card-img-top {
    border-radius: 1rem 1rem 0 0
}

@media(max-width:767.98px) {
    #activityCarousel .col-md-4 {
        flex: 0 0 100%;
        max-width: 100%
    }

    #activityCarousel .card-img-top {
        height: 90px
    }
}

#activityCarousel .carousel-item {
    height: auto !important;
    min-height: 0 !important
}

#activityCarousel .row.g-3 {
    margin-bottom: 0 !important
}

#activityCarousel .card {
    min-height: 100%
}

.announcement-item,
.tender-item {
    transition: .18s;
    cursor: pointer
}

.announcement-item:hover,
.tender-item:hover {
    background: #f0f6ff !important;
    box-shadow: 0 2px 12px rgba(0, 110, 253, .08)
}

.announcement-content {
    font-size: .97rem;
    color: #333
}

@media(max-width:767.98px) {

    .announcement-item,
    .tender-item {
        padding: 1rem .5rem !important
    }

    .announcement-content {
        font-size: .95rem
    }
}

@media(max-width:767.98px) {
    .slide-utama-carousel-item {
        height: 255px !important
    }
}

@media(max-width:1366px) and (min-width:992px) {
    section#slideUtama.has-services-overlay .slide-utama-carousel-item {
        height: var(--slide-carousel-height-with-services) !important;
    }
}

#slideUtama .carousel-indicators [data-bs-target] {
    width: 18px;
    height: 10px;
    border-radius: 6px;
    background: #bdbdbd;
    border: none;
    box-shadow: none;
    opacity: .7;
    margin: 0 4px;
    transition: background .3s, width .3s, opacity .3s;
    position: relative
}

#slideUtama .carousel-indicators .active {
    background: var(--lphs-secondary);
    width: 24px;
    opacity: 1;
    border-radius: 6px
}

#slideUtama .carousel-indicators {
    position: absolute;
    top: calc(var(--slide-navbar-clearance) + 6px);
    left: 50%;
    right: auto;
    bottom: auto;
    transform: translateX(-50%);
    margin: 0;
    z-index: 20;
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 8px;
    pointer-events: auto
}

@media(max-width:1366px) and (min-width:992px) {
    #slideUtama .carousel-indicators {
        top: calc(var(--slide-navbar-clearance) + 4px);
    }
}

@media(max-width:767.98px) {
    #slideUtama .carousel-indicators {
        top: 10px;
        left: 50%;
        transform: translateX(-50%);
        gap: 5px
    }
}

.footer-corporate {
    background: linear-gradient(90deg, var(--lphs-primary) 0, var(--lphs-primary-dark) 100%) !important;
    color: #fff !important;
    font-family: Montserrat, Arial, Helvetica, sans-serif;
    letter-spacing: .01em;
    font-size: .92rem;
    box-shadow: 0 -4px 32px rgba(var(--lphs-primary-rgb), .08)
}

.footer-corporate .footer-logo {
    filter: brightness(0) invert(1) grayscale(.2);
    transition: .2s
}

.footer-corporate .footer-logo:hover {
    filter: brightness(1.2) invert(0) grayscale(0)
}

.footer-corporate .footer-link a,
.footer-corporate .footer-link {
    color: #fff !important;
    text-decoration: underline dotted;
    font-weight: 500;
    margin-right: .5em
}

.footer-corporate .footer-link a:hover {
    color: var(--lphs-secondary) !important
}

.footer-corporate .footer-contact a {
    color: var(--lphs-secondary) !important;
    text-decoration: none;
    font-weight: 600
}

.footer-corporate .footer-contact a:hover {
    color: #fff !important;
    text-decoration: underline
}

.footer-corporate .footer-access {
    font-size: .93em;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2rem;
    padding: .7rem 1.5rem;
    margin-bottom: .7rem;
    box-shadow: 0 2px 12px 0 rgba(var(--lphs-primary-rgb), 0.09);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1.1rem;
    min-width: 220px;
    text-align: left !important
}

.footer-corporate .footer-access span {
    display: flex;
    align-items: center;
    gap: .3rem;
    background: rgba(var(--lphs-primary-rgb), 0.08);
    border-radius: 1rem;
    padding: .25rem .7rem;
    color: #fff;
    font-weight: 500;
    font-size: .98em;
    transition: background 0.18s
}

.footer-corporate .footer-access span b {
    font-weight: 700;
    color: var(--lphs-secondary)
}

.footer-corporate .footer-social {
    margin-top: .3rem;
    display: flex;
    justify-content: center;
    align-items: center
}

.footer-corporate .footer-social ul {
    gap: .9rem;
    display: flex;
    align-items: center;
    justify-content: center
}

.footer-corporate .footer-social a {
    font-size: 1.5rem;
    transition: color 0.18s, background 0.18s, transform 0.18s;
    color: rgba(255, 255, 255, .8) !important;
    background: rgba(var(--lphs-primary-rgb), .16);
    border-radius: 50%;
    width: 2.3rem;
    height: 2.3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 4px 0 rgba(var(--lphs-primary-rgb), .08)
}

.footer-corporate .footer-social a:hover {
    color: var(--lphs-secondary) !important;
    background: rgba(var(--lphs-secondary-rgb), 0.18);
    transform: scale(1.13)
}

@media(max-width:991.98px) {
    .footer-corporate {
        font-size: .89rem
    }

    .footer-corporate .footer-logo {
        max-width: 80px;
        max-height: 50px
    }
}

@media(max-width:767.98px) {
    .footer-corporate {
        font-size: .85rem
    }

    .footer-corporate .footer-logo {
        max-width: 60px;
        max-height: 36px
    }

    .footer-corporate .footer-access {
        font-size: .8em
    }

    .footer-corporate .footer-link {
        display: block;
        margin-top: .2em
    }
}

/* Perkhidmatan Section Styles */
#perkhidmatan {
    margin-top: 2rem;
    margin-bottom: 2rem;
    padding: 1.5rem 0;
    background: #fff;
    border-radius: 1.5rem;
    box-shadow: 0 4px 24px rgba(25, 135, 84, 0.08)
}

.perkhidmatan-header {
    margin-bottom: 1.5rem
}

.perkhidmatan-title {
    color: var(--lphs-primary);
    font-size: 2rem;
    font-family: "Montserrat", Arial, sans-serif;
    letter-spacing: 1px
}

.perkhidmatan-icon {
    background: rgba(var(--lphs-primary-rgb), 0.10);
    border-radius: 50%;
    width: 60px;
    height: 60px;
    display: inline-flex;
    align-items: center;
    justify-content: center
}

.perkhidmatan-list {
    gap: 1.5rem 0.5rem
}

.perkhidmatan-item {
    margin-bottom: 1rem
}

.perkhidmatan-card {
    border-radius: 1rem;
    background: #fff;
    transition: box-shadow .2s, transform .2s
}

.perkhidmatan-card:hover {
    box-shadow: 0 8px 24px rgba(25, 135, 84, 0.12), 0 1.5px 6px rgba(0, 128, 105, 0.12);
    transform: translateY(-6px) scale(1.03)
}

.perkhidmatan-img-container {
    height: 110px;
    background: #f8f9fa;
    border-radius: 1rem 1rem 0 0;
    overflow: hidden
}

.perkhidmatan-img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
    display: block;
    margin: 0 auto
}

.perkhidmatan-plus {
    font-size: 2.2rem;
    color: var(--lphs-primary);
    background: #fff;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    box-shadow: 0 2px 8px rgba(25, 135, 84, 0.08)
}

.perkhidmatan-nama {
    color: #dc3545;
    font-size: .95rem;
    font-weight: 600;
    min-height: 38px;
    font-family: "Montserrat", Arial, sans-serif
}

@media(max-width:991.98px) {
    #perkhidmatan {
        padding: 1rem 0.5rem;
        border-radius: 1rem
    }

    .perkhidmatan-title {
        font-size: 1.3rem
    }

    .perkhidmatan-img-container {
        height: 70px
    }

    .perkhidmatan-plus {
        width: 36px;
        height: 36px;
        font-size: 1.3rem
    }
}

/* Aktiviti terkini — grid kad */
.aktiviti-section-icon {
    background: rgba(var(--lphs-secondary-rgb), 0.12);
    border-radius: 50%;
    width: 56px;
    height: 56px;
    color: var(--lphs-secondary);
    font-size: 1.75rem;
}

.aktiviti-section-title {
    font-family: 'Montserrat', Arial, sans-serif;
    letter-spacing: 0.5px;
    color: var(--lphs-primary);
    font-size: 1.75rem;
}

.aktiviti-section-subtitle {
    font-size: 0.95rem;
    color: var(--lphs-accent-2) !important;
}

.aktiviti-section-cta {
    border: 1px solid var(--lphs-secondary);
    background: transparent;
    border-color: var(--lphs-secondary);
    color: var(--lphs-primary);
    font-weight: 600;
    white-space: nowrap;
}

.aktiviti-section-cta:hover {
    background: var(--lphs-secondary);
    border-color: var(--lphs-secondary);
    color: #fff;
}

.aktiviti-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    color: #111;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

a.aktiviti-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.14);
    color: #111;
}

.aktiviti-card-img-wrap {
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #eef3f8;
}

.aktiviti-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.aktiviti-card:hover .aktiviti-card-img {
    transform: scale(1.04);
}

.aktiviti-card-body {
    padding: 1rem 1rem 1.1rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.aktiviti-card-date {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--lphs-secondary);
    margin-bottom: 0.4rem;
}

.aktiviti-card-title {
    font-family: 'Montserrat', Arial, sans-serif;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.4;
    margin: 0 0 0.75rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.aktiviti-card-link {
    margin-top: auto;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--lphs-primary);
}

@media (max-width: 767.98px) {
    .aktiviti-section-title {
        font-size: 1.45rem;
    }

    .aktiviti-section-cta {
        width: 100%;
        text-align: center;
    }
}

.quicklink-card {
    border-radius: 1.2rem;
    background: #ffffff;
    transition: box-shadow 0.22s, transform 0.22s;
    box-shadow: 0 2px 10px rgba(var(--lphs-primary-rgb), 0.09);
    min-height: 154px;
    position: relative;
    overflow: visible;
    width: 100%;
    max-width: 100%;
}

.quicklink-card:hover {
    box-shadow: 0 12px 36px rgba(var(--lphs-primary-rgb), 0.18), 0 2px 8px rgba(0, 0, 0, 0.09);
    transform: translateY(-10px) scale(1.06);
    background: color-mix(in srgb, var(--lphs-accent-1) 70%, white);
}

.quicklink-link {
    color: var(--lphs-primary) !important;
    font-size: 1rem;
    font-family: 'Montserrat', Arial, Helvetica, sans-serif;
    min-height: 124px;
    padding: 0.95rem 0.3rem 0.8rem 0.3rem;
    border-radius: 1.2rem;
    transition: color 0.18s;
    width: 100%;
    word-break: break-word;
    overflow-wrap: break-word;
}

.quicklink-icon {
    font-size: 2.2rem;
    width: 56px;
    height: 56px;
}

.quicklink-label {
    font-size: 1rem;
    min-height: 32px;
}

@media (max-width: 991.98px) {
    .quicklink-card {
        min-height: 118px;
    }

    .quicklink-link {
        font-size: 0.95rem;
        min-height: 90px;
        padding: 0.72rem 0.1rem 0.62rem 0.1rem;
    }

    .quicklink-icon {
        font-size: 1.8rem;
        width: 40px;
        height: 40px;
    }

    .quicklink-label {
        font-size: 0.85rem;
        min-height: 22px;
    }
}

@media (max-width: 767.98px) {
    .quicklink-card {
        min-height: 82px;
    }

    .quicklink-link {
        font-size: 0.78rem;
        min-height: 62px;
        padding: 0.42rem 0.1rem 0.25rem 0.1rem;
    }

    .quicklink-icon {
        font-size: 1.2rem;
        width: 28px;
        height: 28px;
    }

    .quicklink-label {
        font-size: 0.7rem;
        min-height: 14px;
    }
}

.footer-access-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-width: 120px;
    width: 100%;
}

.footer-access-label {
    flex: 1 1 auto;
    text-align: left;
}

.footer-access-value {
    flex: 0 0 auto;
    text-align: right;
    margin-left: 8px;
}

.menu-wrapper.sticky .custom-navbar {
    background: var(--lphs-primary) !important;
    box-shadow: 0 2px 12px rgba(var(--lphs-primary-rgb), 0.25);
    border-radius: 0 !important;
}

/* Teks & icon putih pada sticky (background biru) */
.menu-wrapper.sticky .navbar-nav .nav-link,
.menu-wrapper.sticky .navbar-brand {
    color: #fff !important;
}

/* Hamburger icon putih pada sticky */
.menu-wrapper.sticky .navbar-toggler {
    border-color: rgba(255, 255, 255, 0.5);
}

.menu-wrapper.sticky .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255%2C255%2C255%2C0.9%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Hamburger icon gelap bila navbar background cerah (bukan sticky) */
.menu-wrapper:not(.sticky) .custom-navbar .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%280%2C 0%2C 0%2C 0.7%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.menu-wrapper:not(.sticky) .custom-navbar .navbar-toggler {
    border-color: rgba(0, 0, 0, 0.3);
}

/* Perkhidmatan utama — kad portal di atas slider */
.slide-utama-carousel-item {
    position: relative;
    background-size: cover;
    background-position: center 42%;
    background-repeat: no-repeat;
    height: var(--slide-carousel-height);
}

section#slideUtama.has-services-overlay .slide-utama-carousel-item::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: var(--slide-services-clearance);
    pointer-events: none;
    z-index: 1;
    background: linear-gradient(
        to top,
        rgba(var(--lphs-accent-1-rgb), 0.92) 35%,
        rgba(var(--lphs-accent-1-rgb), 0.55) 78%,
        transparent 90%
    );
    backdrop-filter: blur(1px);
    -webkit-backdrop-filter: blur(1px);
}

.slide-utama-carousel-item .hero-overlay {
    z-index: 2;
}

@media (min-width: 768px) {
    section#slideUtama.has-services-overlay .slide-utama-carousel-item {
        height: var(--slide-carousel-height-with-services);
        background-position: center 38%;
    }
}

@media (max-width: 767.98px) {
    section#slideUtama.has-services-overlay .slide-utama-carousel-item {
        height: 255px !important;
        background-position: center 40%;
    }

    /* Perkhidmatan di bawah slider — buang gradient/blur bawah */
    section#slideUtama.has-services-overlay .slide-utama-carousel-item::after {
        display: none;
    }
}

section#slideUtama {
    overflow: visible;
}

section#slideUtama #services-overlay {
    bottom: 0;
    z-index: 10;
}

@media (min-width: 768px) {
    section#slideUtama #services-overlay {
        bottom: var(--services-overlay-bottom);
    }
}

section#slideUtama .services-overlay-heading {
    font-family: 'Montserrat', Arial, sans-serif;
    font-size: 1rem;
    letter-spacing: 0.5px;
    padding: 0.25rem 0.75rem;
    display: inline-block;
    border-radius: 999px;
    background: rgba(var(--lphs-accent-1-rgb), 0.92);
    color: var(--lphs-primary) !important;
}

.service-portal-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.14);
    padding: 1rem 0.65rem 0.85rem;
    text-align: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    min-height: 205px;
    color: #111;
}

.service-portal-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.18);
    color: #111;
}

.service-portal-card .service-portal-icon {
    height: 88px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.65rem;
}

.service-portal-card .service-portal-icon img {
    height: 80px;
    width: 80px;
    max-height: 80px;
    max-width: 80px;
    object-fit: contain;
}

.service-portal-card .service-portal-title {
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 1.38;
    margin-bottom: 0.35rem;
    color: #111;
}

.service-portal-card .service-portal-subtitle {
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.44;
    color: #444;
}

/* Services section pada mobile - keluar dari slider, alir ke bawah */
@media (max-width: 767.98px) {
    section#slideUtama {
        display: flex;
        flex-direction: column;
        height: auto !important;
    }

    section#slideUtama>#slideUtamaCarousel {
        height: 255px;
        flex-shrink: 0;
    }

    section#slideUtama #services-overlay {
        position: relative !important;
        width: 100% !important;
        bottom: auto !important;
        top: auto !important;
        z-index: 1 !important;
        background: transparent;
        padding: 0.75rem 0.5rem 1rem;
        box-shadow: none;
    }

    section#slideUtama .services-overlay-heading {
        color: var(--lphs-primary) !important;
        background: transparent;
        padding-left: 0;
    }

    section#slideUtama #services-overlay .service-portal-card {
        min-height: 186px;
        padding: 0.75rem 0.5rem;
    }

    section#slideUtama #services-overlay .service-portal-title {
        font-size: 1.05rem;
    }

    section#slideUtama #services-overlay .service-portal-subtitle {
        font-size: 0.93rem;
    }

    section#slideUtama #services-overlay .service-portal-icon {
        height: 76px;
        margin-bottom: 0.5rem;
    }

    section#slideUtama #services-overlay .service-portal-icon img {
        height: 68px;
        width: 68px;
        max-height: 68px;
        max-width: 68px;
    }

    section#slideUtama #services-overlay .col-6 {
        flex: 0 0 50%;
        max-width: 50%;
    }
}

/* 7 perkhidmatan dalam 1 baris (desktop) */
@media (min-width: 992px) {
    section#slideUtama #services-overlay .services-overlay-row > .services-overlay-col {
        flex: 0 0 calc(100% / 7);
        max-width: calc(100% / 7);
        width: calc(100% / 7);
    }

    section#slideUtama #services-overlay .service-portal-card {
        min-height: 188px;
        padding: 0.75rem 0.35rem 0.65rem;
    }

    section#slideUtama #services-overlay .service-portal-icon {
        height: 72px;
        margin-bottom: 0.45rem;
    }

    section#slideUtama #services-overlay .service-portal-icon img {
        height: 64px;
        width: 64px;
        max-height: 64px;
        max-width: 64px;
    }

    section#slideUtama #services-overlay .service-portal-title {
        font-size: 0.92rem;
        line-height: 1.28;
    }

    section#slideUtama #services-overlay .service-portal-subtitle {
        font-size: 0.78rem;
        line-height: 1.35;
    }

    section#slideUtama #services-overlay .service-portal-acronym {
        font-size: 0.88rem;
    }
}

.menu-wrapper.sticky .navbar-brand img {
    filter: none !important;
}

.dropdown-menu a.dropdown-item:hover {
    color: var(--lphs-primary) !important;
    background: color-mix(in srgb, var(--lphs-accent-1) 60%, white) !important;
    transition: color 0.18s, background 0.18s;
}

/* Pautan Lain (Other Links) Section Styles */
#otherlinks-section .otherlinks-slider {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

#otherlinks-section .otherlinks-track {
    display: flex;
    flex-wrap: nowrap;
    gap: 1.25rem;
    overflow-x: auto;
    scroll-snap-type: x proximity;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 0.25rem 0.5rem 0.5rem;
    flex: 1;
    min-width: 0;
}

#otherlinks-section .otherlinks-track::-webkit-scrollbar {
    display: none;
}

#otherlinks-section .otherlinks-track--center {
    justify-content: center;
}

#otherlinks-section .otherlinks-slider-btn {
    flex-shrink: 0;
    width: 2.25rem;
    height: 2.25rem;
    border: 1px solid rgba(var(--lphs-accent-2-rgb), 0.35);
    border-radius: 50%;
    background: #fff;
    color: var(--lphs-accent-2);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(var(--lphs-accent-2-rgb), 0.12);
    transition: background 0.18s, color 0.18s, border-color 0.18s;
}

#otherlinks-section .otherlinks-slider-btn:hover:not(:disabled) {
    background: var(--lphs-accent-2);
    border-color: var(--lphs-accent-2);
    color: #fff;
}

#otherlinks-section .otherlinks-slider-btn:disabled {
    opacity: 0.35;
    cursor: default;
}

#otherlinks-section .otherlink-item {
    flex: 0 0 auto;
    width: 132px;
    scroll-snap-align: start;
    padding: 0.5rem 0.25rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: transform 0.18s ease;
    color: inherit;
}

#otherlinks-section .otherlink-item:hover {
    transform: translateY(-4px);
}

#otherlinks-section .otherlink-image,
#otherlinks-section .otherlink-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(var(--lphs-accent-2-rgb), 0.10);
    border: 2.5px solid var(--lphs-accent-2);
    margin-bottom: 0.65rem;
    box-shadow: 0 2px 8px rgba(var(--lphs-accent-2-rgb), 0.10);
}

#otherlinks-section .otherlink-image img {
    width: 38px;
    height: 38px;
    object-fit: contain;
}

#otherlinks-section .otherlink-label {
    font-family: 'Montserrat', Arial, sans-serif;
    font-size: 0.95rem;
    color: var(--lphs-accent-2);
    letter-spacing: 0.3px;
    font-weight: 600;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

@media (max-width: 575.98px) {
    #otherlinks-section .otherlink-item {
        width: 112px;
    }

    #otherlinks-section .otherlink-label {
        font-size: 0.88rem;
    }

    #otherlinks-section .otherlinks-slider-btn {
        width: 2rem;
        height: 2rem;
    }
}

/* Berita terkini ticker */
.news-ticker-panel {
    box-shadow: 0 4px 24px rgba(var(--lphs-primary-rgb), 0.10);
    padding: 1rem 1.5rem;
    margin-bottom: 0;
    background: #fff;
    border-radius: 12px;
}

.news-ticker-carousel {
    min-width: 0;
    overflow: hidden;
}

.news-ticker-carousel-inner {
    gap: 1rem;
}

.news-ticker-track {
    min-width: 0;
    overflow: hidden;
}

.news-ticker-item-text,
.news-ticker-link,
.news-ticker-text {
    min-width: 0;
    word-break: break-word;
    overflow-wrap: anywhere;
    font-size: clamp(0.9rem, 1.1vw + 0.75rem, 1.25rem);
    line-height: 1.5;
}

.news-ticker-item-text a,
.news-ticker-link a,
.news-ticker-text a {
    word-break: break-word;
    overflow-wrap: anywhere;
}

.news-ticker-nav {
    gap: 0.5rem;
    flex-shrink: 0;
}

.news-ticker-row {
    gap: 0.75rem;
}

.news-ticker-badge {
    gap: 0.5rem;
    background-color: var(--lphs-primary);
    border-radius: 8px;
    padding: 0.5rem;
    width: fit-content;
}

.news-ticker-badge-icon {
    color: var(--lphs-secondary);
    font-size: 1.5rem;
}

.news-ticker-badge-label {
    font-size: 0.9rem;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.news-ticker-item-icon {
    color: var(--lphs-secondary);
    font-size: 1.1rem;
    margin-top: 3px;
}

.news-ticker-nav-btn {
    width: 2.5rem;
    height: 2.5rem;
    background: rgba(var(--lphs-accent-2-rgb), 0.12);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(var(--lphs-primary-rgb), 0.08);
}
@media (max-width: 767.98px) {
    .news-ticker-panel {
        padding: 0.75rem 0.875rem;
        border-radius: 10px;
    }

    .news-ticker-row {
        gap: 0.625rem;
    }

    .news-ticker-badge {
        width: 100%;
        justify-content: center;
        padding: 0.45rem 0.75rem;
    }

    .news-ticker-badge-icon {
        font-size: 1.15rem;
    }

    .news-ticker-badge-label {
        font-size: 0.8125rem;
    }

    .news-ticker-carousel-inner {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }

    .news-ticker-track {
        width: 100%;
    }

    .news-ticker-track .carousel-item {
        padding-right: 0;
    }

    .news-ticker-item-icon {
        font-size: 1rem;
        margin-top: 2px;
    }

    .news-ticker-item-text,
    .news-ticker-link,
    .news-ticker-text {
        font-size: 0.9375rem;
        line-height: 1.45;
    }

    .news-ticker-nav {
        width: 100%;
        justify-content: center;
        gap: 0.75rem;
    }

    .news-ticker-nav-btn {
        width: 2.25rem;
        height: 2.25rem;
    }

    .news-ticker-nav-btn svg {
        width: 22px;
        height: 22px;
    }
}

@media (max-width: 575.98px) {
    .news-ticker-panel {
        padding: 0.625rem 0.75rem;
    }

    .news-ticker-item-text,
    .news-ticker-link,
    .news-ticker-text {
        font-size: 0.875rem;
    }
}


/* Tajuk seksyen laman utama */
.section-icon-circle {
    border-radius: 50%;
    width: 60px;
    height: 60px;
}

.section-icon-circle--primary {
    background: rgba(var(--lphs-primary-rgb), 0.10);
}

.section-icon-circle--primary i {
    font-size: 36px;
    color: var(--lphs-primary);
}

.section-icon-circle--accent {
    background: rgba(var(--lphs-accent-2-rgb), 0.12);
}

.section-icon-circle--accent i {
    font-size: 36px;
    color: var(--lphs-accent-2);
}

.section-heading {
    font-family: 'Montserrat', Arial, sans-serif;
    letter-spacing: 1px;
    font-size: 2rem;
}

.section-heading--primary {
    color: var(--lphs-primary);
}

.section-heading--accent {
    color: var(--lphs-accent-2);
}

.section-subheading {
    font-size: 1rem;
    color: var(--lphs-accent-2) !important;
}

.otherlink-fallback-icon {
    font-size: 2rem;
    color: var(--lphs-accent-2);
}

/* Halaman dalaman — hero banner */
.page-hero {
    background: linear-gradient(135deg, var(--lphs-primary) 0%, var(--lphs-primary-dark) 100%);
    padding: 60px 0 40px;
    margin-top: 100px;
}

.page-hero-title {
    font-family: 'Montserrat', Arial, sans-serif;
}

/* Galeri */
.gallery-card {
    overflow: hidden;
    border-radius: 10px;
    border: 1px solid rgba(var(--lphs-accent-2-rgb), 0.18);
    transition: box-shadow .2s, transform .2s;
}

.gallery-card:hover {
    box-shadow: 0 6px 24px rgba(var(--lphs-primary-rgb), 0.13);
    transform: translateY(-3px);
}

.gallery-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform .3s;
}

.gallery-card:hover img {
    transform: scale(1.05);
}

.gallery-year-btn.active {
    background-color: var(--lphs-primary);
    color: #fff;
    border-color: var(--lphs-primary);
}

.gallery-photo-thumb {
    cursor: pointer;
    overflow: hidden;
    border-radius: 8px;
    border: 1px solid rgba(var(--lphs-accent-2-rgb), 0.18);
    transition: box-shadow .2s, transform .2s;
}

.gallery-photo-thumb:hover {
    box-shadow: 0 6px 20px rgba(var(--lphs-primary-rgb), 0.15);
    transform: translateY(-2px);
}

.gallery-photo-thumb img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    transition: transform .3s;
}

.gallery-photo-thumb:hover img {
    transform: scale(1.06);
}

/* Bootstrap — selaraskan dengan palet tema LPHS */
.text-primary {
    color: var(--lphs-primary) !important;
}

.btn-primary {
    --bs-btn-bg: var(--lphs-primary);
    --bs-btn-border-color: var(--lphs-primary);
    --bs-btn-hover-bg: var(--lphs-primary-dark);
    --bs-btn-hover-border-color: var(--lphs-primary-dark);
    --bs-btn-active-bg: var(--lphs-primary-dark);
    --bs-btn-active-border-color: var(--lphs-primary-dark);
    --bs-btn-disabled-bg: var(--lphs-primary);
    --bs-btn-disabled-border-color: var(--lphs-primary);
    --bs-btn-focus-shadow-rgb: var(--lphs-primary-rgb);
}

.btn-outline-primary {
    --bs-btn-color: var(--lphs-primary);
    --bs-btn-border-color: var(--lphs-primary);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--lphs-primary);
    --bs-btn-hover-border-color: var(--lphs-primary);
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--lphs-primary-dark);
    --bs-btn-active-border-color: var(--lphs-primary-dark);
    --bs-btn-focus-shadow-rgb: var(--lphs-primary-rgb);
}

.bg-primary {
    --bs-bg-opacity: 1;
    background-color: rgba(var(--lphs-primary-rgb), var(--bs-bg-opacity)) !important;
}

.border-primary {
    border-color: var(--lphs-primary) !important;
}

.badge.bg-primary {
    background-color: var(--lphs-primary) !important;
}

/* Penapis tahun — galeri & statistik */
.filter-year-btn.active,
.gallery-year-btn.active,
.year-btn.active {
    background-color: var(--lphs-primary);
    color: #fff;
    border-color: var(--lphs-primary);
}

/* Borang muat turun */
.card-header-bg.pemaju {
    background: linear-gradient(135deg, var(--lphs-primary) 0%, var(--lphs-primary-dark) 100%);
}

.form-tab-nav .nav-link.active {
    color: var(--lphs-primary);
    border-bottom-color: var(--lphs-primary);
    background: transparent;
}

.section-header-banner {
    background: linear-gradient(135deg, var(--lphs-primary) 0%, var(--lphs-primary-dark) 100%);
    color: #fff;
    padding: 12px 20px;
    border-radius: 8px 8px 0 0;
    font-weight: 700;
    font-size: 1.05rem;
}

/* ALP */
.alp-section-header {
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: var(--lphs-primary);
    text-transform: uppercase;
    border-bottom: 2px solid var(--lphs-primary);
    padding-bottom: 0.4rem;
    margin-bottom: 1.5rem;
}

.member-role-badge {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.8px;
    color: #fff;
    background: var(--lphs-primary);
    border-radius: 30px;
    padding: 2px 12px;
    margin-bottom: 0.4rem;
}

/* CIO */
.cio-profile-header {
    background: linear-gradient(135deg, var(--lphs-primary) 0%, var(--lphs-primary-dark) 100%);
    padding: 28px 24px;
    text-align: center;
    border-radius: 16px 0 0 16px;
}

@media (max-width: 575.98px) {
    .cio-profile-header {
        border-radius: 16px 16px 0 0;
    }
}

/* DataTables & Select2 — frontend */
.select2-container--bootstrap-5 .select2-results__option--highlighted {
    background-color: var(--lphs-primary) !important;
    color: #fff !important;
}

.dataTables_filter input[type="search"]:focus {
    border-color: var(--lphs-primary);
    outline: none;
    box-shadow: 0 0 0 0.2rem rgba(var(--lphs-primary-rgb), .15);
}

.dataTables_paginate .paginate_button {
    color: var(--lphs-primary) !important;
}

.dataTables_paginate .paginate_button.current,
.dataTables_paginate .paginate_button:hover {
    background: var(--lphs-primary) !important;
    color: #fff !important;
    border-color: var(--lphs-primary);
}

#tender-table tbody tr:hover {
    background-color: color-mix(in srgb, var(--lphs-accent-1) 55%, white);
}

/* W3C accessibility — float kanan */
html {
    font-size: calc(100% * var(--w3c-font-scale, 1));
}

.portal-w3c-wrap {
    position: fixed;
    inset: 0;
    z-index: 10050;
    pointer-events: none;
}

.portal-w3c-panel {
    position: fixed;
    right: 0.75rem;
    top: 50%;
    width: 3.25rem;
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-50%) translateX(calc(100% + 1rem));
    transition: opacity .2s ease, transform .2s ease, visibility .2s ease;
    background: #fff;
    border: 1px solid rgba(26, 107, 53, 0.25);
    border-radius: 12px;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.18);
    overflow: hidden;
}

.portal-w3c-panel.is-open {
    pointer-events: auto;
    opacity: 1;
    visibility: visible;
    transform: translateY(-50%) translateX(0);
}

.portal-w3c-panel-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    padding: 0.55rem 0.45rem;
    max-height: calc(100vh - 2rem);
    overflow-y: auto;
}

.portal-w3c-panel-title {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--lphs-primary, #1a6b35);
    margin-bottom: 0.15rem;
}

.portal-w3c-btn,
.portal-w3c-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.15rem;
    height: 2.15rem;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    background: #fff;
    cursor: pointer;
    transition: background-color .15s ease, transform .15s ease;
    flex-shrink: 0;
    padding: 0;
}

.portal-w3c-btn:hover,
.portal-w3c-close:hover {
    background: #f3f4f6;
    transform: translateY(-1px);
}

.portal-w3c-divider {
    width: 1.5rem;
    height: 1px;
    background: #d1d5db;
    margin: 0.1rem 0;
}

.portal-w3c-close {
    background: #f8fafc;
    color: #64748b;
    margin-top: 0.15rem;
}

.portal-w3c-close:hover {
    background: #fee2e2;
    color: #b91c1c;
}

button.portal-top-header-tool-link.portal-w3c-toggle {
    cursor: pointer;
}

body.w3c-custom-text #portalTopHeader,
body.w3c-custom-text #portalTopHeader .portal-top-header-title-top,
body.w3c-custom-text #portalTopHeader .portal-top-header-title-main,
body.w3c-custom-text #portalTopHeader .portal-top-header-tool-label,
body.w3c-custom-text #mainMenu .nav-link,
body.w3c-custom-text #mainMenu .dropdown-item,
body.w3c-custom-text #mainMenu .dropdown-header,
body.w3c-custom-text #portal-main,
body.w3c-custom-text #portal-main h1,
body.w3c-custom-text #portal-main h2,
body.w3c-custom-text #portal-main h3,
body.w3c-custom-text #portal-main h4,
body.w3c-custom-text #portal-main h5,
body.w3c-custom-text #portal-main h6,
body.w3c-custom-text #portal-main p,
body.w3c-custom-text #portal-main li,
body.w3c-custom-text #portal-main span,
body.w3c-custom-text #portal-main a,
body.w3c-custom-text #portal-main label,
body.w3c-custom-text #portal-main td,
body.w3c-custom-text #portal-main th,
body.w3c-custom-text #footerUtama,
body.w3c-custom-text #footerUtama a,
body.w3c-custom-text #footerUtama p,
body.w3c-custom-text #footerUtama span {
    color: var(--w3c-text-color) !important;
}

body.w3c-theme-light {
    background: #fff !important;
}

body.w3c-theme-light #portalTopHeader,
body.w3c-theme-light #mainMenu .dropdown-menu,
body.w3c-theme-light #portal-main,
body.w3c-theme-light #portal-main .card,
body.w3c-theme-light #portal-main .news-ticker-panel,
body.w3c-theme-light #footerUtama {
    background: #fff !important;
}

body.w3c-theme-light #footerUtama {
    background: #c0c0c0 !important;
}

body.w3c-theme-light #portalTopHeader .portal-top-header-title-top,
body.w3c-theme-light #portalTopHeader .portal-top-header-title-main,
body.w3c-theme-light #mainMenu .nav-link,
body.w3c-theme-light #portal-main,
body.w3c-theme-light #portal-main h1,
body.w3c-theme-light #portal-main h2,
body.w3c-theme-light #portal-main h3,
body.w3c-theme-light #portal-main p,
body.w3c-theme-light #portal-main a,
body.w3c-theme-light #footerUtama,
body.w3c-theme-light #footerUtama a {
    color: #111 !important;
}


body.w3c-theme-light #mainMenu,
body.w3c-theme-light .menu-wrapper,
body.w3c-theme-light section.navbarUtama {
    background: transparent !important;
    box-shadow: none !important;
}

body.w3c-theme-dark {
    background: #000 !important;
    color: #fff !important;
}

body.w3c-theme-dark #portalTopHeader,
body.w3c-theme-dark #mainMenu .dropdown-menu,
body.w3c-theme-dark #portal-main,
body.w3c-theme-dark #portal-main .card,
body.w3c-theme-dark #portal-main .news-ticker-panel,
body.w3c-theme-dark #portal-main .aktiviti-card,
body.w3c-theme-dark #portal-main .page-hero {
    background: #000 !important;
    color: #fff !important;
}

body.w3c-theme-dark #footerUtama {
    background: #212529 !important;
}

body.w3c-theme-dark #portalTopHeader .portal-top-header-title-top,
body.w3c-theme-dark #portalTopHeader .portal-top-header-title-main,
body.w3c-theme-dark #portalTopHeader .portal-top-header-tool-label,
body.w3c-theme-dark #mainMenu .nav-link,
body.w3c-theme-dark #mainMenu .dropdown-item,
body.w3c-theme-dark #portal-main,
body.w3c-theme-dark #portal-main h1,
body.w3c-theme-dark #portal-main h2,
body.w3c-theme-dark #portal-main h3,
body.w3c-theme-dark #portal-main p,
body.w3c-theme-dark #portal-main li,
body.w3c-theme-dark #portal-main span,
body.w3c-theme-dark #portal-main a,
body.w3c-theme-dark #footerUtama,
body.w3c-theme-dark #footerUtama a,
body.w3c-theme-dark #footerUtama p,
body.w3c-theme-dark #footerUtama span {
    color: #fff !important;
}


/* Navbar wrapper kekal transparent — hanya pill .custom-navbar berwarna */
body.w3c-theme-dark #mainMenu,
body.w3c-theme-dark .menu-wrapper,
body.w3c-theme-dark section.navbarUtama {
    background: transparent !important;
    box-shadow: none !important;
}

/* Header atas — ikon PNG gelap perlu invert pada bg gelap */
body.w3c-theme-dark #portalTopHeader {
    background: #111 !important;
    border-bottom-color: rgba(255, 255, 255, 0.12) !important;
}

body.w3c-theme-dark .portal-top-header-tool + .portal-top-header-tool {
    border-left-color: rgba(255, 255, 255, 0.2) !important;
}

body.w3c-theme-dark .portal-top-header-tool-icon {
    filter: brightness(0) invert(1);
}

body.w3c-theme-dark #portalW3cToggle[aria-pressed="true"] {
    background: rgba(255, 255, 255, 0.12) !important;
    border-radius: 6px;
}

/* Navbar float — elak teks putih atas bg putih bila tema gelap */
body.w3c-theme-dark .menu-wrapper .custom-navbar,
body.w3c-theme-dark .custom-navbar {
    background: var(--lphs-primary) !important;
    border-color: rgba(255, 255, 255, 0.18) !important;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35) !important;
}

body.w3c-theme-dark .menu-wrapper .navbar-nav .nav-link,
body.w3c-theme-dark .menu-wrapper .navbar-brand,
body.w3c-theme-dark .custom-navbar .navbar-nav .nav-link {
    color: #fff !important;
}

body.w3c-theme-dark .menu-wrapper .custom-navbar .navbar-toggler {
    border-color: rgba(255, 255, 255, 0.5);
}

body.w3c-theme-dark .menu-wrapper .custom-navbar .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255%2C255%2C255%2C0.9%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

body.w3c-theme-dark .custom-navbar .dropdown-menu,
body.w3c-theme-dark #mainMenu .dropdown-menu {
    background: #212529 !important;
    border-color: rgba(255, 255, 255, 0.12);
}

body.w3c-theme-dark .custom-navbar .dropdown-item,
body.w3c-theme-dark .custom-navbar .dropdown-header,
body.w3c-theme-dark #mainMenu .dropdown-item,
body.w3c-theme-dark #mainMenu .dropdown-header {
    color: #fff !important;
}

body.w3c-theme-dark .custom-navbar .dropdown-item:hover,
body.w3c-theme-dark #mainMenu .dropdown-item:hover {
    background: rgba(255, 255, 255, 0.08) !important;
    color: #fff !important;
}

@media (max-width: 767.98px) {
    body.w3c-theme-dark .custom-navbar .navbar-collapse.show,
    body.w3c-theme-dark .custom-navbar .navbar-collapse.collapsing,
    body.w3c-theme-dark .menu-wrapper.sticky .custom-navbar .navbar-collapse.show,
    body.w3c-theme-dark .menu-wrapper.sticky .custom-navbar .navbar-collapse.collapsing {
        background: var(--lphs-primary) !important;
    }

    body.w3c-theme-dark .custom-navbar .navbar-collapse .nav-link {
        color: #fff !important;
    }
}

@media (max-width: 767.98px) {
    .portal-w3c-panel {
        right: 0.5rem;
        top: auto;
        bottom: 5.5rem;
        transform: translateX(calc(100% + 1rem));
        width: 3rem;
    }

    .portal-w3c-panel.is-open {
        transform: translateX(0);
    }

    .portal-w3c-btn,
    .portal-w3c-close {
        width: 2rem;
        height: 2rem;
    }
}
