:root {
  color-scheme: dark;
  --mto-red: #e62b3b;
  --mto-red-bright: #ff3f58;
  --mto-red-deep: #b9162e;
  --mto-purple: #6e3fc0;
  --mto-green: #a8d76f;
  --mto-noir: #121218;
  --mto-surface: #1c1c25;
  --mto-surface-raised: #24242f;
  --mto-surface-soft: rgb(255 255 255 / 0.055);
  --mto-border: rgb(255 255 255 / 0.12);
  --mto-border-strong: rgb(255 255 255 / 0.22);
  --mto-text: #fff;
  --mto-text-soft: rgb(255 255 255 / 0.72);
  --mto-text-faint: rgb(255 255 255 / 0.52);
  --mto-focus: rgb(255 63 88 / 0.42);
  --mto-danger-soft: rgb(230 43 59 / 0.14);
  --mto-success: #54d68b;
  --mto-success-soft: rgb(84 214 139 / 0.13);
  --mto-info: #71bcea;
  --mto-info-soft: rgb(113 188 234 / 0.13);
  --mto-warning: #ffb24c;
  --mto-warning-soft: rgb(255 178 76 / 0.13);
  --mto-header-height: 68px;
  --mto-radius-card: 20px;
  --mto-radius-control: 10px;
  --mto-shadow-card: 0 24px 70px rgb(0 0 0 / 0.48);
  --mto-font: ui-rounded, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--mto-noir);
  text-size-adjust: 100%;
  -webkit-text-size-adjust: 100%;
}

body.mto-auth-body {
  min-width: 280px;
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0;
  overflow-x: hidden;
  color: var(--mto-text);
  background:
    radial-gradient(circle at 10% 8%, rgb(230 43 59 / 0.18), transparent 30rem),
    radial-gradient(circle at 92% 22%, rgb(110 63 192 / 0.18), transparent 34rem),
    var(--mto-noir);
  font-family: var(--mto-font);
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.005em;
}

.mto-auth-backdrop {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.mto-auth-backdrop::before {
  position: absolute;
  inset: -80px;
  background-image:
    radial-gradient(circle, rgb(230 43 59 / 0.14) 0 6px, transparent 7px),
    radial-gradient(circle, rgb(255 255 255 / 0.025) 0 2px, transparent 3px);
  background-position: 0 0, 36px 36px;
  background-size: 72px 72px;
  content: "";
  opacity: 0.72;
  animation: mto-dots-drift 70s linear infinite;
}

.mto-auth-backdrop::after {
  position: absolute;
  inset: 12% auto auto 50%;
  width: min(76vw, 860px);
  height: min(76vw, 860px);
  border: 1px solid rgb(255 255 255 / 0.035);
  border-radius: 50%;
  box-shadow:
    0 0 0 72px rgb(255 255 255 / 0.012),
    0 0 0 144px rgb(230 43 59 / 0.012);
  content: "";
  transform: translateX(-50%);
}

@keyframes mto-dots-drift {
  from {
    transform: translate3d(0, 0, 0);
  }
  to {
    transform: translate3d(144px, 72px, 0);
  }
}

a {
  color: inherit;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
summary,
a {
  -webkit-tap-highlight-color: transparent;
}

[hidden] {
  display: none !important;
}

.is-hidden {
  display: none !important;
}

.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* Shared lightweight site header */
.mto-site-header {
  position: relative;
  z-index: 40;
  min-height: var(--mto-header-height);
  border-bottom: 1px solid rgb(255 255 255 / 0.08);
  background: rgb(18 18 24 / 0.82);
  box-shadow: 0 8px 32px rgb(0 0 0 / 0.18);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.mto-site-header__inner {
  width: min(1180px, calc(100% - 32px));
  min-height: var(--mto-header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin: 0 auto;
}

.mto-site-brand {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--mto-text);
  font-size: 18px;
  font-weight: 850;
  letter-spacing: 0.015em;
  text-decoration: none;
}

.mto-site-brand > span:last-child {
  overflow-wrap: anywhere;
}

.mto-site-brand:hover {
  color: #fff;
}

.mto-site-brand:focus-visible,
.mto-site-nav__link:focus-visible,
.mto-language__summary:focus-visible,
.mto-language__menu a:focus-visible,
.mto-nav-toggle:focus-visible {
  outline: 3px solid var(--mto-focus);
  outline-offset: 3px;
  border-radius: 8px;
}

.mto-nav-disclosure {
  min-width: 0;
}

.mto-nav-toggle {
  display: none;
}

.mto-site-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
}

.mto-site-nav__link {
  position: relative;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border-radius: 9px;
  color: var(--mto-text-soft);
  font-size: 14px;
  font-weight: 750;
  text-align: center;
  text-decoration: none;
  overflow-wrap: anywhere;
  transition: color 160ms ease, background 160ms ease;
}

.mto-site-nav__link:hover {
  color: #fff;
  background: rgb(255 255 255 / 0.065);
}

.mto-site-nav__link[aria-current="page"] {
  color: #fff;
  background: rgb(230 43 59 / 0.14);
}

.mto-site-nav__link[aria-current="page"]::after {
  position: absolute;
  right: 12px;
  bottom: 3px;
  left: 12px;
  height: 2px;
  border-radius: 2px;
  background: var(--mto-red);
  content: "";
}

.mto-language {
  position: relative;
  margin-inline-start: 4px;
}

.mto-language > summary,
.mto-nav-disclosure > summary {
  list-style: none;
}

.mto-language > summary::-webkit-details-marker,
.mto-nav-disclosure > summary::-webkit-details-marker {
  display: none;
}

.mto-language__summary {
  min-height: 40px;
  max-width: 170px;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 10px;
  border: 1px solid var(--mto-border);
  border-radius: 9px;
  color: var(--mto-text-soft);
  font-size: 13px;
  font-weight: 750;
  cursor: pointer;
  user-select: none;
}

.mto-language__summary:hover,
.mto-language[open] .mto-language__summary {
  color: #fff;
  border-color: var(--mto-border-strong);
  background: rgb(255 255 255 / 0.06);
}

.mto-language__summary svg {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
}

.mto-language__summary span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mto-language__menu {
  position: absolute;
  top: calc(100% + 10px);
  inset-inline-end: 0;
  width: min(250px, calc(100vw - 28px));
  max-height: min(440px, calc(100vh - 100px));
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 3px;
  padding: 9px;
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--mto-border);
  border-radius: 13px;
  background: #24242f;
  box-shadow: 0 20px 55px rgb(0 0 0 / 0.55);
}

.mto-language__menu a {
  min-width: 0;
  padding: 9px 10px;
  border-radius: 8px;
  color: var(--mto-text-soft);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.25;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.mto-language__menu a:hover,
.mto-language__menu a[aria-current="true"] {
  color: #fff;
  background: rgb(255 255 255 / 0.08);
}

.mto-language__menu a[aria-current="true"] {
  box-shadow: inset 3px 0 0 var(--mto-red);
}

[dir="rtl"] .mto-language__menu a[aria-current="true"] {
  box-shadow: inset -3px 0 0 var(--mto-red);
}

/* Ladybug brand mark — ported from secret/player.php loading spinner */
.mto-ladybug {
  --ladybug-size: 34px;
  position: relative;
  width: var(--ladybug-size);
  height: var(--ladybug-size);
  flex: 0 0 var(--ladybug-size);
  display: inline-block;
  border: max(2px, calc(var(--ladybug-size) * 0.047)) solid #000;
  border-radius: 50%;
  background: radial-gradient(circle, #d50000 0, #b71c1c 70%);
  box-shadow: 0 2px 10px rgb(0 0 0 / 0.45);
}

.mto-ladybug__dot {
  --ladybug-dot: calc(var(--ladybug-size) * 0.25);
  position: absolute;
  width: var(--ladybug-dot);
  height: var(--ladybug-dot);
  border-radius: 50%;
  background: #000;
}

.mto-ladybug__dot--center {
  --ladybug-dot: calc(var(--ladybug-size) * 0.3);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.mto-ladybug__dot--tl {
  top: 12%;
  left: 12%;
}

.mto-ladybug__dot--tr {
  top: 12%;
  right: 12%;
}

.mto-ladybug__dot--bl {
  bottom: 12%;
  left: 12%;
}

.mto-ladybug__dot--br {
  right: 12%;
  bottom: 12%;
}

@keyframes mto-ladybug-dot-wave {
  0%, 25%, 100% { transform: scale(1); }
  12%           { transform: scale(1.35); }
}

@keyframes mto-ladybug-dot-wave-center {
  0%, 25%, 100% { transform: translate(-50%, -50%) scale(1); }
  12%           { transform: translate(-50%, -50%) scale(1.25); }
}

.mto-site-brand:hover .mto-ladybug .mto-ladybug__dot:not(.mto-ladybug__dot--center),
.auth-brand .mto-ladybug:hover .mto-ladybug__dot:not(.mto-ladybug__dot--center) {
  animation: mto-ladybug-dot-wave 1.2s ease-in-out infinite;
}

.mto-site-brand:hover .mto-ladybug .mto-ladybug__dot--center,
.auth-brand .mto-ladybug:hover .mto-ladybug__dot--center {
  animation: mto-ladybug-dot-wave-center 1.2s ease-in-out infinite;
}

.mto-site-brand:hover .mto-ladybug .mto-ladybug__dot--tl,
.auth-brand .mto-ladybug:hover .mto-ladybug__dot--tl { animation-delay: 0s; }

.mto-site-brand:hover .mto-ladybug .mto-ladybug__dot--tr,
.auth-brand .mto-ladybug:hover .mto-ladybug__dot--tr { animation-delay: 0.15s; }

.mto-site-brand:hover .mto-ladybug .mto-ladybug__dot--bl,
.auth-brand .mto-ladybug:hover .mto-ladybug__dot--bl { animation-delay: 0.25s; }

.mto-site-brand:hover .mto-ladybug .mto-ladybug__dot--br,
.auth-brand .mto-ladybug:hover .mto-ladybug__dot--br { animation-delay: 0.35s; }

.mto-site-brand:hover .mto-ladybug {
  transform: rotate(-7deg) scale(1.04);
}

.mto-site-brand .mto-ladybug {
  transition: transform 180ms ease;
}

/* Main auth surface */
.mto-auth-main {
  width: 100%;
  min-height: calc(100vh - var(--mto-header-height));
  min-height: calc(100dvh - var(--mto-header-height));
  display: flex;
  align-items: center;
  justify-content: center;
  padding:
    clamp(28px, 6vh, 72px)
    max(16px, env(safe-area-inset-right))
    max(32px, env(safe-area-inset-bottom))
    max(16px, env(safe-area-inset-left));
}

.auth-card,
.mto-auth-card {
  position: relative;
  width: min(100%, 430px);
  min-width: 0;
  padding: clamp(24px, 4.5vw, 36px);
  overflow: hidden;
  border: 1px solid var(--mto-border);
  border-radius: var(--mto-radius-card);
  background:
    linear-gradient(145deg, rgb(255 255 255 / 0.025), transparent 34%),
    var(--mto-surface);
  box-shadow: var(--mto-shadow-card);
}

.auth-card::before,
.mto-auth-card::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--mto-red-deep), var(--mto-red-bright), var(--mto-purple));
  content: "";
}

.auth-card--wide,
.mto-auth-card--wide,
.mto-auth-body.auth-layout--wide .auth-card,
.mto-auth-body.auth-layout--wide .mto-auth-card {
  width: min(100%, 590px);
}

.mto-auth-body.auth-layout--profile .auth-card,
.mto-auth-body.auth-layout--profile .mto-auth-card {
  width: min(100%, 680px);
}

html.mto-js body.mto-ui-pending .auth-card,
html.mto-js body.mto-ui-pending .mto-auth-card {
  opacity: 0;
  transform: translateY(12px) scale(0.99);
}

html.mto-js body.mto-ui-ready .auth-card,
html.mto-js body.mto-ui-ready .mto-auth-card {
  opacity: 1;
  transform: none;
  transition:
    opacity 360ms ease,
    transform 460ms cubic-bezier(0.22, 1, 0.36, 1);
}

.auth-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 0 0 24px;
  text-align: center;
}

.auth-brand .mto-ladybug {
  --ladybug-size: 58px;
  margin-bottom: 14px;
  cursor: pointer;
  transition: transform 180ms ease;
}

.auth-brand .mto-ladybug:hover {
  transform: rotate(-7deg) scale(1.05);
}

.auth-brand h1 {
  max-width: 100%;
  margin: 0;
  color: #fff;
  font-size: clamp(24px, 6vw, 32px);
  font-weight: 850;
  line-height: 1.13;
  letter-spacing: -0.018em;
  overflow-wrap: anywhere;
}

.auth-brand .auth-subtitle {
  max-width: 42rem;
  margin: 7px 0 0;
  color: var(--mto-text-soft);
  font-size: 14px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.brand {
  margin: 0 0 6px;
  color: var(--mto-red-bright);
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.auth-card > h1,
.mto-auth-card > h1 {
  margin: 0 0 8px;
  color: #fff;
  font-size: clamp(25px, 6vw, 34px);
  line-height: 1.14;
  overflow-wrap: anywhere;
}

.lead {
  margin: 0 0 24px;
  color: var(--mto-text-soft);
  line-height: 1.6;
  overflow-wrap: anywhere;
}

/* Notices and feedback — leading dot echoes the ladybug spot motif */
.notice,
.error-message,
.success-message,
.attempts-warning {
  position: relative;
  margin: 0 0 18px;
  padding: 12px 14px;
  padding-inline-start: 34px;
  border: 1px solid transparent;
  border-radius: 10px;
  font-size: 14px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.notice::before,
.error-message::before,
.success-message::before,
.attempts-warning::before {
  position: absolute;
  top: 18px;
  inset-inline-start: 14px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  content: "";
}

.notice a,
.error-message a,
.success-message a,
.attempts-warning a {
  color: inherit;
  font-weight: 800;
  text-underline-offset: 2px;
}

.notice--error,
.error-message {
  color: #ffc1c9;
  border-color: rgb(255 82 105 / 0.43);
  background: var(--mto-danger-soft);
}

.notice--success,
.success-message {
  color: #c5f7d8;
  border-color: rgb(84 214 139 / 0.42);
  background: var(--mto-success-soft);
}

.notice--info {
  color: #c8ebff;
  border-color: rgb(113 188 234 / 0.42);
  background: var(--mto-info-soft);
}

.notice--warning,
.attempts-warning {
  color: #ffe0b2;
  border-color: rgb(255 178 76 / 0.42);
  background: var(--mto-warning-soft);
}

.error-message,
.success-message {
  display: none;
}

body.has-error .error-message,
body.has-success .success-message {
  display: block;
}

.attempts-info,
.code-hint,
.hint,
.js-status {
  color: var(--mto-text-faint);
  font-size: 13px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.attempts-info,
.code-hint,
.js-status {
  margin: 0 0 16px;
}

.hint {
  margin: 7px 0 0;
}

/* Forms */
.field {
  min-width: 0;
  display: grid;
  gap: 7px;
  margin: 15px 0;
  text-align: start;
}

.field label {
  color: var(--mto-text-soft);
  font-size: 13px;
  font-weight: 750;
  line-height: 1.35;
  overflow-wrap: anywhere;
  transition: color 160ms ease;
}

.field:focus-within > label {
  color: #fff;
}

.field__wrap {
  position: relative;
  min-width: 0;
}

.field input[type="text"],
.field input[type="email"],
.field input[type="password"],
.field input[type="search"],
.field input[type="url"],
.field input[type="tel"],
.field input[type="number"],
.field select,
.field textarea {
  width: 100%;
  min-width: 0;
  min-height: 48px;
  margin: 0;
  padding: 11px 13px;
  border: 1px solid var(--mto-border);
  border-radius: var(--mto-radius-control);
  outline: none;
  color: var(--mto-text);
  background: var(--mto-surface-soft);
  caret-color: var(--mto-red-bright);
  font-size: max(16px, 1em);
  line-height: 1.35;
  transition:
    border-color 160ms ease,
    box-shadow 160ms ease,
    background 160ms ease;
}

.field textarea {
  min-height: 112px;
  resize: vertical;
}

.field select {
  padding-inline-end: 38px;
}

.field input:hover,
.field select:hover,
.field textarea:hover {
  border-color: var(--mto-border-strong);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--mto-red-bright);
  background: rgb(255 255 255 / 0.075);
  box-shadow: 0 0 0 3px var(--mto-focus);
}

.field input::placeholder,
.field textarea::placeholder {
  color: rgb(255 255 255 / 0.38);
  opacity: 1;
}

.field input:disabled,
.field select:disabled,
.field textarea:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.field input[aria-invalid="true"],
.field select[aria-invalid="true"],
.field textarea[aria-invalid="true"] {
  border-color: var(--mto-red-bright);
}

.field__wrap > input[data-password],
.field__wrap > input[type="password"] {
  padding-inline-end: 50px;
}

.password-toggle {
  position: absolute;
  top: 50%;
  inset-inline-end: 7px;
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  border-radius: 8px;
  color: var(--mto-text-faint);
  background: transparent;
  cursor: pointer;
  transform: translateY(-50%);
  transition: color 160ms ease, background 160ms ease;
}

.password-toggle:hover {
  color: #fff;
  background: rgb(255 255 255 / 0.09);
}

.password-toggle:focus-visible {
  outline: 3px solid var(--mto-focus);
  outline-offset: 1px;
}

.password-toggle svg {
  width: 19px;
  height: 19px;
}

.capslock-hint,
[data-caps-hint] {
  margin: 0;
  color: #ffe0b2;
  font-size: 12px;
  line-height: 1.4;
}

.field--code input {
  min-height: 58px;
  text-align: center;
  font-size: 24px;
  font-weight: 850;
  letter-spacing: 0.32em;
  font-variant-numeric: tabular-nums;
}

.remember {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin: 4px 0 19px;
  color: var(--mto-text-soft);
  font-size: 13px;
  line-height: 1.4;
  cursor: pointer;
  user-select: none;
}

.remember input {
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
  margin: 1px 0 0;
  accent-color: var(--mto-red);
  cursor: pointer;
}

.remember:hover {
  color: #fff;
}

.hp-field,
.token-stage {
  position: absolute !important;
  left: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
}

[dir="rtl"] .hp-field,
[dir="rtl"] .token-stage {
  right: -10000px !important;
  left: auto !important;
}

/* Actions */
.actions {
  display: grid;
  gap: 11px;
  margin-top: 22px;
}

.button,
.btn {
  position: relative;
  width: 100%;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 17px;
  overflow: hidden;
  border: 1px solid transparent;
  border-radius: var(--mto-radius-control);
  color: #fff;
  background: transparent;
  font-size: 14px;
  font-weight: 850;
  line-height: 1.25;
  letter-spacing: 0.02em;
  text-align: center;
  text-decoration: none;
  overflow-wrap: anywhere;
  cursor: pointer;
  transition:
    transform 120ms ease,
    border-color 180ms ease,
    background 180ms ease,
    box-shadow 180ms ease;
}

.button:active,
.btn:active {
  transform: scale(0.985);
}

.button:focus-visible,
.btn:focus-visible {
  outline: 3px solid var(--mto-focus);
  outline-offset: 3px;
}

.button--primary,
.btn--primary {
  background: linear-gradient(135deg, var(--mto-red), var(--mto-red-deep));
  box-shadow: 0 8px 22px rgb(185 22 46 / 0.22);
}

.button--primary:hover,
.btn--primary:hover {
  background: linear-gradient(135deg, var(--mto-red-bright), var(--mto-red));
  box-shadow: 0 10px 28px rgb(230 43 59 / 0.34);
}

.button--secondary,
.btn--secondary {
  color: var(--mto-text);
  border-color: var(--mto-border);
  background: rgb(255 255 255 / 0.065);
}

.button--secondary:hover,
.btn--secondary:hover {
  border-color: var(--mto-border-strong);
  background: rgb(255 255 255 / 0.1);
}

.button--danger,
.btn--danger {
  color: #ffe8ec;
  border-color: rgb(255 92 115 / 0.5);
  background: rgb(185 22 46 / 0.14);
}

.button--danger:hover,
.btn--danger:hover {
  border-color: rgb(255 115 135 / 0.78);
  background: rgb(185 22 46 / 0.24);
}

/* Passkey button — "Cat Noir" variant: pill shape + dark surface + green chip,
   deliberately distinct from the primary red button */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 18px 0 16px;
}

.auth-divider::before,
.auth-divider::after {
  flex: 1;
  height: 1px;
  content: "";
}

.auth-divider::before {
  background: linear-gradient(90deg, transparent, rgb(255 255 255 / 0.16));
}

.auth-divider::after {
  background: linear-gradient(90deg, rgb(255 255 255 / 0.16), transparent);
}

.auth-divider span {
  width: 6px;
  height: 6px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: rgb(168 215 111 / 0.65);
}

.btn--passkey,
.button--passkey {
  gap: 10px;
  border-radius: 999px;
  color: #d8f6b8;
  border: 1px solid rgb(168 215 111 / 0.42);
  background: rgb(12 14 10 / 0.72);
}

.btn--passkey:hover,
.button--passkey:hover {
  color: #ecffd8;
  border-color: rgb(168 215 111 / 0.85);
  background: rgb(20 24 16 / 0.9);
  box-shadow: 0 7px 24px rgb(168 215 111 / 0.18);
}

.btn--passkey:focus-visible,
.button--passkey:focus-visible {
  outline-color: rgb(168 215 111 / 0.55);
}

.btn--passkey svg,
.button--passkey svg {
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
}

.passkey-chip {
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: #cdf3a2;
  border: 1px solid rgb(168 215 111 / 0.45);
  background: rgb(168 215 111 / 0.12);
  transition:
    color 180ms ease,
    background 180ms ease,
    border-color 180ms ease,
    transform 180ms ease;
}

.btn--passkey:hover .passkey-chip,
.button--passkey:hover .passkey-chip {
  color: #10140b;
  background: #a8d76f;
  border-color: #a8d76f;
  transform: rotate(-10deg) scale(1.08);
}

.button[disabled],
.btn[disabled],
.button[aria-disabled="true"],
.btn[aria-disabled="true"] {
  cursor: not-allowed;
  opacity: 0.62;
}

[data-submit].is-submitting {
  color: transparent !important;
  pointer-events: none;
}

[data-submit].is-submitting::before {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 19px;
  height: 19px;
  margin: -9.5px 0 0 -9.5px;
  border: 3px solid rgb(255 255 255 / 0.36);
  border-top-color: #fff;
  border-radius: 50%;
  content: "";
  animation: mto-spinner 760ms linear infinite;
}

@keyframes mto-spinner {
  to {
    transform: rotate(360deg);
  }
}

.links,
.auth-account-links,
.auth-tip {
  margin: 20px 0 0;
  color: var(--mto-text-faint);
  font-size: 13px;
  line-height: 1.75;
  text-align: center;
  overflow-wrap: anywhere;
}

.links a,
.auth-account-links a {
  color: #ffb0bb;
  font-weight: 750;
  text-underline-offset: 3px;
}

.links a:hover,
.auth-account-links a:hover {
  color: #fff;
}

.auth-account-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 5px 9px;
  margin-top: 15px;
}

.auth-tip em {
  color: var(--mto-text-soft);
  font-style: normal;
  font-weight: 750;
}

/* Turnstile */
.turnstile {
  min-height: 70px;
  display: grid;
  place-items: center;
  margin: 19px 0 5px;
  overflow: hidden;
}

.turnstile > * {
  max-width: 100%;
}

/* Account/profile layouts */
.profile,
.profile-card {
  min-width: 0;
}

.profile-header {
  display: flex;
  align-items: center;
  gap: 17px;
  margin-bottom: 24px;
}

.profile-avatar {
  width: 68px;
  height: 68px;
  flex: 0 0 68px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 2px solid rgb(255 255 255 / 0.16);
  border-radius: 50%;
  color: #fff;
  background:
    radial-gradient(circle at 35% 25%, rgb(255 255 255 / 0.18), transparent 32%),
    linear-gradient(145deg, var(--mto-red), var(--mto-purple));
  font-size: 24px;
  font-weight: 850;
}

.profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-heading {
  min-width: 0;
}

.profile-heading h1,
.profile-heading h2 {
  margin: 0;
  color: #fff;
  font-size: clamp(22px, 5vw, 29px);
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.profile-heading p {
  margin: 5px 0 0;
  color: var(--mto-text-soft);
  overflow-wrap: anywhere;
}

.profile-copy {
  min-width: 0;
}

.account-status {
  min-height: 1.4em;
  margin: 16px 0 0;
  color: #ffd2d9;
  text-align: center;
  overflow-wrap: anywhere;
}

.profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.profile-meta {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--mto-border);
  border-radius: 12px;
  background: rgb(255 255 255 / 0.035);
}

.profile-meta__label {
  display: block;
  margin-bottom: 5px;
  color: var(--mto-text-faint);
  font-size: 12px;
  font-weight: 750;
}

.profile-meta__value {
  display: block;
  color: #fff;
  font-weight: 750;
  overflow-wrap: anywhere;
}

.profile-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px;
  margin-top: 22px;
}

/* RTL */
[dir="rtl"] .mto-site-header__inner,
[dir="rtl"] .mto-site-nav,
[dir="rtl"] .profile-header {
  direction: rtl;
}

[dir="rtl"] .field--code input {
  direction: ltr;
}

[dir="rtl"] [data-submit].is-submitting::before {
  right: 50%;
  left: auto;
  margin-right: -9.5px;
  margin-left: 0;
}

/* Responsive navigation and cards */
@media (max-width: 820px) {
  :root {
    --mto-header-height: 62px;
  }

  .mto-site-header__inner {
    width: min(100% - 24px, 1180px);
    gap: 12px;
  }

  .mto-site-brand {
    font-size: 16px;
  }

  .mto-site-brand .mto-ladybug {
    --ladybug-size: 31px;
  }

  .mto-nav-disclosure {
    position: relative;
  }

  .mto-nav-toggle {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    padding: 0;
    border: 1px solid var(--mto-border);
    border-radius: 10px;
    color: #fff;
    background: rgb(255 255 255 / 0.045);
    cursor: pointer;
  }

  .mto-nav-toggle:hover,
  .mto-nav-disclosure[open] .mto-nav-toggle {
    border-color: var(--mto-border-strong);
    background: rgb(255 255 255 / 0.09);
  }

  .mto-nav-toggle__lines,
  .mto-nav-toggle__lines::before,
  .mto-nav-toggle__lines::after {
    width: 20px;
    height: 2px;
    display: block;
    border-radius: 3px;
    background: currentColor;
    content: "";
    transition: transform 180ms ease, opacity 180ms ease;
  }

  .mto-nav-toggle__lines {
    position: relative;
  }

  .mto-nav-toggle__lines::before {
    position: absolute;
    top: -6px;
  }

  .mto-nav-toggle__lines::after {
    position: absolute;
    top: 6px;
  }

  .mto-nav-disclosure[open] .mto-nav-toggle__lines {
    background: transparent;
  }

  .mto-nav-disclosure[open] .mto-nav-toggle__lines::before {
    top: 0;
    transform: rotate(45deg);
  }

  .mto-nav-disclosure[open] .mto-nav-toggle__lines::after {
    top: 0;
    transform: rotate(-45deg);
  }

  .mto-nav-disclosure:not([open]) > .mto-site-nav {
    display: none;
  }

  .mto-site-nav {
    position: absolute;
    top: calc(100% + 9px);
    inset-inline-end: 0;
    width: min(310px, calc(100vw - 24px));
    max-height: calc(100dvh - var(--mto-header-height) - 20px);
    display: grid;
    align-items: stretch;
    gap: 4px;
    padding: 10px;
    overflow-y: auto;
    border: 1px solid var(--mto-border);
    border-radius: 14px;
    background: #22222c;
    box-shadow: 0 22px 60px rgb(0 0 0 / 0.55);
  }

  .mto-site-nav__link {
    min-height: 43px;
    justify-content: flex-start;
    text-align: start;
  }

  .mto-site-nav__link[aria-current="page"]::after {
    top: 9px;
    right: auto;
    bottom: 9px;
    left: 3px;
    width: 3px;
    height: auto;
  }

  [dir="rtl"] .mto-site-nav__link[aria-current="page"]::after {
    right: 3px;
    left: auto;
  }

  .mto-language {
    margin: 5px 0 0;
  }

  .mto-language__summary {
    width: 100%;
    max-width: none;
    min-height: 43px;
  }

  .mto-language__menu {
    position: static;
    width: 100%;
    max-height: 250px;
    margin-top: 6px;
    border-radius: 10px;
    background: rgb(0 0 0 / 0.18);
    box-shadow: none;
  }

  .mto-auth-main {
    align-items: flex-start;
    padding-top: clamp(28px, 7vh, 56px);
  }
}

@media (min-width: 821px) {
  .mto-nav-disclosure:not([open]) > .mto-site-nav {
    display: flex;
  }
}

@media (max-width: 560px) {
  .mto-auth-main {
    padding-right: 12px;
    padding-left: 12px;
  }

  .auth-card,
  .mto-auth-card {
    padding: 24px 19px;
    border-radius: 16px;
  }

  .auth-brand .mto-ladybug {
    --ladybug-size: 52px;
  }

  .profile-header {
    align-items: flex-start;
  }

  .profile-avatar {
    width: 58px;
    height: 58px;
    flex-basis: 58px;
  }

  .profile-grid,
  .profile-actions {
    grid-template-columns: 1fr;
  }

  .mto-language__menu {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 360px) {
  .mto-site-brand > span:last-child {
    max-width: 130px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .auth-card,
  .mto-auth-card {
    padding-right: 16px;
    padding-left: 16px;
  }
}

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

  .mto-auth-backdrop::before {
    animation: none;
  }

  html.mto-js body.mto-ui-pending .auth-card,
  html.mto-js body.mto-ui-pending .mto-auth-card {
    opacity: 1;
    transform: none;
  }
}

@media (forced-colors: active) {
  .auth-card,
  .mto-auth-card,
  .mto-site-header,
  .mto-site-nav,
  .mto-language__menu {
    border: 1px solid CanvasText;
  }

  .mto-ladybug {
    forced-color-adjust: none;
  }

  .button,
  .btn,
  .field input,
  .field select,
  .field textarea {
    border: 1px solid ButtonText;
  }
}
