/*
 * Printiverse Design System - "Printiverse Orbital" (DA de l'outil www)
 * Feuille de style autonome : tokens + calques de fond + composants réutilisables.
 * Voir DESIGN.md pour les règles d'usage.
 */



/* ============================ 1. TOKENS ============================ */
:root {
  /* Couleurs de marque */
  --pv-orange: #ff8200;
  --pv-violet: #ac4fc6;
  --pv-blue: #0047bb;
  --pv-grey: #d9d9d6;
  --pv-black: #000000;
  --pv-white: #ffffff;

  /* Couleurs fonctionnelles */
  --pv-green: #43d97f;
  --pv-online: #35ff6f;

  /* Variantes translucides (bordures / lueurs) */
  --pv-blue-a: rgba(0, 71, 187, 0.45);
  --pv-violet-a: rgba(172, 79, 198, 0.4);
  --pv-orange-a: rgba(255, 130, 0, 0.5);
  --pv-grey-line: rgba(217, 217, 214, 0.3);
  --pv-grey-text: rgba(217, 217, 214, 0.72);

  /* Dégradés signature */
  --pv-grad-glass: linear-gradient(135deg, rgba(0, 71, 187, 0.3), rgba(172, 79, 198, 0.22));
  --pv-grad-glass-hover: linear-gradient(135deg, rgba(0, 71, 187, 0.45), rgba(172, 79, 198, 0.4));
  --pv-grad-solid: linear-gradient(135deg, var(--pv-blue), var(--pv-violet));
  --pv-grad-sheen: radial-gradient(circle at 30% 28%, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0) 45%);

  /* Typographie */
  --pv-font-display: "Michroma", sans-serif;
  --pv-font-body: "Share Tech Mono", monospace;

  /* Formes & mouvement */
  --pv-radius-sm: 6px;
  --pv-radius: 8px;
  --pv-ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --pv-motion: 1.25; /* multiplicateur de durée des animations (>1 = plus lent) */
}

/* ============================ 2. BASE ============================ */
* { box-sizing: border-box; }

html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--pv-black);
  color: var(--pv-white);
  font-family: var(--pv-font-body);
}

/* Page "plein écran sans scroll" (écran d'accueil). Ajouter .pv-fullscreen sur <body>. */
html:has(body.pv-fullscreen),
body.pv-fullscreen {
  height: 100%;
  width: 100%;
  overflow: hidden;
}

a { color: var(--pv-white); text-underline-offset: 2px; }
a:hover,
a:focus-visible { color: var(--pv-orange); }

::selection { background: var(--pv-violet); color: var(--pv-white); }

/* ===================== 3. CALQUES DE FOND (ordre z fixe) =====================
   0 canvas gradient | 1 noise | 2 vignette | 3 scanline | 4 grille perspective
   8 contenu         | 25 panneaux flottants                                  */
#gradient-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  --gradient-color-1: #0047bb;
  --gradient-color-2: #ff8200;
  --gradient-color-3: #ac4fc6;
  --gradient-color-4: #000000;
}

.pv-noise {
  position: fixed;
  inset: 0;
  z-index: 1;
  opacity: 0.06;
  pointer-events: none;
  background-image: url("/assets/noise-DuQlsAyU.gif");
}

.pv-vignette {
  position: fixed;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0) 22%, rgba(0, 0, 0, 0.72) 86%);
}

.pv-scanline {
  position: fixed;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  opacity: 0.09;
  background-image: repeating-linear-gradient(
    to bottom,
    rgba(217, 217, 214, 0.1) 0,
    rgba(217, 217, 214, 0.1) 1px,
    transparent 1px,
    transparent 3px
  );
}

.pv-grid {
  position: fixed;
  left: -10%;
  right: -10%;
  bottom: -8%;
  height: 40vh;
  z-index: 4;
  pointer-events: none;
  background:
    linear-gradient(to top, rgba(0, 0, 0, 0.9), rgba(0, 0, 0, 0.08) 65%, rgba(0, 0, 0, 0) 100%),
    repeating-linear-gradient(to right, rgba(0, 71, 187, 0.28) 0 1px, transparent 1px 60px),
    repeating-linear-gradient(to top, rgba(172, 79, 198, 0.24) 0 1px, transparent 1px 56px);
  transform-origin: center bottom;
  transform: perspective(600px) rotateX(71deg);
  animation: pv-grid-drift calc(11s * var(--pv-motion)) linear infinite;
}

.pv-layout {
  position: relative;
  z-index: 8;
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: clamp(10px, 1.2vw, 18px);
  padding: clamp(12px, 2vw, 28px);
}

/* ============================ 4. TYPOGRAPHIE ============================ */
.pv-title {
  margin: 0;
  font-family: var(--pv-font-display);
  font-size: clamp(16px, 2vw, 26px);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--pv-white);
  text-shadow: 0 0 14px rgba(0, 71, 187, 0.5), 0 0 8px rgba(172, 79, 198, 0.45);
}

.pv-title a { color: inherit; text-decoration: none; }

.pv-subtitle {
  margin: 5px 0 0;
  color: var(--pv-grey);
  font-size: clamp(12px, 1.1vw, 14px);
}

/* Petit libellé orange en capitales (titre d'un bloc d'info) */
.pv-label {
  margin: 0 0 6px;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 130, 0, 0.82);
  text-shadow: 0 0 4px rgba(255, 130, 0, 0.4);
}

.pv-text {
  margin: 0;
  font-size: 11px;
  line-height: 1.5;
  color: var(--pv-grey-text);
}

/* ============================ 5. COMPOSANTS ============================ */
.pv-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

/* Capsule "verre" : hint, légende, badge */
.pv-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  font-size: 12px;
  color: var(--pv-grey);
  border: 1px solid var(--pv-grey-line);
  border-radius: var(--pv-radius);
  background: var(--pv-grad-glass);
}

.pv-hint {
  font-size: clamp(11px, 1vw, 13px);
  padding: 8px 12px;
  color: var(--pv-grey);
  border: 1px solid rgba(217, 217, 214, 0.35);
  border-radius: var(--pv-radius);
  background: linear-gradient(135deg, rgba(0, 71, 187, 0.28), rgba(172, 79, 198, 0.2));
}

.pv-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

.pv-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  background: var(--pv-blue);
}
.pv-dot.violet { background: var(--pv-violet); }
.pv-dot.orange { background: var(--pv-orange); }
.pv-dot.green  { background: var(--pv-green); }

/* Bouton : orbe circulaire (action principale) */
.pv-orb {
  --pv-orb-size: 86px;
  --pv-orb-bg: rgba(0, 71, 187, 0.24);
  --pv-orb-glow: rgba(0, 71, 187, 0.45);
  position: relative;
  width: var(--pv-orb-size);
  height: var(--pv-orb-size);
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid rgba(217, 217, 214, 0.45);
  background: var(--pv-grad-sheen), var(--pv-orb-bg);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.06) inset, 0 0 24px var(--pv-orb-glow);
  color: var(--pv-white);
  font: 700 10px/1.12 var(--pv-font-body);
  letter-spacing: 0.05em;
  text-align: center;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  backdrop-filter: blur(7px);
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.pv-orb:hover,
.pv-orb:focus-visible {
  outline: none;
  color: var(--pv-white);
  transform: scale(1.12);
  background:
    radial-gradient(circle at 30% 28%, rgba(255, 255, 255, 0.33), rgba(255, 255, 255, 0) 45%),
    linear-gradient(135deg, rgba(0, 71, 187, 0.45), rgba(172, 79, 198, 0.4));
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.22) inset,
    0 0 24px rgba(0, 71, 187, 0.55),
    0 0 28px rgba(172, 79, 198, 0.45);
}

.pv-orb::before {
  content: "";
  position: absolute;
  inset: -7px;
  border-radius: 50%;
  border: 1px solid rgba(0, 71, 187, 0);
  pointer-events: none;
}
.pv-orb:hover::before,
.pv-orb:focus-visible::before { animation: pv-satellite-pulse 1.2s ease-in-out infinite; }

.pv-orb.green {
  --pv-orb-size: 40px;
  border-color: rgba(120, 255, 160, 0.52);
  background: var(--pv-grad-sheen), linear-gradient(135deg, rgba(0, 90, 70, 0.55), rgba(35, 190, 120, 0.42));
  box-shadow: 0 0 0 1px rgba(120, 255, 160, 0.16) inset, 0 0 18px rgba(60, 220, 130, 0.28);
}

/* Firefox : backdrop-filter + ancêtre animé = élément invisible. On le coupe. */
@supports (-moz-appearance: none) {
  .pv-orb { backdrop-filter: none; background: var(--pv-grad-sheen), var(--pv-orb-bg), rgba(0, 0, 0, 0.35); }
}

/* Bouton rectangulaire (formulaires, CTA) */
.pv-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 16px;
  font: 700 12px var(--pv-font-body);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--pv-white);
  cursor: pointer;
  border: 1px solid var(--pv-grey-line);
  border-radius: var(--pv-radius);
  background: var(--pv-grad-glass);
  transition: background 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.pv-btn:hover,
.pv-btn:focus-visible {
  outline: none;
  color: var(--pv-white);
  background: var(--pv-grad-glass-hover);
  border-color: rgba(255, 255, 255, 0.5);
  box-shadow: 0 0 18px rgba(0, 71, 187, 0.5), 0 0 22px rgba(172, 79, 198, 0.35);
}
.pv-btn:focus-visible { outline: 1px solid rgba(255, 130, 0, 0.88); outline-offset: 2px; }
.pv-btn:disabled { opacity: 0.35; cursor: not-allowed; }
.pv-btn.primary { background: var(--pv-grad-solid); border-color: transparent; }

/* Champs de formulaire */
.pv-input {
  width: 100%;
  padding: 9px 10px;
  font: 13px var(--pv-font-body);
  color: var(--pv-white);
  border: 1px solid var(--pv-blue-a);
  border-radius: var(--pv-radius-sm);
  background: rgba(0, 0, 0, 0.55);
}
.pv-input:focus { outline: none; border-color: var(--pv-orange); box-shadow: 0 0 10px rgba(255, 130, 0, 0.3); }
.pv-input::placeholder { color: rgba(217, 217, 214, 0.45); }

/* Panneau rétro-futuriste (HUD) */
.pv-panel {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-family: var(--pv-font-body);
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.92) 0%, rgba(10, 10, 20, 0.95) 100%);
  border: 2px solid rgba(0, 71, 187, 0.78);
  box-shadow: 0 0 48px rgba(0, 71, 187, 0.35), inset 1px 1px 12px rgba(255, 130, 0, 0.12);
  backdrop-filter: blur(8px);
}

.pv-panel-header,
.pv-panel-footer {
  padding: 12px 16px;
  flex-shrink: 0;
}
.pv-panel-header {
  border-bottom: 1px solid var(--pv-blue-a);
  background: linear-gradient(to bottom, rgba(0, 71, 187, 0.15), rgba(0, 0, 0, 0.3));
}
.pv-panel-footer {
  border-top: 1px solid var(--pv-blue-a);
  background: linear-gradient(to top, rgba(0, 71, 187, 0.15), rgba(0, 0, 0, 0.3));
  text-align: center;
  font-size: 9px;
  letter-spacing: 0.1em;
}
.pv-panel-title {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-shadow: 0 0 8px rgba(0, 71, 187, 0.5);
}
.pv-panel-scanline {
  height: 1px;
  margin-top: 6px;
  background: linear-gradient(to right, transparent, rgba(0, 71, 187, 0.5), transparent);
}
.pv-panel-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 71, 187, 0.5) rgba(0, 0, 0, 0.2);
}
.pv-panel-body::-webkit-scrollbar { width: 6px; }
.pv-panel-body::-webkit-scrollbar-track { background: rgba(0, 0, 0, 0.2); }
.pv-panel-body::-webkit-scrollbar-thumb { background: rgba(0, 71, 187, 0.5); border-radius: 3px; }

/* Bloc d'information à l'intérieur d'un panneau */
.pv-item {
  margin-bottom: 16px;
  padding: 12px;
  border: 1px solid rgba(0, 71, 187, 0.35);
  border-radius: 2px;
  background: linear-gradient(135deg, rgba(0, 71, 187, 0.08), rgba(172, 79, 198, 0.05));
  box-shadow: inset 0 0 8px rgba(0, 71, 187, 0.12), 0 0 8px rgba(0, 71, 187, 0.2);
}

/* Statut "en ligne" */
.pv-status {
  color: rgba(0, 255, 0, 0.78);
  text-shadow: 0 0 6px rgba(0, 255, 0, 0.5);
  animation: pv-status-pulse 1.2s ease-in-out infinite;
}

.pv-pill-online {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 6px;
  border-radius: 999px;
  border: 1px solid rgba(120, 255, 120, 0.35);
  background: rgba(2, 16, 6, 0.78);
  color: rgba(160, 255, 160, 0.92);
  font-size: 8px;
  letter-spacing: 0.04em;
  text-transform: lowercase;
  box-shadow: 0 0 8px rgba(48, 255, 90, 0.22);
}
.pv-pill-online::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--pv-online);
  box-shadow: 0 0 8px rgba(53, 255, 111, 0.86);
  animation: pv-status-pulse 1.2s ease-in-out infinite;
}

/* Anneau d'orbite décoratif (tracé uniquement, jamais de fond). Variantes : blue / violet / orange / green */
.pv-ring {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  pointer-events: none;
  border: 1px solid rgba(0, 71, 187, 0.65);
  box-shadow: 0 0 18px rgba(0, 71, 187, 0.3);
}
.pv-ring.violet { border: 1px dashed rgba(172, 79, 198, 0.62); box-shadow: 0 0 16px rgba(172, 79, 198, 0.28); }
.pv-ring.orange { border: 1px dotted rgba(255, 130, 0, 0.58);  box-shadow: 0 0 16px rgba(255, 130, 0, 0.24); }
.pv-ring.green  { border: 1px dashed rgba(90, 255, 140, 0.52); box-shadow: 0 0 18px rgba(60, 220, 130, 0.22); }

/* Noyau central (logo) : disque lumineux qui "bat" */
.pv-core {
  position: relative;
  width: min(15vw, 190px);
  min-width: 110px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid rgba(217, 217, 214, 0.4);
  background:
    radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.32), rgba(255, 255, 255, 0) 45%),
    radial-gradient(circle at 74% 70%, rgba(255, 130, 0, 0.27), rgba(0, 0, 0, 0) 56%),
    linear-gradient(150deg, rgba(0, 71, 187, 0.48), rgba(172, 79, 198, 0.38));
  box-shadow: 0 0 48px rgba(0, 71, 187, 0.38), inset 0 0 38px rgba(255, 130, 0, 0.16);
  animation: pv-core-beat 2.2s ease-in-out infinite;
}
.pv-core::before,
.pv-core::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}
.pv-core::before { inset: -16px; border: 1px dashed rgba(172, 79, 198, 0.45); animation: pv-pulse 4.8s ease-in-out infinite; }
.pv-core::after  { inset: -8px;  border: 1px solid rgba(0, 71, 187, 0.45); opacity: 0.5; animation: pv-core-aura 2.2s ease-in-out infinite; }
.pv-core img { width: 48%; filter: brightness(0) invert(1) drop-shadow(0 8px 24px rgba(0, 71, 187, 0.52)); }

/* Décor HUD : crochets d'angle + texte système. À placer dans un parent position:relative. */
.pv-bracket {
  position: absolute;
  width: 30px;
  height: 30px;
  pointer-events: none;
}
.pv-bracket::before,
.pv-bracket::after { content: ""; position: absolute; background: rgba(0, 71, 187, 0.65); }
.pv-bracket::before { height: 2px; left: 0; right: 0; }
.pv-bracket::after  { width: 2px; top: 0; bottom: 0; }
.pv-bracket.tl { top: 3%; left: 3%; }     .pv-bracket.tl::before { top: 0; }    .pv-bracket.tl::after { left: 0; }
.pv-bracket.tr { top: 3%; right: 3%; }    .pv-bracket.tr::before { top: 0; }    .pv-bracket.tr::after { right: 0; }
.pv-bracket.bl { bottom: 3%; left: 3%; } .pv-bracket.bl::before { bottom: 0; } .pv-bracket.bl::after { left: 0; }
.pv-bracket.br { bottom: 3%; right: 3%; } .pv-bracket.br::before { bottom: 0; } .pv-bracket.br::after { right: 0; }

.pv-hud-label {
  position: absolute;
  font-size: 8px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  white-space: nowrap;
  color: rgba(0, 71, 187, 0.6);
  pointer-events: none;
}
.pv-hud-label.tl { top: calc(3% + 12px); left: calc(3% + 6px); }
.pv-hud-label.tr { top: calc(3% + 12px); right: calc(3% + 6px); }
.pv-hud-label.bl { bottom: calc(3% + 12px); left: calc(3% + 6px); }
.pv-hud-label.br { bottom: calc(3% + 12px); right: calc(3% + 6px); }

.pv-blink { display: inline-block; animation: pv-blink 1.2s step-end infinite; }

/* Pied de page légal discret, fixé en bas à gauche */
.pv-footer {
  position: fixed;
  left: 8px;
  bottom: 8px;
  z-index: 10;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: var(--pv-radius-sm);
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(217, 217, 214, 0.18);
  backdrop-filter: blur(4px);
  font-size: clamp(8px, 0.65vw, 10px);
  letter-spacing: 0.03em;
  color: rgba(217, 217, 214, 0.72);
  opacity: 0.68;
  transition: opacity 0.2s ease, border-color 0.2s ease;
}
.pv-footer:hover,
.pv-footer:focus-within { opacity: 0.9; border-color: rgba(217, 217, 214, 0.32); }
.pv-footer a {
  color: rgba(217, 217, 214, 0.74);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}
.pv-footer a:hover,
.pv-footer a:focus-visible { color: rgba(255, 255, 255, 0.94); border-bottom-color: rgba(255, 130, 0, 0.65); outline: none; }

/* ============================ 6. KEYFRAMES ============================ */
@keyframes pv-spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
@keyframes pv-pulse { 0%, 100% { opacity: 0.55; transform: scale(1); } 50% { opacity: 0.95; transform: scale(1.035); } }
@keyframes pv-blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }
@keyframes pv-status-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }
@keyframes pv-core-aura { 0%, 100% { transform: scale(1); opacity: 0.45; } 50% { transform: scale(1.045); opacity: 0.82; } }
@keyframes pv-core-beat {
  0%, 100% { transform: scale(1); }
  14% { transform: scale(1.025); }
  28% { transform: scale(1); }
  42% { transform: scale(1.04); }
  56% { transform: scale(1); }
}
@keyframes pv-grid-drift {
  from { background-position: 0 0, 0 0, 0 0; }
  to { background-position: 0 0, 120px 0, 0 -84px; }
}
@keyframes pv-satellite-pulse {
  0%   { border-color: rgba(0, 71, 187, 0.18); box-shadow: 0 0 0 0 rgba(172, 79, 198, 0.35), 0 0 0 0 rgba(0, 71, 187, 0.25); }
  70%  { border-color: rgba(0, 71, 187, 0.92); box-shadow: 0 0 0 9px rgba(172, 79, 198, 0), 0 0 24px 4px rgba(0, 71, 187, 0.52); }
  100% { border-color: rgba(172, 79, 198, 0.26); box-shadow: 0 0 0 0 rgba(172, 79, 198, 0), 0 0 0 0 rgba(0, 71, 187, 0); }
}

/* ============================ 7. PERFORMANCE / ACCESSIBILITÉ ============================ */
/* body.pv-lite : à poser en JS si FPS bas. Coupe les effets coûteux. */
body.pv-lite .pv-noise { opacity: 0.025; }
body.pv-lite .pv-scanline { opacity: 0; }
body.pv-lite .pv-orb { backdrop-filter: none; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.05) inset, 0 0 16px var(--pv-orb-glow); }
body.pv-lite .pv-ring { box-shadow: none; }

@media (prefers-reduced-motion: reduce) {
  .pv-grid, .pv-core, .pv-core::before, .pv-core::after, .pv-status, .pv-blink { animation: none; }
  .pv-scanline { opacity: 0; }
}

/* ============================ 8. RESPONSIVE ============================ */
@media (max-width: 900px) {
  .pv-layout { padding: 6vw 2vw 4vw; }
  .pv-orb { --pv-orb-size: 64px; font-size: 9px; }
  .pv-core { width: min(36vw, 170px); }
  .pv-legend { font-size: 11px; gap: 6px; }
}

@media (max-width: 700px) {
  .pv-topbar { flex-direction: column; align-items: flex-start; gap: 8px; }
  .pv-title { font-size: 18px; }
  .pv-subtitle { font-size: 11px; }
  .pv-hint { font-size: 10px; padding: 6px 8px; }
}
/* Polices de la charte Printiverse, hébergées avec le site (aucune requête vers Google : rien n'est transmis sur les visiteurs,
   et la politique de sécurité du site reste stricte). Michroma (Vernon Adams) et Share Tech Mono (Carrois Apostrophe) :
   licence SIL Open Font License 1.1. */
@font-face {
  font-family: 'Michroma';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/assets/michroma-latin-4gS0VCia.woff2') format('woff2');
}
@font-face {
  font-family: 'Share Tech Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/assets/share-tech-mono-latin-CCqdbj5z.woff2') format('woff2');
}
/* Site client à la charte Printiverse (printiverse-design/, voir DESIGN.md).
   Les couleurs, polices et composants viennent de printiverse-design.css (jetons --pv-*, classes .pv-*).
   Ce fichier ne fait que placer les blocs et habiller la galerie, composant partagé avec l'outil local. */

/* --- mise en page --------------------------------------------------------------------------------------------------- */

/* Blocs d'information (.pv-item de la charte) : coins plus arrondis et fond bleu plus marqué que dans printiverse-design.css,
   qui n'est pas modifié (même sélecteur, placé après la charte : ces valeurs l'emportent) */
.pv-item {
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(0, 71, 187, 0.48), rgba(172, 79, 198, 0.05));
}

.pv-layout.client {
  padding-bottom: 56px; /* place pour les mentions fixées en bas à gauche */
}

/* En-tête : logo Printiverse en haut à gauche, devant le nom */
.client-brand {
  display: flex;
  align-items: center;
  gap: clamp(10px, 1.2vw, 16px);
}
.client-logo {
  flex: none;
  width: clamp(40px, 4.2vw, 58px);
  aspect-ratio: 1;
  filter: brightness(0) invert(1) drop-shadow(0 0 10px rgba(0, 71, 187, 0.7)); /* blanc, comme le logotype de .pv-core */
}

/* Zone encadrée par le décor HUD (crochets et libellés aux quatre coins) */
.client-stage {
  position: relative;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 28px;
  padding: 56px 24px;
}
.client-hud {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.client-note {
  margin: 24px 0;
  font-size: 12px;
  text-align: center;
}
.client-error {
  margin: 0 0 14px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--pv-orange);
}

/* --- connexion ------------------------------------------------------------------------------------------------------ */
.client-login {
  width: min(360px, 92vw);
}
.client-login .pv-text {
  margin-bottom: 16px;
  font-size: 12px;
}
.client-login .pv-label {
  display: block;
}
.client-login .pv-input {
  margin-bottom: 14px;
}
.client-login .pv-btn {
  width: 100%;
  margin-top: 4px;
  padding: 11px 16px;
}

/* --- espace du client ----------------------------------------------------------------------------------------------- */
.client-session {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}
.client-content {
  display: grid;
  align-content: start;
  gap: clamp(14px, 2vw, 24px);
  width: 100%;
  max-width: 1180px;
  min-width: 0;
  margin: 0 auto;
}
.client-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.client-tabs small {
  margin-left: 0.5em;
  opacity: 0.7;
}

.client-summary {
  gap: 22px;
  padding: 52px 24px 46px;
}
.client-project-title {
  font-size: clamp(18px, 3vw, 34px);
  text-align: center;
  overflow-wrap: anywhere;
}
.client-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(8px, 1.5vw, 18px);
  width: min(900px, 100%);
  margin: 0;
}
.client-stats .pv-item {
  margin: 0;
  padding: 16px 8px;
}
.client-stats .pv-label {
  margin-bottom: 8px;
}
.client-number {
  margin: 0;
  font-family: var(--pv-font-display);
  font-size: clamp(18px, 3.4vw, 25px);
  letter-spacing: 0.06em;
  color: var(--pv-white);
  text-shadow: 0 0 14px rgba(0, 71, 187, 0.5), 0 0 8px rgba(172, 79, 198, 0.45); /* lueur de .pv-title */
}

/* Panneaux de contenu : grands, posés sur le fond animé. Pas de flou d'arrière-plan (coûteux sur une telle surface, pour un fond
   presque opaque) ; la galerie n'est pas rognée, pour que les cartes puissent s'incliner et se retourner jusqu'au bord. */
.client-gallery.pv-panel,
.client-rates.pv-panel {
  backdrop-filter: none;
}
.client-gallery.pv-panel {
  overflow: visible;
}
.client-gallery .pv-panel-body {
  overflow: visible;
  padding: clamp(12px, 2vw, 24px);
}

/* --- taux de drop par rareté ---------------------------------------------------------------------------------------- */
.client-rates ul {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.client-rates li.pv-item {
  display: grid;
  grid-template-columns: minmax(8rem, 1.1fr) minmax(4rem, 2fr) minmax(11rem, 1.5fr);
  align-items: center;
  gap: 6px 18px;
  margin: 0;
  padding: 10px 14px;
}
.client-rate-name,
.client-rate-value {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.client-rate-name strong {
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.client-rate-value {
  text-align: right;
}
.client-rate-value strong {
  font-size: 13px;
  letter-spacing: 0.04em;
}
.client-rate-name span,
.client-rate-value span {
  font-size: 11px;
  color: var(--pv-grey-text);
}
/* barre : part des boosters qui contiennent la rareté */
.client-rate-bar {
  height: 6px;
  border-radius: 3px;
  background: rgba(217, 217, 214, 0.12);
}
.client-rate-bar span {
  display: block;
  min-width: 3px;
  height: 100%;
  border-radius: 3px;
  background: var(--pv-grad-solid);
  box-shadow: 0 0 10px rgba(0, 71, 187, 0.6);
}
.client-rates .pv-panel-footer {
  text-transform: uppercase;
  color: var(--pv-grey-text);
}

/* --- partage de la galerie ------------------------------------------------------------------------------------------ */
.client-share {
  margin: 0 0 clamp(18px, 3vw, 30px);
}
.client-share .pv-text {
  margin-bottom: 10px;
  font-size: 12px;
}
.client-share-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.client-share-row .pv-text,
.client-share-row .pv-input {
  flex: 1 1 18rem;
  width: auto;
  margin: 0;
}
.client-share-title {
  margin-bottom: 12px;
}
.client-share-title .pv-label {
  display: block;
  margin-bottom: 6px;
}
.client-share .client-share-note {
  margin: 8px 0 0;
  color: var(--pv-grey);
}
.client-share .client-share-note:empty {
  display: none;
}

/* --- galerie des cartes (classes de src/Gallery.css, rhabillées avec les jetons de la charte) ----------------------- */
.client .gallery-tools {
  gap: 10px 18px;
  margin-bottom: 14px;
}
.client .gallery-tools input[type='search'] {
  /* = .pv-input */
  min-width: min(16rem, 100%);
  padding: 9px 10px;
  font: 13px var(--pv-font-body);
  color: var(--pv-white);
  border: 1px solid var(--pv-blue-a);
  border-radius: var(--pv-radius-sm);
  background: rgba(0, 0, 0, 0.55);
}
.client .gallery-tools input[type='search']:focus {
  outline: none;
  border-color: var(--pv-orange);
  box-shadow: 0 0 10px rgba(255, 130, 0, 0.3);
}
.client .gallery-tools input[type='search']::placeholder {
  color: rgba(217, 217, 214, 0.45);
}
.client .gallery-size,
.client .gallery-count {
  font-size: 12px;
  letter-spacing: 0.05em;
  color: var(--pv-grey-text);
}
.client .gallery-size input {
  accent-color: var(--pv-blue);
}

.client .chip {
  /* = .pv-chip, avec le survol de .pv-btn */
  padding: 6px 10px;
  font: 12px var(--pv-font-body);
  color: var(--pv-grey);
  border: 1px solid var(--pv-grey-line);
  border-radius: var(--pv-radius);
  background: var(--pv-grad-glass);
  transition: background 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.client .chip:hover,
.client .chip:focus-visible {
  color: var(--pv-white);
  background: var(--pv-grad-glass-hover);
  border-color: rgba(255, 255, 255, 0.5);
  box-shadow: 0 0 18px rgba(0, 71, 187, 0.5), 0 0 22px rgba(172, 79, 198, 0.35);
}
.client .chip:focus-visible {
  outline: 1px solid rgba(255, 130, 0, 0.88);
  outline-offset: 2px;
}
.client .chip.reset {
  border-style: dashed;
}

/* Raretés bien séparées : un trait lumineux et de l'espace entre deux raretés, puis un bandeau numéroté par rareté */
.client .gallery {
  counter-reset: rarity;
}
.client .gallery-group {
  counter-increment: rarity;
  margin: 0 0 clamp(36px, 5vw, 60px);
  padding-top: clamp(20px, 3vw, 32px);
  border-top: 1px solid;
  border-image: linear-gradient(to right, transparent, rgba(0, 71, 187, 0.75), rgba(172, 79, 198, 0.65), transparent) 1;
}
.client .gallery-group:last-of-type {
  margin-bottom: 0;
}
.client .gallery-group h3 {
  flex-wrap: wrap;
  gap: 8px 14px;
  margin: 0 0 16px;
  padding: 12px 16px;
  font: 400 12px var(--pv-font-body);
  border: 1px solid var(--pv-grey-line);
  border-left: 3px solid var(--pv-blue);
  border-radius: var(--pv-radius-sm);
  background: var(--pv-grad-glass);
  box-shadow: 0 0 18px rgba(0, 71, 187, 0.25);
}
.client .gallery-group h3::before {
  /* = .pv-label */
  content: counter(rarity, decimal-leading-zero);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.12em;
  color: rgba(255, 130, 0, 0.82);
  text-shadow: 0 0 4px rgba(255, 130, 0, 0.4);
}
.client .gallery-group-name {
  font-family: var(--pv-font-display);
  font-size: clamp(14px, 1.6vw, 18px);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-shadow: 0 0 14px rgba(0, 71, 187, 0.5), 0 0 8px rgba(172, 79, 198, 0.45); /* lueur de .pv-title */
  overflow-wrap: anywhere;
}
.client .gallery-group h3 small {
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--pv-grey-text);
}
.client-rate-chip {
  margin-left: auto;
  padding: 4px 10px;
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--pv-white);
  border: 1px solid var(--pv-grey-line);
  border-radius: var(--pv-radius-sm);
  background: rgba(0, 0, 0, 0.4);
}
.client .gallery-effect {
  margin: -6px 0 16px 4px;
  font-size: 12px;
  color: var(--pv-grey-text);
}
.client .fx-badge {
  padding: 3px 8px;
  border-radius: var(--pv-radius-sm);
  font: 700 10px var(--pv-font-body);
  letter-spacing: 0.1em;
  text-shadow: none;
}
.client .gallery-grid figcaption {
  font-size: 11px;
  letter-spacing: 0.03em;
  color: var(--pv-grey-text);
}
.client .gallery-more,
.client .gallery-empty {
  font-size: 12px;
  color: var(--pv-grey-text);
}
.client .gallery-error {
  color: var(--pv-orange);
}

/* Cartes : lueur colorée au lieu d'une ombre noire ; elles s'illuminent quand on les survole.
   Chaque carte vit dans une case au rendu isolé (content-visibility dans Gallery.css, pour la fluidité), qui rogne ce qui en
   dépasse : une marge intérieure laisse la place à la lueur, et la carte survolée sort de sa case pour s'incliner, se retourner
   et s'illuminer sans être coupée. */
.client .gallery-grid {
  --card-room: 10px;
  gap: 6px 1px; /* avec les marges intérieures : le même espacement qu'avant entre les cartes */
  margin: 0 calc(-1 * var(--card-room));
}
.client .gallery-grid figure {
  padding: var(--card-room);
}
.client .gallery-grid figure:has(.holo[data-live='true']) {
  position: relative;
  z-index: 1;
  content-visibility: visible;
}
.client .holo:focus-visible {
  outline: 1px solid rgba(255, 130, 0, 0.88);
}
.client .holo-face {
  background: rgba(0, 0, 0, 0.55);
  box-shadow: 0 0 var(--card-room) rgba(0, 71, 187, 0.35);
  transition: opacity 0s linear var(--flip-half), box-shadow 0.25s ease; /* opacité : bascule recto/verso de Gallery.css, à conserver */
}
.client .holo[data-live='true'] .holo-face {
  box-shadow: 0 0 24px rgba(0, 71, 187, 0.55), 0 0 28px rgba(172, 79, 198, 0.45);
}
.client .holo-missing {
  border: 1px dashed var(--pv-grey-line);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pv-orange);
}

/* --- petits écrans -------------------------------------------------------------------------------------------------- */
@media (max-width: 700px) {
  .client-stage {
    padding: 56px 12px;
  }
  .client-session {
    justify-content: flex-start;
  }
  .client-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  /* taux : nom et valeur sur une ligne, barre en dessous sur toute la largeur */
  .client-rates li.pv-item {
    grid-template-columns: 1fr 1fr;
  }
  .client-rate-bar {
    grid-column: 1 / -1;
    grid-row: 2;
  }
  .client-rate-chip {
    margin-left: 0;
  }
  /* en dessous de 16px, iOS zoome sur le champ à la saisie */
  .client .pv-input,
  .client .gallery-tools input[type='search'] {
    font-size: 16px;
  }
}
@media (max-width: 620px) {
  /* galerie sur 2 colonnes (Gallery.css) : cartes plus serrées */
  .client .gallery-grid {
    --card-room: 6px;
    gap: 7px 1px;
  }
}
/* Simulateur Printicards : mise en page à la charte Printiverse (jetons --pv-*, classes .pv-*, voir design/DESIGN.md).
   Placé après printiverse-design.css et client.css (habillage de la galerie du kit). */

/* --- général ------------------------------------------------------------------------------------------------------- */
.pv-input {
  color-scheme: dark; /* calendrier, listes : widgets natifs en thème sombre */
}
select.pv-input option {
  color: var(--pv-white);
  background: #05050c;
}
select.pv-input:disabled,
.pv-input:disabled {
  opacity: 0.45;
}
textarea.pv-input {
  resize: vertical;
  min-height: 70px;
}
.pv-chip input,
.import-option input {
  accent-color: var(--pv-blue);
}
a {
  color: var(--pv-grey);
}
a:hover,
a:focus-visible {
  color: var(--pv-orange);
}
.app-link {
  padding: 0;
  font: 12px var(--pv-font-body);
  letter-spacing: 0.04em;
  color: var(--pv-grey);
  text-decoration: underline;
  text-decoration-color: rgba(217, 217, 214, 0.35);
  text-underline-offset: 3px;
  background: none;
  border: 0;
  cursor: pointer;
}
.app-link:hover,
.app-link:focus-visible {
  color: var(--pv-orange);
  outline: none;
}
.app-link:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}
.app-wide {
  width: 100%;
}
.app-form {
  display: grid;
  gap: 6px;
}
.app-form .pv-label {
  margin-top: 8px;
}
.app-form .pv-btn {
  margin-top: 12px;
}
.app-switch {
  margin-top: 10px;
  text-align: center;
}

/* --- en-tête ------------------------------------------------------------------------------------------------------- */
.app-topbar {
  flex-wrap: wrap;
}
.app-topbar .client-brand {
  text-decoration: none;
}
.app-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.app-user {
  text-decoration: none;
}
.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.lang-flag {
  display: inline-flex;
  width: 26px;
  height: 18px;
  padding: 0;
  overflow: hidden;
  border: 1px solid transparent;
  border-radius: 3px;
  background: transparent;
  cursor: pointer;
  opacity: 0.5;
}
.lang-flag svg {
  display: block;
  width: 100%;
  height: 100%;
}
.lang-flag[aria-pressed='true'] {
  border-color: var(--pv-orange);
  opacity: 1;
}
.lang-flag:focus-visible {
  outline: 2px solid var(--pv-orange);
  outline-offset: 2px;
}
.app-content {
  display: grid;
  align-content: start;
  gap: clamp(14px, 2vw, 24px);
  width: 100%;
  max-width: 1320px;
  min-width: 0;
  margin: 0 auto;
}
.app-page {
  backdrop-filter: none;
}
.app-page.account {
  width: min(520px, 100%);
  margin: 0 auto;
}

/* --- simulateur ---------------------------------------------------------------------------------------------------- */
.editor {
  display: grid;
  grid-template-columns: minmax(330px, 420px) minmax(0, 1fr);
  gap: clamp(14px, 2vw, 24px);
  align-items: start;
}
.editor[hidden] {
  display: none;
}
.editor-panel {
  backdrop-filter: none;
  max-height: calc(100vh - 150px);
  position: sticky;
  top: 12px;
}
.editor-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.pv-btn.editor-new {
  padding: 4px 10px;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-decoration: none;
}

/* Simulateur en pleine page : la page ne défile pas, seul le configurateur (corps du panneau de gauche) défile ; la carte
   prend la place disponible dans la scène (unités de conteneur). */
.app-fullpage {
  height: 100vh;
  height: 100dvh;
  min-height: 0;
  overflow: hidden;
}
.app-fullpage .app-content {
  min-height: 0;
  grid-template-rows: minmax(0, 1fr);
}
.app-fullpage .editor {
  min-height: 0;
  height: 100%;
  align-items: stretch;
}
.app-fullpage .editor-panel {
  position: static;
  max-height: none;
  min-height: 0;
}
.app-fullpage .editor-stage {
  min-height: 0;
  overflow: hidden;
  gap: 12px;
  padding: 44px 24px 20px;
  container-type: size;
}
/* hauteur disponible moins ce qui suit la carte : outils, texte d'exemple, état et leurs écarts (~115 px) */
.app-fullpage .editor-card {
  width: min(420px, 100cqw - 48px, (100cqh - 115px) * var(--card-ratio, 63 / 88));
}
.editor-row {
  margin-bottom: 12px;
}
.editor-corners {
  margin-top: 8px;
  cursor: pointer;
}

/* Masques stockés blanc = zone active, affichés comme le fichier du client : noir = zone de l'effet */
.mask-thumb {
  filter: invert(1);
}

/* Infobulles réglées par l'administrateur (Tip.jsx) */
.tip {
  display: inline-flex;
  vertical-align: middle;
  margin-left: 6px;
}
.tip-icon {
  display: inline-grid;
  place-items: center;
  width: 15px;
  height: 15px;
  padding: 0;
  font: italic 700 10px/1 Georgia, serif;
  color: var(--pv-grey);
  text-transform: none;
  letter-spacing: 0;
  cursor: help;
  background: rgba(0, 71, 187, 0.35);
  border: 1px solid rgba(217, 217, 214, 0.45);
  border-radius: 50%;
}
.tip-icon:hover,
.tip-icon:focus-visible,
.tip-icon[aria-expanded='true'] {
  outline: none;
  color: var(--pv-white);
  border-color: var(--pv-orange);
}
.tip-bubble {
  position: fixed;
  z-index: 950;
  width: max-content;
  max-width: 260px;
  padding: 8px 10px;
  font: 12px/1.45 var(--pv-font-body);
  letter-spacing: 0.02em;
  text-transform: none;
  white-space: pre-line;
  color: var(--pv-white);
  background: rgba(8, 10, 24, 0.97);
  border: 1px solid var(--pv-blue-a);
  border-radius: var(--pv-radius-sm);
  box-shadow: 0 0 16px rgba(0, 71, 187, 0.45);
  pointer-events: none;
}
.editor-row .pv-label,
.editor-grid2 .pv-label {
  display: block;
}
.editor-help {
  margin-top: 8px;
  font-size: 11px;
}
.editor-import {
  margin: 4px 0 14px;
}
.editor-import-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.editor-import-buttons .pv-btn {
  flex: 1 1 auto;
  padding: 8px 10px;
  font-size: 11px;
}
.editor-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}
.editor-grid2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
  margin: 12px 0;
}
.editor-remove-back {
  margin-bottom: 12px;
}
.editor-sources {
  margin: 12px 0 0;
}
.editor-sources ul {
  display: grid;
  gap: 4px;
  margin: 6px 0 8px;
  padding: 0;
  list-style: none;
  font-size: 12px;
}
.editor-sources li {
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
}
.editor-sources li span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.editor-sources small {
  flex: none;
  color: var(--pv-grey-text);
}
.editor-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px 10px;
}
.editor-actions .pv-btn {
  padding: 8px 12px;
}

/* Cases des couches (comme Ribi Holo) */
.slots {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.slot {
  display: grid;
  gap: 6px;
  min-width: 0;
}
.slot-drop {
  display: grid;
  place-items: center;
  aspect-ratio: 63 / 88;
  padding: 0;
  overflow: hidden;
  color: var(--pv-grey-text);
  cursor: pointer;
  border: 1px dashed var(--pv-grey-line);
  border-radius: var(--pv-radius-sm);
  background: rgba(0, 0, 0, 0.55);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
.slot:not(.is-empty) .slot-drop {
  border-style: solid;
  border-color: var(--pv-blue-a);
}
.slot-drop:hover,
.slot-drop:focus-visible,
.slot.is-over .slot-drop {
  outline: none;
  border-color: var(--pv-orange);
  box-shadow: 0 0 12px rgba(255, 130, 0, 0.3);
}
.slot-drop[aria-disabled='true'] {
  cursor: wait;
}
.slot-drop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.slot-drop[draggable='true'] {
  cursor: grab;
}
.slot-plus {
  font: 24px var(--pv-font-display);
  color: rgba(217, 217, 214, 0.5);
}
.slot-meta {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.slot-name {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--pv-white);
}
.slot-info {
  overflow: hidden;
  font-size: 10px;
  white-space: nowrap;
  text-overflow: ellipsis;
  color: var(--pv-grey-text);
}
.slot-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 2px 8px;
}
.slot-actions .app-link {
  font-size: 10px;
}

/* Scène : carte en grand au centre du décor HUD */
.editor-stage {
  min-height: min(82vh, 900px);
  gap: 18px;
  padding: 64px 24px 48px;
}
.editor-card {
  position: relative;
  width: min(420px, 78vw, calc((82vh - 190px) * var(--card-ratio, 63 / 88)));
}
.editor-card .holo-face {
  box-shadow: 0 0 24px rgba(0, 71, 187, 0.55), 0 0 28px rgba(172, 79, 198, 0.45);
}
.editor-zoom {
  top: -2.6rem;
  right: 0;
  opacity: 0.85;
}
.editor-stage-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.editor-stage-tools .pv-chip {
  cursor: pointer;
}
.editor-demo {
  max-width: 360px;
  text-align: center;
  color: var(--pv-orange);
}
.editor-status {
  min-height: 1.5em;
  max-width: 520px;
  text-align: center;
}
.editor-status .client-error {
  margin: 0;
}
.editor-ok {
  color: var(--pv-green);
}

/* --- fenêtres modales ---------------------------------------------------------------------------------------------- */
.app-modal {
  position: fixed;
  inset: 0;
  z-index: 900;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(6, 6, 12, 0.82);
}
.app-modal-panel {
  width: min(440px, 100%);
  max-height: calc(100vh - 32px);
  backdrop-filter: none;
}
.app-modal-panel.wide {
  width: min(880px, 100%);
}
.app-modal-panel .pv-panel-header {
  position: relative;
  padding-right: 48px;
}
.app-modal-close {
  position: absolute;
  top: 6px;
  right: 8px;
  width: 32px;
  height: 32px;
  font-size: 22px;
  line-height: 1;
  color: var(--pv-grey);
  cursor: pointer;
  border: 1px solid var(--pv-grey-line);
  border-radius: var(--pv-radius-sm);
  background: rgba(0, 0, 0, 0.4);
}
.app-modal-close:hover,
.app-modal-close:focus-visible {
  color: var(--pv-white);
  border-color: var(--pv-orange);
  outline: none;
}
.app-modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

/* --- assistants d'import ------------------------------------------------------------------------------------------- */
.import-option {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 18px;
  margin: 12px 0;
  font-size: 12px;
}
.import-option .pv-label {
  margin: 0;
}
.import-pages {
  display: grid;
  gap: 12px;
}
.import-page {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 14px;
  margin: 0;
}
.import-page > img {
  width: 100%;
  border: 1px solid var(--pv-grey-line);
  border-radius: var(--pv-radius-sm);
  object-fit: contain;
  background: #fff;
}
.import-page-body .pv-input {
  max-width: 260px;
}
.import-table {
  width: 100%;
  margin-top: 10px;
  border-collapse: collapse;
  font-size: 12px;
}
.import-table th {
  padding: 4px 6px;
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-align: left;
  text-transform: uppercase;
  color: var(--pv-grey-text);
}
.import-table td {
  padding: 4px 6px;
  border-top: 1px solid rgba(217, 217, 214, 0.12);
}
.import-table td:last-child {
  display: flex;
  gap: 6px;
  align-items: center;
}
.import-ink {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.import-ink img {
  width: 26px;
  height: 36px;
  object-fit: cover;
  border: 1px solid var(--pv-grey-line);
}
.import-color {
  flex: none;
  width: 34px;
  height: 30px;
  padding: 0;
  border: 1px solid var(--pv-grey-line);
  background: none;
}
.import-layers {
  display: grid;
  gap: 6px;
  max-height: 52vh;
  margin: 0;
  padding: 0;
  overflow-y: auto;
  list-style: none;
}
.import-layers li {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 110px 170px;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 6px 10px;
}
.import-layers li.is-ignored {
  opacity: 0.55;
}
.import-layers img,
.import-nothumb {
  width: 48px;
  height: 48px;
  object-fit: contain;
  background: repeating-conic-gradient(rgba(217, 217, 214, 0.12) 0% 25%, transparent 0% 50%) 50% / 12px 12px;
}
.import-layer-name {
  overflow: hidden;
  font-size: 12px;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.import-layer-name small {
  color: var(--pv-grey-text);
}

/* --- devis --------------------------------------------------------------------------------------------------------- */
.quote-notice {
  border-color: var(--pv-orange);
}
.quote-notice .pv-label {
  color: var(--pv-orange);
}
.quote-notice .pv-text {
  margin: 0;
  white-space: pre-line;
}
.quote-summary ul {
  margin: 0;
  padding-left: 18px;
  font-size: 12px;
  line-height: 1.6;
}
.quote-list {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.quote-item {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 16px;
  margin: 0;
}
.quote-item > img {
  width: 72px;
  aspect-ratio: 63 / 88;
  object-fit: cover;
  border-radius: 4.5% / 3.2%;
  box-shadow: 0 0 10px rgba(0, 71, 187, 0.35);
}
.quote-item .pv-text {
  margin-top: 4px;
}
.quote-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 12px;
  margin: 0;
  font-size: 13px;
}
.quote-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 8px;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: 1px solid var(--pv-grey-line);
  border-radius: var(--pv-radius-sm);
  background: rgba(0, 0, 0, 0.4);
}
.status-review .pv-dot,
.status-sent .pv-dot {
  background: var(--pv-orange);
}
.status-accepted .pv-dot {
  background: var(--pv-green);
}
.status-declined .pv-dot {
  background: var(--pv-grey);
}
.quote-note {
  padding: 8px 10px;
  border-left: 2px solid var(--pv-orange);
  background: rgba(0, 0, 0, 0.35);
}
.quote-note .pv-label {
  display: block;
}

/* --- administration ------------------------------------------------------------------------------------------------ */
.admin-filter {
  width: auto;
  min-width: 12rem;
}
.admin-search {
  width: auto;
  flex: 1 1 16rem;
  max-width: 28rem;
}
.admin-demo-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
}
.admin-demo-row .pv-input {
  width: auto;
  flex: 1 1 14rem;
  max-width: 24rem;
}
.admin-demo .pv-text + .pv-text {
  margin-top: 8px;
}
.admin-settings .pv-input {
  margin-bottom: 6px;
}
.admin-settings .pv-label {
  display: block;
  margin-top: 8px;
}
.admin-settings-grid {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  margin-top: 10px;
}
.admin-settings-grid .pv-label {
  margin: 0;
}
.admin-settings-grid input[type='range'] {
  flex: 1 1 12rem;
  max-width: 20rem;
  accent-color: var(--pv-orange);
}
.admin-settings-tips {
  margin-top: 16px !important;
}
.admin-tooltips {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 4px 14px;
}
.admin-tooltips > .pv-text {
  grid-column: 1 / -1;
}
.ai-alert-score {
  margin-top: 10px;
  color: var(--pv-orange);
}
.admin-delete {
  margin-left: 12px;
}
.admin-delete:hover,
.admin-delete:focus-visible {
  color: #ff5a5a;
}
.admin-detail {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 20px;
  margin-top: 14px;
}
.admin-card {
  width: 220px;
}
.admin-detail ul {
  margin: 0 0 12px;
  padding-left: 18px;
}
.admin-message {
  margin-bottom: 12px;
  padding: 8px 10px;
  white-space: pre-wrap;
  border-left: 2px solid var(--pv-blue);
  background: rgba(0, 0, 0, 0.35);
}
.admin-files {
  font-size: 12px;
}
.admin-layers {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  margin: 0 0 12px;
  font-size: 11px;
}
.admin-notify {
  align-self: end;
  font-size: 11px;
}
.admin-save {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 10px;
}

/* --- mes cartes ---------------------------------------------------------------------------------------------------- */
.client .gallery-grid figcaption {
  display: grid;
  gap: 3px;
}
.client .gallery-grid figcaption strong {
  font-size: 12px;
  color: var(--pv-white);
}
.mycards-meta {
  font-size: 10px;
}
.mycards-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2px 10px;
}
.mycards-actions .app-link {
  font-size: 11px;
}
.client .gallery-tools .pv-btn {
  margin-left: auto;
}

/* --- petits écrans ------------------------------------------------------------------------------------------------- */
@media (max-width: 900px) {
  .app-fullpage {
    height: auto;
    min-height: 100vh;
    overflow: visible;
  }
  .app-fullpage .editor-stage {
    container-type: normal;
    padding: 64px 24px 48px;
  }
  .app-fullpage .editor-card {
    width: min(360px, 74vw);
  }
  .editor {
    grid-template-columns: minmax(0, 1fr);
  }
  .editor-stage {
    order: -1;
    min-height: 0;
  }
  .editor-panel {
    position: static;
    max-height: none;
  }
  .editor-card {
    width: min(360px, 74vw);
  }
  .admin-detail {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 620px) {
  .import-layers li {
    grid-template-columns: 40px minmax(0, 1fr);
  }
  .import-layers li .pv-input {
    grid-column: span 1;
  }
  .import-page {
    grid-template-columns: minmax(0, 1fr);
  }
  .import-page > img {
    max-width: 140px;
  }
  .slots {
    gap: 8px;
  }
}
/* Galerie des cartes : effet 3D (inclinaison, reflet, hologramme) écrit pour ce projet. */

.gallery-stage,
.gallery-page {
  background: radial-gradient(circle at 50% 0%, #2a2a3d 0%, #14141c 70%);
  color: #ececf4;
  border-radius: 12px;
}
.gallery-stage {
  padding: 1rem;
  margin-top: 0.6rem;
}
.gallery-page {
  min-height: 100vh;
  max-width: none; /* page entière : pas la colonne de l'outil (main, App.css) */
  margin: 0;
  border-radius: 0;
  padding: 1.5rem clamp(0.8rem, 4vw, 3rem) 3rem;
}
.gallery-page header {
  max-width: 1120px; /* aligné sur la grille des cartes (.gallery) */
  margin: 0 auto;
}
.gallery-page header h1 {
  margin: 0 0 0.2rem;
  font-size: 1.7rem;
  color: #fff;
}
.gallery-page header p {
  margin: 0 0 1rem;
  color: #a8a8c0;
}
.gallery-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem 1.2rem;
  margin-bottom: 0.7rem;
}
.gallery-tools input[type='search'] {
  min-width: 14rem;
  padding: 0.4rem 0.7rem;
  border-radius: 8px;
  border: 1px solid #4a4a63;
  background: #1d1d2a;
  color: inherit;
}
.gallery-size {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: #b9b9d0;
}
.gallery-count {
  font-size: 0.85rem;
  color: #a8a8c0;
}
.gallery-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1rem;
}
.chip {
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  border: 1px solid #5a5a78;
  background: #26263a;
  color: #ececf4;
  font-size: 0.85rem;
  cursor: pointer;
}
.chip small {
  opacity: 0.7;
  margin-left: 0.25rem;
}
.chip.off {
  opacity: 0.45;
  text-decoration: line-through;
}
.chip:disabled {
  opacity: 0.5;
  cursor: wait;
}
.chip.reset {
  border-style: dashed;
}
.verso-box {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.8rem;
  padding: 0.5rem 0.7rem;
  margin-bottom: 0.9rem;
  border: 1px dashed #5a5a78;
  border-radius: 10px;
}
.verso-info {
  font-size: 0.85rem;
  color: #b9b9d0;
}
.gallery-error {
  color: #ff9a9a;
}
.gallery-empty {
  color: #a8a8c0;
}
.gallery-group {
  margin-bottom: 2.2rem;
}
.gallery-group h3 {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 0.3rem;
  font-size: 1.15rem;
  color: #fff;
}
.gallery-group h3 small {
  font-weight: 400;
  color: #a8a8c0;
  font-size: 0.8rem;
}
.gallery-effect {
  margin: 0 0 0.8rem;
  font-size: 0.9rem;
  color: #d8d8ea;
}
.fx-badge {
  padding: 0.1rem 0.55rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
  color: #14141c;
  background: #d0d0e0;
}
.fx-holo {
  background: linear-gradient(100deg, #ff7aa8, #ffd36b, #7dffb5, #6bd0ff, #b08cff);
}
.fx-reverse {
  background: linear-gradient(100deg, #9aa6c8, #ffffff, #6c7aa8);
}
.fx-rainbow {
  background: linear-gradient(100deg, #c0392b, #d68910, #2e9e55, #2a8fbd, #7d3cb5);
}
.fx-cosmos {
  background: linear-gradient(100deg, #5b3fa8, #2a6fb8, #c0489a);
  color: #fff;
}
.fx-gold {
  background: linear-gradient(100deg, #b8862b, #ffe9a0, #c9972b);
}
.fx-shine {
  background: linear-gradient(100deg, #cfd6e4, #ffffff, #cfd6e4);
}
.gallery {
  max-width: 1120px; /* 4 colonnes de cartes de taille confortable, quelle que soit la largeur de l'écran */
  margin: 0 auto;
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.6rem 1.3rem;
}
@media (max-width: 620px) {
  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.2rem 0.8rem;
  }
}
.gallery-more {
  margin: 0.5rem 0 2rem;
  text-align: center;
  font-size: 0.85rem;
  color: #a8a8c0;
}
.gallery-grid figure {
  margin: 0;
  content-visibility: auto; /* les cartes hors écran ne sont ni mises en page ni peintes : défilement fluide même avec des centaines de cartes */
  contain-intrinsic-size: auto 340px;
}
.gallery-grid figcaption {
  margin-top: 0.45rem;
  font-size: 0.78rem;
  line-height: 1.25;
  text-align: center;
  color: #c4c4d8;
  overflow-wrap: anywhere;
}

/* --- zoom ---------------------------------------------------------------------------------------------------------- */
.gallery-card {
  position: relative;
}
/* loupe au coin de la carte : visible au survol ou au clavier ; toujours visible sur écran tactile (pas de survol) */
.gallery-zoom-btn {
  position: absolute;
  top: 0.45rem;
  right: 0.45rem;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 2.1rem;
  height: 2.1rem;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  background: rgba(10, 10, 18, 0.7);
  color: #fff;
  cursor: zoom-in;
  opacity: 0;
  transition: opacity 0.15s ease;
}
.gallery-card:hover .gallery-zoom-btn,
.gallery-card:focus-within .gallery-zoom-btn {
  opacity: 1;
}
@media (hover: none) {
  .gallery-zoom-btn {
    opacity: 0.85;
  }
}
.gallery-zoom {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 0.9rem;
  padding: 1rem;
  background: rgba(6, 6, 12, 0.88);
  cursor: zoom-out;
}
.gallery-zoom-card {
  width: min(92vw, calc((100vh - 7rem) * 63 / 88)); /* la carte entière tient à l'écran, légende comprise */
  cursor: auto;
}
.gallery-zoom .holo[data-live='true'] {
  perspective: 2200px; /* grande carte : inclinaison plus douce qu'avec la perspective de la grille */
}
.gallery-zoom-caption {
  margin: 0;
  max-width: 92vw;
  font-size: 0.9rem;
  text-align: center;
  color: #d8d8ea;
  cursor: auto;
}
.gallery-zoom-close {
  position: fixed;
  top: 0.8rem;
  right: 0.8rem;
  width: 2.6rem;
  height: 2.6rem;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  background: rgba(10, 10, 18, 0.7);
  color: #fff;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
}
.holo-missing {
  display: grid;
  place-items: center;
  aspect-ratio: 63 / 88;
  border: 1px dashed #5a5a78;
  border-radius: 4.5% / 3.2%;
  color: #8e8ea8;
  font-size: 0.8rem;
}

/* --- carte -------------------------------------------------------------------------------------------------------- */
.holo {
  --pointer-x: 50%;
  --pointer-y: 50%;
  --pointer-from-center: 0;
  --pointer-from-top: 0.5;
  --pointer-from-left: 0.5;
  --card-o: 0; /* opacité des effets, écrite au survol par HoloCard.jsx ; holo.css en tire --card-opacity pour chaque couche */
  --background-x: 50%;
  --background-y: 50%;
  --rx: 0deg;
  --ry: 0deg;
  --flip-half: 0.14s; /* instant où le retournement passe à 90° (voir .holo-front, .holo-back) */
  position: relative;
  width: 100%;
  aspect-ratio: 63 / 88;
  outline-offset: 5px;
  touch-action: manipulation;
}
.holo[data-live='true'] {
  perspective: 900px;
}
.holo[data-flippable='true'] {
  cursor: pointer;
}
/* au repos la carte est plate (pas de calque 3D) ; le 3D n'est activé que pour la carte survolée, ciblée ou retournée */
.holo-tilt,
.holo-flip {
  position: absolute;
  inset: 0;
}
.holo[data-live='true'] .holo-tilt,
.holo[data-live='true'] .holo-flip {
  transform-style: preserve-3d;
}
.holo[data-live='true'] .holo-tilt {
  will-change: transform;
}
.holo[data-live='true'][data-motion='true'] .holo-tilt {
  transform: rotateY(var(--ry)) rotateX(var(--rx)); /* variables pilotées image par image par les ressorts (Gallery.jsx) */
}
.holo-flip {
  transition: transform 0.75s cubic-bezier(0.3, 0.8, 0.3, 1);
}
.holo[data-flipped='true'] .holo-flip {
  transform: rotateY(180deg);
}
.holo[data-turning='true'] .holo-flip {
  animation: holo-lift 0.75s ease;
}
@keyframes holo-lift {
  50% {
    scale: 1.1;
  }
}
.holo-face {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: var(--card-radius, 4.5% / 3.2%); /* coins ronds ; 0 pour des coins carrés (HoloCard, corners) */
  background: #1d1d2a;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}
.holo[data-live='true'] .holo-back {
  transform: rotateY(180deg);
}
/* une seule face est visible à la fois : ne dépend pas de backface-visibility, mal gérée par certains moteurs.
   La bascule se fait quand la carte est de profil (90°) : avec la courbe de .holo-flip, à 0,14 s sur 0,75 s, dans les deux sens.
   Plus tard, on verrait le recto en miroir (ou une carte vide) avant le verso, comme si la carte tournait deux fois. */
.holo-front,
.holo-back {
  transition: opacity 0s linear var(--flip-half);
}
.holo-back {
  opacity: 0;
}
.holo[data-flipped='true'] .holo-front {
  opacity: 0;
}
.holo[data-flipped='true'] .holo-back {
  opacity: 1;
}
.holo-face img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  user-select: none;
}

/* reflets et hologrammes : voir ./holo/holo.css */
/* Fichier copié par scripts/sync-effects.js depuis le TCG Processor (frontend/src/holo/holo.css) : ne pas le modifier ici.
   Printicards : sélecteurs .holo[data-tex|glare|mask=…] et variables de base → .holo-face (effet propre à chaque face). */
/*
  Effets holographiques de la galerie.

  Dérivé de « Pokémon Cards Holographic effect in CSS » de Simon Goellner (@simeydotme),
  https://github.com/simeydotme/pokemon-cards-css (commit acb1197), licence GNU GPL v3 — voir ./LICENSE et ./README.md.
  Copyright (C) 2022 Simon Goellner.

  Ce fichier reprend les couches « shine » et « glare » des effets rare holo, reverse holo, rainbow, secret (or), shiny et cosmos,
  puis (section « recettes Pokémon V, VMAX… ») celles de trainer gallery, V, VMAX, VSTAR, V full art, shiny V, shiny VMAX,
  amazing, radiant, rainbow alt, Pikachu secret, trainer full art et trainer gallery secret, MODIFIÉES pour cette application :
    - sélecteurs : .card[data-rarity=…] → .holo-face[data-tex=…] (couche .holo-shine, ex .card__shine) et .holo-face[data-glare=…]
      (couche .holo-glare, ex .card__glare) : la texture et le reflet de chaque recette se choisissent séparément ;
    - les découpes propres aux cartes Pokémon (fenêtre d'illustration : clip-path) sont retirées ;
    - le « foil » propre à chaque carte est remplacé par une texture par défaut (voir ./img) ; chaque image peut être remplacée
      par effet via une variable --img-<emplacement> (foil, glitter, grain, cosmos-bottom, cosmos-middle, cosmos-top) ;
    - les masques propres aux cartes Pokémon (--mask, .masked) sont retirés : le masque est celui de la couche White ;
    - tailles de motif multipliées par --fx-scale, filtre de la couche principale complété par --fx-filter ;
    - les cartes qui ont une couche White sont masquées par --mask (zones sans encre blanche) ;
    - les couches ne sont affichées que sur la carte survolée, ciblée ou retournée ;
    - ajouts : feuille holographique sous l'illustration (.holo-foil) et texture vernis mat (.holo-texture), communs avec
      Printicards.
*/

.holo-face {
  --glitter: var(--img-glitter, url('/assets/glitter-0gk-nuCU.png'));
  --grain: var(--img-grain, url('/assets/grain-BWl84MUi.webp'));
  --glittersize: calc(25% * var(--fx-scale, 1));
  --space: calc(5% * var(--fx-scale, 1));
  --angle: 133deg;
  --imgsize: cover;
  --foil: var(--img-foil, none);
  --mask: none;
  --card-glow: hsl(175, 100%, 90%);
  --cosmosbg: center center;

  --red: #f80e35;
  --yellow: #eedf10;
  --green: #21e985;
  --blue: #0dbde9;
  --violet: #c929f1;

  --sunpillar-1: hsl(2, 100%, 73%);
  --sunpillar-2: hsl(53, 100%, 69%);
  --sunpillar-3: hsl(93, 100%, 69%);
  --sunpillar-4: hsl(176, 100%, 76%);
  --sunpillar-5: hsl(228, 100%, 74%);
  --sunpillar-6: hsl(283, 100%, 73%);
  --sunpillar-clr-1: var(--sunpillar-1);
  --sunpillar-clr-2: var(--sunpillar-2);
  --sunpillar-clr-3: var(--sunpillar-3);
  --sunpillar-clr-4: var(--sunpillar-4);
  --sunpillar-clr-5: var(--sunpillar-5);
  --sunpillar-clr-6: var(--sunpillar-6);

  --foil-brightness: 0.55;
}

/* --- base des couches ----------------------------------------------------------------------------------------------- */
.holo-shine,
.holo-glare {
  position: absolute;
  inset: 0;
  display: grid;
  overflow: hidden;
  pointer-events: none;
  opacity: var(--card-opacity);
}
.holo-shine {
  z-index: 3;
  background: transparent;
  background-size: cover;
  background-position: center;
  filter: brightness(0.85) contrast(2.75) saturate(0.65) var(--fx-filter, contrast(1));
  mix-blend-mode: color-dodge;
}
.holo-shine:before,
.holo-shine:after {
  --sunpillar-clr-1: var(--sunpillar-5);
  --sunpillar-clr-2: var(--sunpillar-6);
  --sunpillar-clr-3: var(--sunpillar-1);
  --sunpillar-clr-4: var(--sunpillar-2);
  --sunpillar-clr-5: var(--sunpillar-3);
  --sunpillar-clr-6: var(--sunpillar-4);
  grid-area: 1 / 1;
  border-radius: inherit;
}
.holo-shine:after {
  --sunpillar-clr-1: var(--sunpillar-6);
  --sunpillar-clr-2: var(--sunpillar-1);
  --sunpillar-clr-3: var(--sunpillar-2);
  --sunpillar-clr-4: var(--sunpillar-3);
  --sunpillar-clr-5: var(--sunpillar-4);
  --sunpillar-clr-6: var(--sunpillar-5);
}
.holo-glare {
  z-index: 4;
  background-image: radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsla(0, 0%, 100%, 0.8) 10%, hsla(0, 0%, 100%, 0.65) 20%, hsla(0, 0%, 0%, 0.5) 90%);
  mix-blend-mode: overlay;
}
.holo-glare:after {
  content: '';
  grid-area: 1 / 1;
}

/* réglages d'un effet de la bibliothèque (espace « Effets ») : intensité de l'effet et force du reflet multiplient l'opacité
   calculée au survol ; héritées par les pseudo-éléments, elles s'appliquent à toutes les recettes */
.holo-shine {
  --card-opacity: calc(var(--card-o, 0) * var(--fx-intensity, 1));
}
.holo-glare {
  --card-opacity: calc(var(--card-o, 0) * var(--fx-glare, 1));
}

/* texture « none » : pas de couche d'effet ; reflet « soft » : halo léger (l'ancien effet « Aucun ») */
.holo-face[data-tex='none'] .holo-shine {
  display: none;
}
.holo-face[data-glare='soft'] .holo-glare {
  opacity: calc(var(--card-opacity) * 0.35);
}

/* au repos, effets coupés, ou masque White pas encore chargé : aucun calque */
.holo:not([data-live='true']) .holo-shine,
.holo:not([data-live='true']) .holo-glare,
.holo[data-motion='false'] .holo-shine,
.holo[data-motion='false'] .holo-glare,
.holo-face[data-mask='pending'] .holo-shine,
.holo-face[data-mask='pending'] .holo-glare {
  display: none;
}

/* carte à couche White : l'effet ne couvre que les zones sans encre blanche (masque PNG, opaque là où il n'y a pas d'encre) */
.holo-face[data-mask='ready'] .holo-shine,
.holo-face[data-mask='ready'] .holo-glare {
  -webkit-mask: var(--mask) center / 100% 100% no-repeat;
  mask: var(--mask) center / 100% 100% no-repeat;
}

/* --- feuille holographique sous l'illustration ------------------------------------------------------------------------
   Le blanc d'une illustration est une absence d'encre : l'image est affichée « encre seule » (blanc → transparent, voir ./ink.js)
   au-dessus de .holo-foil : papier blanc partout, feuille argentée là où l'effet s'applique (zones sans encre blanche de
   soutien : --mask). Sans encre ni blanc de soutien, l'effet se voit donc en entier au travers de l'illustration. */
.holo-foil {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: #fff;
  pointer-events: none;
}
.holo-foil::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    calc(125deg + (var(--pointer-from-left, 0.5) - 0.5) * 40deg),
    #9ea4ad 0%, #e3e6ea 28%, #b2b8c0 50%, #eef0f3 72%, #a0a6ae 100%
  );
}
.holo-face[data-tex='none'] .holo-foil::before,
.holo-face[data-mask='pending'] .holo-foil::before {
  display: none;
}
.holo-face[data-mask='ready'] .holo-foil::before {
  -webkit-mask: var(--mask) center / 100% 100% no-repeat;
  mask: var(--mask) center / 100% 100% no-repeat;
}
.holo-face > img {
  position: relative;
  z-index: 1;
}

/* Texture (ton direct Texture / Mat / Relief… du PDF, ou zones noires du fichier dans Printicards ; --layer-mask : PNG
   alpha, opaque là où il y a la texture) : vernis mat. Sans couleur propre : un grain neutre en « overlay » rend la surface
   rugueuse et reprend la teinte et les reflets de ce qui est dessous (impression, effet holo, dorure) ; léger voile mat
   et reflet très diffus. Légère épaisseur : ombre fine sous le bord bas-droit et lisière claire au bord haut-gauche, qui
   se décalent un peu avec l'inclinaison. */
.holo-texture {
  position: absolute;
  inset: 0;
  pointer-events: none;
  -webkit-mask: var(--layer-mask) center / 100% 100% no-repeat;
  mask: var(--layer-mask) center / 100% 100% no-repeat;
  z-index: 8;
  background:
    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='1.1' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0.6 0.6 0.6 0 -0.4 0.6 0.6 0.6 0 -0.4 0.6 0.6 0.6 0 -0.4 0 0 0 0 1'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E") 0 0 / 180px 180px,
    radial-gradient(circle at var(--pointer-x, 50%) var(--pointer-y, 50%), rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0) 60%),
    rgba(140, 140, 140, 0.25);
  mix-blend-mode: overlay;
  opacity: 0.9;
}
.holo-texture-edge {
  --dx: calc(1px + (0.5 - var(--pointer-from-left, 0.5)) * 1.5px);
  --dy: calc(1.5px + (0.5 - var(--pointer-from-top, 0.5)) * 1.5px);
  position: absolute;
  inset: 0;
  z-index: 7;
  pointer-events: none;
}
/* ombre : masque décalé moins masque d'origine (fine bande hors de la forme, côté bas-droit) */
.holo-texture-edge[data-edge='shadow'] {
  background: rgba(0, 0, 0, 0.45);
  mask:
    var(--layer-mask) var(--dx) var(--dy) / 100% 100% no-repeat,
    var(--layer-mask) 0 0 / 100% 100% no-repeat;
  mask-composite: subtract;
  mix-blend-mode: multiply;
}
/* lisière : masque d'origine moins masque décalé (fine bande dans la forme, côté haut-gauche) */
.holo-texture-edge[data-edge='light'] {
  background: rgba(255, 255, 255, 0.35);
  mask:
    var(--layer-mask) 0 0 / 100% 100% no-repeat,
    var(--layer-mask) var(--dx) var(--dy) / 100% 100% no-repeat;
  mask-composite: subtract;
  mix-blend-mode: screen;
}

/* --- holographique (rare holo) ---------------------------------------------------------------------------------------- */
.holo-face[data-tex='holo'] .holo-shine {
  --scanlines-space: 1px;
  --scanlines-light: #666;
  --scanlines-dark: black;
  --bars: calc(3% * var(--fx-scale, 1));
  --bar-color: hsla(0, 0%, 70%, 1);
  --bar-bg: hsla(0, 0%, 0%, 1);

  background-image:
    repeating-linear-gradient(110deg, var(--violet), var(--blue), var(--green), var(--yellow), var(--red), var(--violet), var(--blue), var(--green), var(--yellow), var(--red), var(--violet), var(--blue), var(--green), var(--yellow), var(--red)),
    repeating-linear-gradient(90deg, var(--scanlines-dark) calc(var(--scanlines-space) * 0), var(--scanlines-dark) calc(var(--scanlines-space) * 2), var(--scanlines-light) calc(var(--scanlines-space) * 2), var(--scanlines-light) calc(var(--scanlines-space) * 4));
  background-position: calc(((50% - var(--background-x)) * 2.6) + 50%) calc(((50% - var(--background-y)) * 3.5) + 50%), center center;
  background-size: 400% 400%, cover;
  background-blend-mode: overlay;
  filter: brightness(1.1) contrast(1.1) saturate(1.2) var(--fx-filter, contrast(1));
  mix-blend-mode: color-dodge;
}
.holo-face[data-tex='holo'] .holo-shine:before {
  content: '';
  background-image:
    repeating-linear-gradient(90deg, var(--bar-bg) calc(var(--bars) * 2), var(--bar-color) calc(var(--bars) * 3), var(--bar-bg) calc(var(--bars) * 3.5), var(--bar-color) calc(var(--bars) * 4), var(--bar-bg) calc(var(--bars) * 5), var(--bar-bg) calc(var(--bars) * 14)),
    repeating-linear-gradient(90deg, var(--bar-bg) calc(var(--bars) * 2), var(--bar-color) calc(var(--bars) * 3), var(--bar-bg) calc(var(--bars) * 3.5), var(--bar-color) calc(var(--bars) * 4), var(--bar-bg) calc(var(--bars) * 5), var(--bar-bg) calc(var(--bars) * 10));
  background-position:
    calc((((50% - var(--background-x)) * 1.65) + 50%) + (var(--background-y) * 0.5)) var(--background-x),
    calc((((50% - var(--background-x)) * -0.9) + 50%) - (var(--background-y) * 0.75)) var(--background-y);
  background-size: 200% 200%, 200% 200%;
  background-blend-mode: screen;
  filter: brightness(1.15) contrast(1.1);
  mix-blend-mode: hard-light;
}
.holo-face[data-tex='holo'] .holo-shine:after {
  content: '';
  background-image: radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsla(0, 0%, 90%, 0.8) 0%, hsla(0, 0%, 78%, 0.1) 25%, hsl(0, 0%, 0%) 90%);
  background-position: center center;
  background-size: cover;
  mix-blend-mode: luminosity;
  filter: brightness(0.6) contrast(4);
}
@media screen and (max-width: 900px) {
  .holo-face[data-tex='holo'] .holo-shine {
    --scanlines-space: 0.5px;
  }
}
.holo-face[data-glare='holo'] .holo-glare {
  opacity: calc(var(--card-opacity) * 0.8);
  filter: brightness(0.8) contrast(1.5);
  mix-blend-mode: overlay;
}
.holo-face[data-glare='holo'] .holo-glare:after {
  background-image: radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsl(180, 100%, 95%) 5%, hsla(0, 0%, 39%, 0.25) 55%, hsla(0, 0%, 0%, 0.36) 110%);
  mix-blend-mode: overlay;
  filter: brightness(0.6) contrast(3);
}

/* --- reverse holo ---------------------------------------------------------------------------------------------------- */
.holo-face[data-tex='reverse'] .holo-shine {
  background-image:
    radial-gradient(circle at var(--pointer-x) var(--pointer-y), #fff 5%, #000 50%, #fff 80%),
    linear-gradient(-45deg, #000 15%, #fff, #000 85%),
    var(--foil);
  background-blend-mode: soft-light, difference;
  background-size: 120% 120%, 200% 200%, cover;
  background-position: center center, calc(100% * var(--pointer-from-left)) calc(100% * var(--pointer-from-top)), center center;
  filter: brightness(var(--foil-brightness)) contrast(1.5) saturate(1) var(--fx-filter, contrast(1));
  mix-blend-mode: color-dodge;
  opacity: calc((1.5 * var(--card-opacity)) - var(--pointer-from-center));
}
.holo-face[data-glare='reverse'] .holo-glare {
  opacity: var(--card-opacity);
  background-image: radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsla(0, 0%, 100%, 0.8) 10%, hsla(0, 0%, 100%, 0.5) 20%, hsla(0, 0%, 0%, 0.75) 90%);
  filter: brightness(0.7) contrast(1.5);
}
.holo-face[data-glare='reverse'] .holo-glare:after {
  opacity: var(--card-opacity);
  background-image: radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsl(0, 0%, 100%) 10%, hsla(0, 0%, 100%, 0.5) 20%, hsla(0, 0%, 0%, 0.5) 120%);
  filter: brightness(1) contrast(1.5);
}

/* --- arc-en-ciel (rare rainbow) ---------------------------------------------------------------------------------------- */
.holo-face[data-tex='rainbow'] .holo-shine {
  --r-clr-1: hsl(0, 57%, 37%);
  --r-clr-2: hsl(40, 53%, 39%);
  --r-clr-3: hsl(90, 60%, 35%);
  --r-clr-4: hsl(180, 60%, 35%);
  --r-clr-5: hsl(180, 60%, 35%);
  --r-clr-6: hsl(210, 57%, 39%);
  --r-clr-7: hsl(280, 55%, 31%);
  --foil: var(--img-foil, url('/assets/illusion-mask-CV2Insva.png'));
  --imgsize: calc(33% * var(--fx-scale, 1));

  background-image:
    linear-gradient(-45deg, var(--r-clr-1), var(--r-clr-5)),
    var(--glitter),
    linear-gradient(-30deg, var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7), var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7), var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7), var(--r-clr-1));
  background-blend-mode: luminosity, soft-light;
  background-size: 200% 200%, var(--glittersize) var(--glittersize), 400% 400%;
  background-position: calc(25% + (50% * var(--pointer-from-left))) calc(25% + (50% * var(--pointer-from-top))), center center, calc(25% + (var(--pointer-x) / 2)) calc(25% + (var(--pointer-y) / 2));
  filter: brightness(calc((var(--pointer-from-center) * 0.25) + 0.6)) contrast(2.2) saturate(0.75) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='rainbow'] .holo-shine:after {
  content: '';
  background-image:
    var(--glitter),
    linear-gradient(-60deg, var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7), var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7), var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7), var(--r-clr-1));
  background-blend-mode: soft-light;
  background-size: var(--glittersize) var(--glittersize), 400% 400%;
  background-position: center center, var(--pointer-x) var(--pointer-y);
  filter: brightness(calc((var(--pointer-from-center) * 0.3) + 0.55)) contrast(2) saturate(1);
  mix-blend-mode: color-dodge;
}
.holo-face[data-tex='rainbow'] .holo-shine:before {
  content: '';
  background-image: var(--foil);
  background-size: var(--imgsize);
  background-position: center center;
  filter: brightness(2.5) contrast(1);
  opacity: calc((var(--pointer-from-center) + 0.4) * 0.6);
  background-blend-mode: difference;
  mix-blend-mode: darken;
}
.holo-face[data-glare='rainbow'] .holo-glare {
  background-image: radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsl(0, 0%, 80%), hsla(187, 10%, 85%, 0.25) 30%, hsl(197, 6%, 25%) 120%);
  filter: brightness(0.9) contrast(1.75);
  opacity: calc(var(--pointer-from-center) * 0.9);
  mix-blend-mode: hard-light;
}

/* --- or (secret rare) -------------------------------------------------------------------------------------------------- */
.holo-face[data-tex='gold'] .holo-shine {
  --shift: 1px;
  --foil: var(--img-foil, url('/assets/geometric-CQlKBuz8.png'));
  --imgsize: calc(33% * var(--fx-scale, 1));

  background-image:
    var(--glitter),
    var(--glitter),
    conic-gradient(var(--sunpillar-clr-4), var(--sunpillar-clr-5), var(--sunpillar-clr-6), var(--sunpillar-clr-1), var(--sunpillar-clr-4)),
    radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsla(150, 0%, 0%, 0.98) 10%, hsla(0, 0%, 95%, 0.15) 90%);
  background-size: var(--glittersize) var(--glittersize), var(--glittersize) var(--glittersize), cover, cover;
  background-position: 45% 45%, 55% 55%, center center, center center;
  background-blend-mode: soft-light, hard-light, overlay;
  mix-blend-mode: color-dodge;
  filter: brightness(calc((var(--pointer-from-center) * 0.3) + 0.2)) contrast(2) saturate(0.75) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='gold'] .holo-shine:before {
  content: '';
  background-image:
    var(--foil),
    linear-gradient(45deg, hsl(46, 95%, 50%), hsl(52, 100%, 69%)),
    radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsla(10, 20%, 90%, 0.95) 10%, hsl(0, 0%, 0%) 70%);
  background-size: var(--imgsize), cover, cover;
  background-position: center center, center center, center center;
  background-blend-mode: hard-light, multiply;
  mix-blend-mode: lighten;
  filter: brightness(1.25) contrast(1.25) saturate(0.35);
  opacity: 0.8;
}
.holo-face[data-tex='gold'] .holo-shine:after {
  content: '';
  background-image: var(--glitter);
  background-size: var(--glittersize) var(--glittersize);
  background-position: calc(50% - ((var(--shift) * 2) * var(--pointer-from-left)) + var(--shift)) calc(50% - ((var(--shift) * 2) * var(--pointer-from-top)) + var(--shift));
  filter: brightness(calc((var(--pointer-from-center) * 0.6) + 0.6)) contrast(1.5);
  mix-blend-mode: overlay;
}
.holo-face[data-glare='gold'] .holo-glare {
  background-image: radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsla(45, 8%, 80%, 0.3) 0%, hsl(22, 15%, 12%) 180%);
  filter: brightness(1.3) contrast(1.5);
  mix-blend-mode: hard-light;
}

/* --- brillant (shiny rare) --------------------------------------------------------------------------------------------- */
.holo-face[data-tex='shine'] .holo-shine,
.holo-face[data-tex='shine'] .holo-shine:after {
  --foil: var(--img-foil, url('/assets/illusion-CKHJKhiM.png'));
  --space: calc(5% * var(--fx-scale, 1));
  --angle: 133deg;
  --imgsize: calc(33% * var(--fx-scale, 1));

  background-image:
    var(--foil),
    repeating-linear-gradient(0deg, var(--sunpillar-clr-1) calc(var(--space) * 1), var(--sunpillar-clr-2) calc(var(--space) * 2), var(--sunpillar-clr-3) calc(var(--space) * 3), var(--sunpillar-clr-4) calc(var(--space) * 4), var(--sunpillar-clr-5) calc(var(--space) * 5), var(--sunpillar-clr-6) calc(var(--space) * 6), var(--sunpillar-clr-1) calc(var(--space) * 7)),
    repeating-linear-gradient(var(--angle), #0e152e 0%, hsl(180, 10%, 60%) 3.8%, hsl(180, 29%, 66%) 4.5%, hsl(180, 10%, 60%) 5.2%, #0e152e 10%, #0e152e 12%),
    radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsla(0, 0%, 0%, 0.1) 12%, hsla(0, 0%, 0%, 0.15) 20%, hsla(0, 0%, 0%, 0.25) 120%);
  background-position: center center, 0% var(--background-y), calc(var(--background-x) + (var(--background-y) * 0.2)) var(--background-y), var(--background-x) var(--background-y);
  background-blend-mode: exclusion, hue, hard-light;
  background-size: var(--imgsize), 200% 700%, 300% 100%, 200% 100%;
  filter: brightness(calc((var(--pointer-from-center) * 0.3) + 0.35)) contrast(2) saturate(1.5) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='shine'] .holo-shine:after {
  content: '';
  background-position: center center, 0% var(--background-y), calc((var(--background-x) + (var(--background-y) * 0.2)) * -1) calc(var(--background-y) * -1), var(--background-x) var(--background-y);
  background-size: var(--imgsize), 200% 400%, 195% 100%, 200% 100%;
  filter: brightness(calc((var(--pointer-from-center) * 0.4) + 0.5)) contrast(1.4) saturate(1.2);
  mix-blend-mode: difference;
}
.holo-face[data-tex='shine'] .holo-shine:before {
  content: '';
  background-image: radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsl(0, 0%, 100%) 0%, hsla(0, 0%, 0%, 0) 40%);
  background-position: center;
  background-size: cover;
  mix-blend-mode: overlay;
  opacity: 0.75;
  z-index: 1;
}
.holo-face[data-glare='shine'] .holo-glare {
  background-image: radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsl(0, 0%, 100%) 0%, hsl(320, 5%, 15%) 150%);
  background-size: cover;
  background-position: center center;
  mix-blend-mode: multiply;
  filter: brightness(1.2) contrast(1) saturate(0.7);
  opacity: calc(var(--card-opacity) * var(--pointer-from-center));
}

/* --- cosmos (rare holo cosmos) ----------------------------------------------------------------------------------------- */
.holo-face[data-tex='cosmos'] .holo-shine {
  --space: calc(4% * var(--fx-scale, 1));

  background-image:
    var(--img-cosmos-bottom, url('/assets/cosmos-bottom-D83TNPWu.png')),
    repeating-linear-gradient(82deg, hsl(53, 65%, 60%) calc(var(--space) * 1), hsl(93, 56%, 50%) calc(var(--space) * 2), hsl(176, 54%, 49%) calc(var(--space) * 3), hsl(228, 59%, 55%) calc(var(--space) * 4), hsl(283, 60%, 55%) calc(var(--space) * 5), hsl(326, 59%, 51%) calc(var(--space) * 6), hsl(326, 59%, 51%) calc(var(--space) * 7), hsl(283, 60%, 55%) calc(var(--space) * 8), hsl(228, 59%, 55%) calc(var(--space) * 9), hsl(176, 54%, 49%) calc(var(--space) * 10), hsl(93, 56%, 50%) calc(var(--space) * 11), hsl(53, 65%, 60%) calc(var(--space) * 12)),
    radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsla(180, 100%, 89%, 0.5) 5%, hsla(180, 14%, 57%, 0.3) 40%, hsl(0, 0%, 0%) 130%);
  background-blend-mode: color-burn, multiply;
  background-position: var(--cosmosbg), calc(10% + (var(--pointer-from-left) * 80%)) calc(10% + (var(--pointer-from-top) * 80%)), center center;
  background-size: cover, 400% 900%, cover;
  filter: brightness(1) contrast(1) saturate(0.8) var(--fx-filter, contrast(1));
  mix-blend-mode: color-dodge;
}
.holo-face[data-tex='cosmos'] .holo-shine:before {
  content: '';
  z-index: 2;
  background-image:
    var(--img-cosmos-middle, url('/assets/cosmos-middle-trans-Cho7JpRz.png')),
    repeating-linear-gradient(82deg, hsl(53, 65%, 60%) calc(var(--space) * 1), hsl(93, 56%, 50%) calc(var(--space) * 2), hsl(176, 54%, 49%) calc(var(--space) * 3), hsl(228, 59%, 55%) calc(var(--space) * 4), hsl(283, 60%, 55%) calc(var(--space) * 5), hsl(326, 59%, 51%) calc(var(--space) * 6), hsl(326, 59%, 51%) calc(var(--space) * 7), hsl(283, 60%, 55%) calc(var(--space) * 8), hsl(228, 59%, 55%) calc(var(--space) * 9), hsl(176, 54%, 49%) calc(var(--space) * 10), hsl(93, 56%, 50%) calc(var(--space) * 11), hsl(53, 65%, 60%) calc(var(--space) * 12));
  background-blend-mode: lighten, multiply;
  background-position: var(--cosmosbg), calc(15% + (var(--pointer-from-left) * 70%)) calc(15% + (var(--pointer-from-top) * 70%)), center center;
  background-size: cover, 400% 900%, cover;
  filter: brightness(1.25) contrast(1.75) saturate(0.8);
  mix-blend-mode: overlay;
}
.holo-face[data-tex='cosmos'] .holo-shine:after {
  content: '';
  z-index: 3;
  background-image:
    var(--img-cosmos-top, url('/assets/cosmos-top-trans-DN14DDc0.png')),
    repeating-linear-gradient(82deg, hsl(53, 65%, 60%) calc(var(--space) * 1), hsl(93, 56%, 50%) calc(var(--space) * 2), hsl(176, 54%, 49%) calc(var(--space) * 3), hsl(228, 59%, 55%) calc(var(--space) * 4), hsl(283, 60%, 55%) calc(var(--space) * 5), hsl(326, 59%, 51%) calc(var(--space) * 6), hsl(326, 59%, 51%) calc(var(--space) * 7), hsl(283, 60%, 55%) calc(var(--space) * 8), hsl(228, 59%, 55%) calc(var(--space) * 9), hsl(176, 54%, 49%) calc(var(--space) * 10), hsl(93, 56%, 50%) calc(var(--space) * 11), hsl(53, 65%, 60%) calc(var(--space) * 12));
  background-blend-mode: multiply, multiply;
  background-position: var(--cosmosbg), calc(20% + (var(--pointer-from-left) * 60%)) calc(20% + (var(--pointer-from-top) * 60%)), center center;
  background-size: cover, 400% 900%, cover;
  filter: brightness(1.25) contrast(1.75) saturate(0.8);
  mix-blend-mode: multiply;
}
.holo-face[data-glare='cosmos'] .holo-glare {
  background-image: radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsla(204, 100%, 95%, 0.8) 5%, hsla(250, 15%, 20%, 1) 150%);
  filter: brightness(0.75) contrast(2) saturate(2);
  mix-blend-mode: overlay;
  opacity: calc(var(--card-opacity) * (0.25 + var(--pointer-from-center)));
}
.holo-face[data-glare='cosmos'] .holo-glare:after {
  background-image: radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsl(280, 100%, 96%) 5%, hsl(0, 0%, 10%) 60%);
  filter: brightness(0.75) contrast(2.5) saturate(2);
  mix-blend-mode: soft-light;
  opacity: calc(1 - var(--pointer-from-top) * 0.75);
}

/* ===== recettes Pokémon V, VMAX… (converties depuis les feuilles d'origine, ordre de la cascade d'origine conservé) ===== */

/* --- Trainer Gallery ---------------------------------------------------------------------------------------------------- */
.holo-face[data-tex='trainer'] .holo-shine {
  --space: calc(5% * var(--fx-scale, 1));
  --angle: -22deg;
  --imgsize: calc(300% * var(--fx-scale, 1)) calc(400% * var(--fx-scale, 1));
  background-image:
    repeating-linear-gradient( var(--angle),
      hsla(283, 49%, 60%, 0.75) calc(var(--space)*1),
      hsla(2, 74%, 59%, 0.75) calc(var(--space)*2),
      hsla(53, 67%, 53%, 0.75) calc(var(--space)*3),
      hsla(93, 56%, 52%, 0.75) calc(var(--space)*4),
      hsla(176, 38%, 50%, 0.75) calc(var(--space)*5),
      hsla(228, 100%, 77%, 0.75) calc(var(--space)*6),
      hsla(283, 49%, 61%, 0.75) calc(var(--space)*7)
    );
  background-blend-mode: color-dodge;
  background-size: var(--imgsize);
  background-position: 0% calc(var(--background-y) * 1), var(--background-x) var(--background-y);
  filter: brightness(calc((var(--pointer-from-center)*0.3) + 0.5)) contrast(2.3) saturate(1) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='trainer'] .holo-shine:after {
  content: "";
  background-image:
    radial-gradient(
      farthest-corner ellipse
      at calc( ((var(--pointer-x)) * 0.5) + 25% ) calc( ((var(--pointer-y)) * 0.5) + 25% ),
      hsl(0, 0%, 100%) 5%,
      hsla(300, 100%, 11%, 0.6) 40%,
      hsl(0, 0%, 22%) 120%
    );
  background-position: center center;
  background-size: 400% 500%;
  filter: brightness(calc((var(--pointer-from-center)*0.2) + 0.4)) contrast(.85) saturate(1.1);
  mix-blend-mode: hard-light;
}
.holo-face[data-tex='trainer'] .holo-shine:before {
  content: none;
  display: none;
}
.holo-face[data-glare='trainer'] .holo-glare {
  background-image:
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 100%, 1) 10%,
      hsla(0, 0%, 100%, 0.6) 35%,
      hsla(180, 11%, 35%, 1) 60%
    );
  mix-blend-mode: soft-light;
}
.holo-face[data-glare='trainer'] .holo-glare:before,
.holo-face[data-glare='trainer'] .holo-glare:after {
  content: none;
  display: none;
}

/* --- Pokémon V ---------------------------------------------------------------------------------------------------------- */
.holo-face[data-tex='vregular'] .holo-shine:after,
.holo-face[data-tex='pillar'] .holo-shine:after {
  --space: calc(5% * var(--fx-scale, 1));
  --angle: 133deg;
  --imgsize: calc(500px * var(--fx-scale, 1));
  background-image:
    var(--grain),
    repeating-linear-gradient( 0deg,
      var(--sunpillar-clr-1) calc(var(--space)*1),
      var(--sunpillar-clr-2) calc(var(--space)*2),
      var(--sunpillar-clr-3) calc(var(--space)*3),
      var(--sunpillar-clr-4) calc(var(--space)*4),
      var(--sunpillar-clr-5) calc(var(--space)*5),
      var(--sunpillar-clr-6) calc(var(--space)*6),
      var(--sunpillar-clr-1) calc(var(--space)*7)
    ),
    repeating-linear-gradient(
      var(--angle),
      #0e152e 0%,
      hsl(180, 10%, 60%) 3.8%,
      hsl(180, 29%, 66%) 4.5%,
      hsl(180, 10%, 60%) 5.2%,
      #0e152e 10% ,
      #0e152e 12%
      ),
    radial-gradient(
      farthest-corner circle
      at var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 0%, 0.1) 12%,
      hsla(0, 0%, 0%, 0.15) 20%,
      hsla(0, 0%, 0%, 0.25) 120%
    );
  background-blend-mode: screen, hue, hard-light;
  background-size: var(--imgsize) 100%, 200% 700%, 300% 100%, 200% 100%;
  background-position: center, 0% var(--background-y), var(--background-x) var(--background-y), var(--background-x) var(--background-y);
  filter: brightness(.8) contrast(2.95) saturate(.65);
}
.holo-face[data-tex='vregular'] .holo-shine,
.holo-face[data-tex='pillar'] .holo-shine {
  --space: calc(5% * var(--fx-scale, 1));
  --angle: 133deg;
  --imgsize: calc(500px * var(--fx-scale, 1));
  background-image:
    var(--grain),
    repeating-linear-gradient( 0deg,
      var(--sunpillar-clr-1) calc(var(--space)*1),
      var(--sunpillar-clr-2) calc(var(--space)*2),
      var(--sunpillar-clr-3) calc(var(--space)*3),
      var(--sunpillar-clr-4) calc(var(--space)*4),
      var(--sunpillar-clr-5) calc(var(--space)*5),
      var(--sunpillar-clr-6) calc(var(--space)*6),
      var(--sunpillar-clr-1) calc(var(--space)*7)
    ),
    repeating-linear-gradient(
      var(--angle),
      #0e152e 0%,
      hsl(180, 10%, 60%) 3.8%,
      hsl(180, 29%, 66%) 4.5%,
      hsl(180, 10%, 60%) 5.2%,
      #0e152e 10% ,
      #0e152e 12%
      ),
    radial-gradient(
      farthest-corner circle
      at var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 0%, 0.1) 12%,
      hsla(0, 0%, 0%, 0.15) 20%,
      hsla(0, 0%, 0%, 0.25) 120%
    );
  background-blend-mode: screen, hue, hard-light;
  background-size: var(--imgsize) 100%, 200% 700%, 300% 100%, 200% 100%;
  background-position: center, 0% var(--background-y), var(--background-x) var(--background-y), var(--background-x) var(--background-y);
  filter: brightness(.8) contrast(2.95) saturate(.65) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='vregular'] .holo-shine:after,
.holo-face[data-tex='pillar'] .holo-shine:after {
  content: "";
  background-position: center, 0% var(--background-y), calc( var(--background-x) * -1) calc( var(--background-y) * -1), var(--background-x) var(--background-y);
  background-size: var(--imgsize) 100%, 200% 400%, 195% 100%, 200% 100%;
  filter: brightness(1) contrast(2.5) saturate(1.75);
  mix-blend-mode: soft-light;
}
.holo-face[data-glare='vregular'] .holo-glare {
  background-image:
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
        hsl(0, 0%, 100%) 0%,
        hsla(210, 3%, 54%, 0.33) 45%,
        hsla(0, 0%, 20%, 0.9) 130%
      );
  opacity: calc(var(--card-opacity)*.5);
  mix-blend-mode: hard-light;
  filter: brightness(.9) contrast(1.75);
}
.holo-face[data-tex='vregular'] .holo-shine,
.holo-face[data-tex='pillar'] .holo-shine {
  filter: brightness(.7) contrast(2) saturate(.5) var(--fx-filter, contrast(1));
}
/* Pillar (ajout de cette application) : la recette Pokémon V, barres de lumière verticales au lieu de diagonales */
.holo-face[data-tex='pillar'] .holo-shine,
.holo-face[data-tex='pillar'] .holo-shine:after {
  --angle: 90deg;
}

/* --- Pokémon VMAX ------------------------------------------------------------------------------------------------------- */
.holo-face[data-tex='vmax'] .holo-shine {
  --space: calc(6% * var(--fx-scale, 1));
  --angle: 133deg;
  --imgsize: cover;
  background-image:
    var(--foil),
    repeating-linear-gradient( -33deg,
      hsl(2, 70%, 47%) calc(var(--space)*1),
      hsl(228, 60%, 64%) calc(var(--space)*2),
      hsl(176, 55%, 39%) calc(var(--space)*3),
      hsl(123, 68%, 35%) calc(var(--space)*4),
      hsl(283, 75%, 57%) calc(var(--space)*5),
      hsl(2, 70%, 47%) calc(var(--space)*6)
    ),
    repeating-linear-gradient(
      var(--angle),
      hsla(227, 53%, 12%, 0.5) 0%,
      hsl(180, 10%, 50%) 2.5%,
      hsl(83, 50%, 35%) 5%,
      hsl(180, 10%, 50%) 7.5%,
      hsla(227, 53%, 12%, 0.5) 10% ,
      hsla(227, 53%, 12%, 0.5) 15%
      ),
    radial-gradient(
      farthest-corner circle
      at var(--pointer-x) var(--pointer-y),
      hsla(189, 76%, 77%, 0.6) 0%,
      hsla(147, 59%, 77%, 0.6) 25%,
      hsla(271, 55%, 69%, 0.6) 50%,
      hsla(355, 56%, 72%, 0.6) 75%
    );
  background-blend-mode: difference, luminosity, soft-light;
  background-size: var(--imgsize), 1100% 1100%, 600% 600%, 200% 200%;
  background-position:
    center,
    var(--background-x) var(--background-y),
    var(--background-x) var(--background-y),
    var(--background-x) var(--background-y);
  filter: brightness(calc((var(--pointer-from-center) * .4) + .4)) contrast(2) saturate(1) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='vmax'] .holo-shine:after {
  content: "";
  background-image: repeating-linear-gradient( 0deg,
    var(--sunpillar-clr-1) calc(var(--space)*1),
    var(--sunpillar-clr-2) calc(var(--space)*2),
    var(--sunpillar-clr-3) calc(var(--space)*3),
    var(--sunpillar-clr-4) calc(var(--space)*4),
    var(--sunpillar-clr-5) calc(var(--space)*5),
    var(--sunpillar-clr-6) calc(var(--space)*6),
    var(--sunpillar-clr-1) calc(var(--space)*7)
  ),
  repeating-linear-gradient(
    var(--angle),
    #0e152e 0%,
    hsl(180, 10%, 60%) 3.8%,
    hsl(180, 29%, 66%) 4.5%,
    hsl(180, 10%, 60%) 5.2%,
    #0e152e 10% ,
    #0e152e 12%
  );
  background-blend-mode: hue, hard-light;
  background-size: 200% 700%, 300% 100%, 200% 100%;
  background-position: 0% var(--background-y), var(--background-x) var(--background-y), var(--background-x) var(--background-y);
  mix-blend-mode: lighten;
  opacity: calc( (0.3 * var(--card-opacity)) + var(--card-opacity) * var(--pointer-from-center) * 0.5 );
  filter: saturate(1.5);
}
.holo-face[data-glare='vmax'] .holo-glare {
  mix-blend-mode: hard-light;
  filter: brightness(1) contrast(1);
  background-image:
    radial-gradient(
      farthest-corner circle at
      var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 100%, 0.75) 0%,
      hsl(0, 0%, 0%) 120%
    );
  opacity: calc( (0.2 * var(--card-opacity)) + var(--card-opacity) * var(--pointer-from-center) * 0.8 );
}
.holo-face[data-tex='vmax'] .holo-shine,
.holo-face[data-tex='vmax'] .holo-shine:after {
  --foil: var(--img-foil, url('/assets/vmaxbg-CfqOZMdN.jpg'));
  --imgsize: calc(60% * var(--fx-scale, 1)) calc(30% * var(--fx-scale, 1));
}

/* --- Pokémon VSTAR ------------------------------------------------------------------------------------------------------ */
.holo-face[data-tex='vstar'] .holo-shine:after {
  --space: calc(5% * var(--fx-scale, 1));
  --angle: 133deg;
  --imgsize: cover;
  background-image:
    var(--foil),
    repeating-linear-gradient( 0deg,
      var(--sunpillar-clr-1) calc(var(--space)*1),
      var(--sunpillar-clr-2) calc(var(--space)*2),
      var(--sunpillar-clr-3) calc(var(--space)*3),
      var(--sunpillar-clr-4) calc(var(--space)*4),
      var(--sunpillar-clr-5) calc(var(--space)*5),
      var(--sunpillar-clr-6) calc(var(--space)*6),
      var(--sunpillar-clr-1) calc(var(--space)*7)
    ),
    repeating-linear-gradient(
      var(--angle),
      #0e152e 0%,
      hsl(180, 10%, 60%) 3.8%,
      hsl(180, 29%, 66%) 4.5%,
      hsl(180, 10%, 60%) 5.2%,
      #0e152e 10% ,
      #0e152e 12%
    ),
    radial-gradient(
      farthest-corner circle
      at var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 0%, 0.1) 12%,
      hsla(0, 0%, 0%, 0.15) 20%,
      hsla(0, 0%, 0%, 0.25) 120%
    );
  background-blend-mode: soft-light, hue, hard-light;
  background-size: var(--imgsize), 200% 700%, 300% 100%, 200% 100%;
  background-position: center center, 0% var(--background-y), var(--background-x) var(--background-y), var(--background-x) var(--background-y);
  filter: brightness(calc((var(--pointer-from-center) * .75) + .25)) contrast(2) saturate(1.25);
}
.holo-face[data-tex='vstar'] .holo-shine {
  --space: calc(5% * var(--fx-scale, 1));
  --angle: 133deg;
  --imgsize: cover;
  background-image:
    var(--foil),
    repeating-linear-gradient( 0deg,
      var(--sunpillar-clr-1) calc(var(--space)*1),
      var(--sunpillar-clr-2) calc(var(--space)*2),
      var(--sunpillar-clr-3) calc(var(--space)*3),
      var(--sunpillar-clr-4) calc(var(--space)*4),
      var(--sunpillar-clr-5) calc(var(--space)*5),
      var(--sunpillar-clr-6) calc(var(--space)*6),
      var(--sunpillar-clr-1) calc(var(--space)*7)
    ),
    repeating-linear-gradient(
      var(--angle),
      #0e152e 0%,
      hsl(180, 10%, 60%) 3.8%,
      hsl(180, 29%, 66%) 4.5%,
      hsl(180, 10%, 60%) 5.2%,
      #0e152e 10% ,
      #0e152e 12%
    ),
    radial-gradient(
      farthest-corner circle
      at var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 0%, 0.1) 12%,
      hsla(0, 0%, 0%, 0.15) 20%,
      hsla(0, 0%, 0%, 0.25) 120%
    );
  background-blend-mode: soft-light, hue, hard-light;
  background-size: var(--imgsize), 200% 700%, 300% 100%, 200% 100%;
  background-position: center center, 0% var(--background-y), var(--background-x) var(--background-y), var(--background-x) var(--background-y);
  filter: brightness(calc((var(--pointer-from-center) * .75) + .25)) contrast(2) saturate(1.25) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='vstar'] .holo-shine:after {
  content: "";
  background-size: var(--imgsize), 200% 400%, 195% 100%, 200% 100%;
  background-position: center center, 0% var(--background-y), calc( var(--background-x) * -1) calc( var(--background-y) * -1), var(--background-x) var(--background-y);
  filter: brightness(calc((var(--pointer-from-center) * .75) + .5)) contrast(1.5) saturate(1.5);
  mix-blend-mode: exclusion;
}
.holo-face[data-tex='vstar'] .holo-shine:before {
  content: "";
  background-image: radial-gradient( farthest-corner circle at var(--pointer-x) var(--pointer-y), hsla(190, 7%, 80%, 0.75) 0%, hsla(260, 7%, 50%, 0.25) 45%, hsl(310, 7%, 50%) 120% );
  mix-blend-mode: hard-light;
  z-index: 2;
  opacity: 0.8;
}
.holo-face[data-glare='vstar'] .holo-glare {
  filter: brightness(.7) contrast(2);
  background-image:
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsl(195, 90%, 90%) 5%,
      hsl(300, 3%, 60%) 60%,
      hsl(350, 0%, 15%) 150%
    );
  mix-blend-mode: hard-light;
  opacity: calc(var(--card-opacity)*(var(--pointer-from-center)*.75));
}
.holo-face[data-tex='vstar'] .holo-shine:after {
  --foil: var(--img-foil, url('/assets/ancient-Ci9hYTiU.png'));
  --imgsize: calc(18% * var(--fx-scale, 1)) calc(15% * var(--fx-scale, 1));
  background-blend-mode: exclusion, hue, hard-light;
  filter: brightness(calc((var(--pointer-from-center) * .25) + .35)) contrast(1.8) saturate(1.75);
}
.holo-face[data-tex='vstar'] .holo-shine {
  --foil: var(--img-foil, url('/assets/ancient-Ci9hYTiU.png'));
  --imgsize: calc(18% * var(--fx-scale, 1)) calc(15% * var(--fx-scale, 1));
  background-blend-mode: exclusion, hue, hard-light;
  filter: brightness(calc((var(--pointer-from-center) * .25) + .35)) contrast(1.8) saturate(1.75) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='vstar'] .holo-shine:after {
  filter: brightness(calc((var(--pointer-from-center) * .75) + .5)) contrast(1.5) saturate(1.5);
}
.holo-face[data-glare='vstar'] .holo-glare {
  filter: brightness(.55) contrast(2);
}

/* --- V Full Art --------------------------------------------------------------------------------------------------------- */
.holo-face[data-tex='vfull'] .holo-shine:after {
  --space: calc(5% * var(--fx-scale, 1));
  --angle: 133deg;
  --imgsize: cover;
  background-image:
    var(--foil),
    repeating-linear-gradient( 0deg,
      var(--sunpillar-clr-1) calc(var(--space)*1),
      var(--sunpillar-clr-2) calc(var(--space)*2),
      var(--sunpillar-clr-3) calc(var(--space)*3),
      var(--sunpillar-clr-4) calc(var(--space)*4),
      var(--sunpillar-clr-5) calc(var(--space)*5),
      var(--sunpillar-clr-6) calc(var(--space)*6),
      var(--sunpillar-clr-1) calc(var(--space)*7)
    ),
    repeating-linear-gradient(
      var(--angle),
      #0e152e 0%,
      hsl(180, 10%, 60%) 3.8%,
      hsl(180, 29%, 66%) 4.5%,
      hsl(180, 10%, 60%) 5.2%,
      #0e152e 10% ,
      #0e152e 12%
      ),
    radial-gradient(
      farthest-corner circle
      at var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 0%, 0.1) 12%,
      hsla(0, 0%, 0%, 0.15) 20%,
      hsla(0, 0%, 0%, 0.25) 120%
    );
  background-position:
    center center,
    0% var(--background-y),
    calc( var(--background-x) + (var(--background-y)*0.2) ) var(--background-y),
    var(--background-x) var(--background-y);
  background-blend-mode: soft-light, hue, hard-light;
  background-size: var(--imgsize), 200% 700%, 300% 100%, 200% 100%;
  filter: brightness(calc((var(--pointer-from-center)*0.4) + .4)) contrast(1.4) saturate(2.25);
}
.holo-face[data-tex='vfull'] .holo-shine {
  --space: calc(5% * var(--fx-scale, 1));
  --angle: 133deg;
  --imgsize: cover;
  background-image:
    var(--foil),
    repeating-linear-gradient( 0deg,
      var(--sunpillar-clr-1) calc(var(--space)*1),
      var(--sunpillar-clr-2) calc(var(--space)*2),
      var(--sunpillar-clr-3) calc(var(--space)*3),
      var(--sunpillar-clr-4) calc(var(--space)*4),
      var(--sunpillar-clr-5) calc(var(--space)*5),
      var(--sunpillar-clr-6) calc(var(--space)*6),
      var(--sunpillar-clr-1) calc(var(--space)*7)
    ),
    repeating-linear-gradient(
      var(--angle),
      #0e152e 0%,
      hsl(180, 10%, 60%) 3.8%,
      hsl(180, 29%, 66%) 4.5%,
      hsl(180, 10%, 60%) 5.2%,
      #0e152e 10% ,
      #0e152e 12%
      ),
    radial-gradient(
      farthest-corner circle
      at var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 0%, 0.1) 12%,
      hsla(0, 0%, 0%, 0.15) 20%,
      hsla(0, 0%, 0%, 0.25) 120%
    );
  background-position:
    center center,
    0% var(--background-y),
    calc( var(--background-x) + (var(--background-y)*0.2) ) var(--background-y),
    var(--background-x) var(--background-y);
  background-blend-mode: soft-light, hue, hard-light;
  background-size: var(--imgsize), 200% 700%, 300% 100%, 200% 100%;
  filter: brightness(calc((var(--pointer-from-center)*0.4) + .4)) contrast(1.4) saturate(2.25) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='vfull'] .holo-shine:after {
  content: "";
  background-position:
    center center,
    0% var(--background-y),
    calc( (var(--background-x) + (var(--background-y)*0.2)) * -1) calc( var(--background-y) * -1),
    var(--background-x) var(--background-y);
  background-size: var(--imgsize), 200% 400%, 195% 100%, 200% 100%;
  filter: brightness(calc((var(--pointer-from-center)*.4) + .8)) contrast(1.5) saturate(1.25);
  mix-blend-mode: exclusion;
}
.holo-face[data-tex='vfull'] .holo-shine:before {
  content: "";
  background-image:
    radial-gradient( farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsl(0, 0%, 100%) 0%,
      hsla(0, 0%, 0%, 0) 40%
    );
  background-position: center;
  background-size: cover;
  mix-blend-mode: overlay;
  opacity: 0.75;
  z-index: 1;
}
.holo-face[data-glare='vfull'] .holo-glare {
  background-image:
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsl(0, 0%, 75%) 5%,
      hsl(200, 5%, 35%) 60%,
      hsl(320, 40%, 10%) 150%
    );
  background-size: 120% 150%;
  background-position: center center;
  mix-blend-mode: hard-light;
  filter: brightness(1) contrast(1.2) saturate(1);
  opacity: calc(var(--card-opacity) * .75 );
}
.holo-face[data-tex='vfull'] .holo-shine:after {
  --foil: var(--img-foil, url('/assets/illusion-CKHJKhiM.png'));
  --imgsize: calc(33% * var(--fx-scale, 1));
  background-blend-mode: exclusion, hue, hard-light;
  filter: brightness(calc((var(--pointer-from-center)*.3) + .35)) contrast(2) saturate(1.5);
}
.holo-face[data-tex='vfull'] .holo-shine {
  --foil: var(--img-foil, url('/assets/illusion-CKHJKhiM.png'));
  --imgsize: calc(33% * var(--fx-scale, 1));
  background-blend-mode: exclusion, hue, hard-light;
  filter: brightness(calc((var(--pointer-from-center)*.3) + .35)) contrast(2) saturate(1.5) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='vfull'] .holo-shine:before {
  content: none;
  display: none;
}
.holo-face[data-tex='vfull'] .holo-shine:after {
  filter: brightness(calc((var(--pointer-from-center)*.5) + .8)) contrast(1.6) saturate(1.4);
}

/* --- Shiny V ------------------------------------------------------------------------------------------------------------ */
.holo-face[data-tex='shinyv'] .holo-shine:after {
  --space: calc(5% * var(--fx-scale, 1));
  --angle: 133deg;
  --imgsize: cover;
  background-image:
    var(--foil),
    repeating-linear-gradient( 0deg,
      var(--sunpillar-clr-1) calc(var(--space)*1),
      var(--sunpillar-clr-2) calc(var(--space)*2),
      var(--sunpillar-clr-3) calc(var(--space)*3),
      var(--sunpillar-clr-4) calc(var(--space)*4),
      var(--sunpillar-clr-5) calc(var(--space)*5),
      var(--sunpillar-clr-6) calc(var(--space)*6),
      var(--sunpillar-clr-1) calc(var(--space)*7)
    ),
    repeating-linear-gradient(
      var(--angle),
      #0e152e 0%,
      hsl(180, 10%, 60%) 3.8%,
      hsl(180, 29%, 66%) 4.5%,
      hsl(180, 10%, 60%) 5.2%,
      #0e152e 10% ,
      #0e152e 12%
      ),
    radial-gradient(
      farthest-corner circle
      at var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 0%, 0.1) 12%,
      hsla(0, 0%, 0%, 0.15) 20%,
      hsla(0, 0%, 0%, 0.25) 120%
    );
  background-position:
    center center,
    0% var(--background-y),
    calc( var(--background-x) + (var(--background-y)*0.2) ) var(--background-y),
    var(--background-x) var(--background-y);
  background-blend-mode: soft-light, hue, hard-light;
  background-size: var(--imgsize), 200% 700%, 300% 100%, 200% 100%;
  filter: brightness(calc((var(--pointer-from-center)*0.4) + .4)) contrast(1.4) saturate(2.25);
}
.holo-face[data-tex='shinyv'] .holo-shine {
  --space: calc(5% * var(--fx-scale, 1));
  --angle: 133deg;
  --imgsize: cover;
  background-image:
    var(--foil),
    repeating-linear-gradient( 0deg,
      var(--sunpillar-clr-1) calc(var(--space)*1),
      var(--sunpillar-clr-2) calc(var(--space)*2),
      var(--sunpillar-clr-3) calc(var(--space)*3),
      var(--sunpillar-clr-4) calc(var(--space)*4),
      var(--sunpillar-clr-5) calc(var(--space)*5),
      var(--sunpillar-clr-6) calc(var(--space)*6),
      var(--sunpillar-clr-1) calc(var(--space)*7)
    ),
    repeating-linear-gradient(
      var(--angle),
      #0e152e 0%,
      hsl(180, 10%, 60%) 3.8%,
      hsl(180, 29%, 66%) 4.5%,
      hsl(180, 10%, 60%) 5.2%,
      #0e152e 10% ,
      #0e152e 12%
      ),
    radial-gradient(
      farthest-corner circle
      at var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 0%, 0.1) 12%,
      hsla(0, 0%, 0%, 0.15) 20%,
      hsla(0, 0%, 0%, 0.25) 120%
    );
  background-position:
    center center,
    0% var(--background-y),
    calc( var(--background-x) + (var(--background-y)*0.2) ) var(--background-y),
    var(--background-x) var(--background-y);
  background-blend-mode: soft-light, hue, hard-light;
  background-size: var(--imgsize), 200% 700%, 300% 100%, 200% 100%;
  filter: brightness(calc((var(--pointer-from-center)*0.4) + .4)) contrast(1.4) saturate(2.25) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='shinyv'] .holo-shine:after {
  content: "";
  background-position:
    center center,
    0% var(--background-y),
    calc( (var(--background-x) + (var(--background-y)*0.2)) * -1) calc( var(--background-y) * -1),
    var(--background-x) var(--background-y);
  background-size: var(--imgsize), 200% 400%, 195% 100%, 200% 100%;
  filter: brightness(calc((var(--pointer-from-center)*.4) + .8)) contrast(1.5) saturate(1.25);
  mix-blend-mode: exclusion;
}
.holo-face[data-tex='shinyv'] .holo-shine:before {
  content: "";
  background-image:
    radial-gradient( farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsl(0, 0%, 100%) 0%,
      hsla(0, 0%, 0%, 0) 40%
    );
  background-position: center;
  background-size: cover;
  mix-blend-mode: overlay;
  opacity: 0.75;
  z-index: 1;
}
.holo-face[data-glare='shinyv'] .holo-glare {
  background-image:
    radial-gradient( farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsl(0, 0%, 90%) 5%,
      hsl(200, 5%, 45%) 80%,
      hsl(320, 40%, 10%) 150%
    );
  background-size: 120% 140%;
  background-position: center center;
  mix-blend-mode: darken;
  filter: brightness(.88) contrast(2.25) saturate(.7);
  opacity: calc( var(--card-opacity) * var(--pointer-from-center) * 0.75 );
}
.holo-face[data-tex='shinyv'] .holo-shine:after {
  --foil: var(--img-foil, url('/assets/illusion-CKHJKhiM.png'));
  --imgsize: calc(33% * var(--fx-scale, 1));
  background-blend-mode: exclusion, hue, hard-light;
  filter: brightness(calc((var(--pointer-from-center)*.3) + .35)) contrast(2) saturate(1.5);
}
.holo-face[data-tex='shinyv'] .holo-shine {
  --foil: var(--img-foil, url('/assets/illusion-CKHJKhiM.png'));
  --imgsize: calc(33% * var(--fx-scale, 1));
  background-blend-mode: exclusion, hue, hard-light;
  filter: brightness(calc((var(--pointer-from-center)*.3) + .35)) contrast(2) saturate(1.5) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='shinyv'] .holo-shine:before {
  content: none;
  display: none;
}
.holo-face[data-tex='shinyv'] .holo-shine:after {
  filter: brightness(calc((var(--pointer-from-center)*.5) + .8)) contrast(1.6) saturate(1.4);
}

/* --- Shiny VMAX --------------------------------------------------------------------------------------------------------- */
.holo-face[data-tex='shinyvmax'] .holo-shine {
  --imgsize: cover;
  --angle: -30deg;
  --r-clr-1: hsl(0, 57%, 37%);
  --r-clr-2: hsl(40, 53%, 39%);
  --r-clr-3: hsl(90, 60%, 35%);
  --r-clr-4: hsl(180, 60%, 35%);
  --r-clr-5: hsl(180, 60%, 35%);
  --r-clr-6: hsl(210, 57%, 39%);
  --r-clr-7: hsl(280, 55%, 31%);
  background-image:
    var(--glitter),
    var(--glitter),
    linear-gradient( var(--angle),
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1)
    ),
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(248, 5%, 10%, 1) 10%,
      hsla(206, 5%, 80%, 0.1) 50%,
      hsla(0, 0%, 95%, .98) 90%
    );
  background-size: var(--glittersize) var(--glittersize), var(--glittersize) var(--glittersize), 400% 400%, cover;
  background-position: 40% 45%, 55% 55%, calc( var(--background-x) * 1.5) calc( var(--background-y) * 1.5 ), center center;
  background-blend-mode: soft-light, overlay, color-burn;
  filter: brightness(1) contrast(1) saturate(.85) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='shinyvmax'] .holo-shine:before {
  content: "";
  background-image:
    var(--foil),
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(248, 5%, 91%, 0.95) 10%,
      hsla(206, 5%, 68%, 0.5) 50%,
      hsl(0, 0%, 0%) 120%
    );
  background-size: var(--imgsize), cover;
  background-position: center center, center center;
  background-blend-mode: color-burn;
  mix-blend-mode: lighten;
  filter: brightness(1) contrast(1) saturate(.4);
  opacity: 0.35;
}
.holo-face[data-tex='shinyvmax'] .holo-shine:after {
  content: "";
  background-image:
    repeating-linear-gradient(
      calc( var(--angle) ),
      var(--sunpillar-clr-1) calc(var(--space)*1),
      var(--sunpillar-clr-2) calc(var(--space)*2),
      var(--sunpillar-clr-3) calc(var(--space)*3),
      var(--sunpillar-clr-4) calc(var(--space)*4),
      var(--sunpillar-clr-5) calc(var(--space)*5),
      var(--sunpillar-clr-6) calc(var(--space)*6),
      var(--sunpillar-clr-1) calc(var(--space)*7)
    );
  background-size: 400% 800%;
  background-position: calc( 50% + (50% - (var(--background-x))) * 3 ) calc( 50% + (50% - (var(--background-y))) * 3 );
  filter: brightness(calc( 0.75 - ( var(--pointer-from-center) * 0.5 ))) contrast(1) saturate(1);
  mix-blend-mode: hue;
}
.holo-face[data-glare='shinyvmax'] .holo-glare {
  background-image:
		radial-gradient(
			farthest-corner circle at
			var(--pointer-x) var(--pointer-y),
			hsla(248, 5%, 90%, 0.45) 0%,
			hsla(206, 5%, 30%, 0.45) 45%,
			hsla(0, 0%, 0%, .33) 120%
		);
  filter: brightness(1) contrast(1.25);
}
.holo-face[data-glare='shinyvmax'] .holo-glare:after {
  content: "";
  background-image:
		radial-gradient(
			farthest-corner circle at
			var(--pointer-x) var(--pointer-y),
			hsla(248, 5%, 90%, 0.75) 0%,
			hsla(206, 5%, 30%, 0.65) 45%,
			hsla(0, 0%, 0%, .75) 100%
		);
  filter: brightness(1) contrast(1.25);
  mix-blend-mode: overlay;
  opacity: 1;
}

/* --- Amazing Rare ------------------------------------------------------------------------------------------------------- */
.holo-face[data-tex='amazing'] .holo-shine {
  background-image:
    var(--glitter),
    var(--glitter),
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(150, 20%, 10%, 1) 10%,
      hsla(177, 22%, 80%, 0.1) 50%,
      hsla(0, 0%, 95%, .98) 90%
    );
  background-size: var(--glittersize) var(--glittersize), var(--glittersize) var(--glittersize), cover;
  background-position: 40% 45%, 55% 55%, center center;
  background-blend-mode: soft-light, color-burn;
  filter: brightness(1) contrast(1) saturate(.9) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='amazing'] .holo-shine:before {
  content: "";
  background-image:
    var(--foil),
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(50, 20%, 90%, 0.95) 10%,
      rgba(181, 139, 164, 0.5) 50%,
      hsl(0, 0%, 0%) 60%
    );
  background-size: cover, cover;
  background-position: center center, center center;
  background-blend-mode: color-burn;
  mix-blend-mode: lighten;
  filter: brightness(1) contrast(1) saturate(1);
  opacity: 0.5;
}
.holo-face[data-tex='amazing'] .holo-shine:after {
  content: "";
  background-image:
    repeating-linear-gradient(
      calc( var(--angle) ),
      var(--sunpillar-clr-1) calc(var(--space)*1),
      var(--sunpillar-clr-2) calc(var(--space)*2),
      var(--sunpillar-clr-3) calc(var(--space)*3),
      var(--sunpillar-clr-4) calc(var(--space)*4),
      var(--sunpillar-clr-5) calc(var(--space)*5),
      var(--sunpillar-clr-6) calc(var(--space)*6),
      var(--sunpillar-clr-1) calc(var(--space)*7)
    );
  background-size: 400% 800%;
  background-position: calc( 50% + (50% - (var(--background-x))) * 3 ) calc( 50% + (50% - (var(--background-y))) * 3 );
  filter: brightness(calc( 0.75 - ( var(--pointer-from-center) * 0.5 ))) contrast(1) saturate(1);
  mix-blend-mode: saturation;
}
.holo-face[data-glare='amazing'] .holo-glare {
  background-image:
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 100%, 1) 10%,
      hsla(0, 0%, 100%, 0.85) 20%,
      hsla(0, 0%, 0%, 0.35) 90%
    );
  mix-blend-mode: multiply;
}

/* --- Radiant ------------------------------------------------------------------------------------------------------------ */
.holo-face[data-tex='radiant'] .holo-shine {
  --barwidth: 1.2%;
  --space: calc(200px * var(--fx-scale, 1));
  --hue: 50;
  --imgsize: cover;
  background-image:
    radial-gradient(
      farthest-corner ellipse
      at calc( ((var(--pointer-x)) * 0.5) + 25% ) calc( ((var(--pointer-y)) * 0.5) + 25% ),
      hsl(0, 0%, 95%) 20%,
      var(--card-glow) 130%
    ),
    repeating-linear-gradient(
      45deg,
      hsl(0,0%,10%) 0% ,
      hsl(0,0%,10%) 1% ,
      hsl(0,0%,10%) var(--barwidth),
      hsl(0,0%,20%) calc( var(--barwidth) + 0.01% ) ,
      hsl(0,0%,20%) calc( var(--barwidth) * 2 ),
      hsl(0,0%,35%) calc( var(--barwidth) * 2 + 0.01% ) ,
      hsl(0,0%,35%) calc( var(--barwidth) * 3 ) ,
      hsl(0,0%,42.5%) calc( var(--barwidth) * 3 + 0.01% ) ,
      hsl(0,0%,42.5%) calc( var(--barwidth) * 4 ) ,
      hsl(0,0%,50%) calc( var(--barwidth) * 4 + 0.01% ) ,
      hsl(0,0%,50%) calc( var(--barwidth) * 5 ) ,
      hsl(0,0%,42.5%) calc( var(--barwidth) * 5 + 0.01% ) ,
      hsl(0,0%,42.5%) calc( var(--barwidth) * 6 ) ,
      hsl(0,0%,35%) calc( var(--barwidth) * 6 + 0.01% ) ,
      hsl(0,0%,35%) calc( var(--barwidth) * 7 ) ,
      hsl(0,0%,20%) calc( var(--barwidth) * 7 + 0.01% ) ,
      hsl(0,0%,20%) calc( var(--barwidth) * 8 )  ,
      hsl(0,0%,10%) calc( var(--barwidth) * 8 + 0.01% ) ,
      hsl(0,0%,10%) calc( var(--barwidth) * 9 )  ,
      hsl(0,0%,0%) calc( var(--barwidth) * 9 + 0.01% ) ,
      hsl(0,0%,0%) calc( var(--barwidth) * 10 )
    ),
    repeating-linear-gradient(
      -45deg,
      hsl(0,0%,10%) 0% ,
      hsl(0,0%,10%) 1% ,
      hsl(0,0%,10%) var(--barwidth),
      hsl(0,0%,20%) calc( var(--barwidth) + 0.01% ) ,
      hsl(0,0%,20%) calc( var(--barwidth) * 2 ),
      hsl(0,0%,35%) calc( var(--barwidth) * 2 + 0.01% ) ,
      hsl(0,0%,35%) calc( var(--barwidth) * 3 ) ,
      hsl(0,0%,42.5%) calc( var(--barwidth) * 3 + 0.01% ) ,
      hsl(0,0%,42.5%) calc( var(--barwidth) * 4 ) ,
      hsl(0,0%,50%) calc( var(--barwidth) * 4 + 0.01% ) ,
      hsl(0,0%,50%) calc( var(--barwidth) * 5 ) ,
      hsl(0,0%,42.5%) calc( var(--barwidth) * 5 + 0.01% ) ,
      hsl(0,0%,42.5%) calc( var(--barwidth) * 6 ) ,
      hsl(0,0%,35%) calc( var(--barwidth) * 6 + 0.01% ) ,
      hsl(0,0%,35%) calc( var(--barwidth) * 7 ) ,
      hsl(0,0%,20%) calc( var(--barwidth) * 7 + 0.01% ) ,
      hsl(0,0%,20%) calc( var(--barwidth) * 8 )  ,
      hsl(0,0%,10%) calc( var(--barwidth) * 8 + 0.01% ) ,
      hsl(0,0%,10%) calc( var(--barwidth) * 9 )  ,
      hsl(0,0%,0%) calc( var(--barwidth) * 9 + 0.01% ) ,
      hsl(0,0%,0%) calc( var(--barwidth) * 10 )
    );
  background-size: cover, 210% 210%, 210% 210%;
  background-position:
    center,
    calc( ((var(--background-x) - 50%) * 1.5) + 50% ) calc( ((var(--background-y) - 50%) * 1.5) + 50% ),
    calc( ((var(--background-x) - 50%) * 1.5) + 50% ) calc( ((var(--background-y) - 50%) * 1.5) + 50% );
  background-blend-mode: exclusion, darken, color-dodge;
  filter: brightness(.5) contrast(2) saturate(1.75) var(--fx-filter, contrast(1));
  mix-blend-mode: color-dodge;
}
.holo-face[data-tex='radiant'] .holo-shine:after {
  content: "";
  background-image:
    var(--foil),
    repeating-linear-gradient( 55deg,
    hsl(3, 95%, 85%) calc(var(--space)*1),
    hsl(207, 100%, 84%) calc(var(--space)*2),
    hsl(29, 100%, 85%) calc(var(--space)*3),
    hsl(160, 100%, 86%) calc(var(--space)*4),
    hsl(309, 94%, 87%) calc(var(--space)*5),
    hsl(188, 95%, 85%) calc(var(--space)*6),
    hsl(3, 95%, 85%) calc(var(--space)*7)
  );
  background-size: var(--imgsize), 400% 100%;
  background-position: center, calc( ((var(--background-x) - 50%) * -2.5) + 50% ) calc( ((var(--background-y) - 50%) * -2.5) + 50% );
  filter: brightness(.6) contrast(3) saturate(2);
  mix-blend-mode: color-dodge;
  background-blend-mode: hard-light;
}
.holo-face[data-tex='radiant'] .holo-shine:before {
  content: "";
  z-index: 2;
  grid-area: 1/1;
  background-image:
    var(--glitter),
    radial-gradient(
      farthest-corner ellipse at calc( ((var(--pointer-x)) * 0.5) + 25% ) calc( ((var(--pointer-y)) * 0.5) + 25% ),
      hsla(0, 0%, 58%, 0.8) 10%,
      hsla(0, 0%, 20%, 0.9) 20%,
      hsla(0, 0%, 20%, 0.5) 50%
    );
  background-position: center;
  background-size: 15% 15%, 350% 350%;
  background-blend-mode: color-dodge;
  mix-blend-mode: overlay;
  filter: brightness(.66) contrast(2) saturate(.5);
}
.holo-face[data-glare='radiant'] .holo-glare {
  background-image:
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 100%, 0.33) 0%,
      hsl(0, 0%, 25%) 110%
    );
  filter: brightness(1) contrast(1.5);
  mix-blend-mode: hard-light;
}
.holo-face[data-tex='radiant'] .holo-shine,
.holo-face[data-tex='radiant'] .holo-shine:after {
  --foil: var(--img-foil, url('/assets/trainerbg-D5xqq63o.png'));
  --imgsize: calc(25% * var(--fx-scale, 1)) auto;
}
.holo-face[data-tex='radiant'] .holo-shine:after {
  background-blend-mode: difference;
}

/* --- Rainbow Alt -------------------------------------------------------------------------------------------------------- */
.holo-face[data-tex='rainbowalt'] .holo-shine {
  --imgsize: cover;
  --r-clr-1: hsl(0, 57%, 37%);
  --r-clr-2: hsl(40, 53%, 39%);
  --r-clr-3: hsl(90, 60%, 35%);
  --r-clr-4: hsl(180, 60%, 35%);
  --r-clr-5: hsl(180, 60%, 35%);
  --r-clr-6: hsl(210, 57%, 39%);
  --r-clr-7: hsl(280, 55%, 31%);
  background-image:
    repeating-linear-gradient(
      var(--angle),
        hsla(283, 49%, 60%, 0.75) calc(var(--space)*1),
        hsla(2, 70%, 58%, 0.75) calc(var(--space)*2),
        hsla(53, 67%, 53%, 0.75) calc(var(--space)*3),
        hsla(93, 56%, 52%, 0.75) calc(var(--space)*4),
        hsla(176, 38%, 50%, 0.75) calc(var(--space)*5),
        hsla(228, 100%, 77%, 0.75) calc(var(--space)*6),
        hsla(283, 49%, 61%, 0.75) calc(var(--space)*7)
      ),
    var(--glitter),
    linear-gradient( -30deg,
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1)
    );
  background-size: 200% 400%, var(--glittersize) var(--glittersize), 400% 400%;
  background-position: 0% calc(var(--background-y) * 1), center center, calc( var(--background-x) * 1.5) calc( var(--background-y) * 1.5 );
  background-blend-mode: luminosity, overlay;
  filter: brightness(calc((var(--pointer-from-center)*0.3) + 0.3)) contrast(3) saturate(1.8) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='rainbowalt'] .holo-shine:after {
  content: "";
  background-image:
    var(--glitter),
    linear-gradient( -60deg,
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1)
    );
  background-blend-mode: overlay;
  background-size: var(--glittersize) var(--glittersize), 400% 400%;
  background-position: center center, calc( var(--background-x) * -1.5) calc( var(--background-y) * -1.5 );
  filter: brightness(calc((var(--pointer-from-center)*0.5) + 0.6)) contrast(3) saturate(1);
  mix-blend-mode: color-dodge;
  opacity: calc(1.2 + (var(--pointer-from-center)/2) * -1);
}
.holo-face[data-tex='rainbowalt'] .holo-shine:before {
  content: "";
  background-image: var(--foil);
  background-size: var(--imgsize);
  background-position: center center;
  filter: brightness(1.5) contrast(1.5);
  opacity: calc((var(--pointer-from-center) + 0.6 ) * 0.4 );
  background-blend-mode: difference;
  mix-blend-mode: color-dodge;
}
.holo-face[data-glare='rainbowalt'] .holo-glare {
  background-image:
		radial-gradient(
			farthest-corner circle at
			var(--pointer-x) var(--pointer-y),
			hsla(50, 20%, 90%, 0.75) 0%,
			hsla(150, 20%, 30%, 0.65) 45%,
			hsla(0, 0%, 0%, 1) 100%
		);
  filter: brightness(.9) contrast(2);
  opacity: calc( var(--card-opacity) * 0.75 );
}
.holo-face[data-tex='rainbowalt'] .holo-shine {
  --foil: var(--img-foil, none);
  --imgsize: calc(25% * var(--fx-scale, 1)) auto;
}

/* --- Secret Pikachu ----------------------------------------------------------------------------------------------------- */
.holo-face[data-tex='pikachu'] .holo-shine {
  --shift: 1px;
  --imgsize: cover;
  background-image:
    var(--glitter),
    var(--glitter),
    conic-gradient(
      var(--sunpillar-clr-4),
      var(--sunpillar-clr-5),
      var(--sunpillar-clr-6),
      var(--sunpillar-clr-1),
      var(--sunpillar-clr-4)
    ),
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(150, 00%, 0%, .98) 10%,
      hsla(0, 0%, 95%, .15) 90%
    );
  background-size: var(--glittersize) var(--glittersize), var(--glittersize) var(--glittersize), cover, cover;
  background-position: 45% 45%, 55% 55%, center center, center center;
  background-blend-mode: soft-light, hard-light, overlay;
  mix-blend-mode: color-dodge;
  filter: brightness(calc( 0.4 + (var(--pointer-from-center) * 0.2) )) contrast(1) saturate(2.7) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='pikachu'] .holo-shine:before {
  content: "";
  background-image:
    var(--foil),
    linear-gradient( 45deg, hsl(46, 95%, 50%), hsl(52, 100%, 69%) ),
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(10, 20%, 90%, 0.95) 10%,
      hsl(0, 0%, 0%) 70%
    );
  background-size: var(--imgsize), cover, cover;
  background-position: center center, center center, center center;
  background-blend-mode: hard-light, multiply;
  mix-blend-mode: lighten;
  filter: brightness(1.25) contrast(1.25) saturate(0.35);
  opacity: .8;
}
.holo-face[data-tex='pikachu'] .holo-shine:after {
  content: "";
  background-image: var(--glitter);
  background-size: var(--glittersize) var(--glittersize);
  background-position: calc(50% - ((var(--shift)*2) * var(--pointer-from-left)) + var(--shift)) calc(50% - ((var(--shift)*2) * var(--pointer-from-top)) + var(--shift));
  filter: brightness(calc((var(--pointer-from-center)*0.6) + 0.6)) contrast(1.5);
  mix-blend-mode: overlay;
}
.holo-face[data-glare='pikachu'] .holo-glare {
  background-image:
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(45, 8%, 80%, 0.3) 0%,
      hsl(22, 15%, 12%) 180%
    );
  filter: brightness(1.3) contrast(1.5);
  mix-blend-mode: hard-light;
}
.holo-face[data-tex='pikachu'] .holo-shine {
  --foil: var(--img-foil, url('/assets/geometric-CQlKBuz8.png'));
  --imgsize: calc(33% * var(--fx-scale, 1));
  filter: brightness( calc( ( var( --pointer-from-center ) * 0.3 ) + 0.2 ) ) contrast(2) saturate(0.75) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='pikachu'] .holo-shine {
  --r-clr-1: hsl(0, 57%, 37%);
  --r-clr-2: hsl(40, 53%, 39%);
  --r-clr-3: hsl(90, 60%, 35%);
  --r-clr-4: hsl(180, 60%, 35%);
  --r-clr-5: hsl(180, 60%, 35%);
  --r-clr-6: hsl(210, 57%, 39%);
  --r-clr-7: hsl(280, 55%, 31%);
  background-image:
    linear-gradient(-45deg, var(--r-clr-1), var(--r-clr-5)),
    var(--glitter),
    linear-gradient( -30deg,
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1)
    );
  background-blend-mode: luminosity, soft-light;
  background-size:
    200% 200%,
    var(--glittersize) var(--glittersize),
    400% 400%;
  background-position:
    calc( 25% + (50% * var(--pointer-from-left) )) calc( 25% + (50% * var(--pointer-from-top) )),
    calc(50% - ((var(--shift)*2) * var(--pointer-from-left)) + var(--shift)) calc(50% - ((var(--shift)*2) * var(--pointer-from-top)) + var(--shift)),
    calc( 25% + (var(--pointer-x) / 2 ) ) calc( 25% + (var(--pointer-y) / 2 ) );
  filter: brightness(calc((var(--pointer-from-center)*0.5) + .75)) contrast(2) saturate(1) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='pikachu'] .holo-shine:after {
  content: "";
  background-image:
    var(--glitter),
    linear-gradient( -60deg,
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1), var(--r-clr-2), var(--r-clr-3), var(--r-clr-4), var(--r-clr-5), var(--r-clr-6), var(--r-clr-7),
      var(--r-clr-1)
    );
  background-blend-mode: soft-light;
  background-size:
    var(--glittersize) var(--glittersize),
    400% 400%;
  background-position:
    calc(50% - ((var(--shift)*2) * var(--pointer-from-left)) - var(--shift)) calc(50% - ((var(--shift)*2) * var(--pointer-from-top)) - var(--shift)),
    var(--pointer-x) var(--pointer-y);
  filter: brightness(calc((var(--pointer-from-center)*0.35) + 0.35)) contrast(2) saturate(1);
  mix-blend-mode: exclusion;
}
.holo-face[data-tex='pikachu'] .holo-shine:before {
  content: "";
  background-image: var(--foil);
  background-size: var(--imgsize);
  background-position: center center;
  filter: brightness(2.5) contrast(1);
  opacity: calc((var(--pointer-from-center) + 0.4 ) * 0.6 );
  mix-blend-mode: multiply;
}
.holo-face[data-glare='pikachu'] .holo-glare {
  background-image:
    radial-gradient( farthest-corner circle at var(--pointer-x) var(--pointer-y), hsl(0,0%,80%), hsla(0, 0%, 74.9%, 0.25) 30%, hsl(0, 0%, 21.6%) 130% );
  filter: brightness(.9) contrast(2);
  opacity: calc( var(--pointer-from-center) * .9 );
  mix-blend-mode: hard-light;
}
.holo-face[data-tex='pikachu'] .holo-shine {
  --foil: var(--img-foil, url('/assets/illusion-mask-CV2Insva.png'));
  --imgsize: calc(33% * var(--fx-scale, 1));
}

/* --- Trainer Full Art --------------------------------------------------------------------------------------------------- */
.holo-face[data-tex='trainerfull'] .holo-shine:after {
  --space: calc(5% * var(--fx-scale, 1));
  --angle: 133deg;
  --imgsize: cover;
  background-image:
    var(--foil),
    repeating-linear-gradient( 0deg,
      var(--sunpillar-clr-1) calc(var(--space)*1),
      var(--sunpillar-clr-2) calc(var(--space)*2),
      var(--sunpillar-clr-3) calc(var(--space)*3),
      var(--sunpillar-clr-4) calc(var(--space)*4),
      var(--sunpillar-clr-5) calc(var(--space)*5),
      var(--sunpillar-clr-6) calc(var(--space)*6),
      var(--sunpillar-clr-1) calc(var(--space)*7)
    ),
    repeating-linear-gradient(
      var(--angle),
      #0e152e 0%,
      hsl(180, 10%, 60%) 3.8%,
      hsl(180, 29%, 66%) 4.5%,
      hsl(180, 10%, 60%) 5.2%,
      #0e152e 10% ,
      #0e152e 12%
      ),
    radial-gradient(
      farthest-corner circle
      at var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 0%, 0.1) 12%,
      hsla(0, 0%, 0%, 0.15) 20%,
      hsla(0, 0%, 0%, 0.25) 120%
    );
  background-position:
    center center,
    0% var(--background-y),
    calc( var(--background-x) + (var(--background-y)*0.2) ) var(--background-y),
    var(--background-x) var(--background-y);
  background-blend-mode: soft-light, hue, hard-light;
  background-size: var(--imgsize), 200% 700%, 300% 100%, 200% 100%;
  filter: brightness(calc((var(--pointer-from-center)*0.4) + .4)) contrast(1.4) saturate(2.25);
}
.holo-face[data-tex='trainerfull'] .holo-shine {
  --space: calc(5% * var(--fx-scale, 1));
  --angle: 133deg;
  --imgsize: cover;
  background-image:
    var(--foil),
    repeating-linear-gradient( 0deg,
      var(--sunpillar-clr-1) calc(var(--space)*1),
      var(--sunpillar-clr-2) calc(var(--space)*2),
      var(--sunpillar-clr-3) calc(var(--space)*3),
      var(--sunpillar-clr-4) calc(var(--space)*4),
      var(--sunpillar-clr-5) calc(var(--space)*5),
      var(--sunpillar-clr-6) calc(var(--space)*6),
      var(--sunpillar-clr-1) calc(var(--space)*7)
    ),
    repeating-linear-gradient(
      var(--angle),
      #0e152e 0%,
      hsl(180, 10%, 60%) 3.8%,
      hsl(180, 29%, 66%) 4.5%,
      hsl(180, 10%, 60%) 5.2%,
      #0e152e 10% ,
      #0e152e 12%
      ),
    radial-gradient(
      farthest-corner circle
      at var(--pointer-x) var(--pointer-y),
      hsla(0, 0%, 0%, 0.1) 12%,
      hsla(0, 0%, 0%, 0.15) 20%,
      hsla(0, 0%, 0%, 0.25) 120%
    );
  background-position:
    center center,
    0% var(--background-y),
    calc( var(--background-x) + (var(--background-y)*0.2) ) var(--background-y),
    var(--background-x) var(--background-y);
  background-blend-mode: soft-light, hue, hard-light;
  background-size: var(--imgsize), 200% 700%, 300% 100%, 200% 100%;
  filter: brightness(calc((var(--pointer-from-center)*0.4) + .4)) contrast(1.4) saturate(2.25) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='trainerfull'] .holo-shine:after {
  content: "";
  background-position:
    center center,
    0% var(--background-y),
    calc( (var(--background-x) + (var(--background-y)*0.2)) * -1) calc( var(--background-y) * -1),
    var(--background-x) var(--background-y);
  background-size: var(--imgsize), 200% 400%, 195% 100%, 200% 100%;
  filter: brightness(calc((var(--pointer-from-center)*.4) + .8)) contrast(1.5) saturate(1.25);
  mix-blend-mode: exclusion;
}
.holo-face[data-tex='trainerfull'] .holo-shine:before {
  content: "";
  background-image:
    radial-gradient( farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsl(0, 0%, 100%) 0%,
      hsla(0, 0%, 0%, 0) 40%
    );
  background-position: center;
  background-size: cover;
  mix-blend-mode: overlay;
  opacity: 0.75;
  z-index: 1;
}
.holo-face[data-glare='trainerfull'] .holo-glare {
  background-image:
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsl(0, 0%, 75%) 5%,
      hsl(200, 5%, 35%) 60%,
      hsl(320, 40%, 10%) 150%
    );
  background-size: 120% 150%;
  background-position: center center;
  mix-blend-mode: hard-light;
  filter: brightness(1) contrast(1.2) saturate(1);
  opacity: calc(var(--card-opacity) * .75 );
}
.holo-face[data-tex='trainerfull'] .holo-shine {
  filter: brightness(calc((var(--pointer-from-center)*0.05) + .8)) contrast(1.75) saturate(1.2) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='trainerfull'] .holo-shine:after {
  filter: brightness(calc((var(--pointer-from-center)*.4) + .85)) contrast(2) saturate(.5);
}
.holo-face[data-tex='trainerfull'] .holo-shine:before {
  background-image:
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsl(0, 0%, 100%) 0%,
      hsla(0, 0%, 0%, 0) 80%
    );
  mix-blend-mode: screen;
  opacity: 0.5;
}
.holo-face[data-glare='trainerfull'] .holo-glare {
  opacity: calc( var(--card-opacity) * .75 );
  mix-blend-mode: multiply;
  filter: brightness(1.5) contrast(1.4) saturate(1);
  background-size: 170% 170%;
}
.holo-face[data-tex='trainerfull'] .holo-shine:after {
  --foil: var(--img-foil, url('/assets/trainerbg-D5xqq63o.png'));
  --imgsize: calc(20% * var(--fx-scale, 1));
  background-blend-mode: color-burn, hue, hard-light;
  filter: brightness(calc((var(--pointer-from-center)*0.05) + .6)) contrast(1.5) saturate(1.2);
}
.holo-face[data-tex='trainerfull'] .holo-shine {
  --foil: var(--img-foil, url('/assets/trainerbg-D5xqq63o.png'));
  --imgsize: calc(20% * var(--fx-scale, 1));
  background-blend-mode: color-burn, hue, hard-light;
  filter: brightness(calc((var(--pointer-from-center)*0.05) + .6)) contrast(1.5) saturate(1.2) var(--fx-filter, contrast(1));
}

/* --- Trainer Gallery Secret --------------------------------------------------------------------------------------------- */
.holo-face[data-tex='tgsecret'] .holo-shine {
  --shift: 1px;
  --imgsize: cover;
  background-image:
    var(--glitter),
    var(--glitter),
    conic-gradient(
      var(--sunpillar-clr-4),
      var(--sunpillar-clr-5),
      var(--sunpillar-clr-6),
      var(--sunpillar-clr-1),
      var(--sunpillar-clr-4)
    ),
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(150, 00%, 0%, .98) 10%,
      hsla(0, 0%, 95%, .15) 90%
    );
  background-size: var(--glittersize) var(--glittersize), var(--glittersize) var(--glittersize), cover, cover;
  background-position: 45% 45%, 55% 55%, center center, center center;
  background-blend-mode: soft-light, hard-light, overlay;
  mix-blend-mode: color-dodge;
  filter: brightness(calc( 0.4 + (var(--pointer-from-center) * 0.2) )) contrast(1) saturate(2.7) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='tgsecret'] .holo-shine:before {
  content: "";
  background-image:
    var(--foil),
    linear-gradient( 45deg, hsl(46, 95%, 50%), hsl(52, 100%, 69%) ),
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(10, 20%, 90%, 0.95) 10%,
      hsl(0, 0%, 0%) 70%
    );
  background-size: var(--imgsize), cover, cover;
  background-position: center center, center center, center center;
  background-blend-mode: hard-light, multiply;
  mix-blend-mode: lighten;
  filter: brightness(1.25) contrast(1.25) saturate(0.35);
  opacity: .8;
}
.holo-face[data-tex='tgsecret'] .holo-shine:after {
  content: "";
  background-image: var(--glitter);
  background-size: var(--glittersize) var(--glittersize);
  background-position: calc(50% - ((var(--shift)*2) * var(--pointer-from-left)) + var(--shift)) calc(50% - ((var(--shift)*2) * var(--pointer-from-top)) + var(--shift));
  filter: brightness(calc((var(--pointer-from-center)*0.6) + 0.6)) contrast(1.5);
  mix-blend-mode: overlay;
}
.holo-face[data-glare='tgsecret'] .holo-glare {
  background-image:
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(45, 8%, 80%, 0.3) 0%,
      hsl(22, 15%, 12%) 180%
    );
  filter: brightness(1.3) contrast(1.5);
  mix-blend-mode: hard-light;
}
.holo-face[data-tex='tgsecret'] .holo-shine {
  --foil: var(--img-foil, url('/assets/geometric-CQlKBuz8.png'));
  --imgsize: calc(33% * var(--fx-scale, 1));
  filter: brightness( calc( ( var( --pointer-from-center ) * 0.3 ) + 0.2 ) ) contrast(2) saturate(0.75) var(--fx-filter, contrast(1));
}
.holo-face[data-tex='tgsecret'] .holo-shine {
  background-image:
    var(--glitter),
    var(--glitter),
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsl(152.7, 21.6%, 10%) 10%,
      hsla(177, 22%, 80%, 0.1) 50%,
      hsla(0, 0%, 95%, .98) 90%
    ),
    linear-gradient( 45deg, hsl(46, 95%, 50%), hsl(52, 100%, 69%) );
  background-size:
    var(--glittersize) var(--glittersize),
    var(--glittersize) var(--glittersize),
    cover,
    cover;
  background-position:
    40% 45%,
    55% 55%,
    center center,
    center center;
  background-blend-mode: soft-light, darken, color;
  filter: brightness(1) contrast(1) saturate(1) var(--fx-filter, contrast(1));
  mix-blend-mode: color-dodge;
}
.holo-face[data-tex='tgsecret'] .holo-shine:before {
  content: "";
  background-image:
    var(--foil),
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(50, 20%, 90%, 0.95) 10%,
      hsla(324, 22%, 63%, 0.5) 50%,
      hsl(0, 0%, 0%) 90%
    );
  background-size: var(--imgsize), cover;
  background-position: center center, center center;
  background-blend-mode: color-burn;
  mix-blend-mode: exclusion;
  filter: brightness(1) contrast(1) saturate(1);
  opacity: 1;
}
.holo-face[data-tex='tgsecret'] .holo-shine:after {
  content: "";
  background-image:
    var(--glitter),
    conic-gradient(
      var(--sunpillar-clr-4),
      var(--sunpillar-clr-5),
      var(--sunpillar-clr-6),
      var(--sunpillar-clr-1),
      var(--sunpillar-clr-2),
      var(--sunpillar-clr-3),
      var(--sunpillar-clr-4)
    );
  background-size: var(--glittersize) var(--glittersize), cover;
  background-blend-mode: luminosity;
  filter: brightness(calc((var(--pointer-from-center)*0.5) + 0.6)) contrast(2) saturate(3);
  mix-blend-mode: soft-light;
}
.holo-face[data-glare='tgsecret'] .holo-glare {
  background-image:
    radial-gradient(
      farthest-corner circle at var(--pointer-x) var(--pointer-y),
      hsla(40, 100%, 95%, 0.2) 10%,
      hsla(40, 20%, 5%, 1) 180%
    );
  filter: brightness(1) contrast(1);
  mix-blend-mode: hard-light;
}
.holo-face[data-tex='tgsecret'] .holo-shine {
  --foil: var(--img-foil, url('/assets/geometric-CQlKBuz8.png'));
  --imgsize: calc(33% * var(--fx-scale, 1));
  filter: brightness( calc( ( var( --pointer-from-center ) * 0.3 ) + 0.2 ) ) contrast(2) saturate(0.75) var(--fx-filter, contrast(1));
}
.holo-face[data-glare='tgsecret'] .holo-glare {
  filter: brightness(.5) contrast(1);
}

/* --- ajouts pour la bibliothèque d'effets (écrits pour cette application, pas repris du projet d'origine) ------------- */

/* métal miroir (« Gold », « Silver ») : la couleur du métal remplace en grande partie l'illustration dans les zones d'effet,
   avec des bandes claires et sombres qui défilent et tournent avec l'inclinaison, plus un trait de lumière net (le miroir) */
.holo-face[data-tex='goldfoil'] .holo-shine {
  --metal-dark: #4a3005;
  --metal-mid: #b8860b;
  --metal-light: #f3cf63;
  --metal-hot: #fff3c2;
}
.holo-face[data-tex='silverfoil'] .holo-shine {
  --metal-dark: #24282d;
  --metal-mid: #6a7078;
  --metal-light: #b7bdc5;
  --metal-hot: #f2f4f7;
  --metal-contrast: 1.35;
}
.holo-face[data-tex='goldfoil'] .holo-shine,
.holo-face[data-tex='silverfoil'] .holo-shine {
  background-image: linear-gradient(
    calc(105deg + (var(--pointer-from-left) - 0.5) * 50deg),
    var(--metal-dark) 0%, var(--metal-light) 10%, var(--metal-mid) 19%, var(--metal-hot) 27%, var(--metal-dark) 37%,
    var(--metal-mid) 48%, var(--metal-hot) 57%, var(--metal-light) 64%, var(--metal-dark) 76%, var(--metal-light) 88%, var(--metal-mid) 100%
  );
  background-size: calc(260% * var(--fx-scale, 1)) calc(260% * var(--fx-scale, 1));
  background-position: var(--background-x) var(--background-y);
  filter: brightness(1) contrast(var(--metal-contrast, 1.2)) saturate(1.1) var(--fx-filter, contrast(1));
  mix-blend-mode: hard-light;
}
.holo-face[data-tex='goldfoil'] .holo-shine:after,
.holo-face[data-tex='silverfoil'] .holo-shine:after {
  content: '';
  background-image: linear-gradient(115deg, transparent 45%, rgba(255, 255, 255, 0.6) 49%, rgba(255, 255, 255, 0.8) 50%, transparent 55%);
  background-size: 300% 300%;
  background-position: calc(((50% - var(--background-x)) * 3) + 50%) calc(((50% - var(--background-y)) * 3) + 50%);
  mix-blend-mode: screen;
}
.holo-face[data-glare='goldfoil'] .holo-glare,
.holo-face[data-glare='silverfoil'] .holo-glare {
  background-image: radial-gradient(farthest-corner circle at var(--pointer-x) var(--pointer-y), hsla(0, 0%, 100%, 1) 4%, var(--glare-metal) 28%, hsla(0, 0%, 0%, 0.75) 95%);
  mix-blend-mode: overlay;
  opacity: calc(var(--card-opacity) * 0.9);
}
.holo-face[data-glare='goldfoil'] .holo-glare {
  --glare-metal: hsla(45, 90%, 60%, 0.6);
}
/* argent : le reflet retire la couleur de l'illustration (fusion « saturation » avec un gris neutre) pour un ton métal froid */
.holo-face[data-glare='silverfoil'] .holo-glare {
  background-image: linear-gradient(hsl(210, 6%, 60%), hsl(210, 6%, 60%));
  mix-blend-mode: saturation;
  opacity: calc(var(--card-opacity) * 0.8);
}

/* reflet « off » : aucun reflet ; reflet « white » : le halo blanc de base, à pleine force */
.holo-face[data-glare='off'] .holo-glare {
  display: none;
}

/* texture importée : l'image (--tex-img) en motif répété, fixé à la carte (incrusté, comme imprimé) ; seule la lumière bouge :
   « irisée » fait glisser des bandes arc-en-ciel dans le motif avec le pointeur. Mode de fusion avec la carte : --tex-blend. */
.holo-face[data-tex='image'] .holo-shine {
  --tex-size: calc(33% * var(--fx-scale, 1));
  background-image:
    var(--tex-img),
    repeating-linear-gradient(110deg, var(--violet), var(--blue), var(--green), var(--yellow), var(--red), var(--violet), var(--blue), var(--green), var(--yellow), var(--red), var(--violet));
  background-size: var(--tex-size), 400% 400%;
  background-position:
    center center,
    calc(((50% - var(--background-x)) * 2.6) + 50%) calc(((50% - var(--background-y)) * 3.5) + 50%);
  background-blend-mode: multiply;
  filter: brightness(0.95) contrast(1.4) saturate(1.2) var(--fx-filter, contrast(1));
  mix-blend-mode: var(--tex-blend, color-dodge);
}
.holo-face[data-tex='image'][data-iris='false'] .holo-shine {
  background-image: var(--tex-img);
}
/* Finitions d'impression simulées par Printicards (code propre à ce projet, ajouté aux effets de ./holo/holo.css) :
   format de carte variable, dorure à chaud, vernis sélectif (la texture et la feuille holo sont dans
   ./holo/holo.css, communes avec le TCG Processor).
   Ces calques n'utilisent que les variables écrites par le moteur (HoloCard.jsx) : --pointer-*, --background-*, --card-o. */

/* --- format ----------------------------------------------------------------------------------------------------------- */
.holo {
  aspect-ratio: var(--card-ratio, 63 / 88);
}
.gallery-zoom-card {
  width: min(92vw, calc((100vh - 7rem) * var(--card-ratio, 63 / 88)));
}
.holo-missing {
  aspect-ratio: var(--card-ratio, 63 / 88);
}

/* Chaque face forme son propre groupe de fusion : sans cela, dans un contexte 3D (preserve-3d + backface-visibility),
   Chromium fusionne les calques color-dodge / overlay avec un fond vide et l'illustration disparaît sous l'effet. */
.holo-face {
  isolation: isolate;
}

/* --- calques de finition : masqués par la couche du client (opaque = finition présente) ------------------------------- */
.holo-stamp,
.holo-varnish {
  position: absolute;
  inset: 0;
  pointer-events: none;
  -webkit-mask: var(--layer-mask) center / 100% 100% no-repeat;
  mask: var(--layer-mask) center / 100% 100% no-repeat;
}

/* Dorure à chaud : film métallique opaque et poli miroir, visible même carte à plat. Il reflète un « décor » de bandes
   claires et sombres à bords nets (--st-0 sombre → --st-3 éclat) qui défilent vite avec l'inclinaison, plus un trait de
   lumière (::before) et un point spéculaire serré sous le pointeur (::after). */
.holo-stamp {
  --st-0: #2e1f04;
  --st-1: #8a6516;
  --st-2: #e2bb4f;
  --st-3: #fff8dc;
  z-index: 5;
  background-image: linear-gradient(
    calc(100deg + (var(--pointer-from-left) - 0.5) * 60deg),
    var(--st-0) 0%, var(--st-2) 7%, var(--st-3) 10%, var(--st-1) 14%, var(--st-0) 23%,
    var(--st-1) 33%, var(--st-3) 40%, var(--st-3) 43%, var(--st-1) 47%, var(--st-0) 56%,
    var(--st-2) 66%, var(--st-3) 70%, var(--st-1) 76%, var(--st-0) 86%, var(--st-2) 95%, var(--st-3) 100%
  );
  background-size: 400% 400%;
  background-position: calc(((50% - var(--background-x)) * 4) + 50%) calc(((50% - var(--background-y)) * 4) + 50%);
  filter: contrast(1.25) saturate(1.1);
}
.holo-stamp::before,
.holo-stamp::after {
  content: '';
  position: absolute;
  inset: 0;
  mix-blend-mode: screen;
}
.holo-stamp::before {
  background-image: linear-gradient(115deg, transparent 44%, rgba(255, 255, 255, 0.8) 49.4%, #fff 50%, rgba(255, 255, 255, 0.8) 50.6%, transparent 56%);
  background-size: 300% 300%;
  background-position: calc(((50% - var(--background-x)) * 5) + 50%) calc(((50% - var(--background-y)) * 5) + 50%);
}
.holo-stamp::after {
  background-image: radial-gradient(circle at var(--pointer-x) var(--pointer-y), #fff 0%, rgba(255, 255, 255, 0.75) 4%, rgba(255, 255, 255, 0) 18%);
  opacity: var(--card-o);
}
.holo-stamp[data-stamp='silver'] {
  --st-0: #1c1f23;
  --st-1: #6d747c;
  --st-2: #c9ced4;
  --st-3: #ffffff;
}
.holo-stamp[data-stamp='copper'] {
  --st-0: #2e1206;
  --st-1: #8c4a26;
  --st-2: #e3976b;
  --st-3: #ffe6d6;
}
.holo-stamp[data-stamp='rose'] {
  --st-0: #3d1c22;
  --st-1: #a2636b;
  --st-2: #ecbcbe;
  --st-3: #fff4f2;
}
.holo-stamp[data-stamp='holo'] {
  background-image: linear-gradient(
    calc(100deg + (var(--pointer-from-left) - 0.5) * 60deg),
    #1d1d24 0%, hsl(2, 100%, 80%) 8%, hsl(53, 100%, 82%) 14%, #1d1d24 22%, hsl(93, 100%, 78%) 32%, #ffffff 40%,
    hsl(176, 100%, 80%) 46%, #1d1d24 55%, hsl(228, 100%, 82%) 66%, hsl(283, 100%, 82%) 74%, #ffffff 80%, #1d1d24 90%, hsl(2, 100%, 80%) 100%
  );
}

/* Vernis sélectif : vernis UV ultra brillant, presque miroir. Transparent à plat ; quand la lumière (le pointeur) passe,
   il renvoie un point spéculaire très serré et des reflets nets, clairs et sombres (bandes à bords francs, comme une fenêtre
   dans un miroir) : en « hard-light », ils éclaircissent et assombrissent l'impression, y compris sur les couleurs claires. */
.holo-varnish {
  z-index: 6;
  background-image:
    radial-gradient(circle at var(--pointer-x) var(--pointer-y), #fff 0%, rgba(255, 255, 255, 0.95) 3%, rgba(255, 255, 255, 0.45) 10%, rgba(255, 255, 255, 0) 30%),
    repeating-linear-gradient(
      calc(110deg + (var(--pointer-from-left) - 0.5) * 40deg),
      rgba(0, 0, 0, 0.35) 0 6%, transparent 6.4% 14%, rgba(255, 255, 255, 0.9) 14.4% 19%, transparent 19.4% 22%,
      rgba(255, 255, 255, 0.7) 22.4% 24%, transparent 24.4% 32%, rgba(0, 0, 0, 0.25) 32.4% 36%, transparent 36.4% 40%
    ),
    linear-gradient(160deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0) 55%, rgba(255, 255, 255, 0.2));
  background-size: 100% 100%, 150% 150%, 100% 100%;
  background-position: center, calc(((50% - var(--background-x)) * 5) + 50%) calc(((50% - var(--background-y)) * 5) + 50%), center;
  mix-blend-mode: hard-light;
  opacity: var(--card-o);
}
.holo:not([data-live='true']) .holo-varnish,
.holo[data-motion='false'] .holo-varnish {
  display: none;
}
/* Administration : onglets et onglet « Wording » (textes français / anglais) */
.admin-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.wording-tools {
  flex-wrap: wrap;
}
.wording-tools input[type='search'] {
  flex: 1 1 16rem;
}
.wording-save {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
  background: linear-gradient(rgba(5, 8, 20, 0.96), rgba(5, 8, 20, 0.85));
}
.wording-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.wording-item {
  padding: 10px 12px;
}
.wording-key {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px;
  margin: 0 0 6px;
  font-size: 11px;
  color: var(--pv-grey-text);
}
.wording-key code {
  color: var(--pv-orange);
}
.wording-key .app-link {
  margin-left: auto;
}
.wording-langs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 6px 12px;
}
.wording-field {
  display: grid;
  gap: 2px;
}
.wording-field .pv-input {
  resize: vertical;
}
.wording-field.is-changed .pv-input {
  border-color: var(--pv-orange);
}
