/*
  Infinite Life — thème néon bleu clair
  ------------------------------------
  UI sombre + accents néon, sans dépendances.
  Ce fichier stylise le layout simple (<header><nav>...) et les pages.

  Louana-like dark UI (bleu → violet)
  -------------------------------------------------
  Fond très sombre, surfaces translucides, accents bleu-indigo et violet,
  glow subtil, hovers fluides, footer collé en bas,
  boutons: bordure animée (UNIQUEMENT la bordure),
  curseurs: personnalisés aux couleurs du site (base + pointer).
*/

:root {
  /* Base */
  --bg0: #050505;
  --bg1: #070a12;
  --text: #f8fafc;
  --muted: rgba(248, 250, 252, .70);

  /* Accents (bleu → violet) */
  --accent1: #3c50e6;
  /* indigo/bleu */
  --accent2: #8232e6;
  /* violet */
  --accent3: #6aa8ff;
  /* bleu clair (hover/halo) */

  /* Surfaces */
  --panel: rgba(255, 255, 255, .04);
  --panel2: rgba(255, 255, 255, .03);
  --border: rgba(255, 255, 255, .10);
  --border2: rgba(255, 255, 255, .07);

  /* Layout */
  --max: 1100px;
  --r: 16px;
  --r2: 12px;

  /* Effets */
  --shadow: 0 18px 70px rgba(0, 0, 0, .55);
  --glow: 0 0 0 1px rgba(130, 50, 230, .16),
    0 12px 45px rgba(60, 80, 230, .14);
  --glowStrong: 0 0 0 1px rgba(106, 168, 255, .22),
    0 16px 60px rgba(130, 50, 230, .20);

  /* Typo */
  --font: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial,
    "Apple Color Emoji", "Segoe UI Emoji";

  /* Motion */
  --ease: cubic-bezier(.2, .8, .2, 1);
  --tFast: 160ms;
  --t: 260ms;

  /* Animations */
  --bgMove: 18s;
  --float: 6s;
}

* {
  box-sizing: border-box;
}

/* Respecte les préférences d’accessibilité */
@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

html,
body {
  height: 100%;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;

  margin: 0;
  font-family: var(--font);
  color: var(--text);
  line-height: 1.55;
  background:
    radial-gradient(1200px 800px at 25% 12%, rgba(60, 80, 230, .22), transparent 60%),
    radial-gradient(900px 650px at 78% 38%, rgba(130, 50, 230, .18), transparent 62%),
    radial-gradient(1100px 700px at 55% 110%, rgba(106, 168, 255, .10), transparent 60%),
    linear-gradient(180deg, var(--bg0), var(--bg1));
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  /* Curseur principal (base) */
  cursor: url("data:image/svg+xml;utf8,\
<svg xmlns='http://www.w3.org/2000/svg' width='32' height='32'>\
<defs><linearGradient id='g' x1='0' y1='0' x2='1' y2='1'>\
<stop offset='0%25' stop-color='%233c50e6'/>\
<stop offset='100%25' stop-color='%238232e6'/>\
</linearGradient></defs>\
<circle cx='16' cy='16' r='6' fill='url(%23g)'/>\
</svg>") 16 16, auto;
}

/* Fond animé (très léger) */
body::before,
body::after {
  content: "";
  position: fixed;
  inset: -20vh;
  z-index: -1;
  pointer-events: none;
  opacity: .55;
}

body::before {
  background:
    radial-gradient(800px 560px at 10% 20%, rgba(60, 80, 230, .18), transparent 60%),
    radial-gradient(760px 520px at 90% 30%, rgba(130, 50, 230, .14), transparent 62%),
    radial-gradient(900px 640px at 50% 110%, rgba(106, 168, 255, .10), transparent 62%);
  filter: blur(10px);
  animation: bgDrift var(--bgMove) var(--ease) infinite alternate;
}

body::after {
  background: linear-gradient(120deg, rgba(60, 80, 230, .06), rgba(130, 50, 230, .05), rgba(106, 168, 255, .04));
  mix-blend-mode: screen;
  animation: bgSheen calc(var(--bgMove) * 1.2) linear infinite;
}

@keyframes bgDrift {
  0% { transform: translate3d(-1.5%, -1.2%, 0) scale(1); }
  100% { transform: translate3d(1.6%, 1.3%, 0) scale(1.02); }
}

@keyframes bgSheen {
  0% { transform: translate3d(-6%, 0, 0) rotate(-1deg); }
  100% { transform: translate3d(6%, 0, 0) rotate(1deg); }
}

::selection {
  background: rgba(60, 80, 230, .28);
}

/* -------------------------
   Liens
-------------------------- */
a {
  color: rgba(106, 168, 255, .95);
  text-decoration: none;
  position: relative;
  transition: color var(--tFast) var(--ease);
}

a:hover {
  text-decoration: none;
}

/* underline animée (plus "premium") */
a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, var(--accent1), var(--accent2));
  transform: scaleX(0);
  transform-origin: left;
  opacity: .85;
  transition: transform var(--t) var(--ease), opacity var(--tFast) var(--ease);
}

a:hover::after {
  transform: scaleX(1);
  opacity: 1;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: none;
  box-shadow: var(--glowStrong);
}

/* -------------------------
   Layout
-------------------------- */
main {
  width: min(var(--max), calc(100% - 32px));
  margin: 28px auto 60px;
  flex: 1 0 auto;
  /* laisse le footer se coller en bas */
}

/* Header / Nav (layout/layout.php utilise <header><nav><a ...>) */
header {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 16px 0;
  background: linear-gradient(180deg, rgba(5, 5, 5, .86), rgba(5, 5, 5, .55));
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border2);
}

header nav {
  width: min(var(--max), calc(100% - 32px));
  margin-inline: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

header nav a {
  display: inline-flex;
  align-items: center;
  padding: 10px 12px;
  border-radius: 999px;
  color: var(--text);
  background: rgba(255, 255, 255, .03);
  border: 1px solid var(--border2);
  transition:
    transform var(--tFast) var(--ease),
    box-shadow var(--tFast) var(--ease),
    border-color var(--tFast) var(--ease),
    background var(--tFast) var(--ease);
}

header nav a:hover {
  text-decoration: none;
  transform: translateY(-1px);
  border-color: rgba(106, 168, 255, .35);
  box-shadow: var(--glow);
  background: rgba(255, 255, 255, .05);
}

/* -------------------------
   Typo
-------------------------- */
h1,
h2,
h3 {
  margin: 0 0 14px;
  letter-spacing: .2px;
}

h1 {
  font-size: clamp(26px, 2.8vw, 38px);
  background: linear-gradient(90deg, var(--text), rgba(248, 250, 252, .92));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 18px 60px rgba(0, 0, 0, .45);
}

h3 {
  font-size: 18px;
}

p {
  margin: 0 0 12px;
  color: var(--muted);
}

small {
  color: rgba(248, 250, 252, .58);
}

/* Utilitaire: texte en dégradé */
.text-gradient {
  background: linear-gradient(90deg, var(--accent1), var(--accent2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* -------------------------
   Hero
-------------------------- */
.hero {
  padding: 34px 26px;
  border-radius: var(--r);
  background: linear-gradient(180deg, rgba(255, 255, 255, .055), rgba(255, 255, 255, .03));
  border: 1px solid var(--border2);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;

  /* parallax JS */
  transform: translate3d(calc(var(--mx, 0) * 1px), calc(var(--my, 0) * 1px), 0);
  transition: transform 240ms var(--ease);
}

.hero::before {
  content: "";
  position: absolute;
  inset: -80px;
  background:
    radial-gradient(circle at 30% 20%, rgba(60, 80, 230, .22), transparent 52%),
    radial-gradient(circle at 75% 35%, rgba(130, 50, 230, .18), transparent 55%);
  filter: blur(8px);
  pointer-events: none;
}

.hero::after {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  background: conic-gradient(from 210deg, rgba(60, 80, 230, .22), rgba(130, 50, 230, .20), rgba(106, 168, 255, .18), rgba(60, 80, 230, .22));
  opacity: .22;
  filter: blur(18px);
  animation: aurora 10s linear infinite;
  pointer-events: none;
}

@keyframes aurora {
  0% { transform: translate3d(-2%, -1%, 0) rotate(0deg); }
  100% { transform: translate3d(2%, 1%, 0) rotate(360deg); }
}

.hero a {
  display: inline-flex;
  padding: 10px 14px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(60, 80, 230, .25), rgba(130, 50, 230, .20));
  border: 1px solid rgba(106, 168, 255, .22);
  color: rgba(248, 250, 252, .95);
  transition:
    box-shadow var(--tFast) var(--ease),
    transform var(--tFast) var(--ease),
    background var(--tFast) var(--ease);
}

.hero a:hover {
  background: linear-gradient(90deg, rgba(60, 80, 230, .32), rgba(130, 50, 230, .26));
  box-shadow: var(--glow);
  transform: translateY(-1px);
}

/* -------------------------
   Grille boutique
-------------------------- */
.grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 16px;
  margin-top: 16px;
}

.grid>* {
  grid-column: span 12;
}

@media (min-width: 680px) {
  .grid>* {
    grid-column: span 6;
  }
}

@media (min-width: 980px) {
  .grid>* {
    grid-column: span 4;
  }
}

/* -------------------------
   Cards
-------------------------- */
.card {
  background: linear-gradient(180deg, var(--panel), var(--panel2));
  border: 1px solid var(--border2);
  border-radius: var(--r);
  padding: 16px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  transition:
    transform var(--t) var(--ease),
    box-shadow var(--t) var(--ease),
    border-color var(--t) var(--ease);
}

.card::after {
  content: "";
  position: absolute;
  inset: -60px;
  background:
    radial-gradient(circle at 70% 20%, rgba(60, 80, 230, .18), transparent 58%),
    radial-gradient(circle at 30% 40%, rgba(130, 50, 230, .14), transparent 60%);
  opacity: .9;
  pointer-events: none;
  animation: cardGlow 9s linear infinite;
}

@keyframes cardGlow {
  0% { transform: translate3d(-1.5%, -1%, 0) rotate(0deg); }
  100% { transform: translate3d(1.5%, 1%, 0) rotate(360deg); }
}

.card:hover {
  transform: translateY(-6px);
  border-color: rgba(106, 168, 255, .30);
  box-shadow: var(--shadow), var(--glow);
}

.card>* {
  position: relative;
}

.card img {
  width: 100%;
  height: 170px;
  object-fit: cover;
  border-radius: var(--r2);
  border: 1px solid var(--border2);
  margin-bottom: 12px;
  transition: transform var(--t) var(--ease);
}

.card:hover img {
  transform: scale(1.015);
}

.card h3 {
  margin-bottom: 8px;
}

.card a {
  display: inline-flex;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(106, 168, 255, .18);
  background: rgba(255, 255, 255, .03);
  color: var(--text);
  transition:
    box-shadow var(--tFast) var(--ease),
    border-color var(--tFast) var(--ease),
    transform var(--tFast) var(--ease);
}

.card a:hover {
  border-color: rgba(106, 168, 255, .32);
  box-shadow: var(--glow);
  transform: translateY(-1px);
}

/* -------------------------
   Formulaires
-------------------------- */
form {
  margin-top: 12px;
}

label {
  color: rgba(248, 250, 252, .82);
  font-size: 14px;
}

input[type="email"],
input[type="password"],
input[type="text"],
input[type="number"],
textarea,
select {
  width: min(520px, 100%);
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--border2);
  background: rgba(255, 255, 255, .03);
  color: var(--text);
  box-shadow: 0 0 0 rgba(0, 0, 0, 0);
  transition:
    border-color var(--tFast) var(--ease),
    box-shadow var(--tFast) var(--ease),
    transform var(--tFast) var(--ease);
}

input[type="number"] {
  width: 90px;
}

input::placeholder,
textarea::placeholder {
  color: rgba(248, 250, 252, .42);
}

input:hover,
textarea:hover,
select:hover {
  border-color: rgba(255, 255, 255, .16);
}

input:focus,
textarea:focus,
select:focus {
  border-color: rgba(106, 168, 255, .34);
  box-shadow: var(--glow);
}

/* Curseur texte natif (meilleure UX) */
input,
textarea {
  cursor: text;
}

/* -------------------------
   Boutons — bordure animée (UNIQUEMENT la bordure)
-------------------------- */

/* Animation de la bordure */
@keyframes borderFlow {
  0% {
    background-position: 0% 50%;
  }

  100% {
    background-position: 200% 50%;
  }
}

/* Boutons (tous) */
button,
.btn {
  position: relative;
  isolation: isolate;
  cursor: pointer;

  padding: 10px 14px;
  border-radius: 999px;

  background: rgba(255, 255, 255, .03);
  color: #ffffff;
  font-weight: 600;

  /* bordure simple au repos */
  border: 1px solid rgba(106, 168, 255, .22);

  overflow: hidden;

  transition:
    background var(--tFast) var(--ease),
    border-color var(--tFast) var(--ease),
    box-shadow var(--tFast) var(--ease),
    filter var(--tFast) var(--ease);
}

/* Pseudo-élément = la bordure gradient, centre masqué (on ne voit QUE le contour) */
button::before,
.btn::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;

  /* épaisseur de la bordure */
  padding: 1px;

  background: linear-gradient(90deg,
      var(--accent1),
      var(--accent2),
      var(--accent1));
  background-size: 200% 100%;

  /* masque le centre => bordure uniquement */
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;

  pointer-events: none;

  /* invisible au repos => la bordure "repos" reste celle du border normal */
  opacity: 0;
  transition: opacity var(--tFast) var(--ease);
}

/* Hover: uniquement la bordure devient animée */
button:hover::before,
.btn:hover::before {
  opacity: 1;
  animation: borderFlow 2s linear infinite;
}

/* Hover: optionnel, très léger (si tu veux ZÉRO glow, mets box-shadow: none;) */
button:hover,
.btn:hover {
  box-shadow: 0 0 0 1px rgba(130, 50, 230, .14);
  filter: brightness(1.04);
}

button:active,
.btn:active {
  filter: brightness(1.0);
}

/* Curseur “pointer” custom sur éléments cliquables */
a,
button,
.btn,
header nav a,
.nav a {
  cursor: url("data:image/svg+xml;utf8,\
<svg xmlns='http://www.w3.org/2000/svg' width='32' height='32'>\
<defs><linearGradient id='g' x1='0' y1='0' x2='1' y2='1'>\
<stop offset='0%25' stop-color='%236aa8ff'/>\
<stop offset='100%25' stop-color='%238232e6'/>\
</linearGradient></defs>\
<circle cx='16' cy='16' r='8' fill='none' stroke='url(%23g)' stroke-width='3'/>\
</svg>") 16 16, pointer;
}

/* Utilitaires curseur */
.grab {
  cursor: grab;
}

.grab:active {
  cursor: grabbing;
}

/* -------------------------
   Listes
-------------------------- */
ul {
  padding-left: 18px;
}

li {
  color: var(--muted);
}

/* -------------------------
   Table (achats)
-------------------------- */
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 14px;
  overflow: hidden;
  border-radius: var(--r);
  background: linear-gradient(180deg, var(--panel), var(--panel2));
  border: 1px solid var(--border2);
  box-shadow: var(--shadow);
}

thead th {
  text-align: left;
  font-size: 13px;
  color: rgba(248, 250, 252, .78);
  background: rgba(255, 255, 255, .05);
  border-bottom: 1px solid var(--border2);
  padding: 12px;
}

tbody td {
  padding: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, .06);
  color: rgba(248, 250, 252, .72);
}

tbody tr:hover td {
  background: linear-gradient(90deg, rgba(60, 80, 230, .08), rgba(130, 50, 230, .05));
}

/* -------------------------
   Statut serveur
-------------------------- */
#server-status {
  margin-top: 12px;
  padding: 14px 16px;
  border-radius: var(--r);
  background: linear-gradient(180deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, .03));
  border: 1px solid var(--border2);
  box-shadow: var(--shadow);
  color: rgba(248, 250, 252, .86);
}

/* Shimmer pendant le chargement */
#server-status.is-loading {
  position: relative;
  overflow: hidden;
}

#server-status.is-loading::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.06), transparent);
  transform: translateX(-120%);
  animation: shimmer 1.2s linear infinite;
  pointer-events: none;
}

@keyframes shimmer {
  0% { transform: translateX(-120%); }
  100% { transform: translateX(120%); }
}

/* -------------------------
   Messages / alertes
-------------------------- */
p[style*="color:red"],
.alert,
.error {
  padding: 12px 14px;
  border-radius: var(--r2);
  border: 1px solid rgba(255, 110, 110, .22);
  background: linear-gradient(180deg, rgba(255, 60, 60, .08), rgba(255, 60, 60, .04));
  color: rgba(255, 210, 210, .92) !important;
  box-shadow: 0 18px 70px rgba(0, 0, 0, .35);
}

/* -------------------------
   Listes plus "card" + hover
-------------------------- */
ul {
  margin: 12px 0;
}

ul li {
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.06);
  background: rgba(255,255,255,.02);
  transition: transform var(--tFast) var(--ease), border-color var(--tFast) var(--ease);
}

ul li:hover {
  transform: translateY(-2px);
  border-color: rgba(106, 168, 255, .18);
}

/* -------------------------
   Reveal animations
-------------------------- */
.js .reveal {
  opacity: 0;
  transform: translateY(14px) scale(.985);
  filter: blur(2px);
  transition:
    opacity 700ms var(--ease),
    transform 700ms var(--ease),
    filter 700ms var(--ease);
  transition-delay: var(--d, 0ms);
}

.js .reveal.in {
  opacity: 1;
  transform: translateY(0) scale(1);
  filter: blur(0);
}

/* Animation d'entrée au chargement (si JS) */
.js body.page-enter main,
.js body.page-enter .site-header,
.js body.page-enter .site-footer {
  opacity: 0;
  transform: translateY(10px);
}

.js body.page-ready main,
.js body.page-ready .site-header,
.js body.page-ready .site-footer {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 700ms var(--ease), transform 700ms var(--ease);
}

/* Petites améliorations sur les "inline styles" existants */
form[style*="display:inline"] {
  display: inline-flex !important;
  gap: 8px;
  align-items: center;
}

/* -------------------------
   Responsive
-------------------------- */
@media (max-width: 520px) {
  header nav a {
    width: 100%;
    justify-content: center;
  }

  button,
  .btn {
    width: 100%;
  }
}

/* -------------------------------------------------
   Compat: layout/header/footer (classes)
-------------------------------------------------- */
.site-header,
header {
  backdrop-filter: blur(10px);
}

.container {
  width: min(var(--max), 92vw);
  margin-inline: auto;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.logo {
  letter-spacing: .14em;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--text);
  text-decoration: none;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--border2);
  background: linear-gradient(90deg, rgba(60, 80, 230, .22), rgba(130, 50, 230, .18));
  box-shadow: var(--glow);
  transition: transform var(--tFast) var(--ease), box-shadow var(--tFast) var(--ease);
}

.logo:hover {
  box-shadow: var(--glowStrong);
  transform: translateY(-1px);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

/* Unifie le style des liens de navigation */
.nav a,
header nav a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--border2);
  background: rgba(255, 255, 255, .03);
  text-decoration: none;
  color: var(--text);
}

/* Footer (collé en bas) */
footer,
.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--border2);
  background: linear-gradient(180deg, rgba(255, 255, 255, .02), rgba(255, 255, 255, .015));
  padding: 22px 0;
}

/* =========================
   Curseur pour champs input
========================= */

input,
textarea,
select {
  cursor: url("data:image/svg+xml;utf8,\
<svg xmlns='http://www.w3.org/2000/svg' width='32' height='32'>\
<defs>\
<linearGradient id='g' x1='0' y1='0' x2='1' y2='1'>\
<stop offset='0%25' stop-color='%233c50e6'/>\
<stop offset='100%25' stop-color='%238232e6'/>\
</linearGradient>\
</defs>\
<rect x='14' y='4' width='4' height='24' fill='url(%23g)' rx='2'/>\
</svg>") 16 16, text;
}

/* =========================================================
   FIX: Tous les "boutons" restants (liens + nav + logout)
   -> bordure animée uniquement, style uniforme
   ========================================================= */

/* 1) Désactive l'underline animée sur les liens qui se comportent comme des boutons */
header nav a::after,
.nav a::after,
.card a::after,
a.btn::after,
a.button::after,
a[role="button"]::after {
  content: none !important;
}

/* 2) Animation bordure (réutilisée) */
@keyframes borderFlow {
  0% {
    background-position: 0% 50%;
  }

  100% {
    background-position: 200% 50%;
  }
}

/* 3) Base "bouton premium" appliquée aux anchors ET boutons */
header nav a,
.nav a,
.card a,
a.btn,
a.button,
a[role="button"],
input[type="submit"],
input[type="button"],
input[type="reset"],
button,
.btn {
  position: relative !important;
  isolation: isolate;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;

  padding: 10px 14px !important;
  border-radius: 999px !important;

  background: rgba(255, 255, 255, .03) !important;
  color: var(--text) !important;
  font-weight: 600 !important;

  border: 1px solid rgba(106, 168, 255, .22) !important;

  text-decoration: none !important;
  overflow: hidden !important;

  /* pas de lift */
  transform: none !important;

  transition:
    filter var(--tFast) var(--ease),
    background var(--tFast) var(--ease) !important;
}

/* 4) Bordure gradient (UNIQUEMENT le contour) */
header nav a::before,
.nav a::before,
.card a::before,
a.btn::before,
a.button::before,
a[role="button"]::before,
input[type="submit"]::before,
input[type="button"]::before,
input[type="reset"]::before,
button::before,
.btn::before {
  content: "" !important;
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  /* épaisseur bordure */

  background: linear-gradient(90deg, var(--accent1), var(--accent2), var(--accent1));
  background-size: 200% 100%;

  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;

  pointer-events: none;
  opacity: 0;
  transition: opacity var(--tFast) var(--ease);
}

/* 5) Hover: la bordure s'anime (comme ton image), rien d’autre */
header nav a:hover::before,
.nav a:hover::before,
.card a:hover::before,
a.btn:hover::before,
a.button:hover::before,
a[role="button"]:hover::before,
input[type="submit"]:hover::before,
input[type="button"]:hover::before,
input[type="reset"]:hover::before,
button:hover::before,
.btn:hover::before {
  opacity: 1;
  animation: borderFlow 2s linear infinite;
}

/* 6) Hover: pas de glow, juste une micro-luminosité */
header nav a:hover,
.nav a:hover,
.card a:hover,
a.btn:hover,
a.button:hover,
a[role="button"]:hover,
input[type="submit"]:hover,
input[type="button"]:hover,
input[type="reset"]:hover,
button:hover,
.btn:hover {
  box-shadow: none !important;
  filter: brightness(1.05);
}

/* 7) Cas fréquent: boutons dans <form style="display:inline"> (ex: Déconnexion) */
form[style*="display:inline"] button,
form[style*="display:inline"] input[type="submit"] {
  width: auto !important;
}

.button_panier {
  position: relative !important;
  isolation: isolate;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  padding: 10px 14px !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, .03) !important;
  color: var(--text) !important;
  font-weight: 600 !important;
  border: 1px solid rgba(106, 168, 255, .22) !important;
  text-decoration: none !important;
  overflow: hidden !important;
  transform: none !important;
  transition: filter var(--tFast) var(--ease), background var(--tFast) var(--ease) !important;
}

.achats {
  position: relative !important;
  isolation: isolate;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  padding: 10px 14px !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, .03) !important;
  color: var(--text) !important;
  font-weight: 600 !important;
  border: 1px solid rgba(106, 168, 255, .22) !important;
  text-decoration: none !important;
  overflow: hidden !important;
  transform: none !important;
  transition: filter var(--tFast) var(--ease), background var(--tFast) var(--ease) !important;
}

.next_payment {
  position: relative !important;
  isolation: isolate;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  padding: 10px 14px !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, .03) !important;
  color: var(--text) !important;
  font-weight: 600 !important;
  border: 1px solid rgba(106, 168, 255, .22) !important;
  text-decoration: none !important;
  overflow: hidden !important;
  transform: none !important;
  transition: filter var(--tFast) var(--ease), background var(--tFast) var(--ease) !important;
}

/* =========================================================
   Animations globales (reveal / page-enter / shimmer)
   ========================================================= */

/* Page enter */
.page-enter .site-header,
.page-enter header {
  opacity: 0;
  transform: translateY(-10px);
}

.page-ready .site-header,
.page-ready header {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 520ms var(--ease), transform 520ms var(--ease);
}

.page-enter main,
.page-enter .container {
  opacity: 0;
  transform: translateY(10px);
}

.page-ready main,
.page-ready .container {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 620ms var(--ease), transform 620ms var(--ease);
}

/* Reveal on scroll */
.js .reveal {
  margin: 0;
  opacity: 0;
  transform: translateY(14px) scale(.985);
  filter: blur(2px);
  transition:
    opacity 650ms var(--ease) var(--d, 0ms),
    transform 650ms var(--ease) var(--d, 0ms),
    filter 650ms var(--ease) var(--d, 0ms);
  will-change: transform, opacity, filter;
}

.js .reveal.in {
  opacity: 1;
  transform: translateY(0) scale(1);
  filter: blur(0);
}

/* Micro "breathing" sur les cards une fois visibles */
@keyframes breathe {
  0% { transform: translateY(0); }
  100% { transform: translateY(-2px); }
}

.js .card.reveal.in {
  animation: breathe 5.5s ease-in-out infinite alternate;
}

/* Shimmer statut serveur */
@keyframes shimmer {
  0% { background-position: 0% 50%; }
  100% { background-position: 200% 50%; }
}

#server-status.is-loading {
  background: linear-gradient(90deg,
      rgba(255,255,255,.04),
      rgba(106,168,255,.08),
      rgba(255,255,255,.04));
  background-size: 200% 100%;
  animation: shimmer 1.2s linear infinite;
}

#server-status.is-online {
  border-color: rgba(86, 255, 186, .28);
  box-shadow: 0 0 0 1px rgba(86, 255, 186, .12);
}

#server-status.is-offline {
  border-color: rgba(255, 107, 107, .28);
  box-shadow: 0 0 0 1px rgba(255, 107, 107, .10);
}

/* Alertes / erreurs inline (ex: <p style="color:red">) */
@keyframes popIn {
  0% { transform: translateY(6px) scale(.98); opacity: 0; }
  100% { transform: translateY(0) scale(1); opacity: 1; }
}

p[style*="color:red"],
.alert-error {
  color: #ff6b6b !important;
  background: rgba(255, 107, 107, .08);
  border: 1px solid rgba(255, 107, 107, .22);
  padding: 10px 12px;
  border-radius: 12px;
  margin: 12px 0 14px;
  animation: popIn 520ms var(--ease) both;
}

/* List items (panier) */
ul li {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, .02);
  border: 1px solid rgba(255, 255, 255, .06);
  transition: transform var(--t) var(--ease), border-color var(--t) var(--ease);
}

ul li:hover {
  transform: translateY(-2px);
  border-color: rgba(106, 168, 255, .22);
}
