/* Splat, the Botple mascot, on the home page (see splat.js). */
.splat{display:inline-flex;align-items:flex-end;gap:6px;vertical-align:bottom;cursor:pointer;user-select:none;-webkit-tap-highlight-color:transparent}
.splat-body{position:relative;display:block;flex:none}
.splat-frame{position:absolute;left:0;top:0;display:block;visibility:hidden}
.splat-frame.on{visibility:visible}
.splat-prop{display:block;flex:none;margin-bottom:6px}
.splat-prop svg{display:block}

/* He breathes: two steps, like a sprite, never a smooth slide. */
.splat-idle .splat-body,.splat-wave .splat-body,.splat-cheer .splat-body{animation:splat-bob 1.8s steps(2,jump-none) infinite}
.splat-prop{animation:splat-bob 1.8s steps(2,jump-none) infinite;animation-delay:.45s}
@keyframes splat-bob{50%{transform:translateY(-3px)}}
.splat-body.hop{animation:splat-hop .42s steps(4,jump-none) 1}
@keyframes splat-hop{40%{transform:translateY(-12px)}100%{transform:none}}

/* 1. The first screen is his playground (splat.js, roam). He is drawn on a
   sheet laid over the hero that takes no clicks; only Splat himself does,
   and only while he is resting. */
.pg-hero-home{position:relative}
.splat-stage{position:absolute;inset:0;pointer-events:none;z-index:4}
.splat-actor,.splat-thing{position:absolute;left:0;top:0;display:block;will-change:transform}
.splat-actor{display:none;cursor:default;pointer-events:none}
.splat-actor.here{display:block}
.splat-actor.resting{pointer-events:auto;cursor:pointer}
.splat-actor.resting .splat-body{animation:splat-bob 1.8s steps(2,jump-none) infinite}
.splat-actor .splat-body{animation:none}
.splat-thing svg{display:block}
.splat-thing.rising{animation:splat-rise .4s steps(5,jump-none) 1 both}
@keyframes splat-rise{from{clip-path:inset(100% 0 0 0)}to{clip-path:inset(0)}}
.splat-thing.going{animation:splat-go .24s steps(3,jump-none) 1 both}
@keyframes splat-go{to{opacity:0}}
.splat-stars{position:absolute;left:50%;top:0;transform:translate(-50%,-20%);visibility:hidden}
.splat-stars svg{display:block}
.splat-stars.on{visibility:visible;animation:splat-dizzy .5s steps(2,jump-none) infinite}
@keyframes splat-dizzy{50%{transform:translate(-50%,-20%) translateX(4px)}}
/* With motion turned off he just stands beside the main button. */
.pg-hero-home .pg-actions{align-items:flex-end}
.pg-hero-home .pg-actions .splat{margin-left:6px}

/* 2 to 5. Over a section's heading. */
.splat-scene{margin:0 0 14px;line-height:0}
.splat-scene-close{margin-bottom:18px}

/* 7. Asleep on the footer's top line, on every page. The scene stands on
   the line; at Christmas it has a tree and two presents, and lights hang
   under the line the whole width of the footer. */
.site-footer{position:relative}
.splat-footer-scene{position:absolute;right:max(16px,5vw);top:1px;transform:translateY(-100%);display:flex;align-items:flex-end;gap:6px;line-height:0;pointer-events:none}
.splat-footer-scene .splat{pointer-events:auto}
.splat-deco{display:block;flex:none}
.splat-deco svg{display:block}
.splat-on-footer{flex-direction:column;align-items:flex-end;gap:2px}
.splat-on-footer .splat-prop{margin:0 4px 0 0;animation:splat-zz 2.4s steps(3,jump-none) infinite}
.splat-lights{position:absolute;left:0;right:0;top:3px;height:5px;pointer-events:none;
  background:repeating-linear-gradient(90deg,#ff3b30 0 5px,transparent 5px 26px,#ff9500 26px 31px,transparent 31px 52px,#34b85a 52px 57px,transparent 57px 78px,#4da3ff 78px 83px,transparent 83px 104px);
  animation:splat-twinkle 1.6s steps(2,jump-none) infinite}
@keyframes splat-twinkle{50%{opacity:.45}}
@keyframes splat-zz{0%{opacity:0;transform:translate(-4px,4px)}35%{opacity:1}100%{opacity:0;transform:translate(4px,-6px)}}

/* 8. Christmas by the logo, on every page (splat.js sizes and picks them
   to fit the room beside the name). They stand on the same line as the
   bottom of the mark; the snowflakes hang near the top. */
.site-nav.has-xmas .wordmark{margin-right:0}
.xmas-head{display:flex;align-items:flex-end;gap:var(--cell,2px);margin-right:auto;align-self:center;flex:none;line-height:0;pointer-events:none}
.xmas-piece{display:block;flex:none}
.xmas-piece[hidden]{display:none}
.xmas-piece svg{display:block}
.xmas-flake{align-self:flex-start;margin-top:calc(var(--cell,2px) * 1)}
.xmas-flake2{align-self:flex-start;margin-top:calc(var(--cell,2px) * 5)}
/* And a Santa hat on the logo's top-left corner (splat.js places it). */
.wordmark.has-hat{position:relative}
.xmas-hat{position:absolute;left:0;top:0;line-height:0;pointer-events:none;z-index:1}
.xmas-hat svg{display:block}

@media (prefers-reduced-motion:reduce){
  .splat-body,.splat-prop,.splat-on-footer .splat-prop,.splat-lights{animation:none!important}
}
@media print{.splat,.splat-scene,.splat-footer-scene,.splat-lights,.xmas-head,.xmas-hat{display:none!important}}
