:root {
  --pit-black: #0b0b0b;
  --bone: #f2efe6;
  --ash: #c8c0b4;
  --smoke: #78736d;
  --bourbon: #ad7132;
  --line: rgba(242, 239, 230, 0.16);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
  background: var(--pit-black);
}

body {
  color: var(--bone);
  font-family: "Inter", sans-serif;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

[hidden] {
  display: none !important;
}

.gate {
  position: relative;
  min-height: 100svh;
  display: grid;
  place-items: center;
  overflow: hidden;
  background:
    url("../images/BROBQ_V_Invite.png")
    76% center / cover no-repeat;
}

.gate-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to bottom, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.82)),
    linear-gradient(to right, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.18));
}

.gate-glow {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  background:
    radial-gradient(
      circle at 50% 46%,
      rgba(195, 107, 35, 0.48),
      rgba(195, 107, 35, 0.08) 32%,
      transparent 62%
    );
}

.gate.is-opening .gate-glow {
  animation: fire-glow 0.9s ease both;
}

.gate-inner {
  position: relative;
  z-index: 1;
  width: min(90%, 560px);
  padding: 2rem 1rem;
  text-align: center;
  animation: rise-in 0.8s ease both;
}

.kicker {
  margin: 0 0 0.8rem;
  color: var(--bourbon);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

h1,
h2 {
  margin: 0;
  font-family: "Cormorant Garamond", serif;
  line-height: 0.92;
}

h1 {
  font-size: clamp(4.2rem, 19vw, 8.5rem);
  white-space: nowrap;
}

h2 {
  font-size: clamp(4rem, 15vw, 7rem);
}

.tagline {
  margin: 1.15rem 0 0;
  color: var(--ash);
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(1.25rem, 4.6vw, 1.8rem);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.rule {
  width: min(240px, 60%);
  height: 1px;
  margin: 2.25rem auto;
  background:
    linear-gradient(
      to right,
      transparent,
      rgba(173, 113, 50, 0.85),
      transparent
    );
}

.gate-note {
  margin: 0;
  color: var(--smoke);
  font-size: 0.86rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.prompt {
  margin: 0.7rem 0 1.25rem;
  font-family: "Cormorant Garamond", serif;
  font-size: 1.65rem;
}

.phrase-form {
  display: grid;
  grid-template-columns: 1fr auto;
  width: min(100%, 430px);
  margin: 0 auto;
  border-bottom: 1px solid rgba(242, 239, 230, 0.42);
}

.phrase-form:focus-within {
  border-color: var(--bourbon);
}

.phrase-form input {
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 0.95rem 0.15rem;
  background: transparent;
  color: var(--bone);
  font-size: 1rem;
  letter-spacing: 0.06em;
}

.phrase-form button {
  border: 0;
  padding: 0.95rem 0 0.95rem 1.5rem;
  background: transparent;
  color: var(--bourbon);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.gate-message {
  min-height: 1.5rem;
  margin: 1.25rem 0 0;
  color: var(--ash);
  font-family: "Cormorant Garamond", serif;
  font-size: 1.15rem;
}

.gate-message.success {
  color: var(--bourbon);
  font-size: 1.3rem;
}

.gate.is-opening .gate-inner {
  animation: open-door 0.9s ease forwards;
}

.clubhouse,
.chapters {
  position: fixed;
  inset: 0;
  overflow-y: auto;
  min-height: 100dvh;
  padding: 2rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(circle at top, rgba(173, 113, 50, 0.1), transparent 38%),
    var(--pit-black);
}

.clubhouse-inner,
.chapters-inner {
  width: min(760px, 100%);
  margin: auto;
  text-align: center;
  animation: clubhouse-in 0.75s ease both;
}

.clubhouse-nav,
.edition-list {
  display: grid;
  margin-top: 3rem;
  border-top: 1px solid var(--line);
}

.clubhouse-nav a,
.menu-link,
.edition-list a,
.edition-locked {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  padding: 1.35rem 0.25rem;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--bone);
  text-decoration: none;
  text-align: left;
}

.clubhouse-nav a,
.menu-link {
  opacity: 0;
  transform: translateY(10px);
  animation: menu-item-in 0.45s ease forwards;
}

.clubhouse-nav > :nth-child(1) {
  animation-delay: 0.1s;
}

.clubhouse-nav > :nth-child(2) {
  animation-delay: 0.2s;
}

.clubhouse-nav > :nth-child(3) {
  animation-delay: 0.3s;
}

.clubhouse-nav > :nth-child(4) {
  animation-delay: 0.4s;
}

.clubhouse-nav > :nth-child(5) {
  animation-delay: 0.5s;
}

.clubhouse-nav a:hover,
.clubhouse-nav a:focus-visible,
.menu-link:hover,
.menu-link:focus-visible,
.edition-list a:hover,
.edition-list a:focus-visible {
  color: var(--bourbon);
  padding-left: 0.6rem;
}

.menu-title,
.edition-list span {
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(1.7rem, 6vw, 2.45rem);
}

.menu-meta,
.edition-list small {
  color: var(--smoke);
  font-family: "Inter", sans-serif;
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.edition-locked {
  color: rgba(242, 239, 230, 0.48);
}

.reset-gate {
  margin-top: 2.5rem;
  border: 0;
  border-bottom: 1px solid var(--smoke);
  padding: 0.35rem 0;
  background: transparent;
  color: var(--smoke);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes fire-glow {
  0% {
    opacity: 0;
  }

  45% {
    opacity: 1;
  }

  100% {
    opacity: 0.35;
  }
}

@keyframes open-door {
  0% {
    opacity: 1;
    transform: scale(1);
  }

  60% {
    opacity: 1;
    transform: scale(1.012);
  }

  100% {
    opacity: 0;
    transform: scale(1.025);
  }
}

@keyframes clubhouse-in {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes menu-item-in {
  to {
    opacity: 1;
    transform: none;
  }
}

@media (max-width: 480px) {
  .gate {
    background-position: 79% center;
  }

  .gate-inner {
    width: 95%;
  }

  h1 {
    font-size: clamp(3.7rem, 18vw, 5.3rem);
  }

  .tagline {
    font-size: 1rem;
  }

  .clubhouse,
  .chapters {
    padding: 1.25rem 1rem;
  }

  .clubhouse-nav,
  .edition-list {
    margin-top: 2.2rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .gate-inner,
  .gate.is-opening .gate-inner,
  .gate.is-opening .gate-glow,
  .clubhouse-inner,
  .chapters-inner,
  .clubhouse-nav a,
  .menu-link {
    animation: none;
    opacity: 1;
    transform: none;
  }
}
