

/* --- General & Layout --- */


main {
  position: relative;
  top: 120px; /* Offset to clear the fixed header */
  padding-bottom: 80px; /* Space above the footer */
  min-height: calc(100vh - 200px); /* Adjust based on header/footer heights if needed */
}

/* --- Section Headers --- */
.section-header {
  background-color: var(--color-red);
  width: fit-content;
  padding: 10px 20px;
  border-radius: 999px;
  margin-bottom: 30px;
  box-sizing: border-box;
}

.section-header h2 {
  margin: 0;
  font-size: 1.5em;
  color: var(--color-white);
  white-space: nowrap;
}

.section-header--left {
  margin-left: 0;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  padding-left: 40px;
}

.section-header--left h2 {
  margin-left: 100px;
}

/*
.section-header--right {
  This rule seems unused in the provided HTML.
  If it's meant for future use, keep it; otherwise, consider removing.
  margin-left: auto;
  margin-right: 0;
  border-radius: 999px;
  padding-right: 400px;
  padding-left: 20px;
}
.section-header--right h2 {
  margin-right: 100px;
}
*/

/* --- Main Form Container --- */
.largeur-form {
  max-width: 900px;
  margin: 60px auto;
  padding: 30px;
  box-sizing: border-box;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 20px;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.intro-section {
  text-align: center;
  margin-bottom: 70px;
}

.intro-section p {
  font-size: 1.35em;
  line-height: 1.7;
  max-width: 800px;
  margin: 0 auto;
  color: var(--color-gray-medium);
  font-weight: 300;
}

/* --- Why Join Section (Cards) --- */
.why-join-section {
  display: flex;
  justify-content: center;
  gap: 40px;
  margin-bottom: 70px;
  flex-wrap: wrap;
}

.card {
  background-color: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 40px;
  border-radius: 18px;
  flex: 1;
  min-width: 300px;
  max-width: 45%;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(to right, transparent, var(--color-red), transparent);
  opacity: 0.5;
  transition: all 0.3s ease;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: 0 18px 35px rgba(0, 0, 0, 0.35);
  background-color: rgba(255, 255, 255, 0.12);
}

.card:hover::before {
  height: 5px;
  opacity: 1;
}

.card h3 {
  color: var(--color-red);
  margin-top: 0;
  margin-bottom: 30px;
  font-size: 1.7em;
  text-align: center;
  letter-spacing: -0.02em;
  font-weight: 600;
}

.card ul {
  list-style: none;
  padding: 0;
  flex-grow: 1;
}

.card ul li {
  margin-bottom: 15px;
  font-size: 1.05em;
  line-height: 1.6;
  color: var(--color-white);
  position: relative;
  padding-left: 25px;
}

.card ul li::before {
  content: '✓';
  color: var(--color-red);
  font-size: 1.2em;
  position: absolute;
  left: 0;
  top: 2px;
  font-weight: bold;
}

/* --- Application Form --- */
.application-form-section form {
  background: transparent;
  padding: 0;
  border-radius: 8px;
}

.form-row {
  display: flex;
  gap: 25px;
  margin-bottom: 25px;
  flex-wrap: wrap;
}

.form-row input[type="text"],
.form-row input[type="email"],
.form-row input[type="tel"],
.form-row textarea {
  flex: 1;
  min-width: 250px;
  padding: 18px 20px;
  background-color: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  color: var(--color-white);
  font-size: 1.05em;
  outline: none;
  transition: border-color 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
  appearance: none;
}

.form-row input::placeholder,
.form-row textarea::placeholder {
  color: var(--color-gray-medium);
  opacity: 0.7;
}

.form-row input:focus,
.form-row textarea:focus {
  border-color: var(--color-red);
  box-shadow: 0 0 0 4px rgba(237, 41, 57, 0.3);
  background-color: rgba(255, 255, 255, 0.1);
}

.form-row textarea {
  resize: vertical;
  min-height: 120px;
}

.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;
}

/* --- File Upload --- */
.file-upload-container {
  text-align: center;
  margin-top: 50px;
  margin-bottom: 30px;
}

.file-upload-button {
  background: linear-gradient(to right, var(--color-blue-light), var(--color-blue));
  color: var(--color-white);
  padding: 18px 45px;
  border: none;
  border-radius: 30px;
  font-size: 1.25em;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 8px 15px rgba(29, 60, 97, 0.3);
  transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
  letter-spacing: 0.5px;
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.file-upload-button i {
  font-size: 1.2em;
}

.file-upload-button:hover {
  background: linear-gradient(to right, #7ab3f1, #2a5288);
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(29, 60, 97, 0.4);
}

.file-upload-button:active {
  transform: scale(0.98);
  box-shadow: 0 4px 10px rgba(29, 60, 97, 0.4);
}

.file-upload-button input[type="file"] {
  display: none;
}

.file-name-display {
  display: block;
  margin-top: 15px;
  color: var(--color-gray-medium);
  font-size: 0.95em;
  min-height: 20px;
}

/* --- Submit Button --- */
.submit-button-container {
  text-align: center;
  margin-top: 50px;
}

.submit-button {
  background: linear-gradient(to bottom, #FFFFFF, #F0F0F0);
  color: #ED2939;
  padding: 12px 24px;
  border: 1px solid #C0C0C0;
  border-radius: 999px;
  font-size: 1.1em;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
  text-align: center;
  display: inline-block;
}

.submit-button:hover {
  background: linear-gradient(to bottom, #F0F0F0, #FFFFFF);
  transform: translateY(-2px);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

.submit-button:active {
  transform: translateY(0);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.consent-text {
  font-size: 0.95em;
  color: var(--color-gray-medium);
  margin-top: 25px;
  font-weight: 300;
}

/* --- Responsive Adjustments --- */
@media (max-width: 890px) {
  .section-header--left h2 {
    margin-left: 50px; /* Reduced offset for smaller screens */
  }

  .why-join-section {
    flex-direction: column;
    gap: 30px;
    margin-bottom: 50px;
  }

  .card {
    max-width: 90%; /* Allows cards to take more width on tablets */
    margin: 0 auto;
  }

  .largeur-form {
    margin: 60px 20px; /* Adjusted margin for overall form on tablets */
    padding: 25px;
  }
}

@media (max-width: 768px) {
  .largeur-form {
    margin: 40px 15px; /* Tighter margins on smaller screens */
    padding: 20px;
  }

  .intro-section {
    margin-bottom: 40px;
  }

  .intro-section p {
    font-size: 1.1em;
  }

  .why-join-section {
    gap: 25px;
    margin-bottom: 40px;
  }

  .card {
    padding: 25px;
    border-radius: 15px;
  }

  .card h3 {
    font-size: 1.4em;
    margin-bottom: 20px;
  }

  .card ul li {
    font-size: 0.9em;
  }

  .form-row {
    flex-direction: column;
    gap: 18px;
    margin-bottom: 18px;
  }

  .form-row input,
  .form-row textarea {
    padding: 14px 16px;
    border-radius: 10px;
    font-size: 0.95em;
  }

  .file-upload-container {
    margin-top: 35px;
    margin-bottom: 20px;
  }

  .file-upload-button {
    width: 90%; /* Make button closer to full width */
    padding: 15px 0;
    font-size: 1.05em;
  }

  .file-name-display {
    font-size: 0.8em;
  }

  .submit-button-container {
    margin-top: 35px;
  }

  .submit-button {
    width: 90%; /* Make button closer to full width */
    padding: 12px 0;
    font-size: 1em;
  }

  .consent-text {
    font-size: 0.8em;
  }
}

@media (max-width: 480px) {
  .largeur-form {
    margin: 20px 10px;
    padding: 15px;
  }

  .intro-section p {
    font-size: 0.95em;
  }

  .why-join-section {
    gap: 15px;
  }

  .card {
    padding: 20px;
  }

  .card h3 {
    font-size: 1.2em;
  }

  .card ul li {
    font-size: 0.85em;
    padding-left: 20px;
  }

  .card ul li::before {
    font-size: 1em;
  }

  .form-row {
    gap: 12px;
    margin-bottom: 12px;
  }

  .form-row input,
  .form-row textarea {
    padding: 10px 12px;
    font-size: 0.85em;
  }

  .file-upload-button {
    font-size: 0.9em;
    padding: 12px 0;
  }

  .submit-button {
    font-size: 0.9em;
    padding: 10px 0;
  }
}