/* =========================================================
   PRODUCT DETAIL PAGE
   Gallery, buy box, tabs and the mobile sticky buy bar.
   ========================================================= */

.pd {
    --pd-ink: #321d1a;
    --pd-text: #6e6059;
    --pd-muted: #9a8c85;
    --pd-line: #eadfce;
    --pd-brand: #ac0060;
    --pd-brand-dark: #8a004d;
    --pd-gold: #cf9c2c;
    --pd-gold-dark: #b2872e;
    --pd-cream: #faf4e9;
    --pd-card: #ffffff;

    padding: 28px 0 8px;
    background: var(--pd-cream);
    color: var(--pd-ink);
    font-family: "Poppins", sans-serif;
}

/* ---------- Breadcrumb ---------- */

.pd-breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 26px;
    color: var(--pd-muted);
    font-family: "Jost", sans-serif;
    font-size: 13px;
}

.pd-breadcrumb a {
    color: var(--pd-text);
    transition: color .2s ease;
}

.pd-breadcrumb a:hover {
    color: var(--pd-brand);
}

.pd-breadcrumb i {
    font-size: 8px;
    color: #c9bbb0;
}

.pd-breadcrumb span {
    max-width: 320px;
    overflow: hidden;
    color: var(--pd-ink);
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ---------- Layout ---------- */

.pd-layout {
    display: grid;
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    gap: 56px;
    align-items: start;
}

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

.pd-gallery {
    position: sticky;
    top: 96px;
    display: flex;
    gap: 16px;
}

.pd-thumbs {
    display: flex;
    flex-direction: column;
    flex: 0 0 84px;
    gap: 12px;
    max-height: 640px;
    overflow-y: auto;
    scrollbar-width: none;
}

.pd-thumbs::-webkit-scrollbar {
    display: none;
}

.pd-thumb {
    flex: 0 0 auto;
    width: 84px;
    aspect-ratio: 4 / 5;
    padding: 0;
    overflow: hidden;
    border: 2px solid transparent;
    border-radius: 12px;
    background: #f1e8da;
    opacity: .65;
    cursor: pointer;
    transition: opacity .2s ease, border-color .2s ease, transform .2s ease;
}

.pd-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.pd-thumb:hover {
    opacity: 1;
}

.pd-thumb.active {
    border-color: var(--pd-brand);
    opacity: 1;
}

.pd-stage {
    position: relative;
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    border-radius: 22px;
    background: #f1e8da;
    box-shadow: 0 18px 50px rgba(50, 29, 26, .08);
}

.pd-track {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    outline: none;
}

.pd-track::-webkit-scrollbar {
    display: none;
}

.pd-slide {
    flex: 0 0 100%;
    aspect-ratio: 4 / 5;
    max-height: 640px;
    overflow: hidden;
    scroll-snap-align: start;
    cursor: zoom-in;
}

.pd-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .25s ease;
}

.pd-slide.zooming img {
    transform: scale(1.8);
}

.pd-stage-badges {
    position: absolute;
    top: 18px;
    left: 18px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    pointer-events: none;
}

.pd-badge {
    padding: 6px 12px;
    border-radius: 30px;
    background: var(--pd-ink);
    color: #ffffff;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .6px;
    text-transform: uppercase;
}

.pd-badge-new {
    background: var(--pd-brand);
}

.pd-badge-off {
    background: var(--pd-gold);
}

.pd-badge[hidden] {
    display: none;
}

.pd-nav {
    position: absolute;
    top: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, .92);
    color: var(--pd-ink);
    box-shadow: 0 6px 18px rgba(0, 0, 0, .12);
    opacity: 0;
    transform: translateY(-50%);
    transition: opacity .2s ease, background .2s ease, color .2s ease;
}

.pd-nav-prev {
    left: 16px;
}

.pd-nav-next {
    right: 16px;
}

.pd-stage:hover .pd-nav,
.pd-nav:focus-visible {
    opacity: 1;
}

.pd-nav:hover {
    background: var(--pd-brand);
    color: #ffffff;
}

.pd-counter {
    position: absolute;
    right: 16px;
    bottom: 16px;
    padding: 5px 12px;
    border-radius: 30px;
    background: rgba(50, 29, 26, .7);
    color: #ffffff;
    font-size: 12px;
    font-weight: 500;
    pointer-events: none;
}

.pd-dots {
    display: none;
}

/* ---------- Info column ---------- */

.pd-info {
    min-width: 0;
}

.pd-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
    font-family: "Jost", sans-serif;
}

.pd-category {
    padding: 5px 12px;
    border-radius: 30px;
    background: rgba(207, 156, 44, .14);
    color: var(--pd-gold-dark);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.pd-category:hover {
    color: var(--pd-brand);
}

.pd-sku {
    color: var(--pd-muted);
    font-size: 12px;
    letter-spacing: .4px;
}

.pd-title {
    margin: 0 0 14px;
    color: var(--pd-ink);
    font-family: "Playfair Display", serif;
    font-size: 40px;
    font-weight: 400;
    line-height: 1.2;
}

.pd-rating {
    display: inline-flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
    color: var(--pd-text);
    font-size: 13px;
}

.pd-rating strong {
    color: var(--pd-ink);
    font-weight: 600;
}

.pd-rating:hover span {
    color: var(--pd-brand);
}

/* Price */

.pd-price-box {
    margin-bottom: 20px;
    padding: 18px 20px;
    border: 1px solid var(--pd-line);
    border-radius: 16px;
    background: var(--pd-card);
}

.pd-price {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.pd-price-now {
    color: var(--pd-ink);
    font-size: 30px;
    font-weight: 600;
    line-height: 1.1;
}

.pd-price del {
    color: var(--pd-muted);
    font-size: 17px;
}

.pd-off {
    padding: 4px 10px;
    border-radius: 30px;
    background: rgba(172, 0, 96, .09);
    color: var(--pd-brand);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .3px;
}

.pd-price [hidden],
.pd-price-note [hidden] {
    display: none;
}

.pd-price-note {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
    margin: 10px 0 0;
    color: var(--pd-muted);
    font-size: 12px;
}

.pd-saving {
    color: #1f8a4c;
    font-weight: 600;
}

.pd-lead {
    margin: 0 0 22px;
    color: var(--pd-text);
    font-size: 14.5px;
    line-height: 1.8;
}

/* Variants */

.pd-block {
    margin-bottom: 18px;
}

.pd-block-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
    color: var(--pd-text);
    font-size: 14px;
}

.pd-block-head strong {
    color: var(--pd-ink);
    font-weight: 600;
}

.pd-block-head a {
    color: var(--pd-brand);
    font-size: 13px;
    font-weight: 500;
}

.pd-variants {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.pd .pd-variant {
    position: relative;
    min-width: 56px;
    height: 44px;
    padding: 0 18px;
    overflow: hidden;
    border: 1.5px solid #dccfbf;
    border-radius: 30px;
    background: var(--pd-card);
    color: var(--pd-ink);
    font-family: "Poppins", sans-serif;
    font-size: 13.5px;
    font-weight: 500;
    transition: border-color .2s ease, background .2s ease, color .2s ease, box-shadow .2s ease;
}

.pd .pd-variant:hover:not([disabled]) {
    border-color: var(--pd-brand);
    color: var(--pd-brand);
}

.pd .pd-variant.active {
    border-color: var(--pd-brand);
    background: var(--pd-brand);
    color: #ffffff;
    box-shadow: 0 6px 16px rgba(172, 0, 96, .25);
}

.pd-error {
    margin: 10px 0 0;
    color: #c0292b;
    font-size: 13px;
}

/* Stock */

.pd-stock {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    padding: 6px 14px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 500;
}

.pd-stock i {
    font-size: 7px;
}

.pd-stock-in {
    background: #e7f5ec;
    color: #1f8a4c;
}

.pd-stock-low {
    background: #fff3de;
    color: #b36b00;
}

.pd-stock-out {
    background: #fdecec;
    color: #c0292b;
}

/* Buy buttons */

.pd-buy {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
}

.pd-qty {
    display: flex;
    align-items: center;
    flex: 0 0 136px;
    height: 54px;
    border: 1.5px solid #dccfbf;
    border-radius: 30px;
    background: var(--pd-card);
}

.pd-qty button {
    width: 44px;
    height: 100%;
    border: 0;
    background: none;
    color: var(--pd-ink);
    font-size: 13px;
}

.pd-qty button:hover {
    color: var(--pd-brand);
}

.pd-qty input {
    width: 100%;
    min-width: 0;
    border: 0;
    background: none;
    color: var(--pd-ink);
    font-size: 15px;
    font-weight: 600;
    text-align: center;
    outline: none;
}

.pd-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    height: 54px;
    padding: 0 24px;
    border: 0;
    border-radius: 30px;
    font-family: "Poppins", sans-serif;
    font-size: 15px;
    font-weight: 500;
    letter-spacing: .2px;
    transition: background .2s ease, transform .15s ease, box-shadow .2s ease;
}

.pd-btn:active:not([disabled]) {
    transform: scale(.98);
}

.pd-btn[disabled] {
    background: #d8cfc8 !important;
    box-shadow: none !important;
    cursor: not-allowed;
}

.pd-btn-cart {
    flex: 1 1 auto;
    background: var(--pd-brand);
    color: #ffffff;
    box-shadow: 0 10px 24px rgba(172, 0, 96, .25);
}

.pd-btn-cart:hover {
    background: var(--pd-brand-dark);
    color: #ffffff;
}

.pd-btn-cart.cart-success {
    background: #1f8a4c;
    box-shadow: 0 10px 24px rgba(31, 138, 76, .25);
}

.pd-btn-buy {
    width: 100%;
    background: var(--pd-gold);
    color: #ffffff;
    box-shadow: 0 10px 24px rgba(207, 156, 44, .25);
}

.pd-btn-buy:hover {
    background: var(--pd-gold-dark);
    color: #ffffff;
}

.pd-actions {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 28px;
    margin: 16px 0 26px;
}

.pd-actions a,
.pd-actions button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0;
    border: 0;
    background: none;
    color: var(--pd-text);
    font-size: 13.5px;
    font-weight: 500;
    transition: color .2s ease;
}

.pd-actions a:hover,
.pd-actions button:hover {
    color: var(--pd-brand);
}

.pd-actions .fa-whatsapp {
    color: #25d366;
    font-size: 17px;
}

/* Perks */

.pd-perks {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin-bottom: 20px;
    border: 1px solid var(--pd-line);
    border-radius: 16px;
    background: var(--pd-card);
}

.pd-perk {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 18px 10px;
    text-align: center;
}

.pd-perk + .pd-perk {
    border-left: 1px solid var(--pd-line);
}

.pd-perk > i {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(172, 0, 96, .08);
    color: var(--pd-brand);
    font-size: 15px;
}

.pd-perk strong {
    display: block;
    color: var(--pd-ink);
    font-size: 12.5px;
    font-weight: 600;
}

.pd-perk span {
    display: block;
    margin-top: 2px;
    color: var(--pd-muted);
    font-size: 11.5px;
    line-height: 1.5;
}

/* Quick specs */

.pd-specs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin: 0;
}

.pd-specs div {
    padding: 12px 16px;
    border-radius: 12px;
    background: rgba(207, 156, 44, .08);
}

.pd-specs dt {
    margin-bottom: 3px;
    color: var(--pd-muted);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: .6px;
    text-transform: uppercase;
}

.pd-specs dd {
    margin: 0;
    color: var(--pd-ink);
    font-size: 14px;
    font-weight: 500;
    overflow-wrap: anywhere;
}

/* ---------- Tabs ---------- */

.pd-tabs-card {
    margin-top: 64px;
    padding: 10px 36px 36px;
    border: 1px solid var(--pd-line);
    border-radius: 22px;
    background: var(--pd-card);
}

.pd-tabs {
    display: flex;
    gap: 34px;
    margin-bottom: 28px;
    overflow-x: auto;
    border-bottom: 1px solid var(--pd-line);
    scrollbar-width: none;
}

.pd-tabs::-webkit-scrollbar {
    display: none;
}

.pd-tab {
    position: relative;
    flex: 0 0 auto;
    padding: 20px 0 16px;
    border: 0;
    background: none;
    color: var(--pd-muted);
    font-family: "Poppins", sans-serif;
    font-size: 15px;
    font-weight: 500;
    transition: color .2s ease;
}

.pd-tab:hover {
    color: var(--pd-ink);
}

.pd-tab.active {
    color: var(--pd-brand);
}

.pd-tab.active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -1px;
    height: 2px;
    border-radius: 2px;
    background: var(--pd-brand);
}

.pd-panel {
    max-width: 860px;
}

.pd-panel h3 {
    margin: 0 0 14px;
    color: var(--pd-ink);
    font-family: "Playfair Display", serif;
    font-size: 26px;
    font-weight: 400;
}

.pd-panel p {
    color: var(--pd-text);
    font-size: 14.5px;
    line-height: 1.85;
}

.pd-panel a {
    color: var(--pd-brand);
    font-weight: 500;
}

.pd-table {
    width: 100%;
    max-width: 620px;
    border-collapse: collapse;
    font-size: 14px;
}

.pd-table th,
.pd-table td {
    padding: 13px 0;
    border-bottom: 1px solid var(--pd-line);
    vertical-align: top;
}

.pd-table th {
    width: 38%;
    color: var(--pd-muted);
    font-weight: 500;
}

.pd-table td {
    color: var(--pd-ink);
    font-weight: 500;
}

.pd-policy {
    display: grid;
    gap: 14px;
}

.pd-policy > div {
    display: flex;
    gap: 16px;
    padding: 18px 20px;
    border-radius: 14px;
    background: var(--pd-cream);
}

.pd-policy i {
    flex: 0 0 auto;
    margin-top: 4px;
    color: var(--pd-brand);
    font-size: 18px;
}

.pd-policy p {
    margin: 0;
}

.pd-policy strong {
    color: var(--pd-ink);
}

/* ---------- Mobile sticky buy bar ---------- */

.pd-sticky {
    display: none;
}

/* ---------- Tablet ---------- */

@media (max-width: 1199px) {
    .pd-layout {
        gap: 40px;
    }

    .pd-title {
        font-size: 34px;
    }
}

@media (max-width: 991px) {
    .pd {
        padding: 18px 0 8px;
    }

    .pd-layout {
        grid-template-columns: minmax(0, 1fr);
        gap: 28px;
    }

    .pd-gallery {
        position: static;
    }

    .pd-sticky {
        position: fixed;
        left: 12px;
        right: 12px;
        bottom: 12px;
        z-index: 1030;
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 10px 10px 10px 12px;
        border: 1px solid var(--pd-line, #eadfce);
        border-radius: 18px;
        background: rgba(255, 255, 255, .97);
        box-shadow: 0 12px 34px rgba(50, 29, 26, .16);
        backdrop-filter: blur(12px);
        opacity: 0;
        pointer-events: none;
        transform: translateY(20px);
        transition: opacity .25s ease, transform .25s ease;
    }

    .pd-sticky.show {
        opacity: 1;
        pointer-events: auto;
        transform: translateY(0);
    }

    .pd-sticky img {
        width: 44px;
        height: 54px;
        flex: 0 0 auto;
        border-radius: 10px;
        object-fit: cover;
    }

    .pd-sticky-text {
        flex: 1 1 auto;
        min-width: 0;
        font-family: "Poppins", sans-serif;
    }

    .pd-sticky-text strong {
        display: block;
        overflow: hidden;
        color: #321d1a;
        font-size: 13px;
        font-weight: 500;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .pd-sticky-text span {
        color: #321d1a;
        font-size: 15px;
        font-weight: 700;
    }

    .pd-sticky .pd-btn {
        flex: 0 0 auto;
        height: 46px;
        padding: 0 22px;
        border-radius: 14px;
        background: #ac0060;
        color: #ffffff;
        font-size: 14px;
    }

    .pd-sticky .pd-btn.cart-success {
        background: #1f8a4c;
    }
}

/* ---------- Phones ---------- */

@media (max-width: 768px) {
    .pd-breadcrumb {
        margin-bottom: 16px;
        font-size: 12px;
    }

    .pd-breadcrumb span {
        max-width: 160px;
    }

    /* Full-bleed swipe gallery with dots */
    .pd-gallery {
        margin: 0 calc(var(--bs-gutter-x, 1.5rem) * -.5);
    }

    .pd-thumbs {
        display: none;
    }

    .pd-stage {
        border-radius: 0;
        box-shadow: none;
    }

    .pd-slide {
        max-height: none;
        cursor: default;
    }

    .pd-nav {
        display: none;
    }

    .pd-dots {
        position: absolute;
        left: 50%;
        bottom: 16px;
        display: flex;
        gap: 6px;
        transform: translateX(-50%);
        pointer-events: none;
    }

    .pd-dots span {
        width: 7px;
        height: 7px;
        border-radius: 7px;
        background: rgba(255, 255, 255, .6);
        box-shadow: 0 1px 4px rgba(0, 0, 0, .2);
        transition: width .25s ease, background .25s ease;
    }

    .pd-dots span.active {
        width: 22px;
        background: #ffffff;
    }

    .pd-counter {
        top: 16px;
        bottom: auto;
    }

    .pd-title {
        font-size: 28px;
    }

    .pd-price-box {
        padding: 16px;
    }

    .pd-price-now {
        font-size: 26px;
    }

    .pd-qty {
        flex-basis: 120px;
    }

    .pd-btn {
        padding: 0 16px;
        font-size: 14.5px;
    }

    .pd-perk {
        padding: 16px 6px;
    }

    .pd-perk span {
        font-size: 11px;
    }

    .pd-tabs-card {
        margin-top: 40px;
        padding: 4px 18px 24px;
        border-radius: 18px;
    }

    .pd-tabs {
        gap: 24px;
        margin-bottom: 20px;
    }

    .pd-tab {
        padding: 16px 0 14px;
        font-size: 14px;
    }

    .pd-panel h3 {
        font-size: 22px;
    }

    /* Sit just above the app-style bottom navigation */
    .pd-sticky {
        left: 10px;
        right: 10px;
        bottom: calc(var(--bottom-nav-height) + 30px); /* clears the raised cart button */
    }
}

@media (max-width: 380px) {
    .pd-perks {
        grid-template-columns: minmax(0, 1fr);
    }

    .pd-perk {
        flex-direction: row;
        text-align: left;
    }

    .pd-perk + .pd-perk {
        border-left: 0;
        border-top: 1px solid var(--pd-line);
    }

    .pd-specs {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media print {
    .pd-sticky {
        display: none !important;
    }
}
