/*!
Theme Name: Goley 2.0 Theme
Theme URI: https://www.goleyinc.com/
Description: Child theme of Divi 4+, maintained for site-specific customizations.
Author: Archetype SC - Jon Long
Author URI: https://www.archetypesc.com/
Company: Archetype SC
Template: Divi
Version: 2.1.0
License: GNU General Public License v2
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: goley-divi-child
*/


/* Universal Classes */
:root {
    /* ---------- Theme colors ---------- */
    --goley-black: #000000;
    --goley-white: #FFFFFF;
    --goley-primary: #ce202f;
    --goley-secondary: #33363b;
    --goley-success: #2e7d4f;
    --goley-info: #2a6f97;
    --goley-warning: #f0a202;
    --goley-danger: #8f1d2c;
    --goley-light: #ECECEC;
    --goley-dark: #4a4b4c;

    /* RGB versions for rgba() usage, same as Bootstrap */
    --goley-primary-rgb: 206, 32, 47;
    --goley-secondary-rgb: 51, 54, 59;
    --goley-success-rgb: 46, 125, 79;
    --goley-info-rgb: 42, 111, 151;
    --goley-warning-rgb: 240, 162, 2;
    --goley-danger-rgb: 143, 29, 44;
    --goley-light-rgb: 244, 245, 246;
    --goley-dark-rgb: 31, 33, 36;

    /* ---------- Primary scale ---------- */
    --goley-red-hover: #af1b28;
    --goley-red-active: var(--goley-primary);
    --goley-primary-bg-subtle: #f5d2d5;
    --goley-primary-border-subtle: #eba6ac;
    --goley-primary-text-emphasis: #520d13;

    --goley-charcoal-hover: #2b2e32;
    --goley-secondary-bg-subtle: #d6d7d8;

    /* ---------- Body ---------- */
    --goley-body-bg: #ffffff;
    --goley-body-color: #2b2d31;
    --goley-border-color: #dcdee1;
    --goley-link-color: var(--goley-red-active);
    --goley-link-hover-color: var(--goley-primary-text-emphasis);

    /* ---------- Typography ---------- */
    --goley-body-font-size: 16px;
    --goley-body-font-weight: 500;
    --goley-body-line-height: 1.6;
    --goley-heading-font-weight: 600;
    --goley-heading-line-height: 1.2;

    /* ---------- Shape and depth ---------- */
    --goley-border-radius: 10px;
    --goley-border-radius-card: 14px;
    --goley-border-radius-btn: 35px;

    /* ---------- Focus ---------- */
    --goley-focus-ring-color: unset;
    --goley-focus-ring-width: 0;

    /* ---------- Buttons - Primary ---------- */
    --goley-btn-bg: var(--goley-primary);
    --goley-btn-border-color: var(--goley-primary);
    --goley-btn-color: var(--goley-white);
    --goley-btn-hover-bg: var(--goley-red-hover);
    --goley-btn-hover-border-color: var(--goley-red-hover);
    --goley-btn-active-bg: var(--goley-red-active);
    --goley-btn-active-border-color: var(--goley-red-active);
    --goley-btn-focus-shadow-rgb: var(--goley-primary-rgb);

    /* ---------- Buttons - Secondary ---------- */
    --goley-second-btn-bg: var(--goley-secondary);
    --goley-second-btn-border-color: var(--goley-secondary);
    --goley-second-btn-color: var(--goley-white);
    --goley-second-btn-hover-bg: var(--goley-charcoal-hover);
    --goley-second-btn-hover-border-color: var(--goley-charcoal-hover);

    /* ---------- Buttons - Warning ---------- */
    --goley-warning-btn-color: var(--goley-dark);
}


/* ---------- Base ---------- */
html {
    background: var(--goley-body-bg);
}

body,
body .dipi_carousel .swiper-container .dipi_carousel_child {
    color: var(--goley-body-color);
    font-size: var(--goley-body-font-size);
    font-weight: var(--goley-body-font-weight);
    line-height: var(--goley-body-line-height);
}

body h1,
body h2,
body h3,
body h4,
body h5,
body h6 {
    padding-bottom: 0px;
    color: var(--goley-primary);
    font-weight: var(--goley-heading-font-weight);
    line-height: var(--goley-heading-line-height);
}

body h1,
body .goley_slide h1 {
    font-size: 40px;
}

body h2,
body .goley_slide h2 {
    font-size: 34px;
}

body h3,
body .goley_slide h3 {
    font-size: 28px;
}

body h4,
body .goley_slide h4 {
    font-size: 24px;
}

body h5,
body .goley_slide h5 {
    font-size: 20px;
}

body h6,
body .goley_slide h6 {
    font-size: 18px;
}

body p {
    font-size: var(--goley-body-font-size);
}

body small {
    font-size: 14px;
}

body sup {
    font-size: 65%;
}

body a {
    color: var(--goley-link-color);
}

body a:hover {
    color: var(--goley-link-hover-color);
}

/** Tablet **/
@media only screen and (max-width: 980px) {

    body h1,
    body .goley_slide h1 {
        font-size: 34px;
    }

    body h2,
    body .goley_slide h2 {
        font-size: 28px;
    }

    body h3,
    body .goley_slide h3 {
        font-size: 24px;
    }

    body h4,
    body .goley_slide h4 {
        font-size: 20px;
    }

    body h5,
    body .goley_slide h5 {
        font-size: 18px;
    }

    body h6,
    body .goley_slide h6 {
        font-size: 18px;
    }
}

/** Mobile **/
@media only screen and (max-width: 767px) {

    body h1,
    body .goley_slide h1 {
        font-size: 28px;
    }

    body h2,
    body .goley_slide h2 {
        font-size: 24px;
    }

    body h3,
    body .goley_slide h3 {
        font-size: 20px;
    }

    body h4,
    body .goley_slide h4 {
        font-size: 18px;
    }

    body h5,
    body .goley_slide h5 {
        font-size: 18px;
    }

    body h6,
    body .goley_slide h6 {
        font-size: 16px;
    }
}


/* ---------- Buttons ---------- */
:focus-visible {
    outline: none;
    box-shadow: 0 0 0 var(--goley-focus-ring-width) var(--goley-focus-ring-color);
}

body .goley_button {
    background-color: var(--goley-btn-bg) !important;
    color: var(--goley-btn-color) !important;
    border-width: 0px !important;
    border-color: var(--goley-btn-border-color) !important;
    border-radius: var(--goley-border-radius-btn) !important;
    font-weight: 700 !important;
}

body .goley_button:hover,
body .goley_button:focus {
    background-color: var(--goley-btn-hover-bg) !important;
    color: var(--goley-btn-color) !important;
    border-width: 0px !important;
    border-color: var(--goley-btn-hover-border-color) !important;
    border-radius: var(--goley-border-radius-btn) !important;
    font-weight: 700 !important;
}

body .dipi_carousel .swiper-button-next:hover,
body .dipi_carousel .swiper-button-prev:hover {
    background-color: var(--goley-btn-hover-bg) !important;
}


/* Desktop Adjustments */
@media (min-width: 981px) {
    .et_pb_row {
        padding: 3% 0;
    }

    .goley_header .et_pb_row {
        padding: 2% 0;
    }

    body .et_pb_gutters3 .et_pb_column_4_4 .et_pb_blog_grid .column.size-1of3,
    body .et_pb_gutters3.et_pb_row .et_pb_column_4_4 .et_pb_blog_grid .column.size-1of3 {
        margin-right: 4.5%;
    }

    body .archposts .et_pb_post .entry-title,
    body .archposts .not-found-title {
        padding-bottom: 20px;
    }
}

/* Tablet Adjustments */
@media (min-width: 768px) and (max-width: 980px) {
    body .goley_stack_tablet.et_pb_row>.et_pb_column {
        width: 100% !important;
        margin-right: 0 !important;
        margin-bottom: 30px !important;
    }

    /* body .goley_stack_tablet.et_pb_row>.et_pb_column:last-child {
        margin-bottom: 0 !important;
    } */
}

/* Tablet and Lower */
@media (max-width: 980px) {
    .et_pb_row:has(> .goley-mobile-first) {
        display: flex;
        flex-direction: column;
    }

    .et_pb_row>.goley-mobile-first {
        order: -1;
        /* margin-bottom: 30px !important; */
    }

    /* The column that is now visually last should not keep a bottom gap */
    .et_pb_row:has(> .goley-mobile-first)>.et_pb_column:nth-last-child(2) {
        margin-bottom: 0 !important;
    }
}

.goley-icon-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-evenly;
    align-items: center;
    gap: 20px;
}

.goley-icon-row .et_pb_module {
    width: 120px;
    margin-bottom: 0 !important;
}

.goley-icon-row .et_pb_image img {
    width: 120px;
    height: 120px;
    object-fit: contain;
}

@media (max-width: 768px) {
    body .goley-icon-row .et_pb_module {
        width: 80px;
    }

    body .goley-icon-row .et_pb_image img {
        width: 80px;
        height: 80px;
    }
}

@media (max-width: 399px) {
    body .goley-icon-row .et_pb_image:nth-child(5) {
        display: none;
    }
}


/* Divi Pixel Adjustments */
@media screen and (max-width: 980px) {
    body .et-l--header {
        height: unset !important;
    }

    body header .et_mobile_menu:before {
        height: unset !important;
    }
}

body .et_pb_text ol,
body .et_pb_text ul,
body #left-area ul,
body .entry-content ul,
body .et-l--body ul,
body .et-l--footer ul,
body .et-l--header ul {
    padding: 0 0 1em 2em;
    line-height: 26px;
}


/* Section Styling */
body .goley_header .goley_header_right {
    text-align: center;
}

body .goley_header .goley_header_right a {
    display: inline-block;
}

body .et_pb_menu.mainmenu ul.nav>li.current-menu-item.current-menu-parent>a,
body .et_pb_menu.mainmenu .nav li ul.sub-menu a {
    font-weight: 500;
}

body .et_pb_menu.mainmenu .nav ul.sub-menu li.current_page_item>a {
    font-weight: 700;
}

body .goley_footer {
    line-height: 1.7em;
}

body .goley_footer_menu #menu-footer-menu {
    flex-direction: column;
}

/* Estimate Section */
body .goley_split_wbg.et_pb_section {
    background: linear-gradient(to right, #FFFFFF 50%, #4A4B4C 50%);
}

body .goley_split_bg.et_pb_section {
    background: linear-gradient(to right, #ECECEC 50%, #4A4B4C 50%);
}

@media screen and (max-width: 980px) {
    body .goley_split_wbg.et_pb_section {
        background: #ECECEC !important;
        background-color: #ECECEC !important;
    }

    body .goley_split_bg.et_pb_section {
        background: #ECECEC !important;
        background-color: #ECECEC !important;
    }
}

/* Sliders */
body .goley_slide h2 {
    color: var(--goley-black);
}

body .goley_slide h2 span {
    color: var(--goley-primary);
}

body .goley_slide li::marker {
    color: var(--goley-primary);
}

/* Card/Blurb Module */
body .goley-card-container {
    display: flex;
    flex-direction: column;
    min-height: 250px;
    align-items: center;
    justify-content: center;
}

body .goley-card-container .et_pb_blurb {
    /* flex: 1; */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

body .goley-card-container .et_pb_blurb_content {
    width: 100%;
    /* height: 100% !important; */
    display: flex !important;
    flex-direction: column !important;
    /* flex: 1; */
}

body .goley-card-container .et_pb_blurb_container {
    /* flex: 1; */
    display: flex;
    flex-direction: column;
}

body .goley-card-container .et_pb_module_header {
    font-weight: 800;
    margin-bottom: 20px;
}

body .goley-card-container .et_pb_blurb_description {
    display: flex !important;
    flex-direction: column !important;
    /* flex: 1; */
    font-weight: 500;
}

body .goley-card-container .et_pb_button_module_wrapper {
    margin-top: auto;
    margin-bottom: 0;
}

body .goley-card-container .goley-card-button {
    font-weight: 500;
}

/* Fullwidth Cards */
body .goley-card-fullwidth .dipi_carousel_child {
    justify-content: center !important;
}

/* body .goley-card-fullwidth .et_pb_module_inner,
body .goley-card-fullwidth .dipi-carousel-child-wrapper,
body .goley-card-fullwidth .dipi-carousel-item-content {
    height: 100%;
}
body .goley-card-fullwidth .dipi-carousel-button-wrapper {
    align-content: end;
} */

/* 3D Flip Card Module */
body .three-d-flip-card-container {
    padding: 20px 0 0;
}

@media (max-width: 767px) {
    body .three-d-card-description {
        font-size: 14px !important;
    }
}

@media (max-width: 600px) {
    body .three-d-flip-card-container .three-d-flip-card {
        height: 260px !important;
    }
}


/* CSS Utility Classes */
@media (min-width: 981px) {
    body .goley_center_column {
        vertical-align: middle;
        margin: auto;
    }
}

body .goley_center_image img {
    object-fit: cover;
    object-position: center;
}

.center-column-content {
    display: flex !important;
    align-items: center !important;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Mobile Utility Classes */
@media only screen and (max-width: 980px) {
    .mobile-stack-row {
        display: flex !important;
        flex-direction: column !important;
    }

    .mobile-stack-row .et_pb_column {
        width: 100% !important;
        float: none !important;
        clear: both !important;
        margin-right: 0 !important;
        margin-bottom: 30px !important;
    }

    .text-icon-row-mobile {
        display: flex !important;
        flex-direction: row !important;
        align-items: flex-start !important;
        justify-content: space-between !important;
        gap: 15px !important;
    }

    /* 1. Give Text Column 70% of the screen */
    .text-icon-row-mobile .et_pb_column:first-child {
        width: 65% !important;
        flex: 0 0 65% !important;
        margin-bottom: 0 !important;
        margin-right: 0 !important;
    }

    /* 2. Give Icon Column 25% of the screen */
    .text-icon-row-mobile .et_pb_column:last-child {
        width: 30% !important;
        flex: 0 0 30% !important;
        margin-bottom: 0 !important;
        margin-right: 0 !important;
    }

    .four-cols-row {
        display: flex !important;
        flex-direction: row !important;
        justify-content: space-around !important;
        align-items: center !important;
        width: 100% !important;
    }

    /* Force each Divi column to stop taking 100% width and sit side-by-side */
    .four-cols-row .et_pb_column {
        width: 22% !important;
        max-width: 22% !important;
        margin-right: 0 !important;
        margin-bottom: 0 !important;
    }

    /* Make sure the icons shrink down to fit nicely */
    .four-cols-row .et_pb_column img,
    .four-cols-row .et_pb_column .et_pb_module {
        max-width: 45px !important;
        width: 100% !important;
        margin: 0 auto !important;
    }

    .five-cols-row-mobile {
        display: flex !important;
        flex-direction: row;
        flex-wrap: nowrap !important;
        gap: 8px !important;
    }

    /* 2. Set the columns to 2 per row (approx 50% each) */
    .five-cols-row-mobile .et_pb_column {
        flex: 0 0 calc(20% - 7px) !important;
        max-width: calc(20% - 7px) !important;
        width: calc(20% - 7px) !important;
        margin-right: 0 !important;
        margin-bottom: 0px !important;
    }

    /* Force row of icons above text */
    .icons-to-row {
        display: flex !important;
        flex-direction: row !important;
        justify-content: center !important;
        gap: 15px !important;
        margin-bottom: 10px !important;
        padding-top: 30px;
        padding-bottom: 0 !important;
    }

    .row-stack-reverse {
        display: flex !important;
        flex-direction: column-reverse !important;
    }
}


/* Homepage Estimate Styling */
.home_estimate_left>.et_pb_module {
    height: 100%;
    display: flex;
    align-items: center;
}

.home_estimate_left img {
    height: 630px;
    object-fit: cover;
    object-position: right;
}

.home_iframe_div {
    height: 820px;
}

.home_iframe {
    border: 0px solid white;
    height: 820px;
    min-width: 450px;
    width: 100%;
    margin-top: 0px;
    margin-bottom: 0px;
    padding-top: 0px;
    background-color: var(--goley-white);
}

@media only screen and (max-width: 960px) {

    .home_iframe_div,
    .home_iframe {
        min-width: auto;
        height: 860px;
        margin-bottom: 0px;
        background-color: #ECECEC;
    }
}

@media only screen and (max-width: 960px) {
    .home_estimate_left img {
        height: 450px;
    }
}


/* Gravity Forms Styling */
body .gform-theme--api,
body .gform-theme--framework {
    --gf-color-primary: var(--goley-primary);
    --gf-color-primary-rgb: var(--goley-primary-rgb);
    --gf-radius: var(--goley-border-radius);
    --gf-ctrl-font-size: var(--goley-body-font-size);

    --gf-ctrl-btn-bg-color-primary: var(--goley-primary);
    --gf-ctrl-btn-color-primary: var(--goley-white);
    --gf-ctrl-btn-shadow: unset;
    --gf-ctrl-btn-radius: var(--goley-border-radius-btn);
    --gf-ctrl-btn-font-size: var(--goley-body-font-size);
    --gf-ctrl-btn-font-weight: 700;

    --gf-ctrl-btn-bg-color-hover-primary: var(--goley-dark);
    --gf-ctrl-btn-border-color-hover-primary: var(--goley-dark);

    --gf-ctrl-outline-color: transparent;
    --gf-ctrl-outline-color-focus: transparent;
    --gf-ctrl-outline-offset: 0px;
    --gf-ctrl-outline-style: none;
    --gf-ctrl-outline-width: 0;
    --gf-ctrl-outline-width-focus: 0px;
    --gf-ctrl-border-color-focus: var(--gf-ctrl-border-color);
    --gf-ctrl-btn-border-width-primary: 0px;

    --gf-ctrl-label-color-primary: var(--goley-body-color);
    --gf-ctrl-label-color-secondary: var(--goley-body-color);
}
body .gform-theme--api .credit-app-form h3, 
body .gform-theme--framework .credit-app-form h3 {
    margin: 34px 0;
}
