/* Rihalo Store UI v0.3.2 — single-product layout only. */

body.rihalo-etsy-product {
    --rihalo-ink: #29252f;
    --rihalo-text: #222124;
    --rihalo-muted: #6f6a66;
    --rihalo-line: #e8e4df;
    --rihalo-soft: #fbfaf8;
    --rihalo-accent: #d95f23;
    --rihalo-green: #347329;
    --rihalo-star: #d9a155;
}

/* Give the product UI a clean full-width canvas without touching the header itself. */
body.rihalo-etsy-product #secondary,
body.rihalo-etsy-product .widget-area {
    display: none !important;
}

body.rihalo-etsy-product .content-area,
body.rihalo-etsy-product .site-main,
body.rihalo-etsy-product .content-container,
body.rihalo-etsy-product .woocommerce,
body.rihalo-etsy-product .entry-content {
    width: 100% !important;
    max-width: none !important;
}

body.rihalo-etsy-product .site-main,
body.rihalo-etsy-product .content-area {
    margin: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

body.rihalo-etsy-product .rihalo-product-shell,
body.rihalo-etsy-product .rihalo-product-shell * {
    box-sizing: border-box;
}

.rihalo-product-shell {
    width: min(1480px, calc(100% - 56px));
    margin: 0 auto;
    padding: 34px 0 64px;
    color: var(--rihalo-text);
    font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.rihalo-product-breadcrumb {
    margin: 0 0 26px;
    font-size: 14px;
    line-height: 1.5;
    color: #645f5b;
}

.rihalo-product-breadcrumb .woocommerce-breadcrumb {
    margin: 0 !important;
    color: inherit !important;
    font-size: inherit !important;
}

.rihalo-product-breadcrumb a {
    color: #4f4a47 !important;
    text-decoration: none;
}

.rihalo-product-breadcrumb a:hover {
    text-decoration: underline;
}

.rihalo-product-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.68fr) minmax(390px, 0.92fr);
    gap: 52px;
    align-items: start;
}

/* Product summary */
.rihalo-product-panel {
    min-width: 0;
    padding-top: 2px;
}

.rihalo-popularity {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin: 0 0 12px;
    color: var(--rihalo-accent);
    font-size: 15px;
    font-weight: 700;
}

.rihalo-popularity-neutral {
    color: #6e655f;
    font-weight: 600;
}

.rihalo-popularity svg {
    width: 18px;
    height: 18px;
}

.rihalo-product-title {
    margin: 0 0 18px !important;
    padding: 0 !important;
    color: #171517 !important;
    font-family: Georgia, "Times New Roman", Times, serif !important;
    font-size: clamp(32px, 2.15vw, 40px) !important;
    font-weight: 700 !important;
    line-height: 1.08 !important;
    letter-spacing: -.025em !important;
    overflow-wrap: anywhere;
}

.rihalo-rating-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-bottom: 18px;
    color: #494441;
    font-size: 15px;
}

.rihalo-rating-stars .star-rating {
    float: none !important;
    margin: 0 !important;
    color: var(--rihalo-star) !important;
}

.rihalo-review-count {
    color: #4f4a47;
}

.rihalo-rating-divider {
    width: 1px;
    height: 20px;
    background: var(--rihalo-line);
}

.rihalo-delivery-label {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #4f4a47;
}

.rihalo-delivery-label svg {
    width: 19px;
    height: 19px;
}

.rihalo-price-block {
    display: flex;
    align-items: baseline;
    gap: 12px;
    margin: 0 0 6px;
    line-height: 1;
}

.rihalo-price-block .price,
.rihalo-price-block > span,
.rihalo-price-block > ins,
.rihalo-price-block > del {
    margin: 0 !important;
}

.rihalo-price-block ins {
    order: -1;
    text-decoration: none !important;
    background: transparent !important;
}

.rihalo-price-block ins .woocommerce-Price-amount,
.rihalo-price-block > .woocommerce-Price-amount,
.rihalo-price-block .price > .woocommerce-Price-amount {
    color: var(--rihalo-accent) !important;
    font-size: 38px !important;
    font-weight: 700 !important;
    letter-spacing: -.03em;
}

.rihalo-price-block del,
.rihalo-price-block del .woocommerce-Price-amount {
    color: #67615e !important;
    font-size: 16px !important;
    font-weight: 400 !important;
    opacity: 1 !important;
}

.rihalo-sale-line {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 8px 0 25px;
    color: var(--rihalo-green);
    font-size: 15px;
}

.rihalo-sale-line strong {
    font-weight: 700;
}

.rihalo-product-excerpt {
    margin: 0 0 22px;
    color: #55504c;
    font-size: 16px;
    line-height: 1.72;
}

.rihalo-product-excerpt p:last-child {
    margin-bottom: 0;
}

.rihalo-product-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 26px;
}

.rihalo-product-badges > span {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 38px;
    padding: 8px 13px;
    border: 1px solid var(--rihalo-line);
    border-radius: 9px;
    background: #fff;
    color: #393532;
    font-size: 13px;
    font-weight: 600;
}

.rihalo-product-badges svg {
    width: 17px;
    height: 17px;
    color: #6a6159;
}

.rihalo-purchase-area {
    margin-top: 2px;
}

.rihalo-simple-cart,
.rihalo-variable-cart-wrap form.cart {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    margin: 0 !important;
}

.rihalo-simple-cart .rihalo-product-buy-now,
.rihalo-variable-buy-now {
    order: 1;
}

.rihalo-simple-cart .rihalo-product-add-cart,
.rihalo-variable-cart-wrap .single_add_to_cart_button {
    order: 2;
}

.rihalo-product-buy-now,
.rihalo-product-add-cart,
.rihalo-variable-cart-wrap .single_add_to_cart_button {
    width: 100% !important;
    min-height: 60px !important;
    margin: 0 !important;
    padding: 13px 22px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 15px !important;
    box-shadow: none !important;
    font-family: inherit !important;
    font-size: 17px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    text-decoration: none !important;
}

.rihalo-product-buy-now,
.rihalo-variable-buy-now {
    gap: 16px !important;
    border: 1.5px solid var(--rihalo-ink) !important;
    background: #fff !important;
    color: var(--rihalo-ink) !important;
}

.rihalo-product-buy-now:hover,
.rihalo-variable-buy-now:hover {
    background: #fbfaf8 !important;
    color: var(--rihalo-ink) !important;
}

.rihalo-product-buy-now img,
.rihalo-variable-buy-now img {
    display: block !important;
    width: 46px !important;
    height: auto !important;
    max-height: 28px !important;
    object-fit: contain !important;
}

.rihalo-buy-divider {
    width: 1px;
    height: 26px;
    background: var(--rihalo-line);
}

.rihalo-product-add-cart,
.rihalo-variable-cart-wrap .single_add_to_cart_button {
    border: 1.5px solid var(--rihalo-ink) !important;
    background: var(--rihalo-ink) !important;
    color: #fff !important;
}

.rihalo-product-add-cart:hover,
.rihalo-variable-cart-wrap .single_add_to_cart_button:hover {
    background: #1c1921 !important;
    border-color: #1c1921 !important;
    color: #fff !important;
}

.rihalo-variable-cart-wrap .variations {
    width: 100% !important;
    margin: 0 0 14px !important;
}

.rihalo-variable-cart-wrap .variations th,
.rihalo-variable-cart-wrap .variations td {
    display: block !important;
    width: 100% !important;
    padding: 0 !important;
}

.rihalo-variable-cart-wrap .variations label {
    display: block;
    margin: 0 0 7px;
    font-size: 14px;
    font-weight: 700;
}

.rihalo-variable-cart-wrap .variations select {
    width: 100% !important;
    min-height: 48px;
    border: 1px solid var(--rihalo-line);
    border-radius: 9px;
    padding: 0 12px;
    background: #fff;
}

.rihalo-variable-cart-wrap .quantity {
    display: none !important;
}

.rihalo-payment-strip {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    width: 100%;
    max-width: 500px;
    margin-top: 20px;
}

.rihalo-payment-method {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    height: 50px;
    padding: 8px 9px;
    box-sizing: border-box;
    border: 1px solid #e2ded9;
    border-radius: 10px;
    background: #fff;
}

.rihalo-payment-method img {
    display: block !important;
    width: auto !important;
    height: auto !important;
    max-width: 58px !important;
    max-height: 30px !important;
    margin: 0 !important;
    object-fit: contain !important;
}

.rihalo-payment-google-pay img {
    max-width: 64px !important;
}

@media (max-width: 520px) {
    .rihalo-payment-strip {
        gap: 7px;
    }

    .rihalo-payment-method {
        height: 46px;
        padding: 7px 6px;
        border-radius: 9px;
    }

    .rihalo-payment-method img {
        max-width: 48px !important;
        max-height: 27px !important;
    }

    .rihalo-payment-google-pay img {
        max-width: 54px !important;
    }
}

.rihalo-security-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 18px;
    margin-top: 15px;
    padding-bottom: 22px;
    border-bottom: 1px solid var(--rihalo-line);
    color: #6d6762;
    font-size: 12.5px;
}

.rihalo-security-row span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.rihalo-security-row svg {
    width: 17px;
    height: 17px;
    flex: 0 0 auto;
}

.rihalo-item-details {
    margin-top: 4px;
}

.rihalo-item-details details {
    border-bottom: 1px solid var(--rihalo-line);
}

.rihalo-item-details summary {
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 60px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 700;
}

.rihalo-item-details summary::-webkit-details-marker {
    display: none;
}

.rihalo-detail-body,
.rihalo-detail-copy {
    padding: 0 0 18px;
    color: #66605c;
    font-size: 14px;
    line-height: 1.65;
}

.rihalo-detail-body > div {
    display: grid;
    grid-template-columns: 110px minmax(0,1fr);
    gap: 16px;
    padding: 6px 0;
}

.rihalo-detail-body strong {
    color: #3b3734;
}

/* Trust strip */
.rihalo-product-trust-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
    margin: 42px 0 0;
    padding: 30px 0 32px;
    border-top: 1px solid var(--rihalo-line);
    border-bottom: 1px solid var(--rihalo-line);
}

.rihalo-product-trust-strip > div {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 0 30px;
    border-right: 1px solid var(--rihalo-line);
}

.rihalo-product-trust-strip > div:first-child {
    padding-left: 18px;
}

.rihalo-product-trust-strip > div:last-child {
    border-right: 0;
}

.rihalo-trust-icon {
    width: 45px;
    height: 45px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    color: #1d1a1d;
}

.rihalo-trust-icon svg {
    width: 38px;
    height: 38px;
}

.rihalo-product-trust-strip p {
    margin: 0;
}

.rihalo-product-trust-strip strong,
.rihalo-product-trust-strip small {
    display: block;
}

.rihalo-product-trust-strip strong {
    margin-bottom: 5px;
    color: #29252f;
    font-size: 14px;
}

.rihalo-product-trust-strip small {
    color: #6d6762;
    font-size: 12.5px;
    line-height: 1.55;
}

/* Description / reviews */
.rihalo-product-lower {
    padding-top: 38px;
}

.rihalo-product-lower .woocommerce-tabs {
    margin: 0 !important;
}

.rihalo-product-lower .woocommerce-tabs ul.tabs {
    display: flex !important;
    gap: 26px !important;
    margin: 0 0 28px !important;
    padding: 0 !important;
    border-bottom: 1px solid var(--rihalo-line) !important;
}

.rihalo-product-lower .woocommerce-tabs ul.tabs::before,
.rihalo-product-lower .woocommerce-tabs ul.tabs li::before,
.rihalo-product-lower .woocommerce-tabs ul.tabs li::after {
    display: none !important;
}

.rihalo-product-lower .woocommerce-tabs ul.tabs li {
    margin: 0 !important;
    padding: 0 0 11px !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
}

.rihalo-product-lower .woocommerce-tabs ul.tabs li.active {
    border-bottom: 2px solid var(--rihalo-ink) !important;
}

.rihalo-product-lower .woocommerce-tabs ul.tabs li a {
    padding: 0 !important;
    color: #4a4541 !important;
    font-size: 15px !important;
    font-weight: 700 !important;
}

.rihalo-product-lower .woocommerce-Tabs-panel {
    max-width: 980px;
    color: #393532;
    font-size: 16px;
    line-height: 1.75;
}

.rihalo-product-lower .woocommerce-Tabs-panel h2:first-child {
    display: none;
}

.rihalo-related-products {
    margin-top: 58px;
}

@media (max-width: 1180px) {
    .rihalo-product-shell {
        width: min(100% - 36px, 1180px);
    }
    .rihalo-product-hero {
        grid-template-columns: minmax(0, 1.42fr) minmax(360px, .9fr);
        gap: 34px;
    }
    .rihalo-product-gallery {
        grid-template-columns: 88px minmax(0,1fr);
        gap: 14px;
    }
    .rihalo-product-title {
        font-size: clamp(31px, 3vw, 41px) !important;
    }
    .rihalo-product-trust-strip > div {
        padding: 0 18px;
    }
}

@media (max-width: 900px) {
    .rihalo-product-shell {
        width: min(100% - 28px, 760px);
        padding-top: 22px;
    }
    .rihalo-product-hero {
        grid-template-columns: 1fr;
        gap: 28px;
    }
    .rihalo-product-gallery {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .rihalo-main-image-wrap {
        grid-row: 1;
    }
    .rihalo-thumb-rail-wrap {
        grid-row: 2;
        overflow: hidden;
    }
    .rihalo-thumb-rail {
        flex-direction: row;
        max-height: none;
        overflow-x: auto;
        overflow-y: hidden;
        scrollbar-width: none;
        padding-bottom: 2px;
    }
    .rihalo-thumb-rail::-webkit-scrollbar { display: none; }
    .rihalo-thumb {
        flex: 0 0 78px;
        width: 78px;
        aspect-ratio: 1;
    }
    .rihalo-thumb-more { display: none; }
    .rihalo-product-panel {
        padding-top: 0;
    }
    .rihalo-product-trust-strip {
        grid-template-columns: repeat(2, minmax(0,1fr));
        row-gap: 26px;
    }
    .rihalo-product-trust-strip > div,
    .rihalo-product-trust-strip > div:first-child {
        padding: 0 18px;
        border-right: 0;
    }
}

@media (max-width: 600px) {
    .rihalo-product-shell {
        width: min(100% - 20px, 560px);
        padding-bottom: 44px;
    }
    .rihalo-product-breadcrumb {
        margin-bottom: 16px;
        font-size: 12.5px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    .rihalo-main-image-wrap {
        border-radius: 11px;
    }
    .rihalo-zoom-button {
        width: 42px;
        height: 42px;
        top: 12px;
        right: 12px;
    }
    .rihalo-product-title {
        font-size: 31px !important;
    }
    .rihalo-price-block ins .woocommerce-Price-amount,
    .rihalo-price-block > .woocommerce-Price-amount,
    .rihalo-price-block .price > .woocommerce-Price-amount {
        font-size: 36px !important;
    }
    .rihalo-product-excerpt {
        font-size: 15px;
    }
    .rihalo-product-buy-now,
    .rihalo-product-add-cart,
    .rihalo-variable-cart-wrap .single_add_to_cart_button {
        min-height: 56px !important;
        border-radius: 13px !important;
        font-size: 16px !important;
    }
    .rihalo-product-trust-strip {
        grid-template-columns: 1fr;
        padding: 24px 0;
    }
    .rihalo-product-trust-strip > div,
    .rihalo-product-trust-strip > div:first-child {
        padding: 0 8px;
    }
    .rihalo-lightbox {
        padding: 50px 14px;
    }
    .rihalo-lightbox img {
        max-width: 94vw;
        max-height: 82vh;
    }
    .rihalo-lightbox-arrow {
        width: 42px;
        height: 52px;
        background: rgba(255,255,255,.92);
    }
    .rihalo-lightbox-arrow.is-prev { left: 8px; }
    .rihalo-lightbox-arrow.is-next { right: 8px; }
}

/* ========================================================================== */
/* v0.3.2 — Native WooCommerce gallery, compact category trail, viewer polish. */
/* ========================================================================== */

/* Compact category trail: no Home and no repeated product title. */
body.rihalo-etsy-product .rihalo-product-breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;
    margin: 0 0 20px;
    color: #77706b;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.35;
}

body.rihalo-etsy-product .rihalo-product-breadcrumb a {
    color: #625c57 !important;
    text-decoration: none !important;
    transition: color .15s ease;
}

body.rihalo-etsy-product .rihalo-product-breadcrumb a:hover {
    color: #29252f !important;
    text-decoration: underline !important;
    text-underline-offset: 3px;
}

body.rihalo-etsy-product .rihalo-breadcrumb-separator {
    color: #aaa39d;
    font-size: 16px;
    line-height: 1;
}

/* Native gallery wrapper. WooCommerce owns the behaviour; Rihalo owns the skin. */
body.rihalo-etsy-product .rihalo-native-gallery-shell {
    min-width: 0;
    width: 100%;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery {
    position: relative !important;
    float: none !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    display: grid !important;
    grid-template-columns: 106px minmax(0, 1fr);
    grid-template-rows: auto;
    column-gap: 18px;
    align-items: start;
    min-width: 0;
}

/* Before FlexSlider initializes the figure is the grid item. Afterwards its
   .flex-viewport parent becomes the grid item; both states are styled. */
body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery > .woocommerce-product-gallery__wrapper,
body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery > .flex-viewport {
    grid-column: 2;
    grid-row: 1;
    width: 100% !important;
    min-width: 0;
    margin: 0 !important;
    border: 1px solid #e8e4df;
    border-radius: 14px;
    background: #f8f6f2;
    overflow: hidden !important;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery__wrapper {
    margin: 0 !important;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery__image {
    margin: 0 !important;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery__image > a {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 100% !important;
    aspect-ratio: 1 / 1;
    background: #f8f6f2;
    overflow: hidden;
    cursor: zoom-in;
}

/* Product artwork must be fully visible. Cropping belongs on catalog cards, not
   on a product-detail image where text and design edges are purchase information. */
body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery__image > a > img:not(.zoomImg) {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    object-fit: contain !important;
    object-position: center !important;
}

/* Vertical Etsy-like thumbnail rail. */
body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-control-thumbs {
    grid-column: 1;
    grid-row: 1;
    display: flex !important;
    flex-direction: column;
    gap: 10px;
    width: 100% !important;
    max-height: 720px;
    margin: 0 !important;
    padding: 1px 2px 2px !important;
    overflow-x: hidden;
    overflow-y: auto;
    list-style: none !important;
    scrollbar-width: none;
    overscroll-behavior: contain;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-control-thumbs::-webkit-scrollbar {
    display: none;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-control-thumbs li {
    float: none !important;
    flex: 0 0 auto;
    width: 100% !important;
    aspect-ratio: 1 / 1.07;
    margin: 0 !important;
    padding: 0 !important;
    border: 1px solid #e8e4df;
    border-radius: 10px;
    background: #fff;
    overflow: hidden;
    cursor: pointer;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-control-thumbs img {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    object-fit: cover !important;
    opacity: 1 !important;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-control-thumbs li:has(img.flex-active) {
    border: 2px solid #29252f;
    box-shadow: 0 0 0 1px #fff inset;
}

/* Native WooCommerce zoom/lightbox trigger. Keep theme orange button rules out. */
body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery__trigger,
body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery__trigger:hover,
body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery__trigger:focus {
    position: absolute !important;
    z-index: 8 !important;
    top: 16px !important;
    right: 16px !important;
    left: auto !important;
    width: 48px !important;
    height: 48px !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 1px solid rgba(41,37,47,.10) !important;
    border-radius: 999px !important;
    background: rgba(255,255,255,.97) !important;
    color: #232025 !important;
    box-shadow: 0 5px 18px rgba(31,28,36,.10) !important;
    opacity: 1 !important;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery__trigger:hover {
    transform: scale(1.035);
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery__trigger:focus-visible {
    outline: 2px solid #29252f !important;
    outline-offset: 3px !important;
}

/* Native FlexSlider previous/next controls, surfaced over the main image. */
body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav {
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav li {
    margin: 0 !important;
    padding: 0 !important;
    list-style: none !important;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav a {
    position: absolute !important;
    z-index: 7 !important;
    top: 50% !important;
    display: grid !important;
    place-items: center !important;
    width: 46px !important;
    height: 46px !important;
    margin: -23px 0 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    border: 1px solid rgba(41,37,47,.10) !important;
    border-radius: 999px !important;
    background: rgba(255,255,255,.97) !important;
    color: #232025 !important;
    box-shadow: 0 4px 16px rgba(31,28,36,.12) !important;
    opacity: 0 !important;
    text-indent: -9999px !important;
    text-decoration: none !important;
    transition: opacity .15s ease, transform .15s ease, box-shadow .15s ease !important;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav a::before {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    width: 100%;
    height: 100%;
    background: none !important;
    color: #232025 !important;
    font-family: Arial, sans-serif !important;
    font-size: 34px !important;
    font-weight: 400 !important;
    line-height: 1 !important;
    text-indent: 0 !important;
    text-shadow: none !important;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav .flex-prev {
    left: 140px !important;
}
body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav .flex-next {
    right: 16px !important;
}
body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav .flex-prev::before { content: '‹' !important; }
body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav .flex-next::before { content: '›' !important; }

body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery:hover .flex-direction-nav a,
body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav a:focus-visible {
    opacity: 1 !important;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav a:hover {
    transform: scale(1.035);
    background: #fff !important;
}

body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav a:focus-visible {
    outline: 2px solid #29252f !important;
    outline-offset: 3px !important;
}

/* PhotoSwipe — native WooCommerce viewer, reskinned to Rihalo/Etsy-like controls. */
body.rihalo-etsy-product .pswp {
    z-index: 2147483600 !important;
}

body.rihalo-etsy-product .pswp__bg {
    background: #171518 !important;
    opacity: .94 !important;
}

body.rihalo-etsy-product .pswp__top-bar,
body.rihalo-etsy-product .pswp__caption {
    background: transparent !important;
}

body.rihalo-etsy-product .pswp__img {
    border-radius: 6px;
}

body.rihalo-etsy-product .pswp__button--close {
    top: 20px !important;
    right: 22px !important;
    width: 50px !important;
    height: 50px !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: #fff !important;
    opacity: 1 !important;
    box-shadow: 0 5px 18px rgba(0,0,0,.20) !important;
}

body.rihalo-etsy-product .pswp__button--close::before,
body.rihalo-etsy-product .pswp__button--close::after {
    content: '';
    position: absolute;
    top: 24px;
    left: 15px;
    width: 20px;
    height: 2px;
    border-radius: 2px;
    background: #232025;
}
body.rihalo-etsy-product .pswp__button--close::before { transform: rotate(45deg); }
body.rihalo-etsy-product .pswp__button--close::after { transform: rotate(-45deg); }

body.rihalo-etsy-product .pswp__button--arrow--left,
body.rihalo-etsy-product .pswp__button--arrow--right,
body.rihalo-etsy-product .pswp__button--arrow--prev,
body.rihalo-etsy-product .pswp__button--arrow--next {
    width: 52px !important;
    height: 52px !important;
    margin-top: -26px !important;
    border: 0 !important;
    border-radius: 999px !important;
    background: #fff !important;
    opacity: 1 !important;
    box-shadow: 0 5px 18px rgba(0,0,0,.20) !important;
}

body.rihalo-etsy-product .pswp__button--arrow--left { left: 24px !important; }
body.rihalo-etsy-product .pswp__button--arrow--right { right: 24px !important; }
body.rihalo-etsy-product .pswp__button--arrow--prev { left: 24px !important; }
body.rihalo-etsy-product .pswp__button--arrow--next { right: 24px !important; }

body.rihalo-etsy-product .pswp__button--arrow--left::before,
body.rihalo-etsy-product .pswp__button--arrow--right::before,
body.rihalo-etsy-product .pswp__button--arrow--prev::before,
body.rihalo-etsy-product .pswp__button--arrow--next::before {
    top: 15px !important;
    width: 18px !important;
    height: 18px !important;
    margin: 0 !important;
    background: none !important;
    border-top: 2px solid #232025 !important;
    border-right: 2px solid #232025 !important;
}
body.rihalo-etsy-product .pswp__button--arrow--left::before,
body.rihalo-etsy-product .pswp__button--arrow--prev::before {
    left: 19px !important;
    transform: rotate(-135deg) !important;
}
body.rihalo-etsy-product .pswp__button--arrow--right::before,
body.rihalo-etsy-product .pswp__button--arrow--next::before {
    right: 19px !important;
    transform: rotate(45deg) !important;
}

body.rihalo-etsy-product .pswp__counter {
    position: fixed !important;
    top: auto !important;
    left: 50% !important;
    bottom: 18px !important;
    min-width: 64px;
    height: auto !important;
    margin: 0 !important;
    padding: 8px 12px !important;
    transform: translateX(-50%);
    border-radius: 999px;
    background: rgba(255,255,255,.95) !important;
    color: #29252f !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    text-align: center;
    opacity: 1 !important;
    box-shadow: 0 4px 18px rgba(0,0,0,.16);
}

/* Keep floating support widgets out of the product viewer. The native viewer is
   intentionally given a very high z-index as a second line of defence. */
body.rihalo-product-viewer-open .crisp-client,
body.rihalo-product-viewer-open #tidio-chat,
body.rihalo-product-viewer-open #tawk-bubble-container,
body.rihalo-product-viewer-open #tawkchat-container,
body.rihalo-product-viewer-open #hubspot-messages-iframe-container,
body.rihalo-product-viewer-open .joinchat,
body.rihalo-product-viewer-open [id*="chat-widget" i],
body.rihalo-product-viewer-open [class*="chat-widget" i],
body.rihalo-product-viewer-open iframe[title*="chat" i] {
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

@media (max-width: 1180px) {
    body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery {
        grid-template-columns: 88px minmax(0, 1fr);
        column-gap: 14px;
    }
    body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav .flex-prev {
        left: 118px !important;
    }
}

@media (max-width: 900px) {
    body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: auto auto;
        row-gap: 12px;
    }

    body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery > .woocommerce-product-gallery__wrapper,
    body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery > .flex-viewport {
        grid-column: 1;
        grid-row: 1;
    }

    body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-control-thumbs {
        grid-column: 1;
        grid-row: 2;
        flex-direction: row;
        gap: 9px;
        max-height: none;
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: 2px !important;
    }

    body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-control-thumbs li {
        flex: 0 0 78px;
        width: 78px !important;
        aspect-ratio: 1;
    }

    body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav a {
        opacity: .96 !important;
    }
    body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav .flex-prev {
        left: 12px !important;
    }
    body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav .flex-next {
        right: 12px !important;
    }
}

@media (max-width: 600px) {
    body.rihalo-etsy-product .rihalo-product-breadcrumb {
        margin-bottom: 14px;
        font-size: 12px;
    }
    body.rihalo-etsy-product .rihalo-product-breadcrumb a:first-of-type:not(:last-of-type),
    body.rihalo-etsy-product .rihalo-product-breadcrumb a:first-of-type:not(:last-of-type) + .rihalo-breadcrumb-separator {
        display: none;
    }

    body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery > .woocommerce-product-gallery__wrapper,
    body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery > .flex-viewport {
        border-radius: 11px;
    }

    body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery__trigger,
    body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery__trigger:hover,
    body.rihalo-etsy-product .rihalo-native-gallery-shell .woocommerce-product-gallery__trigger:focus {
        top: 12px !important;
        right: 12px !important;
        width: 42px !important;
        height: 42px !important;
    }

    body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav a {
        width: 40px !important;
        height: 40px !important;
        margin-top: -20px !important;
    }
    body.rihalo-etsy-product .rihalo-native-gallery-shell .flex-direction-nav a::before {
        font-size: 30px !important;
    }

    body.rihalo-etsy-product .pswp__button--close {
        top: 12px !important;
        right: 12px !important;
        width: 46px !important;
        height: 46px !important;
    }
    body.rihalo-etsy-product .pswp__button--close::before,
    body.rihalo-etsy-product .pswp__button--close::after {
        top: 22px;
        left: 14px;
        width: 18px;
    }
    body.rihalo-etsy-product .pswp__button--arrow--left,
    body.rihalo-etsy-product .pswp__button--arrow--right,
    body.rihalo-etsy-product .pswp__button--arrow--prev,
    body.rihalo-etsy-product .pswp__button--arrow--next {
        width: 44px !important;
        height: 44px !important;
        margin-top: -22px !important;
    }
    body.rihalo-etsy-product .pswp__button--arrow--left { left: 8px !important; }
    body.rihalo-etsy-product .pswp__button--arrow--right { right: 8px !important; }
    body.rihalo-etsy-product .pswp__button--arrow--prev { left: 8px !important; }
    body.rihalo-etsy-product .pswp__button--arrow--next { right: 8px !important; }
}

/* Final mobile reset after legacy product-page responsive rules. */
@media (max-width: 600px) {
    body.rihalo-etsy-product .rihalo-product-breadcrumb {
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
    }
}
