/**
 * Vog Cart — Styles du panneau lateral
 * Adapte de moxiecart.css — palette VOG : #1a1a1a (noir) + #BCCF00 (vert-jaune)
 */

/* ===== OVERLAY ===== */
.vogcart-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  z-index: 9998;
}

.vogcart-overlay.vogcart-active {
  opacity: 1;
  visibility: visible;
}

/* ===== PANNEAU LATERAL ===== */
.vogcart-panel {
  position: fixed;
  top: 0;
  right: -420px;
  width: 420px;
  max-width: 100vw;
  height: 100vh;
  background: #fff;
  box-shadow: -2px 0 12px rgba(0, 0, 0, 0.15);
  transition: right 0.3s ease;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.vogcart-panel.vogcart-active {
  right: 0;
}

/* ===== HEADER NOIR ===== */
.vogcart-header {
  background: #1a1a1a;
  color: #fff;
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px solid #BCCF00;
  flex-shrink: 0;
}

.vogcart-title {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.vogcart-close {
  background: transparent;
  border: none;
  color: #fff;
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.8;
  transition: opacity 0.2s;
}

.vogcart-close:hover {
  opacity: 1;
}

/* ===== MESSAGE LIVRAISON ===== */
.vogcart-shipping-notice {
  padding: 14px 24px;
  background: #f5f5f5;
  border-bottom: 0.5px solid #e5e5e5;
  flex-shrink: 0;
}

.vogcart-shipping-text {
  margin: 0;
  font-size: 13px;
  color: #666;
}

.vogcart-shipping-text strong {
  color: #1a1a1a;
}

.vogcart-shipping-success {
  color: #5a7000;
  font-weight: 600;
}

/* ===== CONTENU SCROLLABLE ===== */
.vogcart-content {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
}

/* ===== PRODUITS DANS LE PANIER ===== */
.vogcart-products {
  margin-bottom: 24px;
}

.vogcart-product {
  display: flex;
  gap: 16px;
  margin-bottom: 16px;
}

.vogcart-product-img {
  width: 80px;
  height: 80px;
  background: #f5f5f5;
  border-radius: 8px;
  flex-shrink: 0;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.vogcart-product-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.vogcart-product-noimg {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.vogcart-product-info {
  flex: 1;
  min-width: 0;
}

.vogcart-product-name {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.3;
  color: #000;
}

.vogcart-product-attrs {
  margin: 0 0 12px;
  font-size: 13px;
  color: #666;
}

.vogcart-product-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Selecteur de quantite */
.vogcart-qty {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 0.5px solid #d1d1d1;
  border-radius: 8px;
  padding: 4px 8px;
}

.vogcart-qty-btn {
  background: transparent;
  border: none;
  color: #666;
  font-size: 16px;
  cursor: pointer;
  padding: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s;
}

.vogcart-qty-btn:hover {
  color: #000;
}

.vogcart-qty-value {
  font-size: 14px;
  font-weight: 500;
  min-width: 20px;
  text-align: center;
}

.vogcart-product-price {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: #000;
}

.vogcart-ht {
  font-size: 11px;
  font-weight: 500;
  color: #999;
  letter-spacing: 0.3px;
}

/* Bouton retirer */
.vogcart-remove {
  background: transparent;
  border: none;
  color: #666;
  font-size: 13px;
  text-decoration: underline;
  cursor: pointer;
  padding: 0;
  margin-bottom: 24px;
  transition: color 0.2s;
}

.vogcart-remove:hover {
  color: #000;
}

/* ===== DIVIDER ===== */
.vogcart-divider {
  height: 0.5px;
  background: #e5e5e5;
  margin: 24px 0;
}

/* ===== INFO TAXES ===== */
.vogcart-tax-notice {
  padding: 12px;
  background: #f5f5f5;
  border-radius: 8px;
}

.vogcart-tax-notice p {
  margin: 0;
  font-size: 13px;
  color: #666;
}

/* ===== PANIER VIDE ===== */
.vogcart-empty {
  text-align: center;
  padding: 60px 24px;
}

.vogcart-empty svg {
  margin-bottom: 16px;
}

.vogcart-empty p {
  margin: 0;
  font-size: 15px;
  color: #999;
}

/* ===== FOOTER STICKY ===== */
.vogcart-footer {
  padding: 20px 24px;
  border-top: 0.5px solid #e5e5e5;
  background: #fff;
  flex-shrink: 0;
}

.vogcart-btn {
  width: 100%;
  height: 48px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  border: none;
}

.vogcart-btn-outline {
  background: transparent;
  color: #1a1a1a;
  border: 0.5px solid #b1b1b1;
  margin-bottom: 12px;
}

.vogcart-btn-outline:hover {
  background: #f5f5f5;
  border-color: #1a1a1a;
}

.vogcart-btn-primary {
  background: #1a1a1a;
  color: #fff;
}

.vogcart-btn-primary:hover {
  background: #000;
  color: #BCCF00;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 480px) {
  .vogcart-panel {
    width: 100vw;
    right: -100vw;
  }

  .vogcart-panel.vogcart-active {
    right: 0;
  }
}

/* ===== ETAT DE CHARGEMENT ===== */
.vogcart-loading {
  pointer-events: none;
  opacity: 0.6;
}

@keyframes vogcart-spin {
  to { transform: rotate(360deg); }
}

.vogcart-spinner {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(0, 0, 0, 0.1);
  border-left-color: #1a1a1a;
  border-radius: 50%;
  animation: vogcart-spin 0.6s linear infinite;
}

/* ===== MASQUER LA MODAL NATIVE PRESTASHOP ===== */
#blockcart-modal,
.blockcart-modal,
[id*="blockcart"],
[class*="blockcart-modal"],
.modal.show.fade[id*="product"],
body.modal-open .modal.show {
  display: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

body.modal-open {
  overflow: auto !important;
  padding-right: 0 !important;
}

.modal-backdrop {
  display: none !important;
}
