/* ==========================================================================
   PATIENT PRISM — HUBSPOT FORM STYLES
   ========================================================================== */

/* --------------------------------------------------------------------------
   Fieldset layout
   -------------------------------------------------------------------------- */

html > body .hbspt-form > form fieldset {
  border: none;
  padding: 0;
  margin: 0 0 1rem;
  min-width: 0;
  width: 100% !important;
  box-sizing: border-box;
}

/* Two-column fieldsets get their own internal grid */
.hs-form fieldset.form-columns-2 {
  display: grid !important;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

/* --------------------------------------------------------------------------
   Field + input wrappers — must fill their grid cell
   -------------------------------------------------------------------------- */

.hs-form .hs-form-field { min-width: 0; width: 100% !important; }
.hs-form .hs-form-field .input { width: 100% !important; }

/* --------------------------------------------------------------------------
   Labels
   -------------------------------------------------------------------------- */

.hs-form label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--blue-900);
  margin-bottom: 0.35rem;
}

.hs-form .hs-form-required {
  color: var(--red-600);
  margin-left: 2px;
}

/* --------------------------------------------------------------------------
   Inputs, textarea, select — exclude checkbox/radio/hidden
   -------------------------------------------------------------------------- */

.hs-form input.hs-input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
.hs-form textarea.hs-input,
.hs-form select.hs-input {
  display: block;
  width: 100% !important;
  padding: 0.65rem 0.9rem;
  font-size: 15px;
  font-family: "Manrope", system-ui, -apple-system, sans-serif;
  font-weight: 400;
  line-height: 1.5;
  color: var(--blue-900);
  background: #fff !important;
  border: 1px solid var(--grey-300) !important;
  border-radius: 8px;
  outline: none;
  appearance: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
  box-sizing: border-box !important;
}

.hs-form input.hs-input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]):focus,
.hs-form textarea.hs-input:focus,
.hs-form select.hs-input:focus {
  border-color: var(--blue-500) !important;
  box-shadow: 0 0 0 3px rgba(20, 124, 255, 0.12) !important;
}

.hs-form textarea.hs-input {
  min-height: 110px;
  resize: vertical;
}

/* --------------------------------------------------------------------------
   Select dropdown arrow
   -------------------------------------------------------------------------- */

.hs-form select.hs-input {
  padding-right: 2.25rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='none' stroke='%2300183B' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round' d='M2 4l4 4 4-4'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 0.75rem center !important;
  background-size: 12px !important;
}

/* --------------------------------------------------------------------------
   Phone field — country select compact, tel input fills remaining space
   -------------------------------------------------------------------------- */

.hs-form .hs-fieldtype-intl-phone {
  display: flex !important;
  gap: 0.5rem;
}

.hs-form .hs-fieldtype-intl-phone select.hs-input {
  width: 120px !important;
  max-width: 120px !important;
  flex: 0 0 120px !important;
  min-width: 0;
}

.hs-form .hs-fieldtype-intl-phone input[type="tel"].hs-input {
  flex: 1 1 0% !important;
  width: 0 !important;
  min-width: 0;
}

/* --------------------------------------------------------------------------
   Checkbox
   -------------------------------------------------------------------------- */

.hs-form .inputs-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.hs-form .hs-form-booleancheckbox-display {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  cursor: pointer;
  font-size: 13px;
  font-weight: 400;
  color: var(--grey-500);
  line-height: 1.4;
}

.hs-form .hs-form-booleancheckbox-display input[type="checkbox"] {
  all: revert;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  margin-top: 2px;
  accent-color: var(--blue-500);
  cursor: pointer;
}

/* --------------------------------------------------------------------------
   Submit button — gradient border via background-clip
   input[type="submit"] ignores flex/align; centering is padding + line-height only
   -------------------------------------------------------------------------- */

.hs-form .actions { margin-top: 0.75rem; }

.hs-form .hs-button {
  padding: 15px 32px;
  line-height: 1;
  font-family: "Manrope", system-ui, -apple-system, sans-serif;
  font-size: 16px;
  font-weight: 600;
  color: var(--blue-900) !important;
  border: 2px solid transparent !important;
  border-radius: 25px;
  cursor: pointer;
  appearance: none;
  box-shadow: none !important;
  background: linear-gradient(#fff, #fff) padding-box,
              linear-gradient(to right, #4B76EE, #2B67FF, #773CDF, #954EB3, #FF9853) border-box !important;
  transition: background 0.4s ease-in-out;
}

.hs-form .hs-button:hover {
  background: linear-gradient(#fff, #fff) padding-box,
              linear-gradient(200deg, #4B76EE, #2B67FF, #773CDF, #954EB3, #FF9853) border-box !important;
}

/* --------------------------------------------------------------------------
   Validation errors
   -------------------------------------------------------------------------- */

.hs-form .hs-error-msgs {
  list-style: none;
  margin: 0.3rem 0 0;
  padding: 0;
  font-size: 12px;
  font-weight: 500;
  color: var(--red-600);
}

.hs-form .hs-error-msgs label {
  font-size: 12px;
  font-weight: 500;
  color: var(--red-600);
  margin: 0;
}

.hs-form input.hs-input.error,
.hs-form textarea.hs-input.error {
  border-color: var(--red-600) !important;
  box-shadow: 0 0 0 3px rgba(254, 57, 53, 0.1) !important;
}
