/* =================================================================
 * custom.css — Styles fiche produit MonPC.Store
 *
 * À placer dans : themes/classic/assets/css/custom.css
 * ================================================================= */

/* -----------------------------------------------------------------
 * 1. BLOC SPECS CLÉS (injecté par custom.js)
 * ----------------------------------------------------------------- */
.monpc-specs-box {
  background: #f8f9fa;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  padding: 14px 18px;
  margin: 16px 0;
}

.monpc-specs-title {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: #6c757d;
  margin: 0 0 10px 0;
}

.monpc-specs-grid {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 16px;
  margin: 0;
}

.monpc-specs-grid dt {
  font-size: 13px;
  font-weight: 400;
  color: #6c757d;
  padding: 2px 0;
}

.monpc-specs-grid dd {
  font-size: 13px;
  font-weight: 600;
  color: #232323;
  margin: 0;
  padding: 2px 0;
}

/* -----------------------------------------------------------------
 * 2. ONGLETS PRODUIT — meilleur style
 * ----------------------------------------------------------------- */
.tabs .nav-tabs {
  border-bottom: 2px solid #e9ecef;
  margin-bottom: 0;
}

.tabs .nav-tabs .nav-link {
  font-size: 14px;
  font-weight: 500;
  color: #6c757d;
  border: none;
  border-bottom: 2px solid transparent;
  padding: 10px 20px;
  margin-bottom: -2px;
  transition: color 0.2s, border-color 0.2s;
  background: transparent;
}

.tabs .nav-tabs .nav-link:hover {
  color: #232323;
  border-bottom-color: #adb5bd;
}

.tabs .nav-tabs .nav-link.active,
.tabs .nav-tabs .nav-link.js-product-nav-active {
  color: #24b9d7;
  border-bottom-color: #24b9d7;
}

.tabs .tab-content {
  padding: 20px 0;
}

/* -----------------------------------------------------------------
 * 3. TABLEAU CARACTÉRISTIQUES — zébré et propre
 * ----------------------------------------------------------------- */
.monpc-specs-table,
#description .table,
#characteristics .table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  margin: 16px 0 0 0;
}

.monpc-specs-table td,
#description .table td,
#characteristics .table td {
  padding: 9px 14px;
  border: none;
  vertical-align: middle;
}

.monpc-specs-table tr:nth-child(even),
#description .table tr:nth-child(even),
#characteristics .table tr:nth-child(even) {
  background-color: #f8f9fa;
}

.monpc-specs-table tr:nth-child(odd),
#description .table tr:nth-child(odd),
#characteristics .table tr:nth-child(odd) {
  background-color: transparent;
}

.monpc-specs-table td:first-child,
#description .table td:first-child,
#characteristics .table td:first-child {
  color: #6c757d;
  font-weight: 400;
  width: 45%;
}

.monpc-specs-table td:first-child strong,
#description .table td:first-child strong,
#characteristics .table td:first-child strong {
  font-weight: 500;
  color: #6c757d;
}

.monpc-specs-table td:last-child,
#description .table td:last-child,
#characteristics .table td:last-child {
  color: #232323;
  font-weight: 500;
}

/* Titre "Informations techniques" dans l'onglet */
#description h3,
#characteristics h3 {
  font-size: 16px;
  font-weight: 600;
  color: #232323;
  margin: 0 0 8px 0;
}

/* -----------------------------------------------------------------
 * 4. DESCRIPTION TEXTE — meilleure lisibilité
 * ----------------------------------------------------------------- */
#description .product-description {
  font-size: 14px;
  line-height: 1.75;
  color: #444;
}

#description .product-description p {
  margin-bottom: 12px;
}

/* -----------------------------------------------------------------
 * 5. DÉTAILS DU PRODUIT — alignement propre
 * ----------------------------------------------------------------- */
#product-details .product-manufacturer,
#product-details .product-reference,
#product-details .product-features {
  font-size: 13px;
  padding: 6px 0;
}

#product-details .label {
  color: #6c757d;
  font-weight: 400;
  min-width: 120px;
  display: inline-block;
}

/* -----------------------------------------------------------------
 * 6. BADGE RECONDITIONNÉ — style éco-responsable
 * ----------------------------------------------------------------- */

/* Badge sur la fiche produit (PrestaShop affiche condition dans .product-condition) */
.product-condition {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
  color: #2e7d32;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid #a5d6a7;
  margin: 8px 0 12px 0;
}

/* Icône feuille avant le texte */
.product-condition::before {
  content: "\267B";  /* symbole recyclage ♻ */
  font-size: 16px;
}

/* Badge sur les vignettes produit en listing (miniatures) */
.product-miniature .product-flag.refurbished,
.product-miniature .product-flag[class*="reconditionn"] {
  background: #2e7d32;
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 3px;
}

/* Masquer le badge condition si c'est "Neuf" (on n'affiche que reconditionné) */
.product-condition[style*="display: none"],
.product-condition:empty {
  display: none;
}

/* -----------------------------------------------------------------
 * 7. RESPONSIVE — mobile (badges éco inclus)
 * ----------------------------------------------------------------- */
@media (max-width: 768px) {
  .monpc-specs-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2px 12px;
  }

  .tabs .nav-tabs .nav-link {
    font-size: 12px;
    padding: 8px 12px;
  }

  .monpc-specs-table td,
  #description .table td,
  #characteristics .table td {
    padding: 7px 10px;
    font-size: 12px;
  }
}
