/* =========================================================
   CONTACT FORM 7 + QWERY
   CSS DEFINITIVO SEGURO
   Compatible con:
   - cf7-row
   - cf7-grid-2
   - cf7-grid-3
   - cf7-col
   - cf7-actions
   - cf7-legal
   - cf7-accept-row

   Sticky opcional:
   - verus-sticky-sidebar
========================================================= */


/* ===== 1) BASE GENERAL ===== */

.wpcf7,
.wpcf7 form {
  margin: 0 !important;
  padding: 0 !important;
}

.wpcf7 p {
  margin: 0 0 6px 0 !important;
  padding: 0 !important;
}

.wpcf7 br {
  display: none !important;
}

.wpcf7 .wpcf7-form-control-wrap {
  display: block !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  box-sizing: border-box !important;
}


/* ===== 2) ESTRUCTURA ===== */

.wpcf7 .cf7-row {
  width: 100% !important;
  margin: 0 0 6px 0 !important;
  padding: 0 !important;
  box-sizing: border-box !important;
}

.wpcf7 .cf7-grid-2,
.wpcf7 .cf7-grid-3 {
  display: flex !important;
  flex-wrap: nowrap !important;
  gap: 6px !important;
  width: 100% !important;
  margin: 0 0 6px 0 !important;
  padding: 0 !important;
  box-sizing: border-box !important;
}

.wpcf7 .cf7-grid-2 > .cf7-col,
.wpcf7 .cf7-grid-3 > .cf7-col {
  flex: 1 1 0 !important;
  min-width: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  box-sizing: border-box !important;
}

.wpcf7 .cf7-actions,
.wpcf7 .cf7-actions p {
  margin: 0 !important;
  padding: 0 !important;
}


/* ===== 3) CAMPOS GENERALES ===== */

.wpcf7 input:not([type="submit"]):not([type="button"]):not([type="reset"]):not([type="checkbox"]):not([type="radio"]):not([type="file"]):not([type="range"]),
.wpcf7 select,
.wpcf7 textarea {
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
  height: 32px !important;
  min-height: 32px !important;
  margin: 0 !important;
  padding: 7px 10px !important;
  border: 1px solid #cfd8dc !important;
  border-radius: 4px !important;
  background: #ffffff !important;
  color: #222222 !important;
  font-size: 14px !important;
  font-family: inherit !important;
  line-height: 1.2 !important;
  box-sizing: border-box !important;
  box-shadow: none !important;
  outline: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  appearance: none !important;
}

.wpcf7 input::placeholder,
.wpcf7 textarea::placeholder {
  color: #7a7a7a !important;
  opacity: 1 !important;
  font-size: 14px !important;
  line-height: 1.2 !important;
}


/* ===== 4) TEXTAREA ===== */

.wpcf7 textarea {
  height: 46px !important;
  min-height: 46px !important;
  max-height: 60px !important;
  resize: vertical !important;
  overflow: auto !important;
}


/* ===== 5) SELECT ===== */

.wpcf7 select {
  color: #7a7a7a !important;
  background-image: none !important;
  padding-right: 10px !important;
}

.wpcf7 select option {
  color: #222222 !important;
}

.wpcf7 select:focus,
.wpcf7 select:valid {
  color: #222222 !important;
}


/* ===== 6) FECHA ===== */

.wpcf7 input[type="date"] {
  color: #7a7a7a !important;
  padding-right: 10px !important;
}

.wpcf7 input[type="date"]::-webkit-datetime-edit,
.wpcf7 input[type="date"]::-webkit-date-and-time-value,
.wpcf7 input[type="date"]::-webkit-datetime-edit-text,
.wpcf7 input[type="date"]::-webkit-datetime-edit-month-field,
.wpcf7 input[type="date"]::-webkit-datetime-edit-day-field,
.wpcf7 input[type="date"]::-webkit-datetime-edit-year-field {
  color: #7a7a7a !important;
}

.wpcf7 input[type="date"]:focus,
.wpcf7 input[type="date"]:valid,
.wpcf7 input[type="date"]:focus::-webkit-datetime-edit,
.wpcf7 input[type="date"]:valid::-webkit-datetime-edit,
.wpcf7 input[type="date"]:focus::-webkit-date-and-time-value,
.wpcf7 input[type="date"]:valid::-webkit-date-and-time-value,
.wpcf7 input[type="date"]:focus::-webkit-datetime-edit-text,
.wpcf7 input[type="date"]:valid::-webkit-datetime-edit-text,
.wpcf7 input[type="date"]:focus::-webkit-datetime-edit-month-field,
.wpcf7 input[type="date"]:valid::-webkit-datetime-edit-month-field,
.wpcf7 input[type="date"]:focus::-webkit-datetime-edit-day-field,
.wpcf7 input[type="date"]:valid::-webkit-datetime-edit-day-field,
.wpcf7 input[type="date"]:focus::-webkit-datetime-edit-year-field,
.wpcf7 input[type="date"]:valid::-webkit-datetime-edit-year-field {
  color: #222222 !important;
}

.wpcf7 input[type="date"]::-webkit-calendar-picker-indicator {
  opacity: 0.75;
  cursor: pointer;
}


/* ===== 7) NUMBER / FILE / RANGE ===== */

.wpcf7 input[type="number"] {
  -moz-appearance: textfield !important;
  appearance: textfield !important;
}

.wpcf7 input[type="number"]::-webkit-outer-spin-button,
.wpcf7 input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none !important;
  margin: 0 !important;
}

.wpcf7 input[type="file"] {
  display: block !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 7px 0 !important;
  color: #222222 !important;
  font-size: 14px !important;
  line-height: 1.2 !important;
  box-sizing: border-box !important;
}

.wpcf7 input[type="range"] {
  display: block !important;
  width: 100% !important;
  margin: 0 !important;
  box-sizing: border-box !important;
}


/* ===== 8) CHECKBOX / RADIO / ACCEPTANCE / QUIZ ===== */

.wpcf7 input[type="checkbox"],
.wpcf7 input[type="radio"] {
  margin: 0 6px 0 0 !important;
  vertical-align: middle !important;
}

.wpcf7 .wpcf7-list-item {
  display: inline-flex !important;
  align-items: flex-start !important;
  margin: 0 12px 6px 0 !important;
}

.wpcf7 .wpcf7-list-item.first {
  margin-left: 0 !important;
}

.wpcf7 .wpcf7-list-item-label,
.wpcf7 .wpcf7-acceptance label,
.wpcf7 .wpcf7-quiz-label {
  color: #222222 !important;
  font-size: 14px !important;
  line-height: 1.2 !important;
}

.wpcf7 .wpcf7-acceptance label {
  display: inline-flex !important;
  align-items: flex-start !important;
  gap: 6px !important;
  margin: 0 !important;
}


/* ===== 9) TEXTO LEGAL ===== */

.wpcf7 .cf7-legal {
  margin: 0 0 6px 0 !important;
  padding: 0 !important;
  color: #5e6870 !important;
  font-size: 13px !important;
  font-family: inherit !important;
  line-height: 1.3 !important;
  font-weight: 400 !important;
  letter-spacing: 0 !important;
  text-transform: none !important;
}

.wpcf7 .cf7-legal,
.wpcf7 .cf7-legal p,
.wpcf7 .cf7-legal span,
.wpcf7 .cf7-legal strong,
.wpcf7 .cf7-legal em {
  color: #5e6870 !important;
  font-size: 13px !important;
  font-family: inherit !important;
  line-height: 1.3 !important;
  font-weight: 400 !important;
}

.wpcf7 .cf7-legal a {
  color: #004557 !important;
  font-size: 13px !important;
  line-height: 1.3 !important;
  text-decoration: underline !important;
}

.wpcf7 .cf7-legal a:hover {
  opacity: 0.9;
}


/* ===== 10) ESPACIADO ACEPTACIONES / BOTÓN ===== */

.wpcf7 .cf7-accept-row {
  margin-bottom: 10px !important;
}

.wpcf7 .cf7-accept-row:last-of-type {
  margin-bottom: 0 !important;
}

.wpcf7 .cf7-row.cf7-actions {
  display: block !important;
  width: 100% !important;
  margin: 0 !important;
  padding-top: 10px !important;
  clear: both !important;
  box-sizing: border-box !important;
}

.wpcf7 .cf7-row.cf7-actions p {
  margin: 0 !important;
  padding: 0 !important;
}

.wpcf7 .cf7-row.cf7-actions input[type="submit"] {
  margin: 0 !important;
}


/* ===== 11) FOCUS ===== */

.wpcf7 input:focus,
.wpcf7 select:focus,
.wpcf7 textarea:focus {
  border-color: #004557 !important;
  box-shadow: none !important;
  outline: none !important;
}


/* ===== 12) MENSAJES / ERRORES ===== */

.wpcf7 .wpcf7-not-valid-tip {
  display: block !important;
  margin-top: 4px !important;
  color: #dc3232 !important;
  font-size: 12px !important;
  line-height: 1.2 !important;
}

.wpcf7 .wpcf7-response-output {
  margin: 8px 0 0 0 !important;
  padding: 8px 10px !important;
  font-size: 13px !important;
  line-height: 1.3 !important;
  box-sizing: border-box !important;
}

.wpcf7 .wpcf7-spinner {
  margin: 0 0 0 6px !important;
  vertical-align: middle !important;
}


/* ===== 13) BOTÓN SUBMIT ===== */

.wpcf7 input[type="submit"] {
  font-size: 14px !important;
  line-height: 1.2 !important;
}


/* ===== 14) STICKY SIDEBAR OPCIONAL ===== */

.verus-sticky-sidebar {
  position: sticky !important;
  top: 20px !important;
  align-self: flex-start !important;
  width: 100% !important;
  height: auto !important;
  max-height: calc(100vh - 20px) !important;
  overflow: auto !important;
  box-sizing: border-box !important;
}

.verus-sticky-sidebar .elementor-widget-wrap,
.verus-sticky-sidebar .elementor-widget-container,
.verus-sticky-sidebar .wpcf7,
.verus-sticky-sidebar .wpcf7 form {
  width: 100% !important;
  max-width: 100% !important;
  box-sizing: border-box !important;
}
