    </main><!-- #primary -->

    <footer id="colophon" class="site-footer">
        <div class="footer-main">
            <div class="container">
                <div class="footer-grid">
                    <!-- Brand Column -->
                    <div class="footer-brand">
                        <div class="footer-logo">
                            <?php if (has_custom_logo()) : ?>
                                <?php the_custom_logo(); ?>
                            <?php else : ?>
                                <span class="footer-logo-text">
                                    Navier<span>Instruments</span>
                                </span>
                            <?php endif; ?>
                        </div>
                        <p>
                            <?php echo esc_html(get_theme_mod('navier_footer_description', __('Spécialiste du prélèvement d\'air en milieu industriel et laboratoire. Innovation, qualité et éco-responsabilité au service de votre santé.', 'navier-instruments'))); ?>
                        </p>
                        <div class="footer-social">
                            <?php
                            $social_links = array(
                                'linkedin'  => get_theme_mod('navier_linkedin', '#'),
                                'twitter'   => get_theme_mod('navier_twitter', '#'),
                                'facebook'  => get_theme_mod('navier_facebook', '#'),
                                'youtube'   => get_theme_mod('navier_youtube', ''),
                            );

                            foreach ($social_links as $platform => $url) :
                                if (!empty($url)) :
                            ?>
                                <a href="<?php echo esc_url($url); ?>" target="_blank" rel="noopener noreferrer" aria-label="<?php echo esc_attr(ucfirst($platform)); ?>">
                                    <?php echo navier_get_social_icon($platform); ?>
                                </a>
                            <?php
                                endif;
                            endforeach;
                            ?>
                        </div>
                    </div>

                    <!-- Navigation Columns -->
                    <div class="footer-column">
                        <h4><?php esc_html_e('Products', 'navier-instruments'); ?></h4>
                        <?php
                        wp_nav_menu(array(
                            'theme_location' => 'footer',
                            'menu_class'     => 'footer-menu',
                            'container'      => false,
                            'depth'          => 1,
                            'fallback_cb'    => function() {
                                echo '<ul class="footer-menu">';
                                echo '<li><a href="#">' . esc_html__('Air Samplers', 'navier-instruments') . '</a></li>';
                                echo '<li><a href="#">' . esc_html__('Analyzers', 'navier-instruments') . '</a></li>';
                                echo '<li><a href="#">' . esc_html__('Accessories', 'navier-instruments') . '</a></li>';
                                echo '<li><a href="#">' . esc_html__('Software', 'navier-instruments') . '</a></li>';
                                echo '</ul>';
                            },
                        ));
                        ?>
                    </div>

                    <div class="footer-column">
                        <h4><?php esc_html_e('Company', 'navier-instruments'); ?></h4>
                        <?php
                        wp_nav_menu(array(
                            'theme_location' => 'footer-2',
                            'menu_class'     => 'footer-menu',
                            'container'      => false,
                            'depth'          => 1,
                            'fallback_cb'    => function() {
                                echo '<ul class="footer-menu">';
                                echo '<li><a href="#">' . esc_html__('About Us', 'navier-instruments') . '</a></li>';
                                echo '<li><a href="#">' . esc_html__('Our Values', 'navier-instruments') . '</a></li>';
                                echo '<li><a href="#">' . esc_html__('Careers', 'navier-instruments') . '</a></li>';
                                echo '<li><a href="#">' . esc_html__('News', 'navier-instruments') . '</a></li>';
                                echo '</ul>';
                            },
                        ));
                        ?>
                    </div>

                    <div class="footer-column">
                        <h4><?php esc_html_e('Contact', 'navier-instruments'); ?></h4>
                        <ul class="footer-menu footer-contact">
                            <li>
                                <svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
                                    <path d="M21 10c0 7-9 13-9 13s-9-6-9-13a9 9 0 0 1 18 0z"></path>
                                    <circle cx="12" cy="10" r="3"></circle>
                                </svg>
                                <span>
                                    <?php echo esc_html(get_theme_mod('navier_address', 'Senlis, France')); ?>
                                </span>
                            </li>
                            <li>
                                <svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
                                    <path d="M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z"></path>
                                </svg>
                                <a href="tel:<?php echo esc_attr(get_theme_mod('navier_phone', '+33 3 44 00 00 00')); ?>">
                                    <?php echo esc_html(get_theme_mod('navier_phone', '+33 3 44 00 00 00')); ?>
                                </a>
                            </li>
                            <li>
                                <svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
                                    <path d="M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2z"></path>
                                    <polyline points="22,6 12,13 2,6"></polyline>
                                </svg>
                                <a href="mailto:<?php echo esc_attr(get_theme_mod('navier_email', 'contact@navier-instruments.com')); ?>">
                                    <?php echo esc_html(get_theme_mod('navier_email', 'contact@navier-instruments.com')); ?>
                                </a>
                            </li>
                        </ul>
                    </div>
                </div>
            </div>
        </div>

        <div class="footer-bottom">
            <div class="container">
                <div class="footer-bottom-inner">
                    <p class="copyright">
                        &copy; <?php echo date('Y'); ?> <?php bloginfo('name'); ?>.
                        <?php esc_html_e('All rights reserved.', 'navier-instruments'); ?>
                    </p>
                    <ul class="footer-legal">
                        <?php
                        wp_nav_menu(array(
                            'theme_location' => 'legal',
                            'container'      => false,
                            'items_wrap'     => '%3$s',
                            'depth'          => 1,
                            'fallback_cb'    => function() {
                                echo '<li><a href="#">' . esc_html__('Privacy Policy', 'navier-instruments') . '</a></li>';
                                echo '<li><a href="#">' . esc_html__('Terms of Use', 'navier-instruments') . '</a></li>';
                                echo '<li><a href="#">' . esc_html__('Legal Notice', 'navier-instruments') . '</a></li>';
                            },
                        ));
                        ?>
                    </ul>
                </div>
            </div>
        </div>
    </footer><!-- #colophon -->

</div><!-- #page -->

<?php wp_footer(); ?>

<!-- Fallback script to ensure animations work -->
<script>
(function() {
    // Initialize immediately
    function revealAll() {
        document.body.classList.add('loaded');
        document.querySelectorAll('[data-reveal]').forEach(function(el) {
            el.classList.add('revealed');
        });
        document.querySelectorAll('.animate').forEach(function(el) {
            el.classList.add('animated');
        });
    }

    // Run after a short delay as fallback
    setTimeout(revealAll, 1000);
})();
</script>

</body>
</html>
