:root {
  --ink:       #0A0A0A;
  --ink-2:     #141414;
  --ink-3:     #1E1E1E;
  --line:      #2A2A2A;
  --muted:     #6B6B6B;
  --subtle:    #9A9A9A;
  --white:     #F4F3EF;
  --gold:      #C8A84B;
  --gold-dim:  rgba(200,168,75,0.12);
  --amber:     #D9822E;
  --green:     #3ECF6C;
  --red:       #E05252;
  --font:      'Inter', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', sans-serif;
  --radius:    10px;
  --nav-h:     104px;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body { background: var(--ink); color: var(--white); font-family: var(--font); line-height: 1.5; overflow-x: hidden; min-height: 100vh; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; color: inherit; }
input { font-family: inherit; }

.nav {
  position: fixed; inset-block-start: 0; inset-inline: 0; z-index: 200;
  height: var(--nav-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 24px;
  background: rgba(10,10,10,.85);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--line);
}
.nav-logo { font-size: 45px; font-weight: 800; letter-spacing: -.04em; white-space: nowrap; color: var(--amber); }
.nav-logo em { font-style: normal; color: var(--amber); }
.nav-right { display: flex; align-items: center; gap: 10px; }
.btn-ghost {
  padding: 7px 16px; border-radius: 7px;
  font-size: 13px; font-weight: 600;
  border: 1px solid var(--line); color: var(--subtle);
  transition: all .15s;
}
.btn-ghost:hover { border-color: var(--subtle); color: var(--white); }
.btn-primary {
  padding: 8px 18px; border-radius: 7px;
  font-size: 13px; font-weight: 700;
  background: var(--gold); color: var(--ink);
  transition: opacity .15s;
}
.btn-primary:hover { opacity: .88; }

@media (max-width: 480px) {
  .nav-logo { font-size: 26px; }
  .nav-right .btn-ghost { display: none; }
}

.auth-wrap {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  padding: calc(var(--nav-h) + 40px) 20px 60px;
  background:
    radial-gradient(1200px 500px at 50% -10%, var(--gold-dim), transparent 60%),
    var(--ink);
}
.auth-card {
  width: 100%; max-width: 420px;
  background: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 36px 32px;
}
.auth-card.wide { max-width: 480px; }
.auth-eyebrow {
  font-size: 11px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--gold);
  margin-bottom: 10px;
}
.auth-title { font-size: 26px; font-weight: 800; letter-spacing: -.02em; margin-bottom: 8px; }
.auth-sub { font-size: 13.5px; color: var(--subtle); margin-bottom: 28px; }

.field { margin-bottom: 16px; }
.field label {
  display: block; font-size: 12px; font-weight: 600; color: var(--subtle);
  margin-bottom: 6px; letter-spacing: .02em;
}
.field input {
  width: 100%; padding: 12px 14px;
  background: var(--ink-3); border: 1px solid var(--line); border-radius: var(--radius);
  color: var(--white); font-size: 14px;
  transition: border-color .15s;
}
.field input::placeholder { color: var(--muted); }
.field input:focus { outline: none; border-color: var(--gold); }
.field-error { font-size: 12px; color: var(--red); margin-top: 6px; display: none; }
.field-error.show { display: block; }
.field-hint { font-size: 11.5px; color: var(--muted); margin-top: 6px; line-height: 1.5; }

.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 76px; }
.pw-toggle {
  position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
  font-size: 12px; font-weight: 600; color: var(--gold);
}

.auth-row-between { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; gap: 12px; }

.link-gold { color: var(--gold); font-size: 13px; font-weight: 600; }
.link-gold:hover { opacity: .85; }

.btn-submit {
  width: 100%; padding: 13px; border-radius: var(--radius);
  background: var(--gold); color: var(--ink);
  font-size: 14px; font-weight: 700;
  transition: opacity .15s;
}
.btn-submit:hover { opacity: .88; }
.btn-submit:disabled { opacity: .5; cursor: not-allowed; }
.btn-secondary {
  width: 100%; padding: 12px; border-radius: var(--radius);
  background: transparent; color: var(--white);
  font-size: 14px; font-weight: 600;
  border: 1px solid var(--line);
  transition: border-color .15s;
}
.btn-secondary:hover { border-color: var(--subtle); }
.btn-secondary:disabled { opacity: .5; cursor: not-allowed; }

.auth-divider {
  display: flex; align-items: center; gap: 12px;
  margin: 22px 0; color: var(--muted); font-size: 12px;
}
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }

.auth-footer { text-align: center; font-size: 13.5px; color: var(--subtle); margin-top: 20px; }
.auth-note {
  margin-top: 24px; padding: 12px 14px; border-radius: 8px;
  background: rgba(200,168,75,.08); border: 1px solid var(--gold-dim);
  font-size: 12px; color: var(--subtle); line-height: 1.6;
}

.form-banner {
  padding: 11px 14px; border-radius: 8px; font-size: 13px; margin-bottom: 18px; line-height: 1.5;
  display: none;
}
.form-banner.show { display: block; }
.form-banner.error { background: rgba(224,82,82,.1); border: 1px solid rgba(224,82,82,.3); color: var(--red); }
.form-banner.success { background: rgba(62,207,108,.1); border: 1px solid rgba(62,207,108,.3); color: var(--green); }
.form-banner.info { background: rgba(200,168,75,.08); border: 1px solid var(--gold-dim); color: var(--white); }

.panel { display: none; }
.panel.show { display: block; }

.otp-row { display: flex; gap: 8px; }
.otp-row input { letter-spacing: .3em; text-align: center; font-size: 18px; font-weight: 700; }

.terms-row { display: flex; align-items: flex-start; gap: 10px; margin: 18px 0 20px; }
.terms-row input { margin-top: 3px; accent-color: var(--gold); }
.terms-row label { font-size: 12.5px; color: var(--subtle); line-height: 1.5; }
.terms-row a { color: var(--gold); font-weight: 600; }

.account-dl { margin: 8px 0 20px; }
.account-dl div {
  display: flex; justify-content: space-between; gap: 12px;
  padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14px;
}
.account-dl dt { color: var(--muted); }
.account-dl dd { font-weight: 600; text-align: right; }

.toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(100px);
  background: var(--ink-3); border: 1px solid var(--line); border-radius: 10px;
  padding: 13px 20px; font-size: 13.5px; z-index: 500;
  opacity: 0; transition: all .3s;
  max-width: 90vw;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
