/*
 * Démo carte cadeau Aphrodite Room.
 * Mêmes jetons que le site (src/app/globals.css) : aubergine et or, la lumière des LED et de la peinture UV.
 */
:root {
  --nuit: #0f0611;
  --cave: #1a0b1e;
  --aubergine: #26112b;
  --grenat: #4c2556;
  --or: #c9a96e;
  --or-clair: #e8d3a6;
  --or-fonce: #8a6a32;
  --ivoire: #f2e7da;
  --uv: #7a3cff;
  --magenta: #e23c9e;
  --eau: #4fd8e6;
  --phosphore: #d8ff8a;

  --display: "Cormorant Garamond", Georgia, serif;
  --sans: "Jost", "Helvetica Neue", Arial, sans-serif;
  --script: "Pinyon Script", "Cormorant Garamond", cursive;
  --ease-voute: cubic-bezier(0.22, 1, 0.36, 1);

  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
}

html,
body {
  height: 100%;
  overflow: hidden;
  background: var(--nuit);
}

body {
  font-family: var(--sans);
  color: color-mix(in srgb, var(--ivoire) 86%, transparent);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid var(--or-clair);
  outline-offset: 3px;
  border-radius: 4px;
}

::selection {
  background: var(--or);
  color: var(--nuit);
}

.defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

/* ───────────── Le cadre : plein écran sur le site, 9:16 ou 4:5 en mode pub ───────────── */

.cadre {
  position: fixed;
  inset: 0;
  overflow: hidden;
  container-type: size;
  background:
    radial-gradient(90% 60% at 50% 58%, #3b1a44 0%, transparent 70%),
    radial-gradient(140% 100% at 50% 40%, var(--aubergine) 0%, var(--cave) 62%, var(--nuit) 100%);
  visibility: hidden;
}

.pret .cadre {
  visibility: visible;
}

html[data-format] body {
  background: radial-gradient(circle at 50% 50%, #170a1a, #070308);
}

html[data-format="story"] .cadre,
html[data-format="feed"] .cadre {
  inset: auto;
  top: 50%;
  left: 50%;
  translate: -50% -50%;
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--or) 22%, transparent),
    0 40px 140px rgb(0 0 0 / 0.7);
}

html[data-format="story"] .cadre {
  width: min(100vw, 100svh * 9 / 16);
  height: min(100svh, 100vw * 16 / 9);
}

html[data-format="feed"] .cadre {
  width: min(100vw, 100svh * 4 / 5);
  height: min(100svh, 100vw * 5 / 4);
}

.ciel,
.paillettes,
.voutes,
.lueurs {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.paillettes {
  z-index: 40;
}

.voutes path {
  fill: none;
  stroke: var(--or);
  stroke-width: 1;
}

.lueur {
  position: absolute;
  width: 70cqmax;
  height: 70cqmax;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.2;
}

.lueur.uv {
  left: -30cqmax;
  top: -26cqmax;
  background: radial-gradient(closest-side, var(--uv), transparent);
}

.lueur.magenta {
  right: -34cqmax;
  bottom: -38cqmax;
  background: radial-gradient(closest-side, var(--magenta), transparent);
  opacity: 0.14;
}

/* Grain de papier sur tout le cadre. */
.cadre::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 60;
  pointer-events: none;
  opacity: 0.09;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ───────────── Logo et titres ───────────── */

.marque {
  position: absolute;
  top: max(3.2cqh, 18px);
  left: 50%;
  translate: -50% 0;
  width: clamp(130px, 30cqw, 210px);
  z-index: 5;
}

.marque svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.marque path {
  fill: url(#orTete);
  fill-opacity: 0;
  stroke: var(--or-clair);
  stroke-width: 18;
}

.titres {
  position: absolute;
  top: calc(max(3.2cqh, 18px) + clamp(52px, 12cqw, 86px) + 1.4cqh);
  left: 0;
  right: 0;
  z-index: 6;
  padding: 0 16px;
  text-align: center;
  pointer-events: none;
}

.surtitre {
  font-size: clamp(0.7rem, 1.4cqmin + 0.4rem, 0.9rem);
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--or-clair) 80%, transparent);
  min-height: 1.4em;
}

.titre {
  font-family: var(--display);
  font-weight: 500;
  font-style: italic;
  font-size: clamp(2rem, min(7.4cqw, 8.4cqh), 4.6rem);
  line-height: 1.02;
  letter-spacing: -0.01em;
  color: var(--or);
  text-wrap: balance;
  text-shadow: 0 2px 40px rgb(15 6 17 / 0.85);
}

.titre .prenom {
  color: var(--or-clair);
}

.titre-occasion {
  position: absolute;
  left: 0;
  right: 0;
  top: 1.4em;
  padding: 0 16px;
  font-size: clamp(2.6rem, min(10cqw, 11cqh), 6rem);
  visibility: hidden;
}

/* Les lettres prennent le reflet or ; SplitText les découpe en mots puis en caractères. */
.titre-occasion .char,
.acc-titre .char,
.fin-titre .char {
  background: linear-gradient(100deg, #a07f3f 0%, #e8d3a6 40%, #fff2d2 50%, #c9a96e 62%, #93733a 100%);
  background-size: 300% 100%;
  background-position: var(--reflet, 100%) 0;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  padding: 0 0.04em;
  margin: 0 -0.04em;
}

.sous-titre {
  margin-top: 0.7em;
  font-size: clamp(0.85rem, 1.4cqmin + 0.55rem, 1.05rem);
  letter-spacing: 0.06em;
  color: color-mix(in srgb, var(--ivoire) 70%, transparent);
  opacity: 0;
}

/* ───────────── Scène, enveloppe ───────────── */

.scene {
  --env-w: min(84cqw, 540px, 74cqh);
  position: absolute;
  left: 0;
  right: 0;
  top: 30cqh;
  bottom: 15cqh;
  display: grid;
  place-items: center;
  perspective: 1400px;
  z-index: 10;
}

@container (orientation: landscape) {
  .scene {
    --env-w: min(84cqw, 520px, 92cqh);
    top: 31cqh;
    bottom: 12cqh;
  }
}

html[data-format="feed"] .scene {
  --env-w: min(82cqw, 520px);
}

.flotteur {
  position: relative;
  width: var(--env-w);
  aspect-ratio: 1000 / 640;
  perspective: 1600px;
  cursor: pointer;
}

.ouverte .flotteur {
  cursor: default;
}

.env {
  position: absolute;
  inset: 0;
}

.env svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.env-dos {
  z-index: 1;
  border-radius: calc(var(--env-w) * 0.014);
  background: #2a1230;
  box-shadow: 0 30px 60px -20px rgb(0 0 0 / 0.7);
  overflow: hidden;
}

.env-dos .doublure {
  position: absolute;
  inset: 3% 3% 0;
  border-radius: calc(var(--env-w) * 0.01);
  background:
    linear-gradient(180deg, rgb(15 6 17 / 0) 30%, rgb(15 6 17 / 0.65) 100%),
    repeating-linear-gradient(45deg, color-mix(in srgb, var(--or) 24%, transparent) 0 1px, transparent 1px 16px),
    repeating-linear-gradient(-45deg, color-mix(in srgb, var(--or) 24%, transparent) 0 1px, transparent 1px 16px),
    #3d1d45;
}

.env-poche {
  z-index: 3;
  pointer-events: none;
}

.pli {
  fill: none;
  stroke: color-mix(in srgb, var(--or) 22%, transparent);
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
}

.pli-or {
  stroke: color-mix(in srgb, var(--or) 55%, transparent);
}

.env-adresse {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 12%;
  text-align: center;
  font-family: var(--script);
  font-size: calc(var(--env-w) * 0.075);
  line-height: 1;
  color: var(--or-clair);
  text-shadow: 0 1px 0 rgb(15 6 17 / 0.8);
  opacity: 0.92;
}

.env-rabat {
  z-index: 4;
  perspective: 1200px;
}

.rabat {
  position: absolute;
  inset: 0;
  transform-origin: 50% 0;
  transform-style: preserve-3d;
  pointer-events: none;
}

.rabat-face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.rabat-int {
  transform: rotateY(180deg);
}

/* ───────────── Le sceau de cire ───────────── */

.sceau {
  position: absolute;
  left: 50%;
  top: 55%;
  width: 21%;
  aspect-ratio: 1;
  translate: -50% -50%;
  border-radius: 50%;
  padding: 0;
}

.sceau-moitie {
  position: absolute;
  inset: 0;
  filter: drop-shadow(0 4px 6px rgb(15 6 17 / 0.6));
}

.sceau-moitie svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.sceau-moitie.g {
  clip-path: polygon(-10% -10%, 54% -10%, 47% 18%, 56% 38%, 46% 57%, 55% 76%, 49% 110%, -10% 110%);
}

.sceau-moitie.d {
  clip-path: polygon(54% -10%, 110% -10%, 110% 110%, 49% 110%, 55% 76%, 46% 57%, 56% 38%, 47% 18%);
}

.sceau-lueur {
  position: absolute;
  inset: -18%;
  border-radius: 50%;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--or-clair) 55%, transparent), transparent 75%);
  opacity: 0;
}

.tap {
  position: absolute;
  left: 50%;
  top: 55%;
  width: 16%;
  aspect-ratio: 1;
  translate: -50% -50%;
  border-radius: 50%;
  border: 2px solid var(--ivoire);
  box-shadow: 0 0 24px color-mix(in srgb, var(--ivoire) 60%, transparent);
  opacity: 0;
  pointer-events: none;
}

/* ───────────── Halo et ombre ───────────── */

.halo {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 190%;
  aspect-ratio: 1;
  translate: -50% -50%;
  border-radius: 50%;
  opacity: 0;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--or) 34%, transparent), color-mix(in srgb, var(--grenat) 30%, transparent) 45%, transparent 72%);
}

.halo .rayons {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: repeating-conic-gradient(from 0deg, color-mix(in srgb, var(--or-clair) 24%, transparent) 0deg 2.5deg, transparent 2.5deg 15deg);
  mask: radial-gradient(closest-side, #000 18%, transparent 70%);
  -webkit-mask: radial-gradient(closest-side, #000 18%, transparent 70%);
  mix-blend-mode: screen;
}

.ombre {
  position: absolute;
  left: 6%;
  right: 6%;
  bottom: -16%;
  height: 20%;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgb(0 0 0 / 0.6), transparent);
  filter: blur(8px);
  z-index: 0;
  pointer-events: none;
}

/* ───────────── La carte ───────────── */

.carte {
  --carte-w: calc(var(--env-w) * 0.94);
  --rayon: calc(var(--carte-w) * 0.045);
  --mx: 0.5;
  --my: 0.3;
  position: absolute;
  left: 50%;
  top: 50%;
  width: var(--carte-w);
  aspect-ratio: 1.6;
  margin-left: calc(var(--carte-w) / -2);
  margin-top: calc(var(--carte-w) / -3.2);
  z-index: 2;
  transform-style: preserve-3d;
  touch-action: none;
}

.carte-tilt,
.carte-rot {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
}

.ouverte .carte {
  cursor: grab;
}

.ouverte .carte:active {
  cursor: grabbing;
}

/* Tranche dorée : des feuillets empilés en profondeur, visibles quand la carte passe de profil. */
.tranche {
  position: absolute;
  inset: 0;
  border-radius: var(--rayon);
  background: linear-gradient(90deg, #6e5025, #e8d3a6 30%, #a8853f 55%, #f3e2b6 80%, #6e5025);
}

.face {
  position: absolute;
  inset: 0;
  border-radius: var(--rayon);
  overflow: hidden;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  container-type: inline-size;
}

.face-avant {
  background:
    radial-gradient(120% 90% at 50% 0%, #4a2353 0%, transparent 60%),
    radial-gradient(90% 80% at 80% 110%, #3a1842 0%, transparent 60%),
    linear-gradient(160deg, #2c1333, #1a0b1e 70%);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--or) 40%, transparent);
}

.face-dos {
  transform: rotateY(180deg) translateZ(var(--demi-epaisseur, 2px));
  background:
    radial-gradient(130% 100% at 30% 20%, #fbf4ea 0%, transparent 70%),
    linear-gradient(160deg, #f4eadd, #e7d8c3);
  color: var(--aubergine);
  display: grid;
  grid-template-columns: 34% 1fr;
  grid-template-rows: 1fr auto;
  /* Pourcentages : rapportés à la largeur de la carte (les unités cqw visent ici le cadre). */
  padding: 6% 6% 4.4%;
  column-gap: 5%;
}

.face-avant {
  transform: translateZ(var(--demi-epaisseur, 2px));
}

.avant-voute {
  position: absolute;
  inset: 0;
}

.avant-voute svg {
  width: 100%;
  height: 100%;
}

.avant-voute path {
  fill: none;
  stroke: var(--or);
  stroke-opacity: 0.16;
  stroke-width: 0.35;
}

.avant-voute path:first-child {
  stroke-opacity: 0.3;
}

.poussiere {
  position: absolute;
  inset: 0;
  opacity: 0.55;
  background-image:
    radial-gradient(1px 1px at 12% 22%, var(--phosphore), transparent),
    radial-gradient(1px 1px at 82% 18%, var(--or-clair), transparent),
    radial-gradient(1.5px 1.5px at 70% 34%, var(--phosphore), transparent),
    radial-gradient(1px 1px at 24% 64%, var(--or-clair), transparent),
    radial-gradient(1px 1px at 90% 70%, var(--phosphore), transparent),
    radial-gradient(1.5px 1.5px at 40% 12%, var(--or-clair), transparent),
    radial-gradient(1px 1px at 58% 82%, var(--phosphore), transparent),
    radial-gradient(1px 1px at 8% 86%, var(--or-clair), transparent);
}

.filet {
  position: absolute;
  inset: 3.2cqw;
  border-radius: calc(var(--rayon) * 0.6);
  border: 1px solid color-mix(in srgb, var(--or) 45%, transparent);
  box-shadow:
    inset 0 0 0 2.5px transparent,
    inset 0 0 0 3.2px color-mix(in srgb, var(--or) 18%, transparent);
}

.mention {
  position: absolute;
  font-size: clamp(6.5px, 1.75cqw, 11px);
  letter-spacing: 0.32em;
  text-transform: uppercase;
  line-height: 1.5;
  color: color-mix(in srgb, var(--or-clair) 78%, transparent);
}

.mention-hg {
  left: 7cqw;
  top: 6.4cqw;
}

.mention-hd {
  right: 7cqw;
  top: 6.4cqw;
  letter-spacing: 0.2em;
}

.mention-bd {
  right: 7cqw;
  bottom: 6.8cqw;
  text-align: right;
  letter-spacing: 0.22em;
  font-size: clamp(5.5px, 1.45cqw, 9px);
  color: color-mix(in srgb, var(--or-clair) 58%, transparent);
}

.carte-logo {
  position: absolute;
  left: 50%;
  top: 15cqw;
  width: 56cqw;
  translate: -50% 0;
  filter: drop-shadow(0 0.18cqw 0 rgb(15 6 17 / 0.95)) drop-shadow(0 -0.08cqw 0 rgb(255 240 205 / 0.35)) drop-shadow(0 0.6cqw 1.2cqw rgb(0 0 0 / 0.45));
}

.carte-logo svg {
  display: block;
  width: 100%;
  height: auto;
}

.carte-logo path {
  fill: url(#orCarte);
}

.carte-devise {
  position: absolute;
  left: 0;
  right: 0;
  top: 40.5cqw;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2.2cqw;
  font-family: var(--display);
  font-style: italic;
  font-size: 3.6cqw;
  color: var(--or-clair);
  text-shadow: 0 0.15cqw 0 rgb(15 6 17 / 0.9);
}

.carte-devise .trait {
  width: 6cqw;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--or));
}

.carte-devise .trait:last-child {
  background: linear-gradient(-90deg, transparent, var(--or));
}

.carte-valeur {
  position: absolute;
  left: 7cqw;
  bottom: 5.2cqw;
  display: flex;
  flex-direction: column;
}

.carte-valeur .mention {
  position: static;
}

.montant {
  font-family: var(--display);
  font-weight: 500;
  font-size: 11.5cqw;
  line-height: 0.9;
  letter-spacing: -0.01em;
  font-variant-numeric: lining-nums;
}

.montant .euro {
  font-size: 0.55em;
  margin-left: 0.12em;
}

/* Or à chaud : le reflet suit l'angle de la carte (--mx, --my, posés par le script). */
.or-feuille {
  background: linear-gradient(
    105deg,
    #7d5e2c 0%,
    #c9a96e calc(var(--mx) * 60% + 2%),
    #fff4d8 calc(var(--mx) * 60% + 18%),
    #c9a96e calc(var(--mx) * 60% + 34%),
    #8a6a32 100%
  );
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0.18cqw 0 rgb(15 6 17 / 0.95)) drop-shadow(0 -0.06cqw 0 rgb(255 240 205 / 0.4));
}

.reflet-holo,
.reflet-or,
.balayage {
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
}

.reflet-holo {
  background: linear-gradient(
    118deg,
    transparent 22%,
    color-mix(in srgb, var(--uv) 34%, transparent) 36%,
    color-mix(in srgb, var(--eau) 28%, transparent) 45%,
    color-mix(in srgb, var(--phosphore) 22%, transparent) 52%,
    color-mix(in srgb, var(--magenta) 30%, transparent) 60%,
    transparent 76%
  );
  background-size: 320% 320%;
  background-position: calc(var(--mx) * 100%) calc(var(--my) * 100%);
  mix-blend-mode: color-dodge;
  opacity: 0.42;
}

.reflet-or {
  background: radial-gradient(
    circle at calc(var(--mx) * 100%) calc(var(--my) * 100%),
    rgb(255 238 196 / 0.32),
    rgb(255 238 196 / 0.08) 28%,
    transparent 55%
  );
  mix-blend-mode: soft-light;
}

.face-dos .reflet-or {
  mix-blend-mode: multiply;
  background: radial-gradient(
    circle at calc(100% - var(--mx) * 100%) calc(var(--my) * 100%),
    transparent 30%,
    rgb(120 90 60 / 0.16) 100%
  );
}

.balayage {
  background: linear-gradient(105deg, transparent 35%, rgb(255 246 222 / 0.55) 48%, rgb(255 246 222 / 0.1) 54%, transparent 62%);
  mix-blend-mode: overlay;
  translate: -120% 0;
}

/* Dos de la carte : papier ivoire, photo sous arche, mot manuscrit. */
.dos-photo {
  grid-row: 1;
  align-self: stretch;
  border-radius: 50% 50% 0.8cqw 0.8cqw / 28% 28% 0.8cqw 0.8cqw;
  overflow: hidden;
  box-shadow:
    0 0 0 0.5cqw #f4eadd,
    0 0 0 0.75cqw color-mix(in srgb, var(--or) 80%, transparent);
}

.dos-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
  display: block;
}

.dos-texte {
  grid-row: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.dos-pour {
  font-size: clamp(6.5px, 1.7cqw, 11px);
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: #8a6a32;
}

.dos-message {
  margin-top: 1.6cqw;
  font-family: var(--display);
  font-style: italic;
  font-weight: 500;
  font-size: 3.55cqw;
  line-height: 1.28;
  color: #3a1a42;
  text-wrap: pretty;
}

.dos-signature {
  margin-top: 1.2cqw;
  align-self: flex-end;
  font-family: var(--script);
  font-size: 6.4cqw;
  line-height: 1;
  color: #9c7a3c;
  padding-right: 2cqw;
}

.dos-pied {
  grid-column: 1 / -1;
  margin-top: 3.4cqw;
  padding-top: 2.2cqw;
  border-top: 1px solid color-mix(in srgb, var(--or) 55%, transparent);
  display: flex;
  justify-content: space-between;
  gap: 2cqw;
  font-size: clamp(5.5px, 1.45cqw, 9.5px);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #6b4c72;
  white-space: nowrap;
}

.dos-pied b {
  font-weight: 500;
  color: #3a1a42;
  letter-spacing: 0.24em;
}

/* ───────────── Indice et commandes ───────────── */

.indice {
  position: absolute;
  left: 0;
  right: 0;
  bottom: max(9cqh, 70px);
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.7em;
  padding: 0 16px;
  font-size: clamp(0.72rem, 1.2cqmin + 0.45rem, 0.88rem);
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--or-clair) 82%, transparent);
  text-align: center;
  opacity: 0;
  pointer-events: none;
}

.indice .point {
  flex: none;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--or-clair);
  box-shadow: 0 0 12px var(--or);
  animation: battement 1.6s ease-in-out infinite;
}

@keyframes battement {
  50% {
    transform: scale(1.8);
    opacity: 0.4;
  }
}

.commandes {
  position: absolute;
  left: 0;
  right: 0;
  bottom: max(3.4cqh, 20px);
  z-index: 20;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0 16px;
  visibility: hidden;
}

.bouton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 44px;
  padding: 0.7rem 1.4rem;
  font-family: var(--sans);
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  border-radius: 999px;
  text-decoration: none;
  white-space: nowrap;
  transition:
    background-color 0.3s var(--ease-voute),
    color 0.3s var(--ease-voute),
    box-shadow 0.4s var(--ease-voute);
}

.bouton-or {
  background: var(--or);
  color: var(--nuit);
}

.bouton-or:hover {
  background: var(--or-clair);
  box-shadow: 0 0 2.5rem -0.5rem color-mix(in srgb, var(--or) 70%, transparent);
}

.bouton-trait {
  border: 1px solid color-mix(in srgb, var(--or) 55%, transparent);
  color: var(--or-clair);
  background: rgb(15 6 17 / 0.3);
}

.bouton-trait:hover {
  background: color-mix(in srgb, var(--or) 14%, transparent);
}

.bouton-rond {
  width: 44px;
  padding: 0;
  border: 1px solid color-mix(in srgb, var(--or) 40%, transparent);
  color: var(--or-clair);
}

.bouton-rond:hover {
  background: color-mix(in srgb, var(--or) 14%, transparent);
}

.bouton svg,
.pastille svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

@media (max-width: 420px) {
  .bouton {
    font-size: 0.82rem;
    padding: 0.65rem 1.05rem;
  }
}

.pastille {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  min-height: 34px;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--or) 30%, transparent);
  background: rgb(15 6 17 / 0.45);
  backdrop-filter: blur(6px);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--or-clair) 85%, transparent);
  text-decoration: none;
  transition: background-color 0.3s;
}

.pastille:hover {
  background: color-mix(in srgb, var(--or) 16%, rgb(15 6 17 / 0.5));
}

.pastille-son {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 50;
  width: 38px;
  height: 38px;
  min-height: 0;
  padding: 0;
  justify-content: center;
}

.pastille-son .barre {
  display: none;
}

.pastille-son[aria-pressed="false"] .barre {
  display: inline;
}

.pastille-son[aria-pressed="false"] .ondes {
  display: none;
}

@container (max-width: 560px) {
  .commandes {
    bottom: 48px;
  }

  .indice {
    bottom: 112px;
  }
}

.hors-cadre {
  display: none;
}

html[data-format] .hors-cadre {
  position: fixed;
  top: 16px;
  left: 16px;
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

html[data-format] .hors-cadre [aria-current="page"] {
  background: var(--or);
  color: var(--nuit);
}

/* Le menu ne recouvre pas le format pub quand la place manque (téléphone, enregistrement plein cadre). */
@media (max-aspect-ratio: 1/1) {
  html[data-format] .hors-cadre {
    display: none;
  }
}

/* ───────────── Fin de la pub ───────────── */

.fin {
  position: absolute;
  inset: 0;
  z-index: 8;
  pointer-events: none;
  visibility: hidden;
}

.fin-arche {
  position: absolute;
  left: 50%;
  top: 14cqh;
  width: min(66cqw, 44cqh);
  height: 38cqh;
  translate: -50% 0;
  border-radius: 50% 50% 0 0 / 32% 32% 0 0;
  overflow: hidden;
  box-shadow:
    0 0 0 6px var(--aubergine),
    0 0 0 7px color-mix(in srgb, var(--or) 70%, transparent);
}

.fin-arche img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
}

.fin-arche::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgb(15 6 17 / 0.75));
}

.fin-slot {
  position: absolute;
  left: 50%;
  top: 49cqh;
  width: min(40cqw, 30cqh);
  aspect-ratio: 1.6;
  translate: -50% 0;
}

/* Titre, mention et adresse s'empilent : si le titre passe sur deux lignes (iPhone), le reste descend. */
.fin-textes {
  position: absolute;
  left: 0;
  right: 0;
  top: 66cqh;
  padding: 0 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: min(2.4cqh, 18px);
  text-align: center;
}

.fin-titre {
  font-family: var(--display);
  font-style: italic;
  font-weight: 500;
  font-size: min(7.6cqw, 5cqh);
  line-height: 1.04;
  color: var(--or);
  text-wrap: balance;
}

.fin-sous {
  max-width: 34em;
  font-size: clamp(9px, min(2.5cqw, 1.5cqh), 15px);
  line-height: 1.6;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  text-wrap: balance;
  color: color-mix(in srgb, var(--ivoire) 78%, transparent);
}

.fin-url {
  margin-top: min(0.8cqh, 6px);
  padding: 0.75em 1.6em;
  border-radius: 999px;
  background: var(--or);
  color: var(--nuit);
  font-size: clamp(11px, min(3cqw, 1.8cqh), 18px);
  font-weight: 500;
  letter-spacing: 0.08em;
  white-space: nowrap;
}

html[data-format="feed"] .fin-arche {
  top: 13cqh;
  height: 38cqh;
}

html[data-format="feed"] .fin-slot {
  top: 48cqh;
}

/* Variante sans carte à la fin : l'arche photo prend la place. */
html[data-fin="sans-carte"] .fin-arche {
  width: min(70cqw, 48cqh);
  height: 48cqh;
}

html[data-format="feed"][data-fin="sans-carte"] .fin-arche {
  height: 54cqh;
}

html[data-format="feed"] .fin-textes {
  top: 71cqh;
}

/* ───────────── Accroche de la pub ───────────── */

.accroche {
  position: absolute;
  inset: 0;
  z-index: 9;
  pointer-events: none;
  display: none;
}

html[data-format] .accroche {
  display: block;
}

.acc-avant {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  translate: 0 -50%;
  padding: 0 7cqw;
  text-align: center;
  font-family: var(--display);
  font-style: italic;
}

.acc-petit {
  font-size: min(8cqw, 4.6cqh);
  line-height: 1.1;
  color: color-mix(in srgb, var(--ivoire) 82%, transparent);
}

.acc-grand {
  margin-top: 0.1em;
  font-weight: 500;
  font-size: min(12.5cqw, 7.2cqh);
  line-height: 1.05;
  color: var(--or-clair);
  text-shadow: 0 2px 40px rgb(15 6 17 / 0.85);
}

.acc-barre {
  position: relative;
  display: inline-block;
}

/* Le trait d'or qui barre « juste un cadeau ». */
.rature {
  position: absolute;
  left: -4%;
  right: -4%;
  top: 56%;
  height: 0.065em;
  border-radius: 1em;
  rotate: -5deg;
  transform-origin: 0 50%;
  background: linear-gradient(90deg, #c9a96e, #fff3d6 55%, #c9a96e);
  box-shadow: 0 0 0.35em color-mix(in srgb, var(--or-clair) 70%, transparent);
}

.acc-arche {
  position: absolute;
  left: 50%;
  top: 15cqh;
  width: min(70cqw, 46cqh);
  height: 46cqh;
  translate: -50% 0;
  border-radius: 50% 50% 0 0 / 32% 32% 0 0;
  overflow: hidden;
  box-shadow:
    0 0 0 6px var(--aubergine),
    0 0 0 7px color-mix(in srgb, var(--or) 70%, transparent);
  clip-path: inset(120% -16px -16px -16px);
}

.acc-arche img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
}

.acc-arche::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgb(15 6 17 / 0.7));
}

.acc-apres {
  position: absolute;
  left: 0;
  right: 0;
  top: 64cqh;
  padding: 0 6cqw;
  text-align: center;
}

.acc-sur {
  font-size: clamp(10px, min(2.8cqw, 1.7cqh), 16px);
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--or-clair);
}

.acc-titre {
  margin-top: 0.25em;
  font-family: var(--display);
  font-style: italic;
  font-weight: 500;
  font-size: min(10cqw, 6.4cqh);
  line-height: 1.02;
  color: var(--or);
  text-wrap: balance;
}

.acc-sous {
  margin-top: 0.15em;
  font-family: var(--display);
  font-style: italic;
  font-size: min(7.4cqw, 4.4cqh);
  color: color-mix(in srgb, var(--ivoire) 86%, transparent);
}

@media (prefers-reduced-motion: reduce) {
  .indice .point {
    animation: none;
  }
}

/* Aperçu intégré à la page d'achat du site : ni navigation entre formats, ni réservation,
   et la consigne passe sous le cadre, où elle ne chevauche pas la carte. */
html[data-integre] .hors-cadre,
html[data-integre] #btnReserver,
html[data-integre] .indice {
  display: none;
}
