:root {
  color-scheme: dark;
  --bg: #071016;
  --panel: rgba(9, 18, 28, 0.78);
  --panel-strong: rgba(12, 24, 37, 0.92);
  --line: rgba(155, 198, 223, 0.2);
  --line-strong: rgba(155, 198, 223, 0.34);
  --text: #f3fbff;
  --muted: #9fb3c5;
  --soft: #d5e9f6;
  --accent: #35a7ff;
  --accent-2: #20d6a5;
  --warning: #f3b44e;
  --danger: #ff6b78;
  --shadow: 0 30px 90px rgba(0, 7, 14, 0.52);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font-family: "Bahnschrift", "Segoe UI Variable Display", "Trebuchet MS", sans-serif;
  background:
    radial-gradient(circle at 18% 12%, rgba(53, 167, 255, 0.26), transparent 28rem),
    radial-gradient(circle at 82% 20%, rgba(32, 214, 165, 0.18), transparent 22rem),
    radial-gradient(circle at 52% 92%, rgba(243, 180, 78, 0.12), transparent 20rem),
    linear-gradient(145deg, #071016 0%, #0a1b24 48%, #071017 100%);
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(circle at 50% 40%, black, transparent 72%);
}

button,
input {
  font: inherit;
}

.auth-page {
  width: min(1180px, calc(100% - 32px));
  min-height: 100vh;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(360px, 460px);
  align-items: center;
  gap: 36px;
  padding: 44px 0;
}

.hero {
  position: relative;
  min-height: 620px;
  padding: 34px;
  border: 1px solid var(--line);
  border-radius: 36px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.08), transparent 34%),
    linear-gradient(180deg, rgba(9, 19, 31, 0.72), rgba(5, 12, 18, 0.52));
  box-shadow: var(--shadow);
  overflow: hidden;
  animation: rise 520ms ease-out both;
}

.hero::after {
  content: "";
  position: absolute;
  width: 520px;
  height: 520px;
  right: -160px;
  bottom: -180px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(53, 167, 255, 0.3), transparent 62%);
}

.brand-row {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-mark {
  width: 58px;
  height: 58px;
  padding: 8px;
  object-fit: contain;
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
}

.brand-title {
  display: grid;
  gap: 2px;
}

.brand-title strong {
  font-size: 18px;
  letter-spacing: 0.12em;
}

.brand-title span,
.eyebrow,
.micro-copy,
.panel-note,
.check-item {
  color: var(--muted);
}

.hero h1 {
  position: relative;
  z-index: 1;
  max-width: 720px;
  margin: 76px 0 18px;
  font-size: clamp(48px, 7vw, 90px);
  line-height: 0.9;
  letter-spacing: -0.07em;
}

.hero-copy {
  position: relative;
  z-index: 1;
  max-width: 650px;
  margin: 0;
  color: #c7dbe9;
  font-size: 19px;
  line-height: 1.55;
}

.signal-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 58px;
}

.signal-card {
  min-height: 126px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(4, 12, 19, 0.54);
  backdrop-filter: blur(16px);
}

.signal-card span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.signal-card strong {
  display: block;
  margin-top: 22px;
  font-size: 26px;
}

.signal-card.good strong {
  color: var(--accent-2);
}

.signal-card.warn strong {
  color: var(--warning);
}

.login-shell {
  position: relative;
  z-index: 2;
  padding: 28px;
  border: 1px solid var(--line-strong);
  border-radius: 32px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), transparent 22%),
    var(--panel-strong);
  box-shadow: var(--shadow);
  animation: rise 520ms ease-out 100ms both;
}

.login-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
  margin-bottom: 26px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-2);
  box-shadow: 0 0 18px var(--accent-2);
}

.login-shell h2 {
  margin: 0 0 10px;
  font-size: 34px;
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.panel-note {
  margin: 0;
  line-height: 1.55;
}

.login-alert {
  margin: 0 0 16px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 107, 120, 0.34);
  border-radius: 18px;
  color: #ffd6da;
  background: rgba(255, 107, 120, 0.1);
}

.login-form {
  display: grid;
  gap: 16px;
}

.field {
  display: grid;
  gap: 9px;
}

.field-label {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--soft);
  font-size: 14px;
}

.field-hint {
  color: var(--muted);
  font-size: 12px;
}

.input-wrap {
  position: relative;
}

.input-wrap input {
  width: 100%;
  height: 58px;
  padding: 0 52px 0 16px;
  border: 1px solid rgba(155, 198, 223, 0.24);
  border-radius: 18px;
  color: var(--text);
  background: rgba(2, 9, 15, 0.74);
  outline: none;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.input-wrap input:focus {
  border-color: rgba(53, 167, 255, 0.82);
  background: rgba(4, 14, 22, 0.92);
  box-shadow: 0 0 0 4px rgba(53, 167, 255, 0.14);
}

.input-icon {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
}

.password-toggle {
  position: absolute;
  right: 8px;
  top: 8px;
  width: 42px;
  height: 42px;
  border: 1px solid transparent;
  border-radius: 14px;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
}

.password-toggle:hover,
.password-toggle:focus-visible {
  color: var(--text);
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.06);
  outline: none;
}

.submit-button {
  position: relative;
  height: 60px;
  margin-top: 4px;
  border: 0;
  border-radius: 20px;
  color: #041019;
  background: linear-gradient(135deg, #68c4ff 0%, #20d6a5 100%);
  font-weight: 800;
  letter-spacing: 0.02em;
  cursor: pointer;
  overflow: hidden;
  transition: transform 160ms ease, filter 160ms ease;
}

.submit-button::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-120%);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.45), transparent);
  transition: transform 520ms ease;
}

.submit-button:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
}

.submit-button:hover::after {
  transform: translateX(120%);
}

.trust-list {
  display: grid;
  gap: 10px;
  margin-top: 20px;
}

.check-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
}

.check-item::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

.micro-copy {
  margin: 20px 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  line-height: 1.5;
}

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

@media (max-width: 940px) {
  .auth-page {
    grid-template-columns: 1fr;
    align-items: start;
    padding: 24px 0;
  }

  .hero {
    min-height: auto;
  }

  .hero h1 {
    margin-top: 48px;
  }
}

@media (max-width: 640px) {
  .auth-page {
    width: min(100% - 20px, 480px);
  }

  .hero {
    display: none;
  }

  .login-shell {
    padding: 20px;
    border-radius: 26px;
  }

  .login-shell h2 {
    font-size: 28px;
  }
}
