/*
 * CONTACT PAGE STYLES
 * Pages: /contact/, /ampere/contact/
 */

/* Hero section */

.hero-section {
  font-weight: 600;
  text-align: center;
  padding-top: 200px;
}

.hero-section h1,
.hero-section p {
  max-width: 1000px;
  margin: 0 auto 24px;
}

.hero-section p {
  font-size: 20px;
}

.contact-form-section .hero-section {
  text-align: left;
  padding-top: 200px;
  margin-bottom: 40px;
}

.contact-form-section .hero-section h1 {
  text-align: left;
  margin: 0 0 16px 0;
  font-family: "Source Sans 3", sans-serif;
  font-size: 40px;
  font-weight: 700;
  line-height: 48px;
  letter-spacing: 1px;
  color: rgba(204, 229, 255, 0.95);
  max-width: 800px;
}

.contact-form-section .hero-section .hero-description {
  text-align: left;
  font-family: "Source Sans 3", sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 24px;
  letter-spacing: 1px;
  margin: 0;
  max-width: 800px;
  color: rgba(204, 229, 255, 0.95);
}

/* Contact form */

.contact-form-wrapper {
  max-width: 1326px;
  margin: 0 auto 80px 0;
  padding: 0 0 0 0;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
  max-width: 800px;
  align-items: flex-start;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
  max-width: 800px;
}

.form-group.full-width {
  width: 100%;
  max-width: 800px;
}

/* Fix Cloudflare Turnstile visibility and reserve space to prevent CLS */
.form-group:has(.cf-turnstile) {
  display: block;
  min-height: 75px;
}

.cf-turnstile {
  min-height: 75px;
}

.form-group label {
  color: rgba(204, 229, 255, 0.95);
  font-size: 16px;
  font-weight: 400;
  font-family: "Source Sans 3", sans-serif;
  line-height: 24px;
  letter-spacing: 1px;
}

.form-group input,
.form-group textarea {
  background-color: #000e1c;
  border: 1px solid #2a5580;
  border-radius: 4px;
  overflow: hidden;
  color: var(--Text-Standard-Standard-Disabled, rgba(204, 229, 255, 0.46));
  -webkit-text-fill-color: var(--Text-Standard-Standard-Disabled, rgba(204, 229, 255, 0.46));
  text-overflow: ellipsis;
  font-family: "Source Sans 3", sans-serif;
  font-size: var(--Font-Size-Body-Default, 16px);
  font-style: normal;
  font-weight: 400;
  line-height: var(--Font-Line-Height-Body-Default, 24px);
  letter-spacing: var(--Font-Letter-Spacing-Body-Default, 1px);
  padding: 12px 16px;
  width: 100%;
  box-sizing: border-box;
  height: 52px;
}

.form-group input:valid,
.form-group input:invalid,
.form-group textarea:valid,
.form-group textarea:invalid {
  color: var(--Text-Standard-Standard-Disabled, rgba(204, 229, 255, 0.46));
  -webkit-text-fill-color: var(--Text-Standard-Standard-Disabled, rgba(204, 229, 255, 0.46));
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: rgba(204, 229, 255, 0.46);
  font-family: "Source Sans 3", sans-serif;
  font-size: 16px;
  font-style: normal;
  font-weight: 400;
  line-height: 24px;
  letter-spacing: 1px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.form-group input:focus,
.form-group textarea:focus {
  border: 1px solid #2a5580;
  outline: none;
}

/* Override browser autofill styling - WebKit (Chrome, Safari) */
.form-group input:-webkit-autofill,
.form-group input:-webkit-autofill:hover,
.form-group input:-webkit-autofill:focus,
.form-group input:-webkit-autofill:active,
.contact-form input:-webkit-autofill,
.contact-form input:-webkit-autofill:hover,
.contact-form input:-webkit-autofill:focus,
.contact-form input:-webkit-autofill:active,
.contact-form textarea:-webkit-autofill,
.contact-form textarea:-webkit-autofill:hover,
.contact-form textarea:-webkit-autofill:focus,
.contact-form textarea:-webkit-autofill:active {
  -webkit-box-shadow: 0 0 0 1000px #000e1c inset !important;
  -webkit-text-fill-color: #CCE5FF !important;
  box-shadow: 0 0 0 1000px #000e1c inset !important;
  color: #CCE5FF !important;
  caret-color: #CCE5FF !important;
  background-color: #000e1c !important;
  transition: background-color 5000s ease-in-out 0s, color 5000s ease-in-out 0s !important;
  -webkit-transition: background-color 5000s ease-in-out 0s, color 5000s ease-in-out 0s !important;
}

/* Override browser autofill styling - Standard (Firefox, modern browsers) */
.form-group input:autofill,
.form-group input:autofill:hover,
.form-group input:autofill:focus,
.form-group input:autofill:active,
.contact-form input:autofill,
.contact-form input:autofill:hover,
.contact-form input:autofill:focus,
.contact-form input:autofill:active,
.contact-form textarea:autofill,
.contact-form textarea:autofill:hover,
.contact-form textarea:autofill:focus,
.contact-form textarea:autofill:active {
  box-shadow: 0 0 0 1000px #000e1c inset !important;
  -webkit-text-fill-color: #CCE5FF !important;
  color: #CCE5FF !important;
  caret-color: #CCE5FF !important;
  background-color: #000e1c !important;
}

.form-group textarea {
  min-height: 205px;
  height: 205px;
  resize: none;
  padding-top: 20px;
}

.invalid-feedback {
  display: none;
  color: #dc3545;
  font-size: 14px;
}

/* Contact form error message */
.contact-form-error {
  color: #ff6b6b;
  font-size: 16px;
  margin-bottom: 16px;
  padding: 12px 16px;
  background: rgba(255, 107, 107, 0.1);
  border-radius: 8px;
  border: 1px solid rgba(255, 107, 107, 0.3);
}

/* Submit button */
.btn-submit-contact {
  background-color: #00dd8d;
  color: var(--Icons-On-Light-Image-Icon-on-Light-Image-2-High-Emphasis, rgba(5, 56, 107, 0.95));
  padding: 8px 16px;
  border-radius: 8px;
  border: none;
  font-family: "Source Sans 3", sans-serif;
  font-size: var(--Font-Size-Other-Button, 14px);
  font-style: normal;
  font-weight: 700;
  line-height: var(--Font-Line-Height-Other-Button, 16px);
  letter-spacing: var(--Font-Letter-Spacing-Other-Button, 1.25px);
  cursor: pointer;
  transition: opacity 0.2s ease;
  height: 40px;
  min-height: 40px;
  max-height: 40px;
  min-width: fit-content;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  text-align: center;
}

.btn-submit-contact:hover {
  opacity: 0.9;
}

.btn-submit-contact .btn-icon {
  width: 20px;
  height: 20px;
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
}

.submit-group {
  display: flex;
  justify-content: flex-start;
  width: 100%;
  max-width: 800px;
}

.contact-form-section .submit-group {
  justify-content: flex-start;
  width: 100%;
}

.contact-form-section .form-row .submit-group {
  justify-content: flex-start;
  width: 100%;
  flex: 1;
}

/* Responsive */

@media (max-width: 1023px) {
  .hero-section {
    padding-top: 80px;
  }

  .contact-form-section .hero-section {
    padding-top: 32px !important;
    margin-bottom: 24px;
  }

  .contact-form-wrapper {
    padding: 0;
  }

  .form-group,
  .submit-group {
    padding-left: 0;
    padding-right: 0;
  }
}

@media (max-width: 480px) {
  .contact-form-section .hero-section {
    padding-top: 24px !important;
    margin-bottom: 20px;
  }

  .contact-form-section .hero-section h1 {
    font-size: 32px;
    line-height: 40px;
  }
}
