/* Bark & Style public authentication dialog. */
#landing-auth-modal .registration-privacy { display: flex; align-items: flex-start; gap: 10px; margin: 16px 0; }
#landing-auth-modal .registration-privacy input { flex: 0 0 18px; width: 18px; height: 18px; margin: 3px 0 0; accent-color: var(--primary); }
#landing-auth-modal .registration-privacy label { display: block; margin: 0; font-size: 14px; font-weight: 400; line-height: 1.55; color: var(--muted-foreground); text-transform: none; letter-spacing: normal; cursor: pointer; }
#landing-auth-modal .registration-privacy a { color: var(--foreground); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
#landing-auth-modal .registration-privacy-error { margin: 6px 0 0; }
#landing-auth-modal .registration-privacy-error[hidden] { display: none; }
#landing-auth-modal .registration-privacy input:focus-visible { outline: 3px solid var(--primary); outline-offset: 3px; }
/* Customer-only addition. Existing email/password and registration controls keep their styling. */
#landing-auth-modal #customer-google-login-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 12px;
  border: 1px solid var(--border);
  color: var(--foreground);
  background: var(--card);
  box-shadow: none;
}
#landing-auth-modal #customer-google-login-btn:hover { background: var(--muted); }
#landing-auth-modal #customer-google-login-btn svg { flex: 0 0 20px; }
#landing-auth-modal #cust-google [hidden] { display: none; }
#landing-auth-modal .google-auth-email { margin: 0 0 16px; overflow-wrap: anywhere; font-weight: 700; }
#landing-auth-modal .google-auth-back {
  padding: 8px 4px;
  border: 0;
  background: transparent;
  color: var(--blue);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}
#landing-auth-modal #cust-google button:disabled { opacity: .6; cursor: wait; }
@media (max-width: 680px) {
  #screen-auth .landing-page .landing-topbar-actions .landing-link-btn {
    display: inline-flex;
  }
}

#landing-auth-modal {
  font-family: var(--font-body);
  color: var(--foreground);
  line-height: 1.7;
  padding: 24px;
  overflow-y: auto;
  background: oklch(25% .025 232 / .45);
}

#landing-auth-modal .auth-panel {
  width: min(100%, 500px);
  max-width: 500px;
  min-height: 0;
  max-height: calc(100vh - 48px);
  justify-content: flex-start;
  padding: 34px 36px 32px;
  overflow-y: auto;
  border: 0;
  border-radius: 12px;
  background: var(--card);
  box-shadow: 0 20px 60px #192d3b1a;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}

#landing-auth-modal .auth-panel::after { display: none; }

#landing-auth-modal.show .auth-panel {
  animation: auth-panel-enter 180ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

@keyframes auth-panel-enter {
  from { opacity: 0; transform: translateY(8px) scale(0.985); }
  to { opacity: 1; transform: none; }
}

#landing-auth-modal .landing-auth-modal-close {
  top: 18px;
  right: 18px;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 6px;
  background: var(--muted);
  color: var(--muted-foreground);
  box-shadow: none;
  transition: background 160ms ease, color 160ms ease;
}

#landing-auth-modal .landing-auth-modal-close:hover {
  color: var(--blue);
  background: var(--secondary);
}

#landing-auth-modal .landing-auth-modal-close:focus-visible,
#landing-auth-modal button:focus-visible,
#landing-auth-modal a:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}

#landing-auth-modal .auth-brand {
  min-height: 52px;
  margin: 0 52px 26px 0;
}

#landing-auth-modal .auth-brand-logo {
  display: block;
  width: 76px;
  height: auto;
  object-fit: contain;
}

#landing-auth-modal .auth-heading {
  margin: 0 0 7px;
  color: var(--foreground);
  font-family: var(--font-heading);
  font-size: 28px;
  font-weight: 850;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

#landing-auth-modal .auth-sub {
  max-width: 360px;
  margin: 0 0 25px;
  color: var(--muted-foreground);
  font-size: 14px;
  line-height: 1.7;
}

#landing-auth-modal .auth-form-body { width: 100%; }

#landing-auth-modal:has(#cust-login.active) .auth-sub { max-width: none; }

.account-name-error { display: block; margin-top: 6px; color: #a52f20; font-size: 11px; line-height: 1.35; }
.account-name-error[hidden] { display: none; }
.account-name-invalid { border-color: #d94a32 !important; box-shadow: 0 0 0 3px rgba(217, 74, 50, 0.08) !important; }
#landing-auth-modal .frow { gap: 12px; }
#landing-auth-modal .fgroup { margin-bottom: 15px; }

#landing-auth-modal #cust-login .fgroup:has(+ .btn-auth),
#landing-auth-modal #cust-register .fgroup:has(+ .btn-auth) {
  margin-bottom: 24px;
}

#landing-auth-modal .fgroup label {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 7px;
  color: var(--foreground);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: none;
}

#landing-auth-modal .auth-optional {
  color: var(--muted-foreground);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
}

#landing-auth-modal .fgroup input,
#landing-auth-modal .fgroup select {
  min-height: 48px;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--foreground);
  background: var(--card);
  box-shadow: none;
}

#landing-auth-modal .fgroup input::placeholder { color: var(--muted-foreground); }

#landing-auth-modal .fgroup input:hover,
#landing-auth-modal .fgroup select:hover {
  border-color: var(--muted-foreground);
  background: var(--card);
}

#landing-auth-modal .fgroup input:focus,
#landing-auth-modal .fgroup select:focus {
  border-color: var(--blue);
  background: var(--card);
  box-shadow: 0 0 0 3px color-mix(in oklch, var(--blue) 14%, transparent);
}

#landing-auth-modal .password-toggle {
  right: 7px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
}

#landing-auth-modal .password-toggle:hover {
  color: var(--blue);
  background: var(--secondary);
}

#landing-auth-modal .btn-auth,
#landing-auth-modal .auth-otp-verify-btn {
  min-height: 48px;
  padding: 12px 18px;
  border: 0;
  border-radius: 6px;
  color: var(--primary-foreground);
  background: var(--primary);
  box-shadow: var(--shadow);
  font-size: 14px;
  font-weight: 500;
  transition: transform 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

#landing-auth-modal .btn-auth:hover,
#landing-auth-modal .auth-otp-verify-btn:hover {
  background: color-mix(in oklch, var(--primary) 90%, transparent);
}

#landing-auth-modal .btn-auth:disabled,
#landing-auth-modal .auth-otp-verify-btn:disabled {
  cursor: not-allowed;
  opacity: 0.58;
  transform: none;
  box-shadow: none;
}

#landing-auth-modal .auth-switch {
  margin-top: 13px;
  color: var(--muted-foreground);
  font-size: 13px;
  line-height: 1.7;
}

#landing-auth-modal .auth-switch a {
  color: var(--blue);
  font-weight: 700;
  text-underline-offset: 3px;
}

#landing-auth-modal .auth-switch a:hover { text-decoration: underline; }
#landing-auth-modal .auth-recovery-link { margin: 0; text-align: right; }
#landing-auth-modal .auth-privacy { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--border); font-size: 11px; }

#landing-auth-modal .msg-error {
  margin-bottom: 15px;
  padding: 10px 12px;
  border: 0;
  border-radius: 10px;
  color: #a52f20;
  background: #fff0ed;
  font-size: 12px;
  line-height: 1.45;
}

/* Verification stays inside same calm surface. */
#landing-auth-modal .auth-otp-stage { margin: 0; }

#landing-auth-modal .auth-otp-card {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

#landing-auth-modal .auth-otp-hero {
  width: 48px;
  height: 48px;
  margin: 0 auto 16px;
  border-radius: 8px;
  color: var(--blue);
  background: var(--secondary);
  box-shadow: none;
  font-size: 18px;
}

#landing-auth-modal .auth-otp-card-title {
  margin-bottom: 7px;
  color: var(--foreground);
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 900;
  letter-spacing: -0.025em;
}

#landing-auth-modal .auth-otp-card-copy {
  margin-bottom: 20px;
  color: var(--muted-foreground);
  font-size: 13px;
  line-height: 1.55;
}

#landing-auth-modal .auth-otp-inline {
  margin-bottom: 14px;
  font-size: 12px;
}

#landing-auth-modal .auth-otp-inline-left {
  color: var(--foreground);
  font-size: 12px;
}

#landing-auth-modal .auth-otp-inline-left strong,
#landing-auth-modal .auth-otp-inline-right { color: var(--blue); }
#landing-auth-modal .auth-otp-inline-right { font-size: 12px; }

#landing-auth-modal .auth-otp-digits {
  gap: 8px;
  margin-bottom: 16px;
}

#landing-auth-modal .auth-otp-digit {
  height: 52px;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--foreground);
  background: var(--card);
  font-size: 22px;
}

#landing-auth-modal .auth-otp-digit:focus {
  border-color: var(--blue);
  background: var(--card);
  box-shadow: 0 0 0 3px color-mix(in oklch, var(--blue) 14%, transparent);
}

#landing-auth-modal .auth-otp-link {
  color: var(--muted-foreground);
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
}

#landing-auth-modal .auth-otp-link:hover { color: var(--blue); }

#landing-auth-modal #auth-otp-message .auth-otp-email,
#landing-auth-modal #auth-otp-message .auth-otp-email a,
#landing-auth-modal #auth-otp-message a[x-apple-data-detectors] {
  color: inherit;
  text-decoration: none !important;
  pointer-events: none;
  cursor: text;
}

#landing-auth-modal .otp-auth-meta {
  color: var(--muted-foreground);
  font-size: 11px;
  line-height: 1.45;
}

@media (max-width: 560px) {
  #landing-auth-modal {
    align-items: center;
    padding: 12px;
  }

  #landing-auth-modal .auth-panel {
    width: 100%;
    max-height: calc(100dvh - 24px);
    padding: 28px 22px 24px;
    border-radius: 12px;
  }

  #landing-auth-modal .auth-brand { margin-bottom: 22px; }
  #landing-auth-modal .auth-brand-logo { width: 68px; }
  #landing-auth-modal .auth-heading { font-size: 25px; }
  #landing-auth-modal .frow { display: block; }
  #landing-auth-modal .fgroup input { font-size: 16px; }
  #landing-auth-modal .auth-otp-digits { gap: 5px; }

  #landing-auth-modal .auth-otp-digit {
    height: 46px;
    border-radius: 9px;
    font-size: 19px;
  }
}

@media (max-width: 560px) and (max-height: 700px) {
  #landing-auth-modal .auth-panel {
    padding: 20px;
  }

  #landing-auth-modal .auth-brand {
    min-height: 44px;
    margin-bottom: 14px;
  }

  #landing-auth-modal .auth-brand-logo { width: 60px; }
  #landing-auth-modal .auth-heading { font-size: 23px; }
  #landing-auth-modal .auth-sub { margin-bottom: 18px; }
  #landing-auth-modal .fgroup { margin-bottom: 11px; }

  #landing-auth-modal .fgroup input,
  #landing-auth-modal .fgroup select,
  #landing-auth-modal .btn-auth {
    min-height: 44px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #landing-auth-modal.show .auth-panel { animation: none; }

  #landing-auth-modal .btn-auth,
  #landing-auth-modal .auth-otp-verify-btn { transition: none; }
}

/* Shared email/password sign-in serves Customer, Owner, and Staff. */
#landing-auth-modal .auth-login-options { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
#landing-auth-modal label.auth-remember { display: flex; align-items: center; gap: 8px; margin: 0; font: inherit; font-size: 13px; font-weight: 400; text-transform: none; letter-spacing: normal; cursor: pointer; }
#landing-auth-modal .auth-remember input { flex: 0 0 auto; width: 16px; height: 16px; margin: 0; accent-color: var(--primary); }
