/*
 * Site-wide scroll areas for recurring "how we work" and service-detail cards.
 * Card icons and headings stay visible; descriptive copy and feature lists scroll.
 */
.models-grid {
    align-items: stretch !important;
}

.tac-sitewide-scroll-card {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    align-self: stretch !important;
    min-width: 0 !important;
    min-height: 0 !important;
    height: auto !important;
    overflow: visible !important;
}

.models-grid > .tac-sitewide-scroll-card,
.swiper-slide > .tac-sitewide-scroll-card {
    height: 100% !important;
}

.tac-sitewide-scroll-card > .model-icon,
.tac-sitewide-scroll-card > .bookx-card__icon {
    display: block;
    flex: 0 0 auto !important;
    min-width: 0 !important;
}

.tac-sitewide-scroll-card > h3 {
    display: flex !important;
    align-items: center !important;
    flex: 0 0 auto !important;
    min-width: 0 !important;
    min-height: 54px !important;
    margin-bottom: 12px !important;
    line-height: 1.2 !important;
    overflow-wrap: break-word !important;
}

.tac-sitewide-scroll-content {
    box-sizing: border-box !important;
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    height: 210px !important;
    min-height: 210px !important;
    max-height: 210px !important;
    flex: 0 0 210px !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    padding: 0 12px 0 0 !important;
    margin: 0 !important;
    scrollbar-width: thin !important;
    scrollbar-color: #c9a84c #f5efe5 !important;
    scrollbar-gutter: stable !important;
    overscroll-behavior-y: contain !important;
    -webkit-overflow-scrolling: touch;
    overflow-wrap: break-word !important;
    word-break: normal !important;
    text-align: left !important;
    line-height: 1.65 !important;
}

.tac-sitewide-scroll-content > p {
    display: block !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    margin: 0 0 10px !important;
    padding: 0 !important;
    overflow: visible !important;
    line-height: 1.65 !important;
    text-align: left !important;
}

.tac-sitewide-scroll-content > p:last-child {
    margin-bottom: 0 !important;
}

.tac-sitewide-scroll-content > ul,
.tac-sitewide-scroll-content > ol {
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    overflow: visible !important;
}

.tac-sitewide-scroll-content li {
    max-width: 100%;
    overflow-wrap: break-word !important;
    word-break: normal !important;
}

@supports selector(::-webkit-scrollbar) {
    .tac-sitewide-scroll-content {
        scrollbar-width: auto !important;
        scrollbar-color: auto !important;
    }

    .tac-sitewide-scroll-content::-webkit-scrollbar {
        width: 7px;
    }

    .tac-sitewide-scroll-content::-webkit-scrollbar-track {
        background: #f5efe5;
        border-radius: 8px;
    }

    .tac-sitewide-scroll-content::-webkit-scrollbar-thumb {
        background: #c9a84c;
        border-radius: 8px;
    }

    .tac-sitewide-scroll-content::-webkit-scrollbar-button {
        display: none;
        width: 0;
        height: 0;
    }
}

.tac-sitewide-scroll-content:focus-visible {
    outline: 2px solid #a9872d;
    outline-offset: 2px;
}

@media (max-width: 767.98px) {
    .tac-sitewide-scroll-card > h3 {
        min-height: 48px !important;
    }

    .tac-sitewide-scroll-content {
        height: 190px !important;
        min-height: 190px !important;
        max-height: 190px !important;
        flex-basis: 190px !important;
    }
}

/* The same fixed-height scroll treatment for the three-column format/type cards. */
.bookx-card-grid--three {
    align-items: stretch !important;
}

.bookx-card-grid--three > .tac-sitewide-scroll-card {
    height: 100% !important;
}

/* Site-wide service cards (e.g. "What We Edit"). Keep icon/title fixed and
   place the description and any tags/features in the scrollable body. */
.tac-sitewide-scroll-card > .service-icon,
.tac-sitewide-scroll-card > .step-num {
    display: block;
    flex: 0 0 auto !important;
    min-width: 0 !important;
}

.tac-sitewide-scroll-card > h4 {
    display: flex !important;
    align-items: center !important;
    flex: 0 0 auto !important;
    min-width: 0 !important;
    min-height: 48px !important;
    margin-bottom: 12px !important;
    line-height: 1.2 !important;
    overflow-wrap: break-word !important;
}

/* Four-step process cards: equal card heights with a compact scrollable copy area. */
.process-steps {
    align-items: stretch !important;
    grid-auto-rows: 1fr !important;
}

.process-steps > .tac-sitewide-scroll-card {
    height: 100% !important;
    min-height: 0 !important;
}

.process-steps .tac-sitewide-scroll-content {
    height: 190px !important;
    min-height: 190px !important;
    max-height: 190px !important;
    flex: 0 0 190px !important;
}

/* Service-card sliders use the same fixed body height so every card aligns. */
.service-card.tac-sitewide-scroll-card {
    min-height: 0 !important;
}

@media (max-width: 767.98px) {
    .tac-sitewide-scroll-card > h4 {
        min-height: 44px !important;
    }

    .process-steps .tac-sitewide-scroll-content {
        height: 180px !important;
        min-height: 180px !important;
        max-height: 180px !important;
        flex-basis: 180px !important;
    }
}
