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

html {
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scrollbar-width: none;
}

html::-webkit-scrollbar {
  display: none;
}

body {
  font-family: var(--font-ui);
  overflow-x: hidden;
  background: var(--stone-end);
}

#app {
  min-height: 100dvh;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  background: none;
  border: none;
  cursor: pointer;
  font: inherit;
  color: inherit;
}

.label {
  font-family: var(--font-ui);
  font-size: var(--label-size);
  letter-spacing: var(--label-spacing);
  text-transform: uppercase;
}

.ink-line-h {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-dim), transparent);
}

.ink-line-v {
  width: 1px;
  background: linear-gradient(to bottom, transparent, var(--gold-dim));
}

.hidden {
  display: none !important;
}

.loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  min-height: 60dvh;
  color: var(--parchment-ghost);
  font-family: var(--font-prose);
  font-size: 13px;
  font-style: italic;
  letter-spacing: 0.5px;
}

/* Infinity spinner */
.spinner-infinity {
  transform: perspective(10em) rotateZ(90deg) rotateY(30deg);
  display: inline-block;
}

.spinner-infinity__half {
  position: relative;
  width: 2.4em;
  height: 2.4em;
}

.spinner-infinity__half:first-child {
  transform: translateY(0.6em) rotateX(180deg);
}

.spinner-infinity__dot {
  position: absolute;
  width: 100%;
  height: 100%;
}

.spinner-infinity__dot::after {
  opacity: 0;
  content: '\2022';
  width: 100%;
  height: 100%;
  display: block;
  color: var(--gold-thread);
  font-size: 10px;
  animation: spinner-orbit 3.5s cubic-bezier(0.4, 0.1, 0.6, 0.9) infinite;
}

.spinner-infinity__half:first-child .spinner-infinity__dot:nth-child(1)::after { animation-delay: 0s; }
.spinner-infinity__half:first-child .spinner-infinity__dot:nth-child(2)::after { animation-delay: 0.25s; }
.spinner-infinity__half:first-child .spinner-infinity__dot:nth-child(3)::after { animation-delay: 0.5s; }
.spinner-infinity__half:first-child .spinner-infinity__dot:nth-child(4)::after { animation-delay: 0.75s; }
.spinner-infinity__half:first-child .spinner-infinity__dot:nth-child(5)::after { animation-delay: 1s; }
.spinner-infinity__half:first-child .spinner-infinity__dot:nth-child(6)::after { animation-delay: 1.25s; }
.spinner-infinity__half:last-child .spinner-infinity__dot:nth-child(1)::after { animation-delay: 1.75s; }
.spinner-infinity__half:last-child .spinner-infinity__dot:nth-child(2)::after { animation-delay: 2s; }
.spinner-infinity__half:last-child .spinner-infinity__dot:nth-child(3)::after { animation-delay: 2.25s; }
.spinner-infinity__half:last-child .spinner-infinity__dot:nth-child(4)::after { animation-delay: 2.5s; }
.spinner-infinity__half:last-child .spinner-infinity__dot:nth-child(5)::after { animation-delay: 2.75s; }
.spinner-infinity__half:last-child .spinner-infinity__dot:nth-child(6)::after { animation-delay: 3s; }

@keyframes spinner-orbit {
  0% { transform: rotate(0deg); opacity: 0; }
  25% { opacity: 1; }
  50%, 100% { transform: rotate(360deg); opacity: 0; }
}
