/* --- Partie formulaire générale --- */

.form-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 5rem 1rem;
  min-height: 70vh; /* para centrar verticalmente */
  background-color: white;
  margin-top: 20px;
}

.form-box {
  background-color: white;
  border-radius: 12px;
  padding: 3rem 2rem;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
  width: 100%;
  max-width: 400px;
}

.form-box h2 {
  color: #007bff; /* color primario */
  margin-bottom: 2rem;
  font-size: 2rem;
  text-align: center;
}

.form-box .form {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.form-box .form label {
  font-weight: 600;
  color: #333;
}

.form-box .form input,
.form-box .form textarea,
.form-box .form select {
  padding: 0.8rem 1rem;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-family: inherit;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.select-beauty {
  padding: 0.8rem 1rem;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-family: inherit;
  font-size: 1rem;
  background-color: #fff;
  transition: border-color 0.3s ease;
  width: 100%;
  max-width: 300px;
  appearance: none; /* Removes default arrow styling in some browsers */
  background-image: url("data:image/svg+xml;utf8,<svg fill='gray' height='16' viewBox='0 0 24 24' width='16' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 1rem;
  cursor: pointer;
}

.select-beauty:focus {
  border-color: #007bff;
  outline: none;
}

.centered-form {
  text-align: center;
  margin: 1em 0;
}

.form-box .form input:focus {
  border-color: #007bff;
  outline: none;
}

.form-box .form button {
  margin: 1.5rem auto 0 auto;
  background-color: #007bff;
  color: white;
  border: none;
  padding: 0.85rem 1.5rem;
  border-radius: 8px;
  font-size: 1.1rem;
  cursor: pointer;
  font-weight: bold;
  transition: background-color 0.3s ease;
}

.form-box .form button:hover {
  background-color: #339cff;
}

.form-box .signup-link {
  margin-top: 1rem;
  font-size: 0.9rem;
  text-align: center;
  color: #444;
}

.form-box .signup-link a {
  color: #007bff;
  text-decoration: none;
  font-weight: 600;
}

.form-box .signup-link a:hover {
  text-decoration: underline;
}

/* Responsive */
@media (max-width: 480px) {
  .form-box {
    padding: 2rem 1rem;
    max-width: 90%;
  }
}

/* Horizontal form layout */
.form-container-horizontal {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 5rem 1rem;
  min-height: 70vh; /* para centrar verticalmente */
  background-color: white;
  margin-top: 20px;
}

.form-box-wide {
  background-color: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
  width: 100%;
  max-width: 1200px;
}

.form-box-wide h2 {
  color: #007bff;
  margin-top: 0;
  margin-bottom: 1rem;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.form-grid label {
  font-weight: 600;
  color: #333;
}

.form-grid input,
.form-grid textarea,
.form-grid select {
  padding: 0.8rem 1rem;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-family: inherit;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-grid input:focus,
.form-grid textarea:focus,
.form-grid select:focus {
  border-color: #007bff;
  outline: none;
}

.form-grid textarea {
  height: calc(2 * 3.6rem + 2rem); /* ~2 input heights + gap */
  resize: vertical; /* Optional: allow manual resizing */
}

.form-buttons {
  grid-column: 1 / -1;
  display: flex;
  justify-content: center;
  gap: 0.8rem;
  margin-top: 1.5rem;
}

.form-buttons button,
.form-buttons .btn-standard {
  background-color: #007bff;
  color: white;
  border: none;
  padding: 0.5rem 1rem; /* Smaller padding */
  border-radius: 6px; /* Slightly tighter corners */
  font-size: 0.95rem; /* Smaller text */
  cursor: pointer;
  font-weight: 600;
  text-decoration: none;
  text-align: center;
  min-width: 120px; /* Optional: consistent button size */
  max-width: 150px;
}

.form-buttons button:hover,
.form-buttons .btn-standard:hover {
  background-color: #339cff;
}

.form-inline-flex {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
}

/* Mobile adaptation */
@media (max-width: 768px) {
  .form-grid {
    grid-template-columns: 1fr;
  }
}
