:root {
  --bgc-app: #101010;
  --bgc-input: #212121;
  --color-text: #ffffff;
  --color-placeholder-input: #808080;
  --effect-color: #D9DBF1;
  --font-family-app: "Exo", sans-serif;
  --danger: #ff6b6b;
  --danger-lo: rgba(255, 107, 107, .1);
  --mono: 'DM Mono', monospace;
}

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-family-app);
  background-color: var(--bgc-app);
  color: var(--color-text);
}

/* ── Layout ── */
.auth-tunedr-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 30px;
  width: 100%;
}

.top-auth-tunedr {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.text-top-page {
  text-align: center;
  font-size: 1rem;
  max-width: 260px;
}

.auth-tunedr { width: 100%; }

.form-signin {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ── Inputs wrapper ── */
.inputs {
  margin-top: 10px;
  width: 50%;
}

@media screen and (max-width: 1000px) { .inputs { width: 80%; } }
@media screen and (max-width: 700px)  { .inputs { width: 90%; } }
@media screen and (max-width: 400px)  { .inputs { width: 100%; } }

/* Desktop : 2 colonnes */
@media screen and (min-width: 1000px) {
  .inputs {
    width: 70%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 20px;
  }
  .link-submit { grid-column: span 2; }
}

/* ── Field ── */
.input {
  display: flex;
  flex-direction: column;
  border-radius: 10px;
  padding: 10px;
  margin-bottom: 8px;
}

.form-label {
  color: var(--color-placeholder-input);
  font-size: 0.8rem;
  margin-bottom: 10px;
}

.form-control {
  border: 1px solid rgba(255, 255, 255, .07);
  border-radius: 10px;
  background-color: var(--bgc-input);
  padding: 10px 12px;
  color: var(--color-text);
  font-family: var(--font-family-app);
  font-size: 0.875rem;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
  width: 100%;
  box-sizing: border-box;
  resize: none;
}

.form-control::placeholder { color: var(--color-placeholder-input); }

.form-control:focus {
  border-color: rgba(255, 255, 255, .35);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, .06);
}

/* ── Error states — même pattern que new-music et login ── */
.form-control.is-invalid {
  border-color: var(--danger) !important;
  box-shadow: 0 0 0 3px var(--danger-lo) !important;
  outline: none;
}

.form-check-input.is-invalid {
  outline: 2px solid var(--danger);
  outline-offset: 2px;
}

/* Message d'erreur sous chaque champ */
.field-error {
  margin: 4px 0 0;
  font-size: 12px;
  font-family: var(--mono);
  color: var(--danger);
  display: none;
}
.field-error.is-visible { display: block; }

/* Bannière d'erreur globale en haut du formulaire */
.form-alert {
  width: min(680px, 92%);
  margin: 10px auto 0;
  padding: 12px 14px;
  border-radius: 10px;
  background: rgba(255, 107, 107, .08);
  border: 1px solid rgba(255, 107, 107, .2);
  color: #ffc8c8;
  font-size: 13px;
  font-family: var(--mono);
}

/* ── Password toggle ── */
.form-label--row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.form-label--row > span:first-child { display: inline-block; }

.pw-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--color-text);
  cursor: pointer;
}

.pw-toggle svg {
  width: 18px;
  height: 18px;
  display: inline-block;
  vertical-align: middle;
}

/* ── Checkbox CGU ── */
.form-check {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.form-check-input,
.form-check input[type="checkbox"] {
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  margin: 0;
  cursor: pointer;
}

.form-check-label {
  margin: 0;
  line-height: 1.2;
  cursor: pointer;
  color: var(--color-text);
}

/* ── Submit area ── */
.link-submit {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  margin-top: 20px;
  width: 100%;
}

.submit-btn {
  padding: 11px 28px;
  background-color: var(--color-text);
  color: var(--bgc-app);
  border: none;
  outline: none;
  border-radius: 10px;
  font-family: var(--font-family-app);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity .15s, transform .1s;
}

.submit-btn:hover  { opacity: .88; }
.submit-btn:active { transform: scale(.98); }

.link {
  text-align: center;
  font-size: 0.8rem;
}

.link a {
  color: var(--effect-color);
  text-decoration: none;
}

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