



/* =============================================
   PRINT
   ============================================= */
@media print { .backgrounds { background-color: var(--bg); } }


/* ╔═════════════════════════════════════════════╗
   ║               ANIMATIONS                   ║
   ║                                            ║
   ║  A) Keyframes                              ║
   ║  B) Auto entrance — children stagger in    ║
   ║  C) Auto exit    — past slide fades out    ║
   ║  D) Fragment classes — stepped reveals     ║
   ║  E) Continuous / looping effects           ║
   ╚═════════════════════════════════════════════╝ */

/* ─────────────────────────────────────────────
   A) KEYFRAMES
   ───────────────────────────────────────────── */

/* Entrances */
@keyframes sig-fade-up {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0);    }
}
@keyframes sig-fade-down {
  from { opacity: 0; transform: translateY(-30px); }
  to   { opacity: 1; transform: translateY(0);     }
}
@keyframes sig-fade-left {
  from { opacity: 0; transform: translateX(44px); }
  to   { opacity: 1; transform: translateX(0);    }
}
@keyframes sig-fade-right {
  from { opacity: 0; transform: translateX(-44px); }
  to   { opacity: 1; transform: translateX(0);     }
}
@keyframes sig-scale-in {
  from { opacity: 0; transform: scale(0.80); }
  to   { opacity: 1; transform: scale(1);    }
}
@keyframes sig-blur-in {
  from { opacity: 0; filter: blur(12px); transform: scale(0.96); }
  to   { opacity: 1; filter: blur(0);    transform: scale(1);    }
}
@keyframes sig-flip-x {
  from { opacity: 0; transform: perspective(700px) rotateX(-28deg) translateY(22px); }
  to   { opacity: 1; transform: perspective(700px) rotateX(0deg)   translateY(0);   }
}
@keyframes sig-flip-y {
  from { opacity: 0; transform: perspective(700px) rotateY(28deg) translateX(-16px); }
  to   { opacity: 1; transform: perspective(700px) rotateY(0deg)  translateX(0);    }
}
@keyframes sig-pop {
  0%   { opacity: 0; transform: scale(0.68); }
  65%  { opacity: 1; transform: scale(1.06); }
  100% { opacity: 1; transform: scale(1);    }
}
@keyframes sig-wipe-up {
  from { clip-path: inset(100% 0 0 0); }
  to   { clip-path: inset(0 0 0 0);    }
}
@keyframes sig-wipe-right {
  from { clip-path: inset(0 100% 0 0); }
  to   { clip-path: inset(0 0 0 0);    }
}

/* Exits */
@keyframes sig-out-down {
  from { opacity: 1; transform: translateY(0);    }
  to   { opacity: 0; transform: translateY(22px); }
}
@keyframes sig-out-up {
  from { opacity: 1; transform: translateY(0);     }
  to   { opacity: 0; transform: translateY(-22px); }
}
@keyframes sig-out-scale {
  from { opacity: 1; transform: scale(1);    }
  to   { opacity: 0; transform: scale(0.88); }
}
@keyframes sig-out-blur {
  from { opacity: 1; filter: blur(0);    }
  to   { opacity: 0; filter: blur(10px); }
}

/* Continuous */
@keyframes sig-float {
  0%, 100% { transform: translateY(0);    }
  50%       { transform: translateY(-7px); }
}
@keyframes sig-gradient-sweep {
  0%   { background-position: 0%   50%; }
  100% { background-position: 500% 50%; }
}
@keyframes sig-border-glow {
  0%, 100% { box-shadow: 0 0 0 0px rgba(18,179,178,0.5); }
  50%       { box-shadow: 0 0 0 9px rgba(18,179,178,0);   }
}
@keyframes sig-spin-slow {
  from { transform: rotate(0deg);   }
  to   { transform: rotate(360deg); }
}

/* ─────────────────────────────────────────────
   B) AUTO ENTRANCE
   Every direct child of .present staggered.
   Cards/callouts inside get a nested stagger.
   ───────────────────────────────────────────── */

/* Default: fade-up for all direct children */
.reveal .slides section.present > * {
  animation: sig-fade-up 0.55s cubic-bezier(0.22,0.61,0.36,1) both;
}

/* Per-child stagger */
.reveal .slides section.present > *:nth-child(1)   { animation-delay: 0.04s; }
.reveal .slides section.present > *:nth-child(2)   { animation-delay: 0.13s; }
.reveal .slides section.present > *:nth-child(3)   { animation-delay: 0.22s; }
.reveal .slides section.present > *:nth-child(4)   { animation-delay: 0.31s; }
.reveal .slides section.present > *:nth-child(5)   { animation-delay: 0.38s; }
.reveal .slides section.present > *:nth-child(6)   { animation-delay: 0.44s; }
.reveal .slides section.present > *:nth-child(n+7) { animation-delay: 0.50s; }

/* Don't animate the gradient bar pseudo-element */
.reveal .slides section.present::before { animation: none; }

/* h1/h2: wipe up for more drama */
.reveal .slides section.present h1,
.reveal .slides section.present h2 {
  animation: sig-wipe-up 0.6s cubic-bezier(0.22,0.61,0.36,1) both;
}

/* code blocks: slide in from right */
.reveal .slides section.present pre {
  animation: sig-fade-left 0.5s cubic-bezier(0.22,0.61,0.36,1) 0.18s both;
}

/* blockquotes: flip on X */
.reveal .slides section.present blockquote {
  animation: sig-flip-x 0.55s cubic-bezier(0.22,0.61,0.36,1) 0.16s both;
}

/* grid children: scale-in with stagger */
.reveal .slides section.present .grid-2 > *,
.reveal .slides section.present .grid-3 > *,
.reveal .slides section.present .grid-4 > * {
  animation: sig-scale-in 0.42s cubic-bezier(0.22,0.61,0.36,1) both;
}
.reveal .slides section.present .grid-2 > *:nth-child(1),
.reveal .slides section.present .grid-3 > *:nth-child(1),
.reveal .slides section.present .grid-4 > *:nth-child(1) { animation-delay: 0.18s; }
.reveal .slides section.present .grid-2 > *:nth-child(2),
.reveal .slides section.present .grid-3 > *:nth-child(2),
.reveal .slides section.present .grid-4 > *:nth-child(2) { animation-delay: 0.30s; }
.reveal .slides section.present .grid-3 > *:nth-child(3),
.reveal .slides section.present .grid-4 > *:nth-child(3) { animation-delay: 0.42s; }
.reveal .slides section.present .grid-4 > *:nth-child(4) { animation-delay: 0.52s; }

/* callout outer: flip-x */
.reveal .slides section.present .callout {
  animation: sig-flip-x 0.5s cubic-bezier(0.22,0.61,0.36,1) both;
}
/* callout tab: slide from left, slightly delayed */
.reveal .slides section.present .callout .callout-title {
  animation: sig-fade-right 0.38s cubic-bezier(0.22,0.61,0.36,1) 0.28s both;
}
/* callout body: fade up, slightly more delayed */
.reveal .slides section.present .callout .callout-content {
  animation: sig-fade-up 0.38s cubic-bezier(0.22,0.61,0.36,1) 0.38s both;
}

/* ─────────────────────────────────────────────
   C) AUTO EXIT
   .past slides animate out subtly so nav is snappy.
   ───────────────────────────────────────────── */

.reveal .slides section.past > * {
  animation: sig-out-down 0.28s ease forwards;
}
.reveal .slides section.past > *:nth-child(1)   { animation-delay: 0s;    }
.reveal .slides section.past > *:nth-child(2)   { animation-delay: 0.03s; }
.reveal .slides section.past > *:nth-child(3)   { animation-delay: 0.06s; }
.reveal .slides section.past > *:nth-child(n+4) { animation-delay: 0.08s; }

/* Future slides: just invisible, no animation */
.reveal .slides section.future > * { opacity: 0; }

/* ─────────────────────────────────────────────
   D) FRAGMENT ANIMATION CLASSES
   Add class="fragment anim-*" to any element.
   Combine with data-fragment-index="N" for order.

   Available:
     anim-fade-up    anim-fade-down
     anim-fade-left  anim-fade-right
     anim-pop        anim-blur
     anim-flip       anim-flip-y
     anim-wipe       anim-zoom
     anim-strike     anim-highlight
   ───────────────────────────────────────────── */

.reveal .fragment { opacity: 0; visibility: inherit; }
.reveal .fragment.visible { opacity: 1; }

/* fade-up */
.reveal .fragment.anim-fade-up {
  opacity: 0; transform: translateY(26px);
  transition: opacity 0.48s cubic-bezier(0.22,0.61,0.36,1),
              transform 0.48s cubic-bezier(0.22,0.61,0.36,1);
}
.reveal .fragment.anim-fade-up.visible { opacity:1; transform:translateY(0); }

/* fade-down */
.reveal .fragment.anim-fade-down {
  opacity: 0; transform: translateY(-26px);
  transition: opacity 0.48s cubic-bezier(0.22,0.61,0.36,1),
              transform 0.48s cubic-bezier(0.22,0.61,0.36,1);
}
.reveal .fragment.anim-fade-down.visible { opacity:1; transform:translateY(0); }

/* fade from right */
.reveal .fragment.anim-fade-left {
  opacity: 0; transform: translateX(44px);
  transition: opacity 0.44s ease, transform 0.44s cubic-bezier(0.22,0.61,0.36,1);
}
.reveal .fragment.anim-fade-left.visible { opacity:1; transform:translateX(0); }

/* fade from left */
.reveal .fragment.anim-fade-right {
  opacity: 0; transform: translateX(-44px);
  transition: opacity 0.44s ease, transform 0.44s cubic-bezier(0.22,0.61,0.36,1);
}
.reveal .fragment.anim-fade-right.visible { opacity:1; transform:translateX(0); }

/* pop with spring overshoot */
.reveal .fragment.anim-pop {
  opacity: 0; transform: scale(0.7);
  transition: opacity 0.38s ease, transform 0.38s cubic-bezier(0.34,1.56,0.64,1);
}
.reveal .fragment.anim-pop.visible { opacity:1; transform:scale(1); }

/* blur-in */
.reveal .fragment.anim-blur {
  opacity: 0; filter: blur(10px); transform: scale(0.96);
  transition: opacity 0.5s ease, filter 0.5s ease, transform 0.5s ease;
}
.reveal .fragment.anim-blur.visible { opacity:1; filter:blur(0); transform:scale(1); }

/* flip on X */
.reveal .fragment.anim-flip {
  opacity: 0;
  transform: perspective(700px) rotateX(-28deg) translateY(18px);
  transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.22,0.61,0.36,1);
}
.reveal .fragment.anim-flip.visible {
  opacity:1;
  transform: perspective(700px) rotateX(0) translateY(0);
}

/* flip on Y */
.reveal .fragment.anim-flip-y {
  opacity: 0;
  transform: perspective(700px) rotateY(30deg) translateX(-14px);
  transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.22,0.61,0.36,1);
}
.reveal .fragment.anim-flip-y.visible {
  opacity:1;
  transform: perspective(700px) rotateY(0) translateX(0);
}

/* wipe up via clip-path */
.reveal .fragment.anim-wipe {
  opacity: 1;
  clip-path: inset(100% 0 0 0);
  transition: clip-path 0.5s cubic-bezier(0.22,0.61,0.36,1);
}
.reveal .fragment.anim-wipe.visible { clip-path: inset(0 0 0 0); }

/* zoom-in (starts large, lands at 1) */
.reveal .fragment.anim-zoom {
  opacity: 0; transform: scale(1.3);
  transition: opacity 0.4s ease, transform 0.4s cubic-bezier(0.22,0.61,0.36,1);
}
.reveal .fragment.anim-zoom.visible { opacity:1; transform:scale(1); }

/* strike-through */
.reveal .fragment.anim-strike {
  opacity: 1;
  transition: color 0.3s ease, text-decoration 0.3s ease;
}
.reveal .fragment.anim-strike.visible {
  color: var(--text-muted);
  text-decoration: line-through;
}

/* border glow highlight */
.reveal .fragment.anim-highlight {
  opacity: 1;
  transition: box-shadow 0.3s ease;
}
.reveal .fragment.anim-highlight.visible {
  animation: sig-border-glow 1.5s ease 1 forwards;
}

/* ─────────────────────────────────────────────
   E) CONTINUOUS / LOOPING
   Apply as a standalone class (no .fragment needed).
   ───────────────────────────────────────────── */

/* gradient text shimmer */
.reveal .anim-shimmer {
  background: var(--gradient);
  background-size: 500% 100%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: sig-gradient-sweep 7s linear infinite;
}

/* gentle float — good for icons */
.reveal .anim-float {
  display: inline-block;
  animation: sig-float 3.2s ease-in-out infinite;
}

/* pulsing glow ring */
.reveal .anim-pulse {
  animation: sig-border-glow 2.2s ease-in-out infinite;
}

/* slow rotation */
.reveal .anim-spin {
  display: inline-block;
  animation: sig-spin-slow 8s linear infinite;
}

.author::before {
  content: "";
  display: inline-block;
  font-size: 1em;           /* key */
  width: 1em;
  height: 1em;
  margin-right: 0.4em;

  background-image: url("https://ludattel.de/eteach/svg/eTeach-ICON-Person-004-path-RGB-black.svg");
  background-size: 200% 200%;
  background-repeat: no-repeat;
  background-position: center;

  vertical-align: -0.15em;  /* tweak alignment */
}
strong {
color: var(--sig-3);
}
em {
color: var(--sig-1);
}

/* =============================================
   PRINT FIX
   ============================================= */
@media print {
  .backgrounds { background-color: var(--bg); }
  
  .reveal .slide-background video {
    width: auto;
    height: auto;
}

  /* Reset all animation/visibility states */
  .reveal .slides section > *,
  .reveal .slides section.past > *,
  .reveal .slides section.future > *,
  .reveal .slides section.present > * {
    animation: none !important;
    transition: none !important;
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
    clip-path: none !important;
    visibility: visible !important;
  }
  
  /* Show all slides, not just .present */
  .reveal .slides section,
  .reveal .slides section.past,
  .reveal .slides section.future {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
  }

  /* Fragments: show everything revealed or not */
  .reveal .fragment,
  .reveal .fragment.visible {
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
    clip-path: none !important;
    visibility: visible !important;
  }
}




/* ─────────────────────────────────────────────
   PRINT PLACEHOLDER BASE
──────────────────────────────────────────── */

.print-placeholder {
  display: none; /* hidden on screen */
}

/* only active in print */
@media print {

  .print-placeholder {
    display: flex !important;


    align-items: center !important;
    justify-content: center !important;

    flex-direction: column !important;

    width: 100% !important;
    min-height: 120px !important;

    border: 2px dashed #999 !important;
    border-radius: 8px !important;

    background: #f7f8fb !important;
    color: #444 !important;

    font-family: 'IBM Plex Mono', monospace !important;
    font-size: 0.75em !important;

    text-align: center !important;
    padding: 1em !important;

    box-sizing: border-box !important;
    gap: 0.4em !important;
  }

  /* ─────────────────────────────────────────────
     CONTENT ELEMENTS
  ───────────────────────────────────────────── */

  .print-placeholder .print-placeholder-icon {
    font-size: 2em !important;
    line-height: 1 !important;
  }

  .print-placeholder .print-placeholder-label {
    font-weight: 600 !important;
    color: #111 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.08em !important;
    font-size: 0.9em !important;
  }

  .print-placeholder .print-placeholder-url {
    color: #12b3b2 !important;
    word-break: break-all !important;
    max-width: 80% !important;
  }

  /* ─────────────────────────────────────────────
     ACTIONS (LINK + BUTTON)
  ───────────────────────────────────────────── */

  .print-placeholder-actions {
    display: flex !important;
    gap: 0.5em !important;
    margin-top: 0.4em !important;
    align-items: center !important;
    justify-content: center !important;
  }

  /* link button */
  .print-placeholder-link {
    display: inline-block !important;
    padding: 0.25em 0.6em !important;

    border-radius: 4px !important;
    border: 1px solid #12b3b2 !important;

    color: #12b3b2 !important;
    text-decoration: none !important;

    font-size: 0.75em !important;
    font-weight: 600 !important;
  }

  .print-placeholder-link:hover {
    background: #12b3b2 !important;
    color: #fff !important;
  }

  /* open button */
  .print-placeholder-button {
    padding: 0.25em 0.6em !important;

    border-radius: 4px !important;
    border: 1px solid #444 !important;

    background: #444 !important;
    color: #fff !important;

    font-size: 0.75em !important;
    font-weight: 600 !important;

    cursor: pointer !important;
  }

  .print-placeholder-button:hover {
    background: #000 !important;
  }

  /* ─────────────────────────────────────────────
     IMAGE VARIANT (COMPACT / SOURCE NOTE STYLE)
  ───────────────────────────────────────────── */

  .print-placeholder--image {
    flex-direction: row !important;
    justify-content: flex-start !important;
    align-items: center !important;

    min-height: unset !important;
    padding: 0.4em 0.6em !important;

    gap: 0.6em !important;

    border: 1px solid #bbb !important;
    background: #fafafa !important;
    font-size: 0.7em !important;
  }

  .print-placeholder--image .print-placeholder-icon {
    font-size: 1.2em !important;
  }

  .print-placeholder--image .print-placeholder-actions {
    display: none !important; /* no buttons for images */
  }

  .print-placeholder--image .print-placeholder-url {
    max-width: 100% !important;
    font-size: 0.7em !important;
    opacity: 0.8 !important;
  }
}


