/* ==========================================================================
   Erlen – animation d'ouverture « Seit 30 Jahren » (accueil uniquement)
   ========================================================================== */

/* Cache provisoire posé dans le <head> tant que le script n'a pas pris le relais */
html.erl-intro-pending::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 99998;
  background: var(--secondary-l-3, #ebe5ff);
}

.erl-intro {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: var(--secondary-l-3, #ebe5ff);
  cursor: pointer;
  transition: opacity .7s ease, transform .7s cubic-bezier(.6, 0, .4, 1);
}
.erl-intro.is-leaving {
  opacity: 0;
  transform: scale(1.04);
  pointer-events: none;
}

.erl-intro__stage {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
  padding: 24px;
  text-align: center;
}

/* Grand blob derrière le logo */
.erl-intro__blob {
  position: absolute;
  left: 50%;
  top: 38%;
  width: min(78vw, 520px);
  aspect-ratio: 420 / 380;
  translate: -50% -50%;
  background: var(--mint, #98e3b4);
  -webkit-mask: var(--blob-4) center / 100% 100% no-repeat;
          mask: var(--blob-4) center / 100% 100% no-repeat;
  animation: erl-intro-blob 1.1s cubic-bezier(.2, 1.4, .4, 1) both, erl-intro-spin 14s linear infinite;
}

.erl-intro__logo {
  position: relative;
  width: min(62vw, 340px);
  height: auto;
  animation: erl-intro-pop .9s .25s cubic-bezier(.2, 1.6, .45, 1) both;
}

.erl-intro__badge {
  position: relative;
  margin: 0;
  padding: .3em .7em .38em;
  font-size: clamp(30px, 6vw, 56px);
  font-weight: 900;
  line-height: 1.1;
  color: #fff;
  animation: erl-intro-up .7s .75s cubic-bezier(.2, 1.3, .4, 1) both;
}

.erl-intro__years {
  position: relative;
  margin: 0;
  font-size: clamp(16px, 2.2vw, 22px);
  font-weight: 800;
  letter-spacing: .12em;
  color: var(--primary, #203147);
  animation: erl-intro-up .6s 1s ease-out both;
}

.erl-intro__skip {
  position: absolute;
  left: 0;
  right: 0;
  bottom: max(32px, 6vh);
  width: max-content;
  margin-inline: auto; /* centrage sans translate (réservé à l'animation d'entrée) */
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 28px;
  border: 0;
  border-radius: 999px;
  background: var(--primary, #203147);
  color: #fff;
  font: inherit;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 10px 24px rgb(32 49 71 / .18);
  animation: erl-intro-up .6s 1.6s ease-out both;
  transition: transform .2s ease, box-shadow .2s ease;
}
.erl-intro__skip::after {
  content: "↓";
  display: inline-block;
  animation: erl-intro-nudge 1.6s 2.4s ease-in-out infinite;
}
.erl-intro__skip:hover { transform: scale(1.05); box-shadow: 0 14px 30px rgb(32 49 71 / .24); }
.erl-intro__skip:focus-visible { outline: 3px solid var(--mint, #98e3b4); outline-offset: 4px; }

.erl-confetti {
  position: fixed;
  inset: 0;
  z-index: 100000;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

@keyframes erl-intro-blob {
  from { scale: 0; opacity: 0; }
  to   { scale: 1; opacity: 1; }
}
@keyframes erl-intro-nudge {
  0%, 100% { translate: 0 0; }
  50%      { translate: 0 4px; }
}
@keyframes erl-intro-spin {
  to { rotate: 360deg; }
}
@keyframes erl-intro-pop {
  from { scale: .4; opacity: 0; rotate: -8deg; }
  to   { scale: 1;  opacity: 1; rotate: 0deg; }
}
@keyframes erl-intro-up {
  from { translate: 0 24px; opacity: 0; }
  to   { translate: 0 0;    opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .erl-intro,
  .erl-intro * { animation: none !important; transition: opacity .3s ease !important; }
}
