﻿/* =========================
   PRODUCTO DETALLE
========================= */

.pd-page {
    padding: 2.75rem 2rem;
}

.pd-shell {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 88px 1fr 420px;
    gap: 1.6rem;
    align-items: start;
}

/* =========================
   THUMBS
========================= */

.pd-thumbs {
    display: flex;
    flex-direction: column;
    gap: .9rem;
    position: sticky;
    top: 92px;
    max-height: calc(100vh - 140px);
    overflow: auto;
    padding-right: .2rem;
}

.pd-thumb {
    border: 1px solid rgba(46,46,46,0.10);
    background: rgba(255,255,255,0.75);
    border-radius: 14px;
    padding: .45rem;
    cursor: pointer;
    transition: all .2s ease;
    position: relative;
    overflow: hidden;
}

    .pd-thumb:hover {
        transform: translateY(-1px);
        border-color: rgba(255,107,90,0.25);
        box-shadow: 0 12px 26px rgba(0,0,0,0.06);
    }

    .pd-thumb img {
        width: 100%;
        aspect-ratio: 1 / 1;
        object-fit: contain;
        display: block;
        border-radius: 10px;
        background: #fff;
        transition: transform .22s ease;
    }

    .pd-thumb:hover img {
        transform: scale(1.06);
    }

    /* Selección más marcada */
    .pd-thumb.is-active {
        border-color: rgba(164,75,193,0.55);
        box-shadow: 0 18px 40px rgba(164,75,193,0.14), 0 14px 30px rgba(0,0,0,0.10);
        transform: translateY(-1px);
    }

        .pd-thumb.is-active::after {
            content: "";
            position: absolute;
            left: 0;
            top: 10px;
            bottom: 10px;
            width: 4px;
            border-radius: 999px;
            background: linear-gradient(180deg, rgba(164,75,193,0.85), rgba(255,107,90,0.55));
        }

/* =========================
   STAGE (imagen grande)
========================= */

.pd-stage {
    background: rgba(255,255,255,0.60);
    border: 1px solid rgba(46,46,46,0.08);
    border-radius: 22px;
    box-shadow: 0 18px 60px rgba(0,0,0,0.08);
    padding: 1.1rem;
}

.pd-stage-inner {
    position: relative;
    border-radius: 18px;
    background: #fff;
    border: 1px solid rgba(46,46,46,0.06);
    min-height: clamp(360px, 56vh, 620px);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    cursor: zoom-in;
}

.pd-main-img {
    max-width: 100%;
    max-height: calc(56vh);
    width: auto;
    height: auto;
    object-fit: contain;
    object-position: center;
    display: block;
    padding: 1.25rem;
    transition: transform .22s ease, transform-origin .12s ease;
}

    .pd-main-img.is-zoom {
        transform: scale(1.25);
    }

.pd-zoom-hint {
    position: absolute;
    bottom: 12px;
    right: 12px;
    font-size: .75rem;
    font-weight: 900;
    letter-spacing: .02em;
    padding: .35rem .6rem;
    border-radius: 999px;
    color: rgba(46,46,46,0.78);
    background: rgba(255,255,255,0.85);
    border: 1px solid rgba(46,46,46,0.12);
}

/* Flechas */
.pd-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 42px;
    height: 42px;
    border-radius: 999px;
    border: 1px solid rgba(46,46,46,0.12);
    background: rgba(255,255,255,0.85);
    color: rgba(46,46,46,0.85);
    font-size: 1.6rem;
    line-height: 1;
    display: grid;
    place-items: center;
    cursor: pointer;
    transition: all .2s ease;
}

    .pd-nav:hover {
        transform: translateY(-50%) scale(1.03);
        box-shadow: 0 18px 40px rgba(0,0,0,0.10);
    }

.pd-prev {
    left: 12px;
}

.pd-next {
    right: 12px;
}

/* =========================
   INFO (panel derecho)
========================= */

.pd-info {
    position: sticky;
    top: 92px;
}

.pd-info-card {
    background: var(--arcus-card);
    border-radius: 22px;
    box-shadow: var(--arcus-shadow), inset 0 0 0 1px rgba(255,107,90,0.12);
    padding: 2rem;
}

.pd-title {
    font-family: var(--arcus-font-serif);
    font-size: 1.9rem;
    margin: 0 0 .4rem 0;
}

.pd-price {
    font-size: 1.35rem;
    font-weight: 900;
    color: var(--arcus-text);
}

.pd-tags {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin: 1rem 0 1.2rem;
}

.pd-tag {
    display: inline-flex;
    align-items: center;
    padding: .35rem .7rem;
    border-radius: 999px;
    border: 1px solid rgba(46,46,46,0.10);
    background: rgba(255,255,255,0.65);
    font-size: .78rem;
    font-weight: 800;
    color: rgba(46,46,46,0.85);
}

/* =========================
   BOTONES
========================= */

.pd-actions {
    display: grid;
    gap: .75rem;
    margin: 1.2rem 0 1.4rem;
}

.pd-btn-cart {
    width: 100%;
    border: none;
    border-radius: 16px;
    padding: .95rem 1rem;
    font-weight: 900;
    background: var(--arcus-success);
    color: #fff;
    transition: all .2s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 18px 40px rgba(157,167,124,0.22);
}

    .pd-btn-cart:hover {
        filter: brightness(0.95);
        transform: translateY(-1px);
    }

    .pd-btn-cart::before {
        content: "";
        position: absolute;
        inset: -40% -30%;
        background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,0.35) 45%, transparent 60%);
        transform: translateX(-40%) rotate(8deg);
        transition: transform .6s ease;
    }

    .pd-btn-cart:hover::before {
        transform: translateX(40%) rotate(8deg);
    }

.pd-btn-secondary {
    width: 100%;
    text-align: center;
    text-decoration: none;
    border-radius: 16px;
    padding: .85rem 1rem;
    font-weight: 900;
    color: var(--arcus-text);
    background: #fff;
    border: 1px solid rgba(46,46,46,0.12);
    transition: all .2s ease;
}

    .pd-btn-secondary:hover {
        background: rgba(255,107,90,0.08);
        border-color: rgba(255,107,90,0.22);
        transform: translateY(-1px);
        text-decoration: none;
    }

/* =========================
   META
========================= */

.pd-meta {
    border-top: 1px solid rgba(46,46,46,0.10);
    padding-top: 1.1rem;
    margin-top: .2rem;
}

.pd-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: .6rem 0;
}

.pd-meta-label {
    color: rgba(46,46,46,0.60);
    font-weight: 800;
    font-size: .85rem;
}

.pd-meta-value {
    font-weight: 900;
    color: rgba(46,46,46,0.92);
}

/* =========================
   ACCORDION (details)
========================= */

.pd-accordion {
    margin-top: 1.1rem;
    display: grid;
    gap: .75rem;
}

.pd-details {
    background: rgba(255,255,255,0.55);
    border: 1px solid rgba(46,46,46,0.08);
    border-radius: 16px;
    padding: .9rem 1rem;
    position: relative;
}

    .pd-details summary {
        cursor: pointer;
        font-weight: 900;
        color: rgba(46,46,46,0.90);
        list-style: none;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: .75rem;
        padding-right: 2.25rem; 
    }

        .pd-details summary::-webkit-details-marker {
            display: none;
        }

        .pd-details summary::after {
            content: "";
            position: absolute;
            right: 14px;
            top: 14px;
            width: 8px;
            height: 8px;
            border-right: 2px solid rgba(46,46,46,0.70);
            border-bottom: 2px solid rgba(46,46,46,0.70);
            transform: rotate(45deg);
            transition: transform .18s ease;
        }

    .pd-details[open] summary::after {
        transform: rotate(225deg);
    }

.pd-desc {
    margin: .75rem 0 0 0;
    color: rgba(46,46,46,0.75);
    line-height: 1.6;
}

.pd-list {
    margin: .8rem 0 0 0;
    padding-left: 1.05rem;
    color: rgba(46,46,46,0.75);
    line-height: 1.6;
}

    .pd-list li {
        margin: .35rem 0;
    }

/* =========================
   RESPONSIVE
========================= */

@media (max-width: 1024px) {
    .pd-shell {
        grid-template-columns: 72px 1fr;
        grid-template-areas:
            "thumbs stage"
            "info info";
    }

    .pd-thumbs {
        grid-area: thumbs;
        position: static;
        max-height: none;
    }

    .pd-stage {
        grid-area: stage;
    }

    .pd-info {
        grid-area: info;
        position: static;
    }
}

@media (max-width: 640px) {
    .pd-page {
        padding: 2rem 1.1rem;
    }

    .pd-shell {
        grid-template-columns: 1fr;
        grid-template-areas:
            "stage"
            "thumbs"
            "info";
    }

    .pd-thumbs {
        flex-direction: row;
        overflow-x: auto;
        overflow-y: hidden;
        padding-bottom: .25rem;
    }

    .pd-thumb {
        min-width: 84px;
    }

    .pd-zoom-hint {
        display: none;
    }
}


.pd-btn-cart.is-disabled {
    opacity: .75;
    cursor: not-allowed;
    filter: saturate(.85);
}

.pd-hold {
    margin-top: .45rem;
    font-size: .92rem;
}
