/* everything hand-drawn. the filters are svg, put in the page by js/sketch.js (chrome ignores
   filter:url(other.svg#id)), and only take hold under .boil, which js/head.js sets.

   boil: the rules and squares redraw three ways in a loop, like squigglevision. the words never boil.
   wobble: the words are bent once, still.
   scribble: words still arriving bend harder and boil, then calm to the wobble once they've landed */

.boil-defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

@keyframes boil {
  0%   { filter: url(#sq0); }
  33%  { filter: url(#sq1); }
  66%  { filter: url(#sq2); }
  100% { filter: url(#sq0); }
}

@keyframes scribble {
  0%   { filter: url(#tx-scribble0); }
  33%  { filter: url(#tx-scribble1); }
  66%  { filter: url(#tx-scribble2); }
  100% { filter: url(#tx-scribble0); }
}

.boil :is(.edge, .block, .slider-line) {
  filter: url(#sq0);
  animation: boil 0.36s steps(1) infinite;
}

:is(
  .wordmark, .top .right, .subscribe-row, .subscribe p,
  .legend .pairing,
  .card-head, .name, .excerpt, .body, .meta, .index-row, .beside .next, .steps a, .dates, .axis,
  .post-nav, .title, .ticks, .version-info, .annotation,
  .stream > :not(img, figure, .pics), .source p, .source a,
  .feed-info, .feeds-grid p,
  .blog .info
) {
  filter: url(#tx-wobble);
}

.boil .stream .coming:not(.landed),
.boil[data-look="wall"] :is(.card:hover, a:focus-visible) .live .excerpt:not(.done) ins,
.boil .subscribe input.typing {
  filter: url(#tx-scribble0);
  animation: scribble 0.24s steps(1) infinite;
}

/* still drawn by hand for anyone who asks for less motion, just not boiling */
@media (prefers-reduced-motion: reduce) {
  .boil :is(.edge, .block, .slider-line),
  .boil .stream .coming:not(.landed),
  .boil[data-look="wall"] :is(.card:hover, a:focus-visible) .live .excerpt:not(.done) ins,
  .boil .subscribe input.typing {
    animation: none;
  }
}
