/* /assets/css/shop.css */

/* Grille de la Boutique */
.shop-grid {
    margin-bottom: 50px;
}

.product-card {
    display: flex;
    flex-direction: column;
    background: var(--ac-card);
    border: 1px solid var(--ac-border);
    border-radius: 16px;
    overflow: hidden;
    transition: transform 0.2s, border-color 0.2s;
}

.product-card:hover {
    transform: translateY(-5px);
    border-color: var(--ac-accent1);
}

.product-image-wrapper {
    position: relative;
    width: 100%;
    padding-top: 100%; /* Ratio 1:1 Carré parfait */
    background: var(--ac-bg2);
    border-bottom: 1px solid var(--ac-border);
}

.product-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background: rgba(138, 43, 226, 0.85); /* Accent2 Violet */
    color: #fff;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-family: var(--ac-font-h2);
    backdrop-filter: blur(4px);
}

.product-badge--digital {
    background: rgba(214, 175, 55, 0.85); /* Accent1 Or */
    color: var(--ac-bg);
    font-weight: bold;
}

.product-body {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.product-title {
    font-family: var(--ac-font-h1);
    color: var(--ac-text);
    font-size: 1.3rem;
    margin-bottom: 8px;
    line-height: 1.4;
}

.product-desc {
    color: var(--ac-muted);
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 20px;
    flex: 1;
}

.product-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
    gap: 10px;
}

.product-price {
    font-family: var(--ac-font-h2);
    font-size: 1.4rem;
    color: var(--ac-accent1);
    font-weight: bold;
}

/* Page Détail Produit */
.product-detail-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-top: 40px;
    margin-bottom: 60px;
}

.product-gallery {
    border: 1px solid var(--ac-border);
    border-radius: 16px;
    overflow: hidden;
    background: var(--ac-card);
}

@media (max-width: 768px) {
    .product-detail-container {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

/* ==========================================================================
   PAGE PANIER (CART)
   ========================================================================== */
.cart-container {
    background: var(--ac-card);
    border: 1px solid var(--ac-border);
    border-radius: 16px;
    padding: 30px;
    margin-bottom: 40px;
}

.cart-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 30px;
}

.cart-table th {
    text-align: left;
    padding: 15px;
    border-bottom: 2px solid var(--ac-border);
    color: var(--ac-accent1);
    font-family: var(--ac-font-h2);
    font-size: 1.2rem;
}

.cart-table td {
    padding: 20px 15px;
    border-bottom: 1px solid var(--ac-line);
    vertical-align: middle;
}

.cart-item-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.cart-item-img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid var(--ac-border);
    background: var(--ac-bg);
}

.cart-item-title {
    font-family: var(--ac-font-h3);
    font-size: 1.2rem;
    color: var(--ac-text);
    margin: 0 0 5px 0;
}

.cart-item-variant {
    color: var(--ac-muted);
    font-size: 0.9rem;
}

.cart-qty-input {
    width: 70px;
    padding: 8px;
    background: var(--ac-bg);
    border: 1px solid var(--ac-border);
    border-radius: 6px;
    color: var(--ac-text);
    text-align: center;
    font-family: var(--ac-font-body);
}

.cart-summary {
    display: flex;
    justify-content: flex-end;
    margin-top: 20px;
}

.cart-summary-box {
    background: var(--ac-bg2);
    border: 1px solid var(--ac-border);
    border-radius: 12px;
    padding: 25px;
    min-width: 300px;
}

.cart-total-line {
    display: flex;
    justify-content: space-between;
    font-size: 1.5rem;
    font-family: var(--ac-font-h2);
    color: var(--ac-accent1);
    margin-bottom: 25px;
    border-bottom: 1px solid var(--ac-line);
    padding-bottom: 15px;
}

/* Responsive Mobile */
@media (max-width: 768px) {
    .cart-table thead {
        display: none; /* Cache les en-têtes sur mobile */
    }
    .cart-table, .cart-table tbody, .cart-table tr, .cart-table td {
        display: block;
        width: 100%;
    }
    .cart-table tr {
        margin-bottom: 20px;
        border: 1px solid var(--ac-border);
        border-radius: 8px;
        padding: 10px;
        background: var(--ac-bg2);
    }
    .cart-table td {
        border-bottom: none;
        padding: 10px;
        display: flex;
        justify-content: space-between;
        align-items: center;
    }
    .cart-table td::before {
        content: attr(data-label);
        font-weight: bold;
        color: var(--ac-accent1);
        margin-right: 10px;
    }
    .cart-item-info {
        flex-direction: column;
        text-align: center;
    }
    .cart-item-img {
        width: 100%;
        max-width: 150px;
        height: auto;
    }
}

/* ==========================================================================
   PAGE DE TRANSITION CHECKOUT
   ========================================================================== */
.checkout-loading-box {
    text-align: center;
    padding: 80px 20px;
    background: var(--ac-card);
    border: 1px solid var(--ac-border);
    border-radius: 16px;
    max-width: 600px;
    margin: 40px auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.checkout-spinner {
    font-size: 4rem;
    animation: arcaneRotate 2s linear infinite;
    margin-bottom: 25px;
    display: inline-block;
}

@keyframes arcaneRotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

