/* NSX Kompetenz — auth screens
   Used by the KIMOS Backoffice, Governance candidate and Elite employer auth pages
   (and, since step 20.4, the Elite register and verification pages).
   Named tokens only (--nsx-*): no colour code anywhere in this file (Rayen's rule,
   31.10.2026). The primary action is white (--nsx-card) on the brand orange
   (--nsx-brand), the decided exception of opencode.md §9.0.
   Etape 20.4 : bord des champs --nsx-field-border (3,2:1), champs en pilule de
   44 px comme kx-input, plus aucun texte sous 12 px. */

.nsx-auth-page,
.nsx-auth-page *,
.nsx-auth-page *::before,
.nsx-auth-page *::after {
  box-sizing: border-box;
}

.nsx-auth-page {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  color: var(--nsx-text);
  background:
    radial-gradient(58rem 42rem at 92% 8%, var(--nsx-orange-tint) 0%, transparent 62%),
    radial-gradient(46rem 36rem at 0% 100%, var(--nsx-blue-tint) 0%, transparent 64%),
    var(--nsx-page);
  overflow-x: clip;
}

.nsx-auth-decoration {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.nsx-auth-petal {
  position: absolute;
  display: block;
  border-radius: 0 100% 0 100%;
  opacity: 0.85;
}

.nsx-auth-petal--a {
  width: 30rem;
  height: 30rem;
  top: -12rem;
  inset-inline-end: -8rem;
  background: var(--nsx-brand-soft);
  transform: rotate(16deg);
}

.nsx-auth-petal--b {
  width: 25rem;
  height: 25rem;
  bottom: -10rem;
  inset-inline-start: -7rem;
  background: var(--nsx-blue-tint);
  transform: rotate(-24deg);
}

.nsx-auth-petal--c {
  width: 13rem;
  height: 13rem;
  bottom: 12%;
  inset-inline-end: 5%;
  background: var(--nsx-yellow-tint);
  transform: rotate(40deg);
  opacity: 0.65;
}

.nsx-auth-skip {
  position: absolute;
  inset-block-start: 0.75rem;
  inset-inline-start: 0.75rem;
  z-index: 40;
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0.65rem 0.9rem;
  border-radius: var(--nsx-radius-sm);
  background: var(--nsx-pole-elite);
  color: var(--nsx-card);
  font-size: 0.875rem;
  font-weight: 700;
  text-decoration: none;
  transform: translateY(-160%);
}

.nsx-auth-skip:focus-visible {
  transform: translateY(0);
  outline: 2px solid var(--nsx-card);
  outline-offset: 2px;
}

.nsx-auth-lang {
  position: absolute;
  inset-block-start: 1.5rem;
  inset-inline-end: 1.5rem;
  z-index: 30;
}

.nsx-auth-lang .nsx-dropdown-trigger {
  min-height: 2.75rem;
  padding: 0.45rem 0.8rem;
  border: 1px solid var(--nsx-lang-bd);
  border-radius: 999px;
  background: color-mix(in srgb, var(--nsx-card) 92%, transparent 8%);
  color: var(--nsx-pole-elite);
  box-shadow: var(--nsx-shadow-soft);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.04em;
}

/* Menu ouvert : le nom de chaque langue dans sa langue (meme liste et meme
   ordre partout, decision de Rayen du 03.11.2026) ; le bouton ferme garde le
   code (« FR ») pour rester compact. */
.nsx-auth-lang .nsx-dropdown-menu {
  inset-inline-end: 0;
  inset-inline-start: auto;
  min-width: 11rem;
}

.nsx-auth-lang .nsx-dropdown-trigger:focus-visible {
  outline: 2px solid var(--nsx-pole-elite);
  outline-offset: 2px;
}

.nsx-auth-lang .nsx-dropdown-item {
  min-height: 2.75rem;
  font-size: 0.875rem;
  text-align: start;
}

.nsx-auth-lang .nsx-dropdown-item.is-active {
  color: var(--nsx-pole-elite);
}

.nsx-auth-lang .nsx-dropdown-check {
  color: var(--nsx-pole-elite);
}

/* Honeypot: visually hidden, still present for bots that fill every field. */
.hp-field {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.nsx-auth-page .nsx-auth-shell {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: clamp(4.75rem, 6vw, 5.5rem) 1.25rem clamp(1.5rem, 4vw, 2.5rem);
}

.nsx-auth-grid--kimos,
.nsx-auth-grid--governance,
.nsx-auth-grid--elite {
  width: min(1120px, 100%);
  grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.95fr);
  align-items: stretch;
  gap: clamp(2rem, 5vw, 5rem);
}

.nsx-auth-hero {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 2rem;
  max-width: 34rem;
  min-height: 100%;
  padding-block: 0.5rem;
  text-align: start;
}

.nsx-auth-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  width: fit-content;
  color: inherit;
  text-decoration: none;
}

.nsx-auth-brand:hover .nsx-auth-brand-copy strong {
  color: var(--nsx-pole-elite);
  text-decoration: underline;
  text-decoration-color: var(--nsx-brand);
  text-underline-offset: 0.18em;
}

.nsx-auth-brand-mark {
  display: block;
  width: 2.75rem;
  height: auto;
  flex: 0 0 auto;
}

.nsx-auth-brand-copy {
  display: grid;
  gap: 0.12rem;
  line-height: 1.15;
}

.nsx-auth-brand-copy strong {
  color: var(--nsx-pole-elite);
  font-family: var(--nsx-font-brand);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  transition: color 160ms ease;
}

.nsx-auth-brand-copy span {
  color: var(--nsx-text-muted);
  font-size: 0.875rem;
  font-weight: 600;
}

.nsx-auth-brand-copy .nsx-auth-brand-tag {
  color: var(--nsx-pole-elite);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.nsx-auth-hero-body {
  margin-block: auto;
  max-width: 32rem;
}

.nsx-auth-eyebrow {
  margin: 0 0 1rem;
  color: var(--nsx-text-muted);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  line-height: 1.5;
  text-transform: uppercase;
}

.nsx-auth-hero-title {
  margin: 0;
  color: var(--nsx-pole-elite);
  font-family: var(--nsx-font-brand);
  font-size: clamp(2.1rem, 3.4vw, 2.65rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.06;
  text-wrap: balance;
}

.nsx-auth-hero-copy {
  max-width: 32rem;
  margin: 1.25rem 0 0;
  color: var(--nsx-text-muted);
  font-size: 1.0625rem;
  line-height: 1.7;
}

.nsx-auth-hero-slogan {
  margin-top: 1.1rem;
  color: var(--nsx-pole-elite);
  font-size: clamp(1.15rem, 1.8vw, 1.4rem);
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.4;
}

.nsx-auth-hero-foot {
  margin: 0;
  color: var(--nsx-text-muted);
  font-size: 0.875rem;
  line-height: 1.5;
}

.nsx-auth-card--kimos,
.nsx-auth-card--governance,
.nsx-auth-card--elite {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 30rem;
  justify-self: end;
  padding: clamp(1.5rem, 3vw, 2.5rem);
  border: 1px solid var(--nsx-border);
  border-radius: var(--nsx-radius-xl);
  background: var(--nsx-card);
  box-shadow: var(--nsx-shadow-raised);
  text-align: start;
}

.nsx-auth-card-head {
  margin-bottom: 1.5rem;
}

.nsx-auth-mark {
  display: block;
  width: 2.75rem;
  height: auto;
  margin: 0 auto 1rem;
}

.nsx-auth-card--kimos .nsx-auth-badge,
.nsx-auth-card--governance .nsx-auth-badge,
.nsx-auth-card--elite .nsx-auth-badge {
  border-color: color-mix(in srgb, var(--nsx-brand) 24%, transparent 76%);
  background: var(--nsx-orange-tint);
  color: var(--nsx-text);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.1em;
}

.nsx-auth-card--kimos .nsx-auth-title,
.nsx-auth-card--governance .nsx-auth-title,
.nsx-auth-card--elite .nsx-auth-title {
  margin: 0.8rem 0 0;
  color: var(--nsx-pole-elite);
  font-size: clamp(1.75rem, 3vw, 2.125rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.12;
}

.nsx-auth-card--kimos .nsx-auth-subtitle,
.nsx-auth-card--governance .nsx-auth-subtitle,
.nsx-auth-card--elite .nsx-auth-subtitle {
  margin: 0.6rem 0 0;
  color: var(--nsx-text-muted);
  font-size: 0.9375rem;
  line-height: 1.65;
}

.nsx-auth-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.25rem;
  margin-bottom: 1.25rem;
  padding: 0.25rem;
  border: 1px solid var(--nsx-border);
  border-radius: 999px;
  background: var(--nsx-navy-tint);
}

.nsx-auth-switch-option {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  color: var(--nsx-text-muted);
  font-size: 0.8125rem;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  transition: background-color 160ms ease, color 160ms ease, box-shadow 160ms ease;
}

.nsx-auth-switch-option:hover {
  color: var(--nsx-pole-elite);
  background: color-mix(in srgb, var(--nsx-card) 70%, transparent 30%);
}

.nsx-auth-switch-option.is-active {
  background: var(--nsx-pole-elite);
  color: var(--nsx-card);
  box-shadow: var(--nsx-shadow-soft);
}

.nsx-auth-switch-option:focus-visible {
  outline: 2px solid var(--nsx-pole-elite);
  outline-offset: 2px;
}

.nsx-auth-panel[hidden] {
  display: none !important;
}

.nsx-auth-form {
  display: grid;
  gap: 1rem;
}

.nsx-auth-field {
  display: grid;
  gap: 0.45rem;
}

.nsx-auth-field label {
  color: var(--nsx-text-muted);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1.4;
  text-transform: uppercase;
}

.nsx-auth-input-wrap {
  position: relative;
}

.nsx-auth-input-icon {
  position: absolute;
  inset-block-start: 50%;
  inset-inline-start: 1rem;
  width: 1.15rem;
  height: 1.15rem;
  color: var(--nsx-text-muted);
  pointer-events: none;
  transform: translateY(-50%);
}

.nsx-auth-field input.nsx-auth-input {
  width: 100%;
  /* 44 px et 16 px, comme kx-input (nsx_components.css) ; bord ardoise nomme,
     3,5:1 sur le blanc du champ (l'ancien navy a 28 % tenait ~1,7:1). */
  min-height: 2.75rem;
  padding-block: 0.5rem;
  padding-inline: 1rem;
  padding-inline-start: 2.9rem;
  border: 1px solid var(--nsx-field-border);
  border-radius: 999px;
  background: var(--nsx-card);
  color: var(--nsx-text);
  font-size: 1rem;
  line-height: 1.4;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.nsx-auth-input-wrap--email input.nsx-auth-input {
  padding-inline-start: 2.9rem;
  padding-inline-end: 1rem;
}

/* The email input is LTR for the address, while its icon follows the page
   direction. Move the text padding to the icon side in RTL. */
[dir="rtl"] .nsx-auth-input-wrap--email input.nsx-auth-input {
  padding-inline-start: 1rem;
  padding-inline-end: 2.9rem;
}

.nsx-auth-input-wrap--password input.nsx-auth-input {
  padding-inline-end: 3.15rem;
}

.nsx-auth-password-toggle {
  position: absolute;
  inset-block-start: 50%;
  inset-inline-end: 0;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  /* Cible de 44 px, dans le champ de 44 px. */
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--nsx-text-muted);
  cursor: pointer;
  transform: translateY(-50%);
  transition: background-color 160ms ease, color 160ms ease;
}

.nsx-auth-password-toggle[hidden] {
  display: none;
}

.nsx-auth-password-toggle:hover {
  background: var(--nsx-navy-tint);
  color: var(--nsx-pole-elite);
}

.nsx-auth-password-toggle:focus-visible {
  outline: 2px solid var(--nsx-pole-elite);
  outline-offset: 2px;
}

.nsx-auth-password-toggle svg {
  width: 1.15rem;
  height: 1.15rem;
}

.nsx-auth-field input.nsx-auth-input::placeholder {
  color: var(--nsx-text-muted);
  opacity: 1;
}

.nsx-auth-field input.nsx-auth-input:focus {
  outline: none;
  border-color: var(--nsx-pole-elite);
  box-shadow: 0 0 0 4px var(--nsx-brand-soft);
}

.nsx-auth-field input.nsx-auth-input:focus-visible {
  outline: 2px solid var(--nsx-pole-elite);
  outline-offset: 2px;
}

/* Texte d'exemple : gris nomme --nsx-text-muted, 4,8:1 sur le blanc du champ
   (4,6:1 sur la teinte d'erreur). */

/* Erreur de connexion : le champ change lui aussi, pas seulement la notice.
   Le template pose deja aria-invalid et aria-describedby sur les deux champs. */
.nsx-auth-field input.nsx-auth-input[aria-invalid="true"] {
  border-color: var(--nsx-danger);
  background: var(--nsx-danger-tint);
}

.nsx-auth-field input.nsx-auth-input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 100px var(--nsx-card) inset !important;
  -webkit-text-fill-color: var(--nsx-text) !important;
}

.nsx-auth-check {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding-block: 0.2rem;
  color: var(--nsx-text);
  cursor: pointer;
  font-size: 0.875rem;
  line-height: 1.55;
}

.nsx-auth-check input[type="checkbox"] {
  width: 1.125rem;
  height: 1.125rem;
  margin: 0.1rem 0 0;
  accent-color: var(--nsx-pole-elite);
  flex: 0 0 auto;
}

.nsx-auth-check input[type="checkbox"]:focus-visible {
  outline: 2px solid var(--nsx-pole-elite);
  outline-offset: 2px;
}

button.nsx-auth-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  width: 100%;
  min-height: 3.25rem;
  margin-top: 0.25rem;
  padding: 0.75rem 1.1rem;
  border: 0;
  border-radius: 999px;
  background: var(--nsx-brand);
  /* Texte blanc, aplat sans ombre orange (choix de Rayen, 30.10.2026). */
  color: var(--nsx-card);
  cursor: pointer;
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.3;
  transition: background-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

button.nsx-auth-submit:hover {
  background: var(--nsx-brand-hover);
  color: var(--nsx-card);
  transform: translateY(-1px);
}

button.nsx-auth-submit:focus-visible {
  outline: 2px solid var(--nsx-pole-elite);
  outline-offset: 3px;
}

button.nsx-auth-submit:disabled {
  opacity: 0.72;
  cursor: wait;
  transform: none;
  box-shadow: none;
}

.nsx-auth-spinner {
  display: none;
  width: 1.1rem;
  height: 1.1rem;
  flex: 0 0 auto;
  border: 2px solid currentColor;
  border-inline-end-color: transparent;
  border-radius: 50%;
  animation: nsx-auth-spin 700ms linear infinite;
}

button.nsx-auth-submit[aria-busy="true"] .nsx-auth-spinner {
  display: inline-block;
}

button.nsx-auth-submit[aria-busy="true"] .nsx-auth-submit-icon {
  display: none;
}

@keyframes nsx-auth-spin {
  to {
    transform: rotate(1turn);
  }
}

.nsx-auth-submit-icon {
  width: 1.1rem;
  height: 1.1rem;
  flex: 0 0 auto;
  transition: transform 160ms ease;
}

button.nsx-auth-submit:hover .nsx-auth-submit-icon {
  transform: translateX(2px);
}

.nsx-auth-notice,
.nsx-auth-panel,
.nsx-auth-sent {
  scroll-margin-block: 1.5rem;
}

.nsx-auth-notice[tabindex="-1"]:focus,
.nsx-auth-panel[tabindex="-1"]:focus,
.nsx-auth-sent[tabindex="-1"]:focus {
  outline: 2px solid var(--nsx-pole-elite);
  outline-offset: 3px;
}

.nsx-auth-sent[tabindex="-1"]:focus {
  border-radius: var(--nsx-radius-md);
}

.nsx-auth-notice {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  margin-bottom: 1rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--nsx-border);
  border-radius: var(--nsx-radius-md);
  font-size: 0.875rem;
  line-height: 1.55;
}

.nsx-auth-notice.is-danger {
  border-color: var(--nsx-danger-border);
  background: var(--nsx-danger-tint);
  color: var(--nsx-text);
}

.nsx-auth-notice.is-success {
  border-color: color-mix(in srgb, var(--nsx-success) 28%, transparent 72%);
  background: var(--nsx-green-tint);
  color: var(--nsx-green-dark);
}

.nsx-auth-notice-icon {
  width: 1.15rem;
  height: 1.15rem;
  margin-top: 0.1rem;
  flex: 0 0 auto;
}

.nsx-auth-notice.is-danger .nsx-auth-notice-icon {
  color: var(--nsx-danger);
}

.nsx-auth-notice.is-success .nsx-auth-notice-icon {
  color: var(--nsx-success-text);
}

.nsx-auth-sent {
  text-align: center;
}

.nsx-auth-sent-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3.25rem;
  height: 3.25rem;
  margin-bottom: 1rem;
  border-radius: 999px;
  background: var(--nsx-green-tint);
  color: var(--nsx-green-dark);
}

.nsx-auth-sent-icon svg {
  width: 1.4rem;
  height: 1.4rem;
}

.nsx-auth-sent-title {
  margin: 0;
  color: var(--nsx-pole-elite);
  font-family: var(--nsx-font-brand);
  font-size: 1.25rem;
  font-weight: 800;
  line-height: 1.25;
}

.nsx-auth-sent-copy {
  margin: 0.6rem 0 1rem;
  color: var(--nsx-text-muted);
  font-size: 0.9375rem;
  line-height: 1.65;
}

.nsx-auth-sent-email {
  color: var(--nsx-pole-elite);
  overflow-wrap: anywhere;
}

.nsx-auth-card--kimos .nsx-ghost-link,
.nsx-auth-card--governance .nsx-ghost-link,
.nsx-auth-card--elite .nsx-ghost-link {
  border-radius: 999px;
}

.nsx-auth-footer {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--nsx-border);
  color: var(--nsx-text-muted);
  font-size: 0.875rem;
  line-height: 1.65;
  text-align: center;
}

.nsx-auth-footer p {
  margin: 0;
}

.nsx-auth-footer-label {
  color: var(--nsx-text-muted);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.nsx-auth-portal-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1rem;
  margin-top: 0.55rem;
}

.nsx-auth-page .nsx-inline-link {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  padding-inline: 0.2rem;
  color: var(--nsx-pole-elite);
  font-weight: 800;
  text-decoration: underline;
  text-decoration-color: var(--nsx-brand);
  text-decoration-thickness: 0.12em;
  text-underline-offset: 0.18em;
}

.nsx-auth-page .nsx-inline-link:hover {
  text-decoration-color: var(--nsx-brand-hover);
}

.nsx-auth-page .nsx-inline-link:focus-visible {
  outline: 2px solid var(--nsx-pole-elite);
  outline-offset: 2px;
}

.nsx-auth-footer p.nsx-auth-legal {
  margin: 1rem 0 0;
  color: var(--nsx-text-muted);
  font-size: 0.8125rem;
  line-height: 1.6;
}

@media (max-width: 960px) {
  .nsx-auth-grid--kimos,
  .nsx-auth-grid--governance,
  .nsx-auth-grid--elite {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .nsx-auth-hero {
    width: 100%;
    max-width: 32rem;
    padding-block: 0;
    justify-self: center;
  }

  .nsx-auth-hero-body {
    margin-block: 0;
  }

  .nsx-auth-hero-title {
    font-size: clamp(1.9rem, 4vw, 2.5rem);
  }

  .nsx-auth-hero-foot {
    display: none;
  }

  .nsx-auth-card--kimos,
  .nsx-auth-card--governance,
  .nsx-auth-card--elite {
    max-width: 32rem;
    justify-self: center;
  }
}

@media (max-width: 640px) {
  .nsx-auth-page .nsx-auth-shell {
    padding-top: 4.5rem;
  }

  .nsx-auth-hero-body,
  .nsx-auth-hero-foot {
    display: none;
  }

  .nsx-auth-mark {
    display: none;
  }

  .nsx-auth-card--kimos,
  .nsx-auth-card--governance,
  .nsx-auth-card--elite {
    padding: 1.5rem;
  }

  .nsx-auth-hero-title {
    font-size: 2rem;
  }

  .nsx-auth-card--kimos .nsx-auth-title,
  .nsx-auth-card--governance .nsx-auth-title,
  .nsx-auth-card--elite .nsx-auth-title {
    font-size: 1.75rem;
  }

  .nsx-auth-switch-option {
    font-size: 0.75rem;
  }

  .nsx-auth-lang {
    inset-block-start: 1rem;
    inset-inline-end: 1rem;
  }

  .nsx-auth-petal--a {
    width: 20rem;
    height: 20rem;
    top: -8rem;
    inset-inline-end: -7rem;
  }

  .nsx-auth-petal--b {
    width: 17rem;
    height: 17rem;
    bottom: -8rem;
    inset-inline-start: -6rem;
  }

  .nsx-auth-petal--c {
    display: none;
  }
}

@media (max-width: 380px) {
  .nsx-auth-card--kimos,
  .nsx-auth-card--governance,
  .nsx-auth-card--elite {
    padding: 1.25rem;
  }

  .nsx-auth-legal {
    font-size: 0.75rem;
  }
}

@media (max-width: 340px) {
  .nsx-auth-input-wrap--password .nsx-auth-input-icon {
    display: none;
  }

  .nsx-auth-input-wrap--password input.nsx-auth-input {
    padding-inline-start: 1rem;
  }
}

[dir="rtl"] .nsx-auth-submit-icon {
  transform: scaleX(-1);
}

[dir="rtl"] button.nsx-auth-submit:hover .nsx-auth-submit-icon {
  transform: scaleX(-1) translateX(-2px);
}

@media (prefers-reduced-motion: reduce) {
  .nsx-auth-switch-option,
  .nsx-auth-brand-copy strong,
  .nsx-auth-field input.nsx-auth-input,
  .nsx-auth-password-toggle,
  button.nsx-auth-submit,
  .nsx-auth-submit-icon {
    transition: none;
  }

  button.nsx-auth-submit:hover {
    transform: none;
  }

  button.nsx-auth-submit:hover .nsx-auth-submit-icon,
  [dir="rtl"] button.nsx-auth-submit:hover .nsx-auth-submit-icon {
    transform: none;
  }

  .nsx-auth-spinner {
    animation: none;
    border-inline-end-color: currentColor;
    opacity: 0.55;
  }
}

/* ── 2FA du staff KIMOS (31.10.2026) : carte seule, QR dessine sur place ── */
.nsx-2fa-shell {
  display: flex;
  justify-content: center;
}

.nsx-2fa-card {
  width: 100%;
  max-width: 30rem;
}

.nsx-2fa-step {
  margin: 1rem 0 0.5rem;
  color: var(--nsx-text);
  font-size: 0.9375rem;
  line-height: 1.5;
}

.nsx-2fa-qr {
  width: 12rem;
  height: 12rem;
  margin: 0.5rem auto;
  padding: 0.5rem;
  border: 1px solid var(--nsx-border);
  border-radius: var(--nsx-radius-md);
  background: var(--nsx-qr-bg);
}

.nsx-2fa-qr svg {
  display: block;
  width: 100%;
  height: 100%;
}

.nsx-2fa-secret code {
  display: inline-block;
  padding: 0.5rem 0.75rem;
  border-radius: var(--nsx-radius-sm);
  background: var(--nsx-page);
  color: var(--nsx-text);
  font-size: 0.9375rem;
  letter-spacing: 0.06em;
  /* La cle arrive en groupes de 4 separes par une espace : retour a la ligne
     entre deux groupes seulement, jamais au milieu d'un groupe (l'ancien
     word-break: break-all coupait « ABCD » en « AB / CD »). */
  word-break: normal;
  overflow-wrap: normal;
}

/* Champ du code a 6 chiffres : chiffres espaces et centres. Taille du texte :
   celle des autres champs (16 px, .nsx-auth-field input.nsx-auth-input) ;
   l'ancienne regle de 20 px etait ecrasee par ce selecteur plus precis et
   n'avait aucun effet, d'ou son retrait (etape 22.3). Pas d'icone dans ce
   champ : marges interieures egales des deux cotes pour un vrai centrage.
   .nsx-2fa-card et [dir="ltr"] : en arabe, la regle [dir="rtl"] input:not(...)
   de nsx_theme.css, plus precise sans eux, alignait les chiffres a droite. */
.nsx-2fa-card .nsx-auth-field input.nsx-auth-input.nsx-2fa-code[dir="ltr"] {
  padding-inline: 1rem;
  letter-spacing: 0.3em;
  text-align: center;
}

.nsx-2fa-links {
  margin-top: 1rem;
  text-align: center;
}

.nsx-2fa-card .nsx-auth-notice {
  margin-top: 1rem;
}
