/* =====================================================================
   Mode Noël (Administration → Apparence → Mode Noël, plugin guillac lib/noel.php)
   Bonnet sur le logo, guirlande sous le menu, traîneau à la place du kart du panier, sapins dans quelques blocs,
   flocons (noel.js). Les couleurs du site ne changent pas.
   Tout est rattaché à html.noel : désactiver le mode suffit à tout retirer.
   ===================================================================== */

/* Bonnet de Noël posé sur le « G » du logo */
html.noel .brand{position:relative}
html.noel .brand::before{content:"";position:absolute;z-index:1;left:-12px;top:-5px;width:38px;height:32px;pointer-events:none;
  transform:rotate(-20deg);transform-origin:50% 100%;
  background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 76 64'%3E%3Cpath d='M10 48C14 30 26 12 44 8c10-2 18 3 22 12 2 5 1 12-2 16-1-6-5-11-10-11-8 0-12 9-14 23z' fill='%23c4202b'/%3E%3Cpath d='M44 8c10-2 18 3 22 12 2 5 1 12-2 16-1-6-5-11-10-11-3 0-6 2-8 5 2-9 1-17-2-22z' fill='%239c1720'/%3E%3Crect x='3' y='44' width='48' height='14' rx='7' fill='%23fff' stroke='%23d9dee0' stroke-width='1.5'/%3E%3Ccircle cx='64' cy='40' r='8' fill='%23fff' stroke='%23d9dee0' stroke-width='1.5'/%3E%3C/svg%3E") no-repeat center/contain}
@media (max-width:760px){html.noel .brand::before{left:-9px;top:-7px;width:24px;height:20px}}

/* Panier : le kart devient un traîneau (l'image d'origine est sortie du cadre, ses animations restent) */
html.noel .cart-kart img{object-position:-9999px 0;background:url("img/noel-traineau.svg") no-repeat center/contain}

/* Sapins enneigés posés en bas de quelques blocs (insérés par noel.js : bandeau d'accueil, appel à l'action, pied de page) */
.noel-trees{position:absolute;z-index:1;right:clamp(12px,4vw,56px);bottom:0;width:clamp(110px,14vw,190px);aspect-ratio:212/120;pointer-events:none;
  background:url("img/noel-sapins.svg") no-repeat bottom/contain}
.noel-trees.left{right:auto;left:clamp(12px,4vw,56px)}
.foot{position:relative}
@media (max-width:760px){.noel-trees{width:96px}html.noel .foot-legal{padding-bottom:60px}}

/* Guirlande lumineuse sous l'en-tête : fil en festons, une ampoule au creux de chaque feston (38 px) */
.noel-garland{position:absolute;left:0;right:0;top:100%;height:20px;display:flex;overflow:hidden;pointer-events:none;padding-left:15px;
  background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='38' height='10'%3E%3Cpath d='M0 1Q19 9 38 1' fill='none' stroke='%232b3a36' stroke-width='1.2'/%3E%3C/svg%3E") repeat-x 0 0}
.noel-garland i{flex:none;width:8px;height:12px;margin:4px 30px 0 0;border-radius:50% 50% 50% 50%/40% 40% 60% 60%;background:#d8312c;
  border-top:3px solid #2b3a36;animation:noel-twinkle 2.4s ease-in-out infinite}
.noel-garland i:nth-child(4n+2){background:#1f8a4c;animation-delay:.6s}
.noel-garland i:nth-child(4n+3){background:#e8b21c;animation-delay:1.2s}
.noel-garland i:nth-child(4n+4){background:#2f6fd0;animation-delay:1.8s}
@keyframes noel-twinkle{50%{opacity:.45}}

/* Bouton flocon (coin bas gauche, flotte au-dessus de la page) : arrêter ou relancer la neige */
.noel-snow-btn{position:fixed;left:16px;bottom:16px;z-index:30;display:grid;place-items:center;width:44px;height:44px;padding:0;
  border:1px solid var(--line);border-radius:4px;background:var(--white,#fff);color:var(--plate);cursor:pointer}
.noel-snow-btn:hover{color:var(--red);border-color:currentColor}
.noel-snow-btn[aria-pressed=false]{color:var(--muted)}
.noel-snow-btn svg{width:18px;height:18px}
.noel-snow-btn[aria-pressed=false] .noel-off{display:block}
.noel-off{display:none}

/* Calque des flocons : au-dessus du contenu, sous l'en-tête, jamais cliquable */
.noel-snow{position:fixed;inset:0;width:100%;height:100%;z-index:15;pointer-events:none}

@media (prefers-reduced-motion:reduce){
  .noel-garland i{animation:none}
  .noel-snow,.noel-snow-btn{display:none}
}
@media print{.noel-trees,.noel-garland,.noel-snow,.noel-snow-btn,html.noel .brand::before{display:none}}
