:root {
  --my-green-clear: rgb(28, 209, 91);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

h1 {
  text-align: center;
  margin-top: 24px;
  margin-bottom: 24px;

  font-family: ui-rounded, "Arial Rounded MT Bold", "Segoe UI", sans-serif;
  letter-spacing: -1.5px;
}

.img-contain {
  width: 100px;
  height: 100px;
  position: relative;

  border: 2px solid var(--my-green-clear);
  border-radius: 50%;
}

.field-error {
  margin-top: 12px;
  color: #b00020;
  font-size: 0.9rem;
  text-align: center;
}

#label-img {
  position: absolute;
  width: 50px;
  height: 50px;

  bottom: -20px;
  left: 25%;

  border: 2px solid var(--my-green-clear);
  background-color: white;
  border-radius: 50%;

  display: flex;
  flex-direction: row;

  justify-content: center;
  align-items: center;

  transition: all 0.2s ease-in;
}
#plus {
  font-size: 2rem;
  font-weight: bolder;
  font-family: ui-rounded, "Arial Rounded MT Bold", "Segoe UI", sans-serif;
}
#img-profil {
  display: none;
}
form {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;

  width: 100%;
  gap: 1.5rem;
}
.div-input {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;

  width: 70%;
}
.normal {
  border-bottom: 1px solid rgba(0, 0, 0, 0.753);
  transition: all 0.2s ease-in;
}

.phone-field {
  flex-direction: row;
  align-items: center;
}

input,
textarea {
  padding: 0.5rem;
  width: 90%;
  font-size: 1rem;
  border: none;
  font-family: inherit;
}

textarea {
  min-height: 92px;
  resize: vertical;
  line-height: 1.35;
}

input:focus,
textarea:focus {
  outline: none;
}

.bio-field {
  align-items: stretch;
}

.facultatif[hidden] {
  display: none !important;
}

.optional-toggle {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 70%;
  color: #222;
  font-size: 0.95rem;
  font-family: sans-serif;
  cursor: pointer;
  user-select: none;
  padding: 4px 0;
  transition: color 0.15s ease;
}

.optional-toggle:hover {
  color: #000;
}

.optional-toggle input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}

.custom-checkbox {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  border: 1.5px solid #111;
  border-radius: 5px;
  background: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.custom-checkbox svg {
  width: 13px;
  height: 13px;
  stroke: #fff;
  opacity: 0;
  transform: scale(0.6);
  transition: all 0.18s ease;
}

.optional-toggle:hover .custom-checkbox {
  border-color: var(--my-green-clear);
}

.optional-toggle input[type="checkbox"]:checked + .custom-checkbox {
  background: var(--my-green-clear);
  border-color: var(--my-green-clear);
}

.optional-toggle input[type="checkbox"]:checked + .custom-checkbox svg {
  opacity: 1;
  transform: scale(1);
}

.optional-toggle input[type="checkbox"]:focus-visible + .custom-checkbox {
  box-shadow: 0 0 0 3px rgba(28, 209, 91, 0.35);
}

.toggle-text {
  font-weight: 600;
  color: #111;
}

.toggle-badge {
  font-size: 0.74rem;
  color: #777;
  background: #f4f4f4;
  padding: 2px 7px;
  border-radius: 12px;
  border: 1px solid #e3e3e3;
  margin-left: 2px;
}

.social-field {
  flex-direction: row !important;
  align-items: center;
  gap: 8px;
}

.social-field .social-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #555;
  transition: color 0.2s ease;
}

.social-field:focus-within .social-icon {
  color: var(--my-green-clear);
}

.social-field input {
  flex: 1;
  width: 100%;
}

.social-field input:not(:placeholder-shown):invalid {
  color: #b00020;
}

.country-code {
  width: min(46%, 190px);
  padding: 0.5rem 0.25rem;
  border: none;
  border-right: 1px solid rgba(0, 0, 0, 0.2);
  background: transparent;
  font-size: 1rem;
}

.country-code:focus {
  outline: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

#message {
  min-height: 1.2rem;
  text-align: center;
  font-family: sans-serif;
}

#message.success {
  color: var(--my-green-clear);
}
#message.error {
  color: #b00020;
}
.pad {
  text-align: center;
  margin: 20px 0;
  font-family: sans-serif;
}

.pad label {
  display: block;
  color: #666;
  font-size: 14px;
  margin-bottom: 10px;
  transition: all 0.2s ease-in;
}

.cases {
  display: inline-flex;
  gap: 15px;
}

.ligne {
  width: 12px;
  height: 12px;
  border-bottom: 2px solid #000;
}
.ligne.ok {
  border: none;
  background: #000;
  border-radius: 50%;
  width: 12px;
  height: 12px;
  position: relative;
}

#input-pin {
  opacity: 0;
  pointer-events: none;
}

input[type="submit"] {
  width: 50%;
  height: 60px;

  letter-spacing: -1.5px;
  border-radius: 10px;

  background-color: black;
  color: white;

  font-weight: bolder;
  font-family: ui-rounded, "Arial Rounded MT Bold", "Segoe UI", sans-serif;
  font-size: 1.5rem;

  transition: all 0.2s ease-in;
}

@media (min-width: 768px) {
  form {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
    width: fit-content;
    margin: 0 auto;
  }

  .img-contain,
  h1,
  .send {
    grid-column: 1 / -1;
    justify-self: center;
  }
}
