/* ══ Intro d'ouverture — accueil ProxiShop ═══════════════════════════════
   Rideau olive (même dégradé et même treillis que l'accroche de l'accueil),
   logo qui se compose, point ambre qui se pose, puis le rideau se lève.
   Durée totale : 2 s. Tout est piloté en CSS : si le JavaScript ne tourne
   pas, l'intro se joue quand même et se retire seule — elle ne peut pas
   rester bloquée devant la page. Le script ne sert qu'à la sauter quand
   elle a déjà été vue dans la session (classe ps-intro-skip sur <html>). */

.ps-intro {
  position: fixed;
  inset: 0;
  z-index: 100000;   /* au-dessus de tout, y compris le bandeau cookies */
  display: grid;
  place-items: center;
  overflow: hidden;
  background: linear-gradient(140deg, #2E3819 0%, #3D4A22 48%, #55632F 100%);
  border-block-end: 3px solid #E9A94A;
  animation: ps-intro-lift .5s cubic-bezier(.76, 0, .24, 1) 1.5s forwards;
}
html.ps-intro-skip .ps-intro { display: none; }

/* Treillis de l'accroche, franc sur les bords, effacé derrière le logo. */
.ps-intro::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(45deg,  rgba(197, 217, 170, .34) 0 1.5px, transparent 1.5px 44px),
    repeating-linear-gradient(-45deg, rgba(197, 217, 170, .34) 0 1.5px, transparent 1.5px 44px);
  -webkit-mask-image: radial-gradient(ellipse 60% 55% at 50% 50%, transparent 30%, #000 100%);
  mask-image: radial-gradient(ellipse 60% 55% at 50% 50%, transparent 30%, #000 100%);
  opacity: 0;
  animation: ps-intro-fade .7s ease-out .05s forwards;
}

.ps-intro__brand {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .55rem;
  padding: 0 1.25rem;
  animation: ps-intro-leave .32s cubic-bezier(.55, 0, .9, .4) 1.48s forwards;
}

.ps-intro__word {
  direction: ltr;
  font-family: 'DM Serif Display', Georgia, 'Times New Roman', serif;
  font-size: clamp(2.7rem, 11vw, 4.75rem);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -.02em;
  white-space: nowrap;
  color: rgba(255, 255, 255, .78);
}
.ps-intro__word em,
.ps-intro__word b,
.ps-intro__word i { display: inline-block; font-style: normal; font-weight: 400; }

/* « Proxi » puis « Shop » montent de derrière une ligne invisible. */
.ps-intro__word em,
.ps-intro__word b {
  transform: translateY(100%);
  clip-path: inset(0 0 100% 0);
  animation: ps-intro-rise .48s cubic-bezier(.2, .8, .2, 1) forwards;
}
.ps-intro__word em { color: #FFFFFF; animation-delay: .08s; }
.ps-intro__word b  { animation-delay: .17s; }

/* Le point ambre : la signature du logo, posé en dernier. */
.ps-intro__word i {
  color: #E9A94A;
  margin-inline-start: 0;
  transform: scale(0);
  transform-origin: 50% 85%;
  animation: ps-intro-dot .34s cubic-bezier(.34, 1.7, .64, 1) .5s forwards;
}

.ps-intro__tag {
  font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
  font-size: clamp(.62rem, 2.4vw, .78rem);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .32em;
  color: rgba(255, 255, 255, .62);
  white-space: nowrap;
  opacity: 0;
  animation: ps-intro-tag .45s ease-out .55s forwards;
}
/* L'arabe ne s'espace pas lettre à lettre : on garde seulement le fondu. */
[dir="rtl"] .ps-intro__tag {
  font-family: 'Cairo', 'Plus Jakarta Sans', system-ui, sans-serif;
  font-size: clamp(.8rem, 3vw, .95rem);
  letter-spacing: 0;
  animation-name: ps-intro-fade;
}

@keyframes ps-intro-rise  { to { transform: none; clip-path: inset(0 0 -25% 0); } }
@keyframes ps-intro-dot   { to { transform: scale(1); } }
@keyframes ps-intro-tag   { to { opacity: 1; letter-spacing: .14em; } }
@keyframes ps-intro-fade  { to { opacity: 1; } }
@keyframes ps-intro-leave { to { transform: translateY(-28px); opacity: 0; } }
@keyframes ps-intro-lift  { to { transform: translateY(-100%); visibility: hidden; } }

/* Mouvement réduit demandé par le visiteur : pas d'intro du tout. */
@media (prefers-reduced-motion: reduce) { .ps-intro { display: none; } }
@media print { .ps-intro { display: none; } }
