/*
Theme Name: Levld Heights Child
Theme URI: https://levldheights.co.uk/
Description: Child theme for Divi used by Levld Heights.
Author: PDDG
Author URI: https://pddesign.com/
Template: Divi
Version: 1.0.0
Text Domain: levldheightschild
*/

/* Globals */
.et_pb_button {
    padding-top: 10px;
    padding-bottom: 10px;
    padding-left: 20px !important;
    padding-right: 20px !important;
}

.et_pb_button:hover,
.et_pb_module .et_pb_button:hover {
    padding-top: 10px;
    padding-bottom: 10px;
    padding-left: 20px !important;
    padding-right: 30px !important;
}

/* Custom Header */
.overlayed-header #main-header {
    display: none;
}

.overlayed-header #page-container {
    padding-top: 0!important;
}

.menu-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.menu-container .menu-lets-connect-wrapper {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.menu-lets-connect {
    border-width: 0px !important;
    border-radius: 0px;
    font-size: 13px;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    background-color: #ac48a2;
    color: #FFFFFF;
    padding: 10px 20px !important;
}

/* Hover animation for "Let's Connect" button */
@keyframes connect-pop {
    0% { transform: translateY(0) scale(1); }
    60% { transform: translateY(-2px) scale(1.03); }
    100% { transform: translateY(-2px) scale(1); }
}

@media (prefers-reduced-motion: no-preference) {
    .menu-lets-connect {
        transition: transform .2s ease, box-shadow .2s ease, background-color .2s ease;
        will-change: transform;
    }
    .menu-lets-connect:hover,
    .menu-lets-connect:focus-visible {
        animation: connect-pop .22s ease-out;
        transform: translateY(-2px);
        box-shadow: 0 8px 18px rgba(172, 72, 162, 0.35);
        background-color: #cc58c1;
    }
}



.et-menu > li {
    font-size: clamp(10px, 1vw, 14px) !important;
}

.connect {
    background-color: #ac48a2;
    padding: 10px !important;
    color: #ffffff !important;
    margin-left: 30px;
}

.connect a {
    color: #fff;
    padding-bottom: 3px;
}

.et_header_style_left #et-top-navigation nav>ul>li.connect>a {
    color: #fff;
    padding-bottom: 3px;
}

@media (max-width: 980px) {
    .et_pb_image_0_tb_header .et_pb_image_wrap img {
        width: auto;
        max-width: 200px;
    }

    .header-logo-column, .header-nav-column {
        margin-bottom: 0!important
    }

    .et_pb_menu--style-left_aligned.et_pb_text_align_center .et_pb_menu__wrap {
        justify-content: flex-end!important;
    }
}

/* Gravity Forms Customization for the Join Form */
#join #input_1_1 {
    background-color: #ac48a2;
    color: #ffffff;
}

body #join .gform_wrapper ::placeholder,
body #join .gform_wrapper ::-webkit-input-placeholder,
body #join .gform_wrapper input[placeholder] {
    color: #ffffff;
    opacity: 1;
    border: none;
}

#join .gform_wrapper.gravity-theme .gform_footer,
.gform_wrapper.gravity-theme .gform_page_footer {
    padding: 0px;
}

#join #gform_submit_button_1 {
    color: #FFFFFF;
    background: #ac48a2;
    font-weight: bold;
    border: none;
    transition: 0.3s;
    text-align: right;
    padding-bottom: 8px;
    font-size: 16px;
}

#join .gform_wrapper #input_1_1 {
    background-image: url("data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8'%3F%3E%3Csvg id='Layer_1' xmlns='http://www.w3.org/2000/svg' version='1.1' viewBox='0 0 640 640'%3E%3Cdefs%3E%3Cstyle%3E .st0 %7B fill: %23fff; %7D %3C/style%3E%3C/defs%3E%3Cpath class='st0' d='M64,186.5v-2.5h0c1.2-31.1,26.9-56,58.4-56h395c31.5,0,57.1,24.9,58.4,56h0v264c0,35.3-28.7,64-64,64H128c-35.3,0-64-28.7-64-64V186.5ZM544,239.6l-176.7,129.5c-28.2,20.6-66.5,20.6-94.6,0L96,239.6v208.4c0,17.7,14.3,32,32,32h384c17.7,0,32-14.3,32-32v-208.4ZM544,186.5c0-14.6-11.9-26.5-26.5-26.5H122.5c-14.6,0-26.5,11.9-26.5,26.5s4,16.4,10.8,21.4l184.8,135.4c16.9,12.4,39.9,12.4,56.8,0l184.8-135.5c6.8-5,10.8-12.9,10.8-21.4h0Z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: 0px center;
    background-size: 24px 24px;
    padding-left: 36px;
    font-size: 16px;
}

/* home hero */
.hero-text-wrapper {
    text-align: left!important;
}

.hero-text-wrapper .hero-text {
    text-align: left;
    background: #333;
    display: table;
    padding: 10px 20px 12px;
    font-size: 4.3em;
}

.hero-text-wrapper .menu-lets-connect {
    padding: 14px 22px !important;
    margin-top: 10px;
    display: inline-block;
}

.block-text {
    background: #333;
    display: table;
    padding: 10px 20px 12px;
    font-weight: 900;
}

@media (max-width: 980px) {
    .lvl-home .hero-text-wrapper .hero-text {
        font-size: 2.5rem;
        display: inline;
        line-height: 1.3em;
        padding: 0;
    }

    .block-text {
        background: #333;
        display: inline;
        padding: 10px 10px 4px;
        line-height: 1.5em !important;
    }
}


/* posts pages */
.et_post_meta_wrapper {
    display: none;
}

/* portfolio pages */
.portfolio-grid .et_pb_portfolio_items {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2vw;
    margin-bottom: 60px;
}

.portfolio-grid .et_pb_portfolio_item {
    width: 100% !important;
    margin: 0 !important;
}

@media (max-width: 980px) {
    .portfolio-grid .et_pb_portfolio_items {
        grid-template-columns: repeat(1, 1fr);
    }
}

/* Levld Blog Grid shortcode styles */
.lv-gridify .lv-grid-posts {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2vw;
    margin-bottom: 60px;
}

/* Stack on smaller viewports */
@media (max-width: 980px) {
    .lv-gridify .lv-grid-posts {
        grid-template-columns: 1fr;
    }
}

/* Ensure items are not constrained */
.lv-gridify .lv-post-card {
    width: 100% !important;
    margin: 0 !important;
}

/* Thumb normalisation: fixed aspect ratio with cover */
.lv-gridify .lv-post-thumb {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}
.lv-gridify .lv-post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Load more button */
.lv-load-more {
    display: block;
    margin: 24px auto 0;
    padding: 10px 20px;
    background-color: #ac48a2;
    color: #fff;
    border: 0;
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    text-align: center;
}
.lv-load-more:hover,
.lv-load-more:focus {
    background-color: #cc58c1;
}
.lv-load-more.is-loading {
    opacity: 0.75;
    cursor: progress;
}

/* checked li */
ul.checked-li {
  list-style: none;
}

ul.checked-li li:before {
  content: '✓';
    margin-right: 12px;
}

.remove-pointer > div {
    cursor: default;
}

/* FOUC prevention + fade-in states (front-end only; classes applied via wp_head bootstrap) */
html.lvl-preload #page-container,
html.lvl-preload body {
  opacity: 0;
}
html.lvl-loaded #page-container,
html.lvl-loaded body {
  opacity: 1;
}
#page-container,
body {
  transition: opacity .35s ease;
}
@media (prefers-reduced-motion: reduce) {
  #page-container,
  body {
    transition: none;
  }
}

/* mobile fixes */
/* Footer mobile layout override: first two full width, last two split side-by-side */
@media (max-width: 980px) {
  /* Ensure columns 1 and 2 span full width */
  #main-footer .footer-col-1,
  #main-footer .footer-col-2 {
    width: 100% !important;
    float: none !important;
    clear: both !important;
    display: block !important;
  }

  /* Make columns 3 and 4 two-up on mobile */
  #main-footer .footer-col-3,
  #main-footer .footer-col-4 {
    width: 42% !important;
    float: left !important;
    clear: none !important;
    display: block !important;
  }

  /* Remove right margins if Divi gutters would otherwise add spacing */
  .et_pb_gutters1 #main-footer .footer-col-3,
  .et_pb_gutters1 #main-footer .footer-col-4,
  .et_pb_gutters2 #main-footer .footer-col-3,
  .et_pb_gutters2 #main-footer .footer-col-4,
  .et_pb_gutters3 #main-footer .footer-col-3,
  .et_pb_gutters3 #main-footer .footer-col-4 {
    margin-right: 0 !important;
  }
}
#lvl-nav-wrapper .et_mobile_menu {
    position: relative;
    overflow: visible; 
}

#lvl-nav-wrapper .et_mobile_menu a {
    color: #fff !important;
}


#lvl-nav-wrapper .et_mobile_menu {
    background-color: #333 !important;
    position: fixed;
    border-top: 3px solid #ac48a2;
    top: 50px;
    /* padding-top: 50px; */
}

.lvl-home #lvl-nav-wrapper .mobile_nav .mobile_menu_bar:before { /* homepage versions */
    color: #fff!important;
}

#lvl-nav-wrapper .mobile_nav .mobile_menu_bar:before { /* all other pages */
    color: #000!important;
}

/* Mobile menu close button */
.et-mobile-close {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 36px;
    height: 36px;
    display: inline-flex !important; 
    align-items: center;
    justify-content: center;
    border: 0;
    /* border-radius: 18px; */
    background-color: #ac48a2; 
    color: #fff;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    z-index: 999999; 
    box-shadow: 0 4px 12px rgba(172, 72, 162, 0.35);
}

.et-mobile-close:hover,
.et-mobile-close:focus-visible {
    background-color: #cc58c1;
    outline: none;
}

.et-mobile-close span {
    display: inline-block;
    transform: translateY(-1px);
}

.et-mobile-close-item {
    list-style: none;
    margin: 0;
    padding: 0;
    height: 0;
    position: static !important; 
}

.mobile_nav {
    position: relative; 
}
.mobile_nav .et-mobile-close {
    position: absolute;
    top: 14px;
    right: 12px;
    width: 36px;
    height: 36px;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    border: 0;
    background-color: #ac48a2;
    color: #fff;
    font-size: 30px;
    line-height: 1;
    cursor: pointer;
    z-index: 999999;
    box-shadow: 0 4px 12px rgba(172, 72, 162, 0.35);
}
