/* =============================
   GLOBAL
============================= */

:root {
  --bg-page: #f5f6f8;
  --text: #0f172a;
  --accent: #00b050;
  --accent-dark: #008a3f;
  --card-border: rgba(15, 23, 42, 0.08);
  --card-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
  --card-shadow-hover: 0 22px 46px rgba(15, 23, 42, 0.16);
  --input-bg: #f7f9fb;
  --input-border: #d6dde5;
  --input-focus: rgba(0, 176, 80, 0.18);
}

body {
  font-family: "Inter", "Poppins", sans-serif;
  background-color: var(--bg-page);
  color: var(--text);
  margin: 0;
  padding: 0;
}

.inscription-page {
  min-height: 80vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: clamp(40px, 10vh, 120px) 16px;
  box-sizing: border-box;
  background: var(--bg-page, #f5f6f8);
}

/* =============================
   FORM CONTAINER
============================= */
.form {
  width: 100%;
  max-width: 520px;
  background: #fff;
  padding: 44px 42px;
  border-radius: 16px;
  border: 1px solid var(--card-border);
  box-shadow: var(--card-shadow);
  text-align: left;
  transition: transform 0.2s ease, box-shadow 0.2s ease;

  margin: 0 auto;
  display: block;
}


.form:hover {
  transform: translateY(-4px);
  box-shadow: var(--card-shadow-hover);
}

/* =============================
   TITRES
============================= */
.form-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 25px;
  color: #0f172a;
  border-left: 4px solid var(--accent);
  padding-left: 14px;
}

/* =============================
   INPUTS
============================= */
.input-container {
  position: relative;
  margin-bottom: 16px;
}

.input-container input,
.input-container select {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--input-border);
  border-radius: 10px;
  font-size: 1rem;
  background: var(--input-bg);
  color: #111;
  transition: all 0.2s ease;
}

.input-container select {
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, #666 50%),
    linear-gradient(135deg, #666 50%, transparent 50%);
  background-position:
    calc(100% - 18px) 50%,
    calc(100% - 12px) 50%;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 38px;
  cursor: pointer;
}

.input-container select::-ms-expand {
  display: none;
}

.input-container input::placeholder {
  color: #888;
}

.input-container input:focus,
.input-container select:focus {
  border-color: var(--accent);
  background: #fff;
  outline: none;
  box-shadow: 0 0 0 3px var(--input-focus);
}

.address-street-wrap {
  position: relative;
}

.address-suggestions {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 6px);
  background: #fff;
  border: 1px solid var(--input-border);
  border-radius: 12px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
  z-index: 20;
  max-height: 220px;
  overflow: auto;
  padding: 6px;
  display: grid;
  gap: 6px;
}

.address-suggestions[hidden] {
  display: none;
}

.address-item {
  padding: 8px 10px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.95rem;
}

.address-item:hover,
.address-item.active {
  background: #f1fdf7;
}

.address-meta {
  display: block;
  color: #6b7280;
  font-size: 0.85rem;
  margin-top: 2px;
}

.address-empty {
  padding: 8px 10px;
  color: #6b7280;
  font-size: 0.9rem;
}

.address-use {
  width: 100%;
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid #cfe7db;
  background: #f1fdf7;
  color: #0b6c5f;
  font-weight: 700;
  cursor: pointer;
}

.address-use:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

/* =============================
   TOGGLE PASSWORD
============================= */
.input-container.password-container {
  position: relative;
}

.toggle-password {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #6b7280;
  cursor: pointer;
  font-size: 1.1em;
  transition: color 0.2s;
}

.toggle-password:hover {
  color: var(--accent);
}

/* =============================
   BOUTON SUBMIT
============================= */
.submit {
  width: 100%;
  padding: 14px 16px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.2s ease;
  box-shadow: 0 12px 22px rgba(0, 176, 80, 0.2);
}

.submit:hover {
  background: var(--accent-dark);
  transform: translateY(-2px);
}

.submit:active {
  transform: translateY(0);
}

/* =============================
   MESSAGES D'ERREUR
============================= */
.error-msg {
  background: #fdeaea;
  border: 1px solid #f5b5b5;
  color: #801919;
  border-radius: 8px;
  padding: 8px 10px;
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 10px;
  text-align: center;
  box-shadow: 0 4px 10px rgba(128, 25, 25, 0.08);
}
.error-msg--large {
  font-size: 1.05rem;
  padding: 12px 14px;
}

/* =============================
   LIENS (INSCRIPTION / CONNEXION)
============================= */
.signup-link {
  text-align: center;
  margin-top: 15px;
  font-size: 0.95rem;
  color: #444;
}

.signup-link a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s;
}

.signup-link a:hover {
  border-color: var(--accent);
}

.subtitle {
  color: #4b5563;
  font-size: 0.95rem;
  margin-top: -6px;
  margin-bottom: 18px;
}

/* =============================
   BOUTONS MULTI-ÉTAPES
============================= */
.step-buttons {
  display: flex;
  justify-content: space-between;
  margin-top: 20px;
  gap: 10px;
}

.next-step,
.prev-step {
  padding: 10px 18px;
  background: #000;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.2s ease;
}

.next-step:hover,
.prev-step:hover {
  background: #333;
  transform: translateY(-1px);
}

/* =============================
   RESPONSIVE
============================= */
@media (max-width: 768px) {
  .form {
    max-width: 440px;
    padding: 34px 28px;
  }

  .form-title {
    font-size: 1.7rem;
  }

  .submit {
    font-size: 0.95rem;
  }
}

@media (max-width: 480px) {
  .form {
    max-width: 100%;
    padding: 28px 20px;
  }

  .form-title {
    font-size: 1.45rem;
  }

  .submit {
    padding: 10px;
    font-size: 0.9rem;
  }
}
