/* BOW Category Hero CMS Element
 * Layout: One card — hero banner (text left + image right) + category grid below
 * Mirrors the admin editor layout
 */

/* ===== BLOCK RESET ===== */
.cms-block-bow-category-hero {
    padding: 0 !important;
}

/* ===== MAIN CARD ===== */
.bow-category-hero {
    width: 100%;
    box-sizing: border-box;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

/* ===== HERO BANNER (top section) ===== */
.bow-category-hero .bow-category-hero__banner {
    position: relative;
    overflow: hidden;
}

.bow-category-hero .bow-category-hero__banner-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    z-index: 0;
}

/* 3-column layout: Headline | List | Image */
.bow-category-hero .bow-category-hero__banner-content {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 2rem;
    padding: 2.5rem 3rem;
}

/* Column 1: Headline */
.bow-category-hero .bow-category-hero__col-headline {
    flex: 0 0 auto;
    max-width: 30%;
    min-width: 0;
}

/* Column 2: Bullet list */
.bow-category-hero .bow-category-hero__col-list {
    flex: 1 1 0%;
    min-width: 0;
}

/* Column 3: Right column */
.bow-category-hero .bow-category-hero__col-image {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bow-category-hero .bow-category-hero__col-right--description {
    flex: 0 1 32%;
    justify-content: flex-start;
}

/* Headline */
.bow-category-hero .bow-category-hero__headline {
    color: var(--bow-cat-hero-headline-color, #1a1a2e);
    font-size: var(--bow-cat-hero-headline-size, 36px);
    font-weight: 700;
    text-transform: uppercase;
    line-height: 1.2;
    margin: 0;
    padding: 0;
}

/* Product image */
.bow-category-hero .bow-category-hero__hero-img {
    max-width: 280px;
    max-height: 280px;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

/* Category description */
.bow-category-hero .bow-category-hero__description {
    width: 100%;
    color: var(--bow-cat-hero-description-color, #333);
    font-size: var(--bow-cat-hero-description-size, 16px);
    line-height: 1.6;
}

.bow-category-hero .bow-category-hero__description p:first-child {
    margin-top: 0;
}

.bow-category-hero .bow-category-hero__description p:last-child {
    margin-bottom: 0;
}

.bow-category-hero .bow-category-hero__description a {
    color: inherit;
    text-decoration: underline;
}

/* ===== LIST (Bullet Points) ===== */
.bow-category-hero .bow-category-hero__list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.bow-category-hero .bow-category-hero__list li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 0.35rem 0;
    color: var(--bow-cat-hero-list-text-color, #333);
    font-size: 1rem;
    line-height: 1.5;
}

.bow-category-hero .bow-category-hero__list-icon {
    flex-shrink: 0;
    color: var(--bow-cat-hero-list-icon-color, #0A74DA);
    display: flex;
    align-items: center;
    margin-top: 2px;
}

.bow-category-hero .bow-category-hero__list-icon svg {
    width: 20px;
    height: 20px;
}

/* Bullet style */
.bow-category-hero .bow-category-hero__list--bullet li::before {
    content: '\2022';
    color: var(--bow-cat-hero-list-icon-color, #0A74DA);
    font-weight: bold;
    font-size: 1.4em;
    line-height: 1;
    margin-right: 0.4rem;
    flex-shrink: 0;
}

/* Number style */
.bow-category-hero .bow-category-hero__list--number {
    counter-reset: bow-hero-list;
}

.bow-category-hero .bow-category-hero__list--number li {
    counter-increment: bow-hero-list;
}

.bow-category-hero .bow-category-hero__list--number li::before {
    content: counter(bow-hero-list) '.';
    color: var(--bow-cat-hero-list-icon-color, #0A74DA);
    font-weight: 700;
    min-width: 1.5em;
    flex-shrink: 0;
}

/* ===== CATEGORY NAVIGATION GRID (below hero, same card) ===== */
.bow-category-hero .bow-category-hero__categories {
    width: 100%;
    padding: 1.25rem 1rem 1.5rem;
    box-sizing: border-box;
}

.bow-category-hero .bow-category-hero__categories-header {
    color: var(--bow-cat-hero-categories-header-color, #1a1a2e);
    font-size: var(--bow-cat-hero-categories-header-size, 20px);
    font-weight: 700;
    line-height: 1.3;
    margin: 0 0 1rem;
    padding: 0;
}

.bow-category-hero .bow-category-hero__categories-grid {
    display: grid;
    grid-template-columns: repeat(var(--bow-cat-hero-cols-desktop, 4), 1fr);
    gap: var(--bow-cat-hero-grid-gap, 12px);
}

/* Category buttons */
.bow-category-hero .bow-category-hero__cat-btn {
    display: flex !important;
    align-items: center !important;
    gap: 0.625rem;
    padding: 0.75rem 1rem;
    background-color: var(--bow-cat-hero-btn-bg, #0A74DA) !important;
    color: var(--bow-cat-hero-btn-color, #fff) !important;
    border-radius: var(--bow-cat-hero-btn-radius, 8px) !important;
    text-decoration: none !important;
    font-weight: 500;
    font-size: 0.9rem;
    transition: background-color 0.2s ease, transform 0.15s ease;
    cursor: pointer;
    border: none !important;
    box-shadow: none;
    line-height: 1.4;
}

.bow-category-hero .bow-category-hero__cat-btn:hover,
.bow-category-hero .bow-category-hero__cat-btn:focus {
    background-color: var(--bow-cat-hero-btn-hover-bg, #085EB0) !important;
    color: var(--bow-cat-hero-btn-color, #fff) !important;
    text-decoration: none !important;
    transform: translateY(-1px);
}

/* "Show All" special button (orange CTA) */
.bow-category-hero .bow-category-hero__cat-btn.bow-category-hero__cat-btn--show-all {
    background-color: var(--bow-cat-hero-btn-show-all-bg, #F28C28) !important;
    color: var(--bow-cat-hero-btn-show-all-color, #fff) !important;
    font-weight: 700;
    cursor: pointer;
}

.bow-category-hero .bow-category-hero__cat-btn.bow-category-hero__cat-btn--show-all:hover,
.bow-category-hero .bow-category-hero__cat-btn.bow-category-hero__cat-btn--show-all:focus {
    background-color: var(--bow-cat-hero-btn-show-all-bg, #F28C28) !important;
    filter: brightness(0.9);
    color: var(--bow-cat-hero-btn-show-all-color, #fff) !important;
    text-decoration: none !important;
}

.bow-category-hero .bow-category-hero__toggle-row {
    display: flex;
    margin-top: var(--bow-cat-hero-grid-gap, 12px);
}

.bow-category-hero .bow-category-hero__toggle-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background-color: var(--bow-cat-hero-btn-show-all-bg, #F28C28);
    color: var(--bow-cat-hero-btn-show-all-color, #fff);
    border: none;
    border-radius: var(--bow-cat-hero-btn-radius, 8px);
    font-weight: 700;
    font-size: 0.9rem;
    line-height: 1.4;
    cursor: pointer;
}

.bow-category-hero .bow-category-hero__toggle-button:hover,
.bow-category-hero .bow-category-hero__toggle-button:focus {
    filter: brightness(0.9);
    color: var(--bow-cat-hero-btn-show-all-color, #fff);
    text-decoration: none;
}

.bow-category-hero .bow-category-hero__toggle-label {
    display: inline-flex;
    align-items: center;
}

/* Hidden categories (toggle mechanism) */
.bow-category-hero .bow-category-hero__cat-btn--hidden {
    display: none !important;
}

.bow-category-hero .bow-category-hero__categories-grid.is-expanded .bow-category-hero__cat-btn--hidden {
    display: flex !important;
}

/* Rotate arrow when expanded */
.bow-category-hero .bow-category-hero__cat-btn--show-all.is-active .bow-category-hero__cat-arrow {
    transform: rotate(90deg);
}

/* Toggle button icon */
.bow-category-hero .bow-category-hero__cat-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bow-category-hero .bow-category-hero__cat-icon svg {
    width: 18px;
    height: 18px;
}

/* Category thumbnail */
.bow-category-hero .bow-category-hero__cat-img {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: 6px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
}

.bow-category-hero .bow-category-hero__cat-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Category name */
.bow-category-hero .bow-category-hero__cat-name {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Arrow icon */
.bow-category-hero .bow-category-hero__cat-arrow {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    opacity: 0.7;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.bow-category-hero .bow-category-hero__cat-btn:hover .bow-category-hero__cat-arrow {
    opacity: 1;
    transform: translateX(2px);
}

/* ===== RESPONSIVE ===== */

@media (min-width: 992px) and (max-width: 1199px) {
    .bow-category-hero .bow-category-hero__categories-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 991px) {
    .bow-category-hero .bow-category-hero__banner-content {
        padding: 2rem;
        gap: 1.5rem;
    }

    .bow-category-hero .bow-category-hero__hero-img {
        max-width: 200px;
        max-height: 200px;
    }

    .bow-category-hero .bow-category-hero__categories-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .bow-category-hero .bow-category-hero__categories {
        padding: 1rem 1rem 1.25rem;
    }
}

@media (max-width: 767px) {
    .bow-category-hero .bow-category-hero__banner-content {
        flex-direction: column;
        text-align: center;
        padding: 1.5rem;
        gap: 1rem;
    }

    .bow-category-hero .bow-category-hero__col-headline,
    .bow-category-hero .bow-category-hero__col-list,
    .bow-category-hero .bow-category-hero__col-image {
        max-width: 100%;
        width: 100%;
    }

    .bow-category-hero .bow-category-hero__headline {
        font-size: var(--bow-cat-hero-headline-size-mobile, 24px);
    }

    .bow-category-hero .bow-category-hero__list li {
        justify-content: center;
    }

    .bow-category-hero .bow-category-hero__col-image {
        order: -1;
    }

    .bow-category-hero .bow-category-hero__col-right--description,
    .bow-category-hero .bow-category-hero__col-right--none {
        order: 0;
    }

    .bow-category-hero .bow-category-hero__hero-img {
        max-width: 160px;
        max-height: 160px;
    }

    .bow-category-hero .bow-category-hero__description {
        font-size: var(--bow-cat-hero-description-size-mobile, 14px);
    }

    .bow-category-hero .bow-category-hero__categories {
        padding: 0.75rem 1rem 1rem;
    }

    .bow-category-hero .bow-category-hero__categories-header {
        font-size: var(--bow-cat-hero-categories-header-size-mobile, 18px);
    }

    .bow-category-hero .bow-category-hero__categories-grid {
        grid-template-columns: repeat(var(--bow-cat-hero-cols-mobile, 2), 1fr);
    }

    .bow-category-hero .bow-category-hero__cat-btn {
        padding: 0.6rem 0.75rem;
        font-size: 0.8rem;
    }

    .bow-category-hero .bow-category-hero__toggle-button {
        padding: 0.6rem 0.75rem;
        font-size: 0.8rem;
    }

    .bow-category-hero .bow-category-hero__cat-img {
        width: 32px;
        height: 32px;
    }
}

@media (max-width: 610px) {
    .bow-category-hero .bow-category-hero__categories-grid {
        grid-template-columns: 1fr;
    }
}