/* Noël à l'encre (src/noel.php) : laque vermillon, or, encre ; chargé seulement pendant la période de Noël. */
:root { --laque-nuit: #2A0907; --laque-fonce: #5A1510; --laque: #8A2620; --laque-vive: #B5382B; --or-clair: #F6DDB1; --or-n: #E9B783; --or-fonce: #A9773F; --kraft: #EFDDBB; }

/* ---------- le ruban d'or, en tête de toutes les pages ---------- */
.noel-ruban { position: relative; overflow: hidden; color: #FBEEDB; font-size: .92rem; line-height: 1.35;
  background: linear-gradient(90deg, var(--laque-fonce), var(--laque) 50%, var(--laque-fonce));
  box-shadow: inset 0 1px 0 rgba(246,221,177,.35), inset 0 -1px 0 rgba(246,221,177,.55); }
.noel-ruban::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(105deg, transparent 0 38%, rgba(246,221,177,.22) 47%, rgba(255,240,210,.38) 50%, rgba(246,221,177,.22) 53%, transparent 62% 100%);
  transform: translateX(-100%); animation: noel-reflet 7s ease-in-out 1.2s infinite; }
@keyframes noel-reflet { 0% { transform: translateX(-100%); } 45%, 100% { transform: translateX(100%); } }
.noel-ruban__dedans { display: flex; align-items: center; justify-content: center; gap: 10px 16px; flex-wrap: wrap; padding-block: 7px; position: relative; z-index: 1; }
.noel-ruban__sceau { display: inline-grid; place-items: center; width: 26px; height: 26px; flex: none; font: 600 .62rem/1 var(--zh); writing-mode: vertical-rl; letter-spacing: -.05em;
  color: #FFF4E4; background: var(--laque-vive); border: 1px solid var(--or-n); border-radius: 2px; box-shadow: 0 0 0 2px rgba(42,9,7,.35); }
.noel-ruban__texte { margin: 0; text-align: center; }
.noel-ruban__texte b { color: var(--or-clair); font-weight: 650; }
.noel-ruban__reste { color: var(--or-n); }
.noel-ruban__lien { color: var(--laque-nuit); background: linear-gradient(180deg, var(--or-clair), var(--or-n)); padding: 3px 12px; border-radius: 999px; font-weight: 650; text-decoration: none; white-space: nowrap;
  box-shadow: 0 1px 0 rgba(255,255,255,.4) inset, 0 2px 6px -2px rgba(0,0,0,.45); }
.noel-ruban__lien:hover { color: var(--laque-nuit); filter: brightness(1.06); }

/* ---------- la vitrine de l'accueil ---------- */
.noel-vitrine { position: relative; overflow: hidden; isolation: isolate; color: #FBEEDB;
  background:
    radial-gradient(ellipse 46% 62% at 27% 48%, rgba(255,198,140,.22) 0%, transparent 60%),
    radial-gradient(ellipse 85% 120% at 30% 40%, var(--laque-vive) 0%, var(--laque) 34%, var(--laque-fonce) 66%, var(--laque-nuit) 100%); }
/* frise d'or 回 en haut et en bas */
.noel-vitrine::before, .noel-vitrine::after { content: ""; position: absolute; left: 0; right: 0; height: 16px; z-index: 3; pointer-events: none; opacity: .9;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='16' viewBox='0 0 32 16'%3E%3Cpath d='M0 14.5H5V1.5H15V11H9V6H12M16 14.5H21V1.5H31V11H25V6H28' fill='none' stroke='%23E9B783' stroke-width='1.6'/%3E%3C/svg%3E") repeat-x 0 50% / 32px 16px,
    linear-gradient(var(--laque-nuit), var(--laque-nuit)); }
.noel-vitrine::before { top: 0; box-shadow: 0 1px 0 rgba(233,183,131,.6); }
.noel-vitrine::after { bottom: 0; box-shadow: 0 -1px 0 rgba(233,183,131,.6); transform: scaleY(-1); }
/* laque : un reflet en diagonale et un grain très léger */
.noel-vitrine__grille::before { content: ""; position: absolute; inset: -40% -10%; z-index: -1; pointer-events: none;
  background: linear-gradient(115deg, transparent 30%, rgba(255,230,200,.07) 42%, transparent 52%), repeating-linear-gradient(0deg, rgba(255,255,255,.012) 0 2px, transparent 2px 5px); }
.noel-neige { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; pointer-events: none; }
.noel-monts { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: clamp(90px, 13vw, 190px); z-index: 0; pointer-events: none; }
.noel-vitrine__grille { position: relative; z-index: 2; display: grid; grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr); align-items: center; gap: clamp(24px, 4.5vw, 72px);
  padding-block: clamp(36px, 4vw, 56px) clamp(48px, 5vw, 70px); }

/* l'écrin : la boîte laquée noire nouée d'or, d'où sort le rouleau */
.noel-ecrin { --boite-l: clamp(220px, min(21vw, 36vh), 310px); --boite-h: calc(var(--boite-l) * .58); position: relative; height: clamp(430px, min(42vw, 70vh), 600px); }
.noel-ecrin__halo { position: absolute; left: 50%; top: 42%; width: 120%; aspect-ratio: 1; transform: translate(-50%, -50%); pointer-events: none;
  background: radial-gradient(circle, rgba(255,214,160,.33) 0%, rgba(255,214,160,.10) 34%, transparent 62%); animation: noel-halo 5s ease-in-out infinite; }
@keyframes noel-halo { 50% { opacity: .65; transform: translate(-50%, -50%) scale(.94); } }
.noel-ecrin__fenetre { position: absolute; left: 0; right: 0; top: 0; bottom: calc(var(--boite-h) * .82 + 4%); display: flex; justify-content: center; align-items: flex-end; overflow: hidden; }
.noel-ecrin__rouleau { position: relative; display: block; width: min(calc(var(--boite-l) * .78), 64%); aspect-ratio: 2 / 3; transform: translateY(102%);
  transition: transform 1.7s cubic-bezier(.2, .8, .16, 1) 1.05s; box-shadow: 0 40px 60px -26px rgba(20,4,2,.85), 0 0 0 1px rgba(255,235,205,.18); background: #BBA17D; }
.noel-ecrin__image, .noel-ecrin__dessin, .noel-ecrin__dessin svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.noel-ecrin__image { object-fit: cover; transition: opacity .5s ease; }
.noel-ecrin--trace .noel-ecrin__image { opacity: 0; }
.noel-ecrin--fini .noel-ecrin__image { opacity: 1; transition-duration: 1.2s; }
.noel-ecrin__rouleau:hover { box-shadow: 0 46px 70px -26px rgba(20,4,2,.9), 0 0 0 2px var(--or-n); }

.noel-boite { position: absolute; left: 50%; bottom: 4%; width: var(--boite-l); height: var(--boite-h); transform: translateX(-50%); cursor: pointer; animation: noel-flotte 6s ease-in-out infinite; }
@keyframes noel-flotte { 50% { transform: translate(-50%, -5px); } }
.noel-boite__corps, .noel-boite__couvercle { position: absolute; display: block; overflow: hidden; border-radius: 3px;
  background: linear-gradient(180deg, #2E2A26 0%, #151210 55%, #0B0908 100%); box-shadow: inset 0 0 0 1px rgba(233,183,131,.55), inset 0 0 0 4px #0B0908, inset 0 0 0 5px rgba(233,183,131,.25); }
.noel-boite__corps { left: 0; right: 0; top: 18%; bottom: 0; box-shadow: inset 0 0 0 1px rgba(233,183,131,.55), inset 0 0 0 4px #0B0908, inset 0 0 0 5px rgba(233,183,131,.25), 0 34px 50px -20px rgba(15,3,2,.9); }
.noel-boite__corps::after { content: ""; position: absolute; inset: 0; background: linear-gradient(112deg, transparent 20%, rgba(255,240,220,.10) 32%, transparent 44%); }
.noel-boite__couvercle { left: -4%; right: -4%; top: 0; height: 26%; z-index: 2; background: linear-gradient(180deg, #3A3530, #1A1714); transform-origin: 20% 100%;
  transition: transform 1.1s cubic-bezier(.5, -.2, .3, 1) .55s, opacity .6s ease 1.15s; }
.noel-boite__ruban-v, .noel-boite__ruban-h { position: absolute; display: block; background: linear-gradient(90deg, var(--or-fonce), var(--or-clair) 45%, var(--or-n) 60%, var(--or-fonce)); }
.noel-boite__ruban-v { top: 0; bottom: 0; left: 50%; width: 12%; transform: translateX(-50%); }
.noel-boite__ruban-h { left: 0; right: 0; top: 46%; height: 13%; background: linear-gradient(180deg, var(--or-fonce), var(--or-clair) 45%, var(--or-n) 60%, var(--or-fonce)); }
.noel-boite__marque { position: absolute; right: 7%; bottom: 10%; z-index: 1; display: grid; place-items: center; width: 15%; aspect-ratio: 1; font: 400 clamp(.55rem, .9vw, .8rem)/.95 var(--zh);
  writing-mode: vertical-rl; color: var(--or-n); border: 1px solid var(--or-n); border-radius: 2px; }
/* le nœud */
.noel-noeud { position: absolute; left: 50%; top: -14%; width: 44%; height: 40%; transform: translateX(-50%); z-index: 3; }
.noel-noeud i { position: absolute; display: block; background: linear-gradient(135deg, var(--or-clair), var(--or-n) 45%, var(--or-fonce)); transition: transform .7s cubic-bezier(.5, 0, .7, .2), opacity .5s ease; }
.noel-noeud__boucle { top: 6%; width: 46%; height: 62%; border-radius: 50% 50% 46% 46% / 64% 64% 36% 36%; box-shadow: inset 0 -6px 10px -4px rgba(90,50,10,.55); }
.noel-noeud__boucle::after { content: ""; position: absolute; inset: 24% 26%; border-radius: inherit; background: rgba(60,30,8,.35); }
.noel-noeud__boucle--g { left: 4%; transform: rotate(-24deg); transform-origin: 100% 100%; }
.noel-noeud__boucle--d { right: 4%; transform: rotate(24deg); transform-origin: 0 100%; }
.noel-noeud__pan { top: 58%; width: 13%; height: 70%; clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 82%, 0 100%); }
.noel-noeud__pan--g { left: 36%; transform: rotate(16deg); transform-origin: 50% 0; }
.noel-noeud__pan--d { right: 36%; transform: rotate(-16deg); transform-origin: 50% 0; }
.noel-noeud__coeur { left: 50%; top: 42%; width: 17%; height: 30%; transform: translate(-50%, 0); border-radius: 5px; box-shadow: 0 2px 4px rgba(60,30,8,.5); }
.noel-boite:hover .noel-noeud__boucle--g { transform: rotate(-30deg); }
.noel-boite:hover .noel-noeud__boucle--d { transform: rotate(30deg); }

/* l'ouverture : le nœud se défait, le couvercle s'envole, le rouleau monte */
.noel-ecrin--ouvert .noel-noeud__boucle--g { transform: rotate(-80deg) scale(0); opacity: 0; }
.noel-ecrin--ouvert .noel-noeud__boucle--d { transform: rotate(80deg) scale(0); opacity: 0; }
.noel-ecrin--ouvert .noel-noeud__coeur { transform: translate(-50%, 0) scale(0); opacity: 0; }
.noel-ecrin--ouvert .noel-noeud__pan--g { transform: translate(-60px, 120px) rotate(70deg); opacity: 0; transition-delay: .25s; }
.noel-ecrin--ouvert .noel-noeud__pan--d { transform: translate(60px, 120px) rotate(-70deg); opacity: 0; transition-delay: .25s; }
.noel-ecrin--ouvert .noel-boite__couvercle { transform: translate(-46%, -150%) rotate(-24deg); opacity: 0; }
.noel-ecrin--ouvert .noel-boite__corps > .noel-boite__ruban-v { animation: noel-ruban-tombe .6s ease .2s both; }
@keyframes noel-ruban-tombe { to { transform: translate(-50%, 110%); } }
.noel-ecrin--ouvert .noel-boite__ruban-h { animation: noel-ruban-glisse .7s ease .3s both; }
@keyframes noel-ruban-glisse { to { transform: scaleX(0); opacity: 0; } }
.noel-ecrin--ouvert .noel-ecrin__rouleau { transform: translateY(0); }
/* la lumière qui s'échappe de la boîte ouverte */
.noel-boite::after { content: ""; position: absolute; left: 4%; right: 4%; top: -6%; height: 42%; z-index: 3; pointer-events: none; opacity: 0; filter: blur(5px);
  background: radial-gradient(ellipse 50% 70% at 50% 62%, rgba(255,222,160,.75), rgba(255,200,130,.25) 50%, transparent 75%); transition: opacity 1.4s ease 1s; }
.noel-ecrin--ouvert .noel-boite::after { opacity: 1; }
.noel-ecrin--ouvert .noel-boite { animation: none; }

/* l'étiquette cadeau, en papier kraft, au bout d'un fil d'or */
.noel-etiquette { position: absolute; right: max(0px, calc(50% - var(--boite-l) * .95)); bottom: calc(var(--boite-h) * .55); z-index: 4; display: grid; justify-items: center; gap: 1px;
  width: clamp(118px, 11vw, 150px); padding: 18px 10px 12px; text-align: center; text-decoration: none; color: #2B1C10;
  background: linear-gradient(160deg, #F5E6C8, var(--kraft) 60%, #E3CDA4); border-radius: 4px 4px 4px 4px;
  clip-path: polygon(14% 0, 86% 0, 100% 12%, 100% 100%, 0 100%, 0 12%); box-shadow: 0 16px 28px -14px rgba(20,4,2,.8);
  transform-origin: 50% -40px; opacity: 0; transform: rotate(-40deg) translateY(-30px); pointer-events: none; }
.noel-etiquette::before { content: ""; position: absolute; top: 7px; left: 50%; width: 9px; height: 9px; transform: translateX(-50%); border-radius: 50%; background: var(--laque-fonce); box-shadow: inset 0 0 0 2px var(--or-n); }
.noel-etiquette__fil { position: absolute; top: -40px; left: 50%; width: 1.5px; height: 46px; background: linear-gradient(var(--or-fonce), var(--or-clair)); }
.noel-etiquette__zh { font: 400 1.35rem/1.1 var(--zh); color: var(--laque); letter-spacing: .02em; }
.noel-etiquette b { font: 600 .98rem/1.1 var(--titre); }
.noel-etiquette small { font-size: .72rem; color: #5E4A33; line-height: 1.25; }
.noel-etiquette:hover { color: #2B1C10; }
.noel-ecrin--fini .noel-etiquette { opacity: 1; pointer-events: auto; animation: noel-balance 2.6s cubic-bezier(.3, .2, .2, 1) both; }
@keyframes noel-balance { 0% { opacity: 0; transform: rotate(-40deg) translateY(-30px); } 18% { opacity: 1; transform: rotate(16deg); } 38% { transform: rotate(-9deg); } 56% { transform: rotate(5deg); } 74% { transform: rotate(-2deg); } 100% { opacity: 1; transform: rotate(-3deg); } }

/* ---------- le texte, le sceau des jours, le choix « Pour qui ? » ---------- */
.noel-vitrine__surtitre { color: var(--or-n) !important; letter-spacing: .14em; }
.noel-vitrine__surtitre span { font-family: var(--zh); letter-spacing: .1em; }
.noel-vitrine h2 { color: #FFF8EE; font-size: clamp(2.1rem, 3.6vw, 3.5rem); line-height: .98; letter-spacing: -.03em; margin: .15em 0 .35em; text-shadow: 0 2px 30px rgba(42,9,7,.5); }
.noel-vitrine h2 em { font-style: italic; color: var(--or-clair); }
.noel-vitrine__chapo { max-width: 52ch; font-size: 1.06rem; color: rgba(251,238,219,.88); }
.noel-vitrine__texte, .noel-ecrin { min-width: 0; }
.noel-sceau { margin: 18px 0 22px; }
.noel-sceau__bloc { display: flex; align-items: center; gap: 16px; }
.noel-sceau__bloc[hidden] { display: none; }
.noel-sceau__cachet { position: relative; display: grid; place-items: center; align-content: center; width: 86px; height: 86px; flex: none; color: #FFF6EA; background: var(--laque-vive);
  border-radius: 4px; box-shadow: inset 0 0 0 3px var(--laque-vive), inset 0 0 0 4.5px rgba(255,246,234,.85), 0 10px 22px -10px rgba(20,4,2,.8); transform: rotate(-3deg);
  animation: noel-tampon .7s cubic-bezier(.2, 1.6, .4, 1) .3s both; }
.noel-sceau__cachet::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: .35;
  background: radial-gradient(circle at 30% 70%, transparent 0 3px, rgba(0,0,0,.25) 3px 4px, transparent 4px) 0 0 / 13px 11px; mix-blend-mode: multiply; }
@keyframes noel-tampon { 0% { transform: scale(1.8) rotate(-12deg); opacity: 0; } 100% { transform: scale(1) rotate(-3deg); opacity: 1; } }
.noel-sceau__cachet small { font: 600 .7rem/1 var(--texte); letter-spacing: .12em; opacity: .9; }
.noel-sceau__cachet b { font: 600 2.4rem/1 var(--titre); font-variant-numeric: lining-nums; }
.noel-sceau__cachet b[lang] { font: 400 2.6rem/1 var(--zh); }
.noel-sceau__texte { margin: 0; max-width: 40ch; color: rgba(251,238,219,.9); }
.noel-sceau__texte strong { color: #FFF8EE; display: block; font: 600 1.15rem/1.2 var(--titre); }
.noel-sceau__texte b { color: var(--or-clair); }
.noel-sceau__reste { display: block; color: var(--or-n); font-size: .9rem; margin-top: 2px; }

.noel-choix__question { margin: 0 0 10px; font: 600 1.15rem/1.2 var(--titre); color: #FFF8EE; }
.noel-choix__puces { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.noel-puce { appearance: none; cursor: pointer; padding: 7px 14px; border-radius: 999px; font-size: .92rem; line-height: 1.2; color: #FBEEDB; text-decoration: none;
  background: rgba(42,9,7,.32); border: 1px solid rgba(233,183,131,.55); transition: background .2s, color .2s, transform .2s, box-shadow .2s; }
.noel-puce:hover { color: #FFF8EE; background: rgba(42,9,7,.5); transform: translateY(-1px); }
.noel-puce[aria-pressed="true"] { color: var(--laque-nuit); background: linear-gradient(180deg, var(--or-clair), var(--or-n)); border-color: var(--or-clair); box-shadow: 0 6px 16px -8px rgba(233,183,131,.9); font-weight: 650; }
.noel-puce--lien { border-style: dashed; }
.noel-puce:focus-visible { outline: 2px solid var(--or-clair); outline-offset: 2px; }
.noel-idees { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(10px, 1.4vw, 18px); }
.noel-idees[hidden] { display: none; }
.noel-carte { --i: 0; display: grid; gap: 2px; padding: 9px 9px 12px; text-decoration: none; color: var(--encre); background: #FFFCF6; border-radius: 3px;
  box-shadow: 0 18px 30px -18px rgba(20,4,2,.9), inset 0 0 0 1px rgba(169,119,63,.25); transition: transform .25s ease, box-shadow .25s ease;
  animation: noel-carte .6s cubic-bezier(.2, .9, .3, 1.2) calc(var(--i) * 90ms) both; }
@keyframes noel-carte { from { opacity: 0; transform: translateY(18px) rotate(-2deg) scale(.96); } }
.noel-carte:hover { color: var(--encre); transform: translateY(-4px) rotate(-.6deg); box-shadow: 0 26px 36px -18px rgba(20,4,2,.95), 0 0 0 2px var(--or-n); }
.noel-carte__image { display: block; aspect-ratio: 5 / 4; overflow: hidden; background: var(--mur, #E9E1D2); margin-bottom: 6px; }
.noel-carte__image img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.noel-carte:hover .noel-carte__image img { transform: scale(1.05); }
.noel-carte__zh { font: 400 1.5rem/1.05 var(--zh); color: var(--laque); }
.noel-carte__nom { font: 600 1rem/1.15 var(--titre); }
.noel-carte__prix { font-size: .8rem; color: #5E574D; }
.noel-vitrine__liens { display: flex; flex-wrap: wrap; gap: 8px 22px; align-items: center; margin: 20px 0 0; }
.noel-vitrine__liens a { color: var(--or-clair); }
.noel-vitrine__liens a:hover { color: #FFF8EE; }
.noel-vitrine__liens svg { width: 1em; height: 1em; vertical-align: -2px; }

/* ---------- petits écrans ---------- */
@media (max-width: 900px) {
  .noel-vitrine__grille { grid-template-columns: minmax(0, 1fr); gap: 6px; padding-top: 34px; }
  .noel-ecrin { --boite-l: min(62vw, 270px); height: min(122vw, 500px); }
  .noel-etiquette { right: 2%; }
  .noel-vitrine__texte { text-align: left; }
  .noel-idees { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: minmax(150px, 44%); overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 6px; margin-inline: -4px; padding-inline: 4px; }
  .noel-carte { scroll-snap-align: start; }
}
@media (max-width: 560px) {
  .noel-ruban { font-size: .84rem; }
  .noel-ruban__sceau { display: none; }
  .noel-ruban__dedans { gap: 6px 10px; }
  .noel-sceau__cachet { width: 72px; height: 72px; }
  .noel-sceau__cachet b { font-size: 2rem; }
}

/* ---------- mouvement réduit : tout est déjà ouvert ---------- */
@media (prefers-reduced-motion: reduce) {
  .noel-ruban::after, .noel-ecrin__halo, .noel-boite { animation: none; }
  .noel-ecrin__rouleau { transform: none; transition: none; }
  .noel-boite__couvercle, .noel-noeud { display: none; }
  .noel-etiquette { opacity: 1; transform: rotate(-3deg); pointer-events: auto; animation: none !important; }
  .noel-sceau__cachet, .noel-carte { animation: none; }
}
