/* =====================================================================
   Bétail et Viande — Personnalisation interactive des colis (accueil)
   Styles autonomes, préfixés « pz- » pour éviter tout conflit.
   ===================================================================== */

/* Bouton Commander ajouté sur les cartes de l'accueil */
.pz-commander {
  margin-top: 0.9rem;
}

/* Empêche le défilement de l'arrière-plan quand la fenêtre est ouverte */
body.pz-open {
  overflow: hidden;
}

/* ---- Voile ------------------------------------------------------- */
.pz-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 24px 16px;
  background: rgba(20, 28, 20, 0.55);
  overflow-y: auto;
}
.pz-overlay[hidden] {
  display: none;
}

/* ---- Fenêtre ----------------------------------------------------- */
.pz-modal {
  position: relative;
  width: 100%;
  max-width: 760px;
  margin: auto;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
  overflow: hidden;
}

.pz-close {
  position: absolute;
  top: 10px;
  right: 12px;
  width: 38px;
  height: 38px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
}
.pz-close:hover {
  background: rgba(255, 255, 255, 0.32);
}

/* ---- En-tête ----------------------------------------------------- */
.pz-head {
  padding: 18px 20px 16px;
  background: var(--green-700, #1b5e20);
  color: #fff;
}
.pz-cat {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: rgba(255, 255, 255, 0.16);
  padding: 3px 10px;
  border-radius: 999px;
}
.pz-head h2 {
  margin: 0.5rem 0 0.6rem;
  font-size: 1.4rem;
  color: #fff;
}
.pz-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  font-size: 0.92rem;
}
.pz-meta span {
  display: inline-flex;
  gap: 6px;
}
.pz-meta strong {
  font-weight: 700;
  opacity: 0.85;
}
.pz-demo {
  margin: 0.7rem 0 0;
  font-size: 0.8rem;
  opacity: 0.9;
}

/* ---- Corps ------------------------------------------------------- */
.pz-body {
  padding: 18px 20px 20px;
}
.pz-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.pz-col h3 {
  margin: 0 0 0.7rem;
  font-size: 1.02rem;
  color: var(--green-700, #1b5e20);
}

/* ---- Liste du contenu (radios) ----------------------------------- */
.pz-compo {
  list-style: none;
  margin: 0;
  padding: 0;
}
.pz-item {
  margin-bottom: 6px;
}
.pz-radio {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 11px;
  border: 1px solid #d4dad4;
  border-radius: 8px;
  cursor: pointer;
}
.pz-radio:hover {
  border-color: var(--green-700, #1b5e20);
}
.pz-radio input {
  margin: 0;
  width: 18px;
  height: 18px;
  accent-color: var(--green-700, #1b5e20);
  flex: none;
}
.pz-item-nom {
  flex: 1;
  font-weight: 600;
}
.pz-item-qte {
  color: #555;
  font-size: 0.9rem;
  white-space: nowrap;
}
.pz-item.is-modifie .pz-radio {
  border-color: var(--green-700, #1b5e20);
  background: #eef5ef;
}

/* ---- Bloc des remplacements -------------------------------------- */
.pz-rempl {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.pz-hint {
  margin: 0 0 4px;
  font-size: 0.9rem;
  color: #555;
}
.pz-opt {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  text-align: left;
  padding: 10px 11px;
  border: 1px solid #d4dad4;
  border-radius: 8px;
  background: #fff;
  font: inherit;
  cursor: pointer;
}
.pz-opt:hover {
  border-color: var(--green-700, #1b5e20);
  background: #f4f9f4;
}
/* ---- Actions ----------------------------------------------------- */
.pz-actions {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

/* ---- Récapitulatif final ----------------------------------------- */
.pz-recap h3 {
  margin: 0 0 0.8rem;
  color: var(--green-700, #1b5e20);
}
.pz-recap-list {
  list-style: none;
  margin: 0 0 12px;
  padding: 0;
}
.pz-recap-list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 0;
  border-bottom: 1px solid #eceece;
}
.pz-recap-list li span:last-child {
  color: #555;
  white-space: nowrap;
}
.pz-recap-modif {
  font-size: 0.92rem;
  margin: 0 0 12px;
}
.pz-recap-modifs {
  border: 1px solid #cfe0d2;
  background: #f3f8f3;
  border-radius: 10px;
  padding: 10px 14px;
  margin-bottom: 12px;
}
.pz-recap-modifs > strong {
  display: block;
  margin-bottom: 6px;
  color: var(--green-700, #1b5e20);
}
.pz-recap-modifs ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.pz-recap-modifs li {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 5px 0;
  font-size: 0.92rem;
  border-top: 1px dashed #d4dad4;
}
.pz-recap-modifs li:first-child {
  border-top: none;
}
.pz-arrow {
  color: var(--green-700, #1b5e20);
  font-weight: 700;
}
.pz-recap-pay {
  border: 1px solid #cfe0d2;
  background: #f3f8f3;
  border-radius: 10px;
  padding: 8px 14px;
  margin-bottom: 12px;
}
.pz-recap-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 4px 0;
  font-size: 0.92rem;
}
.pz-recap-row span:last-child {
  font-weight: 600;
  text-align: right;
}
.pz-demo-box {
  font-size: 0.85rem;
  color: #6b5b00;
  background: #fff7d6;
  border: 1px solid #ece0a0;
  border-radius: 8px;
  padding: 9px 12px;
}

/* ---- Étape choix retrait / livraison ----------------------------- */
.pz-remise h3 {
  margin: 0 0 .8rem;
  color: var(--green-700, #1b5e20);
}

.pz-remise-cards {
  display: grid;
  gap: .7rem;
  margin-bottom: 1rem;
}

.pz-remise-card {
  display: flex;
  align-items: center;
  gap: .8rem;
  padding: 1rem 1.1rem;
  border: 1.5px solid #d4dad4;
  border-radius: 10px;
  cursor: pointer;
  background: #fff;
  transition: .15s ease;
}

.pz-remise-card:hover {
  border-color: var(--green-700, #1b5e20);
}

.pz-remise-card.selected {
  border-color: var(--green-700, #1b5e20);
  background: #eef5ef;
}

.pz-remise-card input {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  accent-color: var(--green-700, #1b5e20);
  margin: 0;
}

.pz-remise-card__body {
  flex: 1;
}

.pz-remise-card__body strong {
  display: block;
  font-size: 1rem;
  color: var(--green-800, #284631);
  margin-bottom: .15rem;
}

.pz-remise-card__body span {
  font-size: .88rem;
  color: #555;
}

/* ---- Formulaire retrait / livraison dans la modale ---------------- */
.pz-remise-form {
  margin: .8rem 0 .4rem;
  padding: 1rem 1.1rem;
  border: 1px solid #cfe0d2;
  border-radius: 10px;
  background: #f8fbf8;
}

.pz-remise-form .pz-demo-box {
  margin-bottom: .8rem;
}

.pz-field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .8rem;
}

.pz-field {
  display: grid;
  gap: .3rem;
  margin-bottom: .7rem;
}

.pz-field label {
  font-weight: 600;
  font-size: .86rem;
  color: var(--green-800, #284631);
}

.pz-field .req {
  color: var(--bordeaux, #8a2733);
}

.pz-field input,
.pz-field select {
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: .95rem;
  padding: .6rem .75rem;
  border-radius: 8px;
  border: 1.5px solid #d4dad4;
  background: #fff;
  color: var(--ink, #2c2820);
}

.pz-field input:focus,
.pz-field select:focus {
  outline: none;
  border-color: var(--green-600, #3d7049);
  box-shadow: 0 0 0 3px rgba(61, 112, 73, .15);
}

.pz-remise-note {
  margin: .5rem 0 0;
  font-size: .88rem;
  color: #555;
  font-style: italic;
}

/* ---- Info ville (livraison) --------------------------------------- */
.pz-liv-info {
  padding: .7rem .9rem;
  border-radius: 8px;
  font-size: .9rem;
  margin: .3rem 0 .6rem;
  border: 1px solid;
}

.pz-liv-info--ok {
  background: #eef5ef;
  border-color: var(--green-600, #3d7049);
  color: var(--green-800, #284631);
}

.pz-liv-info--ko {
  background: #fbeed3;
  border-color: #e0c78a;
  color: #6b4f3a;
}

.pz-hors-zone-actions {
  display: flex;
  gap: .6rem;
  margin-top: .6rem;
  flex-wrap: wrap;
}

.pz-hors-zone-actions .btn {
  font-size: .88rem;
  padding: .5rem 1rem;
}

/* ---- Responsive : tablette étroite et mobile --------------------- */
@media (max-width: 720px) {
  .pz-cols {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .pz-modal {
    border-radius: 12px;
  }
  .pz-head h2 {
    font-size: 1.2rem;
  }
  .pz-actions .btn {
    flex: 1 1 auto;
  }
}

@media (max-width: 400px) {
  .pz-overlay {
    padding: 12px 8px;
  }
  .pz-body {
    padding: 14px 14px 16px;
  }
  .pz-head {
    padding: 16px 16px 14px;
  }
}
