/* ============================================================================
   FAIRFIELD COUNTY ENGINEER — form styling for emailmeform
   ----------------------------------------------------------------------------
   Paste this into the emailmeform form's Custom CSS box.
   Self-contained: no variables, no font imports needed beyond Montserrat,
   which emailmeform can load via the @import on the first line.
   Matches the styling used on co.fairfield.oh.us/Engineer form pages.
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800&display=swap');

/* ---- palette (for reference if you need to tweak) --------------------------
   navy          #032949      field label + headings
   navy-2        #063a66      focus ring / submit hover
   gold          #e6a91d      accents
   ink           #1c2126      strongest text
   body          #3a3f45      body text
   muted         #6b7280      helper text
   line          #dfe3e8      borders
   canvas        #f6f7f9      tinted panel background
   -------------------------------------------------------------------------- */

/* ---- form shell ---------------------------------------------------------- */
form,
.emf-form {
  font-family: 'Montserrat', Arial, Helvetica, sans-serif !important;
  color: #3a3f45;
  max-width: 760px;
  margin: 0 auto;
  padding: 24px 26px 28px;
  background: #fff;
  border: 1px solid #dfe3e8;
  border-radius: 14px;
  box-shadow: 0 1px 2px rgba(16, 24, 40, .05), 0 1px 3px rgba(16, 24, 40, .1);
  box-sizing: border-box;
}

/* strip emailmeform's default table chrome */
form table,
form tbody,
form tr,
form td {
  border: 0 !important;
  background: none !important;
  padding: 0 !important;
  display: block !important;
  width: 100% !important;
}

/* ---- section headings (emailmeform "Section Break" element) -------------- */
.section_break,
form h2,
form legend {
  font-family: 'Montserrat', Arial, Helvetica, sans-serif;
  font-size: 15.5px;
  font-weight: 800;
  color: #032949;
  letter-spacing: 0;
  padding: 0 0 6px;
  margin: 26px 0 10px;
  border: 0;
  border-top: 1px solid #dfe3e8;
  padding-top: 22px;
}
.section_break:first-child,
form h2:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

/* ---- field wrapper ------------------------------------------------------- */
.form_element,
.field {
  margin-bottom: 14px;
}

/* ---- field labels -------------------------------------------------------- */
label,
.form_element label,
.element_label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .03em;
  color: #1c2126;
  margin-bottom: 6px;
  line-height: 1.4;
}

/* required marker */
.required,
.req {
  color: #c0392b;
}

/* helper / instruction text under a label */
.guidelines,
.form-note,
.grp-note {
  display: block;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0;
  color: #6b7280;
  margin: -2px 0 6px;
  line-height: 1.5;
}

/* ---- text inputs, selects, textareas ------------------------------------- */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="url"],
input[type="number"],
input[type="date"],
input[type="password"],
select,
textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 11px 13px;
  border: 1px solid #dfe3e8;
  border-radius: 8px;
  font-family: 'Montserrat', Arial, Helvetica, sans-serif;
  font-size: 15px;
  font-weight: 400;
  color: #1c2126;
  background: #fff;
  -webkit-appearance: none;
  appearance: none;
}

select {
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath fill='%236b7280' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 38px;
}

textarea {
  resize: vertical;
  min-height: 96px;
  line-height: 1.6;
}

input::placeholder,
textarea::placeholder {
  color: #aab0b7;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: #063a66;
  box-shadow: 0 0 0 3px rgba(6, 58, 102, .12);
}

/* ---- checkboxes + radios ------------------------------------------------- */
/* emailmeform renders each option as a checkbox and its text SIDE BY SIDE as
   siblings, not nested. So the checkbox is styled inline (not flex) — that
   keeps the text on the same line as the box no matter which structure it
   uses. Each option sits on its own row.                                    */

.choices,
.checkbox_group,
.radio_group,
.chk-grid {
  display: block;
  margin-top: 4px;
}

/* the box itself — inline, so text stays beside it */
input[type="checkbox"],
input[type="radio"] {
  width: 16px !important;
  height: 16px !important;
  min-width: 16px;
  margin: 0 8px 0 0 !important;
  padding: 0 !important;
  display: inline-block !important;
  vertical-align: -3px;
  border: 1px solid #b9c0c8;
  cursor: pointer;
  accent-color: #032949;
  -webkit-appearance: auto;
  appearance: auto;
  box-shadow: none !important;
}

/* option TEXT when it is a sibling of the box (emailmeform's usual markup) */
input[type="checkbox"] + label,
input[type="radio"] + label,
input[type="checkbox"] + span,
input[type="radio"] + span {
  display: inline !important;
  font-size: 14px !important;
  font-weight: 400 !important;
  letter-spacing: 0 !important;
  line-height: 1.5;
  color: #3a3f45 !important;
  margin: 0 !important;
  padding: 0;
  vertical-align: baseline;
  cursor: pointer;
}

/* one option per row */
.choices label,
.checkbox_group label,
.radio_group label,
.choices > span,
.checkbox_group > span,
.radio_group > span {
  display: block;
  padding: 5px 0;
  margin: 0;
}

/* keep box + text on the same line inside each row */
.choices label input,
.checkbox_group label input,
.radio_group label input,
.choices > span input,
.checkbox_group > span input,
.radio_group > span input {
  display: inline-block !important;
}

/* option TEXT when it is nested inside its label (our own page's markup) */
label.chk {
  display: block;
  padding: 5px 0;
  margin: 0;
  font-size: 14px;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.5;
  color: #3a3f45;
  cursor: pointer;
}

/* ---- want the options in 2 columns instead of one long list? --------------
   Uncomment this block. Leave it off if any option text is long — short
   labels like "Daily" or "Bicycle" column nicely, long ones do not.
   .choices, .checkbox_group, .radio_group {
     columns: 2;
     column-gap: 24px;
   }
   .choices label, .checkbox_group label, .radio_group label {
     break-inside: avoid;
   }
   -------------------------------------------------------------------------- */

/* ---- submit button ------------------------------------------------------- */
input[type="submit"],
button[type="submit"],
.btn-submit {
  width: 100%;
  padding: 13px 18px;
  margin-top: 6px;
  border: 0;
  border-radius: 9px;
  background: #032949;
  color: #fff;
  font-family: 'Montserrat', Arial, Helvetica, sans-serif;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: .02em;
  cursor: pointer;
  transition: background .15s, transform .12s;
  -webkit-appearance: none;
  appearance: none;
}

input[type="submit"]:hover,
button[type="submit"]:hover,
.btn-submit:hover {
  background: #063a66;
  transform: translateY(-1px);
}

/* reset / secondary button, if the form has one */
input[type="reset"],
button[type="reset"] {
  width: auto;
  padding: 11px 20px;
  margin-top: 10px;
  border: 1.5px solid #032949;
  border-radius: 9px;
  background: #fff;
  color: #032949;
  font-family: 'Montserrat', Arial, Helvetica, sans-serif;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}
input[type="reset"]:hover,
button[type="reset"]:hover {
  background: #032949;
  color: #fff;
}

/* ---- validation messages ------------------------------------------------- */
.error,
.form-error,
.error_message {
  margin-bottom: 12px;
  padding: 10px 13px;
  border-radius: 8px;
  background: #fbe9e7;
  border: 1px solid #f3b9b2;
  color: #a5281b;
  font-size: 13.5px;
  font-weight: 500;
}

input.error,
select.error,
textarea.error {
  background: #fff;
  border-color: #f3b9b2;
  padding: 11px 13px;
}

/* ---- captcha ------------------------------------------------------------- */
.captcha,
.g-recaptcha {
  margin: 18px 0 8px;
}

/* ---- links inside the form ---------------------------------------------- */
form a {
  color: #063a66;
  text-decoration: underline;
  text-underline-offset: 2px;
}
form a:hover {
  color: #e6a91d;
}

/* ---- small screens ------------------------------------------------------- */
@media (max-width: 560px) {
  form,
  .emf-form {
    padding: 18px 16px 22px;
    border-radius: 10px;
  }
  .choices,
  .checkbox_group,
  .radio_group {
    columns: 1;
  }
}
