/**
 * Theme Name:     Betheme Child
 * Author:         Muffin Group
 * Template:       betheme
 * Text Domain:	   Betheme Child
 * Description:    The biggest WordPress Theme ever
 */


#Content {
padding-top: 0px !important;
}

div.gmw-item-title, h3.gmw-item.gmw-item-title {
    white-space: wrap !important;
}

div.gmw-item-footer  {
    height: 100% !important;
    display: flex;
    align-items: center;
    background-color: #fbfcfe !important;
    margin-top: 0px;
    align-self: center;
    border-top-width: 0px;
}

div.gmw-item-footer a, #gmw-submit-1, #gmw-submit-3{
    font-size: 16px;
    color: rgb(0, 0, 0);
    font-weight: 600;
    padding: 5px 40px 3px;
    border-radius: 50px 50px 50px 50px;
    border-style: solid;
    border-color: rgb(0, 0, 0);
    border-width: 1px;
    text-align: center;
    margin: 0 auto;
    font-weight: 500;
    background-color: #fbfcfe !important;
}

div.gmw-item-footer a:hover, #gmw-submit-1:hover, #gmw-submit-3:hover {
    background-color: #ba7f63;
    border-color: #ba7f63;
    color: #030303 !important;
    font-weight: 500;
}

.gmw-item-footer {
    display: flex;
}

.gmw-item.gmw-item-address {
    width: 100%;
    justify-content: center;
}

.gmw-icon-th-list, .gmw-results-wrapper a, .gmw-standard-info-window .gmw-info-window-inner i  {
    color: rgb(0, 0, 0) !important;
}

.gmw-results-wrapper .gmw-pagination li>.current, .gmw-results-wrapper .gmw-pagination li:hover>*, a.leaflet-popup-close-button {
    background-color: #c3133d !important;
    color: white !important;
}


.gmw-info-window-inner.standard, .gmw-map-wrapper .leaflet-popup-content-wrapper, .gm-style-iw-d {
    overflow: hidden !important;
    overflow-y: hidden !important;
}

.title.gmw-info-window-element a, .address.gmw-icon-location.gmw-info-window-element {
    font-family: "DM Sans";
}

.gmw-results-message {
    display: none !important;
}

.gmw-info-window-inner.standard h3.gmw-item.gmw-item-title {
    font-size: 17px;

}

.gmw-form-wrapper.gmw-template-custom-template.gmw-ajaxfmspt-custom-template-form-wrapper  form {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.gmw-form-wrapper.gmw-template-custom-template.gmw-ajaxfmspt-custom-template-form-wrapper  form > div {
    width: 100%;
}

.gmw-distance-field-wrapper {
    display: none;
}

.gmw-submit-field-wrapper {
    margin-top: auto !important;
}

.gmw-results-items.gmw-results-list li {
    display: flex;
    flex-direction: row;
}

.gmw-item-content {
    grid-template-columns: 1fr !important;
    height: 100%;
    width: 100%;
}

div.gmw-item-title h3{
    margin-bottom: 0px;
    font-size: 26px;
}

.gmw-item.gmw-location-meta-wrapper {
    margin-top: auto;
}

.field.phone {
    display: list-item !important;
}

ul.gmw-results-items.gmw-results-list {
    margin-bottom: 20px;
}

/* GMW Layout container */
[id^="gmw-layout-container-"] {
    /* display: flex; */
    gap: 20px;
    align-items: flex-start;
    padding-top: 50px !important;
}

[id^="gmw-left-col-"] {
    /* flex: 1; */
    min-width: 0;
}

[id^="gmw-right-col-"] {
    flex: 1;
    min-width: 0;
    position: sticky;
    top: 20px;
}

.gmw-item.gmw-location-meta-wrapper {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    height: 100%;
}

#bloqueMapa #gmw-global-map-wrapper-3 {
	width: 40% !important;
    height: 500px !important;
    flex: 1;
    min-width: 0;
    position: sticky;
    top: 20px;
	padding-top: 50px;
}

#bloqueMapa .column_attr.mfn-inline-editor.clearfix {
	display: flex;
	gap: 20px;
}

#bloqueMapa #gmw-map-wrapper-1 {
	display: none !important;
}

#bloqueMapa .gmw-ajax-form-container {
         flex: 1;
         min-width: 0;
}

@media (min-width: 1156px) {
    /* los <p>, <br> y el clearfix contaban como columnas flex y sumaban 100px de huecos */
    #bloqueMapa .column_attr.mfn-inline-editor.clearfix::before,
    #bloqueMapa .column_attr.mfn-inline-editor.clearfix::after,
    #bloqueMapa .column_attr > p,
    #bloqueMapa .column_attr > br {
            display: none;
    }
}

@media (max-width: 1155px) {
    [id^="gmw-layout-container-"] {
        flex-direction: column;
    }

    [id^="gmw-right-col-"] {
        position: initial !important;
    }

    #gmw-layout-container > div,
    .gmw-form-wrapper.gmw-template-custom-template.gmw-ajaxfmspt-custom-template-form-wrapper,
    .gmw-results-wrapper.gmw-template-custom-template.gmw-ajaxfmspt-custom-template-results-wrapper  {
        width: 100% !important;
    }

    #gmw-layout-container > div:nth-child(2) {
        position: initial !important;
    }

    .gmw-form-wrapper.gmw-template-custom-template.gmw-ajaxfmspt-custom-template-form-wrapper {
        margin-bottom: 0px;
    }
	
	#bloqueMapa .column_attr.mfn-inline-editor.clearfix {
        flex-direction: column;
        padding-top: 50px;
    }

    #bloqueMapa .column_attr > p {
        display: none;
    }

    /* los contenedores intermedios desaparecen y sus hijos se ordenan con order */
    #bloqueMapa .gmw-ajax-form-container,
    #bloqueMapa #gmw-layout-container-1 {
        display: contents;
    }

    #bloqueMapa .gmw-form-wrapper    { order: 1; }
    #bloqueMapa .gmw-results-wrapper { order: 3; }

    #bloqueMapa #gmw-global-map-wrapper-3 {
        order: 2;
        flex: none;
        width: 100% !important;
        height: 450px !important;
        position: static;
        padding-top: 0;
    }

    #bloqueMapa #gmw-map-wrapper-3 {
        height: 100% !important;
    }

    /* el mapa del formulario 1 sigue oculto, igual que en escritorio */
    #bloqueMapa #gmw-map-wrapper-1 {
        display: none !important;
    }

}

@media (max-width: 768px) {
    .gmw-form-wrapper.gmw-template-custom-template.gmw-ajaxfmspt-custom-template-form-wrapper form {
        display: block !important;
    }

    .gmw-results-items.gmw-results-list > li {
        flex-direction: column !important;
    }

    .gmw-element-template .gmw-item-footer {
        width: 100%;
    }

    .gmw-meta-fields.gmw-address-field {
        display: flex;
        flex-direction: row !important;
    }

    .gmw-item.gmw-item-address {
        display: flex;
    }

    .gmw-results-items.gmw-results-list {
        display: flex !important;
        flex-direction: column !important;
    }

    .content_wrapper .section_wrapper.mfn-wrapper-for-wraps.mcb-section-inner {
        padding-inline: 0px;
    }
	
	#bloqueMapa #gmw-global-map-wrapper-3 {
        height: 320px !important;
    }
}
