/* assets/ux-pro.css — couche de design globale (UX) : s'appuie sur les variables du thème (--primary, --surface, --border…),
   donc compatible avec le thème sombre et les couleurs des revendeurs. Chargée automatiquement par includes/lang.php. */

:root{
  --ux-ease:cubic-bezier(.2,.8,.2,1);
  --ux-ring:0 0 0 4px rgba(255,120,0,.22);
  --ux-card-sh:0 1px 2px rgba(16,24,40,.05),0 10px 28px -12px rgba(16,24,40,.16);
  --ux-card-sh-hover:0 2px 4px rgba(16,24,40,.06),0 18px 40px -14px rgba(16,24,40,.24);
}

/* ── Base : lisibilité, fluidité ─────────────────────────────── */
html{-webkit-text-size-adjust:100%;scroll-behavior:smooth;scroll-padding-top:76px}
html body{
  font-size:16px;line-height:1.6;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;
  background-attachment:scroll;               /* le fond « fixed » fait saccader le défilement sur mobile */
  overflow-wrap:anywhere;
}
html body h1,html body h2,html body h3{font-family:var(--font-h);letter-spacing:-.02em;line-height:1.18;text-wrap:balance}
html body h1{font-size:clamp(1.65rem,5.6vw,2.5rem);font-weight:800}
html body h2{font-size:clamp(1.3rem,4.2vw,1.75rem);font-weight:800}
html body p{text-wrap:pretty}
html body img,html body svg,html body video{max-width:100%}
html body ::selection{background:var(--primary);color:#fff}

/* ── Accessibilité : focus visible partout ───────────────────── */
html body :focus{outline:none}
html body :focus-visible{outline:3px solid var(--primary);outline-offset:3px;border-radius:10px}
html body input:focus-visible,html body select:focus-visible,html body textarea:focus-visible{outline:none}

/* ── Cartes : relief doux, bordure fine, rayon homogène ──────── */
html body .bg-white.rounded-2xl,
html body .bg-white.rounded-xl,
html body .bg-white.rounded-3xl,
html body .ux-card{
  border:1px solid var(--border);border-radius:20px;box-shadow:var(--ux-card-sh);
  transition:transform .25s var(--ux-ease),box-shadow .25s var(--ux-ease),border-color .2s;
}
@media (hover:hover) and (pointer:fine){
  html body a.bg-white.rounded-2xl:hover,html body a.bg-white.rounded-xl:hover,
  html body .card-hover:hover,html body .ux-card:hover{transform:translateY(-3px);box-shadow:var(--ux-card-sh-hover);border-color:var(--primary)}
}
html body a.bg-white:active,html body .card-hover:active{transform:scale(.985)}

/* ── Boutons principaux : grande zone tactile, retour visuel ─── */
html body button[type=submit]:not([class*="text-xs"]):not([class*="text-sm"]),
html body .ux-btn{min-height:52px}
html body button[type=submit],
html body .gradient-primary,html body .g-primary,html body .ux-btn{
  border-radius:14px;font-family:var(--font-h);font-weight:700;letter-spacing:.005em;
  transition:transform .15s var(--ux-ease),box-shadow .25s var(--ux-ease),filter .2s;
}
html body button[type=submit]:not(:disabled):hover,html body .ux-btn-primary:hover{filter:brightness(1.05);box-shadow:0 12px 26px -10px rgba(0,0,0,.4)}
html body button:not(:disabled):active,html body .ux-btn:active,html body a.nlnk-depot:active{transform:scale(.97)}
html body button:disabled,html body button[aria-busy=true]{opacity:.65;cursor:not-allowed}
html body button.is-loading{position:relative;color:transparent!important;pointer-events:none}
html body button.is-loading::after{
  content:"";position:absolute;inset:0;margin:auto;width:22px;height:22px;border-radius:50%;
  border:3px solid rgba(255,255,255,.45);border-top-color:#fff;animation:ux-spin .7s linear infinite;
}
@keyframes ux-spin{to{transform:rotate(360deg)}}

/* ── Formulaires : champs confortables, pas de zoom iOS ──────── */
html body input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=file]):not([type=hidden]),
html body select,html body textarea{
  min-height:48px;font-size:16px;border-radius:14px;border:1.5px solid var(--border2);
  transition:border-color .2s,box-shadow .2s,background .2s;
}
html body textarea{min-height:110px;line-height:1.5}
html body input:not([type=checkbox]):not([type=radio]):focus,html body select:focus,html body textarea:focus{
  border-color:var(--primary);box-shadow:var(--ux-ring);
}
html body input::placeholder,html body textarea::placeholder{color:var(--muted2)}
html body input[type=checkbox],html body input[type=radio]{accent-color:var(--primary);width:20px;height:20px}
html body label{font-weight:600}

/* ── Navigation ──────────────────────────────────────────────── */
html body #sb-nav{transition:box-shadow .25s,background .25s}
html body .nav-lnk,html body .mob-lnk{min-height:44px}
html body .bnav-it{min-width:56px;min-height:48px;justify-content:center;position:relative;transition:color .2s,transform .15s}
html body .bnav-it:active{transform:scale(.92)}
html body .bnav-it.active::after{content:"";position:absolute;bottom:-2px;width:18px;height:3px;border-radius:3px;background:var(--primary)}
html body #sb-bnav{padding-bottom:calc(6px + env(safe-area-inset-bottom,0px))}
@media (max-width:900px){ html body{padding-bottom:calc(84px + env(safe-area-inset-bottom,0px))} }

/* ── Sélecteurs langue + devise : même langage visuel ────────── */
.langwrap .langsw,.langwrap .cursw{box-shadow:0 1px 2px rgba(16,24,40,.06)}
.langwrap a{transition:background .2s,color .2s}

/* ── Composants de la page d'accueil (visiteurs) ─────────────── */
.ux-hero{
  position:relative;overflow:hidden;border-radius:28px;padding:28px 22px 24px;margin-bottom:28px;
  background:linear-gradient(135deg,var(--surface) 0%,var(--primary-lt) 160%);
  border:1px solid var(--border);box-shadow:var(--sh-md);
}
.ux-hero::after{content:"";position:absolute;right:-70px;top:-70px;width:240px;height:240px;border-radius:50%;
  background:radial-gradient(circle,var(--primary-mid),transparent 70%);opacity:.8;pointer-events:none}
.ux-hero>*{position:relative;z-index:1}
.ux-eyebrow{display:inline-flex;align-items:center;gap:8px;padding:6px 14px;border-radius:999px;margin-bottom:14px;
  background:var(--surface);border:1px solid var(--border);font-size:13px;font-weight:700;color:var(--text2)}
.ux-eyebrow i{color:var(--gold)}
html body .ux-hero h1{margin:0 0 12px}
.ux-lead{font-size:1.04rem;color:var(--text2);max-width:64ch;margin:0 0 4px}
.ux-cta-row{display:flex;flex-wrap:wrap;gap:12px;margin:20px 0 18px}
.ux-btn{display:inline-flex;align-items:center;justify-content:center;gap:9px;padding:0 26px;text-decoration:none;font-size:16px;cursor:pointer;border:0}
.ux-btn-primary{background:linear-gradient(135deg,var(--primary),var(--gold));color:#fff!important;box-shadow:0 12px 26px -12px rgba(0,0,0,.45)}
.ux-btn-ghost{background:var(--surface);color:var(--text)!important;border:1.5px solid var(--border2)}
.ux-btn-ghost:hover{border-color:var(--primary);color:var(--primary)!important}
@media (max-width:520px){ .ux-cta-row .ux-btn{width:100%} }
.ux-trust{display:flex;flex-wrap:wrap;gap:8px 18px;list-style:none;padding:0;margin:0;color:var(--text2);font-size:14px;font-weight:600}
.ux-trust li{display:inline-flex;align-items:center;gap:7px}
.ux-trust i{color:var(--primary)}
.ux-steps{display:grid;gap:12px;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));margin-top:22px;padding:0;list-style:none}
.ux-step{display:flex;gap:12px;align-items:flex-start;background:var(--surface);border:1px solid var(--border);border-radius:18px;padding:15px}
.ux-step-n{flex:0 0 34px;height:34px;border-radius:12px;display:grid;place-items:center;font:800 15px var(--font-h);color:#fff;
  background:linear-gradient(135deg,var(--primary),var(--gold))}
.ux-step b{display:block;font-family:var(--font-h);font-size:15px;color:var(--text)}
.ux-step span{display:block;font-size:13.5px;color:var(--muted);line-height:1.45;margin-top:2px}
.ux-compact-seo{font-size:clamp(1.2rem,4vw,1.5rem)!important}

/* ── Apparition douce au défilement (ajoutée en JS, jamais en dur) ─ */
.ux-pre{opacity:0;transform:translateY(16px)}
.ux-pre.ux-in{opacity:1;transform:none;transition:opacity .55s var(--ux-ease),transform .55s var(--ux-ease)}

/* ── Respect des préférences système ─────────────────────────── */
@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*::before,*::after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}
  .ux-pre{opacity:1;transform:none}
}

/* ── Accueil : accroche courte en haut, texte de présentation en bas ── */
html body .ux-hero{padding:22px 18px 18px;margin-bottom:22px}
html body .ux-hero-title{font-size:clamp(1.45rem,5.2vw,2.2rem);margin:0 0 4px}
.ux-hero .ux-cta-row{margin:16px 0 14px}
.ux-about{margin:34px 0 8px;padding:22px 18px;border-radius:22px;background:var(--surface);border:1px solid var(--border)}
.ux-about h2{margin:0 0 14px}
.ux-about .ux-steps{margin:0 0 18px}
.ux-about-text{color:var(--muted);font-size:14.5px;line-height:1.65;max-width:75ch;margin:0}
.sr-only{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
