/* Authentication uses the same theme tokens as the customer entry and workspace. */
@font-face {
  font-family: 'Warraby Google Sans';
  src: url('./fonts/google-sans-medium.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
body.h6p-auth-mode { margin: 0; }
body.h6p-auth-mode > .site-header,
body.h6p-auth-mode > .site-footer,
body.h6p-auth-mode > .customer-context-nav,
body.h6p-auth-mode > .mobile-bottom-nav,
body.h6p-auth-mode #sidebar,
body.h6p-auth-mode #footer,
body.h6p-auth-mode #header { display: none !important; }
body.h6p-auth-mode #app-shell,
body.h6p-auth-mode #main {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  min-height: 100svh;
  margin: 0 !important;
  padding: 0 !important;
  overflow: visible !important;
}
body.h6p-auth-mode #network-banner:empty,
body.h6p-auth-mode #storage-banner:empty { display: none; }

.h6p-auth-gate {
  display: grid;
  grid-template-rows: auto 1fr;
  align-content: start;
  min-height: 100svh;
  background: var(--surface);
  color: var(--ink);
}
.auth-utility {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  border-block-end: 1px solid var(--line);
  padding: var(--space-3) clamp(1rem, 5vw, 4rem);
}
.h6p-auth-frame {
  display: grid;
  grid-template-columns: minmax(13rem, .8fr) minmax(18rem, 1fr);
  gap: clamp(2rem, 6vw, 6rem);
  align-items: start;
  width: min(calc(100% - 3rem), 60rem);
  margin: clamp(3rem, 10vh, 7rem) auto auto;
}
.h6p-auth-intro { min-inline-size: 0; }
.h6p-auth-dialog { min-inline-size: 0; padding-block-end: var(--space-5); }
.h6p-auth-brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--ink);
  font-size: var(--type-title);
  font-weight: 780;
  letter-spacing: -.045em;
}
.h6p-auth-brand img { width: 30px; height: 30px; flex: 0 0 30px; }
.h6p-auth-languages {
  display: inline-flex;
  flex-shrink: 0;
  gap: 2px;
  padding: 2px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}
.h6p-auth-languages button {
  appearance: none;
  min-width: 44px;
  min-height: var(--target-min);
  padding: 0 var(--space-1);
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-size: .75rem;
  font-weight: 700;
}
.h6p-auth-languages button[aria-pressed='true'] { color: var(--brand); background: var(--brand-soft); }
.h6p-auth-languages button:not(:disabled):hover { color: var(--ink); background: var(--surface-2); }
.h6p-auth-dialog-heading { margin-bottom: var(--space-5); }
.h6p-auth-dialog-heading h1 {
  margin: 0;
  font-size: clamp(1.8rem, 3.5vw, 3rem);
  font-weight: 650;
  line-height: 1.16;
  letter-spacing: -.035em;
  text-wrap: balance;
}
.h6p-auth-dialog-heading p {
  margin: var(--space-2) 0 0;
  color: var(--muted);
  font-size: var(--type-small);
  line-height: 1.5;
}
.h6p-trial-steps { display: flex; gap: var(--space-3); list-style: none; margin: 0 0 var(--space-4); padding: 0; }
.h6p-trial-steps li {
  flex: 1;
  padding-top: var(--space-2);
  border-top: 2px solid var(--line);
  color: var(--muted);
  font-size: .75rem;
  font-weight: 650;
}
.h6p-trial-steps [aria-current='step'] { border-color: var(--brand); color: var(--brand); }
.customer-entry.customer-entry-signup {
  grid-template-columns: minmax(0, 452px);
  justify-content: center;
  max-inline-size: none;
  padding: clamp(var(--space-5), 5vh, var(--space-12)) var(--space-4);
}
.customer-entry-signup .h6p-auth-dialog { padding: clamp(22px, 5vw, 32px); }
.customer-entry-signup .h6p-trial-steps { margin: 0; }
.customer-entry-signup h1 { font-size: var(--type-display); line-height: 1.16; letter-spacing: -.035em; }
.customer-entry-signup .customer-entry-trial-details { border-block-start: 1px solid var(--line); }
.customer-entry-signup .customer-entry-trial-details summary {
  display: list-item;
  align-content: center;
  min-block-size: var(--target-min);
  cursor: pointer;
  font-weight: 650;
}
.customer-entry-signup .customer-entry-trial-details p { margin-block: var(--space-1) var(--space-3); }
.h6p-auth-dialog :is(.h6p-google-button, .h6p-email-toggle, .account-form .button) {
  display: inline-flex;
  width: 100%;
  min-height: 44px;
  padding: var(--space-2) var(--space-3);
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  border-radius: var(--radius-sm);
  font-size: var(--type-small);
  font-weight: 680;
}
.h6p-auth-dialog :is(.h6p-google-button, .h6p-email-toggle) {
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--line-strong);
}
.h6p-auth-dialog :is(.h6p-google-button, .h6p-email-toggle):not(:disabled):hover {
  background: var(--surface-hover);
  border-color: var(--control-line);
}
.h6p-auth-dialog .h6p-google-button,
.h6p-auth-dialog .h6p-google-button:not(:disabled):hover {
  gap: 10px;
  padding-inline: 12px;
  border: 1px solid #747775;
  background: #fff;
  color: #1f1f1f;
  font: 500 14px/20px 'Warraby Google Sans', sans-serif;
}
.h6p-auth-dialog .h6p-google-button:not(:disabled):hover { box-shadow: 0 1px 3px #1f1f1f30; }
.h6p-google-button img { width: 20px; height: 20px; flex: 0 0 20px; object-fit: contain; }
.h6p-email-guidance { margin-bottom: var(--space-3); }
.h6p-auth-dialog .h6p-email-toggle { justify-content: space-between; text-align: start; }
.h6p-auth-dialog .h6p-email-toggle[aria-expanded='true'] .chevron { transform: rotate(180deg); }
.h6p-auth-dialog .h6p-email-toggle + .h6p-email-panel { margin-top: var(--space-4); }
.h6p-auth-divider {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin: var(--space-4) 0;
  color: var(--muted);
  font-size: .75rem;
}
.h6p-auth-divider::before, .h6p-auth-divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.h6p-auth-dialog .account-form { display: grid; gap: var(--space-3); }
.h6p-auth-dialog .field { color: var(--ink); }
.h6p-auth-dialog .field input {
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--control-line);
  min-height: 44px;
  border-radius: var(--radius-sm);
  font-size: var(--type-body);
}
.h6p-auth-dialog .check-field {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  color: var(--muted);
  font-size: var(--type-small);
  min-height: 44px;
  padding: var(--space-2) 0;
}
.h6p-auth-dialog .check-field input { flex: 0 0 18px; width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--brand); }
.h6p-auth-dialog .account-feedback { margin: 0; color: var(--muted); font-size: var(--type-small); }
.h6p-auth-dialog .account-feedback:empty { display: none; }
.h6p-auth-dialog .account-feedback.error-text {
  margin-bottom: var(--space-2);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  color: var(--red);
  background: var(--red-soft);
}
.h6p-auth-dialog .account-panel.card { padding: 0; border: 0; background: transparent; box-shadow: none; }
.h6p-auth-recipient {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-4);
  padding: var(--space-3);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg);
  color: var(--ink);
  font-size: var(--type-small);
  overflow-wrap: anywhere;
}
.h6p-auth-recipient svg { flex: 0 0 18px; width: 18px; height: 18px; color: var(--muted); }
.h6p-auth-dialog input[name='code'] {
  min-height: 48px;
  letter-spacing: .24em;
  font-variant-numeric: tabular-nums;
  font-weight: 650;
}
.h6p-auth-help { margin-top: -4px; color: var(--muted); font-size: .75rem; }
.h6p-auth-announcement { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.h6p-auth-recovery, .h6p-auth-dialog-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0 var(--space-3);
}
.h6p-auth-recovery button, .h6p-auth-dialog-foot a, .h6p-auth-switch {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--brand);
  font-size: var(--type-small);
}
.h6p-auth-recovery button { justify-content: flex-start; padding: 0; text-align: start; }
.h6p-auth-dialog-foot { margin-top: var(--space-3); border-top: 1px solid var(--line); }
.h6p-auth-switch { margin: var(--space-2) 0; border: 0; background: none; padding: 0; }
.h6p-enroll-guidance { margin-bottom: var(--space-3); }
.h6p-auth-gate :is(a, button, input):focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; }
.h6p-auth-dialog input[aria-invalid='true'] { border-color: var(--red); }

@media (max-width: 767px) {
  .auth-utility { padding-block-start: max(var(--space-3), env(safe-area-inset-top)); }
  .h6p-auth-gate { padding-block-end: max(var(--space-4), env(safe-area-inset-bottom)); }
  .h6p-auth-frame { grid-template-columns: minmax(0,1fr); width:min(calc(100% - 2.5rem), 31rem); gap:1rem; margin-block-start:var(--space-6); }
  .h6p-auth-dialog-heading { margin-block-end:0; }
  .h6p-auth-dialog input:not([type='checkbox']) { font-size: 1rem; }
}

.auth-recipient-change { min-block-size: 44px; margin-bottom: var(--space-2); }

.h6p-email-panel {
 padding-block:var(--space-3);
}
