/* ============================================================
   SITE DYMO SHOP — PRODUCT DETAIL CSS
   Galerie / Informations / Caractéristiques / Panier / Commande
============================================================ */


/* ============================================================
   VARIABLES
============================================================ */

:root {

    --detail-primary: #2563eb;
    --detail-primary-dark: #1d4ed8;
    --detail-primary-light: #60a5fa;

    --detail-success: #16a34a;
    --detail-danger: #dc2626;
    --detail-warning: #f59e0b;

    --detail-text: #0f172a;
    --detail-text-light: #475569;
    --detail-muted: #64748b;

    --detail-white: #ffffff;
    --detail-background: #f8fafc;
    --detail-background-light: #f1f5f9;

    --detail-border: #e2e8f0;

    --detail-radius-small: 8px;
    --detail-radius: 12px;
    --detail-radius-large: 20px;

    --detail-shadow:
        0 10px 30px rgba(15, 23, 42, 0.07);

    --detail-shadow-hover:
        0 20px 45px rgba(15, 23, 42, 0.12);
}


/* ============================================================
   CONTENEUR PRINCIPAL
============================================================ */

.detail-container {

    width: 100%;

    max-width: 1400px;

    margin:
        0 auto;

    padding:
        45px 30px 90px;

    color:
        var(--detail-text);
}


.product-view {

    display: grid;

    grid-template-columns:
        minmax(0, 1.05fr)
        minmax(420px, 0.95fr);

    gap:
        55px;

    align-items:
        start;
}


/* ============================================================
   GALERIE
============================================================ */

.product-gallery {

    position: sticky;

    top: 110px;

    min-width: 0;
}


/* ============================================================
   IMAGE PRINCIPALE
============================================================ */

.main-image-container {

    position: relative;

    width: 100%;

    height: 540px;

    display: flex;

    align-items: center;

    justify-content: center;

    overflow: hidden;

    padding: 30px;

    border:
        1px solid var(--detail-border);

    border-radius:
        var(--detail-radius-large);

    background:
        linear-gradient(
            145deg,
            #f8fafc,
            #eef2f7
        );

    box-shadow:
        var(--detail-shadow);

    transition:
        box-shadow 0.3s ease,
        transform 0.3s ease;
}


.main-image-container:hover {

    box-shadow:
        var(--detail-shadow-hover);
}


.main-image-container img {

    width: 100%;

    height: 100%;

    object-fit: contain;

    transition:
        transform 0.4s ease;
}


.main-image-container:hover img {

    transform:
        scale(1.025);
}


/* Image indisponible */

.product-no-image {

    width: 100%;

    height: 100%;

    display: flex;

    flex-direction: column;

    align-items: center;

    justify-content: center;

    color:
        var(--detail-muted);

    text-align: center;
}


.product-no-image span {

    margin-bottom: 10px;

    font-size: 60px;
}


.product-no-image p {

    font-size: 13px;
}


/* ============================================================
   MINIATURES
============================================================ */

.thumbnails-carousel {

    display: flex;

    align-items: center;

    gap: 12px;

    margin-top: 18px;

    padding:
        2px 2px 8px;

    overflow-x: auto;

    scrollbar-width: none;
}


.thumbnails-carousel::-webkit-scrollbar {

    display: none;
}


.thumb-item {

    width: 82px;

    height: 82px;

    flex-shrink: 0;

    padding: 5px;

    display: flex;

    align-items: center;

    justify-content: center;

    overflow: hidden;

    border:
        2px solid transparent;

    border-radius:
        var(--detail-radius);

    background:
        var(--detail-background);

    cursor: pointer;

    transition:
        border-color 0.25s ease,
        box-shadow 0.25s ease,
        transform 0.25s ease;
}


.thumb-item:hover {

    border-color:
        #93c5fd;

    transform:
        translateY(-2px);
}


.thumb-item.active {

    border-color:
        var(--detail-primary);

    box-shadow:
        0 0 0 4px
        rgba(37, 99, 235, 0.10);
}


.thumb-item img {

    width: 100%;

    height: 100%;

    object-fit: contain;
}


/* ============================================================
   PANNEAU INFORMATIONS
============================================================ */

.product-info-panel {

    min-width: 0;
}


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

.breadcrumb {

    display: flex;

    align-items: center;

    flex-wrap: wrap;

    gap: 7px;

    margin-bottom: 20px;

    color:
        var(--detail-muted);

    font-size: 12px;

    line-height: 1.5;
}


.breadcrumb a {

    color:
        var(--detail-primary);

    font-weight: 600;
}


.breadcrumb a:hover {

    color:
        var(--detail-primary-dark);

    text-decoration:
        underline;
}


.breadcrumb strong {

    color:
        var(--detail-text-light);

    font-weight: 600;
}


/* ============================================================
   MARQUE
============================================================ */

.brand-tag {

    display: inline-flex;

    align-items: center;

    margin-bottom: 8px;

    padding:
        5px 9px;

    border-radius:
        6px;

    background:
        #eff6ff;

    color:
        var(--detail-primary);

    font-size: 12px;

    font-weight: 850;

    letter-spacing: 1px;

    text-transform:
        uppercase;
}


/* ============================================================
   TITRE
============================================================ */

.product-info-panel h1 {

    margin:
        0 0 10px;

    color:
        var(--detail-text);

    font-size:
        clamp(
            2rem,
            4vw,
            3rem
        );

    line-height:
        1.15;

    font-weight:
        850;

    letter-spacing:
        -1.2px;
}


/* ============================================================
   MODÈLE
============================================================ */

.product-model {

    margin:
        0 0 10px;

    color:
        var(--detail-muted);

    font-size:
        13px;
}


.product-model strong {

    color:
        var(--detail-text-light);
}


/* ============================================================
   TYPE PRODUIT
============================================================ */

.product-type-display {

    display: inline-flex;

    align-items: center;

    margin-bottom: 20px;

    padding:
        5px 10px;

    border:
        1px solid var(--detail-border);

    border-radius:
        6px;

    background:
        var(--detail-background);

    color:
        var(--detail-text-light);

    font-size:
        13px;

    font-weight:
        700;
}


/* ============================================================
   PRIX
============================================================ */

.price-box {

    display: flex;

    align-items: baseline;

    flex-wrap: wrap;

    gap: 12px;

    margin-bottom: 15px;

    padding-bottom:
        18px;

    border-bottom:
        1px solid var(--detail-border);
}


.current-price {

    color:
        var(--detail-primary);

    font-size:
        clamp(
            1.7rem,
            4vw,
            2.35rem
        );

    font-weight:
        900;

    letter-spacing:
        -0.8px;
}


.old-price {

    color:
        var(--detail-danger);

    font-size:
        14px;

    font-weight:
        650;

    text-decoration:
        line-through;

    opacity:
        0.85;
}


.discount-badge {

    display: inline-flex;

    align-items: center;

    padding:
        4px 8px;

    border-radius:
        999px;

    background:
        #fef2f2;

    color:
        var(--detail-danger);

    font-size:
        9px;

    font-weight:
        800;

    text-transform:
        uppercase;
}


/* ============================================================
   STOCK
============================================================ */

.detail-stock {

    display: flex;

    align-items: center;

    flex-wrap: wrap;

    gap: 10px;

    margin-bottom:
        25px;
}


.stock-status {

    display: inline-flex;

    align-items: center;

    gap: 7px;

    font-size:
        12px;

    font-weight:
        750;
}


.stock-status.available {

    color:
        var(--detail-success);
}


.stock-status.unavailable {

    color:
        var(--detail-danger);
}


.stock-dot {

    width: 8px;

    height: 8px;

    flex-shrink: 0;

    border-radius: 50%;
}


.available .stock-dot {

    background:
        var(--detail-success);

    box-shadow:
        0 0 0 4px
        rgba(22, 163, 74, 0.10);
}


.unavailable .stock-dot {

    background:
        var(--detail-danger);

    box-shadow:
        0 0 0 4px
        rgba(220, 38, 38, 0.10);
}


.stock-warning {

    padding:
        4px 8px;

    border-radius:
        5px;

    background:
        #fffbeb;

    color:
        #b45309;

    font-size:
        10px;

    font-weight:
        700;
}


/* ============================================================
   DESCRIPTION
============================================================ */

.product-description {

    margin-bottom:
        30px;
}


.product-description h2,
.technical-specifications h2,
.quick-order-section h2 {

    margin-bottom:
        12px;

    color:
        var(--detail-text);

    font-size:
        17px;

    font-weight:
        800;
}


.product-description p {

    color:
        var(--detail-text-light);

    font-size:
        14px;

    line-height:
        1.8;
}


/* ============================================================
   CARACTÉRISTIQUES TECHNIQUES
============================================================ */

.technical-specifications {

    margin-bottom:
        30px;
}


.specs-grid {

    display: grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap:
        10px;
}


.spec-card {

    min-width: 0;

    padding:
        13px;

    border:
        1px solid var(--detail-border);

    border-radius:
        var(--detail-radius);

    background:
        var(--detail-background);

    text-align:
        left;

    transition:
        border-color 0.25s ease,
        background 0.25s ease,
        transform 0.25s ease;
}


.spec-card:hover {

    border-color:
        #bfdbfe;

    background:
        #f8fbff;

    transform:
        translateY(-2px);
}


.spec-card span {

    display: block;

    margin-bottom:
        5px;

    color:
        var(--detail-muted);

    font-size:
        10px;

    font-weight:
        650;
}


.spec-card strong {

    display: block;

    overflow-wrap:
        anywhere;

    color:
        var(--detail-text);

    font-size:
        13px;

    line-height:
        1.4;

    font-weight:
        750;
}


.spec-card.warranty-card {

    border-color:
        #bbf7d0;

    background:
        #f0fdf4;
}


.spec-card.warranty-card span {

    color:
        #15803d;
}


.spec-card.warranty-card strong {

    color:
        #166534;
}


/* ============================================================
   PANIER CLASSIQUE
============================================================ */

.panier-section {

    margin-top:
        25px;

    margin-bottom:
        25px;

    padding:
        22px;

    border:
        1px solid var(--detail-border);

    border-radius:
        var(--detail-radius-large);

    background:
        var(--detail-white);

    box-shadow:
        var(--detail-shadow);
}


.panier-title {

    margin-bottom:
        15px;

    color:
        var(--detail-text);

    font-size:
        17px;

    font-weight:
        800;
}


.panier-form {

    display: flex;

    align-items: flex-end;

    gap:
        10px;
}


.quantity-group {

    display: flex;

    flex-direction: column;

    gap:
        6px;
}


.quantity-group label,
.panier-form label {

    color:
        var(--detail-text-light);

    font-size:
        11px;

    font-weight:
        700;
}


.quantity-group input,
.panier-form input {

    width:
        90px;

    height:
        45px;

    padding:
        8px 10px;

    border:
        1px solid var(--detail-border);

    border-radius:
        var(--detail-radius);

    background:
        var(--detail-white);

    color:
        var(--detail-text);

    font-size:
        14px;

    font-weight:
        600;

    text-align:
        center;
}


.quantity-group input:focus,
.panier-form input:focus {

    outline:
        none;

    border-color:
        var(--detail-primary);

    box-shadow:
        0 0 0 4px
        rgba(37, 99, 235, 0.10);
}


.panier-btn {

    min-height:
        45px;

    flex:
        1;

    padding:
        10px 18px;

    border:
        1px solid var(--detail-primary);

    border-radius:
        var(--detail-radius);

    background:
        var(--detail-primary);

    color:
        var(--detail-white);

    font-size:
        12px;

    font-weight:
        800;

    cursor:
        pointer;

    transition:
        background 0.25s ease,
        transform 0.25s ease,
        box-shadow 0.25s ease;
}


.panier-btn:hover:not(:disabled) {

    background:
        var(--detail-primary-dark);

    transform:
        translateY(-2px);

    box-shadow:
        0 8px 18px
        rgba(37, 99, 235, 0.22);
}


.panier-btn:disabled {

    background:
        #94a3b8;

    border-color:
        #94a3b8;

    cursor:
        not-allowed;
}


/* ============================================================
   COMMANDE RAPIDE
============================================================ */

.quick-order-section {

    margin-top:
        25px;

    padding:
        25px;

    border:
        1px solid #bfdbfe;

    border-radius:
        var(--detail-radius-large);

    background:
        linear-gradient(
            145deg,
            #f8fbff,
            #eff6ff
        );
}


.quick-order-header {

    display: flex;

    align-items:
        flex-start;

    gap:
        12px;

    margin-bottom:
        22px;
}


.quick-order-icon {

    width:
        42px;

    height:
        42px;

    flex-shrink:
        0;

    display: flex;

    align-items:
        center;

    justify-content:
        center;

    border-radius:
        11px;

    background:
        var(--detail-primary);

    color:
        var(--detail-white);

    font-size:
        19px;

    box-shadow:
        0 7px 15px
        rgba(37, 99, 235, 0.20);
}


.quick-order-header h2 {

    margin:
        0 0 4px;

    font-size:
        17px;
}


.quick-order-header p {

    color:
        var(--detail-muted);

    font-size:
        11px;

    line-height:
        1.6;
}


/* ============================================================
   FORMULAIRE COMMANDE RAPIDE
============================================================ */

.purchase-form {

    width:
        100%;
}


.purchase-form .form-group {

    display:
        flex;

    flex-direction:
        column;

    gap:
        6px;

    margin-bottom:
        15px;
}


.purchase-form .form-group label {

    color:
        var(--detail-text-light);

    font-size:
        11px;

    font-weight:
        700;
}


.purchase-form .form-group input {

    width:
        100%;

    height:
        45px;

    padding:
        10px 12px;

    border:
        1px solid var(--detail-border);

    border-radius:
        var(--detail-radius);

    background:
        var(--detail-white);

    color:
        var(--detail-text);

    font-size:
        13px;
}


.purchase-form .form-group input:focus {

    outline:
        none;

    border-color:
        var(--detail-primary);

    box-shadow:
        0 0 0 4px
        rgba(37, 99, 235, 0.10);
}


/* ============================================================
   INFORMATIONS CLIENT
============================================================ */

.customer-info-fields {

    display:
        grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap:
        14px;

    margin-top:
        20px;

    padding:
        20px;

    border:
        1px solid var(--detail-border);

    border-radius:
        var(--detail-radius);

    background:
        var(--detail-white);
}


.customer-info-fields h3 {

    grid-column:
        1 / -1;

    margin:
        0 0 3px;

    padding-bottom:
        10px;

    border-bottom:
        1px solid var(--detail-border);

    color:
        var(--detail-text);

    font-size:
        14px;

    font-weight:
        800;
}


.input-group {

    display:
        flex;

    flex-direction:
        column;

    min-width:
        0;

    gap:
        6px;
}


.input-group label {

    color:
        var(--detail-text-light);

    font-size:
        13px;

    font-weight:
        750;
}


.input-group label small {

    color:
        var(--detail-muted);

    font-size:
        12px;

    font-weight:
        500;
}


.input-group input {

    width:
        100%;

    min-height:
        43px;

    padding:
        9px 11px;

    border:
        1px solid var(--detail-border);

    border-radius:
        var(--detail-radius);

    background:
        var(--detail-white);

    color:
        var(--detail-text);

    font-size:
        13px;

    transition:
        border-color 0.25s ease,
        box-shadow 0.25s ease;
}


.input-group input::placeholder {

    color:
        #94a3b8;
}


.input-group input:focus {

    outline:
        none;

    border-color:
        var(--detail-primary);

    box-shadow:
        0 0 0 4px
        rgba(37, 99, 235, 0.10);
}


/* ============================================================
   BOUTON COMMANDE
============================================================ */

.btn-buy {

    width:
        100%;

    min-height:
        52px;

    margin-top:
        18px;

    padding:
        12px 18px;

    border:
        1px solid var(--detail-primary);

    border-radius:
        var(--detail-radius);

    background:
        var(--detail-primary);

    color:
        var(--detail-white);

    font-size:
        14px;

    font-weight:
        850;

    cursor:
        pointer;

    box-shadow:
        0 10px 20px
        rgba(37, 99, 235, 0.20);

    transition:
        background 0.25s ease,
        transform 0.25s ease,
        box-shadow 0.25s ease;
}


.btn-buy:hover:not(:disabled) {

    background:
        var(--detail-primary-dark);

    transform:
        translateY(-2px);

    box-shadow:
        0 15px 25px
        rgba(37, 99, 235, 0.28);
}


.btn-buy:active:not(:disabled) {

    transform:
        translateY(0);
}


.btn-buy:disabled {

    background:
        #94a3b8;

    border-color:
        #94a3b8;

    cursor:
        not-allowed;

    box-shadow:
        none;
}


/* ============================================================
   INFORMATIONS SERVICES
============================================================ */

.product-service-info {

    display:
        grid;

    grid-template-columns:
        repeat(3, 1fr);

    gap:
        10px;

    margin-top:
        20px;
}


.service-item {

    display:
        flex;

    align-items:
        flex-start;

    gap:
        9px;

    padding:
        13px;

    border:
        1px solid var(--detail-border);

    border-radius:
        var(--detail-radius);

    background:
        var(--detail-background);
}


.service-item > span {

    font-size:
        20px;

    line-height:
        1;
}


.service-item strong {

    display:
        block;

    margin-bottom:
        3px;

    color:
        var(--detail-text);

    font-size:
        13px;

    font-weight:
        800;
}


.service-item p {

    color:
        var(--detail-muted);

    font-size:
        12px;

    line-height:
        1.5;
}


/* ============================================================
   ANIMATION
============================================================ */

.product-info-panel {

    animation:
        detailFadeIn 0.5s ease both;
}


.product-gallery {

    animation:
        detailFadeIn 0.5s ease both;
}


@keyframes detailFadeIn {

    from {

        opacity:
            0;

        transform:
            translateY(15px);
    }

    to {

        opacity:
            1;

        transform:
            translateY(0);
    }
}


/* ============================================================
   TABLETTE
============================================================ */

@media (max-width: 1100px) {

    .detail-container {

        padding:
            35px 25px 70px;
    }


    .product-view {

        grid-template-columns:
            1fr;

        gap:
            40px;
    }


    .product-gallery {

        position:
            relative;

        top:
            auto;

        max-width:
            800px;

        width:
            100%;

        margin:
            0 auto;
    }


    .main-image-container {

        height:
            480px;
    }


    .product-info-panel {

        max-width:
            800px;

        width:
            100%;

        margin:
            0 auto;
    }

}


/* ============================================================
   TABLETTE PETITE
============================================================ */

@media (max-width: 800px) {

    .main-image-container {

        height:
            420px;
    }


    .customer-info-fields {

        grid-template-columns:
            1fr;
    }


    .customer-info-fields h3 {

        grid-column:
            auto;
    }


    .product-service-info {

        grid-template-columns:
            1fr;
    }

}


/* ============================================================
   MOBILE
============================================================ */

@media (max-width: 600px) {

    .detail-container {

        padding:
            20px 15px 55px;
    }


    .product-view {

        gap:
            28px;
    }


    .main-image-container {

        height:
            330px;

        padding:
            18px;

        border-radius:
            15px;
    }


    .thumbnails-carousel {

        margin-top:
            12px;

        gap:
            8px;
    }


    .thumb-item {

        width:
            65px;

        height:
            65px;
    }


    .breadcrumb {

        font-size:
            10px;

        gap:
            5px;
    }


    .product-info-panel h1 {

        font-size:
            1.9rem;

        letter-spacing:
            -0.7px;
    }


    .current-price {

        font-size:
            1.75rem;
    }


    .old-price {

        font-size:
            12px;
    }


    .product-description p {

        font-size:
            13px;
    }


    .specs-grid {

        grid-template-columns:
            1fr 1fr;

        gap:
            8px;
    }


    .spec-card {

        padding:
            11px;
    }


    .spec-card strong {

        font-size:
            11px;
    }


    .panier-section,
    .quick-order-section {

        padding:
            17px;
    }


    .panier-form {

        align-items:
            stretch;

        flex-direction:
            column;
    }


    .quantity-group input {

        width:
            100%;
    }


    .customer-info-fields {

        padding:
            15px;

        gap:
            12px;
    }


    .quick-order-header {

        gap:
            9px;
    }


    .quick-order-icon {

        width:
            37px;

        height:
            37px;

        font-size:
            16px;
    }


    .quick-order-header h2 {

        font-size:
            15px;
    }


    .quick-order-header p {

        font-size:
            10px;
    }


    .btn-buy {

        min-height:
            48px;

        font-size:
            13px;
    }

}


/* ============================================================
   TRÈS PETITS ÉCRANS
============================================================ */

@media (max-width: 400px) {

    .main-image-container {

        height:
            280px;
    }


    .product-info-panel h1 {

        font-size:
            1.65rem;
    }


    .specs-grid {

        grid-template-columns:
            1fr;
    }


    .current-price {

        font-size:
            1.55rem;
    }


    .old-price {

        font-size:
            11px;
    }

}


/* ============================================================
   ACCESSIBILITÉ
============================================================ */

@media (prefers-reduced-motion: reduce) {

    .detail-container *,
    .detail-container *::before,
    .detail-container *::after {

        animation:
            none !important;

        transition:
            none !important;
    }

}