/* https://theme-toggle.rdsx.dev/ */
:root {
  --expo-in: linear(
    0 0%,
    0.0085 31.26%,
    0.0167 40.94%,
    0.0289 48.86%,
    0.0471 55.92%,
    0.0717 61.99%,
    0.1038 67.32%,
    0.1443 72.07%,
    0.1989 76.7%,
    0.2659 80.89%,
    0.3465 84.71%,
    0.4419 88.22%,
    0.554 91.48%,
    0.6835 94.51%,
    0.8316 97.34%,
    1 100%
  );
  --expo-out: linear(
    0 0%,
    0.1684 2.66%,
    0.3165 5.49%,
    0.446 8.52%,
    0.5581 11.78%,
    0.6535 15.29%,
    0.7341 19.11%,
    0.8011 23.3%,
    0.8557 27.93%,
    0.8962 32.68%,
    0.9283 38.01%,
    0.9529 44.08%,
    0.9711 51.14%,
    0.9833 59.06%,
    0.9915 68.74%,
    1 100%
  );
}

::view-transition-group(root) {
  animation-timing-function: var(--expo-out);
}

::view-transition-new(root) {
  mask: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 40"><defs><filter id="blur"><feGaussianBlur stdDeviation="2"/></filter></defs><circle cx="0" cy="0" r="18" fill="white" filter="url(%23blur)"/></svg>')
    top left / 0 no-repeat;
  mask-origin: content-box;
  animation: scale 1s;
  transform-origin: top left;
}

::view-transition-old(root),
.dark::view-transition-old(root) {
  animation: scale 1s;
  transform-origin: top left;
  z-index: -1;
}

@keyframes scale {
  to {
    mask-size: 350vmax;
  }
}
