:root {
  --ink: #11151B;
  --panel: #171D26;
  --hairline: #2B3542;
  --brass: #B68A4E;
  --brass-light: #D9B57C;
  --parchment: #EDE7DA;
  --slate: #8B96A3;
  --error: #C2594A;
}

* { box-sizing: border-box; }

html, body {
  height: 100%;
  margin: 0;
}

body {
  background: var(--ink);
  background-image:
    radial-gradient(ellipse 900px 600px at 50% -10%, rgba(182, 138, 78, 0.08), transparent 60%);
  color: var(--parchment);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px;
}

.stage {
  width: 100%;
  display: flex;
  justify-content: center;
}

.panel {
  width: 100%;
  max-width: 440px;
  background: var(--panel);
  border: 1px solid var(--hairline);
  border-radius: 4px;
  padding: 48px 40px 40px;
  position: relative;
}

.panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 40px;
  right: 40px;
  height: 2px;
  background: linear-gradient(90deg, var(--brass), transparent 70%);
}

.panel__head {
  margin-bottom: 32px;
}

.kicker {
  font-size: 0.78rem;
  color: var(--brass-light);
  letter-spacing: 0.02em;
  margin: 0 0 14px;
  font-weight: 500;
}

.welcome {
  font-family: 'Fraunces', serif;
  font-weight: 500;
  font-size: 2.6rem;
  line-height: 1.05;
  margin: 0 0 14px;
  color: var(--parchment);
}

.sub {
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--slate);
  margin: 0;
  max-width: 34ch;
}

.ticks {
  display: flex;
  gap: 8px;
  margin-bottom: 36px;
}

.tick {
  height: 2px;
  flex: 1;
  background: var(--hairline);
  border-radius: 2px;
  transition: background 0.4s ease;
}

.tick.is-complete {
  background: var(--brass);
}

.tick.is-active {
  background: var(--brass-light);
}

.gate {
  position: relative;
}

.step {
  display: none;
}

.step.is-active {
  display: block;
  animation: rise 0.35s ease;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.field-label {
  display: block;
  font-size: 0.8rem;
  color: var(--slate);
  margin-bottom: 10px;
}

.field-input {
  width: 100%;
  background: var(--ink);
  border: 1px solid var(--hairline);
  border-radius: 3px;
  color: var(--parchment);
  font-family: 'Inter', sans-serif;
  font-size: 1.15rem;
  letter-spacing: 0.04em;
  padding: 14px 16px;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.field-input::placeholder {
  color: #4A5563;
  letter-spacing: 0.2em;
}

.field-input:focus {
  outline: none;
  border-color: var(--brass);
  background: #141A22;
}

.field-input.is-wrong {
  border-color: var(--error);
}

.error {
  min-height: 1.2em;
  font-size: 0.82rem;
  color: var(--error);
  margin: 14px 0 0;
}

.submit {
  width: 100%;
  margin-top: 22px;
  padding: 15px 20px;
  background: var(--brass);
  color: #211607;
  border: none;
  border-radius: 3px;
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.1s ease;
}

.submit:hover {
  background: var(--brass-light);
}

.submit:active {
  transform: scale(0.99);
}

.submit:disabled {
  opacity: 0.6;
  cursor: wait;
}

.submit.is-done {
  background: #6B8F71;
}

@media (prefers-reduced-motion: reduce) {
  .step.is-active { animation: none; }
}

:focus-visible {
  outline: 2px solid var(--brass-light);
  outline-offset: 2px;
}

@media (max-width: 480px) {
  .panel { padding: 36px 24px 28px; }
  .welcome { font-size: 2.1rem; }
}
