/* ============================================================
   MODAL "AJOUTÉ AU PANIER" — AtelierCox Child Theme
   ============================================================ */

.ac-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(45, 37, 24, 0.55);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity .2s ease, visibility .2s ease;
}
.ac-modal-overlay.is-visible {
    opacity: 1;
    visibility: visible;
}
body.ac-modal-open { overflow: hidden; }

/* Card */
.ac-modal-card {
    background: #fff;
    border-radius: 8px;
    max-width: 600px;
    width: calc(100% - 32px);
    padding: 40px 40px 36px;
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
    transform: translateY(20px);
    transition: transform .2s ease;
}
.ac-modal-overlay.is-visible .ac-modal-card { transform: translateY(0); }

/* Close */
.ac-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 32px;
    height: 32px;
    border: 1px solid #e0e0d8;
    border-radius: 4px;
    background: #fff;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--ac-text);
    transition: background .15s;
}
.ac-modal-close:hover { background: #f5f5f0; }

/* Cart icon */
.ac-modal-icon-wrap {
    display: flex;
    justify-content: center;
    position: relative;
    margin-bottom: 18px;
}
.ac-modal-cart-svg { display: block; }
.ac-modal-badge {
    position: absolute;
    top: -6px;
    left: calc(50% + 10px);
    background: var(--ac-green);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    font-family: var(--ac-font-body);
    border-radius: 50%;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Title */
.ac-modal-title {
    font-family: var(--ac-font-title);
    font-size: 20px;
    font-weight: 700;
    color: var(--ac-text);
    text-align: center;
    margin: 0 0 28px;
    line-height: 1.35;
}

/* Product row */
.ac-modal-product {
    display: flex;
    gap: 22px;
    margin-bottom: 24px;
}
.ac-modal-product-img-wrap { flex-shrink: 0; width: 200px; }
.ac-modal-product-img {
    width: 200px;
    height: auto;
    min-height: 140px;
    object-fit: cover;
    border-radius: 4px;
    display: block;
}
.ac-modal-product-details { flex: 1; }
.ac-modal-product-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--ac-text);
    margin: 0 0 14px;
    line-height: 1.4;
}
.ac-modal-options { margin-bottom: 14px; }
.ac-modal-options-label {
    font-size: 13px;
    font-weight: 600;
    color: var(--ac-text);
    display: block;
    margin-bottom: 4px;
}
.ac-modal-options ul {
    list-style: none;
    margin: 0;
    padding: 0;
}
.ac-modal-options li {
    font-size: 13px;
    color: var(--ac-text-light);
    line-height: 1.75;
}
.ac-modal-price {
    font-size: 22px;
    font-weight: 700;
    color: var(--ac-green);
    margin: 0;
}
.ac-modal-price .woocommerce-Price-amount { color: var(--ac-green); }

/* Divider */
.ac-modal-divider {
    border: none;
    border-top: 1px solid #e8e8e0;
    margin: 0 0 24px;
}

/* Actions */
.ac-modal-actions {
    display: flex;
    gap: 14px;
}
.ac-modal-actions .ac-btn-outline,
.ac-modal-actions .ac-btn-primary {
    flex: 1;
    text-align: center;
    padding: 14px 16px;
    font-size: 14px;
    font-weight: 600;
}

/* Responsive */
@media (max-width: 520px) {
    .ac-modal-card { padding: 28px 20px 24px; }
    .ac-modal-product { flex-direction: column; }
    .ac-modal-product-img-wrap { width: 100%; }
    .ac-modal-product-img { width: 100%; min-height: auto; }
    .ac-modal-actions { flex-direction: column-reverse; }
    .ac-modal-title { font-size: 17px; }
}
