/**
 * Sous-thème DolceVitaDog Noël (classe dvd-noel sur body).
 *
 * La boutique passe sur fond sapin, avec la palette du Menu de Noël. Le contenu
 * de chaque page est posé sur une feuille crème bordée d'or, entre l'en-tête et
 * la lettre. Hors saison, le module dolce_noel rend la main au thème DolceVitaDog.
 */

.dvd-noel {
  --noel-sapin: #17382e;
  --noel-sapin-c: #245443;
  --noel-sapin-f: #102a22;
  --noel-creme: #fbf4e6;
  --noel-or: #c9a24b;
  --noel-or-c: #e9d199;
  --noel-baie: #9c2a2f;
  --noel-baie-f: #7c1f24;
  --noel-gris: #665b50;
  --noel-conteneur: 100%;

  /* Le bleu nuit du site devient vert sapin. */
  --dvd-sage: #17382e;
  --dvd-sage-d: #102a22;
  --dvd-sage-l: #245443;
  --dvd-sage-wash: #e4ece4;
  --bs-primary: #17382e;

  background: var(--noel-sapin-f);
}
@media (min-width: 576px) { .dvd-noel { --noel-conteneur: 540px; } }
@media (min-width: 768px) { .dvd-noel { --noel-conteneur: 720px; } }
@media (min-width: 992px) { .dvd-noel { --noel-conteneur: 960px; } }
@media (min-width: 1200px) { .dvd-noel { --noel-conteneur: 1140px; } }
@media (min-width: 1400px) { .dvd-noel { --noel-conteneur: 1320px; } }

/* Le sapin et une neige fixe, discrète, derrière toute la page. */
.dvd-noel::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    radial-gradient(1.5px 1.5px at 30px 40px, rgba(255, 255, 255, .55) 60%, transparent 62%),
    radial-gradient(2px 2px at 120px 200px, rgba(255, 255, 255, .4) 60%, transparent 62%),
    radial-gradient(1.5px 1.5px at 210px 90px, rgba(255, 255, 255, .55) 60%, transparent 62%),
    radial-gradient(2.5px 2.5px at 280px 270px, rgba(255, 255, 255, .3) 60%, transparent 62%),
    radial-gradient(1.5px 1.5px at 75px 290px, rgba(255, 255, 255, .5) 60%, transparent 62%),
    radial-gradient(120% 70% at 50% 0, var(--noel-sapin-c) 0, var(--noel-sapin) 55%, var(--noel-sapin-f) 100%);
  background-size: 320px 320px, 320px 320px, 320px 320px, 320px 320px, 320px 320px, 100% 100%;
}

/* ==========================================================================
   En-tête
   ========================================================================== */
.dvd-noel .dvd-topbar { background: var(--noel-baie); }
.dvd-noel .dvd-header {
  background: rgba(16, 42, 34, .97);
  border-bottom-color: rgba(233, 209, 153, .25);
}
.dvd-noel .dvd-nav { border-top-color: rgba(233, 209, 153, .2); }

/* La guirlande pend sous l'en-tête, et se retire dès qu'on fait défiler. */
.dvd-noel .dvd-header::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  height: 96px;
  background: url(../images/lumieres-eteintes.svg) repeat-x left top, url(../images/guirlande.svg) repeat-x left top;
  pointer-events: none;
  transition: opacity .35s ease, transform .35s ease;
}
/* Les ampoules s'allument le soir (noel.js, de 17 h à 8 h chez le visiteur)
   et quand l'appareil est en mode sombre. */
.dvd-noel.noel-nuit .dvd-header::after {
  background-image: url(../images/lumieres-allumees.svg), url(../images/guirlande.svg);
}
@media (prefers-color-scheme: dark) {
  .dvd-noel .dvd-header::after {
    background-image: url(../images/lumieres-allumees.svg), url(../images/guirlande.svg);
  }
}
.dvd-noel.noel-defile .dvd-header::after {
  opacity: 0;
  transform: translateY(-12px);
}

/* Le logo garde ses couleurs, posé sur un médaillon crème. */
.dvd-noel .dvd-header .dvd-brand {
  position: relative;
  padding: 4px 14px;
  background: var(--noel-creme);
  border-radius: 999px;
  box-shadow: 0 0 0 1px var(--noel-or), 0 0 0 4px rgba(201, 162, 75, .18);
}
.dvd-noel .dvd-header .dvd-brand::after {
  content: '';
  position: absolute;
  right: -16px;
  top: -12px;
  width: 36px;
  height: 22px;
  background: url(../images/houx.svg) no-repeat center / contain;
  transform: rotate(18deg);
  pointer-events: none;
}
.dvd-noel .dvd-header .dvd-brand__logo { height: 48px; }

.dvd-noel .dvd-header__main .dvd-icon-btn,
.dvd-noel .dvd-header--minimal .dvd-checkout__back,
.dvd-noel .dvd-header--minimal .dvd-checkout__secure { color: var(--noel-creme); }
.dvd-noel .dvd-header__main .dvd-icon-btn:hover { background: rgba(251, 244, 230, .12); }
.dvd-noel .dvd-icon-btn__count { background: var(--noel-baie); }
.dvd-noel .dvd-burger__bar { background: var(--noel-creme); }

/* Sur ordinateur, le menu est sur le sapin. Sur téléphone, il s'ouvre sur du crème. */
@media (min-width: 768px) {
  .dvd-noel .dvd-navbar__link { color: var(--noel-creme); }
  .dvd-noel .dvd-navbar__link:hover,
  .dvd-noel .dvd-navbar__link:focus,
  .dvd-noel .dvd-navbar__link.show,
  .dvd-noel .dvd-navbar__item.is-active > .dvd-navbar__link,
  .dvd-noel .dvd-navbar__item.show > .dvd-navbar__link { color: var(--noel-or-c); }
  .dvd-noel .dvd-navbar__link:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--noel-or-c); }
}

/* ==========================================================================
   La feuille crème : tout ce qui est entre l'en-tête et la lettre
   ========================================================================== */
.dvd-noel .dialog-off-canvas-main-canvas > .dvd-header ~ :not(.region-newsletter-band, .dvd-footer, .dvd-wide--top:has(.noel-accueil), script, style) {
  position: relative;
  width: calc(100% - 48px);
  max-width: 1360px;
  margin-left: auto;
  margin-right: auto;
  background: var(--noel-creme);
  box-shadow: inset 1px 0 0 var(--noel-or), inset -1px 0 0 var(--noel-or);
  overflow-x: clip;
}
/* Une feuille qui est elle-même un conteneur aligne son texte sur les autres. */
.dvd-noel .dialog-off-canvas-main-canvas > .dvd-header ~ .container:not(.region-newsletter-band) {
  padding-left: max(12px, calc((100% - var(--noel-conteneur)) / 2 + 12px));
  padding-right: max(12px, calc((100% - var(--noel-conteneur)) / 2 + 12px));
}
/* Haut de la feuille, sous la guirlande. */
.dvd-noel .dialog-off-canvas-main-canvas > .dvd-header + *,
.dvd-noel .dialog-off-canvas-main-canvas > .dvd-wide--top:has(.noel-accueil) + * {
  margin-top: 72px;
  border-radius: 8px 8px 0 0;
  box-shadow: inset 1px 0 0 var(--noel-or), inset -1px 0 0 var(--noel-or), inset 0 1px 0 var(--noel-or);
}
/* Bas de la feuille (la commande n'a ni lettre ni pied de page). */
.dvd-noel .dialog-off-canvas-main-canvas > .dvd-header ~ :has(+ .region-newsletter-band),
.dvd-noel .dialog-off-canvas-main-canvas > .dvd-header ~ :not(.region-newsletter-band):has(+ .dvd-footer),
.dvd-noel .dialog-off-canvas-main-canvas > .dvd-header ~ :not(.region-newsletter-band, .dvd-footer):last-child {
  margin-bottom: 48px;
  padding-bottom: 32px;
  border-radius: 0 0 8px 8px;
  box-shadow: inset 1px 0 0 var(--noel-or), inset -1px 0 0 var(--noel-or), inset 0 -1px 0 var(--noel-or);
}
/* Le fil d'Ariane vide au-dessus de l'accueil de Noël n'a pas lieu d'être. */
.dvd-noel .dialog-off-canvas-main-canvas > .dvd-header ~ :has(~ .dvd-wide--top .noel-accueil) { display: none; }

/* Le Menu de Noël a déjà son propre sapin : pas de feuille sur sa page.
   Classe doublée pour passer devant la règle de la feuille. */
.dvd-noel.dvd-noel .dialog-off-canvas-main-canvas > .dvd-header ~ :has(.mn-app),
.dvd-noel.dvd-noel .dialog-off-canvas-main-canvas:has(.mn-app) > .dvd-header ~ :not(.region-newsletter-band, .dvd-footer) {
  width: 100%;
  max-width: none;
  background: transparent;
  box-shadow: none;
  border-radius: 0;
}
.dvd-noel .dialog-off-canvas-main-canvas:has(.mn-app) .main-content-wrap { max-width: none; }
.dvd-noel .mn-app { background: transparent; }
.dvd-noel .mn-app::before,
.dvd-noel .mn-app::after { display: none; }
.dvd-noel .mn-guirlande { display: none; }
/* Sa guirlande cachée, la place qu'elle gardait en haut de la page part avec elle.
   L'accueil du Menu descend d'autant pour que la toque de Rubis reste sous la nôtre. */
.dvd-noel .mn { padding-top: 18px; }
.dvd-noel .mn-debut { margin-top: 220px; }
@media (max-width: 820px) {
  .dvd-noel .mn { padding-top: 0; }
  .dvd-noel .mn-debut { margin-top: 192px; }
}

@media (max-width: 767.98px) {
  .dvd-noel .dialog-off-canvas-main-canvas > .dvd-header ~ :not(.region-newsletter-band, .dvd-footer, .dvd-wide--top:has(.noel-accueil), script, style) { width: calc(100% - 16px); }
  .dvd-noel .dialog-off-canvas-main-canvas > .dvd-header + *,
  .dvd-noel .dialog-off-canvas-main-canvas > .dvd-wide--top:has(.noel-accueil) + * { margin-top: 56px; }
  .dvd-noel .dvd-header::after { height: 72px; background-size: 315px 72px, 315px 72px; }
}

/* ==========================================================================
   Sections de la boutique
   ========================================================================== */
.dvd-noel .dvd-iconbox,
.dvd-noel .dvd-iconbox__row { background: var(--noel-sapin) !important; }
.dvd-noel .dvd-iconbox__icon { color: var(--noel-or-c); border-color: rgba(233, 209, 153, .4); }

/* Un brin de houx au-dessus des titres de section. */
.dvd-noel .dvd-bestsellers__head .dvd-eyebrow::after,
.dvd-noel .dvd-cat-rail-section .dvd-eyebrow::after {
  content: '';
  display: block;
  width: 56px;
  height: 34px;
  margin: 8px auto 0;
  background: url(../images/houx.svg) no-repeat center / contain;
}

/* Ruban « Idée cadeau » sur les cartes produit. */
.dvd-noel .dvd-product-card__ruban {
  position: absolute;
  z-index: 3;
  left: 0;
  bottom: 14px;
  height: 22px;
  padding: 0 6px 0 12px;
  line-height: 22px;
  background: var(--noel-baie);
  color: var(--noel-creme);
  font-family: var(--dvd-sans);
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  box-shadow: 0 2px 4px rgba(0, 0, 0, .18);
}
.dvd-noel .dvd-product-card__ruban::after {
  content: '';
  position: absolute;
  top: 0;
  right: -10px;
  border-style: solid;
  border-width: 11px 0 11px 10px;
  border-color: var(--noel-baie) transparent var(--noel-baie) var(--noel-baie);
}

/* La lettre en rouge baie, le pied de page dans le sapin. */
.dvd-noel .region-newsletter-band,
.dvd-noel .dvd-newsletter-section { background: transparent; }
.dvd-noel .dvd-newsletter {
  position: relative;
  background: var(--noel-baie);
  box-shadow: 0 18px 40px rgba(0, 0, 0, .3);
}
.dvd-noel .dvd-newsletter button,
.dvd-noel .dvd-newsletter .btn,
.dvd-noel .dvd-newsletter [type="submit"] {
  background: var(--noel-sapin);
  border-color: var(--noel-sapin);
}
.dvd-noel .dvd-footer { background: rgba(11, 31, 25, .92); }
.dvd-noel .dvd-footer h2,
.dvd-noel .dvd-footer h3,
.dvd-noel .dvd-footer h4,
.dvd-noel .dvd-footer .block-title { color: var(--noel-or-c); }

/* ==========================================================================
   Accueil de Noël
   ========================================================================== */
.dvd-noel .noel-accueil {
  padding: 120px 24px 72px;
  text-align: center;
  color: var(--noel-creme);
}
.noel-accueil__sur {
  font-size: .8125rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--noel-or-c);
}
.dvd-noel .noel-accueil__titre {
  margin: 12px 0 14px;
  font-family: var(--dvd-serif);
  font-size: clamp(2.6rem, 5vw, 4rem);
  font-weight: 400;
  line-height: 1.05;
  color: var(--noel-creme);
}
.noel-accueil__titre em { color: var(--noel-or-c); }
.noel-accueil__lead {
  max-width: 620px;
  margin: 0 auto 44px;
  font-size: 1.125rem;
  color: rgba(251, 244, 230, .86);
}
.noel-accueil__portes {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  max-width: 1240px;
  margin: 0 auto;
}
.noel-accueil__portes--2 { grid-template-columns: repeat(2, 1fr); max-width: 840px; }
.noel-accueil__portes--1 { grid-template-columns: 1fr; max-width: 420px; }

.noel-porte {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 14px 14px 28px;
  background: var(--noel-creme);
  color: var(--dvd-ink);
  border: 1px solid var(--noel-or);
  border-radius: 6px;
  box-shadow: inset 0 0 0 5px var(--noel-creme), inset 0 0 0 6px var(--noel-or), 0 18px 40px rgba(0, 0, 0, .35);
  text-decoration: none;
  transition: transform .25s ease, box-shadow .25s ease;
}
.noel-porte:hover {
  color: var(--dvd-ink);
  transform: translateY(-4px);
  box-shadow: inset 0 0 0 5px var(--noel-creme), inset 0 0 0 6px var(--noel-or), 0 24px 48px rgba(0, 0, 0, .42);
}
.noel-porte:focus-visible { outline: 2px solid var(--noel-or-c); outline-offset: 4px; }
.noel-houx {
  position: absolute;
  top: -30px;
  left: 50%;
  width: 100px;
  height: 60px;
  transform: translateX(-50%);
  background: url(../images/houx.svg) no-repeat center / contain;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, .25));
}
.noel-porte__image {
  display: block;
  width: 100%;
  height: 250px;
  margin-bottom: 20px;
  border-radius: 4px;
  background: var(--dvd-paper-2) center / cover no-repeat;
}
.noel-porte__image--rubis {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  overflow: hidden;
  background: radial-gradient(90% 80% at 50% 30%, var(--noel-sapin-c), var(--noel-sapin));
}
.noel-porte__image--rubis img { height: 96%; width: auto; max-width: 100%; object-fit: contain; object-position: bottom; }
.noel-porte__titre {
  margin-bottom: 6px;
  font-family: var(--dvd-serif);
  font-size: 1.75rem;
  line-height: 1.15;
  color: var(--noel-sapin);
}
.noel-porte__texte {
  flex: 1;
  margin: 0 12px 18px;
  font-size: .9375rem;
  color: var(--noel-gris);
}
.noel-porte__bouton {
  padding: 11px 22px;
  background: var(--noel-baie);
  color: var(--noel-creme);
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  transition: background .2s ease;
}
.noel-porte:hover .noel-porte__bouton { background: var(--noel-baie-f); }

/* Les budgets : sur le sapin à l'accueil, sur la feuille dans la page. */
.noel-budgets {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: center;
  margin: 46px auto 0;
}
.noel-budgets__label {
  margin-right: 4px;
  font-size: .875rem;
  letter-spacing: .06em;
  color: var(--noel-or-c);
}
.dvd-noel .noel-budgets__lien {
  padding: 10px 20px;
  border: 1px solid var(--noel-or-c);
  border-radius: 999px;
  color: var(--noel-creme);
  font-size: .875rem;
  text-decoration: none;
  transition: background .2s ease, color .2s ease;
}
.dvd-noel .noel-budgets__lien:hover { background: var(--noel-or-c); color: var(--noel-sapin); }
.noel-budgets--page { margin: 0 0 32px; justify-content: flex-start; }
.dvd-noel .noel-budgets--page .noel-budgets__lien { border-color: var(--noel-sapin); color: var(--noel-sapin); }
.dvd-noel .noel-budgets--page .noel-budgets__lien:hover,
.dvd-noel .noel-budgets--page .noel-budgets__lien.is-actif { background: var(--noel-sapin); color: var(--noel-creme); }

@media (max-width: 991.98px) {
  .noel-accueil__portes,
  .noel-accueil__portes--2 { grid-template-columns: 1fr; max-width: 460px; gap: 44px; }
}
@media (max-width: 767.98px) {
  .dvd-noel .noel-accueil { padding: 92px 16px 56px; }
  .noel-accueil__lead { font-size: 1rem; margin-bottom: 40px; }
  .noel-porte__image { height: 220px; }
}

/* ==========================================================================
   Idées cadeaux
   ========================================================================== */
.noel-idees { padding-bottom: 48px; }
.noel-idees__grille {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 28px 24px;
}
.noel-idees__vide { color: var(--noel-gris); }
@media (max-width: 575.98px) {
  .noel-idees__grille { grid-template-columns: repeat(2, 1fr); gap: 20px 12px; }
}

/* ==========================================================================
   Panier et commande
   ========================================================================== */
.dvd-noel .dvd-checkout-wrap { --dvd-sage-wash: #f6ecd4; }

/* Les étapes : une ficelle dorée, l'étape en cours en rouge baie. */
.dvd-noel .dvd-steps__list::before {
  height: 2px;
  background: repeating-linear-gradient(90deg, var(--noel-or) 0 8px, transparent 8px 14px);
}
/* La ficelle va du premier au dernier rond, quel que soit le nombre d'étapes. */
.dvd-noel .dvd-steps__list:has(> li:nth-child(3):last-child) { --dvd-steps-count: 3; }
.dvd-noel .dvd-steps__list:has(> li:nth-child(4):last-child) { --dvd-steps-count: 4; }
.dvd-noel .dvd-steps__list:has(> li:nth-child(5):last-child) { --dvd-steps-count: 5; }
.dvd-noel .dvd-steps__dot {
  background: var(--noel-creme);
  border-color: var(--noel-or-c);
  color: var(--noel-gris);
}
.dvd-noel .dvd-steps__item--previous .dvd-steps__dot {
  background: var(--noel-sapin);
  border-color: var(--noel-or);
  color: var(--noel-or-c);
}
.dvd-noel .dvd-steps__item--current .dvd-steps__dot {
  background: var(--noel-baie);
  border-color: var(--noel-or);
  color: var(--noel-creme);
  box-shadow: 0 0 0 4px rgba(201, 162, 75, .28);
}
.dvd-noel .dvd-steps__item--current .dvd-steps__label { color: var(--noel-baie); }

/* Un brin de houx dans le coin de chaque carte du formulaire. */
.dvd-noel .dvd-checkout-main .checkout-pane:not(.checkout-pane .checkout-pane),
.dvd-noel .dvd-checkout-main .dvd-review-pane {
  border-color: rgba(201, 162, 75, .45);
  background: #fff url(../images/houx.svg) no-repeat right 14px top 12px / 46px auto;
}
.dvd-noel .dvd-checkout-main .checkout-pane > legend,
.dvd-noel .dvd-checkout-main .checkout-pane > h3 { padding-right: 52px; }
.dvd-noel .dvd-checkout-main .checkout-pane-dolce-terms-pane {
  background-color: var(--dvd-sage-wash);
  border: 1px dashed var(--noel-or);
}

/* Le récapitulatif, emballé comme un cadeau : un ruban et son nœud. */
.dvd-noel .dvd-checkout-side .checkout-pane-order-summary {
  position: relative;
  margin-top: 34px;
  padding-top: 3rem;
  border-color: rgba(201, 162, 75, .45);
  overflow: visible;
}
.dvd-noel .dvd-checkout-side .checkout-pane-order-summary::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 14px;
  border-radius: 13px 13px 0 0;
  background: var(--noel-baie);
  box-shadow: inset 0 -2px 0 var(--noel-baie-f), inset 0 2px 0 rgba(233, 209, 153, .5);
}
.dvd-noel .dvd-checkout-side .checkout-pane-order-summary::after {
  content: '';
  position: absolute;
  top: -30px;
  left: 50%;
  width: 104px;
  height: 65px;
  margin-left: -52px;
  background: url(../images/noeud.svg) no-repeat center / contain;
  pointer-events: none;
}
.dvd-noel .view-commerce-checkout-order-summary .view-footer .order-total-line__total {
  background: var(--noel-sapin);
  box-shadow: inset 0 2px 0 var(--noel-or);
}
.dvd-noel .view-commerce-checkout-order-summary .view-footer .order-total-line__total .order-total-line-value { color: var(--noel-or-c); }

/* Le bouton qui fait avancer la commande passe en rouge baie. */
.dvd-noel .dvd-checkout-actions .button--primary,
.dvd-noel .dvd-checkout-actions .btn-primary,
.dvd-noel .cart-form [id^=edit-checkout] {
  /* Le thème DolceVitaDog impose le vert aux boutons du tunnel avec !important. */
  background: var(--noel-baie) !important;
  border-color: var(--noel-baie) !important;
  color: var(--noel-creme) !important;
  box-shadow: inset 0 0 0 1px rgba(233, 209, 153, .55);
}
.dvd-noel .dvd-checkout-actions .button--primary:hover,
.dvd-noel .dvd-checkout-actions .btn-primary:hover,
.dvd-noel .cart-form [id^=edit-checkout]:hover {
  background: var(--noel-baie-f) !important;
  border-color: var(--noel-baie-f) !important;
}
