/*
Theme Name: Astra Child
Theme URI: https://wpastra.com/
Template: astra
Author: Brainstorm Force
Author URI: https://wpastra.com/about/?utm_source=theme_preview&utm_medium=author_link&utm_campaign=astra_theme
Description: The Astra WordPress theme is lightning-fast and highly customizable. It has over 1 million downloads and the only theme in the world with 6,000+ five-star reviews! It’s ideal for professional web designers, solopreneurs, small businesses, eCommerce, membership sites and any type of website. It offers special features and templates so it works perfectly with all page builders like Spectra, Elementor, Beaver Builder, etc. Fast performance, clean code, mobile-first design and schema markup are all built-in, making the theme exceptionally SEO-friendly. It’s fully compatible with WooCommerce, SureCart and other eCommerce plugins and comes with lots of store-friendly features and templates. Astra also provides expert support for free users. A dedicated team of fully trained WordPress experts are on hand to help with every aspect of the theme. Try the live demo of Astra: https://zipwp.org/themes/astra/
Tags: custom-menu,custom-logo,entertainment,one-column,two-columns,left-sidebar,e-commerce,right-sidebar,custom-colors,editor-style,featured-images,full-width-template,microformats,post-formats,rtl-language-support,theme-options,threaded-comments,translation-ready,blog
Version: 4.11.15.1764106964
Updated: 2025-11-25 21:42:44

*/

// Auto-select the "90 min" service in Booking Calendar
add_action( 'wp_footer', function() {
    ?>
    <script>
        document.addEventListener('DOMContentLoaded', function() {
            const options = document.querySelectorAll('.wpbc_time_option, .wpbc_time_selected, .wpbc_time_slot');

            options.forEach(option => {
                const text = option.innerText.trim();

                // Match the 90 minute option
                if (text.includes('90 min') || text.includes('90min') || text.includes('90')) {
                    option.click();
                }
            });
        });
    </script>
    <?php
});

/************************************************************
  ASTRA – CUSTOM BREAKPOINT: 1350 PX
  Replace the default 921px breakpoint fully and safely.
************************************************************/

/* ----------------------------------------------------------
   1) MOBILE HEADER should appear BELOW 1350 px
---------------------------------------------------------- */
@media (max-width: 1350px) {

    /* Hide desktop navigation */
    .main-header-bar-navigation {
        display: none !important;
    }

    /* Show mobile header */
    .ast-mobile-header-wrap,
    .ast-mobile-menu-buttons,
    .ast-mobile-header-content {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
}

/* ----------------------------------------------------------
   2) DESKTOP HEADER should appear ABOVE 1350 px
---------------------------------------------------------- */
@media (min-width: 1351px) {

    /* Show desktop navigation */
    .main-header-bar-navigation {
        display: flex !important;
    }

    /* Hide mobile header menu/button */
    .ast-mobile-header-wrap,
    .ast-mobile-menu-buttons,
    .ast-mobile-header-content {
        display: none !important;
        visibility: hidden !important;
        opacity: 0 !important;
    }
}

/* ----------------------------------------------------------
   3) Fix for dropdowns opening permanently (Astra mobile bug)
---------------------------------------------------------- */
@media (max-width: 1350px) {
    .ast-header-break-point .main-header-menu .menu-item-has-children > .ast-menu-toggle {
        display: inline-block !important;
    }
    .ast-header-break-point .main-header-menu .sub-menu {
        display: none !important;
    }
    .ast-header-break-point .main-header-menu .menu-item-has-children.ast-submenu-open > .sub-menu {
        display: block !important;
    }
}


/*FOOTER */
/* ==========================================================
   FOOTER LINKS – FIX COLOR + REMOVE BLUE OVERRIDE
   ========================================================== */

/* Target ONLY Astra footer menu links */
#astra-footer-menu .menu-link,
#astra-footer-menu a {
    color: #4f6b57 !important;          /* your new muted green */
    text-decoration: none !important;
    opacity: 0.85 !important;
    font-weight: 500;
}

/* Hover effect */
#astra-footer-menu .menu-link:hover,
#astra-footer-menu a:hover {
    color: #2c5b3c !important;          /* darker green on hover */
    opacity: 1 !important;
    text-decoration: underline !important;
}

/* Remove WordPress default blue link styling */
.footer-bar-navigation a {
    color: inherit !important;
}

