/**
 * FAEL — scroll shell + wipe-fill hovers (no scale / lift)
 */

html:has(body.theme-fael) {
  overflow-x: clip;
  overscroll-behavior: none;
}

body.theme-fael {
  overflow-x: clip;
  overscroll-behavior-y: none;
  max-width: 100vw;
  min-height: 100dvh;
}

body.theme-fael #main,
body.theme-fael .site-header,
body.theme-fael .site-footer {
  max-width: 100vw;
}

body.theme-fael img,
body.theme-fael video,
body.theme-fael svg {
  max-width: 100%;
}

/* Wipe-fill buttons */
body.theme-fael .btn,
body.theme-fael a.btn,
body.theme-fael button.btn,
body.theme-fael .nav-cta {
  position: relative;
  z-index: 0;
  overflow: hidden;
  isolation: isolate;
  transition: color 0.22s ease, border-color 0.22s ease;
}

body.theme-fael .btn::before,
body.theme-fael a.btn::before,
body.theme-fael button.btn::before,
body.theme-fael .nav-cta::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--fael-red-dark);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1);
}

body.theme-fael .btn:hover::before,
body.theme-fael a.btn:hover::before,
body.theme-fael button.btn:hover::before,
body.theme-fael .nav-cta:hover::before {
  transform: scaleX(1);
}

body.theme-fael .btn:hover,
body.theme-fael a.btn:hover,
body.theme-fael button.btn:hover,
body.theme-fael .nav-cta:hover {
  background: transparent;
  border-color: var(--fael-red-dark);
  color: #ffffff;
}

body.theme-fael .btn-outline,
body.theme-fael a.btn-outline,
body.theme-fael button.btn-outline,
body.theme-fael .fael-hero__btn--ghost {
  background: #ffffff;
}

body.theme-fael .btn-outline::before,
body.theme-fael a.btn-outline::before,
body.theme-fael button.btn-outline::before,
body.theme-fael .fael-hero__btn--ghost::before {
  background: var(--fael-red-soft);
}

body.theme-fael .btn-outline:hover,
body.theme-fael a.btn-outline:hover,
body.theme-fael button.btn-outline:hover,
body.theme-fael .fael-hero__btn--ghost:hover {
  background: transparent;
  border-color: var(--fael-red);
  color: var(--fael-red);
}

/* Nav links — underline wipe */
body.theme-fael .nav-list a {
  position: relative;
}

body.theme-fael .nav-list a::after {
  content: "";
  position: absolute;
  left: 0.85rem;
  right: 0.85rem;
  bottom: 0.2rem;
  height: 2px;
  background: var(--fael-red);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.22s ease;
}

body.theme-fael .nav-list a:hover::after,
body.theme-fael .nav-list a[aria-current="page"]::after {
  transform: scaleX(1);
}

body.theme-fael .nav-list a[aria-current="page"] {
  border-bottom-color: transparent;
}

/* Language switcher — fill wipe per cell */
body.theme-fael .lang-switch__btn {
  position: relative;
  z-index: 0;
  overflow: hidden;
  isolation: isolate;
  transition: color 0.2s ease;
}

body.theme-fael .lang-switch__btn::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--fael-red);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.22s ease;
}

body.theme-fael .lang-switch__btn:hover::before {
  transform: scaleX(1);
}

body.theme-fael .lang-switch__btn:hover {
  color: #ffffff;
  background: transparent;
}

body.theme-fael .lang-switch__btn.is-active {
  background: var(--fael-red);
  color: #ffffff;
}

body.theme-fael .lang-switch__btn.is-active::before {
  background: var(--fael-red-dark);
}

body.theme-fael .lang-switch__btn.is-active:hover::before {
  transform: scaleX(1);
}

/* Shop cards — border wipe, no lift/zoom */
body.theme-fael .fael-shop-card__link {
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

body.theme-fael .fael-shop-card__link:hover {
  transform: none;
  border-color: var(--fael-red);
  box-shadow: var(--fael-shadow-sm);
}

body.theme-fael .fael-shop-card__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(227, 6, 19, 0.12);
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}

body.theme-fael .fael-shop-card__link:hover .fael-shop-card__media::after {
  opacity: 1;
}

body.theme-fael .fael-shop-card__media img {
  transition: none;
}

body.theme-fael .fael-shop-card__link:hover .fael-shop-card__media img {
  transform: none;
}

body.theme-fael .fael-shop-card__quick {
  transform: none;
  opacity: 0;
  transition: opacity 0.2s ease;
}

body.theme-fael .fael-shop-card__link:hover .fael-shop-card__quick {
  transform: none;
  opacity: 1;
}

/* Kill magnetic / lift globally on FAEL */
body.theme-fael .fael-magnetic {
  transform: none !important;
  will-change: auto;
}

@media (prefers-reduced-motion: reduce) {
  body.theme-fael .btn::before,
  body.theme-fael .nav-cta::before,
  body.theme-fael .lang-switch__btn::before,
  body.theme-fael .nav-list a::after {
    transition: none;
    transform: none;
  }
}
