/* =========================================================
   BISE Malakand Modern Theme
   Lightweight reveal and state animations
========================================================= */

.bmh-reveal {
    opacity: 0;
    transform: translateY(18px);
    transition:
        opacity 0.5s ease,
        transform 0.5s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.bmh-reveal.is-visible {
    opacity: 1;
    transform: none;
}

.bmh-reveal-stagger > * {
    opacity: 0;
    transform: translateY(12px);
    transition:
        opacity 0.42s ease,
        transform 0.42s ease;
}

.bmh-reveal-stagger.is-visible > * {
    opacity: 1;
    transform: none;
}

.bmh-reveal-stagger.is-visible > *:nth-child(2) { transition-delay: 0.04s; }
.bmh-reveal-stagger.is-visible > *:nth-child(3) { transition-delay: 0.08s; }
.bmh-reveal-stagger.is-visible > *:nth-child(4) { transition-delay: 0.12s; }
.bmh-reveal-stagger.is-visible > *:nth-child(5) { transition-delay: 0.16s; }
.bmh-reveal-stagger.is-visible > *:nth-child(6) { transition-delay: 0.20s; }

.bmh-tab-pane.is-active,
.bmh-board-hub__panel.is-active {
    animation: bmhFadeIn 0.22s ease;
}

@keyframes bmhFadeIn {
    from {
        opacity: 0;
        transform: translateY(4px);
    }
    to {
        opacity: 1;
        transform: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .bmh-shell *,
    .bmh-shell *::before,
    .bmh-shell *::after {
        animation: none !important;
        transition: none !important;
    }

    .bmh-reveal,
    .bmh-reveal-stagger > * {
        opacity: 1 !important;
        transform: none !important;
    }
}

/* =========================================================
   BISE Malakand Modern Theme
   Responsive styles
========================================================= */

@media (min-width: 768px) {
    .bmh-container {
        width: min(calc(100% - 50px), 1480px);
    }
}

@media (max-width: 1200px) {
    .bmh-brandbar__inner {
        grid-template-columns:
            minmax(430px, 1fr)
            minmax(250px, 300px);

        gap: 18px;
    }

    .bmh-brand strong {
        font-size: clamp(18px, 1.7vw, 20px);
    }

    .bmh-brand img {
        width: 82px;
        height: 82px;
    }

    .bmh-brand-copy > .site-urdu-name {
        font-size: 18px;
        line-height: 38px !important;
    }

    .bmh-brand-actions .bmh-btn {
        padding-inline: 13px;

        font-size: 11px;
    }

    .bmh-header-search {
        max-width: 280px;
    }
}

/* Homepage review pass: compact, readable mobile system. */

@media (max-width: 820px) {
    .bmh-home section:not(.bmh-urgent):not(.bmh-hero) {
        padding-block: 15px;
    }

    .bmh-home .bmh-section-title,
    .bmh-home .bmh-services-directory__heading,
    .bmh-home .bmh-institution-corner__heading,
    .bmh-home .bmh-contact__heading,
    .bmh-home .bmh-board-hub__heading {
        font-size: 1.375rem;
        line-height: 1.18;
    }

    .bmh-home .bmh-section-intro,
    .bmh-home .bmh-services-directory__intro,
    .bmh-home .bmh-institution-corner__intro,
    .bmh-home .bmh-contact__intro {
        font-size: 0.8125rem;
        line-height: 1.55;
    }

    .bmh-home :is(button, .btn, [role="button"], input, select, textarea):not(.bmh-carousel-control):not([data-bmh-gallery-dot]),
    .bmh-home .bmh-service-tabs__button,
    .bmh-home .bmh-mobile-nav-toggle,
    .bmh-home .bmh-mobile-updates-toggle {
        min-height: 44px;
    }

    .bmh-home .bmh-social-link {
        width: 44px;
        height: 44px;
    }

    .bmh-home .bmh-urgent__item,
    .bmh-home .bmh-footer,
    .bmh-home .bmh-footer a,
    .bmh-home .bmh-institution-corner__card,
    .bmh-home .bmh-contact-card {
        font-size: 0.8125rem;
    }

    .bmh-home .bmh-mobile-updates-toggle {
        color: var(--bmh-white);
    }

    .bmh-home .bmh-featured-services__item,
    .bmh-home .bmh-featured-service-link {
        min-height: 64px;
    }

    .bmh-home .bmh-featured-service-title {
        font-size: 0.8375rem;
        line-height: 1.35;
    }

    .bmh-home :is(#bmh-services, #services) .bmh-featured-service-link__main {
        min-height: 44px !important;
    }
}

@media (max-width: 479px) {
    .bmh-home section:not(.bmh-urgent):not(.bmh-hero) {
        padding-block: 15px;
    }

}

/* Brand hierarchy: English name is primary, Urdu name is secondary. */

@media (max-width: 1200px) {
    .bmh-brand-heading {
        font-size: clamp(1.25rem, 2vw, 1.5rem);
    }

    .bmh-brand-heading + .site-urdu-name {
        font-size: 1rem;
        line-height: 1.5 !important;
    }
}

@media (max-width: 820px) {
    .bmh-brand-heading {
        font-size: 1.125rem;
        line-height: 1.18;
    }

    .bmh-brand-heading + .site-urdu-name {
        margin-top: 3px;
        font-size: 0.9375rem;
        line-height: 1.45 !important;
        text-align: left;
    }
}

@media (max-width: 430px) {
    .bmh-brand-heading {
        font-size: 1rem;
    }

    .bmh-brand-heading + .site-urdu-name {
        font-size: 0.875rem;
        white-space: normal;
    }
}

@media (max-width: 820px) {
    .bmh-home .bmh-urgent__item {
        font-family: var(--bmh-font-urdu) !important;
        font-size: 0.75rem;
        font-weight: 400;
        line-height: 1.8;
    }
}

@media (max-width: 430px) {
    .bmh-home .bmh-urgent__item {
        font-size: 0.71875rem;
    }
}


@media (max-width: 1100px) {
    .bmh-brandbar__inner {
        grid-template-columns:
            minmax(400px, 1fr)
            minmax(240px, 280px);

        gap: 16px;
    }
}


@media (max-width: 1040px) {
    .bmh-hero-grid {
        grid-template-columns:
            minmax(0, 1.35fr)
            minmax(300px, 0.85fr);
    }

    .bmh-services-layout {
        grid-template-columns: 1fr;
    }

    .bmh-institution-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .bmh-glance,
    .bmh-download-layout,
    .bmh-contact-layout {
        grid-template-columns: 1fr;
    }

    .bmh-footer__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}


@media (max-width: 950px) {
    .bmh-brandbar__inner {
        grid-template-columns:
            minmax(0, 1fr)
            minmax(230px, 260px);
        grid-template-rows: auto auto;

        gap: 8px 12px;
        padding-block: 10px;
    }

    .bmh-brand {
        grid-row: 1 / 3;
    }

    .bmh-brand img {
        width: 72px;
        height: 72px;
    }

    .bmh-brand strong {
        font-size: 18px;
    }

    .bmh-brand-copy > .site-urdu-name {
        font-size: 17px;
        line-height: 36px !important;
    }

    .bmh-header-search {
        grid-column: 2;
        grid-row: 1;

        width: 100%;
        max-width: 260px;
        justify-self: end;
    }

    .bmh-brand-actions {
        grid-column: 2;
        grid-row: 2;
        justify-self: end;
    }
}


@media (max-width: 900px) {
    .bmh-nav-menu .bmh-nav-link {
        padding-inline: 10px;

        font-size: 12px;
    }
}


@media (max-width: 950px) {
    .bmh-hero-grid {
        grid-template-columns: 1fr;
    }

    .bmh-gallery-card {
        height: 430px;
    }

    .bmh-updates-card {
        height: 500px;
    }

    .bmh-about {
        grid-template-columns: 1fr;
    }

    .bmh-about__visual {
        min-height: 220px;
    }

    .bmh-about__visual img {
        width: 125px;
        height: 125px;
    }

    .bmh-service-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .bmh-section {
        padding: 40px 0;
    }

    .bmh-section-head {
        align-items: flex-start;
    }

    .bmh-download-feature-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}


@media (max-width: 760px) {
    .bmh-nav__inner {
        display: block;

        min-height: 42px;
    }

    .bmh-nav-toggle {
        display: flex;

        min-height: 42px;
        padding-block: 8px;
    }

    .bmh-nav-menu {
        display: none;

        width: 100%;

        padding: 0 0 10px;

        gap: 2px;
    }

    .bmh-nav-menu.is-open {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .bmh-nav-menu .bmh-nav-link {
        justify-content: flex-start;

        width: 100%;
        min-height: 46px;

        padding: 11px 13px;

        font-size: 13px;
    }

    .bmh-nav-menu .bmh-nav-link i {
        width: 21px;

        font-size: 14px;
    }

    .bmh-nav-menu .bmh-nav-link::after {
        right: auto;
        bottom: 5px;
        left: 13px;

        width: 28px;

        transform: scaleX(0.4);
        transform-origin: left center;
    }

    .bmh-nav-menu .bmh-nav-link:hover::after,
    .bmh-nav-menu .bmh-nav-link:focus-visible::after,
    .bmh-nav-menu .bmh-nav-link.is-active::after {
        transform: scaleX(1);
    }
}


@media (max-width: 700px) {
    .bmh-topbar__inner {
        display: flex;
        flex-wrap: nowrap;

        min-height: auto;

        gap: 8px;
        padding-block: 4px;
    }

    .bmh-topbar__links {
        flex: 1 1 auto;

        display: flex;

        gap: 13px;

        min-width: 0;

        overflow-x: auto;

        white-space: nowrap;

        scrollbar-width: none;
    }

    .bmh-topbar__links::-webkit-scrollbar {
        display: none;
    }

    .bmh-topbar__links a {
        display: inline-flex;
        align-items: center;
        flex: 0 0 auto;

        min-height: 30px;

        font-size: 10.5px;
    }

    .bmh-social {
        flex: 0 0 auto;

        gap: 5px;
        margin-left: auto;
    }

    .bmh-social__label {
        display: none;
    }
}


@media (max-width: 680px) {
    .bmh-brandbar__inner {
        grid-template-columns: 1fr;
        grid-template-rows: auto;

        gap: 9px;
        padding-block: 10px;
    }

    .bmh-brand {
        width: auto;
        align-items: flex-start;
        justify-self: center;
        grid-row: auto;
    }

    .bmh-brand-copy {
        width: auto;
        max-width: calc(100vw - 84px);
    }

    .bmh-brand img {
        width: 64px;
        height: 64px;
    }

    .bmh-brand strong {
        font-size: 18px;
    }

    .bmh-brand-copy > .site-urdu-name {
        padding-left: 0;

        font-size: 16px;
        line-height: 34px !important;
    }

    .bmh-header-search {
        grid-column: auto;
        grid-row: auto;
        order: initial;

        width: 100%;
        max-width: 340px;
        justify-self: center;
    }

    .bmh-brand-actions {
        display: grid !important;
        grid-template-columns:
            minmax(0, 1fr)
            minmax(0, 1fr);

        width: min(100%, 340px);

        gap: 7px;
        justify-self: center;
        grid-column: auto;
        grid-row: auto;
    }

    .bmh-brand-actions .bmh-btn,
    .bmh-brand-actions .bmh-btn--outline {
        display: inline-flex !important;

        width: 100%;
        min-width: 0;
        min-height: 36px;

        padding: 7px 9px;

        font-size: 10.5px;

        white-space: normal;
        text-align: center;
    }

    .bmh-urgent__label {
        display: none;
    }

    .bmh-urgent__inner {
        grid-template-columns:
            32px
            minmax(0, 1fr)
            32px
            32px;

        min-height: 56px;

        gap: 4px;
    }

    .bmh-urgent__item {
        min-width: 72vw;
        max-width: 78vw;

        font-size: 12px;
        line-height: 1.7;

        display: -webkit-box;
        overflow: hidden;

        -webkit-box-orient: vertical;
        -webkit-line-clamp: 2;
    }
}


@media (max-width: 600px) {
    .bmh-brand strong {
        font-size: 18px;
    }

    .bmh-brand-copy > .site-urdu-name {
        font-size: 16px;
        line-height: 34px !important;
    }

    .bmh-hero-section {
        padding: 8px 0 32px;
    }

    .bmh-gallery-card {
        height: 390px;
    }

    .bmh-gallery-slide img {
        object-fit: cover;
        object-position: center;
    }

    .bmh-updates-card {
        height: 480px;
    }

    .bmh-gallery-slide__content {
        right: 18px;
        bottom: 58px;
        left: 18px;
    }

    .bmh-gallery-slide__content strong {
        font-size: 20px;
    }

    .bmh-gallery-controls {
        right: auto;
        bottom: 14px;
        left: 16px;
    }

    .bmh-gallery-dots {
        right: 16px;
        bottom: 28px;
        left: auto;
    }

    .bmh-section {
        padding: 34px 0;
    }

    .bmh-section-head {
        display: grid;
        grid-template-columns: 1fr;
    }

    .bmh-home .bmh-section-head {
        row-gap: 8px;
    }

    .bmh-section-head h2 {
        font-size: 25px;
    }

    .bmh-section-head > a {
        justify-self: start;
        margin-top: 0;
    }

    .bmh-about__content {
        max-height: none;

        padding: 20px;
    }

    .bmh-service-grid,
    .bmh-institution-grid {
        grid-template-columns: 1fr;
    }

    .bmh-download-feature-grid {
        grid-template-columns: 1fr;
    }

    .bmh-glance__content {
        padding: 23px;
    }

    .bmh-glance__stats {
        grid-template-columns: repeat(2, 1fr);
    }

    .bmh-footer__grid {
        grid-template-columns: 1fr;
    }

    .bmh-footer__bottom {
        display: block;
    }

    .bmh-footer__bottom span {
        display: block;

        margin-top: 5px;
    }
}

@media (max-width: 480px) {
    .bmh-social a {
        width: 27px;
        height: 27px;
    }

    .bmh-topbar__links {
        gap: 10px;
    }

    .bmh-brand img {
        width: 56px;
        height: 56px;
    }

    .bmh-brand strong {
        font-size: 17px;
        line-height: 1.08;
    }

    .bmh-brand-title {
        white-space: normal;
    }

    .bmh-brand-copy > .site-urdu-name {
        display: block;
        margin-left: 0;
        color: var(--bmh-green-800);
        font-size: 15px;
        line-height: 32px !important;
        text-align: center;
        white-space: nowrap;
    }
}


@media (max-width: 430px) {
    .bmh-nav-menu.is-open {
        grid-template-columns: 1fr;
    }

    .bmh-urgent__inner {
        grid-template-columns:
            28px
            minmax(0, 1fr)
            28px
            28px;

        gap: 3px;
    }

    .bmh-urgent__item {
        min-width: 70vw;
        max-width: 74vw;

        font-size: 11.5px;
    }

    .bmh-quick-grid,
    .bmh-glance__stats {
        grid-template-columns: 1fr;
    }

    .bmh-card-head {
        padding: 16px 14px 12px;
    }

    .bmh-card-head h2 {
        font-size: 19px;
    }
}


@media (prefers-reduced-motion: reduce) {
    .bmh-nav-menu .bmh-nav-link,
    .bmh-nav-menu .bmh-nav-link i,
    .bmh-card--corner-pattern::after,
    .bmh-download-feature::after {
        transition: none;
    }
}

/* =========================================================
   FINAL RESPONSIVE COMPONENT RULES
========================================================= */

@media (max-width: 1200px) {
    .bmh-institution-compact-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .bmh-services-directory-layout {
        grid-template-columns: minmax(310px, 340px) minmax(0, 1fr);
    }

    .bmh-service-directory-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .bmh-board-glance__summary,
    .bmh-board-glance__district-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .bmh-glance-breakdown-card__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 1100px) {
    .bmh-contact-layout-modern {
        grid-template-columns: minmax(0, 1fr) minmax(340px, 0.8fr);
    }

    .bmh-download-modern-layout {
        grid-template-columns: minmax(0, 2.3fr) minmax(250px, 0.8fr);
    }

    .bmh-download-primary-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .bmh-download-modern-layout,
    .bmh-contact-layout-modern,
    .bmh-board-hub__shell {
        grid-template-columns: 1fr;
    }

    .bmh-facebook-card {
        height: auto;
    }

    .bmh-download-modern-layout > *,
    .bmh-download-modern-content,
    .bmh-social-follow-card {
        min-height: 0;
        height: auto;
    }

    .bmh-board-hub__nav {
        grid-template-columns: repeat(3, minmax(190px, 1fr));
        overflow-x: auto;
        padding-bottom: 5px;
        scrollbar-width: none;
    }

    .bmh-board-hub__nav::-webkit-scrollbar {
        display: none;
    }

    .bmh-board-hub__map {
        margin: 14px 14px 0;
        padding: 18px;
        border-radius: 20px;
    }

    .bmh-board-hub__map-image {
        min-height: 300px;
    }

    .bmh-board-hub__content {
        padding: 14px;
    }

    .bmh-board-overview {
        height: auto;
    }

    /* Services tools: one stable tablet/mobile flow. */
    .bmh-services-browser__tools {
        display: block !important;
        width: 100%;
        min-height: 0 !important;
        height: auto !important;
        margin-bottom: 10px;
    }

    .bmh-service-filters {
        display: flex;
        flex-wrap: wrap;
        width: 100%;
        max-width: 100%;
        gap: 6px;
        padding-bottom: 0;
        overflow: visible;
    }

    .bmh-service-filters::-webkit-scrollbar {
        display: none;
    }

    .bmh-service-filter,
    .bmh-service-more-filter {
        flex: 0 0 auto;
    }

    .bmh-service-search {
        position: relative !important;
        display: flex !important;
        align-items: center !important;
        width: 100% !important;
        max-width: none !important;
        min-height: 44px !important;
        height: auto !important;
        margin: 12px 0 0 !important;
        padding: 0 !important;
        inset: auto !important;
        transform: none !important;
    }

    .bmh-service-search > i.fa-search {
        position: absolute !important;
        left: 14px !important;
        top: 50% !important;
        z-index: 3;
        margin: 0 !important;
        transform: translateY(-50%) !important;
        color: var(--bmh-green);
    }

    .bmh-service-search input {
        box-sizing: border-box !important;
        display: block !important;
        width: 100% !important;
        max-width: none !important;
        height: 44px !important;
        min-height: 44px !important;
        margin: 0 !important;
        padding: 0 42px 0 40px !important;
        border-radius: 12px;
    }

    .bmh-service-search button {
        box-sizing: border-box !important;
        position: absolute !important;
        right: 8px !important;
        top: 8px !important;
        margin: 0 !important;
        transform: none !important;
    }

    .bmh-service-directory-grid {
        margin-top: 16px !important;
    }
}

@media (max-width: 820px) {
    .bmh-services-directory-layout {
        grid-template-columns: 1fr;
    }

    .bmh-featured-services__list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .bmh-location-map iframe {
        height: 340px !important;
    }
}

@media (max-width: 767px) {
    /* Chairman legacy DB markup: compact image beside the text. */
    .bmh-board-chairman__database-content {
        max-height: none;
        overflow: visible;
    }

    .bmh-board-chairman__database-content .row {
        display: grid !important;
        grid-template-columns: 82px minmax(0, 1fr) !important;
        align-items: start;
        gap: 14px;
        width: 100%;
        margin: 0 !important;
    }

    .bmh-board-chairman__database-content .row > div {
        width: auto !important;
        max-width: none !important;
        flex: none !important;
        margin: 0 !important;
        padding: 0 !important;
        text-align: left !important;
    }

    .bmh-board-chairman__database-content .row > div:first-child {
        width: 82px !important;
    }

    .bmh-board-chairman__database-content img {
        display: block !important;
        float: none !important;
        width: 76px !important;
        height: 76px !important;
        max-width: 76px !important;
        margin: 0 !important;
        border-radius: 50% !important;
        object-fit: cover !important;
    }

    .bmh-board-chairman__database-content p {
        margin: 0 0 7px !important;
        font-size: 12px !important;
        line-height: 1.55 !important;
    }

}

@media (max-width: 700px) {
    .bmh-institution-section {
        padding-block: 30px;
    }

    .bmh-institution-compact-grid,
    .bmh-service-directory-grid {
        grid-template-columns: 1fr;
    }

    .bmh-institution-compact-card {
        grid-template-columns: 42px minmax(0, 1fr) 28px;
        min-height: 112px;
        gap: 11px;
        padding: 13px;
    }

    .bmh-board-glance {
        padding: 14px;
    }

    .bmh-board-glance__summary,
    .bmh-board-glance__district-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .bmh-board-glance__breakdown {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .bmh-download-modern-content {
        padding: 12px;
        gap: 10px;
    }

    .bmh-model-papers-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .bmh-facebook-card__body {
        padding: 12px;
    }
}

@media (max-width: 600px) {
    .bmh-section {
        padding-block: 30px;
    }

    .bmh-section-head {
        gap: 10px;
        margin-bottom: 14px;
    }

    .bmh-featured-services {
        padding: 18px;
    }

    .bmh-featured-services__head p {
        display: none;
    }

    .bmh-featured-services__list {
        grid-template-columns: 1fr;
        gap: 5px;
        margin-top: 15px;
    }

    .bmh-board-hub__nav {
        grid-template-columns: repeat(3, 170px);
        gap: 7px;
    }

    .bmh-board-hub__tab {
        min-height: 66px;
        padding: 9px 10px;
    }

    .bmh-board-hub__tab-icon {
        flex-basis: 35px;
        width: 35px;
        height: 35px;
    }

    .bmh-board-hub__map {
        margin: 10px 10px 0;
        padding: 15px;
    }

    .bmh-board-hub__map-image {
        min-height: 230px;
        padding: 5px;
    }

    .bmh-board-hub__content {
        padding: 10px;
    }

    .bmh-board-chairman,
    .bmh-board-glance,
    .bmh-board-directory {
        padding: 14px;
    }

    .bmh-board-directory__grid {
        grid-template-columns: 1fr;
    }

    .bmh-contact-card-head {
        padding: 17px 18px 14px;
    }

    .bmh-contact-directory {
        padding: 18px;
    }

    .bmh-contact-directory > .row,
    .bmh-contact-directory .row:first-child {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .bmh-contact-office-grid {
        grid-template-columns: 1fr;
    }

    .bmh-location-map iframe {
        height: 280px !important;
        min-height: 280px;
    }

    .bmh-location-details {
        grid-template-columns: 1fr;
    }

    .bmh-location-detail + .bmh-location-detail {
        border-top: 1px solid var(--bmh-line);
        border-left: 0;
    }
}

@media (max-width: 560px) {
    .bmh-download-primary-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .bmh-download-primary-card {
        min-height: 122px;
        padding: 12px !important;
    }

    .bmh-download-secondary-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .bmh-board-chairman__database-content .row {
        grid-template-columns: 64px minmax(0, 1fr) !important;
        gap: 10px;
    }

    .bmh-board-chairman__database-content .row > div:first-child {
        width: 64px !important;
    }

    .bmh-board-chairman__database-content img {
        width: 60px !important;
        height: 60px !important;
        max-width: 60px !important;
    }

    .bmh-model-papers-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 420px) {
    .bmh-board-glance__summary,
    .bmh-board-glance__district-grid {
        grid-template-columns: 1fr;
    }

    .bmh-model-papers-grid {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    .bmh-institution-compact-card,
    .bmh-institution-compact-card::after,
    .bmh-institution-compact-card__icon,
    .bmh-institution-compact-card__arrow,
    .bmh-service-directory-card,
    .bmh-service-directory-card::after,
    .bmh-glance-summary-card,
    .bmh-glance-district-card,
    .bmh-glance-breakdown-card {
        transition: none !important;
    }
}

/* =========================================================
   FINAL HOMEPAGE UI REFINEMENT - RESPONSIVE
========================================================= */


/* Tablet: keep some compactness, but not desktop density */

@media (min-width: 601px) and (max-width: 900px) {

    .bmh-section {
        padding-top: 38px;
        padding-bottom: 38px;
    }

    .bmh-section-head {
        margin-bottom: 14px;
    }

    .bmh-section-head p {
        font-size: 14px;
    }


    /* Institution cards */

    .bmh-institution-compact-card {
        min-height: 112px;

        padding:
            12px
            13px;
    }


    /* Contact */

    .bmh-contact-office-item {
        min-height: 80px;

        padding:
            11px
            12px;
    }


    /* Footer */

    .bmh-footer__grid > div > a:not(.bmh-brand) {
        font-size: 12.5px;
    }

}

/* Mobile should remain comfortably spaced and readable */

@media (max-width: 600px) {

    .bmh-section {
        padding-top: 30px;
        padding-bottom: 30px;
    }


    .bmh-section-head p {
        font-size: 13.5px;
        line-height: 1.5;
    }


    .bmh-institution-compact-card__content small {
        font-size: 10px;
    }


    /*
     * Do not over-compress touch targets on mobile.
     */

    .bmh-contact-office-item {
        min-height: 92px;

        padding:
            13px
            14px;
    }


    .bmh-footer {
        padding:
            30px
            0
            15px;
    }


    .bmh-footer__grid > div > a:not(.bmh-brand) {
        font-size: 13px;

        padding:
            5px
            0;
    }


    .bmh-footer__bottom {
        font-size: 11.5px;
    }

}


/* =========================================================
   CHAIRMAN MESSAGE - STACK EARLIER ON MEDIUM SCREENS
========================================================= */

@media (max-width: 980px) {

    .bmh-board-chairman__database-content .row {
        display: block !important;

        width: 100% !important;

        margin: 0 !important;
    }


    .bmh-board-chairman__database-content .row > div {
        width: 100% !important;
        max-width: 100% !important;

        flex: none !important;

        margin: 0 !important;
        padding: 0 !important;
    }


    /* Chairman image on top */

    .bmh-board-chairman__database-content .row > div:first-child {
        display: flex !important;

        justify-content: center;
        align-items: center;

        width: 100% !important;

        margin-bottom: 14px !important;

        text-align: center !important;
    }


    .bmh-board-chairman__database-content img {
        display: block !important;

        float: none !important;

        width: 130px !important;
        height: 130px !important;
        max-width: 130px !important;

        margin: 0 auto !important;

        border-radius: 50% !important;

        object-fit: cover !important;
    }


    /* Message below */

    .bmh-board-chairman__database-content .row > div:nth-child(2) {
        width: 100% !important;

        text-align: left !important;
    }


    .bmh-board-chairman__database-content p {
        font-size: 13px !important;
        line-height: 1.6 !important;
    }

}


/* Smaller mobile screens */

@media (max-width: 600px) {

    .bmh-board-chairman__database-content img {
        width: 150px !important;
        height: 150px !important;
        max-width: 150px !important;
    }

}

@media (max-width: 768px) {
    .bmh-inner-page-shell {
        padding: 12px 0 24px;
    }

    .bmh-inner-content .section-title {
        margin-bottom: 10px;
        padding: 9px 12px;
    }
}

@media (max-width: 480px) {
    .bmh-inner-page-shell {
        padding-top: 10px;
    }
}

/* Compact shared footer */
@media (max-width: 700px) {
    .bmh-footer {
        padding: 22px 0 12px;
    }

    .bmh-footer__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 20px 14px;
    }

    .bmh-footer__brand {
        display: grid;
        grid-column: 1 / -1;
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: center;
        gap: 12px;
        padding-bottom: 14px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.14);
    }

    .bmh-footer__brand .bmh-brand {
        min-width: 0;
    }

    .bmh-footer__brand .bmh-brand img {
        width: 50px;
        height: 50px;
        padding: 5px;
        border-radius: 10px;
    }

    .bmh-footer__brand .bmh-brand strong {
        font-size: 1rem;
        line-height: 1.2;
    }

    .bmh-footer__brand .bmh-brand small {
        margin-top: 2px;
        font-size: 0.68rem;
        line-height: 1.35;
    }

    .bmh-footer__social {
        flex-wrap: nowrap;
        margin-top: 0;
    }

    .bmh-footer__social a {
        width: 30px;
        height: 30px;
    }

    .bmh-footer__grid h3 {
        margin-bottom: 7px;
        font-size: 0.9rem;
        line-height: 1.3;
    }

    .bmh-footer__grid > div:nth-child(4) {
        display: grid;
        grid-column: 1 / -1;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        column-gap: 14px;
    }

    .bmh-footer__grid > div:nth-child(4) h3 {
        grid-column: 1 / -1;
    }

    .bmh-footer__grid > div > a:not(.bmh-brand) {
        padding: 3px 0;
        font-size: 0.75rem;
        line-height: 1.4;
    }

    .bmh-footer__bottom {
        display: grid;
        gap: 4px;
        margin-top: 18px;
        padding-top: 11px;
        font-size: 0.68rem;
        line-height: 1.45;
    }

    .bmh-footer__bottom span {
        margin-top: 0;
    }
}

@media (max-width: 380px) {
    .bmh-footer__brand {
        grid-template-columns: 1fr;
    }

    .bmh-footer__social {
        justify-self: start;
    }
}


@media (max-width: 820px) {
    .bmh-home section:not(.bmh-urgent):not(.bmh-hero) {
        padding-block: 15px;
    }

    .bmh-home :is(.bmh-section-title, .bmh-services-directory__heading, .bmh-institution-corner__heading, .bmh-contact__heading, .bmh-board-hub__heading) {
        font-size: 1.375rem;
        line-height: 1.18;
    }

    .bmh-home :is(.bmh-section-intro, .bmh-services-directory__intro, .bmh-institution-corner__intro, .bmh-contact__intro),
    .bmh-home :is(.bmh-urgent__item, .bmh-footer, .bmh-footer a, .bmh-institution-corner__card, .bmh-contact-card) {
        font-size: 0.8125rem;
        line-height: 1.5;
    }

    .bmh-home :is(button, .btn, [role="button"], input, select, textarea, .bmh-service-tabs__button, .bmh-mobile-nav-toggle, .bmh-mobile-updates-toggle):not(.bmh-carousel-control):not([data-bmh-gallery-dot]) {
        min-height: 44px;
    }

    .bmh-home .bmh-social-link {
        width: 44px;
        height: 44px;
    }

    .bmh-home .bmh-mobile-updates-toggle {
        color: var(--bmh-white);
    }

    .bmh-home :is(.bmh-featured-services__item, .bmh-featured-service-link) {
        min-height: 64px;
    }

    .bmh-home .bmh-featured-service-title {
        font-size: 0.8375rem;
        line-height: 1.35;
    }

    .bmh-home :is(#bmh-services, #services) .bmh-featured-service-link__main {
        min-height: 44px !important;
    }
}

@media (max-width: 479px) {
    .bmh-home section:not(.bmh-urgent):not(.bmh-hero) {
        padding-block: 15px;
    }

}
.bmh-shell .bmh-urgent__item,
.bmh-shell .bmh-urgent__item * {
    font-family: var(--bmh-font-urdu) !important;
    font-weight: 400;
}

.bmh-common-card-grid {
    align-items: stretch;
    grid-auto-rows: auto !important;
}

.bmh-common-card {
    --bmh-common-card-height: 158px;
    --bmh-common-card-content-height: 88px;
    --cards-footer-height: 40px;
    position: relative;
    display: flex !important;
    box-sizing: border-box;
    min-width: 0;
    height: var(--bmh-common-card-height) !important;
    min-height: var(--bmh-common-card-height) !important;
    max-height: var(--bmh-common-card-height) !important;
    flex-direction: column;
    padding: 10px 12px 0 !important;
    overflow: hidden;
    border: 1px solid var(--bmh-border);
    border-radius: var(--bmh-radius);
    background: var(--bmh-white);
    box-shadow: var(--bmh-shadow);
    color: var(--bmh-ink);
    transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.bmh-common-card[hidden] {
    display: none !important;
}

.bmh-common-card--roomy {
    --bmh-common-card-height: 190px;
    --bmh-common-card-content-height: 117px;
}

.bmh-common-card__head {
    position: relative !important;
    z-index: 1;
    display: grid !important;
    grid-template-columns: 38px minmax(0, 1fr) 32px !important;
    width: 100% !important;
    min-width: 0;
    min-height: 40px;
    align-items: start !important;
    gap: 8px !important;
    text-align: left;
}

.bmh-common-card__icon,
.bmh-common-card__arrow {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 12px !important;
    background: var(--bmh-green-soft) !important;
    color: var(--bmh-green-dark) !important;
}

.bmh-common-card__icon {
    width: 38px !important;
    height: 38px !important;
    font-size: 15px !important;
}

.bmh-common-card__arrow {
    width: 32px !important;
    height: 32px !important;
    justify-self: end;
    text-decoration: none !important;
    transition: background-color 0.18s ease, color 0.18s ease;
}

.bmh-common-card__arrow:hover,
.bmh-common-card__arrow:focus-visible {
    background: var(--bmh-green) !important;
    color: var(--bmh-white) !important;
}

.bmh-common-card:has(> .bmh-common-card__badge) .bmh-common-card__arrow {
    margin-top: 18px;
}

.bmh-common-card__heading,
.bmh-common-card__content,
.bmh-common-card__middle {
    min-width: 0;
}

.bmh-common-card__heading {
    width: 100%;
    padding-top: 1px;
    text-align: left;
}

.bmh-common-card__eyebrow {
    display: block;
    margin: 0 0 1px;
    color: var(--bmh-red) !important;
    font-family: var(--bmh-font-ui) !important;
    font-size: 10px !important;
    font-weight: 700 !important;
    line-height: 1.15 !important;
    text-transform: uppercase;
}

.bmh-common-card__title {
    display: -webkit-box !important;
    width: 100%;
    max-height: 35px;
    overflow: hidden;
    color: var(--bmh-green-dark) !important;
    font-family: var(--bmh-font-ui) !important;
    font-size: 14px !important;
    font-weight: 750 !important;
    line-height: 1.25 !important;
    text-align: left;
    text-decoration: none !important;
    overflow-wrap: anywhere;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.bmh-common-card__badge {
    position: absolute;
    top: 5px;
    right: 15px;
    z-index: 2;
    display: inline-flex;
    min-width: 28px;
    min-height: 16px;
    align-items: center;
    justify-content: center;
    padding: 2px 6px;
    border-radius: 999px;
    background: var(--bmh-red);
    color: var(--bmh-white);
    font-family: var(--bmh-font-ui);
    font-size: 9px;
    font-weight: 750;
    line-height: 1;
}

.cards_w_footer {
    position: relative;
    overflow: hidden;
}

.cards_w_footer__content {
    position: absolute !important;
    right: 0 !important;
    bottom: 0 !important;
    left: 0 !important;
    display: flex !important;
    box-sizing: border-box;
    width: 100% !important;
    height: var(--bmh-common-card-content-height) !important;
    min-height: 0 !important;
    max-height: var(--bmh-common-card-content-height) !important;
    flex-direction: column !important;
    gap: 4px;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    border: 0 !important;
    background: transparent !important;
}

.bmh-common-card__middle {
    overflow: hidden;
    background: transparent !important;
    color: var(--bmh-green-dark);
    font-family: var(--bmh-font-ui) !important;
    font-size: 12px !important;
    line-height: 1.35 !important;
    text-align: center;
}

.cards_w_footer__content > :not(.cards_w_footer__footer) {
    align-self: center;
}

.cards_w_footer__middle {
    display: flex !important;
    width: 100%;
    min-height: 48px;
    flex: 1 1 auto;
    align-items: center;
    justify-content: center;
    gap: 2px !important;
    padding: 5px 10px !important;
}

.bmh-common-card__middle--split {
    flex-direction: column;
    gap: 3px;
}

.bmh-common-card__middle-label,
.bmh-common-card__middle-actions,
.bmh-card-action-note {
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
}

.bmh-card-action-note {
    display: block;
    flex: 1 0 100%;
    text-align: center;
}

.cards_w_footer__middle .btn {
    display: inline-flex !important;
    max-width: 100% !important;
    min-height: 26px !important;
    align-items: center;
    justify-content: center;
    margin: 0 !important;
    padding: 4px 8px !important;
    overflow: hidden !important;
    border: 1px solid var(--bmh-border) !important;
    border-radius: 8px !important;
    background: var(--bmh-green-50) !important;
    color: var(--bmh-green-dark) !important;
    font-family: var(--bmh-font-ui) !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    line-height: 1.25 !important;
    text-overflow: ellipsis;
    white-space: nowrap !important;
}

.cards_w_footer__footer {
    display: grid !important;
    width: 100% !important;
    height: var(--cards-footer-height) !important;
    min-height: var(--cards-footer-height) !important;
    max-height: var(--cards-footer-height) !important;
    flex: 0 0 var(--cards-footer-height) !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 0 !important;
    margin: auto 0 0 !important;
    padding: 0 !important;
    overflow: hidden;
    border: 0 !important;
    border-top: 1px solid var(--bmh-border) !important;
    border-radius: 0 !important;
    background: rgba(234, 245, 239, 0.35) !important;
}

body .cards_w_footer .cards_w_footer__footer > :is(a, button, .btn) {
    position: relative !important;
    inset: auto !important;
    display: flex !important;
    box-sizing: border-box !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    height: var(--cards-footer-height) !important;
    min-height: var(--cards-footer-height) !important;
    max-height: var(--cards-footer-height) !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 5px 28px 5px 10px !important;
    overflow: hidden !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: var(--bmh-green-dark) !important;
    font-family: var(--bmh-font-ui) !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    text-align: center !important;
    text-decoration: none !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
}

body .cards_w_footer .cards_w_footer__footer > :is(a, button, .btn)::after {
    position: absolute;
    top: 50%;
    right: 10px;
    display: block !important;
    content: "\2192";
    font-size: 12px;
    line-height: 1;
    transform: translateY(-50%);
}

body .cards_w_footer .cards_w_footer__footer > :is(a, button, .btn) + :is(a, button, .btn) {
    border-left: 1px solid var(--bmh-border) !important;
}

.cards_w_footer__footer > :is(a, button, .btn):only-child {
    grid-column: 1 / -1;
}

body .cards_w_footer .cards_w_footer__footer > :is(a, button, .btn):hover,
body .cards_w_footer .cards_w_footer__footer > :is(a, button, .btn):focus-visible {
    background: var(--bmh-green-100) !important;
    color: var(--bmh-green-deep) !important;
}

.bmh-card-hover-lift {
    transition: border-color 0.22s ease, box-shadow 0.22s ease, transform 0.22s ease !important;
}

.bmh-card-hover-lift__icon,
.bmh-card-hover-lift__arrow {
    transition: background-color 0.22s ease, color 0.22s ease, transform 0.22s ease !important;
}

@media (hover: hover) {
    .bmh-card-hover-lift:hover {
        border-color: rgba(15, 103, 66, 0.28) !important;
        box-shadow: var(--bmh-shadow-hover) !important;
        transform: translateY(-3px) !important;
    }

    .bmh-card-hover-lift:hover .bmh-card-hover-lift__icon {
        background: var(--bmh-green) !important;
        color: var(--bmh-white) !important;
        transform: translateY(-2px) !important;
    }

    .bmh-card-hover-lift:hover .bmh-card-hover-lift__arrow {
        background: var(--bmh-green) !important;
        color: var(--bmh-white) !important;
        transform: translateX(3px) !important;
    }
}

.bmh-card-hover-lift:focus-visible,
.bmh-card-hover-lift:focus-within {
    border-color: rgba(15, 103, 66, 0.28) !important;
    box-shadow: var(--bmh-shadow-hover) !important;
    transform: translateY(-3px) !important;
}

.bmh-card-hover-lift:focus-visible .bmh-card-hover-lift__icon,
.bmh-card-hover-lift:focus-within .bmh-card-hover-lift__icon {
    background: var(--bmh-green) !important;
    color: var(--bmh-white) !important;
    transform: translateY(-2px) !important;
}

.bmh-card-hover-lift:focus-visible .bmh-card-hover-lift__arrow,
.bmh-card-hover-lift:focus-within .bmh-card-hover-lift__arrow {
    background: var(--bmh-green) !important;
    color: var(--bmh-white) !important;
    transform: translateX(3px) !important;
}

.bmh-common-card--roomy .bmh-common-card__content > :not(.cards_w_footer__footer) {
    margin-right: 10px;
    margin-left: 10px;
}

.bmh-common-card--roomy .bmh-application-meta {
    gap: 3px;
    margin-top: 0;
    margin-bottom: 0;
    padding: 6px 9px;
    border-radius: 10px;
    background: var(--bmh-green-soft);
    font-size: 12px;
    line-height: 1.3;
}

.bmh-common-card--roomy .bmh-application-status {
    gap: 6px;
    margin-top: 0;
    margin-bottom: 0;
    font-size: 12px;
}

.bmh-featured-service-link__main > span {
    display: -webkit-box !important;
    overflow: hidden !important;
    font-size: 14px !important;
    color: var(--bmh-white) !important;
    font-weight: 750 !important;
    padding-left: 0 !important;
    line-height: 1.3 !important;
    white-space: normal !important;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.bmh-featured-service-link__main > i:first-child {
    position: static !important;
    align-self: center !important;
    width: 22px !important;
    font-size: 16px !important;
    transform: translateY(-2px);
}

.bmh-featured-card-actions {
    padding: 0 12px 10px;
}

.bmh-featured-card-actions .service-w-button,
.bmh-featured-card-actions .service-w-button:has(.btn:nth-of-type(3)),
.bmh-featured-card-actions .service-w-button:has(.btn:only-of-type) {
    display: flex !important;
    width: 100% !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
    gap: 2px !important;
    overflow: hidden !important;
}

.bmh-featured-card-actions .service-w-button .btn,
.bmh-featured-card-actions .service-w-button .btn:nth-last-of-type(n+3),
.bmh-featured-card-actions .service-w-button .btn:nth-last-of-type(-n+2) {
    position: static !important;
    inset: auto !important;
    display: block !important;
    width: auto !important;
    max-width: 100% !important;
    min-height: 22px !important;
    flex: 0 1 auto !important;
    margin: 0 !important;
    padding: 3px 7px !important;
    overflow: hidden !important;
    border: 1px solid rgba(255, 255, 255, 0.14) !important;
    border-radius: 999px !important;
    background: rgba(255, 255, 255, 0.10) !important;
    color: rgba(255, 255, 255, 0.9) !important;
    font-size: 12px !important;
    line-height: 1.25 !important;
    overflow-wrap: anywhere !important;
    text-overflow: clip !important;
    white-space: normal !important;
}

.bmh-card-pill,
.cards_w_footer__middle .btn.bmh-card-pill,
.bmh-featured-card-actions .service-w-button .btn.bmh-card-pill {
    display: inline-flex !important;
    width: auto !important;
    max-width: 100% !important;
    min-height: 24px !important;
    flex: 0 1 auto !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 2px 7px !important;
    overflow: hidden !important;
    border-radius: 999px !important;
    font-family: var(--bmh-font-ui) !important;
    font-size: 12px !important;
    font-weight: 500 !important;
    line-height: 1.25 !important;
    text-decoration: none !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
}

.cards_w_footer__middle .btn.bmh-card-pill {
    border: 1px solid transparent !important;
    background: var(--bmh-surface-2) !important;
    color: var(--bmh-muted) !important;
}

.bmh-featured-card-actions .service-w-button .btn.bmh-card-pill {
    border: 1px solid transparent !important;
    background: rgba(255, 255, 255, .07) !important;
    color: rgba(255, 255, 255, .82) !important;
}

.cards_w_footer__middle .btn.bmh-card-pill:hover,
.cards_w_footer__middle .btn.bmh-card-pill:focus-visible {
    border-color: transparent !important;
    background: var(--bmh-green-100) !important;
    color: var(--bmh-green-900) !important;
}

.bmh-featured-card-actions .service-w-button .btn.bmh-card-pill:hover,
.bmh-featured-card-actions .service-w-button .btn.bmh-card-pill:focus-visible {
    border-color: transparent !important;
    background: rgba(255, 255, 255, .12) !important;
    color: var(--bmh-white) !important;
}

.bmh-shell .bmh-btn--outline:hover,
.bmh-shell .bmh-btn--outline:focus-visible {
    border-color: var(--bmh-green-900) !important;
    background: var(--bmh-green-900) !important;
    color: var(--bmh-white) !important;
}

.bmh-shell .bmh-btn--outline:is(:hover, :focus-visible) :is(i, span) {
    color: currentColor !important;
}

@media (max-width: 820px) {
    .bmh-common-card--compact {
        --bmh-common-card-height: 160px;
        --bmh-common-card-content-height: 92px;
        --cards-footer-height: 44px;
        padding-right: 11px !important;
        padding-left: 11px !important;
    }

    .bmh-featured-service-link__main {
        grid-template-columns: 20px minmax(0, 1fr) 14px !important;
        gap: 8px !important;
        padding: 10px 11px 8px !important;
    }
}

@media (max-width: 480px) {
    .bmh-common-card__head {
        grid-template-columns: 36px minmax(0, 1fr) 32px !important;
        gap: 7px !important;
    }

    .bmh-common-card__icon {
        width: 36px !important;
        height: 36px !important;
    }

    .bmh-featured-service-link__main {
        padding-inline: 9px !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    .bmh-common-card,
    .bmh-common-card__arrow,
    .bmh-card-hover-lift,
    .bmh-card-hover-lift__icon,
    .bmh-card-hover-lift__arrow {
        transition: none;
    }

    .bmh-common-card:hover,
    .bmh-common-card:focus-within,
    .bmh-card-hover-lift:hover,
    .bmh-card-hover-lift:focus-visible,
    .bmh-card-hover-lift:focus-within,
    .bmh-card-hover-lift:hover .bmh-card-hover-lift__icon,
    .bmh-card-hover-lift:hover .bmh-card-hover-lift__arrow,
    .bmh-card-hover-lift:focus-visible .bmh-card-hover-lift__icon,
    .bmh-card-hover-lift:focus-visible .bmh-card-hover-lift__arrow,
    .bmh-card-hover-lift:focus-within .bmh-card-hover-lift__icon,
    .bmh-card-hover-lift:focus-within .bmh-card-hover-lift__arrow {
        transform: none;
    }
}
.bmh-action-pill {
    box-sizing: border-box;
    min-height: 36px !important;
    gap: 7px !important;
    padding: 8px 13px !important;
    border-radius: 999px !important;
    font-size: 11px !important;
    line-height: 1 !important;
}

/* Shared visual patterns for the Modern theme. */

.bmh-card-head__action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 32px;
    gap: 6px;
    padding: 6px 10px;
    border-radius: 999px;
    background: var(--bmh-green-50);
    color: var(--bmh-green-900) !important;
    font-size: 12px !important;
    font-weight: 750;
    line-height: 1;
    white-space: nowrap;
    transition: background-color .2s ease, color .2s ease;
}

.bmh-card-head__action:hover,
.bmh-card-head__action:focus-visible {
    background: var(--bmh-green-900);
    color: var(--bmh-white) !important;
}

.bmh-nav-utility {
    display: none;
}

.bmh-home .bmh-section {
    padding-block: var(--bmh-space-section-desktop);
}

.bmh-home .bmh-section-head {
    margin-bottom: var(--bmh-space-heading-content);
}

.bmh-home .bmh-section-head p,
.bmh-home .bmh-about-rich-content,
.bmh-home .bmh-about-rich-content p {
    font-size: 14px;
    line-height: 1.6;
}

.bmh-home .bmh-tab-list button,
.bmh-home .bmh-update-item,
.bmh-home .bmh-updates-footer a {
    font-size: 13px;
}

.bmh-home .bmh-update-item small,
.bmh-home .bmh-update-date,
.bmh-home .bmh-update-new {
    font-size: 12px;
}

.bmh-home .bmh-institution-compact-grid {
    gap: var(--bmh-space-card-gap);
}

.bmh-home .bmh-institution-compact-card__content strong {
    display: -webkit-box;
    overflow: hidden;
    font-size: 14px;
    line-height: 1.3;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.bmh-home .bmh-institution-compact-card__content small {
    display: -webkit-box;
    overflow: hidden;
    font-size: 12px;
    line-height: 1.45;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.bmh-home :is(
    .bmh-institution-compact-card__icon,
    .bmh-download-card-icon,
    .bmh-contact-card-head__icon,
    .bmh-location-detail__icon
) {
    border-radius: 10px;
}

.bmh-home #bmh-services .bmh-featured-service-actions .btn {
    border-color: transparent !important;
    background: rgba(255, 255, 255, .11) !important;
    color: rgba(255, 255, 255, .94) !important;
}

.bmh-home #bmh-services .bmh-featured-service-actions .btn:hover,
.bmh-home #bmh-services .bmh-featured-service-actions .btn:focus-visible {
    background: rgba(255, 255, 255, .2) !important;
    color: var(--bmh-white) !important;
}

.bmh-home .bmh-institution-profile.is-ready {
    border: 1px solid var(--bmh-border);
    background: var(--bmh-surface-2);
    box-shadow: var(--bmh-shadow-sm);
}

.bmh-home .bmh-institution-profile .bmh-board-hub__map {
    border: 1px solid var(--bmh-border);
    background: var(--bmh-white);
}

.bmh-home .bmh-institution-profile .bmh-board-glance {
    border: 0;
    background: transparent;
    color: var(--bmh-ink);
}

.bmh-home .bmh-board-glance__subhead span {
    color: var(--bmh-coral-700);
}

.bmh-home .bmh-board-glance__subhead strong {
    color: var(--bmh-green-900);
}

.bmh-home #board-at-a-glance :is(
    .bmh-glance-summary-card small,
    .bmh-glance-district-card__stats small,
    .bmh-glance-district-card__total span,
    .bmh-glance-breakdown-card__head small,
    .bmh-glance-breakdown-card__grid small
) {
    font-size: 11px;
    line-height: 1.35;
}

.bmh-home #board-at-a-glance :is(
    .bmh-glance-district-card__stats strong,
    .bmh-glance-breakdown-card__grid strong
) {
    font-size: 14px;
}

.bmh-home .bmh-social-follow-action {
    border-color: var(--bmh-border) !important;
    background: var(--bmh-green-50) !important;
    color: var(--bmh-green-900) !important;
}

.bmh-home .bmh-social-follow-action:hover,
.bmh-home .bmh-social-follow-action:focus-visible {
    border-color: var(--bmh-green-800) !important;
    background: var(--bmh-green-800) !important;
    color: var(--bmh-white) !important;
}

.bmh-home .bmh-facebook-card__body,
.bmh-home .bmh-deferred-embed--facebook {
    min-height: 240px;
    max-height: 300px;
}

.bmh-home .bmh-deferred-embed--facebook iframe {
    width: 100%;
    height: 300px;
}

.bmh-home .bmh-contact-office-grid {
    gap: 8px;
}

.bmh-home .bmh-contact-office-item {
    min-height: 72px;
    border-radius: 12px;
    background: var(--bmh-surface-2);
    box-shadow: none;
}

.bmh-home .bmh-contact-office-item h4 {
    font-size: 14px;
}

.bmh-home .bmh-contact-office-item a,
.bmh-home .bmh-location-detail__content {
    font-size: 12px;
}

.bmh-footer__grid {
    gap: 28px;
}

.bmh-footer__grid h3 {
    font-size: 16px;
}

.bmh-footer__grid > div > a:not(.bmh-brand) {
    min-height: 34px;
    padding-block: 6px;
    font-size: 13px;
}

.bmh-footer__bottom {
    font-size: 12px;
}

@media (min-width: 1101px) {
    .bmh-home .bmh-hero-grid {
        grid-template-columns: minmax(0, 1.85fr) minmax(360px, 1fr);
    }
}

@media (max-width: 900px) {
    .bmh-home .bmh-section {
        padding-block: var(--bmh-space-section-tablet);
    }

    .bmh-home .bmh-about-rich-content,
    .bmh-home .bmh-about-rich-content p {
        font-size: 14px;
    }
}

@media (max-width: 760px) {
    .bmh-topbar {
        display: none;
    }

    .bmh-nav-utility {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        width: 100%;
        padding: 8px;
        border-top: 1px solid rgba(255, 255, 255, .12);
    }

    .bmh-nav-utility a {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-height: 40px;
        padding: 7px 8px;
        color: rgba(255, 255, 255, .9);
        font-size: 12px;
    }

    .bmh-home .bmh-section {
        padding-block: var(--bmh-space-section-mobile);
    }

    .bmh-home .bmh-section-head {
        row-gap: 8px;
    }

    .bmh-home .bmh-facebook-card__body,
    .bmh-home .bmh-deferred-embed--facebook {
        min-height: 190px;
        max-height: 230px;
    }

    .bmh-home .bmh-deferred-embed--facebook iframe {
        height: 230px;
    }
}

@media (max-width: 600px) {
    .bmh-home .bmh-featured-services__list {
        display: flex;
        gap: 8px;
        overflow-x: auto;
        padding-bottom: 8px;
        scroll-snap-type: x proximity;
        scrollbar-width: thin;
    }

    .bmh-home .bmh-featured-services__list > .bmh-featured-service-link {
        flex: 0 0 min(82vw, 310px);
        scroll-snap-align: start;
    }

    .bmh-home .bmh-contact-office-grid {
        grid-template-columns: 1fr;
    }

    .bmh-home .bmh-board-chairman__database-content img {
        width: 128px !important;
        height: 128px !important;
        max-width: 128px !important;
    }

    .bmh-home .bmh-board-chairman__database-content .row > div:first-child {
        margin-bottom: 10px;
    }

    .bmh-footer__grid {
        gap: 22px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .bmh-card-head__action {
        transition: none;
    }
}
@supports (content-visibility: auto) {
    .bmh-home > #bmh-board,
    .bmh-home > #bmh-services,
    .bmh-home > #bmh-institutions,
    .bmh-home > #board-at-a-glance,
    .bmh-home > #bmh-downloads,
    .bmh-home > #bmh-contact {
        content-visibility: auto;
        contain-intrinsic-size: auto 760px;
    }
}

.bmh-tab-loading {
    margin: 0;
    padding: 32px 20px;
    color: var(--bmh-color-text-muted);
    text-align: center;
}
