.product-page {
    --product-ink: var(--store-ink, #2c2140);
    --product-muted: #5f5869;
    --product-line: #e6e1ea;
    --product-accent: var(--orbe-roxo);
    width: min(calc(100% - 3rem), 1160px);
    margin: 1.5rem auto 4rem;
    color: var(--product-ink);
}

.product-page :is(button, a, summary):focus-visible {
    outline: 2px solid var(--product-accent);
    outline-offset: 3px;
}

.product-breadcrumbs {
    display: flex;
    align-items: center;
    gap: .625rem;
    margin-bottom: 1rem;
    color: var(--product-muted);
    font-size: .8125rem;
}

.product-breadcrumbs a { padding-block: .55rem; }
.product-breadcrumbs a:hover { color: var(--product-accent); text-decoration: underline; }
.product-breadcrumbs i { font-size: .625rem; }

.product-overview {
    --product-photo-height: clamp(320px, 39vw, 500px);
    display: grid;
    grid-template-columns: minmax(0, 1.16fr) minmax(0, .84fr);
    grid-template-areas: "gallery purchase" "details purchase";
    gap: clamp(1.75rem, 4vw, 3rem) clamp(1.5rem, 4vw, 3.5rem);
    align-items: start;
}

.product-purchase-panel { grid-area: purchase; min-width: 0; }

@media (min-width: 992px) {
    .product-purchase-panel {
        display: flex;
        flex-direction: column;
        justify-content: center;
        min-block-size: var(--product-photo-height);
    }

    .product-purchase-panel[data-sticky-ready] {
        position: sticky;
        top: var(--product-sticky-top);
    }
}

.product-heading { margin-bottom: 1.125rem; }

.product-identity {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .375rem;
    margin-bottom: .25rem;
    font-size: .9375rem;
    font-weight: 750;
    line-height: 1.25;
}

.product-brand { color: var(--product-muted); overflow-wrap: anywhere; }
.product-identity-divider { color: var(--product-muted); font-weight: 500; }

.product-code-copy {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    min-height: 44px;
    padding: .125rem .375rem;
    border: 0;
    border-radius: 7px;
    background: transparent;
    color: var(--product-accent);
    font: inherit;
    font-variant-numeric: tabular-nums;
}

.product-code-copy i { font-size: .8125rem; }
.product-code-copy:hover, .product-code-copy[data-copied] { background: var(--store-wash); }

.product-heading h1 {
    margin: 0;
    font-size: clamp(1.65rem, 3vw, 2.375rem);
    font-weight: 800;
    letter-spacing: -.03em;
    line-height: 1.14;
    overflow-wrap: anywhere;
}

.product-gallery { grid-area: gallery; min-width: 0; }
.product-photo-stage {
    position: relative;
    height: var(--product-photo-height);
    border: 1px solid var(--product-line);
    border-radius: 16px;
    background: #fff;
    touch-action: pan-y pinch-zoom;
}

.product-main-photo {
    display: block;
    width: 100%;
    height: 100%;
    padding: clamp(1rem, 3vw, 2.5rem);
    border-radius: inherit;
}

a.product-main-photo { cursor: zoom-in; }
.product-main-photo picture, .product-main-photo img { display: block; width: 100%; height: 100%; }
.product-main-photo img { object-fit: contain; }

.product-gallery-nav, .product-photo-zoom {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 1px solid var(--product-line);
    border-radius: 50%;
    background: #fff;
    color: var(--product-ink);
    font-size: .875rem;
}

.product-photo-zoom { position: absolute; top: .75rem; right: .75rem; }
.product-gallery-nav:hover, a:hover > .product-photo-zoom { color: var(--product-accent); background: var(--store-wash); }
.product-gallery-nav:is(.gallery-previous, .gallery-next) {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
}
.gallery-previous { left: .75rem; }
.gallery-next { right: .75rem; }

.product-photo-count {
    flex: none;
    padding: .2rem .6rem;
    border: 1px solid var(--product-line);
    border-radius: 20px;
    background: #fff;
    color: var(--product-muted);
    font-size: .75rem;
    white-space: nowrap;
}

.product-gallery-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    margin-top: .5rem;
}

.product-thumbnails {
    display: flex;
    min-width: 0;
    gap: .5rem;
    padding: 4px;
    overflow: auto hidden;
    scrollbar-width: none;
}
.product-thumbnails::-webkit-scrollbar { display: none; }
.product-thumbnails button {
    display: grid;
    flex: 0 0 54px;
    place-items: center;
    width: 54px;
    height: 54px;
    padding: 4px;
    border: 1px solid var(--product-line);
    border-radius: 8px;
    background: #fff;
}
.product-thumbnails button[aria-pressed="true"] { border-color: var(--product-accent); box-shadow: inset 0 0 0 1px var(--product-accent); }
.product-thumbnails img { width: 100%; height: 100%; object-fit: contain; }

.product-offer {
    min-width: 0;
    padding-top: .25rem;
}
.product-price > span { color: var(--product-muted); font-size: .8125rem; }
.product-price-list { display: grid; gap: .375rem; margin-top: .3rem; }
.product-price-row {
    display: grid;
    grid-template-columns: clamp(20px, 2vw, 26px) minmax(0, 1fr);
    align-items: center;
    gap: .625rem;
}
.product-price-flag {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 1;
    border: 1px solid var(--product-line);
    border-radius: 50%;
    object-fit: cover;
}
.product-price strong {
    font-size: clamp(1.7rem, 3.4vw, 2.625rem);
    line-height: 1.15;
    letter-spacing: -.03em;
    font-weight: 800;
    color: var(--product-accent);
}
.product-price small {
    color: var(--product-muted);
    font-size: clamp(.9375rem, 1.5vw, 1.125rem);
    font-weight: 650;
}
.product-purchase-note { color: var(--product-muted); font-size: .8125rem; }
.product-price :is(strong, small), .product-mobile-dock strong, .product-related-link strong {
    font-variant-numeric: tabular-nums;
    overflow-wrap: anywhere;
}

.product-availability {
    display: flex;
    flex-wrap: wrap;
    gap: .375rem 1rem;
    margin: .9rem 0 1.125rem;
    font-size: .8125rem;
    font-weight: 650;
}
.product-availability i { margin-inline-end: .2rem; color: #156643; }
.product-purchase-actions { display: grid; grid-template-columns: 55px minmax(0, 1fr); gap: .75rem; }

.product-cart-action, .product-secondary-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .45rem;
    min-height: 48px;
    padding: .625rem .625rem;
    border: 1px solid var(--product-accent, var(--orbe-roxo));
    border-radius: 8px;
    background: var(--product-accent, var(--orbe-roxo));
    color: #fff;
    text-align: center;
    line-height: 1.2;
    font-size: .9rem;
    font-weight: 750;
}

.product-cart-action:hover { color: #fff; background: var(--store-chrome-start); }
.product-secondary-action { width: 44px; border-color: var(--product-line); background: #fff; color: var(--product-accent); }
.product-secondary-action:hover { background: var(--store-wash); color: var(--product-accent); }
.product-purchase-cart {
    width: 100%;
    border-color: var(--product-accent);
    background: var(--product-accent);
    color: #fff;
    font-size: 1.125rem;
}
.product-purchase-cart:hover { background: var(--store-chrome-start); color: #fff; }
.product-purchase-actions :is(.product-purchase-cart, .product-buy-link) { min-height: 55px; }

@media (prefers-reduced-motion: no-preference) {
    .product-buy-link { position: relative; }
    .product-buy-link::after {
        position: absolute;
        inset: 0;
        border-radius: inherit;
        outline: 2px solid #38a773;
        pointer-events: none;
        animation: product-buy-outline 2.6s ease-out infinite;
        content: "";
    }

    @keyframes product-buy-outline {
        0% { opacity: .58; outline-offset: 0; }
        62%, 100% { opacity: 0; outline-offset: 6px; }
    }
}
.product-purchase-note { margin: .75rem 0 0; }

.product-details { grid-area: details; min-width: 0; }
.product-related { margin-top: clamp(2rem, 5vw, 3.75rem); }
.product-details h2, .product-related h2 {
    margin: 0 0 1rem;
    font-size: clamp(1.25rem, 2.25vw, 1.75rem);
    font-weight: 800;
    letter-spacing: -.02em;
}

.product-detail-grid { display: grid; gap: .875rem; align-items: start; }
.product-specs { display: grid; gap: .875rem; }
.product-detail-panel {
    min-width: 0;
    background: #fff;
    border: 1px solid var(--product-line);
    border-radius: 14px;
}
.product-detail-panel summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    padding: .85rem 1rem;
    min-height: 48px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 750;
}
.product-detail-panel summary::-webkit-details-marker { display: none; }
.product-detail-panel summary::after {
    content: "";
    width: .5rem;
    height: .5rem;
    margin-inline-end: .25rem;
    border: solid var(--product-accent);
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}
.product-detail-panel[open] summary::after { transform: rotate(225deg); }
.product-description, .product-spec-table {
    margin: 0;
    padding: 0 1rem 1rem;
    font-size: .9rem;
    line-height: 1.65;
    overflow-wrap: anywhere;
}
.product-description > :last-child { margin-bottom: 0; }
.product-description :is(h2,h3,h4,h5,h6) { margin-block: .85rem .5rem; font-size: 1rem; font-weight: 750; }
.product-description :is(ul, ol) { padding-inline-start: 1.25rem; margin-bottom: .75rem; }
.product-description ul { list-style: disc; }
.product-description a { color: var(--product-accent); text-decoration: underline; }
.product-description pre { white-space: pre-wrap; }
.product-description table { display: block; max-width: 100%; overflow-x: auto; }
.product-spec-table > div {
    display: grid;
    grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr);
    gap: .5rem;
    padding: .5rem 0;
    border-top: 1px solid var(--product-line);
}
.product-spec-table dt { color: var(--product-muted); font-weight: 650; }
.product-spec-table dd { margin: 0; }

.product-card-list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .875rem; }
.product-related-item { display: flex; min-width: 0; }
.product-related-link {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-width: 0;
    border: 1px solid var(--product-line);
    border-radius: 14px;
    background: #fff;
    color: inherit;
}

.product-related-media {
    position: relative;
    aspect-ratio: 8 / 5;
    max-height: 170px;
    border-bottom: 1px solid var(--product-line);
}

.product-related-media img {
    position: absolute;
    inset: .65rem;
    width: calc(100% - 1.3rem);
    height: calc(100% - 1.3rem);
    object-fit: contain;
}

.product-related-content {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: .5rem;
    padding: .75rem .875rem;
}

.product-related-link h3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0;
    font-size: .875rem;
    line-height: 1.3;
    font-weight: 650;
    overflow-wrap: anywhere;
}
.product-related-link strong {
    margin-top: auto;
    padding-top: .125rem;
    color: var(--product-accent);
    font-size: clamp(1rem, 1.5vw, 1.2rem);
    line-height: 1.25;
}

.product-related-cta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .375rem;
    color: var(--product-accent);
    font-size: .8125rem;
    font-weight: 650;
}

.product-related-arrow {
    display: grid;
    flex: none;
    place-items: center;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    background: var(--store-wash);
    font-size: .75rem;
}

.product-related-link:is(:hover, :focus-visible) { border-color: var(--product-accent); }
.product-related-link:is(:hover, :focus-visible) .product-related-arrow { background: var(--product-accent); color: #fff; }

.product-unavailable-intro {
    padding: clamp(1.5rem, 5vw, 3rem);
    border: 1px solid var(--product-line);
    border-radius: 14px;
    background: #fff;
}
.product-unavailable-intro h1 { font-size: clamp(1.5rem, 3vw, 2.25rem); font-weight: 800; }

.product-lightbox {
    width: min(94vw, 980px);
    max-width: none;
    max-height: 94dvh;
    padding: .75rem;
    border: 0;
    border-radius: 14px;
    background: #fff;
    color: var(--product-ink);
}
.product-lightbox::backdrop { background: #1a1223db; }
.product-lightbox-toolbar { display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.product-lightbox-toolbar h2 { margin: 0; padding-inline-start: .25rem; font-size: .95rem; }
.product-lightbox-toolbar .product-photo-count { margin-inline-start: auto; }
.product-lightbox-photo {
    position: relative;
    height: min(76dvh, 790px);
    padding: .5rem 2.5rem 1.5rem;
    touch-action: pan-y pinch-zoom;
}
.product-lightbox-photo img { display: block; width: 100%; height: 100%; object-fit: contain; }
.product-lightbox-photo .gallery-previous { left: 0; }
.product-lightbox-photo .gallery-next { right: 0; }

.product-mobile-dock { display: none; }

@media (max-width: 991.98px) {
    .product-page { width: min(calc(100% - 2rem), 680px); }
    .product-overview {
        grid-template-columns: minmax(0, 1fr);
        grid-template-areas: "heading" "gallery" "offer" "details";
        gap: .625rem;
    }
    .product-purchase-panel { display: contents; }
    .product-heading { grid-area: heading; margin-bottom: 0; }
    .product-photo-stage { height: clamp(240px, 56vw, 375px); }
    .product-offer { grid-area: offer; }
    .product-details { margin-top: clamp(1.5rem, 4vw, 2.75rem); }
}

@media (max-width: 768px) {
    .product-page { width: calc(100% - 1.5rem); margin: .75rem auto 2.5rem; }
    .product-breadcrumbs { margin-bottom: .35rem; font-size: .75rem; }
    .product-heading h1 { font-size: clamp(1.2rem, 4.75vw, 1.575rem); }
    .product-identity { margin-bottom: .125rem; font-size: .875rem; }
    .product-photo-stage { height: clamp(160px, 49vw, 258px); border-radius: 12px; }
    .product-gallery:has(.product-gallery-controls) .product-photo-stage { height: clamp(174px, 53vw, 272px); }
    .product-main-photo { padding: .625rem 2.625rem; }
    .product-photo-zoom { width: 40px; height: 40px; top: .375rem; right: .375rem; }
    .product-gallery-nav { width: 42px; height: 42px; }
    .gallery-previous { left: .375rem; }
    .gallery-next { right: .375rem; }
    .product-gallery-controls { margin-top: .25rem; }
    .product-thumbnails button { flex-basis: 44px; width: 44px; height: 44px; }
    .product-price strong { font-size: clamp(1.5rem, 6.3vw, 2rem); }
    .product-availability { margin: .5rem 0 .75rem; font-size: .75rem; }
    .product-purchase-actions { grid-template-columns: 48px minmax(0, 1fr); gap: .5rem; }
    .product-purchase-actions :is(.product-purchase-cart, .product-buy-link) { min-height: 48px; }
    .product-card-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .625rem; }
    .product-related-content { padding: .625rem; }

    body[data-orbe-product] { padding-bottom: var(--product-dock-height, 0px); }
    body[data-orbe-product] .whatsapp-float { display: none; }
    body[data-orbe-product] .cart-feedback { bottom: calc(var(--orbe-mobile-nav-height) + var(--product-dock-height, 0px) + .6rem); }
    body[data-orbe-product] .whatsapp-contact-panel.is-mobile-nav-origin {
        bottom: calc(var(--orbe-mobile-nav-height) + max(18px, var(--product-dock-height, 0px) + 8px));
    }
    .product-mobile-dock:not([hidden]) {
        position: fixed;
        inset: auto 0 var(--orbe-mobile-nav-height);
        z-index: 1030;
        display: grid;
        grid-template-columns: minmax(0, 1fr) 44px minmax(92px, auto);
        align-items: center;
        gap: .5rem;
        padding: .5rem max(.75rem, env(safe-area-inset-right)) 1.25rem max(.75rem, env(safe-area-inset-left));
        border-top: 1px solid var(--store-line);
        background: var(--store-wash);
        box-shadow: 0 -4px 16px #1b102215;
    }
    .product-mobile-dock strong { font-size: clamp(1rem, 4.8vw, 1.25rem); }
    .product-mobile-dock .product-buy-link { padding-inline: .55rem; font-size: .75rem; }
}
