Skip to content

Herk Edit Kit by Nate Herk: edit videos, reels, and YouTube Shorts with Codex or Claude Code. 15 skills, transcript-driven cuts, storytelling, 406 motion-graphics cards, and HyperFrames templates.

6.3 KB
Raw Blame
<!doctype html>
<!--
  KALLAWAY · tier2 · label · BUBBLE
  A glass speech-bubble callout with a small pointer tail at the bottom-left.
  The bubble scales up from zero with a back.out spring; term glows bold inside;
  detail is dimmer text below. Anchored right side, mid-height.
  Slots: term (~24 chars), detail (~70 chars).
-->
<html>
  <head>
    <meta charset="utf-8" />
    <link rel="stylesheet" href="../../tokens.css" />
    <style>
      html, body { margin: 0; background: transparent; }

      #t2-lb-bub {
        position: absolute; inset: 0; width: 1920px; height: 1080px;
        background: transparent; overflow: hidden;
        font-family: var(--font-display);
      }

      /* Local glow centered on bubble */
      #t2-lb-bub .local-glow {
        position: absolute; right: 100px; top: 340px;
        width: 540px; height: 320px; border-radius: 50%;
        background: radial-gradient(ellipse at 50% 45%,
          rgba(var(--accent-rgb), 0.24) 0%,
          rgba(var(--accent-rgb), 0.08) 55%,
          transparent 80%);
        filter: blur(48px);
        pointer-events: none;
      }

      /* Bubble wrapper — anchored right */
      #t2-lb-bub .bubble-wrap {
        position: absolute; right: 130px; top: 360px;
        display: flex; flex-direction: column; gap: 0;
        /* transform-origin bottom-left for tail-anchored spring */
        transform-origin: calc(100% - 60px) 100%;
      }

      /* Main bubble body */
      #t2-lb-bub .bubble-body {
        padding: 24px 30px 22px;
        max-width: 480px;
        background: var(--glass-bg-dark);
        backdrop-filter: var(--glass-blur);
        -webkit-backdrop-filter: var(--glass-blur);
        border: 1.5px solid rgba(var(--accent-rgb), 0.45);
        border-radius: var(--radius);
        box-shadow: 0 0 28px rgba(var(--accent-rgb), 0.28),
                    inset 0 1px 0 rgba(255,255,255,0.18),
                    var(--glass-shadow);
        position: relative;
        overflow: hidden;
      }

      /* Top inner-highlight shimmer */
      #t2-lb-bub .bubble-body::before {
        content: "";
        position: absolute; top: 0; left: 16px; right: 16px; height: 1px;
        background: linear-gradient(90deg, transparent, rgba(255,255,255,0.55) 40%, rgba(255,255,255,0.55) 60%, transparent);
        border-radius: 1px;
      }

      /* Accent bar at top of bubble */
      #t2-lb-bub .bubble-accent-bar {
        height: 2px; width: 40px;
        background: var(--accent);
        box-shadow: var(--glow-accent-sm);
        border-radius: 1px;
        margin-bottom: 14px;
      }

      /* Term text */
      #t2-lb-bub .bubble-term {
        font-family: var(--font-display); font-weight: var(--wt-bold);
        font-size: 32px; letter-spacing: var(--track-snug);
        color: var(--white); text-shadow: var(--textglow);
        margin-bottom: 10px;
        line-height: 1.1;
      }

      /* Detail text */
      #t2-lb-bub .bubble-detail {
        font-family: var(--font-body); font-weight: var(--wt-reg);
        font-size: 21px; line-height: 1.5;
        color: var(--text-dim);
        max-width: 420px;
      }

      /* Pointer tail — SVG triangle below-left of the bubble */
      #t2-lb-bub .tail-svg {
        /* aligned so its left edge lines up 60px from right of bubble */
        position: absolute;
        /* right-align: bubble is at right:130px, width up to 480px;
           tail starts at bubble right-60 = right:190px */
        right: 208px; top: 570px;  /* top = 360 + 24+22+fontSize heights ~ 210px */
        width: 40px; height: 24px;
        overflow: visible;
      }

      #t2-lb-bub .tail-path {
        fill: var(--glass-bg-dark);
        stroke: rgba(var(--accent-rgb), 0.45);
        stroke-width: 1.5px;
        stroke-linejoin: round;
        filter: drop-shadow(0 2px 8px rgba(0,0,0,0.50));
      }
    </style>
  </head>
  <body>
    <div id="t2-lb-bub" data-composition-id="t2-lb-bub" data-start="0" data-width="1920" data-height="1080">

      <div class="local-glow"></div>

      <!-- Pointer tail SVG (appears below the bubble corner) -->
      <svg class="tail-svg" viewBox="0 0 40 24" xmlns="http://www.w3.org/2000/svg">
        <polygon class="tail-path" points="0,0 40,0 10,24" />
      </svg>

      <div class="bubble-wrap">
        <div class="bubble-body">
          <div class="bubble-accent-bar"></div>
          <div class="bubble-term" data-slot="term">Fine-Tuning</div>
          <div class="bubble-detail" data-slot="detail">Adapting a pre-trained model to a specific task using a small, curated dataset.</div>
        </div>
      </div>

    </div>

    <script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/gsap.min.js"></script>
    <script>
      window.__timelines = window.__timelines || {};
      const tl = gsap.timeline({ paused: true });

      const COMP = "#t2-lb-bub";

      /* Local glow blooms in */
      tl.from(`${COMP} .local-glow`, {
            autoAlpha: 0, scale: 0.55, transformOrigin: "50% 45%",
            duration: 1.1, ease: "expo.out" }, 0)

        /* Tail pops in first (anchor hint) */
        .from(`${COMP} .tail-svg`, {
            autoAlpha: 0, scale: 0.4, transformOrigin: "0% 0%",
            duration: 0.38, ease: "back.out(1.8)" }, 0.12)

        /* Bubble body springs up from the tail anchor */
        .from(`${COMP} .bubble-wrap`, {
            autoAlpha: 0, scale: 0.72, y: 22,
            duration: 0.78, ease: "back.out(1.4)" }, 0.26)

        /* Accent bar draws width */
        .from(`${COMP} .bubble-accent-bar`, {
            scaleX: 0, transformOrigin: "0% 50%",
            duration: 0.40, ease: "power3.out" }, 0.72)

        /* Term glides in */
        .from(`${COMP} .bubble-term`, {
            autoAlpha: 0, y: 12, filter: "blur(8px)",
            duration: 0.62, ease: "power4.out" }, 0.88)

        /* Detail follows */
        .from(`${COMP} .bubble-detail`, {
            autoAlpha: 0, y: 10, filter: "blur(6px)",
            duration: 0.58, ease: "power4.out" }, 1.08)

        /* Finite glow pulse on bubble border */
        .to(`${COMP} .bubble-body`, {
            boxShadow: "0 0 44px rgba(55,189,248,0.50), inset 0 1px 0 rgba(255,255,255,0.24), 0 24px 70px rgba(0,0,0,0.50)",
            duration: 1.2, ease: "sine.inOut", repeat: 2, yoyo: true }, 1.90)

        .set({}, {}, 7);

      window.__timelines["t2-lb-bub"] = tl;
    </script>
  </body>
</html>