/* Account modal forms (views/overrides/lh-account-modal.liquid), on top of the theme's
   lh-account-modal.css dialog. Tokens only. */
.lh-amx { max-width: 28rem; }
.lh-amx__panel { align-items: stretch; text-align: left; }
.lh-amx__panel .lh-am__lead { align-self: center; text-align: center; }
.lh-amx__form { display: grid; gap: var(--space-4); }
.lh-amx__row { display: grid; gap: var(--space-4); }
@media (min-width: 420px) { .lh-amx__row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.lh-amx__form .lh-field { min-width: 0; }

.lh-amx__link {
  justify-self: start; padding: 0; background: none; border: 0; cursor: pointer;
  font: inherit; font-size: var(--font-body-sm); color: var(--text-link); text-decoration: underline; text-underline-offset: 3px;
}
.lh-amx__link:hover { color: var(--color-primary-hover); }
.lh-amx__forgot { justify-self: end; margin-top: calc(var(--space-2) * -1); }
.lh-amx__form .lh-amx__link:last-child { justify-self: center; }

.lh-amx__check { display: flex; gap: var(--space-2); align-items: flex-start; font-size: var(--font-body-sm); color: var(--text-body); cursor: pointer; }
.lh-amx__check input { width: 18px; height: 18px; margin: 1px 0 0; accent-color: var(--color-primary); flex-shrink: 0; }

.lh-amx__msg { margin: 0; font-size: var(--font-body-sm); color: var(--color-error); }
.lh-amx__msg.is-ok { color: var(--color-instock); }
.lh-amx__msg[hidden] { display: none; }

/* "Continue with Google": Google draws its own button inside the slot. */
.lh-amx__google { display: grid; gap: var(--space-4); margin-bottom: var(--space-4); }
.lh-amx__google-btn { display: flex; justify-content: center; min-height: 44px; }
.lh-amx__or {
  display: flex; align-items: center; gap: var(--space-3); margin: 0;
  font-size: var(--font-caption); color: var(--text-subtle); text-transform: uppercase; letter-spacing: var(--tracking-overline);
}
.lh-amx__or::before, .lh-amx__or::after { content: ''; flex: 1; height: 1px; background: var(--border-subtle); }
.lh-amx[data-view="recover"] .lh-amx__google,
.lh-amx[data-view="recover"] .lh-am__tabs { display: none; }

/* Phones: the dialog becomes a bottom sheet that fills the width, easier to reach with a thumb. */
@media (max-width: 559px) {
  .lh-am:has(.lh-amx) { align-items: flex-end; padding: 0; }
  .lh-am .lh-amx {
    max-width: none; max-height: calc(100dvh - var(--space-8)); border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    padding: var(--space-6) var(--space-5) calc(var(--space-6) + env(safe-area-inset-bottom));
    transform: translateY(24px);
  }
  .lh-am.is-open .lh-amx { transform: none; }
  .lh-am .lh-amx .lh-am__crest { display: none; }
}

/* "Don't have an account? Sign up" / "Already have an account? Sign in" under each form. */
.lh-amx__switch { margin: var(--space-4) 0 0; text-align: center; font-size: var(--font-body-sm); color: var(--text-muted); }
