/* Overlay */
.pxn-lad-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 23, 42, 0.55);
}

.pxn-lad-modal[hidden] {
  display: none;
}

/* Boite centrale */
.pxn-lad-modal__box {
  position: relative;
  background: #fff;
  border-radius: 14px;
  padding: 2rem 2rem 1.75rem;
  width: min(420px, calc(100vw - 2rem));
  box-shadow: 0 8px 40px rgba(15, 23, 42, 0.18);
  box-sizing: border-box;
}

/* Bouton fermer */
.pxn-lad-modal__close {
  position: absolute;
  top: 0.75rem;
  right: 0.9rem;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.3rem;
  line-height: 1;
  color: #64748b;
  padding: 4px 6px;
}

.pxn-lad-modal__close:hover {
  color: #0f172a;
}

/* Onglets */
.pxn-lad-modal__tabs {
  display: flex;
  margin-bottom: 1.5rem;
  border-bottom: 2px solid #e2e8f0;
}

.pxn-lad-modal__tab {
  padding: 0.6rem 1.1rem;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  cursor: pointer;
  font-size: 0.95rem;
  color: #64748b;
}

.pxn-lad-modal__tab--active {
  color: #0b5cff;
  border-bottom-color: #0b5cff;
  font-weight: 600;
}

/* Panneaux */
.pxn-lad-modal__panel {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.pxn-lad-modal__panel[hidden] {
  display: none;
}

/* Champ */
.pxn-lad-modal__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.pxn-lad-modal__label {
  font-weight: 600;
  font-size: 0.93rem;
}

.pxn-lad-modal__input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #d0d5dd;
  border-radius: 8px;
  box-sizing: border-box;
  font-size: 1rem;
}

.pxn-lad-modal__input:focus {
  outline: 2px solid #0b5cff;
  outline-offset: 1px;
}

/* Bouton principal de la modale */
.pxn-lad-modal__submit {
  padding: 11px 14px;
  border: 1px solid #0b5cff;
  background: #0b5cff;
  color: #fff;
  border-radius: 10px;
  cursor: pointer;
  font-size: 1rem;
  margin-top: 4px;
  text-align: center;
}

.pxn-lad-modal__submit:hover:not(:disabled) {
  filter: brightness(0.95);
}

.pxn-lad-modal__submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Message d'erreur */
.pxn-lad-modal__error {
  color: #b42318;
  font-size: 0.9rem;
  min-height: 1.1em;
  font-weight: 600;
  margin: 0;
}

/* Footer (lien mot de passe oublie) */
.pxn-lad-modal__footer {
  margin: 0;
  font-size: 0.85rem;
  color: #64748b;
  text-align: center;
}

.pxn-lad-modal__footer a {
  color: #0b5cff;
}

/* Barre auth (connecte en tant que...) */
.pxn-lad__auth-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  color: #475569;
  flex-wrap: wrap;
  width: 100%;
}

.pxn-lad__auth-bar[hidden] {
  display: none;
}

.pxn-lad__auth-name {
  font-weight: 600;
  color: #1e3a5f;
}

/* Bouton auth-locked : visuellement grise mais cliquable */
.pxn-lad__btn--auth-locked {
  opacity: 0.55;
  cursor: pointer;
  border-color: #94a3b8;
  background: #eceff3;
  color: #475569;
}

/* Selecteur de format email */
.pxn-lad__email-picker {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  width: 100%;
  padding: 8px 0 2px;
}

.pxn-lad__email-picker[hidden] {
  display: none;
}

.pxn-lad__email-picker-label {
  font-size: 0.9rem;
  color: #475569;
}

.pxn-lad__btn--cancel {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.85rem;
  color: #64748b;
  padding: 4px 6px;
  text-decoration: underline;
}
