.auth-gate {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, .95fr) minmax(360px, .75fr);
  gap: 42px;
  align-items: center;
  padding: 56px clamp(22px, 6vw, 92px);
  background:
    radial-gradient(circle at 18% 18%, rgba(20,99,255,.18), transparent 30%),
    radial-gradient(circle at 86% 26%, rgba(10,164,246,.18), transparent 32%),
    linear-gradient(135deg,#f8fbff,#edf4ff 58%,#f9fbff);
}

.auth-gate-card {
  max-width: 620px;
}

.auth-gate-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--navy);
  text-decoration: none;
  margin-bottom: 38px;
}

.auth-gate-brand .brand-mark {
  color: #fff;
}

.auth-gate-brand strong,
.auth-gate-brand small {
  display: block;
}

.auth-gate-brand strong {
  font-size: 15px;
}

.auth-gate-brand small {
  color: #6f83a0;
  font-size: 11px;
  margin-top: 3px;
}

.auth-gate-pill {
  display: inline-flex;
  align-items: center;
  padding: 7px 11px;
  border-radius: 999px;
  background: #eaf2ff;
  color: var(--blue);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.auth-gate h1 {
  max-width: 580px;
  color: var(--navy);
  font-size: clamp(42px, 6vw, 72px);
  line-height: .95;
  letter-spacing: -.07em;
  margin: 18px 0;
}

.auth-gate p {
  max-width: 555px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
  margin: 0;
}

.auth-gate-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 30px;
}

#auth-gate-status {
  color: #6f83a0;
  font-size: 12px;
  font-weight: 800;
}

.auth-gate-preview {
  min-height: 520px;
  display: grid;
  place-items: center;
}

.preview-window {
  width: min(100%, 500px);
  padding: 20px;
  border: 1px solid rgba(221,229,241,.9);
  border-radius: 28px;
  background: rgba(255,255,255,.82);
  box-shadow: 0 28px 80px rgba(11,31,68,.15);
  backdrop-filter: blur(14px);
  transform: rotate(1.2deg);
}

.preview-bar {
  display: flex;
  gap: 7px;
  margin-bottom: 20px;
}

.preview-bar span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #d8e2ef;
}

.preview-metric-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 14px;
}

.preview-metric-row div,
.preview-pipeline {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
}

.preview-metric-row div {
  padding: 18px;
}

.preview-metric-row small,
.preview-metric-row strong {
  display: block;
}

.preview-metric-row small {
  color: #7a8ba3;
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.preview-metric-row strong {
  color: var(--navy);
  font-size: 38px;
  letter-spacing: -.05em;
  margin-top: 7px;
}

.preview-pipeline {
  padding: 18px;
}

.preview-pipeline span {
  display: block;
  height: 14px;
  border-radius: 999px;
  background: #edf3fb;
  margin: 12px 0;
}

.preview-pipeline span:nth-child(1) { width: 92%; background: #dfeaff; }
.preview-pipeline span:nth-child(2) { width: 76%; }
.preview-pipeline span:nth-child(3) { width: 84%; background: #e7f7ed; }
.preview-pipeline span:nth-child(4) { width: 62%; }

.auth-status {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 7px 10px;
  border-radius: 999px;
  background: #eef4ff;
  color: #315178;
  font-size: 11px;
  font-weight: 850;
  white-space: nowrap;
}

.auth-status::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  margin-right: 7px;
  background: currentColor;
}

.auth-status.online {
  background: #e7f7ed;
  color: #14763f;
}

.auth-status.syncing {
  background: #eef4ff;
  color: #315178;
}

.auth-status.local {
  background: #fff4df;
  color: #8a5600;
}

.auth-status.offline {
  background: #f0f3f8;
  color: #6d7d92;
}

.auth-status.error {
  background: #ffe9e9;
  color: #a13232;
}

.account-card {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 6px 10px 6px 6px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255,255,255,.85);
}

.account-copy {
  display: block;
  min-width: 0;
}

.account-copy strong,
.account-copy small {
  display: block;
  max-width: 210px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-copy strong {
  color: var(--navy);
  font-size: 11px;
}

.account-copy small {
  color: var(--muted);
  font-size: 9px;
  margin-top: 2px;
}

.auth-action {
  white-space: nowrap;
}

@media (max-width: 850px) {
  .auth-gate {
    grid-template-columns: 1fr;
  }

  .auth-gate-preview {
    display: none;
  }

  .auth-status {
    display: none;
  }

  .account-copy strong,
  .account-copy small {
    max-width: 135px;
  }
}

@media (max-width: 680px) {
  .account-copy {
    display: none;
  }

  .account-card {
    padding-right: 6px;
  }
}
