﻿/* ========================================================= */
/* JOLIE CAPRICIEUSE PARIS                                  */
/* FILE : frontend/css/produit.css                          */
/* VERSION : PRODUCT V4 — PREMIUM FINAL LAYOUT              */
/* ========================================================= */

.product-page,
.product-page * {
    box-sizing: border-box;
}

body.product-page {
    background: #ffffff;
    color: #111111;
    padding-top: 0;
}

.product-main {
    background: #ffffff;
    color: #111111;
    padding-top: 320px;
}

body.header-compact-active .product-main {
    padding-top: 480px;
}

/* ========================================================= */
/* BREADCRUMB                                                */
/* ========================================================= */

.product-breadcrumb {
    width: calc(100% - 12px);
    margin: 0 auto 8px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(17, 17, 17, 0.56);
    font-family: "Inter", sans-serif;
    font-size: 18px;
    font-weight: 400;
}

.product-breadcrumb a {
    color: rgba(17, 17, 17, 0.72);
    text-decoration: none;
}

.product-breadcrumb a:hover {
    color: #111111;
}

/* ========================================================= */
/* PRODUCT EXPERIENCE GRID                                   */
/* ========================================================= */

.product-experience {
    width: calc(100% - 32px);
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 620px;
    gap: 64px;
    align-items: start;
}

.product-main > .product-experience {
    padding-top: 0;
    padding-bottom: 0;
}

.product-media-grid {
    display: grid;
    grid-template-columns: minmax(0, 2.157fr) minmax(0, 1fr);
    grid-template-areas:
        "hero detail"
        "hero catalog"
        "lifestyle secondary"
        "video video";
    gap: 20px;
    align-items: stretch;
}

.product-media-card {
    position: relative;
    overflow: hidden;
    background: #ffffff;
}

.product-media-card img,
.product-media-card video {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: center center;
    transition: transform 0.35s ease;
}

.product-media-card:hover img {
    transform: scale(1.018);
}

.product-media-card-1 {
    grid-area: hero;
    height: 940px;
}

.product-media-card-2 {
    grid-area: detail;
    height: 360px;
}

.product-media-card-3 {
    grid-area: catalog;
    height: 560px;
}

.product-media-card-4 {
    grid-area: lifestyle;
    height: 500px;
}

.product-media-card-5 {
    grid-area: secondary;
    height: 500px;
}

.product-media-card-6 {
    grid-area: video;
    width: 100%;
    max-width: 480px;
    aspect-ratio: 9 / 16;
    margin-left: 0;
    margin-right: auto;
    overflow: hidden;
    border-radius: 0;
}

[data-product-media-slot="video"] {
    height: auto;
    background: #ffffff;
}

[data-product-media-slot="video"] video {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: center center;
}

[data-product-media-slot="catalog"] img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center center;
    padding: 0;
    transform: scale(1.18);
    transform-origin: center center;
}

[data-product-media-slot="catalog"]:hover img {
    transform: scale(1.18);
}

.product-media-card[hidden] {
    display: none;
}

/* ========================================================= */
/* BUY BOX                                                   */
/* ========================================================= */

.product-buybox {
    position: sticky;
    top: 92px;
    align-self: start;
    padding: 46px 0 0;
}

.product-kicker,
.product-section-heading span,
.product-story span {
    display: block;
    color: #9B773B;
    font-family: "Inter", sans-serif;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.product-buybox h1 {
    margin: 16px 0 16px;
    color: #111111;
    font-family: var(--font-title, "Cormorant Garamond", serif);
    font-size: clamp(44px, 4vw, 74px);
    font-weight: 500;
    line-height: 0.96;
    letter-spacing: -0.055em;
}

.product-short-description {
    max-width: 560px;
    margin: 0 0 56px;
    color: rgba(17, 17, 17, 0.68);
    font-size: 15px;
    line-height: 1.75;
}

.product-price-line {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 18px;
}

.product-price {
    margin: 0;
    color: #111111;
    font-size: 24px;
    font-weight: 800;
}

/* ========================================================= */
/* PROMOTION PRICE                                           */
/* ========================================================= */

.product-price.is-promotion {
    display: block;
    margin-bottom: 18px;
}

.product-price-block {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
}

.product-price-before {
    color: #C00000;
    font-size: 18px;
    font-weight: 800;
    line-height: 1;
    text-decoration: line-through;
    text-decoration-thickness: 2px;
}

.product-price-current {
    color: #111111;
    font-size: 16px;
    font-weight: 800;
    line-height: 1;
}

.product-badge {
    min-height: 26px;
    display: inline-flex;
    align-items: center;
    padding: 0 12px;
    border: 1px solid rgba(198, 160, 98, 0.36);
    border-radius: 999px;
    color: #9B773B;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.product-stock {
    margin-bottom: 26px;
    color: #177245;
    font-size: 13px;
    font-weight: 700;
}

.product-stock.is-low {
    color: #9B773B;
}

.product-stock.is-unavailable {
    color: #9B2E2E;
}

/* ========================================================= */
/* VARIANTS                                                  */
/* VERSION : V1 DEFINITIVE                                  */
/* ========================================================= */

.product-variants[hidden],
.product-variant-group[hidden] {
    display: none !important;
}

.product-variants {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin: 28px 0 30px;
}

.product-variant-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.product-variant-label {
    margin: 0;
    color: #111111;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .14em;
    text-transform: uppercase;
}

.product-variant-options {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

/* ---------- Base option ---------- */

.product-variant-option {
    appearance: none;
    border: 1px solid #DADADA;
    background: #FFFFFF;
    color: #111111;
    cursor: pointer;
    user-select: none;
    transition:
        border-color .20s ease,
        background .20s ease,
        color .20s ease,
        transform .20s ease,
        box-shadow .20s ease;
}

/* ---------- Text buttons : taille / fallback ---------- */

.product-variant-option.is-size,
.product-variant-option:not(.is-metal):not(.is-color):not(.is-image) {
    min-width: 54px;
    min-height: 44px;
    padding: 0 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 700;
}

.product-variant-option.is-size:hover,
.product-variant-option:not(.is-metal):not(.is-color):not(.is-image):hover {
    border-color: #C6A062;
    transform: translateY(-1px);
}

.product-variant-option.is-size.is-selected,
.product-variant-option:not(.is-metal):not(.is-color):not(.is-image).is-selected {
    background: #111111;
    color: #FFFFFF;
    border-color: #111111;
}

/* ---------- Metal + color badges ---------- */

.product-variant-option.is-metal,
.product-variant-option.is-color {
    width: 20px;
    height: 20px;
    min-width: 16px;
    min-height: 16px;
    flex: 0 0 20px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 1px solid rgba(17,17,17,.16);
    border-radius: 50%;
    overflow: hidden;
}

.product-variant-option.is-metal img,
.product-variant-option.is-color img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    border-radius: 50%;
}

.product-variant-option.is-metal:hover,
.product-variant-option.is-color:hover {
    border-color: #C6A062;
    transform: scale(1.06);
}

.product-variant-option.is-metal.is-selected,
.product-variant-option.is-color.is-selected {
    background: transparent;
    border-color: #C6A062;
    box-shadow: 0 0 0 2px #C6A062;
}

/* ---------- Image swatches future motifs ---------- */

.product-variant-option.is-image {
    width: 54px;
    height: 54px;
    min-width: 54px;
    min-height: 54px;
    padding: 2px;
    overflow: hidden;
}

.product-variant-option.is-image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

/* ---------- Disabled ---------- */

.product-variant-option.is-disabled {
    opacity: .35;
    pointer-events: none;
    cursor: not-allowed;
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
    .product-variants {
        gap: 22px;
    }

    .product-variant-options {
        gap: 10px;
    }

    .product-variant-option.is-size,
    .product-variant-option:not(.is-metal):not(.is-color):not(.is-image) {
        min-height: 42px;
        font-size: 12px;
    }

    .product-variant-option.is-metal,
    .product-variant-option.is-color {
        width: 28px;
        height: 28px;
        min-width: 28px;
        min-height: 28px;
        flex-basis: 28px;
    }
}

/* ========================================================= */
/* ACTIONS                                                   */
/* ========================================================= */

.product-actions {
    display: grid;
    gap: 12px;
    margin-bottom: 28px;
}

.product-add-cart,
.product-buy-now {
    width: 100%;
    min-height: 58px;
    border: 1px solid #111111;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    cursor: pointer;
    transition:
        background-color 0.25s ease,
        color 0.25s ease,
        border-color 0.25s ease,
        transform 0.25s ease;
}

.product-add-cart {
    background: #111111;
    color: #ffffff;
}

.product-buy-now {
    background: transparent;
    color: #111111;
}

.product-add-cart:hover,
.product-buy-now:hover {
    transform: translateY(-1px);
}

.product-buy-now:hover {
    background: #111111;
    color: #ffffff;
}

.product-add-cart.is-added {
    background: #C6A062;
    border-color: #C6A062;
    color: #111111;
}

/* ========================================================= */
/* SERVICE BOX                                               */
/* ========================================================= */

.product-service-box {
    display: grid;
    gap: 12px;
    margin: 26px 0 28px;
    padding: 22px;
    background: #F8F4F1;
    border: 1px solid rgba(198, 160, 98, 0.18);
}

.product-service-box article {
    display: grid;
    grid-template-columns: 32px 1fr;
    gap: 14px;
    align-items: start;
}

.product-service-box span {
    color: #C6A062;
    font-size: 23px;
    line-height: 1;
}

.product-service-box strong {
    display: block;
    margin-bottom: 4px;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.product-service-box p {
    margin: 0;
    color: rgba(17, 17, 17, 0.62);
    font-size: 13px;
    line-height: 1.55;
}

/* ========================================================= */
/* ACCORDIONS                                                */
/* ========================================================= */

.product-accordions {
    margin-top: 36px;
    border-top: 1px solid rgba(17, 17, 17, 0.10);
}

.product-accordions details {
    border-bottom: 1px solid rgba(17, 17, 17, 0.10);
}

.product-accordions summary {
    min-height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: #111111;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
    list-style: none;
}

.product-accordions summary::-webkit-details-marker {
    display: none;
}

.product-accordions summary::after {
    content: "+";
    color: #9B773B;
    font-size: 18px;
}

.product-accordions details[open] summary::after {
    content: "–";
}

.product-accordions details p,
.product-specs {
    margin: 0 0 24px;
    color: rgba(17, 17, 17, 0.66);
    font-size: 14px;
    line-height: 1.75;
}

.product-specs {
    display: grid;
    gap: 12px;
}

.product-specs div {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 18px;
}

.product-specs dt {
    color: #111111;
    font-weight: 800;
}

.product-specs dd {
    margin: 0;
}

/* ========================================================= */
/* STORY                                                     */
/* ========================================================= */

.product-story {
    width: min(1680px, calc(100% - 48px));
    margin: 86px auto 0;
    padding: 48px;
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 44px;
    background: #F5EDE7;
    border: 1px solid rgba(198, 160, 98, 0.22);
}

.product-story h2 {
    margin: 14px 0 0;
    color: #111111;
    font-family: var(--font-title, "Cormorant Garamond", serif);
    font-size: clamp(36px, 3.2vw, 58px);
    font-weight: 500;
    line-height: 0.98;
    letter-spacing: -0.045em;
}

.product-story p {
    margin: 0;
    align-self: center;
    color: rgba(17, 17, 17, 0.66);
    font-size: 16px;
    line-height: 1.8;
}

/* ========================================================= */
/* RECOMMENDATIONS                                           */
/* ========================================================= */

.product-recommendations {
    width: min(1680px, calc(100% - 48px));
    margin: 96px auto 92px;
}

.product-section-heading {
    margin-bottom: 34px;
}

.product-section-heading h2 {
    margin: 14px 0 12px;
    color: #111111;
    font-family: var(--font-title, "Cormorant Garamond", serif);
    font-size: clamp(42px, 4vw, 72px);
    font-weight: 500;
    line-height: 0.94;
    letter-spacing: -0.055em;
}

.product-section-heading p {
    max-width: 600px;
    margin: 0;
    color: rgba(17, 17, 17, 0.62);
    font-size: 15px;
    line-height: 1.7;
}

.product-carousel-shell {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr) 48px;
    gap: 18px;
    align-items: center;
}

.product-carousel-arrow {
    width: 48px;
    height: 48px;
    border: 1px solid rgba(17, 17, 17, 0.22);
    border-radius: 999px;
    background: #ffffff;
    color: #111111;
    cursor: pointer;
    font-size: 18px;
    transition:
        background-color 0.25s ease,
        color 0.25s ease,
        transform 0.25s ease;
}

.product-carousel-arrow:hover {
    background: #111111;
    color: #ffffff;
    transform: translateY(-1px);
}

.product-carousel-viewport {
    overflow: hidden;
}

.product-carousel-track {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: calc((100% - 54px) / 4);
    gap: 18px;
    transition: transform 0.35s ease;
}

.product-reco-card {
    min-width: 0;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: #111111;
    background: #ffffff;
    border: 1px solid rgba(198, 160, 98, 0.20);
    overflow: hidden;
}

.product-reco-media {
    height: 360px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    overflow: hidden;
}

.product-reco-media img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center center;
    display: block;
    transform: scale(1.18);
    transform-origin: center center;
    transition: transform 0.45s ease;
}

.product-reco-card:hover .product-reco-media img {
    transform: scale(1.22);
}

.product-reco-content {
    min-height: 230px;
    display: flex;
    flex-direction: column;
    padding: 20px 22px 22px;
}

.product-reco-badge {
    min-height: 18px;
    margin-bottom: 10px;
    color: #9B773B;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.product-reco-title {
    margin: 0;
    font-family: var(--font-title, "Cormorant Garamond", serif);
    font-size: 28px;
    font-weight: 800;
    line-height: 1.04;
    letter-spacing: -0.03em;
}

.product-reco-description {
    margin: 10px 0 0;
    color: rgba(17, 17, 17, 0.62);
    font-size: 13px;
    line-height: 1.55;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-reco-price {
    margin: 12px 0 0;
    color: #111111;
    font-size: 14px;
    font-weight: 800;
}

.product-reco-button {
    margin-top: auto;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #111111;
    color: #111111;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.11em;
    text-transform: uppercase;
}

/* ========================================================= */
/* STATUS                                                    */
/* ========================================================= */

.product-status {
    width: min(760px, calc(100% - 48px));
    margin: 220px auto 120px;
    padding: 42px;
    background: #F5EDE7;
    color: rgba(17, 17, 17, 0.72);
    text-align: center;
    font-size: 15px;
    line-height: 1.7;
}

/* ========================================================= */
/* RESPONSIVE                                                */
/* ========================================================= */

@media screen and (max-width: 1300px) {
    .product-experience {
        grid-template-columns: 1fr;
    }

    .product-buybox {
        position: relative;
        top: auto;
    }

    .product-carousel-track {
        grid-auto-columns: calc((100% - 18px) / 2);
    }
}

@media screen and (max-width: 900px) {
    .product-page {
        padding-top: 132px;
    }

    .product-breadcrumb,
    .product-experience,
    .product-story,
    .product-recommendations {
        width: calc(100% - 34px);
    }

    .product-breadcrumb {
        margin-bottom: 18px;
        overflow-x: auto;
        white-space: nowrap;
    }

    .product-media-grid {
        grid-template-columns: 1fr;
        grid-template-areas:
            "hero"
            "catalog"
            "secondary"
            "lifestyle"
            "detail"
            "video";
    }

    .product-media-card-1,
    .product-media-card-2,
    .product-media-card-3,
    .product-media-card-4,
    .product-media-card-5,
    .product-media-card-6 {
        aspect-ratio: 1;
    }

    .product-media-card-1 {
        aspect-ratio: 0.82;
    }

    .product-buybox h1 {
        font-size: 46px;
    }

    .product-story {
        margin-top: 56px;
        padding: 32px 24px;
        grid-template-columns: 1fr;
    }

    .product-carousel-shell {
        grid-template-columns: 1fr;
    }

    .product-carousel-arrow {
        display: none;
    }

    .product-carousel-viewport {
        overflow-x: auto;
        scroll-snap-type: x mandatory;
    }

    .product-carousel-track {
        grid-auto-columns: 82%;
        gap: 16px;
    }

    .product-reco-card {
        scroll-snap-align: start;
    }

    .product-reco-media {
        height: 320px;
    }

    .product-specs div {
        grid-template-columns: 1fr;
        gap: 4px;
    }
}