:root {
  --bg: #070809;
  --bg-soft: #101316;
  --glass: rgba(255, 255, 255, 0.08);
  --glass-border: rgba(255, 255, 255, 0.24);
  --text: #f6f2ea;
  --text-soft: #d8cec0;
  --gold: #d1a060;
  --gold-strong: #e5b779;
  --brown: #3c2516;
  --success: #8de8be;
  --error: #ff9f9f;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  color: var(--text);
  font-family: 'Manrope', sans-serif;
  background:
    radial-gradient(circle at 12% 18%, rgba(71, 44, 26, 0.45) 0%, transparent 35%),
    radial-gradient(circle at 88% 2%, rgba(209, 160, 96, 0.2) 0%, transparent 33%),
    linear-gradient(145deg, #070809 0%, #0b1016 55%, #070809 100%);
}

.top-nav-wrap {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(6, 7, 9, 0.72);
}

.top-nav {
  width: min(1120px, 100%);
  margin: 0 auto;
  padding: 0.9rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  color: var(--text);
  text-decoration: none;
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.8rem, 4vw, 2.2rem);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.desktop-links {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.desktop-links a,
.mobile-menu a {
  text-decoration: none;
  color: var(--text-soft);
  font-size: 0.92rem;
  font-weight: 600;
  border-radius: 999px;
  padding: 0.5rem 0.9rem;
  transition: transform 200ms ease, color 200ms ease, background-color 200ms ease;
}

.desktop-links a:hover,
.mobile-menu a:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.09);
}

.desktop-links .active,
.mobile-menu .active {
  background: rgba(255, 255, 255, 0.13);
  color: #fff;
}

.desktop-links .cta-link {
  margin-left: 0.2rem;
  background: linear-gradient(135deg, var(--gold-strong), var(--gold));
  color: #1a130e;
  box-shadow: 0 12px 28px rgba(205, 148, 76, 0.33);
}

.desktop-links .cta-link:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 32px rgba(205, 148, 76, 0.45);
}

.mobile-toggle {
  display: none;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  padding: 0.5rem 0.95rem;
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  font-weight: 600;
}

.mobile-menu {
  width: min(1120px, 100%);
  margin: 0 auto;
  padding: 0 1rem 0.9rem;
  display: grid;
  gap: 0.45rem;
}

.hidden {
  display: none;
}

.auth-scene {
  min-height: calc(100vh - 83px);
  padding: 2rem 1rem 2.8rem;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
}

.blur-orb {
  position: absolute;
  border-radius: 999px;
  filter: blur(40px);
  animation: floatBlob 8.5s ease-in-out infinite;
}

.orb-1 {
  width: 300px;
  height: 300px;
  background: rgba(209, 160, 96, 0.19);
  left: max(5%, 24px);
  top: max(10%, 66px);
}

.orb-2 {
  width: 380px;
  height: 380px;
  background: rgba(84, 50, 31, 0.31);
  right: max(8%, 24px);
  bottom: max(8%, 24px);
  animation-delay: 1.7s;
}

@keyframes floatBlob {
  0%,
  100% {
    transform: translate3d(0, 0, 0) scale(1);
  }

  50% {
    transform: translate3d(10px, -12px, 0) scale(1.05);
  }
}

.auth-card {
  position: relative;
  z-index: 2;
  width: min(100%, 460px);
  border-radius: 26px;
  border: 1px solid var(--glass-border);
  background: var(--glass);
  backdrop-filter: blur(16px);
  box-shadow: 0 28px 55px rgba(0, 0, 0, 0.48), inset 0 1px 0 rgba(255, 255, 255, 0.13);
  padding: 1.5rem 1.2rem;
  transform-style: preserve-3d;
}

.eyebrow {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.68rem;
  color: var(--gold-strong);
}

.auth-card h1 {
  margin: 0.35rem 0 0;
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2rem, 6vw, 2.7rem);
}

.subtitle {
  margin-top: 0.42rem;
  color: var(--text-soft);
  font-size: 0.93rem;
}

form {
  margin-top: 1rem;
  display: grid;
  gap: 0.74rem;
}

label {
  display: grid;
  gap: 0.35rem;
  color: var(--text-soft);
  font-size: 0.86rem;
}

input {
  width: 100%;
  border-radius: 13px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  font: inherit;
  padding: 0.77rem 0.9rem;
  transition: border-color 220ms ease, box-shadow 220ms ease, transform 220ms ease;
}

.password-wrap {
  position: relative;
}

.password-wrap input {
  padding-right: 2.8rem;
}

.password-toggle {
  position: absolute;
  right: 0.45rem;
  top: 50%;
  transform: translateY(-50%);
  width: 2rem;
  height: 2rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  cursor: pointer;
  color: var(--text-soft);
  transition: color 180ms ease, background-color 180ms ease;
}

.password-toggle::before {
  content: '\1F441';
  font-size: 1rem;
  line-height: 1;
}

.password-toggle.is-visible::before {
  content: '\1F576';
}

.password-toggle:hover,
.password-toggle:focus-visible {
  color: var(--gold-strong);
  background: rgba(255, 255, 255, 0.1);
  outline: none;
}

input:focus {
  outline: none;
  border-color: var(--gold-strong);
  box-shadow: 0 0 0 3px rgba(209, 160, 96, 0.28);
}

.row-between {
  margin-top: 0.2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.inline-check {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.82rem;
}

.inline-check input {
  width: 16px;
  height: 16px;
  accent-color: var(--gold);
}

.text-link {
  color: var(--gold-strong);
  text-decoration: none;
  font-size: 0.83rem;
}

.text-link:hover {
  text-decoration: underline;
}

button[type='submit'] {
  margin-top: 0.3rem;
  border: 0;
  border-radius: 13px;
  padding: 0.88rem 1rem;
  font: inherit;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #1d150f;
  background: linear-gradient(135deg, #efc68a 0%, #c99452 100%);
  cursor: pointer;
  transition: transform 220ms ease, box-shadow 220ms ease, filter 220ms ease;
}

button[type='submit']:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  filter: brightness(1.03);
}

.status {
  min-height: 1.1rem;
  margin: 0;
  font-size: 0.84rem;
  color: var(--text-soft);
}

.status.error {
  color: var(--error);
}

.status.success {
  color: var(--success);
}

.switch-text {
  margin: 0.8rem 0 0.1rem;
  font-size: 0.85rem;
  color: var(--text-soft);
}

@media (max-width: 820px) {
  .desktop-links {
    display: none;
  }

  .mobile-toggle {
    display: inline-block;
  }
}

@media (max-width: 520px) {
  .top-nav {
    padding: 0.75rem 0.8rem;
  }

  .auth-scene {
    padding: 1.5rem 0.75rem 1.8rem;
  }

  .auth-card {
    border-radius: 20px;
    padding: 1.2rem 0.9rem;
  }
}
