/* Scheda prodotto – layout commerciale */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,600;0,700&family=Outfit:wght@300;400;500;600;700&display=swap');

.prodotto-page {
  --prodotto-bg: #faf9f7;
  --prodotto-card: #fff;
  --prodotto-charcoal: #1a1918;
  --prodotto-muted: #5c5651;
  --prodotto-gold: #b8860b;
  --prodotto-gold-light: #e8d5a3;
  --prodotto-cta: #8b6914;
  --prodotto-cta-hover: #6d5210;
  --prodotto-border: #e8e4df;
  font-family: 'Outfit', sans-serif;
  background: var(--prodotto-bg);
  color: var(--prodotto-charcoal);
}

.prodotto-page .breadcrumb-prodotto {
  font-size: 0.85rem;
  color: var(--prodotto-muted);
  margin-bottom: 1rem;
}
.prodotto-page .breadcrumb-prodotto a { color: var(--prodotto-muted); text-decoration: none; }
.prodotto-page .breadcrumb-prodotto a:hover { color: var(--prodotto-cta); }

/* Galleria principale */
.prodotto-gallery-wrap {
  position: sticky;
  top: 1rem;
  background: var(--prodotto-card);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 24px rgba(0,0,0,.06);
}
.prodotto-gallery-main {
  aspect-ratio: 1;
  background: linear-gradient(145deg, #f5f2ee 0%, #faf9f7 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  position: relative;
}
.prodotto-gallery-main img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  transition: transform 0.3s ease;
}
.prodotto-gallery-main:hover img { transform: scale(1.02); }

/* Badge "Variante" sulla foto principale */
.prodotto-img-badge {
  position: absolute;
  left: 14px;
  bottom: 14px;
  padding: 0.45rem 0.7rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  background: rgba(26, 25, 24, 0.86);
  color: #fff;
  border: 1px solid rgba(255,255,255,.25);
  backdrop-filter: blur(8px);
}

/* Miniature galleria */
.prodotto-gallery-thumbs {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
  padding: 12px;
  border-top: 1px solid var(--prodotto-border);
  background: #fff;
}
@media (max-width: 576px) {
  .prodotto-gallery-thumbs { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}
.prodotto-thumb {
  appearance: none;
  border: 2px solid transparent;
  background: #faf9f7;
  border-radius: 12px;
  padding: 8px;
  cursor: pointer;
  position: relative;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform .12s ease, border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.prodotto-thumb img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.prodotto-thumb:hover {
  transform: translateY(-1px);
  border-color: var(--prodotto-gold-light);
  box-shadow: 0 8px 18px rgba(0,0,0,.08);
}
.prodotto-thumb.is-active {
  border-color: var(--prodotto-cta);
  box-shadow: 0 10px 22px rgba(139,105,20,.22);
  background: #fffdf6;
}

/* Evidenzia subito che è una variante */
.prodotto-thumb.is-variant {
  border-style: dashed;
  background: linear-gradient(145deg, #ffffff 0%, #fff9ea 100%);
}
.prodotto-thumb.is-variant.is-active {
  border-style: solid;
  outline: 2px solid rgba(184,134,11,.28);
  outline-offset: 2px;
}
.prodotto-thumb-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 0.12rem 0.35rem;
  border-radius: 6px;
  background: rgba(184, 134, 11, 0.16);
  color: var(--prodotto-cta);
  border: 1px solid rgba(184, 134, 11, 0.35);
}

/* Buy box */
.prodotto-buy-box {
  background: var(--prodotto-card);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 4px 24px rgba(0,0,0,.06);
}
.prodotto-page .prodotto-brand {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--prodotto-gold);
  margin-bottom: 0.5rem;
}
.prodotto-page .prodotto-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 0.75rem;
  color: var(--prodotto-charcoal);
}
.prodotto-short-desc {
  font-size: 0.95rem;
  color: var(--prodotto-muted);
  line-height: 1.5;
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--prodotto-border);
}
.prodotto-price-block {
  margin-bottom: 1.5rem;
}
.prodotto-price {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--prodotto-charcoal);
}
.prodotto-price .currency { font-size: 1rem; font-weight: 500; color: var(--prodotto-muted); }
.prodotto-badge-listino {
  font-size: 0.7rem;
  padding: 0.2rem 0.5rem;
  background: var(--prodotto-gold-light);
  color: var(--prodotto-cta);
  border-radius: 4px;
  margin-left: 0.5rem;
  font-weight: 600;
}
.prodotto-variants .variant-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 1rem;
  border: 2px solid var(--prodotto-border);
  border-radius: 10px;
  margin-bottom: 0.5rem;
  transition: border-color 0.2s, background 0.2s;
}
.prodotto-variants .variant-item:hover { border-color: var(--prodotto-gold-light); background: #fefdfb; }
.prodotto-variants .variant-item .variant-name { font-weight: 500; }
.prodotto-variants .variant-item .variant-price { font-weight: 700; color: var(--prodotto-charcoal); }
.prodotto-variants .variant-item .btn-add-variant {
  background: linear-gradient(135deg, var(--prodotto-cta) 0%, #a07818 100%);
  color: #fff;
  border: none;
  font-weight: 600;
  padding: 0.4rem 1rem;
  border-radius: 8px;
  font-size: 0.9rem;
  transition: transform 0.15s, box-shadow 0.2s;
}
.prodotto-variants .variant-item .btn-add-variant:hover { color: #fff; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(139,105,20,.3); }
.prodotto-qty-wrap {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1.25rem 0;
}
.prodotto-qty-wrap label { font-weight: 500; margin-bottom: 0; min-width: 60px; }
.prodotto-qty-wrap input.form-control { width: 80px; text-align: center; }
.prodotto-cta-add {
  width: 100%;
  padding: 1rem 1.5rem;
  font-size: 1.05rem;
  font-weight: 600;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--prodotto-cta) 0%, #a07818 100%);
  border: none;
  color: #fff;
  transition: transform 0.15s, box-shadow 0.2s;
}
.prodotto-cta-add:hover { color: #fff; transform: translateY(-1px); box-shadow: 0 6px 20px rgba(139,105,20,.35); }
.prodotto-trust {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--prodotto-border);
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 0.8rem;
  color: var(--prodotto-muted);
}
.prodotto-trust span { display: inline-flex; align-items: center; gap: 0.35rem; }

/* Sezioni sotto */
.prodotto-section {
  background: var(--prodotto-card);
  border-radius: 16px;
  padding: 2rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 2px 16px rgba(0,0,0,.04);
}
.prodotto-section h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--prodotto-charcoal);
}
.prodotto-section .content { color: var(--prodotto-muted); line-height: 1.7; }

/* Related */
.prodotto-related-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  color: var(--prodotto-charcoal);
}
.prodotto-related-card {
  background: var(--prodotto-card);
  border-radius: 12px;
  overflow: hidden;
  height: 100%;
  text-decoration: none;
  color: inherit;
  display: block;
  transition: transform 0.2s, box-shadow 0.2s;
  border: 1px solid var(--prodotto-border);
}
.prodotto-related-card:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(0,0,0,.08); color: inherit; }
.prodotto-related-card .img-wrap {
  aspect-ratio: 1;
  background: linear-gradient(145deg, #f5f2ee 0%, #faf9f7 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.prodotto-related-card .img-wrap img { max-width: 100%; max-height: 100%; object-fit: contain; }
.prodotto-related-card .card-body { padding: 1rem; }
.prodotto-related-card .card-body .name { font-weight: 600; font-size: 0.95rem; }

.prodotto-back { color: var(--prodotto-muted); text-decoration: none; font-size: 0.9rem; display: inline-flex; align-items: center; gap: 0.35rem; margin-top: 1rem; }
.prodotto-back:hover { color: var(--prodotto-cta); }
