/* --- PRODUCT HERO COMPONENT --- */
.product-hero {
    max-width: var(--content-max-width, var(--product-hero-max-width, 1200px));
    margin: 0 auto;
    padding: var(--product-hero-padding, 60px 5%);
    background-color: var(--color-bg, transparent);
}

.product-hero-titlebar {
    position: relative;
    width: 100%;
    margin: 0 0 40px 0;
    padding-bottom: var(--product-hero-underline-gap, 20px);
}

/* The underline starts from the left (above the image) and spans part of the width */
.product-hero-titlebar::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: var(--product-hero-underline-width, 100%);
    height: var(--product-hero-underline-height, 2px);
    background: var(--product-hero-underline-color, var(--color-primary));
}

.product-hero-title {
    text-align: var(--product-hero-title-align, left);
    color: var(--product-hero-title-color, var(--color-primary));
    font-size: var(--product-hero-title-size, 48px);
    font-weight: var(--product-hero-title-weight, 800);
    text-transform: var(--product-hero-title-transform, uppercase);
    letter-spacing: var(--product-hero-title-letter-spacing, normal);
    line-height: 1.1;
    margin: 0 0 0 auto;
    max-width: var(--product-hero-title-max-width, none);
}

.product-hero-row {
    display: flex;
    gap: var(--product-hero-gap, 40px);
    align-items: var(--product-hero-align, flex-start);
    flex-wrap: wrap;
}

.product-hero-media {
    flex: 1 1 var(--product-hero-media-width, 45%);
    min-width: 300px;
}

.product-hero-text {
    flex: 1 1 var(--product-hero-text-width, 45%);
    min-width: 300px;
    line-height: 1.6;
}

.product-hero-subtitle {
    font-size: var(--product-hero-subtitle-size, 18px);
    font-weight: var(--product-hero-subtitle-weight, 700);
    color: var(--product-hero-subtitle-color, var(--color-text-light, #fff));
    margin: 0 0 20px 0;
}

.product-hero-messaging,
.product-hero-messaging p {
    font-size: var(--product-hero-messaging-size, 16px);
    color: var(--product-hero-messaging-color, var(--color-primary));
    line-height: 1.6;
}

.product-hero-messaging p + p {
    margin-top: 1em;
}

.product-hero-description,
.product-hero-description p {
    font-size: var(--product-hero-description-size, 16px);
    color: var(--product-hero-description-color, var(--color-text-light, #fff));
    line-height: 1.6;
    margin-top: 20px;
}

@media (max-width: 767px) {
    .product-hero-title {
        text-align: left;
        font-size: var(--product-hero-title-size-mobile, 34px);
    }
}

/* --- Opt-ins: icon, theme, badgeImage, thumbnails, ctas. Nothing here applies without them. --- */
.product-hero-titlebar:has(.product-hero-icon) {
    display: flex;
    align-items: center;
    gap: var(--product-hero-icon-gap, 16px);
}

.product-hero-icon {
    flex: none;
    width: var(--product-hero-icon-size, 56px);
    height: auto;
}

.product-hero--themed {
    background-color: var(--product-hero-theme-bg, color-mix(in srgb, var(--product-hero-theme) 12%, #ffffff));
}

.product-hero--themed .product-hero-titlebar::after {
    background-color: var(--product-hero-theme-accent, var(--product-hero-theme));
}

.product-hero--themed .product-hero-cta {
    border-color: var(--product-hero-theme-accent, var(--product-hero-theme));
    background-color: var(--product-hero-theme-accent, var(--product-hero-theme));
}

.product-hero-media:has(.product-hero-badge) {
    position: relative;
}

.product-hero-badge {
    position: absolute;
    top: var(--product-hero-badge-top, 0);
    right: var(--product-hero-badge-right, 0);
    z-index: 2;
    width: var(--product-hero-badge-size, 80px);
    height: auto;
}

.product-hero-thumbs {
    display: flex;
    flex-wrap: wrap;
    justify-content: var(--product-hero-thumbs-justify, center);
    gap: var(--product-hero-thumbs-gap, 8px);
    margin: var(--product-hero-thumbs-margin, 16px 0 0);
    padding: 0;
    list-style: none;
}

.product-hero-thumb {
    display: block;
    width: var(--product-hero-thumb-size, 64px);
    height: var(--product-hero-thumb-size, 64px);
    padding: 2px;
    border: var(--product-hero-thumb-border, 2px solid transparent);
    border-radius: var(--product-hero-thumb-radius, 4px);
    background: var(--product-hero-thumb-bg, #ffffff);
    cursor: pointer;
}

.product-hero-thumb img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.product-hero-thumb.is-current {
    border-color: var(--product-hero-thumb-current-border-color, var(--product-hero-theme, currentColor));
}

/* the thumbnails replace the carousel's dots */
.product-hero-media:has(.product-hero-thumbs) .carousel-nav {
    display: var(--product-hero-thumbs-dots, none);
}

.product-hero-ctas {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: var(--product-hero-ctas-margin, 24px);
}

.product-hero-cta {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: var(--product-hero-cta-padding, 10px 24px);
    border: 2px solid var(--product-hero-cta-bg, var(--color-primary, #1a1a1a));
    border-radius: var(--product-hero-cta-radius, var(--border-radius-button, 0));
    background-color: var(--product-hero-cta-bg, var(--color-primary, #1a1a1a));
    color: var(--product-hero-cta-color, #ffffff);
    font-weight: var(--product-hero-cta-weight, 700);
    text-decoration: none;
}

.product-hero-cta--secondary,
.product-hero--themed .product-hero-cta--secondary {
    background-color: transparent;
    color: var(--product-hero-cta-secondary-color, inherit);
}
