/* Auth page is styled by trading/app.css. This file is intentionally light. */
.input-container{position:relative}
.password-toggle{position:absolute;right:.7rem;top:50%;transform:translateY(-50%);border:0;background:transparent;color:#94a0ad;padding:.25rem;cursor:pointer}
.form-actions{margin-top:4px}
.form-link{text-align:center;margin-top:.85rem}
.alert{padding:.75rem 1rem;border-radius:14px;background:rgba(255,255,255,.06)}


/* Auth — récupération mot de passe + renvoi de code */
.auth-form{
  display:grid;
  gap:14px;
}

.auth-messages{
  display:grid;
  gap:8px;
  margin:14px 0;
}

.auth-code-destination{
  padding:10px 12px;
  border:1px solid rgba(34,197,94,.22);
  background:rgba(34,197,94,.08);
  border-radius:14px;
}

.auth-code-destination strong{
  color:#e5fff3;
}

.auth-resend-form{
  margin-top:12px;
  text-align:center;
}

.auth-link-btn{
  border:0;
  background:transparent;
  color:#22c55e;
  font:inherit;
  font-weight:800;
  cursor:pointer;
  padding:6px 8px;
}

.auth-link-btn:hover{
  text-decoration:underline;
}

.form-link a{
  color:#22c55e;
  font-weight:800;
  text-decoration:none;
}

.form-link a:hover{
  text-decoration:underline;
}


/* Auth — conditions dans une modale avant inscription */
.auth-inline-link{
  border:0;
  background:transparent;
  color:#22c55e;
  font:inherit;
  font-weight:900;
  padding:0;
  cursor:pointer;
  text-decoration:none;
}

.auth-inline-link:hover{
  text-decoration:underline;
}

.auth-terms-modal[hidden]{
  display:none!important;
}

.auth-terms-modal{
  position:fixed;
  inset:0;
  z-index:3200;
  display:grid;
  place-items:center;
  padding:18px;
}

.auth-terms-modal__backdrop{
  position:absolute;
  inset:0;
  background:rgba(0,0,0,.72);
  backdrop-filter:blur(12px);
}

.auth-terms-modal__card{
  position:relative;
  width:min(980px,calc(100vw - 28px));
  max-height:calc(100dvh - 28px);
  display:grid;
  grid-template-rows:auto minmax(0,1fr) auto;
  overflow:hidden;
  border:1px solid rgba(210,221,235,.15);
  border-radius:28px;
  background:
    radial-gradient(circle at 12% 0%,rgba(34,197,94,.15),transparent 34%),
    linear-gradient(180deg,rgba(21,27,36,.98),rgba(7,9,12,.99));
  color:#f2f6fa;
  box-shadow:0 34px 100px rgba(0,0,0,.55);
}

.auth-terms-modal__header,
.auth-terms-modal__footer{
  display:flex;
  align-items:center;
  gap:14px;
  padding:18px 20px;
  background:rgba(7,9,12,.72);
  border-color:rgba(210,221,235,.12);
}

.auth-terms-modal__header{
  justify-content:space-between;
  border-bottom:1px solid rgba(210,221,235,.12);
}

.auth-terms-modal__footer{
  justify-content:flex-end;
  border-top:1px solid rgba(210,221,235,.12);
}

.auth-terms-modal__kicker{
  display:block;
  color:#22c55e;
  font-size:11px;
  font-weight:1000;
  letter-spacing:.14em;
  text-transform:uppercase;
}

.auth-terms-modal__header h2{
  margin:6px 0 0;
  color:#f2f6fa;
  font-size:clamp(24px,3vw,34px);
  line-height:1;
  letter-spacing:-.04em;
}

.auth-terms-modal__close{
  width:42px;
  height:42px;
  display:grid;
  place-items:center;
  border:1px solid rgba(210,221,235,.16);
  border-radius:14px;
  background:rgba(255,255,255,.05);
  color:#94a0ad;
}

.auth-terms-modal__close:hover{
  color:#f2f6fa;
  background:rgba(255,255,255,.08);
}

.auth-terms-modal__body{
  min-height:0;
  overflow:auto;
  padding:20px;
  outline:none;
}

.auth-terms-modal__legal{
  max-width:880px;
  margin:0 auto;
  display:grid;
  gap:12px;
}

.auth-terms-modal__legal h2{
  margin:18px 0 0;
  color:#f2f6fa;
  font-size:20px;
  line-height:1.18;
  letter-spacing:-.02em;
}

.auth-terms-modal__legal h2:first-child{
  margin-top:0;
}

.auth-terms-modal__legal p{
  margin:0;
  color:#b6c1ce;
  font-size:14px;
  line-height:1.62;
}

.auth-terms-modal__legal strong{
  color:#f2f6fa;
}

.auth-terms-modal__reject,
.auth-terms-modal__accept{
  min-height:46px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:14px;
  padding:12px 16px;
  font-weight:950;
  line-height:1;
}

.auth-terms-modal__reject{
  border:1px solid rgba(210,221,235,.16);
  color:#f2f6fa;
  background:rgba(255,255,255,.055);
}

.auth-terms-modal__accept{
  border:1px solid rgba(255,255,255,.16);
  color:#07100e;
  background:linear-gradient(135deg,#22c55e,#b5f6d8);
  box-shadow:0 18px 44px rgba(34,197,94,.18);
}

.auth-terms-modal-open{
  overflow:hidden;
}

@media (max-width:640px){
  .auth-terms-modal{
    padding:10px;
  }

  .auth-terms-modal__card{
    width:100%;
    max-height:calc(100dvh - 20px);
    border-radius:22px;
  }

  .auth-terms-modal__header,
  .auth-terms-modal__footer{
    padding:14px;
  }

  .auth-terms-modal__footer{
    display:grid;
    grid-template-columns:1fr;
  }

  .auth-terms-modal__reject,
  .auth-terms-modal__accept{
    width:100%;
  }

  .auth-terms-modal__body{
    padding:14px;
  }
}


/* Auth — zéro espace entre la card et le footer */
.pino-main:has(.auth-card--footer-tight){
  min-height:0!important;
  margin-bottom:0!important;
  padding-bottom:0!important;
}

.auth-card--footer-tight{
  margin-bottom:0!important;
}

.auth-card--footer-tight + .auth-terms-modal{
  margin:0!important;
}

.pino-main:has(.auth-card--footer-tight) + .pino-footer,
.pino-main:has(.auth-card--footer-tight) + .pino-footer-clean{
  margin-top:0!important;
}

body:has(.auth-card--footer-tight) .pino-footer,
body:has(.auth-card--footer-tight) .pino-footer-clean{
  margin-top:0!important;
}
