html.auth-pending body > :not(.auth-gate) {
  display: none !important;
}

html.auth-pending,
html.auth-pending body {
  min-height: 100%;
  margin: 0;
}

.auth-gate {
  align-items: center;
  background:
    radial-gradient(circle at 14% 18%, rgba(51, 179, 198, 0.2), transparent 30rem),
    linear-gradient(145deg, #0d2538 0%, #173f5b 56%, #0d6072 100%);
  box-sizing: border-box;
  color: #1b1b1b;
  display: flex;
  font-family: "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans-serif;
  justify-content: center;
  min-height: 100vh;
  padding: clamp(1rem, 4vw, 3rem);
}

.auth-gate--loading {
  background: #f5f7f9;
  color: #334155;
}

.auth-loading {
  display: grid;
  justify-items: center;
  gap: 0.75rem;
  text-align: center;
}

.auth-loading p { margin: 0; }

.auth-loading__spinner {
  border: 3px solid #dbe3eb;
  border-top-color: #2563eb;
  border-radius: 50%;
  height: 1.5rem;
  width: 1.5rem;
  animation: auth-loading-spin 0.8s linear infinite;
}

@keyframes auth-loading-spin {
  to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
  .auth-loading__spinner { animation: none; }
}

.auth-card {
  background: #fff;
  border-radius: 1.25rem;
  box-shadow: 0 1.5rem 4rem rgba(0, 13, 26, 0.32);
  box-sizing: border-box;
  display: grid;
  grid-template-columns: minmax(18rem, .9fr) minmax(22rem, 1.1fr);
  max-width: 58rem;
  overflow: hidden;
  width: 100%;
}

.auth-card__brand {
  background: #102f46;
  color: #fff;
  display: flex;
  flex-direction: column;
  min-height: 31rem;
  padding: clamp(2rem, 5vw, 3.2rem);
}

.auth-card__signin {
  align-self: center;
  padding: clamp(2.25rem, 6vw, 4.2rem);
}

.auth-mark {
  align-items: center;
  background: #fff;
  border-radius: 0.9rem;
  color: #102f46;
  display: flex;
  font-size: 0.82rem;
  font-weight: 800;
  height: 3.7rem;
  justify-content: center;
  letter-spacing: 0.08em;
  margin-bottom: 2rem;
  width: 3.7rem;
}

.auth-brand-name { font-size: 1.8rem; font-weight: 800; letter-spacing: -0.03em; margin: 0 0 0.7rem; }
.auth-brand-copy { color: #cce7f2; font-size: 1.08rem; line-height: 1.55; margin: 0; }
.auth-brand-copy a { color: inherit; }
.auth-features { color: #e3f3f7; display: grid; gap: 0.85rem; line-height: 1.4; list-style: none; margin: auto 0 0; padding: 0; }
.auth-features li { padding-left: 1.7rem; position: relative; }
.auth-features li::before { color: #56d2dd; content: "✓"; font-weight: 900; left: 0; position: absolute; }

.auth-eyebrow {
  color: #005ea8;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  margin: 0 0 0.5rem;
  text-transform: uppercase;
}

.auth-card h1 {
  color: #102f46;
  font-size: clamp(2rem, 5vw, 2.8rem);
  letter-spacing: -0.035em;
  line-height: 1.05;
  margin: 0 0 1rem;
}

.auth-intro {
  color: #565c65;
  font-size: 1.1rem;
  margin: 0 0 1.75rem;
}

.auth-form label {
  display: block;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.auth-form input {
  border: 2px solid #565c65;
  border-radius: 0.25rem;
  box-sizing: border-box;
  font: inherit;
  min-height: 3rem;
  padding: 0.5rem 0.75rem;
  width: 100%;
}

.auth-form input:focus,
.auth-form button:focus {
  outline: 0.25rem solid #face00;
  outline-offset: 0.2rem;
}

.auth-form input[aria-invalid="true"] {
  border-color: #b50909;
}

.auth-error {
  color: #b50909;
  font-weight: 700;
  min-height: 1.5rem;
  margin: 0.5rem 0;
}

.auth-form button {
  background: #005ea8;
  border: 0;
  border-radius: 0.25rem;
  color: #fff;
  cursor: pointer;
  font: inherit;
  font-weight: 700;
  min-height: 3rem;
  padding: 0.65rem 1.5rem;
  width: 100%;
}

.auth-form button:hover {
  background: #1a4480;
}

.auth-form button:disabled {
  cursor: wait;
  opacity: 0.65;
}

.auth-google-button {
  align-items: center;
  background: #fff;
  border: 2px solid #565c65;
  border-radius: 0.55rem;
  color: #1b1b1b;
  cursor: pointer;
  display: flex;
  font: inherit;
  font-weight: 700;
  gap: 0.8rem;
  justify-content: center;
  min-height: 3.4rem;
  padding: 0.65rem 1rem;
  width: 100%;
}

.auth-google-button:hover:not(:disabled) {
  background: #f0f0f0;
}

.auth-google-button:focus-visible {
  outline: 0.25rem solid #face00;
  outline-offset: 0.2rem;
}

.auth-google-button:disabled {
  cursor: wait;
  opacity: 0.65;
}

.auth-google-mark {
  color: #1a73e8;
  font-family: Arial, sans-serif;
  font-size: 1.35rem;
  font-weight: 800;
}

.auth-help {
  color: #565c65;
  font-size: 0.85rem;
  line-height: 1.45;
  margin: 1.2rem 0 0;
}

.site-auth-session {
  align-items: center;
  background: #fff;
  border: 1px solid #c9c9c9;
  border-radius: 999px;
  bottom: 1rem;
  box-shadow: 0 0.35rem 1rem rgba(27, 50, 71, 0.2);
  color: #1b1b1b;
  display: flex;
  font-family: "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 0.82rem;
  gap: 0.65rem;
  left: 1rem;
  max-width: min(24rem, calc(100vw - 2rem));
  padding: 0.45rem 0.55rem 0.45rem 0.85rem;
  position: fixed;
  z-index: 9998;
}

.site-auth-session__identity {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-auth-session button {
  background: #e7eef3;
  border: 0;
  border-radius: 999px;
  color: #163558;
  cursor: pointer;
  flex: 0 0 auto;
  font: inherit;
  font-weight: 700;
  padding: 0.45rem 0.7rem;
}

.site-auth-session button:hover { background: #d9e8f6; }
.site-auth-session button:focus-visible { outline: 0.2rem solid #face00; outline-offset: 0.15rem; }
.site-auth-session button:disabled { cursor: wait; opacity: 0.6; }

.site-editor-launcher {
  align-items: center;
  background: #163558;
  border: 2px solid #fff;
  border-radius: 999px;
  bottom: 1rem;
  box-shadow: 0 0.4rem 1.2rem rgba(27, 50, 71, 0.3);
  color: #fff !important;
  display: inline-flex;
  font-family: "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  gap: 0.45rem;
  line-height: 1;
  padding: 0.75rem 1rem;
  position: fixed;
  right: 1rem;
  text-decoration: none !important;
  z-index: 9998;
}

.site-editor-launcher:hover {
  background: #005ea8;
}

.site-editor-launcher:focus-visible {
  outline: 0.25rem solid #face00;
  outline-offset: 0.2rem;
}

@media (prefers-reduced-motion: reduce) {
  .auth-form button {
    transition: none;
  }
}

@media (max-width: 560px) {
  .site-auth-session__identity { max-width: 9rem; }
}

@media (max-width: 760px) {
  .auth-card { grid-template-columns: 1fr; max-width: 30rem; }
  .auth-card__brand { min-height: auto; padding: 1.5rem 1.7rem; }
  .auth-mark { height: 3rem; margin-bottom: 1rem; width: 3rem; }
  .auth-brand-name { font-size: 1.35rem; }
  .auth-brand-copy, .auth-features { display: none; }
  .auth-card__signin { padding: 2rem 1.7rem 2.2rem; }
}
