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.

9.4 KB
Raw Blame
<!doctype html>
<!--
  KALLAWAY · tier1 · stat · FRACTION
  "X of Y" glowing fraction with a row of segment dots that light up one-by-one to
  represent the fraction. Big gradient number above the dots. Aurora bloom.
  Slots: kicker (~28 chars uppercase), stat (e.g. "7 of 10"), label (~70 chars, <em>),
         source (~40 chars).
-->
<html>
  <head>
    <meta charset="utf-8" />
    <link rel="stylesheet" href="../../tokens.css" />
    <style>
      html, body { margin: 0; }

      #t1-stat-frac {
        position: absolute; inset: 0; width: 1920px; height: 1080px;
        background: var(--canvas); color: var(--text);
        font-family: var(--font-display); overflow: hidden;
      }

      #t1-stat-frac .bloom {
        position: absolute; inset: 0; background: var(--bloom-bottom); z-index: 1;
      }
      #t1-stat-frac .grid {
        position: absolute; inset: 0; z-index: 1;
        background-image: var(--dot); background-size: var(--dot-size);
        opacity: 0.5;
        -webkit-mask-image: radial-gradient(120% 100% at 50% 60%, #000 35%, transparent 80%);
                mask-image: radial-gradient(120% 100% at 50% 60%, #000 35%, transparent 80%);
      }

      /* Content */
      #t1-stat-frac .content {
        position: absolute; left: 0; right: 0; top: 0; bottom: 0;
        display: flex; flex-direction: column; align-items: center;
        justify-content: center; z-index: 4; gap: 44px; padding-bottom: 40px;
      }

      #t1-stat-frac .kicker {
        font-family: var(--font-mono);
        font-size: var(--size-label);
        font-weight: var(--wt-bold);
        letter-spacing: var(--track-wide);
        text-transform: uppercase;
        color: var(--accent);
        text-shadow: var(--textglow-accent);
      }

      /* Fraction display: "7 of 10" */
      #t1-stat-frac .fraction-row {
        display: flex; align-items: baseline; gap: 28px;
        line-height: 1;
      }
      #t1-stat-frac .frac-num {
        font-family: var(--font-display);
        font-weight: var(--wt-black);
        font-size: 240px;
        letter-spacing: var(--track-tight);
        background: linear-gradient(160deg, #ffffff 12%, rgba(var(--accent-rgb),0.85) 82%);
        -webkit-background-clip: text; background-clip: text;
        -webkit-text-fill-color: transparent; text-fill-color: transparent;
        filter: drop-shadow(0 0 30px rgba(var(--accent-rgb), 0.55))
                drop-shadow(0 0 80px rgba(var(--accent-rgb), 0.28));
      }
      #t1-stat-frac .frac-of {
        font-family: var(--font-body);
        font-weight: var(--wt-semi);
        font-size: 52px;
        color: var(--text-dim);
        letter-spacing: 0.10em;
        text-transform: uppercase;
        padding-bottom: 20px;          /* optical baseline align */
      }
      #t1-stat-frac .frac-denom {
        font-family: var(--font-display);
        font-weight: var(--wt-black);
        font-size: 140px;
        letter-spacing: var(--track-tight);
        color: var(--text-faint);
        filter: drop-shadow(0 0 12px rgba(255,255,255,0.18));
        padding-bottom: 8px;
      }

      /* Segment dots row */
      #t1-stat-frac .dots-row {
        display: flex; gap: 20px; align-items: center; justify-content: center;
      }
      #t1-stat-frac .dot {
        width: 52px; height: 52px; border-radius: 50%;
        /* Off state */
        background: rgba(255,255,255,0.08);
        border: 1.5px solid rgba(255,255,255,0.12);
        transition: none;
        flex-shrink: 0;
      }
      #t1-stat-frac .dot.on {
        background: radial-gradient(circle at 40% 38%,
          #ffffff 0%,
          rgba(var(--accent-rgb), 0.90) 45%,
          rgba(var(--accent-rgb), 0.35) 75%,
          transparent 100%);
        border-color: rgba(var(--accent-rgb), 0.60);
        box-shadow:
          0 0 14px 3px rgba(var(--accent-rgb), 0.65),
          0 0 30px 6px rgba(var(--accent-rgb), 0.30);
      }

      #t1-stat-frac .label {
        font-family: var(--font-body);
        font-size: var(--size-body);
        font-weight: var(--wt-med);
        color: var(--text-dim);
        text-align: center;
        max-width: 900px;
        line-height: 1.45;
      }
      #t1-stat-frac .label em {
        font-style: normal; color: var(--text); text-shadow: var(--textglow);
      }

      #t1-stat-frac .source {
        position: absolute; left: var(--pad); bottom: 44px;
        font-family: var(--font-mono); font-size: var(--size-tiny);
        font-weight: var(--wt-reg); letter-spacing: 0.12em;
        text-transform: uppercase; color: var(--text-faint); z-index: 5;
      }

      #t1-stat-frac .vignette {
        position: absolute; inset: 0; pointer-events: none; z-index: 6;
        background: var(--vignette);
      }
      #t1-stat-frac .grain {
        position: absolute; inset: -40px; background: var(--tex-grain);
        background-size: 200px 200px; mix-blend-mode: overlay; opacity: 0.10;
        pointer-events: none; z-index: 7;
      }
    </style>
  </head>
  <body>
    <div id="t1-stat-frac" data-composition-id="t1-stat-frac" data-start="0" data-width="1920" data-height="1080">
      <div class="bloom"></div>
      <div class="grid"></div>

      <div class="content">
        <div class="kicker" data-slot="kicker">AI READINESS INDEX · 2026</div>

        <div class="fraction-row">
          <div class="frac-num" id="t1-stat-frac-num">7</div>
          <div class="frac-of">of</div>
          <div class="frac-denom" id="t1-stat-frac-denom">10</div>
        </div>
        <!-- The slot drives both the fraction display and the dots row via JS -->
        <!-- Hidden slot anchor for the combined value -->
        <div style="display:none" data-slot="stat" id="t1-stat-frac-slot">7 of 10</div>

        <div class="dots-row" id="t1-stat-frac-dots">
          <!-- Dots built by JS from the fraction -->
        </div>

        <div class="label" data-slot="label">companies say AI has <em>fundamentally changed</em> how they hire engineering talent</div>
      </div>

      <div class="source" data-slot="source">SOURCE · STACK OVERFLOW 2026</div>

      <div class="vignette"></div>
      <div class="grain"></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 });

      /* Parse slot "7 of 10" */
      const slotEl  = document.getElementById("t1-stat-frac-slot");
      const parts   = slotEl.textContent.trim().split(/\s+of\s+/i);
      const numerator   = parseInt(parts[0], 10) || 7;
      const denominator = parseInt(parts[1], 10) || 10;

      const numEl   = document.getElementById("t1-stat-frac-num");
      const denomEl = document.getElementById("t1-stat-frac-denom");
      const dotsRow = document.getElementById("t1-stat-frac-dots");

      /* Set display */
      numEl.textContent   = numerator;
      denomEl.textContent = denominator;

      /* Build dot elements */
      const dotEls = [];
      for (let i = 0; i < denominator; i++) {
        const d = document.createElement("div");
        d.className = "dot";  /* start all off */
        dotsRow.appendChild(d);
        dotEls.push(d);
      }

      /* ambient grain flicker */
      tl.fromTo("#t1-stat-frac .grain",
        { backgroundPosition: "0px 0px" },
        { backgroundPosition: "110px 80px", duration: 0.6, ease: "none", repeat: 11, yoyo: true }, 0);

      /* bloom + grid */
      tl.from("#t1-stat-frac .bloom",
        { autoAlpha: 0, scale: 0.88, transformOrigin: "50% 120%", duration: 1.4, ease: "expo.out" }, 0)
        .from("#t1-stat-frac .grid",
          { autoAlpha: 0, duration: 1.1, ease: "power2.out" }, 0.2)

        /* kicker */
        .from("#t1-stat-frac .kicker",
          { autoAlpha: 0, y: 18, filter: "blur(8px)", duration: 0.75, ease: "power3.out" }, 0.50)

        /* fraction row glides in */
        .from("#t1-stat-frac .fraction-row",
          { autoAlpha: 0, y: 30, filter: "blur(20px)", duration: 1.0, ease: "power4.out" }, 0.70)

        /* numerator focus pull */
        .from("#t1-stat-frac .frac-num",
          { scale: 0.82, transformOrigin: "50% 50%", duration: 0.85, ease: "back.out(1.2)" }, 0.72)

        /* dots light up one by one */
        ;

      /* Stagger the "on" class toggling via gsap calls */
      for (let i = 0; i < denominator; i++) {
        const delay = 1.55 + i * 0.10;
        const dotEl = dotEls[i];
        const isOn  = i < numerator;
        tl.add(function() {
          /* blur in the dot, then if it's "on" apply the glow class */
          const d = dotEl;
          d.style.opacity = "0";
          d.style.transform = "scale(0.4)";
        }, delay - 0.01);
        tl.fromTo(dotEl,
          { autoAlpha: 0, scale: 0.4 },
          { autoAlpha: 1, scale: 1,
            duration: 0.38, ease: "back.out(1.6)",
            onComplete: function() {
              if (isOn) dotEl.classList.add("on");
            }
          }, delay);
      }

      tl
        /* label */
        .from("#t1-stat-frac .label",
          { autoAlpha: 0, y: 20, filter: "blur(8px)", duration: 0.85, ease: "power3.out" }, 2.55)

        /* source */
        .from("#t1-stat-frac .source",
          { autoAlpha: 0, duration: 0.7, ease: "power2.out" }, 2.85)

        /* breathing pulse on "on" dots */
        .to("#t1-stat-frac .dot.on",
          { opacity: 0.60, duration: 1.4, ease: "sine.inOut", repeat: 2, yoyo: true }, 3.10)

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

      window.__timelines["t1-stat-frac"] = tl;
    </script>
  </body>
</html>