:root {
  --night-1: #050c1d;
  --night-2: #0b1f3f;
  --night-3: #16335f;
  --gold: #f3c64f;
  --gold-deep: #c8902b;
  --cream: #fffaf0;
  --ink: #2a1f1a;
  --ink-soft: #6b5d52;
  --red: #c41e2f;
  --green: #17603c;
  --script: 'Great Vibes', cursive;
  --serif: Fraunces, Georgia, serif;
  --sans: Inter, system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { color-scheme: dark; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--night-1);
  color: #eef2fb;
  font: 16px/1.55 var(--sans);
  overflow-x: hidden;
}

/* ---------- Ciel ---------- */
.sky {
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(120% 70% at 50% 0%, var(--night-3) 0%, var(--night-2) 45%, var(--night-1) 100%);
}
.stars {
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(1px 1px at 20px 30px, #fff, transparent),
    radial-gradient(1px 1px at 140px 90px, #dfe8ff, transparent),
    radial-gradient(1.5px 1.5px at 60px 170px, #fff, transparent),
    radial-gradient(1px 1px at 210px 220px, #fff, transparent),
    radial-gradient(1px 1px at 260px 40px, #cfe0ff, transparent),
    radial-gradient(1.5px 1.5px at 320px 140px, #fff, transparent);
  background-size: 340px 260px;
  opacity: .55;
  mask-image: linear-gradient(to bottom, #000 0%, #000 50%, transparent 85%);
}
.stars--twinkle {
  background-size: 470px 380px;
  background-position: 120px 60px;
  animation: twinkle 4s ease-in-out infinite alternate;
}
@keyframes twinkle { from { opacity: .15; } to { opacity: .8; } }

.aurora {
  position: absolute;
  inset: -20% -10% auto;
  height: 70%;
  background:
    radial-gradient(40% 50% at 25% 40%, rgba(62, 224, 143, .18), transparent 70%),
    radial-gradient(35% 45% at 70% 30%, rgba(79, 179, 255, .16), transparent 70%),
    radial-gradient(30% 40% at 50% 55%, rgba(255, 123, 213, .08), transparent 70%);
  filter: blur(30px);
  animation: aurora 18s ease-in-out infinite alternate;
}
@keyframes aurora {
  from { transform: translateX(-4%) skewX(-4deg); }
  to   { transform: translateX(4%) skewX(4deg); }
}

.moon {
  position: absolute;
  top: 200px;
  right: 4%;
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fffdf3, #f1e7c8 60%, #d9cba2);
  box-shadow: 0 0 40px 10px rgba(255, 246, 214, .25), 0 0 120px 40px rgba(255, 246, 214, .1);
}
.moon::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background:
    radial-gradient(circle at 62% 58%, rgba(170, 155, 115, .35) 0 9px, transparent 10px),
    radial-gradient(circle at 40% 70%, rgba(170, 155, 115, .25) 0 6px, transparent 7px),
    radial-gradient(circle at 55% 30%, rgba(170, 155, 115, .25) 0 5px, transparent 6px);
}

#snow {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 5;
}

/* ---------- Guirlande ---------- */
.lights {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 60px;
  z-index: 4;
  overflow: hidden;
  pointer-events: none;
}
.lights svg { position: absolute; top: 0; left: 0; }
.bulb {
  position: absolute;
  width: 12px;
  height: 20px;
  margin-left: -6px;
  transform: rotate(var(--r));
  transform-origin: 50% 0;
}
.bulb::before {
  content: '';
  position: absolute;
  top: 0;
  left: 3px;
  width: 6px;
  height: 6px;
  border-radius: 1px;
  background: #3b4a40;
}
.bulb::after {
  content: '';
  position: absolute;
  top: 5px;
  left: 0;
  width: 12px;
  height: 16px;
  border-radius: 50% 50% 50% 50% / 40% 40% 60% 60%;
  background: radial-gradient(circle at 40% 35%, #fff 0 2px, var(--c) 5px);
  box-shadow: 0 0 10px 3px var(--c), 0 0 24px 6px color-mix(in srgb, var(--c) 45%, transparent);
  animation: glow 2.4s ease-in-out infinite;
  animation-delay: var(--d);
}
@keyframes glow {
  0%, 100% { opacity: 1; filter: brightness(1.1); }
  50% { opacity: .45; filter: brightness(.7); box-shadow: 0 0 4px 1px var(--c); }
}

/* ---------- En-tête ---------- */
.hero {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 120px 16px 40px;
  text-align: center;
}
.baubles { position: absolute; inset: 0 0 auto; height: 0; pointer-events: none; }
.bauble {
  position: absolute;
  top: 0;
  left: var(--x);
  width: 2px;
  height: var(--len);
  background: linear-gradient(#c9b27a, #f3e3b0);
  transform-origin: 50% 0;
  animation: swing 5s ease-in-out infinite;
  animation-delay: var(--d);
}
.bauble::before {
  /* attache */
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  width: calc(var(--s) * .32);
  height: calc(var(--s) * .22);
  transform: translateX(-50%);
  border-radius: 3px 3px 1px 1px;
  background: linear-gradient(90deg, #a07c32, #f6dc8c, #a07c32);
}
.bauble::after {
  content: '';
  position: absolute;
  top: calc(100% + var(--s) * .18);
  left: 50%;
  width: var(--s);
  height: var(--s);
  transform: translateX(-50%);
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 28%, rgba(255, 255, 255, .85) 0 8%, rgba(255, 255, 255, 0) 22%),
    radial-gradient(circle at 50% 50%, transparent 55%, rgba(0, 0, 0, .35) 100%),
    var(--c);
  box-shadow: 0 0 22px color-mix(in srgb, var(--c) 55%, transparent);
}
@keyframes swing {
  0%, 100% { transform: rotate(-4deg); }
  50% { transform: rotate(4deg); }
}

.eyebrow {
  margin: 0;
  font-weight: 600;
  font-size: .8rem;
  letter-spacing: .32em;
  text-transform: uppercase;
  color: var(--gold);
}
.eyebrow span { display: inline-block; margin: 0 .5em; animation: spin 6s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

h1 {
  /* marge interne généreuse : le dégradé (background-clip: text) ne couvre que la boîte,
     les hampes de la police manuscrite dépassent sinon et sont rognées */
  margin: -.2em 0 -.1em;
  font-family: var(--script);
  font-weight: 400;
  font-size: clamp(3.6rem, 12vw, 8rem);
  line-height: 1.1;
  padding: .3em .25em .15em;
  background: linear-gradient(180deg, #fffbe6 0%, #ffe28a 40%, var(--gold) 60%, var(--gold-deep) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 2px 0 rgba(90, 50, 0, .5)) drop-shadow(0 0 28px rgba(243, 198, 79, .35));
}
.intro {
  max-width: 560px;
  margin: 12px auto 0;
  color: #c7d3ea;
  font-size: 1.05rem;
}
.countdown {
  display: inline-flex;
  align-items: baseline;
  gap: .4em;
  margin-top: 26px;
  padding: 10px 22px;
  border-radius: 999px;
  border: 1px solid rgba(243, 198, 79, .45);
  background: rgba(255, 255, 255, .06);
  backdrop-filter: blur(6px);
  color: #e9eefb;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .1), 0 0 30px rgba(243, 198, 79, .12);
}
.countdown strong {
  font-family: var(--serif);
  font-size: 1.5rem;
  color: var(--gold);
  font-variant-numeric: tabular-nums;
}

.divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin: 44px auto 0;
  max-width: 520px;
}
.divider .line { flex: 1; height: 1px; background: linear-gradient(90deg, transparent, rgba(243, 198, 79, .6), transparent); }
.holly { width: 70px; height: 35px; filter: drop-shadow(0 2px 6px rgba(0, 0, 0, .4)); }

/* ---------- Grille de cadeaux ---------- */
main {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px 16px 40px;
}
.gifts {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr));
  gap: 56px 32px;
}
.gift {
  padding-top: 40px;
  perspective: 900px;
  animation: drop-in .8s cubic-bezier(.2, .9, .3, 1.2) both;
  animation-delay: calc(var(--i) * 120ms + 200ms);
}
@keyframes drop-in {
  from { opacity: 0; transform: translateY(40px) scale(.94); }
  to   { opacity: 1; transform: none; }
}

/* Papiers cadeaux */
.wrap-red {
  --paper: repeating-linear-gradient(45deg, #a8111d 0 12px, #c41e2f 12px 24px);
  --ribbon: #e9b949; --ribbon-light: #fff0b3; --ribbon-dark: #a8741f;
}
.wrap-green {
  --paper:
    radial-gradient(circle, #f3c64f 0 2px, transparent 2.6px) 0 0 / 22px 22px,
    radial-gradient(circle, rgba(255, 255, 255, .55) 0 1.4px, transparent 2px) 11px 11px / 22px 22px,
    #145234;
  --ribbon: #d0283a; --ribbon-light: #ff8a8f; --ribbon-dark: #8c1420;
}
.wrap-gold {
  --paper:
    repeating-linear-gradient(-45deg, rgba(255, 255, 255, .18) 0 6px, transparent 6px 18px),
    linear-gradient(135deg, #c8902b, #f3c64f 50%, #c8902b);
  --ribbon: #b3192a; --ribbon-light: #ff6b72; --ribbon-dark: #7d0f1b;
}
.wrap-navy {
  --paper:
    radial-gradient(circle, #fff 0 1.6px, transparent 2.2px) 0 0 / 26px 26px,
    radial-gradient(circle, rgba(255, 255, 255, .5) 0 1px, transparent 1.6px) 13px 13px / 26px 26px,
    #1a2d5e;
  --ribbon: #c9d3e3; --ribbon-light: #ffffff; --ribbon-dark: #7f8ca4;
}

.present {
  --rx: 0deg; --ry: 0deg; --mx: 50%; --my: 0%;
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  color: var(--ink);
  text-decoration: none;
  border-radius: 18px;
  transform: rotateX(var(--rx)) rotateY(var(--ry));
  transform-style: preserve-3d;
  transition: transform .25s ease-out, filter .3s;
  filter: drop-shadow(0 18px 30px rgba(0, 0, 0, .45));
}
.present:hover { filter: drop-shadow(0 26px 40px rgba(0, 0, 0, .55)) drop-shadow(0 0 30px rgba(243, 198, 79, .18)); }
.present:focus-visible { outline: 3px solid var(--gold); outline-offset: 6px; }

.lid {
  position: relative;
  height: 68px;
  border-radius: 18px 18px 0 0;
  background: var(--paper);
  box-shadow: inset 0 -10px 16px -10px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(255, 255, 255, .25);
}
.ribbon {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 26px;
  transform: translateX(-50%);
  background: linear-gradient(90deg, var(--ribbon-dark), var(--ribbon) 25%, var(--ribbon-light) 50%, var(--ribbon) 75%, var(--ribbon-dark));
}
.bow {
  position: absolute;
  left: 50%;
  top: -40px;
  width: 116px;
  transform: translateX(-50%);
  filter: drop-shadow(0 4px 4px rgba(0, 0, 0, .35));
  transition: transform .4s cubic-bezier(.3, 1.6, .5, 1);
  transform-origin: 50% 55%;
}
.present:hover .bow { transform: translateX(-50%) scale(1.08) rotate(-3deg); }

.box {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  border-radius: 0 0 18px 18px;
  background:
    radial-gradient(600px circle at var(--mx) var(--my), rgba(255, 255, 255, .55), transparent 40%),
    var(--cream);
  overflow: hidden;
}
.box::before {
  /* bande de ruban sous le couvercle */
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 6px;
  background: linear-gradient(rgba(0, 0, 0, .18), transparent);
}

/* Étiquette de prix */
.tag-wrap {
  position: absolute;
  top: 10px;
  right: 14px;
  z-index: 3;
  transform-origin: 14px 0;
  animation: tag-sway 4s ease-in-out infinite;
  animation-delay: calc(var(--i) * -0.7s);
}
.present:hover .tag-wrap { animation-duration: 1.2s; }
@keyframes tag-sway {
  0%, 100% { transform: rotate(-4deg); }
  50% { transform: rotate(3deg); }
}
.string {
  position: absolute;
  top: -10px;
  left: 13px;
  width: 1.5px;
  height: 30px;
  background: #8a6a3c;
}
.tag {
  position: relative;
  margin-top: 10px;
  padding: 18px 14px 10px;
  min-width: 92px;
  text-align: center;
  color: #4a2d12;
  background: linear-gradient(160deg, #f2dfb6, #dcbf88);
  clip-path: polygon(0 18px, 18px 0, 100% 0, 100% 100%, 0 100%);
  -webkit-mask: radial-gradient(circle at 14px 10px, transparent 0 3.5px, #000 4px);
          mask: radial-gradient(circle at 14px 10px, transparent 0 3.5px, #000 4px);
  border-radius: 0 6px 6px 6px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, .25);
}
.tag small {
  display: block;
  font-size: .62rem;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  opacity: .7;
}
.tag span {
  display: block;
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.35rem;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
  color: var(--red);
}
.tag--text span { font-size: .95rem; max-width: 96px; }

.media {
  position: relative;
  aspect-ratio: 4 / 3;
  margin: 16px 16px 0;
  padding: 22px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: radial-gradient(circle at 50% 45%, #ffffff 0%, #ffffff 55%, #f3ece0 100%);
  box-shadow: inset 0 0 0 1px rgba(90, 60, 30, .08);
}
.media img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  mix-blend-mode: multiply;
  transition: transform .5s cubic-bezier(.2, .9, .3, 1.3);
}
.present:hover .media img { transform: scale(1.07) translateY(-4px); }

.giftcard {
  position: relative;
  width: 82%;
  aspect-ratio: 1.586;
  border-radius: 14px;
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  color: #fff;
  background:
    radial-gradient(circle at 85% 15%, rgba(255, 255, 255, .25), transparent 40%),
    linear-gradient(135deg, #3643ba 0%, #0082c3 100%);
  box-shadow: 0 14px 26px rgba(20, 40, 120, .35);
  overflow: hidden;
  transform: rotate(-4deg);
  transition: transform .5s cubic-bezier(.2, .9, .3, 1.3);
}
.present:hover .giftcard { transform: rotate(0deg) scale(1.05); }
.giftcard::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 35%, rgba(255, 255, 255, .35) 50%, transparent 65%);
  transform: translateX(-100%);
  animation: sheen 4s ease-in-out infinite;
}
@keyframes sheen { 0%, 60% { transform: translateX(-100%); } 100% { transform: translateX(100%); } }
.giftcard__flake { position: absolute; top: 12px; left: 16px; width: 34px; height: 34px; opacity: .9; }
.giftcard span { font-size: .75rem; letter-spacing: .12em; text-transform: uppercase; opacity: .85; }
.giftcard strong { font-family: var(--serif); font-size: 1.6rem; line-height: 1.1; }

.info {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 18px 20px 22px;
}
.store {
  font-size: .7rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--green);
}
.info h2 {
  margin: 6px 0 8px;
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.22rem;
  line-height: 1.25;
  color: var(--ink);
}
.info p { margin: 0 0 20px; color: var(--ink-soft); font-size: .92rem; }
.cta {
  margin-top: auto;
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 999px;
  font-weight: 600;
  font-size: .9rem;
  color: #fff;
  background: linear-gradient(180deg, #d9303f, #a8111d);
  box-shadow: 0 4px 12px rgba(168, 17, 29, .35), inset 0 1px 0 rgba(255, 255, 255, .3);
  transition: gap .2s, box-shadow .2s;
}
.cta svg { width: 18px; height: 18px; transition: transform .2s; }
.present:hover .cta { box-shadow: 0 6px 18px rgba(168, 17, 29, .5), inset 0 1px 0 rgba(255, 255, 255, .3); }
.present:hover .cta svg { transform: translateX(3px); }

/* ---------- Pied de page : paysage ---------- */
.scene {
  position: relative;
  height: clamp(300px, 34vw, 440px);
  margin-top: 20px;
  overflow: hidden;
}
.landscape { position: absolute; bottom: 0; left: 0; width: 100%; height: 100%; }
.scene__text {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 0 16px;
}
.merry {
  margin: 0;
  font-family: var(--script);
  font-size: clamp(2.6rem, 7vw, 4.4rem);
  color: var(--gold);
  text-shadow: 0 0 24px rgba(243, 198, 79, .4);
}

/* ---------- Responsive & accessibilité ---------- */
@media (max-width: 640px) {
  .hero { padding-top: 100px; }
  .bauble--hide-sm, .moon { display: none; }
  .gifts { gap: 48px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
