/* One Million Screenshots. Hand-written, no build step. */

:root {
  --ink: #1f2937;
  --text: #6b7280;
  --line: #e5e7eb;
  --wash: #f3f4f6;
  --dark: #111827;
  --accent: #4f46e5; /* dark enough for small text on white (6.3:1) */
  --radius: 0.75rem;
  --shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  color-scheme: light;
}

/* The "@view-transition" rule that turns on page-to-page transitions is
   written into each page's head (see layout.js), not here. Chromium drops
   the transition when the rule arrives in a stylesheet over the network. */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font: 16px/1.5 Inter, ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  -webkit-text-size-adjust: 100%;
  color: var(--text);
  background: #fff;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

h1,
h2,
h3 {
  color: var(--ink);
  line-height: 1.25;
  text-wrap: balance;
}
h1 {
  font-size: 1.5rem;
}
h3,
.sub {
  font-size: 1rem;
  margin: 2rem 0 0.75rem;
}
a {
  color: var(--accent);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
strong,
b {
  color: var(--ink);
}
img {
  max-width: 100%;
  height: auto;
}
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
kbd {
  font: 0.6875rem ui-monospace, monospace;
  background: var(--wash);
  border: 1px solid var(--line);
  border-radius: 0.25rem;
  padding: 0 0.25rem;
  color: #4b5563;
}
/* Shown only when reached with the Tab key. */
.skip {
  position: absolute;
  z-index: 20;
  top: 6rem;
  left: 1rem;
  padding: 0.5rem 0.75rem;
  background: #fff;
  border-radius: 0.5rem;
  box-shadow: var(--shadow);
}
.skip:not(:focus) {
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
}
.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.icon {
  width: 1rem;
  height: 1rem;
  flex: none;
}
/* Things that only work with JavaScript stay hidden until it runs. */
/* Without this, any display rule of ours would un-hide a hidden element. */
[hidden] {
  display: none !important;
}
html:not(.js) .js-only {
  display: none !important;
}

/* Header and footer bars */

.bar {
  z-index: 10;
  width: min(100% - 2rem, 48rem);
  margin-inline: auto;
  background: #fff;
  border: 1px solid var(--wash);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  padding: 0 1rem;
  view-transition-name: var(--vt);
}
.bar.top {
  --vt: top-bar;
  position: fixed;
  top: 1rem;
  left: 0;
  right: 0;
  min-height: 4rem;
}
.bar.bottom {
  --vt: bottom-bar;
  margin-block: auto 1rem;
  min-height: 2rem;
  padding-block: 0.5rem;
  flex-wrap: wrap;
  font-size: 0.75rem;
  line-height: 1;
}
.map .bar.bottom {
  position: fixed;
  bottom: 1rem;
  left: 0;
  right: 0;
}
.bar p {
  margin: 0;
}
.bar p a {
  text-decoration: underline;
}
/* Big enough to tap: at least 24px tall. */
.bar ul :is(a, button) {
  display: inline-block;
  padding-block: 0.375rem;
}
.bar ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 0.75rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.logo {
  font-size: 1.25rem;
  line-height: 1;
  font-weight: 300;
  color: var(--ink);
}
.logo b {
  font-weight: 700;
}
.logo:hover {
  text-decoration: none;
}
.brand p {
  font-size: 0.75rem;
  margin-top: 0.25rem;
}
.actions {
  display: flex;
  gap: 0.5rem;
}
.link {
  font: inherit;
  color: var(--accent);
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  height: 2rem;
  padding: 0 1rem;
  border: 0;
  border-radius: 0.5rem;
  background: var(--dark);
  color: #fff;
  font-family: inherit;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.15s, box-shadow 0.15s;
}
.button:hover {
  background: #374151;
  text-decoration: none;
  box-shadow: 0 1px 3px rgb(0 0 0 / 0.2);
}
.button .icon {
  color: #d1d5db;
}
.button.light {
  background: var(--wash);
  border: 1px solid var(--line);
  color: var(--text);
  font-weight: 400;
}
.button.light:hover {
  background: #fff;
}
.button.light .icon {
  color: var(--ink);
}

.search {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  height: 2rem;
  padding: 0 0.5rem;
  background: var(--wash);
  border: 1px solid var(--line);
  border-radius: 0.5rem;
  color: var(--ink);
}
.search:focus-within {
  background: #fff;
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.search input {
  width: 9rem;
  border: 0;
  background: none;
  font: inherit;
  font-size: 0.75rem;
  color: var(--ink);
  outline: none;
}
.results {
  position: absolute;
  top: calc(100% + 0.5rem);
  left: 0;
  width: max(100%, 18rem);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 0.5rem;
  box-shadow: var(--shadow);
  padding: 0.5rem;
  font-size: 0.875rem;
}
.hits {
  list-style: none;
  margin: 0;
  padding: 0;
}
.hits a {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.5rem;
  border-radius: 0.375rem;
  color: var(--text);
}
.hits a:hover,
.hits a:focus {
  background: var(--wash);
  text-decoration: none;
}
.hits span {
  font-family: ui-monospace, monospace;
  font-size: 0.75rem;
}

@media (max-width: 40rem) {
  .logo {
    font-size: 1rem;
  }
  .brand p,
  .actions .button span,
  .search kbd {
    display: none !important;
  }
  .actions .button {
    padding: 0 0.625rem;
  }
  .bar.top {
    padding-inline: 0.75rem;
    gap: 0.5rem;
  }
  .search input {
    width: 4.5rem;
  }
  .map .bar.bottom {
    margin-right: 4.5rem;
    width: auto;
    left: 1rem;
  }
}

/* The map
 *
 * The page holds every tile at its true position in the world, one box
 * (.level) per zoom level. Three numbers on .stage say what to look at:
 *
 *   --x, --y   the cell in the middle of the screen
 *   --z        the zoom (a cell is 2^(z+2) pixels wide)
 *
 * and --ox, --oy nudge the picture by a number of pixels, for dragging.
 * Everything below follows from those five, so moving the map is only ever
 * a matter of changing them, and animating it is an ordinary CSS transition
 * or animation. They are registered as numbers so that they can animate, and
 * they do not inherit, so a change restyles one element, not every tile.
 */

@property --x {
  syntax: '<number>';
  inherits: false;
  initial-value: 0;
}
@property --y {
  syntax: '<number>';
  inherits: false;
  initial-value: 0;
}
@property --z {
  syntax: '<number>';
  inherits: false;
  initial-value: 0;
}
@property --ox {
  syntax: '<number>';
  inherits: false;
  initial-value: 0;
}
@property --oy {
  syntax: '<number>';
  inherits: false;
  initial-value: 0;
}

.map {
  overflow: hidden;
}
.viewport {
  position: fixed;
  inset: 0;
  overflow: hidden;
  overscroll-behavior: none;
}
/* The stage only marks the middle of the screen and holds the numbers. */
.stage {
  position: absolute;
  left: 50%;
  top: 50%;
  isolation: isolate;
}
/* Each level takes the numbers from the stage and places itself. Its tiles
   are in its own pixels, where a cell is 2^(k+2) wide, so it is drawn at
   2^(z-k) times its size, shifted so the middle cell lands mid-screen.
   Sharper levels sit on top. */
.level {
  --x: inherit;
  --y: inherit;
  --z: inherit;
  --ox: inherit;
  --oy: inherit;
  --cell: pow(2, var(--z) + 2);
  position: absolute;
  left: 0;
  top: 0;
  z-index: calc(var(--k) + 3);
  transform-origin: 0 0;
  transform: translate(calc((var(--ox) - (var(--x) + 0.5) * var(--cell)) * 1px), calc((var(--oy) - (var(--y) + 0.5) * var(--cell)) * 1px))
    scale(pow(2, var(--z) - var(--k)));
}
.level > * {
  position: absolute;
}
.level img {
  display: block;
  width: 128px;
  height: 128px;
  max-width: none;
  user-select: none;
  -webkit-user-drag: none;
}
.level > a:not(.cell):hover img {
  filter: brightness(0.8);
}

/* Arriving from somewhere else on the map: the server writes the route as
   an "arrive" animation of --x, --y and --z, and how long it takes. */
.stage.arrive {
  animation: arrive var(--ms) linear var(--wait) backwards;
}
/* Going from one map page to the next, the browser shows a picture of the
   old page until the new one is ready (a view transition). The new page
   first draws before its tiles have loaded, so the usual cross-fade blinks
   to a blank map. Instead: no fade. The old map stays underneath for a
   moment (--wait) and the new one, which is see-through until its tiles
   arrive, is drawn over it. The arrival waits as long, so both show the
   same picture while that happens. */
:root {
  --wait: 0.25s;
}
body.map {
  background: var(--wash);
}
.viewport {
  view-transition-name: map;
}
/* The far-away backdrop loads at once and covers everything, which would
   hide the old map behind a blur. So on arriving from another place on the
   map it stays out of sight for that moment. On any other load it shows
   straight away: it is the first picture of the map a visitor gets. */
.stage.arrive .level.far {
  animation: late var(--wait) step-end backwards;
}
@keyframes late {
  from {
    visibility: hidden;
  }
}

/* The server sends enough tiles for a large screen and marks the ones only
   a wider (.x3: over 3 × 256px) or taller (.y2) screen can show. Hidden
   here, a lazy image is never downloaded. */
@media (max-width: 256px) {
  .level .x1 {
    display: none;
  }
}
@media (max-width: 512px) {
  .level .x2 {
    display: none;
  }
}
@media (max-width: 768px) {
  .level .x3 {
    display: none;
  }
}
@media (max-width: 1024px) {
  .level .x4 {
    display: none;
  }
}
@media (max-width: 1280px) {
  .level .x5 {
    display: none;
  }
}
@media (max-width: 1536px) {
  .level .x6 {
    display: none;
  }
}
@media (max-width: 1792px) {
  .level .x7 {
    display: none;
  }
}
@media (max-width: 2048px) {
  .level .x8 {
    display: none;
  }
}
@media (max-width: 2304px) {
  .level .x9 {
    display: none;
  }
}
@media (max-width: 2560px) {
  .level .x10 {
    display: none;
  }
}
@media (max-height: 256px) {
  .level .y1 {
    display: none;
  }
}
@media (max-height: 512px) {
  .level .y2 {
    display: none;
  }
}
@media (max-height: 768px) {
  .level .y3 {
    display: none;
  }
}
@media (max-height: 1024px) {
  .level .y4 {
    display: none;
  }
}
@media (max-height: 1280px) {
  .level .y5 {
    display: none;
  }
}
@media (max-height: 1536px) {
  .level .y6 {
    display: none;
  }
}
::view-transition-group(map) {
  animation-duration: var(--wait);
}
::view-transition-old(map),
::view-transition-new(map) {
  animation: none;
  mix-blend-mode: normal;
}

/* With JavaScript, enhance.js changes the numbers as you drag, scroll and
   pinch; these transitions do the moving. */
.js .viewport {
  touch-action: none;
  cursor: grab;
}
.js .viewport.dragging {
  cursor: grabbing;
}
.js .stage {
  transition: --ox var(--dur, 0.25s) cubic-bezier(0.1, 0.7, 0.3, 1), --oy var(--dur, 0.25s) cubic-bezier(0.1, 0.7, 0.3, 1),
    --z var(--dur, 0.25s) cubic-bezier(0.1, 0.7, 0.3, 1);
}
.js .stage.still {
  transition: none;
}
.js .stage.held {
  animation: none;
}
/* Browsers without pow() can't work the placement out, so they use two
   numbers the server worked out for them (--c, the width of a cell, and
   --s, each level's scale) and get a map that stays still. */
@supports not (scale: pow(2, 1)) {
  .level {
    transform: translate(calc((var(--x) + 0.5) * var(--c) * -1px), calc((var(--y) + 0.5) * var(--c) * -1px)) scale(var(--s));
  }
  .stage.arrive {
    animation: none;
  }
  .js .viewport {
    touch-action: auto;
    cursor: auto;
  }
}
.controls a.off {
  color: #d1d5db;
  pointer-events: none;
}
.cell {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  text-align: center;
  transition: background 0.15s;
}
.cell span {
  opacity: 0;
  padding: 0.25rem 0.5rem;
  overflow-wrap: anywhere;
  transition: opacity 0.15s;
}
.cell:hover,
.cell:focus-visible {
  background: rgb(0 0 0 / 0.7);
  outline: 2px solid var(--accent);
  outline-offset: -2px;
  text-decoration: none;
}
.cell:hover span,
.cell:focus-visible span {
  opacity: 1;
}
.cell.here {
  outline: 3px solid var(--accent);
  outline-offset: -3px;
  align-items: flex-start;
  animation: pulse 1.2s ease-out 2;
}
.cell.here span {
  opacity: 1;
  background: var(--accent);
  border-radius: 0 0 0.375rem 0.375rem;
}
@keyframes pulse {
  from {
    box-shadow: 0 0 0 0 rgb(99 102 241 / 0.7);
  }
  to {
    box-shadow: 0 0 0 2rem rgb(99 102 241 / 0);
  }
}

.controls {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 10;
  display: grid;
  gap: 0.5rem;
  justify-items: end;
}
.controls a,
.controls span {
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  background: #fff;
  color: var(--ink);
  font-size: 1.125rem;
  line-height: 1;
  border: 1px solid var(--line);
}
.controls span {
  color: #d1d5db;
}
.controls a:hover {
  background: var(--wash);
  text-decoration: none;
}
.pad {
  display: grid;
  grid-template: 'a up b' 'left c right' 'd down e' / 2rem 2rem 2rem;
  border-radius: 0.5rem;
  box-shadow: var(--shadow);
}
.pad a:nth-child(1) {
  grid-area: up;
  border-radius: 0.5rem 0.5rem 0 0;
}
.pad a:nth-child(2) {
  grid-area: left;
  border-radius: 0.5rem 0 0 0.5rem;
}
.pad a:nth-child(3) {
  grid-area: right;
  border-radius: 0 0.5rem 0.5rem 0;
}
.pad a:nth-child(4) {
  grid-area: down;
  border-radius: 0 0 0.5rem 0.5rem;
}
.zoom {
  display: grid;
  box-shadow: var(--shadow);
  border-radius: 0.5rem;
  overflow: hidden;
}
/* On a phone you drag the map, so the arrows go. Without JavaScript there
   is no dragging, so they stay. */
@media (max-width: 40rem) {
  .js .pad {
    display: none;
  }
}
.toast {
  position: fixed;
  left: 50%;
  bottom: 5rem;
  translate: -50%;
  z-index: 10;
  margin: 0;
  padding: 0.5rem 1rem;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  font-size: 0.875rem;
  animation: rise 0.3s ease-out;
}
@keyframes rise {
  from {
    opacity: 0;
    translate: -50% 1rem;
  }
}

/* The About popover */

.modal {
  width: min(100% - 2rem, 48rem);
  max-height: 90vh;
  overflow-y: auto;
  padding: clamp(2rem, 6vw, 4rem);
  border: 1px solid var(--wash);
  border-radius: var(--radius);
  box-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.25);
  font-size: 0.875rem;
  color: var(--text);
  opacity: 0;
  translate: 0 1rem;
  transition: opacity 0.2s, translate 0.2s, display 0.2s allow-discrete, overlay 0.2s allow-discrete;
}
.modal:popover-open {
  opacity: 1;
  translate: 0;
}
@starting-style {
  .modal:popover-open {
    opacity: 0;
    translate: 0 1rem;
  }
}
.modal::backdrop {
  background: rgb(0 0 0 / 0.5);
}
.modal h2 {
  margin-top: 0;
  font-size: 1.5rem;
}
@supports not selector(:popover-open) {
  [popover] {
    display: none;
  }
}
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr));
  gap: 1rem;
  margin-block: 3rem;
}
.features figure {
  margin: 0;
}
.features figcaption {
  color: var(--ink);
  font-weight: 700;
  text-align: center;
  margin-bottom: 0.5rem;
}
.features img {
  border: 4px solid #fff;
  border-radius: 0.5rem;
  box-shadow: var(--shadow);
}

/* Ordinary pages */

.content {
  width: min(100% - 2rem, 48rem);
  margin-inline: auto;
  padding: 8rem 0 4rem;
}
.row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
}
.notice {
  display: flex;
  gap: 0.5rem;
  background: #fef3c7;
  color: #b45309;
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
}
.notice .icon {
  width: 1.25rem;
  height: 1.25rem;
  color: #d97706;
}
.snippet,
.code pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font: 0.75rem/1.6 ui-monospace, SFMono-Regular, Menlo, monospace;
}
.snippet {
  background: var(--dark);
  color: #e2e8f0;
  border-radius: 0.5rem;
  padding: 0.75rem;
  box-shadow: var(--shadow);
}
.promo {
  border-radius: 0.5rem;
  box-shadow: var(--shadow);
  margin-top: 2rem;
}
.faq {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
  gap: 3rem;
  margin-block: 4rem;
}
.faq dt {
  font-weight: 600;
  color: var(--ink);
}
.faq dd {
  margin: 0.5rem 0 0;
}
.missing {
  text-align: center;
  display: grid;
  justify-items: center;
}
.code-404 {
  font: 6rem/1 ui-monospace, monospace;
  color: #c7d2fe;
  margin: 2rem 0;
}

.notify {
  margin-top: 4rem;
}
.notify > p {
  font-size: 0.875rem;
  max-width: 32rem;
}
.fields {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 0.5rem;
}
.fields label {
  flex: 1 1 12rem;
  font-size: 0.875rem;
}
.fields input {
  display: block;
  width: 100%;
  height: 2rem;
  margin-top: 0.25rem;
  padding: 0 1rem;
  border: 1px solid #d1d5db;
  border-radius: 0.5rem;
  font: inherit;
  color: #000;
}

/* Site pages */

.crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  font-family: ui-monospace, monospace;
}
.crumbs a {
  color: var(--text);
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}
.crumbs a:first-child .icon {
  rotate: 180deg;
  width: 1.25rem;
  height: 1.25rem;
}
.crumbs b {
  color: var(--accent);
  font-weight: 400;
}
.intro {
  display: flex;
  gap: 2rem;
  margin-bottom: 2rem;
}
.intro h1 {
  margin: 0.5rem 0 1rem;
}
.thumb {
  flex: none;
  width: 16rem;
  box-shadow: var(--shadow);
  align-self: start;
}
@media (max-width: 40rem) {
  .thumb {
    display: none;
  }
}
.shot {
  display: block;
  overflow: hidden;
  aspect-ratio: 1;
  background: var(--wash);
}
.shot img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: left top;
}
.sensitive .shot img {
  filter: blur(1rem) brightness(0.6);
}
.sensitive:has(#show-sensitive:checked) .shot img {
  filter: none;
}

.tabs {
  display: flex;
  gap: 1.5rem;
  overflow-x: auto;
  border-bottom: 1px solid var(--line);
  margin: 2rem 0;
}
.tabs a {
  color: var(--text);
  white-space: nowrap;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid transparent;
  margin-bottom: -1px;
}
.tabs a:hover {
  color: var(--ink);
  text-decoration: none;
}
.tabs [aria-current] {
  color: var(--accent);
  border-color: var(--accent);
}

.menu {
  position: relative;
  font-size: 0.875rem;
}
.menu summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 14rem;
  height: 2rem;
  padding: 0 0.75rem 0 1rem;
  border: 1px solid var(--line);
  border-radius: 0.5rem;
  cursor: pointer;
  list-style: none;
}
.menu summary::-webkit-details-marker {
  display: none;
}
.menu ul {
  position: absolute;
  z-index: 5;
  width: 14rem;
  margin: 0.5rem 0 0;
  padding: 0.5rem;
  list-style: none;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 0.5rem;
  box-shadow: var(--shadow);
}
.menu li a {
  display: block;
  padding: 0.25rem 0.5rem;
  border-radius: 0.375rem;
  color: var(--text);
}
.menu li a:hover {
  background: var(--wash);
  text-decoration: none;
}

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 2rem;
}
@media (max-width: 40rem) {
  .grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
.grid > * {
  min-width: 0;
}
.grid .shot {
  box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
}
.label {
  display: block;
  margin-top: 0.5rem;
  font: 0.75rem ui-monospace, monospace;
  color: var(--text);
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.preview:hover {
  text-decoration: none;
}
.nine {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  transition: scale 0.2s, gap 0.2s;
}
.preview:hover .nine {
  scale: 1.06;
  gap: 0.25rem;
}
.empty {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  background: #f9fafb;
  color: #d1d5db;
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
}

.history {
  display: grid;
  grid-template-columns: 1fr 13rem;
  gap: 4rem;
  align-items: start;
}
.history figure {
  margin: 0;
}
.history figcaption {
  margin-top: 1rem;
  font-size: 0.875rem;
}
.compare {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 1rem;
}
/* With JavaScript the two months are stacked and a slider wipes between them. */
.compare.slider {
  position: relative;
  display: block;
  --pos: 50%;
}
.compare.slider figure + figure {
  position: absolute;
  inset: 0;
}
.compare.slider figure + figure .shot {
  clip-path: inset(0 0 0 var(--pos));
}
.compare.slider figure + figure figcaption {
  text-align: right;
}
.compare.slider::after {
  content: '';
  position: absolute;
  top: 0;
  left: var(--pos);
  width: 2px;
  bottom: 2.5rem;
  background: #fff;
  box-shadow: 0 0 4px rgb(0 0 0 / 0.5);
  pointer-events: none;
}
.compare.slider input {
  position: absolute;
  inset: 0 0 2.5rem;
  width: 100%;
  margin: 0;
  opacity: 0;
  cursor: ew-resize;
}
.history aside h2 {
  margin-top: 0;
  font-size: 0.875rem;
}
.history ol {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1rem;
  max-height: 40rem;
  overflow-y: auto;
}
.history li a {
  display: grid;
  grid-template-columns: 5rem 8rem;
  align-items: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--ink);
}
.history li a:hover,
.history li [aria-current] {
  color: var(--accent);
  text-decoration: none;
}
.history li .shot {
  box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
  transition: scale 0.15s;
}
.history li a:hover .shot {
  scale: 1.03;
}
@media (max-width: 40rem) {
  .history {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .history ol {
    grid-template-columns: repeat(2, 1fr);
    max-height: none;
  }
  .history li a {
    grid-template-columns: 1fr;
  }
}

.code {
  display: flex;
  flex-wrap: wrap;
  background: var(--dark);
  color: #e5e7eb;
  border-radius: 0.5rem;
  box-shadow: var(--shadow);
  overflow: hidden;
  font-size: 0.75rem;
}
.code > input {
  position: absolute;
  opacity: 0;
}
.code > label {
  padding: 0.5rem 0.75rem;
  color: #9ca3af;
  border-right: 1px solid #374151;
  border-bottom: 1px solid #374151;
  cursor: pointer;
}
.code > label:hover,
.code > input:checked + label {
  color: #fff;
  border-bottom-color: #fff;
}
.code > input:focus-visible + label {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}
.code .panel {
  display: none;
  order: 1;
  width: 100%;
  position: relative;
  border-top: 1px solid #374151;
  margin-top: -1px;
}
.code > input:checked + label + .panel {
  display: block;
}
.code pre {
  margin: 0;
  padding: 0.75rem;
  height: 24rem;
  overflow: auto;
}
.code button {
  position: absolute;
  top: 0.5rem;
  right: 1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.25rem 0.5rem;
  background: #1f2937;
  color: #e5e7eb;
  border: 1px solid #374151;
  border-radius: 0.375rem;
  font: inherit;
  cursor: pointer;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) {
    animation: none !important;
  }
}
