/*
 Theme Name:   Bricks Child Theme
 Theme URI:    https://bricksbuilder.io/
 Description:  Use this child theme to extend Bricks.
 Author:       Bricks
 Author URI:   https://bricksbuilder.io/
 Template:     bricks
 Version:      1.1
 Text Domain:  bricks
*/

.x-hotspots_marker-image {
  filter: brightness(0) invert(1);
}
/* Bricks Text/Rich Text masonry-style grid (with fallback grid) */
@media (max-width: 767px) {
  .x-marker {
    display: none !important;
  }
}
.zip-grid {
  margin: 0;
  padding: 0;
}

.zip-grid p {
  margin: 0 0 1em 0;
  break-inside: avoid;
  page-break-inside: avoid;
}

/* Mobile first - single column */
@media (max-width: 767px) {
  .zip-grid {
    column-count: 1;
    column-gap: 20px;
  }
}

/* Tablet - 2 columns */
@media (min-width: 768px) and (max-width: 1023px) {
  .zip-grid {
    column-count: 2;
    column-gap: 25px;
  }
}

/* Desktop - 3 columns for medium screens */
@media (min-width: 1024px) and (max-width: 1279px) {
  .zip-grid {
    column-count: 3;
    column-gap: 30px;
  }
}

/* Desktop - 4 columns for large screens */
@media (min-width: 1280px) {
  .zip-grid {
    column-count: 4;
    column-gap: 30px;
  }
}
/* -------------------------------------------------------------------------
   JETFORMBUILDER + CORE FRAMEWORK CONSOLIDATED STYLING
------------------------------------------------------------------------- */

/* Container & Global Font Fix */
.jet-fb-form-block {
    max-width: var(--max-width-100);
    margin-inline: auto;
    font-size: var(--text-m); 
    color: var(--text-body);
    line-height: var(--line-height-xl);
}

/* Section Headings */
.wp-block-heading {
    font-size: var(--text-xl);
    font-weight: 700;
    margin-top: var(--space-l);
    margin-bottom: var(--space-m);
    padding-bottom: var(--space-3xs);
    border-bottom: 2px solid var(--primary-10);
    color: var(--text-title);
}

/* Field Spacing */
.jet-form-builder-row {
    margin-bottom: var(--space-s);
}

/* Labels - High Contrast */
.jet-form-builder__label-text {
    display: block;
    font-weight: 700;
    margin-bottom: var(--space-4xs);
    font-size: var(--text-m);
    color: var(--text-title);
}

.jet-form-builder__required {
    color: var(--error);
    margin-left: 2px;
}

/* Text Inputs, Dates, Numbers */
.jet-form-builder__field.text-field,
.jet-form-builder__field.date-field,
.jet-form-builder__field.number-field {
    width: 100%;
    padding: var(--space-3xs) var(--space-2xs);
    border: 1px solid var(--base-30); 
    border-radius: var(--radius-s);
    font-size: var(--text-l);
    background-color: var(--bg-surface);
    color: var(--text-body);
    transition: all 0.2s ease;
}

.jet-form-builder__field:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px var(--primary-20);
}

/* Radio & Checkbox Styling */
.checkradio-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-s); 
    padding: var(--space-5xs) 0;
}

.radio-wrap, .checkboxes-wrap {
    background: transparent;
    padding: 0;
    border: none;
}

.jet-form-builder__field-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-size: var(--text-m);
    color: var(--text-body);
}

.jet-form-builder__field.radio-field,
.jet-form-builder__field.checkboxes-field {
    accent-color: var(--primary); 
    width: 1.8rem;
    height: 1.8rem;
    cursor: pointer;
}

/* --- Buttons: Unified Primary Style --- */
.jet-form-builder__action-button,
.jet-form-builder-repeater__new {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: var(--primary);
    color: var(--light);
    padding: var(--space-2xs) var(--space-l);
    border: none;
    border-radius: var(--radius-s);
    font-weight: 700;
    font-size: var(--text-m);
    cursor: pointer;
    transition: filter 0.2s ease, transform 0.1s ease;
    text-transform: uppercase;
}

.jet-form-builder__action-button:hover,
.jet-form-builder-repeater__new:hover {
    filter: brightness(1.2);
}

/* --- Repeater Row Spacing Fixes --- */
.jet-form-builder-repeater {
    border: 1px solid var(--base-20);
    border-radius: var(--radius-m);
    padding: var(--space-m);
    background: transparent;
}

/* This targets the inner box with the red border from your screenshot */
.jet-form-builder-repeater__row {
    position: relative;
    background: var(--bg-surface);
    /* Increase left padding significantly to move text away from the red bar */
    padding: var(--space-m) var(--space-l) var(--space-m) var(--space-xl) !important; 
    border: 1px solid var(--base-20);
    border-left: 8px solid var(--primary); /* Thick red accent bar */
    border-radius: var(--radius-m);
    margin-bottom: var(--space-m);
    box-shadow: var(--shadow-xs);
}

/* Fix vertical spacing inside the repeater rows */
.jet-form-builder-repeater__row-fields {
    display: flex;
    flex-direction: column;
    gap: var(--space-m); /* Adds gap between "Sex" and "Date of Birth" */
}

/* Repeater Action Footer */
.jet-form-builder-repeater__actions {
    margin-top: var(--space-s);
    padding-top: var(--space-m);
    border-top: 1px dashed var(--base-20);
}

/* --- The "X" Remove Button --- */
.jet-form-builder-repeater__row-remove {
    position: absolute;
    top: var(--space-xs);
    right: var(--space-xs);
    z-index: 10;
}

.jet-form-builder-repeater__remove {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    background-color: var(--base-10);
    color: var(--text-body);
    border: 1px solid var(--base-20);
    border-radius: var(--radius-full);
    font-size: 2rem;
    cursor: pointer;
}

.jet-form-builder-repeater__remove:hover {
    background-color: var(--error);
    color: var(--light);
}

/* Helper Text */
.jet-form-builder__desc small {
    display: block;
    margin-top: var(--space-5xs);
    color: var(--base-l-2);
    font-size: var(--text-m);
    font-style: italic;
}
/* -------------------------------------------------------------------------
   GRAVITY FORM 2, KEEP DEFAULT GF LAYOUT, APPLY JET-STYLE VISUALS ONLY
------------------------------------------------------------------------- */

#gform_2 {
    max-width: var(--max-width-100);
    margin-inline: auto;
    font-size: var(--text-m);
    color: var(--text-body);
    line-height: var(--line-height-xl);
}

/* Field spacing only, no layout changes */
#gform_2 .gfield {
    margin-bottom: var(--space-s);
}

/* Section headings */
#gform_2 .gsection_title {
    font-size: var(--text-xl);
    font-weight: 700;
    margin-top: var(--space-l);
    margin-bottom: var(--space-m);
    padding-bottom: var(--space-3xs);
    border-bottom: 2px solid var(--primary-10);
    color: var(--text-title);
}

/* Labels */
#gform_2 .gfield_label,
#gform_2 .gform-field-label {
    display: block;
    font-weight: 700;
    margin-bottom: var(--space-4xs);
    font-size: var(--text-m);
    color: var(--text-title);
}

/* Sub labels */
#gform_2 .gform-field-label--type-sub {
    display: block;
    margin-bottom: var(--space-5xs);
    font-size: var(--text-m);
    font-weight: 600;
    color: var(--text-title);
}

/* Helper / description text */
#gform_2 .gfield_description {
    display: block;
    margin-top: var(--space-5xs);
    margin-bottom: var(--space-3xs);
    color: var(--base-l-2);
    font-size: var(--text-m);
    font-style: italic;
}

/* Inputs */
#gform_2 input[type="text"],
#gform_2 input[type="email"],
#gform_2 input[type="tel"],
#gform_2 input[type="number"],
#gform_2 input[type="date"],
#gform_2 input[type="url"],
#gform_2 input[type="password"],
#gform_2 select,
#gform_2 textarea {
    width: 100%;
    padding: var(--space-3xs) var(--space-2xs);
    border: 1px solid var(--base-30);
    border-radius: var(--radius-s);
    font-size: var(--text-l);
    background-color: var(--bg-surface);
    color: var(--text-body);
    transition: all 0.2s ease;
    box-sizing: border-box;
}

/* Respect GF input size classes visually */
#gform_2 input.small,
#gform_2 input.medium,
#gform_2 input.large,
#gform_2 select.small,
#gform_2 select.medium,
#gform_2 select.large,
#gform_2 textarea.small,
#gform_2 textarea.medium,
#gform_2 textarea.large {
    width: 100%;
}

/* Focus */
#gform_2 input[type="text"]:focus,
#gform_2 input[type="email"]:focus,
#gform_2 input[type="tel"]:focus,
#gform_2 input[type="number"]:focus,
#gform_2 input[type="date"]:focus,
#gform_2 input[type="url"]:focus,
#gform_2 input[type="password"]:focus,
#gform_2 select:focus,
#gform_2 textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px var(--primary-20);
}

/* Choice groups, visual only */
#gform_2 .gfield_checkbox,
#gform_2 .gfield_radio {
    padding: var(--space-5xs) 0;
}

/* Individual checkbox/radio choice */
#gform_2 .gchoice {
    margin-bottom: var(--space-5xs);
}

/* Keep short labels from awkward wrapping */
#gform_2 #field_2_7 .gchoice label,
#gform_2 #field_2_20 .gchoice label {
    white-space: nowrap;
}

/* Native checkboxes/radios */
#gform_2 input[type="checkbox"].gfield-choice-input,
#gform_2 input[type="radio"].gfield-choice-input {
    accent-color: var(--primary);
    cursor: pointer;
}

/* Inline labels next to checkbox/radio */
#gform_2 .gform-field-label--type-inline {
    font-size: var(--text-m);
    font-weight: 400;
    color: var(--text-body);
    line-height: 1.35;
}

/* Nested form wrapper */
#gform_2 .gpnf-nested-entries-container {
    border: 1px solid var(--base-20);
    border-radius: var(--radius-m);
    padding: var(--space-m);
    background: transparent;
}

/* Nested entries table */
#gform_2 .gpnf-nested-entries {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    margin-bottom: var(--space-m);
    background: var(--bg-surface);
    border: 1px solid var(--base-20);
    border-left: 8px solid var(--primary);
    border-radius: var(--radius-m);
    overflow: hidden;
    box-shadow: var(--shadow-xs);
}

/* Table cells */
#gform_2 .gpnf-nested-entries th,
#gform_2 .gpnf-nested-entries td {
    padding: var(--space-s) var(--space-m);
    text-align: left;
    border-bottom: 1px solid var(--base-20);
    font-size: var(--text-s);
    color: var(--text-body);
    vertical-align: middle;
}

#gform_2 .gpnf-nested-entries th {
    font-weight: 700;
    color: var(--text-title);
    background: var(--bg-surface);
}

#gform_2 .gpnf-nested-entries tr:last-child td {
    border-bottom: none;
}

/* Empty row text */
#gform_2 .gpnf-no-entries td {
    color: var(--base-l-2);
    font-style: italic;
}

/* Buttons */
#gform_2 .gpnf-add-entry,
#gform_2 .gform_button,
#gform_2 input[type="submit"].gform_button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: var(--primary);
    color: var(--light);
    padding: var(--space-2xs) var(--space-l);
    border: none;
    border-radius: var(--radius-s);
    font-weight: 700;
    font-size: var(--text-s);
    cursor: pointer;
    transition: filter 0.2s ease, transform 0.1s ease;
    text-transform: uppercase;
    line-height: 1;
    text-decoration: none;
}

#gform_2 .gpnf-add-entry:hover,
#gform_2 .gform_button:hover,
#gform_2 input[type="submit"].gform_button:hover {
    filter: brightness(1.2);
}

/* Footer spacing */
#gform_2 .gform_footer,
#gform_2 .gform-footer {
    margin-top: var(--space-m);
}

/* Textareas */
#gform_2 textarea {
    resize: vertical;
    min-height: 12rem;
}

/* Disabled appearance only, does not disable anything */
#gform_2 input:disabled,
#gform_2 select:disabled,
#gform_2 textarea:disabled,
#gform_2 .gf-default-disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

/* Validation */
#gform_2 .gfield_error input,
#gform_2 .gfield_error select,
#gform_2 .gfield_error textarea {
    border-color: var(--error);
}

#gform_2 .validation_message,
#gform_2 .gfield_validation_message {
    margin-top: var(--space-5xs);
    font-size: var(--text-xs);
    color: var(--error);
}
/* -------------------------------------------------------------------------
   GRAVITY FORM 2, FIX CHECKBOX / RADIO ALIGNMENT
------------------------------------------------------------------------- */

/* Keep each choice on one line unit */
#gform_2 .gchoice {
    display: flex;
    align-items: flex-start;
    gap: 0.45rem;
    margin-bottom: var(--space-5xs);
}

/* Prevent the label from dropping below the checkbox/radio */
#gform_2 .gchoice .gfield-choice-input {
    flex: 0 0 auto;
    margin: 0;
    position: relative;
    top: 0.15em;
}

#gform_2 .gchoice .gform-field-label--type-inline,
#gform_2 .gchoice label {
    display: inline-block;
    margin: 0;
    line-height: 1.35;
    vertical-align: top;
}

/* Keep the short top choices inline */
#gform_2 #field_2_7 .gfield_checkbox,
#gform_2 #field_2_20 .gfield_radio {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1.25rem;
}

/* Requirements list should be vertical like the original GF form */
#gform_2 #field_2_16 .gfield_checkbox {
    display: block;
}

#gform_2 #field_2_16 .gchoice {
    display: flex;
    align-items: flex-start;
    margin-bottom: var(--space-4xs);
}

/* Native checkbox/radio appearance */
#gform_2 input[type="checkbox"].gfield-choice-input,
#gform_2 input[type="radio"].gfield-choice-input {
    accent-color: var(--primary);
    cursor: pointer;
}
#gform_2 #field_2_7 .gchoice label,
#gform_2 #field_2_20 .gchoice label {
    white-space: nowrap;
}