:root {
  --ink: #111827;
  --muted: #5b6472;
  --paper: #f6f2ea;
  --surface: #ffffff;
  --line: #d9dde4;
  --blue: #1f6feb;
  --green: #127c67;
  --red: #c2412d;
  --shadow: 0 18px 48px rgba(17, 24, 39, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(5, 12, 24, 0.9), rgba(5, 12, 24, 0.42)),
    linear-gradient(135deg, rgba(31, 111, 235, 0.48), transparent 42%),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.08) 0 1px, transparent 1px 72px),
    #111827;
  font-family: "Manrope", sans-serif;
  line-height: 1.55;
}

.auth-bg {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 42px 18px;
}

.auth-card {
  width: min(920px, 100%);
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.48);
  border-radius: 8px;
  padding: clamp(24px, 4vw, 40px);
  box-shadow: var(--shadow);
}

.auth-header {
  max-width: 720px;
  margin: 0 0 28px;
}

.auth-pill {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 8px;
  background: rgba(17, 24, 39, 0.06);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.auth-header h1 {
  margin: 12px 0 10px;
  max-width: 13ch;
  color: var(--ink);
  font-family: "Newsreader", serif;
  font-size: clamp(2.5rem, 6vw, 5rem);
  line-height: 1;
}

.auth-header p {
  margin: 0;
  max-width: 620px;
  color: var(--muted);
  font-size: 1rem;
}

.auth-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(280px, 1fr));
  gap: 16px;
  align-items: stretch;
}

.auth-section {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
}

.auth-section-muted {
  background: rgba(17, 24, 39, 0.04);
}

.auth-section h2 {
  margin: 0 0 8px;
  font-size: 1.22rem;
}

.auth-hint,
.auth-note {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 0.95rem;
}

.auth-form {
  display: grid;
  gap: 10px;
}

.auth-form label {
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 700;
}

.auth-form input {
  width: 100%;
  min-height: 46px;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

.auth-form input:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(31, 111, 235, 0.16);
}

.auth-btn {
  min-height: 46px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.auth-btn.primary {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}

.auth-btn.ghost {
  background: transparent;
}

.auth-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.auth-error {
  padding: 10px 12px;
  border: 1px solid rgba(194, 65, 45, 0.28);
  border-radius: 8px;
  background: rgba(194, 65, 45, 0.08);
  color: var(--red);
  font-size: 0.88rem;
}

.auth-separator {
  margin: 20px 0;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.auth-subscribe-link {
  display: inline-flex;
  width: fit-content;
  margin-top: 14px;
  color: var(--blue);
  font-weight: 800;
  text-decoration: none;
}

.auth-footer {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.auth-status {
  color: var(--muted);
}

.hidden {
  display: none !important;
}

@media (max-width: 820px) {
  body {
    background:
      linear-gradient(180deg, rgba(5, 12, 24, 0.9), rgba(5, 12, 24, 0.48)),
      linear-gradient(135deg, rgba(31, 111, 235, 0.48), transparent 44%),
      repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.08) 0 1px, transparent 1px 56px),
      #111827;
  }

  .auth-grid {
    grid-template-columns: 1fr;
  }

  .auth-footer {
    align-items: stretch;
    flex-direction: column;
  }
}
