/* Syron Finance Newsletter Wide Layout Styling - Light/Dark Theme Adaptive */
.syron-finance-wide-form {
  border-radius: 12px !important;
  padding: 30px !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04) !important;
  border: 1px solid !important;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 !important;
  transition: all 0.3s ease !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
}

/* Light Theme Colors */
html[scheme="light"] .syron-finance-wide-form,
html:not([scheme]) .syron-finance-wide-form {
  background: #ffffff !important;
  border-color: #379d7e !important;
  color: #1f2937 !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04) !important;
}

/* Dark Theme Colors */
html[scheme="dark"] .syron-finance-wide-form {
  background: #272c31 !important;
  border-color: #379d7e !important;
  color: #f1f5f9 !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25) !important;
}

/* Newsletter Description - Inline with form */
.syron-finance-wide-form .newsletter-description {
  flex: 0 0 auto !important;
  margin: 0 !important;
  padding: 0 !important;
  display: flex !important;
  align-items: center !important;
}

.syron-finance-wide-form .newsletter-description p {
  font-size: 16px !important;
  font-weight: 600 !important;
  line-height: 1 !important;
  margin: 0 !important;
  padding: 0 !important;
  white-space: nowrap !important;
  display: flex !important;
  align-items: center !important;
  height: 54px !important;
}

/* Light Theme Text Colors */
html[scheme="light"] .syron-finance-wide-form .newsletter-description p,
html:not([scheme]) .syron-finance-wide-form .newsletter-description p {
  color: #1f2937 !important;
}

/* Dark Theme Text Colors */
html[scheme="dark"] .syron-finance-wide-form .newsletter-description p {
  color: #e2e8f0 !important;
}

/* Form Layout - Single Row with description */
.syron-finance-wide-form .form-row {
  display: flex !important;
  gap: 15px !important;
  align-items: flex-start !important;
  justify-content: center !important;
  flex-wrap: wrap !important;
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
}

.syron-finance-wide-form .form-row .field-group {
  flex: 1 !important;
  min-width: 200px !important;
  max-width: 250px !important;
  display: block !important;
  margin-bottom: 10px !important;
  box-sizing: border-box !important;
}

.syron-finance-wide-form .form-row .button-group {
  flex: 0 0 auto !important;
  display: flex !important;
  align-items: center !important;
  margin-bottom: 10px !important;
  box-sizing: border-box !important;
}

/* Form Field Styling */
.syron-finance-wide-form .wpcf7-form-control-wrap {
  position: relative !important;
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  box-sizing: border-box !important;
}

.syron-finance-wide-form input[type="text"],
.syron-finance-wide-form input[type="email"] {
  width: 100% !important;
  max-width: 100% !important;
  padding: 14px 18px !important;
  border: 2px solid !important;
  border-radius: 8px !important;
  font-size: 16px !important;
  transition: all 0.3s ease !important;
  box-sizing: border-box !important;
  margin: 0 !important;
  height: 54px !important;
  min-width: 0 !important;
  display: flex !important;
  align-items: center !important;
}

/* Light Theme Input Colors */
html[scheme="light"] .syron-finance-wide-form input[type="text"],
html[scheme="light"] .syron-finance-wide-form input[type="email"],
html:not([scheme]) .syron-finance-wide-form input[type="text"],
html:not([scheme]) .syron-finance-wide-form input[type="email"] {
  border-color: #379d7e !important;
  background-color: #ffffff !important;
  color: #1f2937 !important;
}

html[scheme="light"] .syron-finance-wide-form input[type="text"]:focus,
html[scheme="light"] .syron-finance-wide-form input[type="email"]:focus,
html:not([scheme]) .syron-finance-wide-form input[type="text"]:focus,
html:not([scheme]) .syron-finance-wide-form input[type="email"]:focus {
  outline: none !important;
  border-color: #2a7a66 !important;
  background-color: #ffffff !important;
  box-shadow: 0 0 0 3px rgba(55, 157, 126, 0.15) !important;
}

html[scheme="light"] .syron-finance-wide-form input[type="text"]::placeholder,
html[scheme="light"] .syron-finance-wide-form input[type="email"]::placeholder,
html:not([scheme]) .syron-finance-wide-form input[type="text"]::placeholder,
html:not([scheme]) .syron-finance-wide-form input[type="email"]::placeholder {
  color: #6b7280 !important;
  opacity: 0.8 !important;
}

/* Dark Theme Input Colors */
html[scheme="dark"] .syron-finance-wide-form input[type="text"],
html[scheme="dark"] .syron-finance-wide-form input[type="email"] {
  border-color: #379d7e !important;
  background-color: #1f2328 !important;
  color: #f1f5f9 !important;
}

html[scheme="dark"] .syron-finance-wide-form input[type="text"]:focus,
html[scheme="dark"] .syron-finance-wide-form input[type="email"]:focus {
  outline: none !important;
  border-color: #2a7a66 !important;
  background-color: #1f2328 !important;
  box-shadow: 0 0 0 3px rgba(55, 157, 126, 0.15) !important;
}

html[scheme="dark"] .syron-finance-wide-form input[type="text"]::placeholder,
html[scheme="dark"] .syron-finance-wide-form input[type="email"]::placeholder {
  color: #94a3b8 !important;
  opacity: 0.8 !important;
}

/* Submit Button */
.syron-finance-wide-form input[type="submit"] {
  border: none !important;
  border-radius: 8px !important;
  font-size: 16px !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  transition: all 0.3s ease !important;
  text-transform: none !important;
  letter-spacing: 0.3px !important;
  white-space: nowrap !important;
  height: 54px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-width: 140px !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
  position: relative !important;
  padding: 0 24px !important;
  margin: 0 !important;
  min-width: 0 !important;
}

/* Light Theme Button Colors */
html[scheme="light"] .syron-finance-wide-form input[type="submit"],
html:not([scheme]) .syron-finance-wide-form input[type="submit"] {
  background: #379d7e !important;
  color: white !important;
}

html[scheme="light"] .syron-finance-wide-form input[type="submit"]:hover,
html:not([scheme]) .syron-finance-wide-form input[type="submit"]:hover {
  background: #2a7a66 !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 6px 16px rgba(55, 157, 126, 0.3) !important;
}

/* Dark Theme Button Colors */
html[scheme="dark"] .syron-finance-wide-form input[type="submit"] {
  background: #379d7e !important;
  color: white !important;
}

html[scheme="dark"] .syron-finance-wide-form input[type="submit"]:hover {
  background: #2a7a66 !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 6px 16px rgba(55, 157, 126, 0.3) !important;
}

.syron-finance-wide-form input[type="submit"]:active {
  transform: translateY(0) !important;
}

/* Error and Success Messages */
.syron-finance-wide-form .wpcf7-not-valid-tip {
  font-size: 12px !important;
  margin-top: 6px !important;
  display: block !important;
  position: static !important;
  width: 100% !important;
  padding: 6px 10px !important;
  border-radius: 4px !important;
  border: 1px solid !important;
  z-index: 10 !important;
  box-sizing: border-box !important;
}

/* Light Theme Error Messages */
html[scheme="light"] .syron-finance-wide-form .wpcf7-not-valid-tip,
html:not([scheme]) .syron-finance-wide-form .wpcf7-not-valid-tip {
  color: #dc2626 !important;
  background: rgba(254, 242, 242, 0.95) !important;
  border-color: #fecaca !important;
}

/* Dark Theme Error Messages */
html[scheme="dark"] .syron-finance-wide-form .wpcf7-not-valid-tip {
  color: #f87171 !important;
  background: rgba(127, 29, 29, 0.3) !important;
  border-color: #7f1d1d !important;
}

.syron-finance-wide-form .wpcf7-validation-errors {
  padding: 12px !important;
  border-radius: 6px !important;
  margin-bottom: 15px !important;
  font-size: 14px !important;
  border: 1px solid !important;
}

/* Light Theme Validation Errors */
html[scheme="light"] .syron-finance-wide-form .wpcf7-validation-errors,
html:not([scheme]) .syron-finance-wide-form .wpcf7-validation-errors {
  background: #fef2f2 !important;
  border-color: #fecaca !important;
  color: #dc2626 !important;
}

/* Dark Theme Validation Errors */
html[scheme="dark"] .syron-finance-wide-form .wpcf7-validation-errors {
  background: rgba(127, 29, 29, 0.3) !important;
  border-color: #7f1d1d !important;
  color: #f87171 !important;
}

.syron-finance-wide-form .wpcf7-mail-sent-ok {
  padding: 12px !important;
  border-radius: 6px !important;
  margin-bottom: 15px !important;
  font-size: 14px !important;
  border: 1px solid !important;
}

/* Light Theme Success Messages */
html[scheme="light"] .syron-finance-wide-form .wpcf7-mail-sent-ok,
html:not([scheme]) .syron-finance-wide-form .wpcf7-mail-sent-ok {
  background: #f0fdf4 !important;
  border-color: #379d7e !important;
  color: #166534 !important;
}

/* Dark Theme Success Messages */
html[scheme="dark"] .syron-finance-wide-form .wpcf7-mail-sent-ok {
  background: rgba(39, 44, 49, 0.8) !important;
  border-color: #379d7e !important;
  color: #379d7e !important;
}

/* Loading State */
.syron-finance-wide-form .wpcf7-spinner {
  display: none !important;
  width: 20px !important;
  height: 20px !important;
  border: 2px solid #e5e7eb !important;
  border-radius: 50% !important;
  animation: spin 1s linear infinite !important;
  position: absolute !important;
  right: 12px !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  z-index: 10 !important;
}

/* Light Theme Spinner */
html[scheme="light"] .syron-finance-wide-form .wpcf7-spinner,
html:not([scheme]) .syron-finance-wide-form .wpcf7-spinner {
  border-top: 2px solid #379d7e !important;
}

/* Dark Theme Spinner */
html[scheme="dark"] .syron-finance-wide-form .wpcf7-spinner {
  border-top: 2px solid #379d7e !important;
}

/* Show spinner during submission */
.syron-finance-wide-form.submitting .wpcf7-spinner {
  display: block !important;
  width: 22px !important;
  height: 22px !important;
  z-index: 15 !important;
  animation: spin 0.8s linear infinite !important;
}

/* Light Theme Submitting Spinner */
html[scheme="light"] .syron-finance-wide-form.submitting .wpcf7-spinner,
html:not([scheme]) .syron-finance-wide-form.submitting .wpcf7-spinner {
  border: 3px solid #e5e7eb !important;
  border-top: 3px solid #379d7e !important;
  border-right: 3px solid #7bc5a7 !important;
  box-shadow: 0 2px 8px rgba(55, 157, 126, 0.3) !important;
}

/* Dark Theme Submitting Spinner */
html[scheme="dark"] .syron-finance-wide-form.submitting .wpcf7-spinner {
  border: 3px solid #475569 !important;
  border-top: 3px solid #379d7e !important;
  border-right: 3px solid #7bc5a7 !important;
  box-shadow: 0 2px 8px rgba(55, 157, 126, 0.3) !important;
}

/* Submitting state styling */
.syron-finance-wide-form.submitting {
  position: relative !important;
  pointer-events: none !important;
}

.syron-finance-wide-form.submitting::before {
  content: "" !important;
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  border-radius: 12px !important;
  z-index: 5 !important;
  backdrop-filter: blur(1px) !important;
}

/* Light Theme Submitting Overlay */
html[scheme="light"] .syron-finance-wide-form.submitting::before,
html:not([scheme]) .syron-finance-wide-form.submitting::before {
  background: rgba(255, 255, 255, 0.8) !important;
}

/* Dark Theme Submitting Overlay */
html[scheme="dark"] .syron-finance-wide-form.submitting::before {
  background: rgba(39, 44, 49, 0.8) !important;
}

.syron-finance-wide-form.submitting input[type="submit"] {
  background: #9ca3af !important;
  cursor: not-allowed !important;
  transform: none !important;
  box-shadow: none !important;
  position: relative !important;
  z-index: 10 !important;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Response messages - Hidden by Default and Centered */
.syron-finance-wide-form .wpcf7-response-output {
  padding: 12px 16px !important;
  border-radius: 8px !important;
  margin: 15px 0 0 0 !important;
  font-size: 14px !important;
  font-weight: 500 !important;
  display: none !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
  border-width: 2px !important;
  border-style: solid !important;
  transition: none !important;
}

/* Show response output only when form has a state */
.syron-finance-wide-form.sent .wpcf7-response-output,
.syron-finance-wide-form.failed .wpcf7-response-output,
.syron-finance-wide-form.aborted .wpcf7-response-output,
.syron-finance-wide-form.invalid .wpcf7-response-output,
.syron-finance-wide-form.spam .wpcf7-response-output,
.syron-finance-wide-form.unaccepted .wpcf7-response-output {
  display: flex !important;
}

/* Success message colors - applied immediately when shown */
html[scheme="light"] .syron-finance-wide-form.sent .wpcf7-response-output,
html:not([scheme]) .syron-finance-wide-form.sent .wpcf7-response-output {
  background: #f0fdf4 !important;
  border-color: #22c55e !important;
  color: #166534 !important;
}

html[scheme="dark"] .syron-finance-wide-form.sent .wpcf7-response-output {
  background: rgba(22, 101, 52, 0.2) !important;
  border-color: #22c55e !important;
  color: #4ade80 !important;
}

/* Error states - All error types */
html[scheme="light"] .syron-finance-wide-form.failed .wpcf7-response-output,
html[scheme="light"] .syron-finance-wide-form.aborted .wpcf7-response-output,
html[scheme="light"] .syron-finance-wide-form.invalid .wpcf7-response-output,
html[scheme="light"] .syron-finance-wide-form.spam .wpcf7-response-output,
html[scheme="light"] .syron-finance-wide-form.unaccepted .wpcf7-response-output,
html:not([scheme]) .syron-finance-wide-form.failed .wpcf7-response-output,
html:not([scheme]) .syron-finance-wide-form.aborted .wpcf7-response-output,
html:not([scheme]) .syron-finance-wide-form.invalid .wpcf7-response-output,
html:not([scheme]) .syron-finance-wide-form.spam .wpcf7-response-output,
html:not([scheme]) .syron-finance-wide-form.unaccepted .wpcf7-response-output {
  background: #fef2f2 !important;
  border-color: #ef4444 !important;
  color: #991b1b !important;
}

html[scheme="dark"] .syron-finance-wide-form.failed .wpcf7-response-output,
html[scheme="dark"] .syron-finance-wide-form.aborted .wpcf7-response-output,
html[scheme="dark"] .syron-finance-wide-form.invalid .wpcf7-response-output,
html[scheme="dark"] .syron-finance-wide-form.spam .wpcf7-response-output,
html[scheme="dark"] .syron-finance-wide-form.unaccepted .wpcf7-response-output {
  background: rgba(127, 29, 29, 0.3) !important;
  border-color: #dc2626 !important;
  color: #f87171 !important;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .syron-finance-wide-form {
    padding: 25px 20px !important;
    margin: 0 15px !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .syron-finance-wide-form .form-row {
    flex-direction: column !important;
    gap: 15px !important;
    align-items: stretch !important;
  }

  .syron-finance-wide-form .newsletter-description {
    order: -1 !important;
    text-align: center !important;
    margin-bottom: 10px !important;
  }

  .syron-finance-wide-form .newsletter-description p {
    white-space: normal !important;
    font-size: 16px !important;
  }

  .syron-finance-wide-form .form-row .field-group {
    max-width: 100% !important;
    min-width: 100% !important;
  }

  .syron-finance-wide-form input[type="submit"] {
    width: 100% !important;
    min-width: 100% !important;
  }
}

@media (max-width: 480px) {
  .syron-finance-wide-form {
    padding: 20px 15px !important;
    margin: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .syron-finance-wide-form input[type="text"],
  .syron-finance-wide-form input[type="email"] {
    padding: 12px 16px !important;
    font-size: 14px !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }

  .syron-finance-wide-form .newsletter-description p {
    font-size: 15px !important;
  }

  .syron-finance-wide-form input[type="submit"] {
    height: 48px !important;
    font-size: 15px !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }
}

/* Override common theme conflicts */
.syron-finance-wide-form * {
  box-sizing: border-box !important;
}

.syron-finance-wide-form button {
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
}

.syron-finance-wide-form p {
  margin: 0 !important;
  padding: 0 !important;
}

.syron-finance-wide-form input {
  outline: none !important;
  box-shadow: none !important;
}

/* Light Theme Input Focus */
html[scheme="light"] .syron-finance-wide-form input:focus,
html:not([scheme]) .syron-finance-wide-form input:focus {
  box-shadow: 0 0 0 3px rgba(55, 157, 126, 0.15) !important;
}

/* Dark Theme Input Focus */
html[scheme="dark"] .syron-finance-wide-form input:focus {
  box-shadow: 0 0 0 3px rgba(55, 157, 126, 0.15) !important;
}

/* Google reCAPTCHA Badge - Ensure it stays on top */
.grecaptcha-badge {
  z-index: 9999 !important;
}
