/* =========================================================
   DETALLE DEL PRODUCTO — DOLCI HANDS
========================================================= */

.product-detail-page {
    width: min(1180px, calc(100% - 48px));
    margin: 0 auto;
    padding: 28px 0 70px;
}


/* =========================================================
   BREADCRUMB
========================================================= */

.product-detail-breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 7px;

    margin-bottom: 30px;

    font-size: 13px;
    line-height: 1.4;
}

.product-detail-breadcrumb a {
    text-decoration: none;
}

.product-detail-breadcrumb strong {
    font-weight: 600;
}


/* =========================================================
   CONTENIDO PRINCIPAL
========================================================= */

.product-detail-main {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(390px, 0.95fr);
    gap: 56px;
    align-items: start;
}


/* =========================================================
   GALERÍA
========================================================= */

.product-detail-gallery {
    display: grid;
    grid-template-columns: 74px minmax(0, 1fr);
    gap: 18px;
}

.product-detail-thumbnails {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.product-detail-thumbnail {
    width: 74px;
    height: 74px;

    padding: 0;

    border: 1px solid rgba(93, 52, 40, 0.15);
    border-radius: 14px;

    background: transparent;

    overflow: hidden;
    cursor: pointer;
}

.product-detail-thumbnail img {
    width: 100%;
    height: 100%;

    display: block;

    object-fit: cover;
}

.product-detail-main-image {
    min-height: 540px;

    border-radius: 28px;
    overflow: hidden;

    display: flex;
    align-items: center;
    justify-content: center;
}

.product-detail-main-image img {
    width: 100%;
    height: 100%;

    display: block;

    object-fit: contain;
}

.product-detail-image-placeholder {
    width: 100%;
    min-height: 540px;

    display: flex;
    align-items: center;
    justify-content: center;
}


/* =========================================================
   INFORMACIÓN DEL PRODUCTO
========================================================= */

.product-detail-info {
    position: relative;

    padding-top: 2px;
}

.product-detail-category {
    display: block;

    margin-bottom: 10px;

    font-size: 12px;
    font-weight: 600;

    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.product-detail-info h1 {
    max-width: 620px;

    margin: 0 0 16px;

    font-size: clamp(34px, 4vw, 50px);
    line-height: 1.06;
    letter-spacing: -0.025em;
}

.product-detail-rating {
    display: flex;
    align-items: center;
    gap: 8px;

    margin-bottom: 18px;

    font-size: 13px;
}

.product-detail-stars {
    letter-spacing: 2px;
    font-size: 15px;
}

.product-detail-price {
    margin-bottom: 17px;

    font-size: 29px;
    line-height: 1.1;
    font-weight: 700;
}


/* =========================================================
   PROMOCIÓN DEL PRODUCTO
========================================================= */

/* =========================================================
   PROMOCIÓN + PRECIO
   ========================================================= */

.product-detail-promotion {
    width: 100%;
    max-width: 520px;
    min-height: 70px;

    display: flex;
    align-items: stretch;
    justify-content: space-between;

    margin: 6px 0 22px;

    background: #f4ded9;
    border: 1px solid rgba(181, 95, 75, 0.10);
    border-radius: 13px;

    overflow: hidden;
}


/* ---------------------------------------------------------
   LADO IZQUIERDO
   --------------------------------------------------------- */

.product-detail-promotion-main {
    display: flex;
    align-items: center;
    gap: 14px;

    padding: 12px 16px;
}


/* ---------------------------------------------------------
   ICONO
   --------------------------------------------------------- */

.product-detail-promotion-icon {
    width: 44px;
    height: 44px;

    flex: 0 0 44px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: #cf7458;
}


.product-detail-promotion-icon img {
    width: 27px;
    height: 27px;

    display: block;

    object-fit: contain;
}


/* ---------------------------------------------------------
   TEXTO
   --------------------------------------------------------- */

.product-detail-promotion-content {
    min-width: 0;
}


.product-detail-promotion-content strong {
    display: block;

    margin: 0 0 2px;

    color: #b85e48;

    font-size: 15px;
    line-height: 1.2;
    font-weight: 700;
}


.product-detail-promotion-content p {
    margin: 0;

    color: #3f312d;

    font-size: 11px;
    line-height: 1.4;
}


/* ---------------------------------------------------------
   PRECIO
   --------------------------------------------------------- */

.product-detail-promotion-price {
    min-width: 145px;

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;

    padding: 10px 18px;

    border-left: 1px solid rgba(181, 95, 75, 0.18);
}


.product-detail-price-original {
    margin-bottom: 2px;

    color: #73635d;

    font-size: 12px;
    line-height: 1;

    text-decoration: line-through;
}


.product-detail-price-current {
    color: #b85e48;

    font-size: 22px;
    line-height: 1.1;
    font-weight: 700;
}


.product-detail-promotion-price-single {
    justify-content: center;
}

.product-detail-promotion-content strong {
    display: block;

    margin-bottom: 2px;

    font-size: 13px;
    font-weight: 700;
    line-height: 1.25;
}

.product-detail-promotion-content p {
    margin: 0;

    font-size: 11px;
    line-height: 1.4;
}


/* =========================================================
   MÓVIL
========================================================= */

@media (max-width: 600px) {

    .product-detail-promotion {
        max-width: none;
        padding: 11px 13px;
    }

    .product-detail-promotion-icon {
        width: 40px;
        height: 40px;
        flex-basis: 40px;
    }

    .product-detail-promotion-icon img {
        width: 34px;
        height: 34px;
    }

}

.product-detail-short-description {
    max-width: 620px;

    margin: 0 0 25px;

    font-size: 15px;
    line-height: 1.6;
}


/* =========================================================
   CARACTERÍSTICAS
========================================================= */

.product-detail-features {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;

    margin: 24px 0 28px;
}

.product-detail-feature {
    display: flex;
    align-items: center;
    gap: 9px;

    min-width: 0;
}

.product-detail-feature-icon {
    width: 46px;
    height: 46px;

    flex: 0 0 46px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 1px solid rgba(181, 95, 75, 0.25);
    border-radius: 50%;

    overflow: hidden;
}

.product-detail-feature-icon img {
    width: 71px;
    height: 71px;

    display: block;

    object-fit: contain;
}

.product-detail-feature > div:last-child {
    min-width: 0;
}

.product-detail-feature strong {
    display: block;

    margin: 0 0 3px;

    font-size: 11px;
    font-weight: 600;
    line-height: 1.25;
}

.product-detail-feature p {
    margin: 0;

    font-size: 10px;
    line-height: 1.3;
}


/* =========================================================
   COMPRA
========================================================= */

.product-detail-purchase {
    display: grid;

    grid-template-columns: 142px minmax(0, 1fr);
    grid-template-rows: 20px 52px;

    column-gap: 16px;

    margin-top: 22px;
}

.product-detail-quantity {
    position: relative;

    grid-column: 1;
    grid-row: 2;

    width: 142px;
    height: 52px;

    display: flex;
    align-items: center;

    border: 1px solid rgba(181, 95, 75, 0.20);
    border-radius: 26px;

    overflow: hidden;

    background: rgba(255, 255, 255, 0.30);
}

.product-detail-quantity::before {
    content: "Cantidad";

    position: absolute;

    left: 0;
    bottom: calc(100% + 7px);

    font-size: 12px;
    font-weight: 600;

    white-space: nowrap;
}

.product-detail-quantity button,
.product-detail-quantity span {
    width: 47px;
    height: 52px;

    display: flex;
    align-items: center;
    justify-content: center;
}

.product-detail-quantity button {
    padding: 0;

    border: 0;

    background: transparent;

    cursor: pointer;

    font-size: 22px;
    font-weight: 400;
}

.product-detail-quantity span {
    font-size: 15px;
}

.product-detail-purchase form {
    grid-column: 2;
    grid-row: 1 / span 2;

    display: flex;
    align-items: flex-end;

    width: 100%;
}

.product-detail-purchase form .button,
.product-detail-purchase > a {
    position: relative;

    width: 100%;
    min-height: 52px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 12px;

    font-size: 14px;
    font-weight: 600;

    text-align: center;
}


/* =========================================================
   ICONO DEL CARRITO
========================================================= */

.product-detail-purchase form .button::before {
    content: "";

    position: absolute;
    left: 20px;
    top: 50%;

    width: 22px;
    height: 22px;

    transform: translateY(-50%);

    background-image: url("../images/icons/cart.png");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}

/* Icono real de la biblioteca Dolci Hands */
.product-detail-purchase form .button::before {
    content: "";

    width: 22px;
    height: 22px;

    display: block;

    background-image: url("../images/icons/cart.png");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}


/* =========================================================
   INFORMACIÓN DE ENTREGA
========================================================= */

.product-detail-delivery {
    display: flex;
    align-items: center;
    gap: 14px;

    margin-top: 24px;
    padding: 13px 16px;

    min-height: 58px;

    border-radius: 10px;

    background: #f3dfd9;
    border: 1px solid rgba(181, 95, 75, 0.07);
}

.product-detail-delivery-icon {
    width: 48px;
    height: 48px;

    flex: 0 0 48px;

    display: flex;
    align-items: center;
    justify-content: center;
}

.product-detail-delivery-icon img {
    width: 71px;
    height: 71px;

    display: block;

    object-fit: contain;
}

.product-detail-delivery > div:last-child {
    min-width: 0;
}

.product-detail-delivery strong {
    display: block;

    margin-bottom: 3px;

    font-size: 12px;
    font-weight: 600;
}

.product-detail-delivery p {
    margin: 0;

    font-size: 11px;
    line-height: 1.45;
}


/* =========================================================
   TABS
========================================================= */

.product-detail-tabs {
    margin-top: 70px;
}

.product-detail-tab-buttons {
    display: flex;
    align-items: center;
    gap: 30px;

    border-bottom: 1px solid rgba(75, 42, 32, 0.10);
}

.product-detail-tab-buttons button {
    position: relative;

    padding: 14px 0;

    border: 0;
    background: transparent;

    cursor: pointer;

    font: inherit;
    font-size: 13px;
}

.product-detail-tab-buttons button.active {
    font-weight: 600;
}

.product-detail-tab-buttons button.active::after {
    content: "";

    position: absolute;

    left: 0;
    right: 0;
    bottom: -1px;

    height: 2px;

    background: #b65f4b;
}


.product-detail-tab-content {
    padding-top: 34px;
}


/* =========================================================
   PANELES
========================================================= */

.product-detail-tab-panel {
    display: none;

    margin: 0;
}

.product-detail-tab-panel.active {
    display: block;
}


.product-detail-tab-panel h2 {
    margin: 0 0 14px;

    font-size: 23px;
}

.product-detail-tab-panel p {
    max-width: 850px;

    margin: 0;

    font-size: 14px;
    line-height: 1.8;
}


/* =========================================================
   COMPONENTES
========================================================= */

.product-detail-components {
    margin-top: 32px;
}

.product-detail-components h3 {
    margin: 0 0 10px;

    font-size: 18px;
}


/* =========================================================
   RESEÑAS
========================================================= */

.product-detail-tab-panel article {
    margin-top: 16px;
    padding: 18px;

    border-radius: 14px;

    background: rgba(255, 255, 255, 0.30);
}


/* =========================================================
   RESEÑAS
========================================================= */

.product-detail-tab-content article {
    margin-top: 16px;
    padding: 18px;

    border-radius: 14px;

    background: rgba(255, 255, 255, 0.30);
}


/* =========================================================
   TABLET
========================================================= */

@media (max-width: 900px) {

    .product-detail-page {
        width: min(100% - 32px, 720px);
    }

    .product-detail-main {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .product-detail-main-image {
        min-height: 460px;
    }

    .product-detail-image-placeholder {
        min-height: 460px;
    }

    .product-detail-info h1 {
        font-size: 42px;
    }

    .product-detail-features {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 16px;
    }

    .product-detail-tabs {
        margin-top: 55px;
    }

}


/* =========================================================
   MÓVIL
========================================================= */

@media (max-width: 600px) {

    .product-detail-page {
        width: calc(100% - 24px);
        padding: 24px 0 50px;
    }

    .product-detail-breadcrumb {
        margin-bottom: 24px;
        font-size: 12px;
    }

    .product-detail-gallery {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .product-detail-thumbnails {
        order: 2;

        flex-direction: row;

        overflow-x: auto;
    }

    .product-detail-thumbnail {
        flex: 0 0 64px;

        width: 64px;
        height: 64px;
    }

    .product-detail-main-image {
        min-height: 340px;
        border-radius: 22px;
    }

    .product-detail-image-placeholder {
        min-height: 340px;
    }

    .product-detail-info h1 {
        font-size: 35px;
    }

    .product-detail-rating {
        margin-bottom: 16px;
    }

    .product-detail-price {
        font-size: 27px;
    }

    .product-detail-short-description {
        font-size: 14px;
    }

    .product-detail-features {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 10px;
    }

    .product-detail-feature {
        gap: 7px;
        align-items: center;
    }

    .product-detail-feature-icon {
        width: 43px;
        height: 43px;
        flex-basis: 43px;
    }

    .product-detail-feature-icon img {
        width: 36px;
        height: 36px;
    }

    .product-detail-feature strong {
        font-size: 10px;
    }

    .product-detail-feature p {
        font-size: 9px;
    }

    .product-detail-purchase {
        grid-template-columns: 128px minmax(0, 1fr);
        column-gap: 12px;
    }

    .product-detail-quantity {
        width: 128px;
    }

    .product-detail-quantity button,
    .product-detail-quantity span {
        width: 42px;
    }

    .product-detail-purchase form .button,
    .product-detail-purchase > a {
        font-size: 13px;
    }

    .product-detail-delivery {
        margin-top: 20px;
        padding: 12px 14px;
    }

    .product-detail-delivery-icon {
        width: 44px;
        height: 44px;
        flex-basis: 44px;
    }

    .product-detail-delivery-icon img {
        width: 35px;
        height: 35px;
    }

    .product-detail-tab-buttons {
        gap: 20px;
        overflow-x: auto;
    }

    .product-detail-tab-buttons button {
        white-space: nowrap;
        font-size: 12px;
    }

}