:root {
  font-size: 20px;
  --menu-button-offset: 2rem;
  --content-max-width: 1200px;
  --color-border: color-mix(in hsl, var(--color-text), transparent);
  --color-affirm: #0a7c0a;
  --image-background: fixed radial-gradient(ellipse 50% 30% at 50% 100%, color-mix(in hsl, var(--color-background) 90%, #000), transparent), fixed radial-gradient(ellipse at top left, var(--color-background), color-mix(in hsl, var(--color-background) 94%, #000));
}

@media (prefers-color-scheme: light) {
  :root {
    --color-background: hsl(16 58.77% 95.23%);
    --color-text: #303030;
    --menu-background: rgb(254 254 254 / 40%);
    --logo-url: url(../img/snaps-logo.svg);
    --header-brightness: 110%;
    --color-menu-background: #000;
    --color-menu-text: #fff;
    --header-background-color: rgba(255, 255, 255, 0.4);
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    --color-background: hsl(255 5% 15.69%);
    --color-text: #c4c4c4;
    --menu-background: rgb(44 40 40 / 40%);
    --logo-url: url(../img/snaps-logo-white.svg);
    --header-brightness: 120%;
    --color-menu-background: #000;
    --color-menu-text: #fff;
    --header-background-color: rgba(0, 0, 0, 0.4);
  }
}

@font-face {
  font-family: "NunitoSans";
  src: url(fonts/NunitoSans-Variable.ttf) format("truetype");
  font-display: swap;
  font-weight: 300 700;
}

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

html {
  width: 100%;
  min-height: 100dvh;
  font-size: 18px;
  text-rendering: geometricPrecision;
  scroll-behavior: smooth;
}

body {
  font-family: "NunitoSans", sans-serif;
  font-size: 100%;
  margin: 0;
  padding: 0;
  min-height: 100%;
  width: 100%;
  background: #000;
}

#splash {
  /* background:#000; */
  height: 100%;
  width: 100%;
  position: fixed;
  left: 0;
  top: 0;
  opacity: 1;
  transform: scale(1);
  z-index: 1000;
  background: #000;
  --logo-duration: 3.5s;
  --cover-duration: 1.5s;
  --easing: ease-in-out;
  perspective: 1px;
  animation: 2s splashZoom ease-in-out forwards;
  transition: transform 0.3s, opacity 0.3s;

  &.fadeout {
    transform: scale(1.2);
    opacity: 0;
  }
}

#splash.cover-loaded {
  transition: opacity 0.5s, visibility 0.5s;
}

#splash > div.cover {
  position: absolute;
  z-index: 10;
  width: 100%;
  max-width: 500px;
  height: 100%; /*70%;*/
  left: 50%;
  background: var(--cover-image);
  transform: translate3d(0, -500px, -500px) rotate3d(0, 1, 0, -10deg) translateX(-50%);
  animation: calc(var(--cover-duration) - 0.3s) coverZoom ease-out forwards;
  animation-delay: calc(var(--logo-duration) - 1s);
  opacity: 0;
  --transform: scale(1.1);
  --access-top: calc(100dvh - 15rem);

  &::before {
    --transform: scale(1.1);
  }
  &::after {
    --transform: scale(1.2);
  }
  &::before,
  &::after {
    content: "";
    position: absolute;
    inset: 0;
    background: inherit;
    filter: blur(10px);
    opacity: 0.5;
    transform: var(--transform);
    animation: calc(var(--cover-duration) - 0.3s) coverBlurZoom ease-out forwards;
    animation-delay: calc(var(--logo-duration) - 1s);
  }

  > div.logo {
    width: 100%;
    left: 0;
    position: absolute;
    z-index: 2;
    top: var(--cover-logo-y, 50%); /* 70dvh */
    height: 30dvh;
    opacity: 0;
    transform: translateY(-50%) scale(0.7);
    --event-logo-shadow-color: color-mix(in oklab, var(--event-color-primary), transparent 40%);
    filter: var(--cover-logo-shadow, "");
    animation: 4s boomIn ease-out forwards;
    animation-delay: calc(var(--logo-duration) + var(--cover-duration) - 1.5s);
    display: flex;
    align-items: center;
    justify-content: center;

    > svg {
      width: 90%;
    }
  }

  > div.access {
    left: 50%;
    position: absolute;
    top: var(--cover-logo-y); /* (100% - 3.5rem); */ /* var(--access-top); */
    transform: translate(-50%, 4.5rem);
    font-size: 1rem;
    white-space: nowrap;
    /* filter: drop-shadow(0 0 1px #fff) drop-shadow(0 0 1px #fff) drop-shadow(0 0 1px #fff); */
    color: var(--event-color-primary);
    font-weight: 400;
    font-weight: bold;
    z-index: 5;
    opacity: 0;
    transition: opacity 1s;
    transition-delay: 1s;
  }
}

#splash.cover-in {
  > div.cover {
    > div.access {
      opacity: 1;
    }
  }
}

body.preview #splash > div.cover {
  --access-top: calc(var(--cover-logo-y) + 32vw);
}

@keyframes boomIn {
  0% {
    transform: translateY(-50%) scale(0.85);
    opacity: 0;
  }
  50% {
    opacity: 1;
  }
  100% {
    transform: translateY(-50%) scale(1);
    opacity: 1;
  }
}

#splash > div.flare {
  position: absolute;
  top: 50%;
  left: 50%;
  --ypos: -48%;
  transform: translate(-50%, var(--ypos)) scale(0.2, 0.1);
  width: 100%;
  max-width: 1000px;
  height: 150px;
  z-index: 20;

  animation: flare 3s linear forwards;
  transition: opacity 1s;

  background: 50% / 100% no-repeat radial-gradient(20% 27% at 50%, hsla(199, 22%, 70%, 0.2), hsla(199, 52%, 45%, 0)), 50% / 90% no-repeat radial-gradient(closest-side, hsl(199, 78%, 25%), rgba(0, 0, 0, 0));

  &::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    transform: translate(-50%, -50%);
    height: 10px;
    background: 50% / 100% no-repeat radial-gradient(closest-side, hsl(210, 96%, 48%), rgba(0, 0, 0, 0));
    mix-blend-mode: screen;
  }

  &::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    transform: translate(-50%, -50%);
    height: 5px;
    background: 50% / 80% no-repeat radial-gradient(closest-side, #548080, rgba(0, 0, 0, 0));
    mix-blend-mode: color-dodge;
  }
}

#splash > div.app {
  width: 100%;
  max-width: 500px;
  height: 100%;
  left: 50%;
  transform: translateX(-50%);
  position: absolute;
  z-index: 30;
  /* background: #000; */
  transition: background 0.5s, visibility 0.5s;

  > div.logo {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 100%;
    aspect-ratio: 1.9115226337;
    opacity: var(--event-logo-opacity, 1);
    transform: translate(-50%, -50%) scale(1);
    --bounce-back-fast: cubic-bezier(0.34, 1.56, 0.64, 1);
    --bounce-back-slow: cubic-bezier(0.7, 0.9, 0.36, 1.15);
    --bounce-curved: cubic-bezier(0.29, 0, 0.12, 1.15);
    --base-duration: 0.3s;
    --base-offset: 0.5s;
    /* animation: fadeOut 1s ease-in forwards;
        animation-delay: 3s; */

    svg {
      overflow: visible;
      position: absolute;
      width: 50%;
      height: 100%;
      left: 50%;
      top: 50%;
      transform: translate(-50%, -50%);
      max-width: 130px;
      max-height: 483px;
      animation: bounceDown 1s ease-in forwards;
      animation-delay: 3s;
      opacity: 1;

      > g.photos {
        clip-path: polygon(0 0, 50% 0, 50% 58.6%, 100% 58.6%, 100% 100%, 0 100%);
      }

      g[class^="photo-"] {
        opacity: 0;
        /* Center of SVG (width/2, height/2) */
        --easing: var(--bounce-curved);
        transform-origin: 462.5px 241.5px;
        animation: rotateIn calc(var(--base-duration) * 2.8) var(--easing) forwards;
        --animation-delay: calc(var(--base-offset) + calc(var(--base-duration) * 2));

        > path {
          fill: #fff;
        }

        &.photo-01 {
          animation-delay: var(--animation-delay);
        }

        &.photo-02 {
          animation-delay: calc(0.1s + var(--animation-delay));
        }

        &.photo-03 {
          animation-delay: calc(0.2s + var(--animation-delay));
        }

        &.photo-04 {
          animation-delay: calc(0.3s + var(--animation-delay));
        }
      }

      .text {
        stroke: #fff;
        stroke-dasharray: calc(var(--dash-array) * 1px);
        stroke-dashoffset: var(--dashoffset-start);
        --dashoffset-start: calc(var(--dash-array) * 1px);
        --dashoffset-end: 0;
        --draw-speed: 445;
        --animation-duration: calc(var(--dash-array) / var(--draw-speed) * var(--base-duration));
        --easing: linear;
        animation: drawText var(--animation-duration) var(--easing) forwards;
      }

      path[class*="text-"] {
        /* S cap */
        &.text-01 {
          --dash-array: 520;
          --dashoffset-start: calc(var(--dash-array) * 1px);
          --dashoffset-end: calc(2px * var(--dash-array));
          animation-delay: calc(var(--base-offset) + calc(var(--base-duration) * 0.33));
        }

        /* N ascender */
        &.text-02 {
          --dash-array: 130;
          animation-delay: calc(var(--base-offset) + calc(var(--base-duration) * 1.11));
        }

        /* N curve */
        &.text-03 {
          --dash-array: 350;
          animation-delay: calc(var(--base-offset) + calc(var(--base-duration) * 1.35));
        }

        /* A top */
        &.text-04 {
          --dash-array: 350;
          animation-delay: calc(var(--base-offset) + calc(var(--base-duration) * 1.93));
        }

        /* A bottom */
        &.text-05 {
          --dash-array: 200;
          animation-delay: calc(var(--base-offset) + calc(var(--base-duration) * 1.93));
        }

        /* A bottom right */
        &.text-06 {
          --dash-array: 230;
          animation-delay: calc(var(--base-offset) + calc(var(--base-duration) * 2.14));
        }

        /* P bottom */
        &.text-07 {
          --dash-array: 150;
          animation-delay: calc(var(--base-offset) + calc(var(--base-duration) * 2.44));
        }

        /* P curve */
        &.text-08 {
          --dash-array: 210;
          animation-delay: calc(var(--base-offset) + calc(var(--base-duration) * 2.68));
        }

        /* S end */
        &.text-09 {
          --dash-array: 350;
          --draw-speed: 150;
          --animation-duration: calc(var(--dash-array) / var(--draw-speed) * var(--base-duration));
          --easing: cubic-bezier(0, 0, 0.13, 1);
          animation-delay: calc(var(--base-offset) + calc(var(--base-duration) * 3.14));
        }
      }
    }
  }
}

#splash.cover-in > div.flare {
  opacity: 0;
}

@keyframes splashZoom {
  to {
    /* perspective: 10000px; */
  }
}

@keyframes coverZoom {
  0% {
    transform: translate3d(0, -500px, -500px) rotate3d(0, 1, 0, -10deg) translateX(-50%);
    opacity: 0;
  }
  30% {
    opacity: 1;
  }
  100% {
    transform: translate3d(0, 0, 0) rotate3d(0, 1, 0, 0deg) translateX(-50%);
    opacity: 1;
  }
}

@keyframes coverBlurZoom {
  80% {
    filter: blur(10px);
    transform: var(--transform);
  }
  100% {
    filter: blur(0px);
    transform: scale(1);
  }
}

@keyframes bounceDown {
  to {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0);
  }
}

@keyframes fadeOut {
  to {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0);
  }
}

@keyframes drawText {
  0% {
    stroke-dashoffset: var(--dashoffset-start);
  }

  100% {
    stroke-dashoffset: var(--dashoffset-end);
  }
}

@keyframes rotateIn {
  0% {
    transform: rotate(-145deg) scale(0.5);
    opacity: 1;
  }

  50% {
    opacity: 1;
  }

  100% {
    transform: rotate(0deg) scale(1);
    opacity: 1;
  }
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

@keyframes flare {
  0% {
    transform: translate(-50%, var(--ypos)) scale(0.1, 0.1);
    filter: grayscale(1) brightness(5);
  }

  17% {
    transform: translate(-50%, var(--ypos)) scale(1, 0.3);
    filter: grayscale(0.5) brightness(1);
  }

  100% {
    transform: translate(-50%, var(--ypos)) scale(1, 1);
    filter: grayscale(0) brightness(1);
  }
}

.notification {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgb(0 0 0 / 50%);
  color: #fff;
  padding: 1rem;
  border-radius: 0.75rem;
  z-index: 1000001;
  pointer-events: none;
  opacity: 1;
  border: 2px solid #fff;
  transition: opacity 0.23s allow-discrete;
  text-align: center;

  @starting-style {
    opacity: 0;
  }

  &[class*="icon-"] {
    padding-left: 2rem;
    padding-right: 2rem;

    &::before {
      content: "";
      display: block;
      width: 100%;
      height: 4rem;
      background-size: contain;
      background-position: 50%;
      background-repeat: no-repeat;
    }
  }

  &.icon-checkmark::before {
    background-image: url(/img/icons/checkmark-outlined.svg);
    filter: invert();
  }
}

button {
  --horizontal-padding: 0.5rem;
  --vertical-padding: 0.5rem;
  font-size: 1rem;
  color: var(--color-background);
  appearance: none;
  border: 0;
  border-radius: 2rem;
  padding: var(--vertical-padding) var(--horizontal-padding);
  color: var(--color-background);
  cursor: pointer;
  transform: scale(1);
  transition: background 0.23s, transform 0.18s cubic-bezier(0, 0.54, 0.47, 1);
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  -webkit-touch-callout: none;
  -webkit-font-smoothing: subpixel-antialiased;
}

button:focus {
  outline: none;
}

button:active {
  transform: scale(0.95);
}

button span {
  white-space: nowrap;
  position: relative;
}

dialog {
  /* position: fixed; */
  /* top: 0;
    left: 0; */
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(10px);
  margin: 0;
  padding: 0;
  border: 0;
  max-width: unset;
  max-height: unset;
  /* display: flex;
    justify-content: center;
    align-items: center; */
  /* z-index: 1000; */
  transition: opacity 0.3s ease-out;
  transition-behavior: allow-discrete;

  @starting-style {
    opacity: 0;
    backdrop-filter: blur(0px);
  }
}

dialog::backdrop {
  background: transparent;
}

dialog form {
  --color-bg: hsl(0deg 0% 14% / 90%);
  --color-fields-bg: hsl(0 0% 23% / 1);
  color: #fff;
  background: var(--color-bg);
  padding: 1rem;
  border-radius: 8px;
  width: 100%;
  max-width: min(400px, calc(100vw - 2rem));
  max-height: calc(100dvh - 4rem);
  overflow: auto;
  left: 50%;
  top: 50%;
  position: absolute;
  transform: translate(-50%, -50%);
  transition: transform 0.3s ease-out, opacity 0.3s ease-out;
  transition-behavior: allow-discrete;

  @starting-style {
    opacity: 0;
    transform: translate(-50%, -48%);
  }
}

dialog[data-type="info"] form header h2,
dialog[data-type="info"] form header + section {
  text-align: center;
}

dialog input:not([type="checkbox"]):not([type="radio"]),
dialog select,
dialog form button:not(.icon-only) {
  background-color: var(--color-fields-bg);
  color: #fff;
  display: block;
  width: 100%;
  margin-bottom: 1rem;
  padding: 0.5rem;
  border: 0;
  font-size: 1rem;
  appearance: none;
}

dialog input:last-child {
  margin-bottom: 0;
}

label:has(span input[type="checkbox"]) {
  display: flex;
  gap: 1rem;

  > span {
    flex: 1;
  }

  > span:has(> input[type="checkbox"]) {
    background: var(--color-fields-bg);
    border-radius: 1rem;
    display: inline-block;
    flex: 0 0 2rem;
    height: 1.2rem;
    position: relative;
    outline: 2px solid transparent;
    transition: outline 0.23s;

    /* &:has(input:checked) {
            background: color-mix(in oklab, var(--color-fields-bg) 50%, var(--color-affirm) 50%);
        } */

    > input {
      opacity: 0;
    }

    &::before {
      content: "";
      background: var(--color-bg);
      border-radius: 50%;
      width: 1rem;
      height: 1rem;
      position: absolute;
      left: 2px;
      top: 2px;
      transition: background 0.23s, left 0.23s;
    }

    &:has(input:checked)::before {
      left: calc(100% - 1rem - 2px);
      background: var(--color-affirm);
    }
  }

  &:hover > span:has(> input[type="checkbox"]) {
    outline: 2px solid #201f2e;
  }
}

dialog input,
dialog select {
  border-radius: 0.25rem;
  outline: 2px solid transparent;
  transition: outline 0.23s;
}

dialog select {
  background-image: url(../img/icons/up-down-solid.svg);
  background-position: calc(100% - 0.5rem) 50%;
  background-repeat: no-repeat;
  background-size: 0.6rem;
}

label {
  display: block;
  padding: 0 0 0.5rem;
}

input[type="text"]:focus-visible,
input[type="text"]:hover,
input[type="email"]:focus-visible,
input[type="email"]:hover,
input[type="datetime-local"]:focus-visible,
input[type="datetime-local"]:hover,
select:focus-visible,
select:hover {
  outline: 2px solid #201f2e;
}

::placeholder,
select:invalid {
  color: #808080;
}

dialog footer {
  padding-top: 2rem;
}

button.primary {
  background: linear-gradient(19deg, var(--color-affirm), #ffe500), linear-gradient(8deg, #028068, #00aafa00);
  background-blend-mode: overlay;
  color: #fff;
  /* padding: 1rem; */
}

button.secondary {
  background: none;
  /* width: auto; */
  border: 1px solid;
  color: #fff;
  margin: 0 auto;
}

dialog fieldset {
  margin-bottom: 1rem;
}

dialog fieldset label {
  display: block;
  margin-bottom: 0.5rem;
}


:root {

--cover-image: 50% / cover url(/app/cover/4d3201df-03c7-11f0-8698-fa163e582850/1754906730972-123321b35add674d.jpg) no-repeat;
	--event-color-primary: hsl(49 100% 100%); 
}

.cover { 
	--cover-logo-y: 40%; 
	--cover-logo-opacity: 0; 
}