/*
 * Redesigned product page (/product/{id}) — prefix pdp-.
 * Uses the storefront kit tokens (--sf-*, storefront.css). The product cards in the two strips are the
 * listing pages' cards (.plp-card, listing.css).
 */

.pdp-page [x-cloak] {
    display: none !important;
}

.pdp-page {
    /* flow-root keeps the last strip's bottom margin inside the tinted page. */
    display: flow-root;
    background: var(--sf-bg);
    font-family: var(--sf-font);
    color: var(--sf-ink);
}

/* ---------- Layout: one column on phones, gallery + details from 900px ---------- */

.pdp {
    display: grid;
    gap: 20px;
    max-width: var(--sf-max-width);
    margin: 0 auto;
    padding: 12px 20px 40px;
}

.pdp__media,
.pdp__info {
    position: relative;
    min-width: 0;
}

@media (min-width: 640px) {
    .pdp {
        padding: 16px 24px 48px;
    }
}

@media (min-width: 900px) {
    .pdp {
        grid-template-columns: 440px minmax(0, 1fr);
        gap: 40px;
        align-items: start;
        padding: 16px 32px 56px;
    }

    .pdp__media {
        position: sticky;
        top: calc(var(--sf-nav-h) + 16px);
    }
}

@media (min-width: 1100px) {
    .pdp {
        grid-template-columns: 480px minmax(0, 1fr);
    }
}

/* ---------- Gallery ---------- */

.pdp-tag {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 5;
    padding: 3px 10px;
    border-radius: var(--sf-radius-pill);
    background: #64748b;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #fff;
    pointer-events: none;
}

.pdp-gal__main {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: 1 / 1;
    margin-bottom: 10px;
    overflow: hidden;
    border: 1.5px solid var(--sf-border);
    border-radius: 20px;
    background: #fff;
}

.pdp-gal__main .carousel-inner,
.pdp-gal__main .carousel-item {
    height: 100%;
}

.pdp-gal__open {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    padding: 16px;
    border: 0;
    background: transparent;
    cursor: zoom-in;
}

.pdp-gal__open img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.pdp-gal__nav,
.pdp-gal__zoom {
    position: absolute;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1.5px solid var(--sf-border);
    background: rgba(255, 255, 255, .9);
    color: var(--sf-ink);
    cursor: pointer;
    transition: border-color .15s, color .15s;
}

.pdp-gal__nav {
    top: 50%;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    transform: translateY(-50%);
}

.pdp-gal__nav--prev {
    left: 10px;
}

.pdp-gal__nav--next {
    right: 10px;
}

.pdp-gal__zoom {
    right: 10px;
    bottom: 10px;
    width: 32px;
    height: 32px;
    border-radius: var(--sf-radius-sm);
    color: var(--sf-text);
}

.pdp-gal__nav:hover,
.pdp-gal__zoom:hover {
    border-color: var(--sf-primary);
    color: var(--sf-primary);
}

.pdp-gal__nav:focus-visible,
.pdp-gal__zoom:focus-visible,
.pdp-gal__open:focus-visible,
.pdp-gal__thumb:focus-visible {
    outline: 2px solid var(--sf-primary);
    outline-offset: 2px;
}

/* Bootstrap's .carousel-indicators (it marks the active thumbnail) restyled as a thumbnail strip. */
.pdp-gal .pdp-gal__thumbs {
    position: static;
    z-index: auto;
    display: flex;
    justify-content: flex-start;
    gap: 8px;
    margin: 0;
    padding: 0 0 2px;
    overflow-x: auto;
    scrollbar-width: none;
    list-style: none;
}

.pdp-gal .pdp-gal__thumbs::-webkit-scrollbar {
    display: none;
}

.pdp-gal .pdp-gal__thumbs .pdp-gal__thumb {
    box-sizing: border-box;
    flex: 0 0 auto;
    width: 70px;
    height: 70px;
    margin: 0;
    padding: 2px;
    overflow: hidden;
    border: 2px solid var(--sf-border);
    border-radius: var(--sf-radius-sm);
    background: #fff;
    text-indent: 0;
    opacity: 1;
    cursor: pointer;
    transition: border-color .15s;
}

.pdp-gal .pdp-gal__thumbs .pdp-gal__thumb.active,
.pdp-gal .pdp-gal__thumbs .pdp-gal__thumb:hover {
    border-color: var(--sf-primary);
}

.pdp-gal__thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

@media (min-width: 640px) {
    .pdp-gal .pdp-gal__thumbs .pdp-gal__thumb {
        width: 80px;
        height: 80px;
    }
}

@media (min-width: 900px) {
    .pdp-gal .pdp-gal__thumbs .pdp-gal__thumb {
        width: 90px;
        height: 90px;
    }
}

.pdp-gal__main--empty {
    cursor: default;
}

.pdp-gal__ph {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.pdp-gal__ph i {
    font-size: 4.5rem;
    color: #d0c4d8;
}

.pdp-gal__ph span {
    font-size: 12px;
    font-weight: 600;
    color: var(--sf-muted);
}

.pdp-video-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: 12px;
    padding: 8px 16px;
    border: 1.5px solid var(--sf-primary);
    border-radius: var(--sf-radius-pill);
    background: #fff;
    font-size: 13px;
    font-weight: 700;
    color: var(--sf-primary);
    cursor: pointer;
    transition: background .15s, color .15s;
}

.pdp-video-btn:hover {
    background: var(--sf-primary);
    color: #fff;
}

/* ---------- Name + details ---------- */

.pdp-title {
    margin: 0 0 14px;
    font-size: clamp(18px, 5vw, 26px);
    font-weight: 900;
    line-height: 1.2;
    letter-spacing: -.025em;
    color: var(--sf-ink);
}

.pdp-title .bi-gem {
    margin-right: 4px;
    font-size: .8em;
    vertical-align: .05em;
    color: var(--sf-primary);
}

.pdp-specs {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    margin: 0 0 16px;
    overflow: hidden;
    border: 1px solid var(--sf-border);
    border-radius: 10px;
    background: #fff;
}

.pdp-spec {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 6px;
    min-width: 0;
    padding: 9px 12px;
    font-size: 12.5px;
}

.pdp-spec dt {
    display: flex;
    align-items: center;
    gap: 5px;
    margin: 0;
    font-weight: 700;
    white-space: nowrap;
    color: var(--sf-text);
}

.pdp-spec dt i {
    font-size: 13px;
    color: var(--sf-primary-mid);
}

.pdp-spec dd {
    min-width: 0;
    margin: 0;
    overflow-wrap: anywhere;
    color: var(--sf-ink);
}

.pdp-spec dd a {
    font-weight: 600;
    color: var(--sf-primary);
    text-decoration: none;
}

.pdp-spec dd a:hover {
    text-decoration: underline;
}

.pdp-spec--mono dd {
    font-family: var(--sf-mono);
    font-size: 12px;
}

.pdp-price {
    display: inline-flex;
    align-items: center;
    padding: 4px 14px;
    border-radius: var(--sf-radius-pill);
    background: var(--sf-primary);
    font-size: 16px;
    font-weight: 900;
    color: #fff;
}

@media (max-width: 600px) {
    .pdp-specs {
        grid-template-columns: minmax(0, 1fr);
    }

    .pdp-spec--gap {
        display: none;
    }
}

/* ---------- Notices ---------- */

.pdp-notes {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 12px;
}

/* No notice for this product: no box and no gap. */
.pdp-notes:not(:has(.pdp-note)) {
    display: none;
}

.pdp-note {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 10px 12px;
    border: 1px solid;
    border-radius: var(--sf-radius);
    font-size: 12.5px;
    font-weight: 600;
    line-height: 1.5;
}

.pdp-note > i {
    flex-shrink: 0;
    font-size: 15px;
    line-height: 1.3;
}

.pdp-note a {
    font-weight: 700;
    color: inherit;
    text-decoration: underline;
}

.pdp-note--warn {
    border-color: #f5a623;
    background: #fff8eb;
    color: var(--sf-warning-dark);
}

.pdp-note--warn > i {
    color: #d97706;
}

.pdp-note--accent {
    border-color: #c4b5fd;
    background: #ede9fe;
    color: #5b21b6;
}

.pdp-note--promo {
    border-color: var(--sf-danger-border);
    background: var(--sf-danger-soft);
    color: #991b1b;
}

.pdp-note--special {
    border-color: var(--sf-warning-border);
    background: var(--sf-warning-soft);
    color: var(--sf-warning-dark);
}

.pdp-note--special > i {
    color: #d97706;
}

.pdp-note--danger {
    border-color: #f5c6cb;
    background: #fdecea;
    color: #721c24;
}

.pdp-note--plain {
    align-items: center;
    border-color: var(--sf-border);
    background: #fff;
    color: var(--sf-primary);
}

/* ---------- MAP agreements + size charts ---------- */

.pdp-links {
    margin-bottom: 16px;
}

.pdp-links__hd {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 0 0 6px;
    font-size: 12.5px;
    font-weight: 700;
    color: var(--sf-primary);
}

.pdp-links__list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.pdp-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    min-height: 28px;
    padding: 4px 10px;
    border: 1.5px solid var(--sf-border);
    border-radius: var(--sf-radius-pill);
    background: #fff;
    font-size: 11.5px;
    font-weight: 600;
    color: var(--sf-text);
    text-decoration: none;
    transition: border-color .12s, color .12s;
}

.pdp-chip:hover {
    border-color: var(--sf-primary);
    color: var(--sf-primary);
}

/* ---------- Buying ---------- */

.pdp-buy {
    margin: 18px 0;
}

.pdp-buy__row {
    display: flex;
    align-items: stretch;
    gap: 10px;
}

.pdp-qty {
    display: flex;
    flex-shrink: 0;
    align-items: center;
    overflow: hidden;
    border: 2px solid var(--sf-border);
    border-radius: 10px;
    background: var(--sf-bg);
}

.pdp-qty__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 50px;
    padding: 0;
    border: 0;
    background: transparent;
    font-size: 20px;
    font-weight: 700;
    color: var(--sf-text);
    cursor: pointer;
    transition: background .12s, color .12s;
}

.pdp-qty__btn:hover {
    background: var(--sf-primary-soft);
    color: var(--sf-primary);
}

.pdp-qty__val {
    width: 52px;
    height: 50px;
    padding: 0;
    border: 0;
    border-right: 2px solid var(--sf-border);
    border-left: 2px solid var(--sf-border);
    outline: none;
    background: #fff;
    font-family: var(--sf-font);
    font-size: 15px;
    font-weight: 800;
    text-align: center;
    color: var(--sf-ink);
    -moz-appearance: textfield;
}

.pdp-qty__val::-webkit-outer-spin-button,
.pdp-qty__val::-webkit-inner-spin-button,
.pdp-sbar__qty input::-webkit-outer-spin-button,
.pdp-sbar__qty input::-webkit-inner-spin-button {
    margin: 0;
    -webkit-appearance: none;
}

/* An empty box adds 1, so the placeholder reads as the value. */
.pdp-qty__val::placeholder,
.pdp-sbar__qty input::placeholder {
    color: inherit;
    opacity: 1;
}

.pdp-qty__val:focus-visible {
    box-shadow: inset 0 0 0 2px var(--sf-primary);
}

.pdp-btn {
    display: flex;
    flex: 1;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-width: 0;
    min-height: 50px;
    padding: 0 16px;
    border: 2px solid var(--sf-primary);
    border-radius: 10px;
    background: var(--sf-primary);
    box-shadow: 0 4px 14px rgba(123, 45, 139, .3);
    font-family: var(--sf-font);
    font-size: 14px;
    font-weight: 800;
    white-space: nowrap;
    color: #fff;
    text-decoration: none;
    cursor: pointer;
    transition: background .15s, box-shadow .15s, transform .1s;
}

.pdp-btn:hover {
    border-color: var(--sf-primary-dark);
    background: var(--sf-primary-dark);
    box-shadow: 0 6px 22px rgba(123, 45, 139, .4);
    color: #fff;
    transform: translateY(-1px);
}

.pdp-btn:focus-visible,
.pdp-icon-btn:focus-visible,
.pdp-qty__btn:focus-visible,
.pdp-pill:focus-visible,
.pdp-acc__hd:focus-visible,
.pdp-link-btn:focus-visible {
    outline: 2px solid var(--sf-primary);
    outline-offset: 2px;
}

.pdp-btn:disabled {
    opacity: .7;
    cursor: progress;
    transform: none;
}

/* Out of stock still adds (backorder, as today), so the button stays but is outlined. */
.pdp-btn.is-oos {
    border-color: var(--sf-border);
    background: #fff;
    box-shadow: none;
    color: var(--sf-text);
}

.pdp-btn.is-oos:hover {
    border-color: var(--sf-primary);
    background: #fff;
    color: var(--sf-primary);
}

.pdp-btn--special {
    border-color: var(--sf-primary);
    background: #fff;
    box-shadow: none;
    color: var(--sf-primary);
}

.pdp-btn--special:hover {
    background: var(--sf-primary);
    color: #fff;
}

.pdp-btn--ghost {
    border-color: var(--sf-primary);
    background: #fff;
    box-shadow: none;
    color: var(--sf-primary);
}

.pdp-btn--ghost:hover {
    background: var(--sf-primary-soft);
    color: var(--sf-primary-dark);
}

.pdp-icon-btn {
    display: flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    width: 50px;
    padding: 0;
    border: 1.5px solid var(--sf-border);
    border-radius: 10px;
    background: #fff;
    font-size: 17px;
    color: var(--sf-text);
    cursor: pointer;
    transition: border-color .15s, color .15s;
}

.pdp-icon-btn:hover {
    border-color: var(--sf-primary);
    color: var(--sf-primary);
}

.pdp-icon-btn.is-on {
    border-color: var(--sf-danger);
    background: #fff8f8;
    color: var(--sf-danger);
}

.pdp-buy__error {
    margin-top: 8px;
    font-size: 12.5px;
    font-weight: 600;
    color: var(--sf-danger);
}

.pdp-buy__extras {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.pdp-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 13px;
    border: 1.5px solid;
    border-radius: var(--sf-radius-pill);
    font-family: var(--sf-font);
    font-size: 12.5px;
    font-weight: 700;
    line-height: 1.4;
}

.pdp-pill--cart {
    border-color: var(--sf-success-border);
    background: #dcfce7;
    color: var(--sf-success);
}

.pdp-pill--watch {
    border-color: var(--sf-warning-border);
    background: var(--sf-warning-soft);
    color: var(--sf-warning-dark);
}

.pdp-pill--notify {
    border-color: var(--sf-primary);
    background: #fff;
    color: var(--sf-primary);
    cursor: pointer;
    transition: background .12s, color .12s;
}

.pdp-pill--notify:hover {
    background: var(--sf-primary);
    color: #fff;
}

.pdp-buy__guest {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.pdp-buy__guest .pdp-btn {
    flex: 1 1 240px;
}

@media (max-width: 480px) {
    .pdp-buy__row {
        gap: 6px;
    }

    .pdp-qty__btn {
        width: 34px;
        height: 44px;
    }

    .pdp-qty__val {
        width: 40px;
        height: 44px;
    }

    .pdp-btn {
        min-height: 44px;
        padding: 0 10px;
        font-size: 13px;
    }

    .pdp-icon-btn {
        width: 44px;
    }
}

/* ---------- Sections (Description, Attributes, Item Order History, Product Images) ---------- */

.pdp-accs {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
}

/* Item Order History is its own Livewire component; its host box must not add a gap when it is empty. */
.pdp-acc-host {
    display: contents;
}

.pdp-acc {
    overflow: hidden;
    border: 1.5px solid var(--sf-border);
    border-radius: var(--sf-radius-lg);
    background: #fff;
}

.pdp-acc__title {
    margin: 0;
    font-size: inherit;
}

.pdp-acc__hd {
    display: flex;
    align-items: center;
    gap: 9px;
    width: 100%;
    padding: 14px 16px;
    border: 0;
    background: transparent;
    font-family: var(--sf-font);
    font-size: 14px;
    font-weight: 800;
    text-align: left;
    color: var(--sf-ink);
    cursor: pointer;
}

.pdp-acc__hd:hover {
    background: var(--sf-bg);
}

.pdp-acc__ic {
    font-size: 15px;
    color: var(--sf-primary);
}

.pdp-acc__count {
    padding: 1px 8px;
    border-radius: var(--sf-radius-pill);
    background: var(--sf-primary-soft);
    font-size: 11px;
    font-weight: 700;
    color: var(--sf-primary);
}

.pdp-acc__ch {
    margin-left: auto;
    font-size: 13px;
    color: var(--sf-muted);
    transition: transform .2s;
}

.pdp-acc__hd[aria-expanded="true"] .pdp-acc__ch {
    transform: rotate(180deg);
}

.pdp-acc__body {
    padding: 0 16px 16px;
}

.pdp-acc__text {
    font-size: 13.5px;
    line-height: 1.75;
    color: var(--sf-text);
    overflow-wrap: anywhere;
}

.pdp-acc__text ul {
    margin: 8px 0 0;
    padding-left: 18px;
}

.pdp-acc__text li {
    margin-bottom: 3px;
}

.pdp-acc__text img {
    max-width: 100%;
    height: auto;
}

.pdp-acc__tools {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 10px;
}

.pdp-attrs {
    width: 100%;
    border-collapse: collapse;
}

.pdp-attrs tr {
    border-bottom: 1px solid var(--sf-border);
}

.pdp-attrs tr:last-child {
    border-bottom: 0;
}

.pdp-attrs th,
.pdp-attrs td {
    padding: 8px 4px;
    vertical-align: top;
}

.pdp-attrs th {
    width: 36%;
    padding-right: 12px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .05em;
    text-transform: uppercase;
    color: var(--sf-muted);
}

.pdp-attrs td {
    font-size: 13px;
    font-weight: 600;
    color: var(--sf-ink);
    overflow-wrap: anywhere;
}

.pdp-tbl-wrap {
    overflow-x: auto;
    border: 1px solid var(--sf-border);
    border-radius: var(--sf-radius);
}

.pdp-tbl {
    width: 100%;
    border-collapse: collapse;
    font-size: 12.5px;
}

.pdp-tbl th {
    padding: 9px 12px;
    border-bottom: 1px solid var(--sf-border);
    background: var(--sf-bg);
    font-weight: 700;
    text-align: left;
    white-space: nowrap;
    color: var(--sf-text);
}

.pdp-tbl td {
    padding: 9px 12px;
    border-bottom: 1px solid var(--sf-border);
    white-space: nowrap;
    color: var(--sf-ink);
}

.pdp-tbl tbody tr:last-child td {
    border-bottom: 0;
}

.pdp-tbl .pdp-tbl__num {
    text-align: right;
}

.pdp-link-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    font-family: var(--sf-font);
    font-size: 12px;
    font-weight: 700;
    color: var(--sf-primary);
    text-decoration: none;
    cursor: pointer;
}

.pdp-link-btn:hover {
    color: var(--sf-primary-dark);
    text-decoration: underline;
}

.pdp-acc__body > .pdp-link-btn {
    margin-top: 10px;
}

/* ---------- Recently Viewed + Frequently Purchased Together ---------- */

.pdp-strip {
    max-width: var(--sf-max-width);
    margin: 0 auto 32px;
    padding: 0 20px;
}

.pdp-strip__hd {
    margin: 0 0 14px;
    font-size: 14px;
    font-weight: 800;
    color: var(--sf-ink);
}

.pdp-strip__row {
    display: flex;
    gap: 12px;
    padding: 2px 2px 10px;
    overflow-x: auto;
    scrollbar-width: thin;
}

.pdp-strip__row > .plp-card {
    flex: 0 0 220px;
    width: 220px;
}

@media (min-width: 640px) {
    .pdp-strip {
        padding: 0 24px;
    }
}

/* Wide screens: five cards per row, more wrap to a new row (as today). Phones and tablets: one row that scrolls. */
@media (min-width: 900px) {
    .pdp-strip {
        padding: 0 32px;
    }

    .pdp-strip__row {
        display: grid;
        grid-template-columns: repeat(5, minmax(0, 1fr));
        overflow: visible;
    }

    .pdp-strip__row > .plp-card {
        width: auto;
    }
}

/* ---------- Full-size image overlay (product-image-lightbox.js moves it to <body>) ----------
   Same look as the current page, where these rules sit inline in the gallery view. */

body.product-image-lightbox-open .product-image-lightbox-overlay {
    pointer-events: auto;
}

.product-image-lightbox-overlay {
    position: fixed;
    inset: 0;
    z-index: 2147483000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.product-image-lightbox-overlay.is-open {
    display: flex;
}

.product-image-lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .55);
}

.product-image-lightbox-panel {
    position: relative;
    z-index: 1;
    width: min(1140px, 96vw);
    max-height: 96vh;
    overflow: hidden;
    border-radius: .5rem;
    background: #fff;
    box-shadow: 0 12px 40px rgba(0, 0, 0, .25);
}

.product-image-lightbox-close {
    position: absolute;
    top: .75rem;
    right: .75rem;
    z-index: 12;
}

.product-image-lightbox-body {
    position: relative;
    padding: 2.5rem 1rem 1.5rem;
}

.product-image-lightbox-stage {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: min(80vh, 720px);
    min-height: min(60vh, 480px);
    margin: 0 auto;
}

.product-image-lightbox-img {
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: 100%;
    object-fit: contain;
}

.product-image-lightbox-nav {
    position: absolute;
    top: 50%;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3.25rem;
    height: 3.25rem;
    padding: 0;
    border: 2px solid var(--sf-primary);
    border-radius: 50%;
    background-color: #fff;
    box-shadow: 0 2px 12px rgba(0, 0, 0, .18);
    color: var(--sf-primary);
    cursor: pointer;
    transform: translateY(-50%);
    transition: background-color .2s ease, color .2s ease, transform .2s ease, box-shadow .2s ease;
}

.product-image-lightbox-nav .bi {
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1;
}

.product-image-lightbox-nav:hover,
.product-image-lightbox-nav:focus-visible {
    background-color: var(--sf-primary);
    box-shadow: 0 4px 16px rgba(123, 45, 139, .35);
    color: #fff;
    outline: none;
}

.product-image-lightbox-nav:active {
    transform: translateY(-50%) scale(.96);
}

.product-image-lightbox-prev {
    left: 1rem;
}

.product-image-lightbox-next {
    right: 1rem;
}

@media (max-width: 767px) {
    .product-image-lightbox-nav {
        width: 2.75rem;
        height: 2.75rem;
    }

    .product-image-lightbox-nav .bi {
        font-size: 1.5rem;
    }

    .product-image-lightbox-prev {
        left: .35rem;
    }

    .product-image-lightbox-next {
        right: .35rem;
    }
}

/* ---------- Sticky bar on phones and tablets ---------- */

.pdp-sbar {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1010;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px max(10px, env(safe-area-inset-bottom));
    background: var(--sf-primary);
    box-shadow: 0 -3px 20px rgba(0, 0, 0, .22);
    visibility: hidden;
    transform: translateY(110%);
    transition: transform .22s cubic-bezier(.4, 0, .2, 1), visibility 0s linear .22s;
}

.pdp-sbar.is-shown {
    visibility: visible;
    transform: translateY(0);
    transition: transform .22s cubic-bezier(.4, 0, .2, 1);
}

.pdp-sbar__info {
    flex-shrink: 0;
}

.pdp-sbar__lbl {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .7);
}

.pdp-sbar__price {
    font-size: 20px;
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -.02em;
    color: #fff;
}

.pdp-sbar__qty {
    display: flex;
    flex-shrink: 0;
    align-items: center;
    overflow: hidden;
    border-radius: 10px;
    background: rgba(255, 255, 255, .15);
}

.pdp-sbar__q {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 40px;
    padding: 0;
    border: 0;
    background: transparent;
    font-size: 20px;
    font-weight: 700;
    color: #fff;
    cursor: pointer;
}

.pdp-sbar__qty input {
    width: 38px;
    height: 40px;
    padding: 0;
    border: 0;
    outline: none;
    background: rgba(255, 255, 255, .2);
    font-family: var(--sf-font);
    font-size: 14px;
    font-weight: 800;
    text-align: center;
    color: #fff;
    -moz-appearance: textfield;
}

.pdp-sbar__btn {
    display: flex;
    flex: 1;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-width: 0;
    height: 44px;
    padding: 0 8px;
    border: 0;
    border-radius: 10px;
    background: #fff;
    font-family: var(--sf-font);
    font-size: 13.5px;
    font-weight: 900;
    white-space: nowrap;
    color: var(--sf-primary);
    cursor: pointer;
}

.pdp-sbar__btn.is-oos {
    background: #e2d8ea;
    color: var(--sf-text);
}

.pdp-sbar__q:focus-visible,
.pdp-sbar__btn:focus-visible,
.pdp-sbar__qty input:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 1px;
}

@media (max-width: 899.98px) {
    /* While the bar shows, the page can scroll far enough that it never hides the end of the footer. */
    body:has(.pdp-sbar.is-shown) {
        padding-bottom: 64px;
    }
}

@media (max-width: 380px) {
    .pdp-sbar {
        gap: 8px;
        padding-right: 12px;
        padding-left: 12px;
    }

    .pdp-sbar__price {
        font-size: 17px;
    }
}

@media (min-width: 900px) {
    .pdp-sbar {
        display: none;
    }
}
