/* Premium account entry: calm, private, and unmistakably MyMappi. */
html body .auth-gate {
  padding: clamp(18px, 4vw, 52px) !important;
  color: #082f3a !important;
  background:
    linear-gradient(132deg, rgba(56, 203, 154, 0.2) 0 18%, transparent 18% 62%, rgba(64, 169, 222, 0.16) 62% 78%, transparent 78%),
    linear-gradient(180deg, #dff4ed 0%, #eef8f5 50%, #fbfaf5 100%) !important;
}

html body .auth-gate::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    repeating-linear-gradient(118deg, transparent 0 76px, rgba(10, 99, 102, 0.025) 76px 77px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.32), transparent 38% 68%, rgba(255, 255, 255, 0.22));
}

html body .auth-memory-path {
  border-color: rgba(8, 105, 112, 0.16) !important;
}

html body .auth-card {
  grid-template-columns: minmax(260px, 0.9fr) minmax(340px, 1.1fr) !important;
  grid-template-areas:
    "mascot form"
    "brand form"
    ". message"
    ". legal" !important;
  align-items: center !important;
  width: min(900px, 100%) !important;
  min-height: min(650px, calc(100dvh - 56px)) !important;
  gap: 10px 54px !important;
  padding: clamp(34px, 5vw, 64px) !important;
  overflow: hidden !important;
  border: 1px solid rgba(255, 255, 255, 0.78) !important;
  border-radius: 32px !important;
  text-align: left !important;
  background: rgba(251, 253, 249, 0.9) !important;
  box-shadow:
    0 34px 90px rgba(7, 73, 78, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.96) !important;
  backdrop-filter: blur(24px) saturate(1.08) !important;
  -webkit-backdrop-filter: blur(24px) saturate(1.08) !important;
}

html body .auth-card::before {
  content: "";
  position: absolute;
  inset: 0 51% 0 0;
  z-index: -1;
  border-right: 1px solid rgba(255, 255, 255, 0.56);
  background:
    linear-gradient(145deg, rgba(6, 55, 67, 0.96), rgba(7, 94, 87, 0.94) 56%, rgba(15, 125, 132, 0.92));
}

html body .auth-card.signup-mode,
html body .auth-card.verify-mode {
  width: min(900px, 100%) !important;
  gap: 10px 54px !important;
  padding: clamp(30px, 4vw, 56px) !important;
}

html body .auth-gate:has(.auth-card.signup-mode) {
  place-items: start center !important;
  overflow-y: auto !important;
}

html body .auth-card.signup-mode {
  min-height: 0 !important;
  gap: 6px 54px !important;
  padding: 28px 52px !important;
}

html body .auth-card.signup-mode .auth-gate-form {
  gap: 9px !important;
}

html body .auth-card.signup-mode .auth-gate-form input {
  min-height: 44px !important;
}

html body .auth-card.signup-mode .auth-form-heading {
  margin-bottom: 0 !important;
}

html body .auth-mappi,
html body .auth-card.signup-mode .auth-mappi {
  grid-area: mascot !important;
  align-self: end !important;
  justify-self: center !important;
  width: clamp(150px, 19vw, 210px) !important;
  height: clamp(150px, 19vw, 210px) !important;
  margin-bottom: 2px !important;
  border: 1px solid rgba(220, 255, 244, 0.12) !important;
  border-radius: 24px !important;
  object-fit: contain !important;
  filter: drop-shadow(0 22px 28px rgba(1, 28, 37, 0.28)) !important;
}

html body .auth-brand {
  grid-area: brand !important;
  align-self: start !important;
  justify-items: center !important;
  gap: 7px !important;
  color: #f5fffb !important;
  text-align: center !important;
}

html body .auth-brand-kicker {
  color: rgba(222, 255, 245, 0.7);
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

html body .auth-brand h1,
html body .auth-card.signup-mode .auth-brand h1 {
  display: inline-flex !important;
  align-items: baseline !important;
  margin: 0 !important;
  color: #f7fffc !important;
  font-size: clamp(2.65rem, 5vw, 4.15rem) !important;
  font-family: inherit !important;
  font-weight: 850 !important;
  line-height: 0.98 !important;
  letter-spacing: 0 !important;
  text-shadow: 0 10px 28px rgba(0, 25, 32, 0.22) !important;
}

html body .auth-brand-my {
  color: #f7fffc;
}

html body .auth-brand-second-m {
  color: #52dfa9;
}

html body .auth-brand-app {
  color: transparent;
  background: linear-gradient(90deg, #48d9b4, #48c8de 48%, #58a7f2);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

html body .auth-brand-i {
  position: relative;
  color: #71b4f4;
}

html body .auth-brand-i::after {
  content: "";
  position: absolute;
  top: -0.04em;
  left: 50%;
  width: 0.19em;
  height: 0.19em;
  border: 0.025em solid rgba(255, 255, 255, 0.92);
  border-radius: 50%;
  background: #f0525b;
  box-shadow: 0 5px 13px rgba(240, 82, 91, 0.32);
  transform: translateX(-50%);
}

html body .auth-brand p {
  margin: 0 !important;
  color: rgba(244, 255, 251, 0.92) !important;
  font-size: 1rem !important;
  font-weight: 760 !important;
}

html body .auth-brand-promise {
  color: rgba(220, 250, 242, 0.66);
  font-size: 0.78rem;
  font-weight: 650;
}

html body .auth-gate-form,
html body .auth-verification-panel {
  grid-area: form !important;
  align-self: center !important;
  width: 100% !important;
  max-width: 410px !important;
  justify-self: center !important;
}

html body .auth-gate-form {
  display: grid !important;
  gap: 14px !important;
  max-height: none !important;
  padding: 0 !important;
  overflow: visible !important;
  text-align: left !important;
}

html body .auth-gate-form.hidden,
html body .auth-verification-panel.hidden {
  display: none !important;
}

html body .auth-form-heading {
  display: grid;
  gap: 5px;
  margin-bottom: 4px;
  text-align: left;
}

html body .auth-form-heading strong {
  color: #092f39;
  font-size: clamp(1.55rem, 3vw, 2rem);
  font-weight: 850;
  line-height: 1.1;
}

html body .auth-form-heading span {
  color: rgba(8, 47, 57, 0.58);
  font-size: 0.88rem;
  font-weight: 620;
  line-height: 1.45;
}

html body .auth-gate-form label {
  gap: 7px !important;
  color: rgba(8, 47, 57, 0.68) !important;
  font-size: 0.72rem !important;
  font-weight: 820 !important;
}

html body .auth-gate-form input {
  min-height: 50px !important;
  padding: 0 15px !important;
  border: 1px solid rgba(8, 98, 99, 0.14) !important;
  border-radius: 13px !important;
  color: #082f3a !important;
  font-size: 1rem !important;
  background: rgba(255, 255, 255, 0.78) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9) !important;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease !important;
}

html body .auth-gate-form input:focus {
  border-color: rgba(18, 163, 137, 0.62) !important;
  background: #fff !important;
  box-shadow: 0 0 0 4px rgba(49, 194, 154, 0.12) !important;
}

html body .auth-gate-form .account-auth-actions {
  display: grid !important;
  grid-template-columns: 1fr 1fr !important;
  gap: 10px !important;
  margin-top: 2px !important;
}

html body .auth-gate .account-auth-button {
  min-height: 48px !important;
  border: 1px solid rgba(8, 89, 91, 0.14) !important;
  border-radius: 13px !important;
  color: #0a4852 !important;
  font-size: 0.92rem !important;
  font-weight: 820 !important;
  background: rgba(244, 250, 247, 0.92) !important;
  box-shadow: 0 7px 18px rgba(7, 73, 78, 0.06) !important;
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 160ms ease, filter 160ms ease !important;
}

html body .auth-gate .account-auth-button.primary {
  color: #f7fffc !important;
  border-color: rgba(19, 133, 119, 0.26) !important;
  background: linear-gradient(112deg, #087e78, #159f8b 54%, #168ead) !important;
  box-shadow: 0 13px 28px rgba(11, 126, 117, 0.2) !important;
}

html body .auth-gate .account-auth-button:hover,
html body .auth-gate .account-auth-button:focus-visible {
  filter: brightness(1.03);
  transform: translateY(-1px);
}

html body .auth-gate button:focus-visible,
html body .auth-gate a:focus-visible {
  outline: 3px solid rgba(40, 184, 155, 0.25) !important;
  outline-offset: 3px !important;
}

html body .auth-text-button {
  width: max-content;
  min-height: 30px;
  padding: 2px 0;
  border: 0;
  color: #0b776f;
  font: inherit;
  font-size: 0.76rem;
  font-weight: 780;
  text-decoration: none;
  background: transparent;
  cursor: pointer;
}

html body #authForgotPasswordButton {
  justify-self: end;
  margin-top: -9px;
}

html body .auth-local-divider {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 10px;
  color: rgba(8, 47, 57, 0.36);
  font-size: 0.7rem;
  font-weight: 760;
}

html body .auth-local-divider::before,
html body .auth-local-divider::after {
  content: "";
  height: 1px;
  background: rgba(8, 89, 91, 0.1);
}

html body .auth-local-option {
  display: grid;
  justify-items: center;
  gap: 3px;
  text-align: center;
}

html body .auth-gate-form .auth-local-option .local-device-button {
  width: auto !important;
  min-height: 30px !important;
  margin: 0 !important;
  padding: 2px 6px !important;
  border: 0 !important;
  color: #0b6e69 !important;
  font-size: 0.8rem !important;
  background: transparent !important;
  box-shadow: none !important;
}

html body .auth-local-option > span {
  color: rgba(8, 47, 57, 0.48);
  font-size: 0.68rem;
  font-weight: 620;
  line-height: 1.35;
}

html body .auth-verification-panel {
  display: grid;
  justify-items: stretch;
  gap: 14px;
  text-align: left;
}

html body .auth-verification-mark {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  margin-bottom: 3px;
  border: 1px solid rgba(26, 167, 139, 0.2);
  border-radius: 16px;
  background: linear-gradient(145deg, rgba(73, 215, 170, 0.2), rgba(82, 173, 224, 0.16));
}

html body .auth-verification-mark span {
  position: relative;
  width: 24px;
  height: 17px;
  border: 2px solid #0b8b7d;
  border-radius: 4px;
}

html body .auth-verification-mark span::before,
html body .auth-verification-mark span::after {
  content: "";
  position: absolute;
  width: 14px;
  height: 2px;
  background: #0b8b7d;
  transform-origin: left center;
}

html body .auth-verification-mark span::before {
  transform: translate(1px, 1px) rotate(34deg);
}

html body .auth-verification-mark span::after {
  transform: translate(21px, 1px) rotate(146deg);
}

html body .auth-verification-email {
  overflow: hidden;
  color: #08756c;
  font-size: 0.96rem;
  font-weight: 820;
  text-overflow: ellipsis;
  white-space: nowrap;
}

html body .auth-verification-panel p {
  margin: -3px 0 2px;
  color: rgba(8, 47, 57, 0.62);
  font-size: 0.82rem;
  font-weight: 620;
  line-height: 1.5;
}

html body .auth-verification-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

html body .auth-verification-actions button:disabled {
  opacity: 0.5;
  cursor: default;
}

html body .auth-card > .account-auth-message {
  grid-area: message !important;
  min-height: 20px !important;
  margin: 2px 0 0 !important;
  color: rgba(8, 47, 57, 0.6) !important;
  font-size: 0.74rem !important;
  font-weight: 650 !important;
  line-height: 1.4 !important;
  text-align: center !important;
}

html body .auth-card > .account-auth-message.error {
  color: #b42318 !important;
}

html body .auth-card > .auth-legal-links {
  grid-area: legal !important;
  margin-top: 0 !important;
}

@media (max-width: 760px) {
  html body .auth-gate {
    place-items: start center !important;
    min-height: 100dvh !important;
    padding: max(12px, env(safe-area-inset-top)) 10px max(12px, env(safe-area-inset-bottom)) !important;
    overflow-y: auto !important;
  }

  html body .auth-card,
  html body .auth-card.signup-mode,
  html body .auth-card.verify-mode {
    grid-template-columns: 74px minmax(0, 1fr) !important;
    grid-template-areas:
      "mascot brand"
      "form form"
      "message message"
      "legal legal" !important;
    width: min(100%, 430px) !important;
    min-height: 0 !important;
    max-height: none !important;
    gap: 18px 12px !important;
    padding: 18px 16px 16px !important;
    overflow: visible !important;
    border-radius: 25px !important;
  }

  html body .auth-card::before {
    inset: 0 0 auto 0 !important;
    height: 104px !important;
    border-right: 0 !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.34) !important;
  }

  html body .auth-mappi,
  html body .auth-card.signup-mode .auth-mappi {
    align-self: center !important;
    width: 70px !important;
    height: 70px !important;
    margin: 0 !important;
    border-radius: 18px !important;
  }

  html body .auth-brand {
    align-self: center !important;
    justify-items: start !important;
    gap: 3px !important;
    text-align: left !important;
  }

  html body .auth-brand-kicker,
  html body .auth-brand-promise {
    display: none;
  }

  html body .auth-brand h1,
  html body .auth-card.signup-mode .auth-brand h1 {
    font-size: clamp(2.1rem, 11vw, 2.9rem) !important;
  }

  html body .auth-brand p {
    font-size: 0.78rem !important;
  }

  html body .auth-gate-form,
  html body .auth-verification-panel {
    width: 100% !important;
    max-width: none !important;
  }

  html body .auth-gate-form {
    gap: 11px !important;
  }

  html body .auth-form-heading strong {
    font-size: 1.45rem;
  }

  html body .auth-gate-form input {
    min-height: 46px !important;
  }

  html body .auth-gate-form .account-auth-actions {
    grid-template-columns: 1fr 1fr !important;
  }

  html body .auth-gate .account-auth-button {
    min-height: 46px !important;
    font-size: 0.85rem !important;
  }

  html body .auth-card > .account-auth-message {
    margin-top: -3px !important;
  }
}

@media (max-width: 390px) {
  html body .auth-gate-form .account-auth-actions {
    grid-template-columns: 1fr !important;
  }

  html body .auth-verification-actions {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html body .auth-gate *,
  html body .auth-gate *::before,
  html body .auth-gate *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
