:root {
  --bg-abyss:      #050706;
  --bg-hull:       #0c0f0d;
  --ember:         #d9531e;
  --ember-hot:     #f0813a;
  --teal:          #3d8a9e;
  --bone:          #ece7dc;
  --fog:           #a7a196;
  --fog-dim:       #6f6a61;
  --line:          rgba(236, 231, 220, 0.14);

  --font-display: 'Anton', 'Impact', sans-serif;
  --font-body:    'Barlow', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --maxw: 34rem;
}

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

html {
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; }

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg-abyss);
  color: var(--fog);
  font-family: var(--font-body);
  font-size: clamp(1rem, 0.9rem + 0.4vw, 1.125rem);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* wood texture pinned to the top, fading down into black */
.bg {
  position: fixed;
  inset: 0;
  z-index: -2;
  background-color: var(--bg-abyss);
  background-image:
    linear-gradient(
      180deg,
      rgba(5, 7, 6, 0.10) 0%,
      rgba(5, 7, 6, 0.30) 38%,
      rgba(5, 7, 6, 0.72) 62%,
      var(--bg-abyss) 84%,
      var(--bg-abyss) 100%
    ),
    url("../images/bg.jpg");
  background-repeat: no-repeat, no-repeat;
  background-position: top center, top center;
  background-size: cover, cover;
}

.vignette {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(
    130% 90% at 50% 28%,
    transparent 40%,
    rgba(5, 7, 6, 0.55) 100%
  );
}

.stage {
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(1.5rem, 4vh, 2.75rem);
  padding: clamp(2.5rem, 8vh, 5rem) 1.5rem clamp(2rem, 5vh, 3.5rem);
  text-align: center;
}

.logo {
  width: min(85%, 30rem);
  height: auto;
  filter: drop-shadow(0 12px 40px rgba(0, 0, 0, 0.7));
  animation: rise 1s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.tagline {
  margin: 0;
  max-width: 30rem;
  color: var(--fog);
  font-size: clamp(1.05rem, 0.95rem + 0.6vw, 1.35rem);
  font-weight: 400;
  letter-spacing: 0.01em;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.8);
  animation: rise 1s cubic-bezier(0.16, 1, 0.3, 1) 0.1s both;
}

.signup {
  width: 100%;
  max-width: var(--maxw);
  padding: clamp(1.5rem, 4vw, 2.25rem);
  background: linear-gradient(180deg, rgba(18, 22, 20, 0.72), rgba(8, 10, 9, 0.82));
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.55),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  animation: rise 1s cubic-bezier(0.16, 1, 0.3, 1) 0.2s both;
}

.signup h2 {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.5rem, 1.2rem + 1.6vw, 2.1rem);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--bone);
}

.signup-sub {
  margin: 0 0 1.25rem;
  color: var(--fog);
  font-size: 0.95rem;
}

.formkit-form { width: 100%; }

.formkit-fields {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  justify-content: center;
  margin: 0 auto;
}

.formkit-field {
  flex: 1 1 15rem;
  min-width: 0;
}

.formkit-input {
  width: 100%;
  padding: 0.85rem 1rem;
  font: inherit;
  color: var(--bone);
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--line);
  border-radius: 8px;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.formkit-input::placeholder { color: var(--fog-dim); }

.formkit-input:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(61, 138, 158, 0.25);
}

.formkit-submit {
  flex: 0 0 auto;
  padding: 0.85rem 1.6rem;
  font-family: var(--font-display);
  font-size: 1rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #1a0d05;
  background: linear-gradient(180deg, var(--ember-hot), var(--ember));
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: transform 0.12s ease, filter 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 6px 18px rgba(217, 83, 30, 0.35);
}
.formkit-submit > span { display: block; }
.formkit-submit:hover { filter: brightness(1.08); box-shadow: 0 8px 24px rgba(217, 83, 30, 0.5); }
.formkit-submit:active { transform: translateY(1px); }
.formkit-submit:focus-visible { outline: 2px solid var(--ember-hot); outline-offset: 3px; }

.formkit-alert {
  flex: 1 1 100%;
  margin: 0.9rem 0 0;
  padding: 0.6rem 0.85rem;
  list-style: none;
  font-size: 0.9rem;
  text-align: center;
  border-radius: 8px;
}
.formkit-alert:empty { display: none; }
.formkit-alert-error {
  color: var(--ember-hot);
  background: rgba(217, 83, 30, 0.12);
  border: 1px solid rgba(240, 129, 58, 0.4);
}
.formkit-alert-success {
  color: var(--teal);
  background: rgba(61, 138, 158, 0.12);
  border: 1px solid rgba(61, 138, 158, 0.4);
}

.socials {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: clamp(0.5rem, 2vw, 0.9rem);
  max-width: var(--maxw);
  animation: rise 1s cubic-bezier(0.16, 1, 0.3, 1) 0.3s both;
}

.socials a {
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  color: var(--fog);
  background: rgba(12, 15, 13, 0.55);
  border: 1px solid var(--line);
  transition: color 0.2s, transform 0.2s, border-color 0.2s, background 0.2s, box-shadow 0.2s;
}

.socials a svg {
  width: 1.3rem;
  height: 1.3rem;
  fill: currentColor;
}

.socials a:hover,
.socials a:focus-visible {
  color: var(--ember-hot);
  border-color: rgba(240, 129, 58, 0.55);
  background: rgba(20, 14, 10, 0.8);
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
  outline: none;
}

.footer {
  margin-top: 0.5rem;
  color: var(--fog-dim);
  font-size: 0.8rem;
  letter-spacing: 0.02em;
  animation: rise 1s cubic-bezier(0.16, 1, 0.3, 1) 0.4s both;
}
.footer p { margin: 0; }

.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 {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

@media (max-width: 30rem) {
  .formkit-submit { flex: 1 1 100%; }
  .socials a { width: 2.75rem; height: 2.75rem; }
}
