/* TechCom auth — white default, site-aligned type + pill CTA */

html:has(body.auth-body),
body.auth-body {
  background: #ffffff;
}

body.auth-body .shell {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  max-width: 640px;
  background: #ffffff;
  /* Top inset only; bottom handled by .auth-screen__footer to avoid double pad. */
  padding-top: var(--safe-top);
  padding-bottom: 0;
}

.auth-screen {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  width: 100%;
}

.auth-screen__header {
  display: flex;
  align-items: center;
  min-height: 50px;
  padding: 10px 0 14px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 28px;
}

.tc-header--auth {
  align-items: flex-start;
  text-align: left;
  max-width: none;
  width: 100%;
  animation: none;
}

.tc-header--auth .tc-logo {
  width: 148px;
  max-width: 48vw;
  margin: 0;
}

.tc-header--auth .tc-logo-wordmark {
  font-size: clamp(28px, 8vw, 40px);
  text-align: left;
}

.auth-screen__body {
  flex: 1;
  min-height: 0;
}

.auth-screen__eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  color: var(--accent);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.auth-screen__eyebrow::before {
  content: "";
  width: 14px;
  height: 14px;
  flex: 0 0 14px;
  background: var(--accent);
  clip-path: polygon(50% 0%, 93% 25%, 93% 75%, 50% 100%, 7% 75%, 7% 25%);
}

.auth-screen__title {
  margin: 0 0 10px;
  color: #262626;
  font-size: clamp(1.75rem, 7vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  text-transform: uppercase;
}

.auth-screen__lead {
  margin: 0;
  max-width: 28rem;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 500;
  line-height: 1.45;
}

.auth-screen__footer {
  margin-top: auto;
  padding-top: 24px;
  padding-bottom: max(8px, var(--safe-bottom));
}

.auth-screen__cta {
  display: flex;
  width: 100%;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0 18px;
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

.auth-email {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

.auth-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.auth-field__label {
  color: #262626;
  font-size: 0.8125rem;
  font-weight: 600;
}

.auth-field input {
  height: 48px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fafafa;
  color: #262626;
  font: inherit;
  font-size: 0.95rem;
}

.auth-field input:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
  background: #ffffff;
}

.auth-field__hint {
  margin: 0;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.4;
}

.auth-email__status {
  margin: 0;
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.4;
}

.auth-email__status--error {
  color: #b42318;
}

.auth-email__send,
.auth-email__verify {
  width: 100%;
}

.auth-email__send:disabled,
.auth-email__verify:disabled,
.auth-email__send.is-busy,
.auth-email__verify.is-busy {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
  pointer-events: none;
}

.auth-email__resend {
  align-self: flex-start;
  padding: 0;
  border: none;
  background: none;
  color: var(--accent);
  font: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
}

.auth-email__resend:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

/* Desktop: CTAs + email form share full shell width (aligned, not narrowed) */
@media (min-width: 720px) {
  body.auth-body .shell {
    min-height: auto;
    padding-top: 32px;
  }

  .auth-screen {
    min-height: auto;
  }

  .auth-screen__body {
    flex: 0 0 auto;
  }

  .auth-screen__footer {
    margin-top: 28px;
    padding-top: 0;
    padding-bottom: 0;
    width: 100%;
    max-width: none;
  }

  .auth-screen__cta {
    width: 100%;
    min-width: 0;
  }

  .auth-email {
    max-width: none;
    width: 100%;
  }
}

/* .btn { display: flex } can override the HTML hidden attribute */
.auth-email__send[hidden],
.auth-email__verify[hidden],
.auth-email__resend[hidden],
.auth-email__code-step[hidden] {
  display: none !important;
}

.auth-legal-links {
  margin: 20px 0 0;
  text-align: center;
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 500;
}

.auth-legal-links a {
  color: var(--muted);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}
