:root {
  color-scheme: dark;
  --page-padding: clamp(1.25rem, 5vw, 3rem);
  --text: #ffffff;
  --background: #000000;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--background);
}

body {
  min-height: 100svh;
  margin: 0;
  background: var(--background);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  text-rendering: optimizeLegibility;
}

main {
  min-height: 100svh;
  padding: 0 var(--page-padding) var(--page-padding);
}

.hero {
  display: flex;
  min-height: 100svh;
  width: min(100%, 44rem);
  margin: 0 auto;
  padding: var(--page-padding) 0;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  perspective: 52rem;
  text-align: center;
}

.mark {
  --box-depth: clamp(1.55rem, 5vw, 3.2rem);
  --box-line: clamp(2px, 0.45vw, 4px);
  --box-size: clamp(8.8rem, 30vw, 16.5rem);
  position: relative;
  display: grid;
  width: var(--box-size);
  height: var(--box-size);
  margin: var(--box-depth) 0 clamp(1.25rem, 3vw, 2rem);
  place-items: center;
  border: var(--box-line) solid currentColor;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0.025) 58%, rgba(255, 255, 255, 0.08));
  box-shadow: 0 clamp(1rem, 4vw, 2.4rem) clamp(1.5rem, 6vw, 4rem) rgba(0, 0, 0, 0.65), inset 0 0 0 1px rgba(255, 255, 255, 0.12);
  font-family: "Emilys Candy", Georgia, serif;
  font-size: clamp(7rem, 28vw, 15rem);
  font-weight: 400;
  line-height: 0.8;
  transform: rotateX(-9deg) rotateY(-18deg);
  transform-style: preserve-3d;
}

.mark::before,
.mark::after {
  position: absolute;
  border: var(--box-line) solid currentColor;
  background: rgba(255, 255, 255, 0.06);
  content: "";
  pointer-events: none;
}

.mark::before {
  right: calc(-1 * var(--box-line));
  bottom: 100%;
  left: calc(-1 * var(--box-line));
  height: var(--box-depth);
  border-bottom: 0;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.045));
  transform: rotateX(90deg);
  transform-origin: bottom;
}

.mark::after {
  top: calc(-1 * var(--box-line));
  bottom: calc(-1 * var(--box-line));
  left: 100%;
  width: var(--box-depth);
  border-left: 0;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.025));
  transform: rotateY(90deg);
  transform-origin: left;
}

.mark-symbol {
  display: block;
  transform: translateZ(calc(var(--box-depth) * 0.16));
  text-shadow: 0.035em 0.045em 0 rgba(255, 255, 255, 0.14), 0 0.12em 0.22em rgba(0, 0, 0, 0.5);
}

.slogan {
  margin: 0;
  font-size: clamp(1.6rem, 5vw, 3rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.description {
  margin: clamp(1rem, 3vw, 1.5rem) auto 0;
  max-width: 39rem;
  font-size: clamp(1rem, 2.2vw, 1.15rem);
  line-height: 1.65;
}

.description p {
  margin: 0;
}

.description p + p {
  margin-top: 0.85rem;
}

.learn-more {
  margin-top: 1rem;
}

.learn-more summary {
  display: inline-flex;
  padding: 0;
  align-items: center;
  gap: 0.35rem;
  justify-content: center;
  border: 0;
  color: #d0d0d0;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.3;
  list-style: none;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.24em;
  text-transform: lowercase;
  transition: color 160ms ease, opacity 160ms ease;
}

.learn-more summary:hover {
  color: var(--text);
}

.learn-more summary::after {
  display: inline-block;
  content: "↓";
  text-decoration: none;
  transition: transform 220ms ease;
}

.learn-more[open] summary::after {
  transform: rotate(180deg);
}

.learn-more summary::-webkit-details-marker {
  display: none;
}

.learn-more summary:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 4px;
}

.full-description {
  margin: 1.25rem auto 0;
  max-width: 42rem;
  font-size: clamp(0.95rem, 2vw, 1.05rem);
  line-height: 1.65;
  transform-origin: top;
}

.learn-more[open] .full-description {
  animation: unfold-description 260ms ease both;
}

@keyframes unfold-description {
  from {
    opacity: 0;
    transform: translateY(-0.45rem) scaleY(0.98);
  }

  to {
    opacity: 1;
    transform: translateY(0) scaleY(1);
  }
}

.full-description p {
  margin: 0;
}

.full-description p + p {
  margin-top: 0.85rem;
}

@media (prefers-reduced-motion: reduce) {
  .learn-more summary,
  .learn-more summary::after {
    transition: none;
  }

  .learn-more[open] .full-description {
    animation: none;
  }
}

.scroll-note {
  margin-top: clamp(1.5rem, 4vw, 2.25rem);
  font-size: clamp(0.95rem, 2vw, 1.05rem);
  font-weight: 700;
  line-height: 1.45;
}

.current-box-reveals {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  justify-content: center;
  margin: 0.7rem 0 0;
  color: #d0d0d0;
  font-size: 0.85rem;
  line-height: 1.4;
}

.current-box-reveals[hidden],
.current-box-reveal[hidden],
.current-box-reveal-separator[hidden] {
  display: none;
}

.current-box-reveal {
  display: inline-grid;
  min-width: min(100%, 12rem);
  min-height: 2.75rem;
  place-items: center;
}

.hints {
  width: min(100%, 48rem);
  margin: 0 auto;
  padding: clamp(2rem, 8vw, 5rem) 0 clamp(3rem, 10vw, 6rem);
}

.previous-box {
  display: grid;
  min-height: 2.75rem;
  padding-bottom: clamp(1.5rem, 5vw, 3rem);
  place-items: center;
  text-align: center;
}

.previous-box[hidden] {
  display: none;
}

.previous-box-button,
.previous-box-answer,
.current-box-reveal-button,
.current-box-reveal-answer {
  grid-area: 1 / 1;
  color: #d0d0d0;
  font: inherit;
  font-size: 0.85rem;
  line-height: 1.4;
}

.previous-box-button,
.current-box-reveal-button {
  position: relative;
  z-index: 1;
  min-height: 2.75rem;
  padding: 0.5rem 0.85rem;
  border: 0;
  border-radius: 0.35rem;
  background: transparent;
  cursor: pointer;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.24em;
  transition: color 160ms ease, opacity 1200ms ease, transform 1200ms ease;
}

.previous-box-button:hover,
.current-box-reveal-button:hover {
  color: var(--text);
}

.previous-box-button:focus-visible,
.current-box-reveal-button:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 4px;
}

.previous-box-answer,
.current-box-reveal-answer {
  display: inline-block;
  max-width: min(100%, 22rem);
  opacity: 0;
  pointer-events: none;
  transform: translateY(0.2rem);
  transition: opacity 1200ms ease 600ms, transform 1200ms ease 600ms;
}

.previous-box.is-revealed .previous-box-button,
.current-box-reveal.is-revealed .current-box-reveal-button {
  opacity: 0;
  pointer-events: none;
  transform: translateY(-0.2rem);
}

.previous-box.is-revealed .previous-box-answer,
.current-box-reveal.is-revealed .current-box-reveal-answer {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.site-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem 1.25rem;
  justify-content: center;
  padding: 0 var(--page-padding) var(--page-padding);
  color: #8a8a8a;
  font-size: 0.85rem;
  line-height: 1.4;
}

.site-footer a {
  color: inherit;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.24em;
  transition: color 160ms ease;
}

.site-footer a:hover {
  color: var(--text);
}

.site-footer a:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 4px;
}

@media (prefers-reduced-motion: reduce) {
  .previous-box-button,
  .previous-box-answer,
  .current-box-reveal-button,
  .current-box-reveal-answer,
  .site-footer a {
    transition: none;
  }
}

.hint-list {
  display: flex;
  flex-direction: column-reverse;
  gap: clamp(1.8rem, 5vw, 3rem);
  margin: 0;
  padding: 0;
  list-style: none;
}

.hint-list.is-loaded {
  flex-direction: column;
}

.hint-list-error {
  color: #8a8a8a;
  font-size: 0.95rem;
  text-align: center;
}

.component {
  display: flex;
  justify-content: center;
  text-align: center;
}

.component-title {
  margin: clamp(1rem, 4vw, 2rem) 0 0;
  font-family: "Emilys Candy", Georgia, serif;
  font-size: clamp(2.25rem, 9vw, 4.5rem);
  font-weight: 400;
  line-height: 0.95;
}

.hint {
  display: flex;
  align-items: center;
  flex-direction: column;
  font-size: clamp(1rem, 2vw, 1.15rem);
  line-height: 1.45;
  text-align: center;
}

.hint-number {
  font-family: "Emilys Candy", Georgia, serif;
  font-size: clamp(1.75rem, 5vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.04em;
}

.hint-time {
  display: block;
  margin-top: 0.35rem;
  color: #8a8a8a;
  font-size: 0.8rem;
  letter-spacing: 0.02em;
}

.hint-countdown {
  display: flex;
  justify-content: center;
  color: #8a8a8a;
  font-size: 0.85rem;
  line-height: 1.45;
  text-align: center;
}

.component-group-1,
.hint-group-1 {
  color: #ff4fd8;
}

.component-group-2,
.hint-group-2 {
  color: #00e5ff;
}

.component-group-3,
.hint-group-3 {
  color: #ffe45c;
}

.component-group-4,
.hint-group-4 {
  color: #7cff6b;
}

.component-group-5,
.hint-group-5 {
  color: #ff8a3d;
}

.component-group-6,
.hint-group-6 {
  color: #a78bfa;
}

.component-group-7,
.hint-group-7 {
  color: #38f8b6;
}

.component-group-8,
.hint-group-8 {
  color: #ff5f6d;
}

.component-group-9,
.hint-group-9 {
  color: #5c9dff;
}

.component-group-10,
.hint-group-10 {
  color: #f7b7ff;
}

@media (max-width: 34rem) {
  .hero {
    width: min(100%, 22rem);
  }

  .description {
    line-height: 1.55;
  }
}
