/* =========================================================================
   ADA PREMIUM FX — generischer Veredelungs-Layer für ALLE ADA-Seiten.
   Wirkt über gemeinsame Klassennamens-Muster (…-card, …-btn, …-section-head,
   …-detail-item, …-step, …-stat …) auf jeder Unterseite, ohne dass jede
   Seite einzeln angefasst werden muss. Rein additiv, keine Layout-Brüche.
   ========================================================================= */

@media (prefers-reduced-motion: no-preference) {

  /* ---- 1) Scroll-Reveal --------------------------------------------- */
  .adafx-reveal {
    opacity: 0;
    transform: translateY(26px) scale(.98);
    transition: opacity .7s cubic-bezier(.2,.7,.2,1) var(--afx-d, 0ms),
                transform .7s cubic-bezier(.2,.7,.2,1) var(--afx-d, 0ms);
    will-change: opacity, transform;
  }
  .adafx-reveal.adafx-in { opacity: 1; transform: translateY(0) scale(1); }

  /* ---- 2) Card spotlight + micro-tilt -------------------------------- */
  [class*="-card"]:not(.adax-modal-box):not([class*="-card-"]),
  [class*="-detail-item"],
  [class*="-pkg-card"] {
    position: relative;
    transition: transform .35s cubic-bezier(.2,.8,.3,1), box-shadow .35s ease, border-color .35s ease;
  }
  [class*="-card"]:not(.adax-modal-box):not([class*="-card-"])::after,
  [class*="-detail-item"]::after,
  [class*="-pkg-card"]::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    opacity: 0;
    transition: opacity .3s ease;
    background: radial-gradient(240px circle at var(--afx-mx, 50%) var(--afx-my, 50%), rgba(255,255,255,.14), transparent 62%);
    z-index: 1;
  }
  [class*="-card"].adafx-tilt-active:not(.adax-modal-box):not([class*="-card-"]),
  [class*="-detail-item"].adafx-tilt-active,
  [class*="-pkg-card"].adafx-tilt-active {
    transform: perspective(900px) rotateX(var(--afx-rx, 0deg)) rotateY(var(--afx-ry, 0deg)) translateY(-3px);
    box-shadow: 0 22px 55px -18px rgba(0,0,0,.6), 0 0 30px -8px rgba(var(--rgb,0,234,255),.35);
  }
  [class*="-card"].adafx-tilt-active:not(.adax-modal-box):not([class*="-card-"])::after,
  [class*="-detail-item"].adafx-tilt-active::after,
  [class*="-pkg-card"].adafx-tilt-active::after { opacity: 1; }

  /* ---- 3) Button shimmer sweep + magnetic hover ---------------------- */
  a[class*="-btn"], button[class*="-btn"] {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    transition: transform .18s ease, box-shadow .25s ease, filter .25s ease;
  }
  a[class*="-btn"]::before, button[class*="-btn"]::before {
    content: "";
    position: absolute;
    top: 0; left: -60%;
    width: 45%; height: 100%;
    background: linear-gradient(115deg, transparent, rgba(255,255,255,.35), transparent);
    transform: skewX(-18deg);
    transition: left .55s ease;
    z-index: 1;
    pointer-events: none;
  }
  a[class*="-btn"]:hover::before, button[class*="-btn"]:hover::before { left: 130%; }
  a[class*="-btn"]:hover, button[class*="-btn"]:hover { filter: brightness(1.05); }
  a[class*="-btn"]:active, button[class*="-btn"]:active { transform: scale(.97); }

  /* ---- 4) Section-head animated accent underline --------------------- */
  [class*="-section-head"] h2 { position: relative; display: inline-block; }
  [class*="-section-head"] h2::after {
    content: "";
    position: absolute;
    left: 0; bottom: -8px;
    height: 3px; width: 0;
    background: linear-gradient(90deg, var(--c, #00eaff), transparent);
    box-shadow: 0 0 10px rgba(var(--rgb,0,234,255),.7);
    transition: width .9s cubic-bezier(.2,.8,.2,1);
  }
  [class*="-section-head"].adafx-in h2::after,
  [class*="-section-head"] h2.adafx-in::after { width: 92px; }

  /* ---- 5) Stat counters: soft glow pulse when counted ----------------- */
  [class*="-stat"] b, .adav7-trust-strip strong { transition: text-shadow .4s ease; }
  .adafx-counted { animation: adafxCountGlow .9s ease-out 1; }
  @keyframes adafxCountGlow {
    0% { text-shadow: 0 0 0 rgba(var(--rgb,0,234,255),0); }
    45% { text-shadow: 0 0 22px rgba(var(--rgb,0,234,255),.9); }
    100% { text-shadow: 0 0 14px rgba(var(--rgb,0,234,255),.5); }
  }

  /* ---- 6) Hero parallax layers ---------------------------------------- */
  [class*="-hero-bg"] { will-change: transform; }

  /* ---- 7) Ticker light-sweep overlay ----------------------------------- */
  [class*="-ticker"] { position: relative; overflow: hidden; }
  [class*="-ticker"]::after {
    content: "";
    position: absolute; inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.06) 45%, transparent 55%, transparent);
    background-size: 220% 100%;
    animation: adafxTickerSweep 6.5s linear infinite;
    pointer-events: none;
  }
  @keyframes adafxTickerSweep { 0% { background-position: 140% 0; } 100% { background-position: -40% 0; } }

  /* ---- 8) FAQ accordion polish (native <details> + custom .xx-faq-item) */
  [class*="-faq"] details, [class$="-faq-item"] {
    transition: border-color .25s ease, background .25s ease;
  }
  details[open] summary, [class$="-faq-item"].open [class$="-faq-q"] {
    color: var(--c, #00eaff);
  }
  [class*="-plus"] { display: inline-block; transition: transform .3s ease; }
  [class$="-faq-item"].open [class*="-plus"] { transform: rotate(45deg); }
}

/* ---- 9) Signature: custom "power cable" scrollbar ---------------------- */
body.ada-v7-active { scrollbar-width: thin; scrollbar-color: var(--c, #00eaff) #060a14; }
body.ada-v7-active::-webkit-scrollbar { width: 11px; }
body.ada-v7-active::-webkit-scrollbar-track { background: #05070f; }
body.ada-v7-active::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--c, #00eaff), #0a2540);
  border-radius: 8px;
  border: 2px solid #05070f;
  box-shadow: 0 0 8px rgba(0,234,255,.5);
}
body.ada-v7-active::-webkit-scrollbar-thumb:hover { background: var(--c, #00eaff); }

::selection { text-shadow: none; }

/* ---- 10) Boot / "Power-On" intro overlay -------------------------------- */
#adafxBoot {
  position: fixed; inset: 0; z-index: 999999;
  background: #02050c;
  display: flex; align-items: center; justify-content: center;
  transition: opacity .5s ease, visibility .5s ease;
}
#adafxBoot.adafx-hide { opacity: 0; visibility: hidden; pointer-events: none; }
#adafxBoot svg { width: min(72vw, 260px); height: auto; overflow: visible; }
#adafxBoot .adafx-bolt-path {
  fill: none;
  stroke: #00eaff;
  stroke-width: 6;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 340;
  stroke-dashoffset: 340;
  filter: drop-shadow(0 0 10px rgba(0,234,255,.9)) drop-shadow(0 0 26px rgba(0,234,255,.5));
  animation: adafxDraw 1.05s cubic-bezier(.3,.8,.2,1) forwards;
}
#adafxBoot .adafx-bolt-fill {
  fill: #00eaff;
  opacity: 0;
  filter: drop-shadow(0 0 18px rgba(0,234,255,.85));
  animation: adafxFillIn .5s ease-out .9s forwards, adafxFlicker 1.1s ease-in-out .95s;
}
#adafxBoot .adafx-boot-label {
  position: absolute;
  bottom: 14%;
  left: 0; right: 0;
  text-align: center;
  font-family: Rajdhani, Inter, sans-serif;
  letter-spacing: .3em;
  text-transform: uppercase;
  font-size: .8rem;
  color: #6fe9ff;
  opacity: 0;
  animation: adafxLabelIn .6s ease-out 1.05s forwards;
}
@keyframes adafxDraw { to { stroke-dashoffset: 0; } }
@keyframes adafxFillIn { to { opacity: 1; } }
@keyframes adafxFlicker {
  0%, 100% { opacity: 1; }
  10% { opacity: .4; }
  18% { opacity: 1; }
  24% { opacity: .55; }
  30% { opacity: 1; }
}
@keyframes adafxLabelIn { to { opacity: .85; } }
@media (prefers-reduced-motion: reduce) {
  #adafxBoot { display: none !important; }
}

/* ---- 11) Cursor spark trail + click bursts ------------------------------ */
#adafxSparkLayer {
  position: fixed; inset: 0; z-index: 9000;
  pointer-events: none;
}
.adafx-spark {
  position: fixed;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--adafx-spark-color, #00eaff);
  box-shadow: 0 0 8px 1px var(--adafx-spark-color, #00eaff);
  pointer-events: none;
  z-index: 9001;
  animation: adafxSparkFade .6s ease-out forwards;
}
@keyframes adafxSparkFade {
  0% { opacity: .9; transform: translate(-50%,-50%) scale(1); }
  100% { opacity: 0; transform: translate(-50%,-50%) scale(.2) translateY(14px); }
}
.adafx-burst {
  position: fixed;
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--adafx-spark-color, #00eaff);
  box-shadow: 0 0 10px 2px var(--adafx-spark-color, #00eaff);
  pointer-events: none;
  z-index: 9002;
  animation: adafxBurstFly .55s cubic-bezier(.2,.7,.3,1) forwards;
}
@keyframes adafxBurstFly {
  0% { opacity: 1; transform: translate(-50%,-50%) translate(0,0) scale(1); }
  100% { opacity: 0; transform: translate(-50%,-50%) translate(var(--afx-bx,0px), var(--afx-by,0px)) scale(.3); }
}

/* ---- 11b) Scroll progress bar (Akzentleitung am oberen Rand) ------------- */
#adafxProgress {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  width: 0;
  z-index: 100000;
  pointer-events: none;
  border-radius: 0 3px 3px 0;
}

/* ---- 11c) Value-Headline: em-Akzent in allen Seiten-Heros ----------------- */
[class*="-hero"] h1 em { font-style: normal; color: var(--c, #00eaff); }

/* ---- 12) Easter-egg toast ------------------------------------------------ */
.adafx-toast {
  position: fixed;
  left: 50%; bottom: 26px;
  transform: translateX(-50%) translateY(20px);
  background: linear-gradient(135deg, #0c1120, #070a14);
  border: 1px solid var(--c, #00eaff);
  color: #fff;
  font-family: Rajdhani, Inter, sans-serif;
  font-weight: 800;
  letter-spacing: .04em;
  padding: 14px 22px;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0,0,0,.5), 0 0 30px rgba(var(--rgb,0,234,255),.4);
  z-index: 9500;
  opacity: 0;
  transition: opacity .35s ease, transform .35s ease;
}
.adafx-toast.adafx-show { opacity: 1; transform: translateX(-50%) translateY(0); }

@media (prefers-reduced-motion: reduce) {
  #adafxSparkLayer, .adafx-spark, .adafx-burst { display: none !important; }
}
@media (pointer: coarse) {
  #adafxSparkLayer { display: none; }
}
