/* mafparolle (26/11/2026) : personnalisation en direct des affiches Parolle. Polices de l'affiche (libres, OFL) hébergées
   sur le site : les mêmes fichiers que le rendu d'impression du studio, pour que l'aperçu coupe les lignes au même endroit. */
@font-face { font-family: "MafInstrument"; src: url("../fonts/InstrumentSerif-Regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "MafBaskerville"; src: url("../fonts/LibreBaskerville-Regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "MafBaskerville"; src: url("../fonts/LibreBaskerville-Italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "MafBaskerville"; src: url("../fonts/LibreBaskerville-Bold.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "MafCaveat"; src: url("../fonts/Caveat-Regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }   /* signature (26/11, Sébastien) */

/* le formulaire d'origine reste dans la page (il porte le texte envoyé), caché */
.mafpr-actif .product-customization form { display: none; }
.mafpr-actif .product-customization .card { padding: 0; border: 0; background: transparent; box-shadow: none; }

/* 26/11/2026 (Sébastien : « garder une unité sur le site ») : mêmes titres, champs, liens et boutons que Famiglia (mafamiglia.css) */
.mafpr { margin: 6px 0 4px; text-align: left; }
.mafpr [hidden] { display: none !important; }
.mafpr__ouvrir { display: block; margin: 18px auto 0; }   /* centré comme le titre et le prix de la fiche, décollé de la note */
/* 26/11/2026 (Sébastien, variante 2) : pilule rouge brique #a8322d, comme l'étiquette « ✍️ Personnalisable » des grilles (19/11) */
.mafpr .mafpr__ouvrir { background: #a8322d; border-color: #a8322d; color: #fff; border-radius: 999px; padding: 9px 22px; box-shadow: 0 1px 3px rgba(40, 30, 20, .18); }
.mafpr .mafpr__ouvrir:hover, .mafpr .mafpr__ouvrir:focus { background: #8f2a26; border-color: #8f2a26; color: #fff; }
.mafpr__sous { margin: 6px 0 4px; text-align: center; font-size: .82rem; color: #6b6259; }
.mafpr__titre { font-weight: 500; font-size: 1rem; margin: 14px 0 10px; color: #1c1a18; }
.mafpr__editeur > .mafpr__titre:first-of-type { margin-top: 0; }
.mafpr__deux { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
.mafpr__lignes { display: grid; gap: 8px; }
.mafpr__ligne { display: flex; align-items: flex-start; gap: 8px; }
.mafpr .mafpr__saisie {
  flex: 1 1 0; width: 100%; min-width: 0; font-size: 16px; /* 16 px : iOS ne zoome pas sur le champ */
  padding: 11px 12px; border: 1px solid #d8cfc2; border-radius: 6px; background: #fffdf9; color: #1c1a18;
  -webkit-appearance: none; appearance: none; line-height: 1.3; font-family: inherit;
}
.mafpr textarea.mafpr__saisie { resize: none; overflow: hidden; display: block; }
.mafpr .mafpr__saisie:focus { outline: 2px solid #1c1a18; outline-offset: 1px; border-color: #1c1a18; }
.mafpr__retirer { flex: 0 0 auto; width: 32px; height: 44px; border: 0; background: transparent; color: #8a8077; font-size: 1.4rem; line-height: 1; cursor: pointer; padding: 0; }
.mafpr__retirer:hover { color: #b3261e; }
.mafpr__ajout { display: inline-block; margin: 10px 0 0; border: 0; background: transparent; color: #85633a; font: inherit; font-weight: 500; font-size: .92rem; padding: 6px 0; cursor: pointer; text-align: left; }
.mafpr__ajout:hover { text-decoration: underline; color: #85633a; }
.mafpr__aide { margin: 4px 0 0; font-size: .82rem; color: #6b6259; }
.mafpr__etat { margin: 6px 0 0; font-size: .85rem; min-height: 1.2em; color: #6b6259; }
.mafpr__etat.mafpr--erreur { color: #b3261e; }
.mafpr__liens { display: flex; flex-direction: column; align-items: flex-start; }
.mafpr__liens .mafpr__ajout { margin-top: 2px; }
.mafpr__dessins { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.mafpr__dessins button { width: 44px; height: 44px; border: 1px solid #d8cfc2; background: #fffdf9; border-radius: 6px; cursor: pointer; display: grid; place-items: center; padding: 0; }
.mafpr__dessins button:hover { border-color: #1c1a18; }
.mafpr__dessins button[aria-pressed="true"] { border-color: #1c1a18; background: #f3ead8; }
.mafpr__dessins button svg { width: 24px; height: 24px; }
.mafpr__dessins .mafpr__aucun { width: auto; padding: 0 10px; font-size: .8rem; color: #6b6259; }

/* aperçu : la feuille entière, à plat, avec une ombre légère */
.mafpr-vue { position: relative; width: 100%; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, .10), 0 10px 26px rgba(40, 30, 20, .16); }
.mafpr-vue__affiche { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }

/* sur la grande photo de la galerie, pendant la modification */
.mafpr-calque { position: absolute; inset: 0; z-index: 3; background: #f5f1eb; display: flex; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transition: opacity .25s ease, visibility .25s; }
.mafpr-calque.mafpr--visible { opacity: 1; visibility: visible; }
.mafpr-calque__feuille { width: 62%; }
.mafpr-calque__badge { position: absolute; left: 12px; top: 12px; z-index: 2; background: rgba(28, 26, 24, .82); color: #fff; font-size: 12px; letter-spacing: .02em; padding: 4px 9px; border-radius: 999px; }

/* mobile : l'aperçu se met au-dessus des champs pendant la modification */
.mafpr__apercu { display: none; margin: 0 auto 4px; width: 54%; }   /* largeur fixe : dans la grille, une marge auto donnait une largeur nulle */
@media (max-width: 991px) {
  .mafpr--edition .mafpr__apercu { display: block; }
}
.mafpr-galerie-seule .product-thumbs, .mafpr-galerie-seule .products-imagescover .slick-dots { display: none !important; }
.mafpr--envoi { opacity: .6; pointer-events: none; }

/* ordinateur : la photo (et l'aperçu) reste visible pendant qu'on descend dans les champs */
@media (min-width: 992px) {
  .mafpr-actif .page-content--product { position: sticky; top: 16px; }
}

/* 26/11/2026 (Sébastien) : fenêtre de validation avant le panier, pour un texte personnalisé */
.mafpr-valid { position: fixed; inset: 0; z-index: 2000; background: rgba(28, 26, 24, .55); display: flex; align-items: center; justify-content: center;
  padding: max(16px, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) max(16px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); }
.mafpr-valid__boite { background: #fff; width: 100%; max-width: 440px; max-height: 100%; overflow: auto; padding: 22px 22px 18px; text-align: center;
  box-shadow: 0 18px 50px rgba(28, 26, 24, .35); display: flex; flex-direction: column; align-items: center; }
.mafpr-valid__titre { font-weight: 600; font-size: 1.15rem; margin: 0; color: #1c1a18; }
.mafpr-valid__format { margin: 2px 0 14px; font-size: .85rem; color: #6b6259; }
.mafpr-valid__feuille { width: min(78%, calc((100vh - 290px) * .707)); min-width: 160px; }
.mafpr-valid__relire { margin: 16px 0 12px; font-size: .92rem; color: #1c1a18; }
.mafpr-valid__boite:focus { outline: none; }
.mafpr-valid__oui { width: 100%; padding: 13px 16px; font-weight: 500; }
.mafpr-valid .mafpr-valid__oui:focus { box-shadow: none; }
.mafpr-valid .mafpr-valid__oui:focus-visible { outline: 2px solid #1c1a18; outline-offset: 2px; }
.mafpr .mafpr-valid__non, .mafpr-valid .mafpr-valid__non { margin: 8px 0 0; }
.mafpr-valid .mafpr__ajout { border: 0; background: transparent; color: #85633a; font: inherit; font-weight: 500; font-size: .92rem; padding: 6px 0; cursor: pointer; }
.mafpr-valid .mafpr__ajout:hover { text-decoration: underline; }
.mafpr-valid__mention { margin: 10px 0 0; font-size: .75rem; color: #8a8077; line-height: 1.4; }
.mafpr-valid-ouverte { overflow: hidden; }
