/* Mobile Menu CSS
 * Optimized for better user experience on mobile devices
 */

.menu-mobile {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: #fff;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    display: none;
    z-index: 1050;
    padding: 10px 0;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.menu-mobile__list {
    display: flex;
    justify-content: space-around;
    align-items: center;
    list-style: none;
    padding: 0;
    margin: 0;
}

.menu-mobile__item {
    flex: 1;
    text-align: center;
}

.menu-mobile__link {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 5px;
    color: #666;
    text-decoration: none;
    font-size: 1.2rem;
    transition: color 0.3s;
}

.menu-mobile__link i {
    font-size: 2rem;
    margin-bottom: 5px;
}

.menu-mobile__link.active {
    color: var(--primary-color);
}

/* Add padding to the bottom of the page to account for fixed mobile menu */


/* Show the mobile menu only on mobile devices */
@media (max-width: 768px) {
    .menu-mobile {
        display: block;
    }



    .footer {
        padding-bottom: 80px;
    }
}

/* Mobile Menu Toggle Button */
.menu-toggle {
    display: none;
    border: none;
    background: transparent;
    font-size: 2.4rem;
    color: #333;
    cursor: pointer;
    outline: none;
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .header-nav {
        display: none;
    }
}

/* Mobile Menu Animation */
.menu-mobile__link {
    position: relative;
    overflow: hidden;
}

.menu-mobile__link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background-color: #ff4d4d;
    transform: translateX(-50%);
    transition: width 0.3s;
}

.menu-mobile__link:hover::after,
.menu-mobile__link.active::after {
    width: 50%;
}

/* Mobile Overlay Menu (Fullscreen) */
.mobile-overlay-menu {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #fff;
    z-index: 1060;
    overflow-y: auto;
    padding: 20px;
    transform: translateX(-100%);
    transition: transform 0.3s ease-in-out;
    display: none;
}

.mobile-overlay-menu.active {
    transform: translateX(0);
    display: block;
}

.mobile-overlay-menu__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 15px;
    margin-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.mobile-overlay-menu__title {
    font-size: 2.2rem;
    font-weight: 700;
    margin: 0;
    color: #333;
}

.mobile-overlay-menu__close {
    background: transparent;
    border: none;
    font-size: 2.4rem;
    color: #333;
    cursor: pointer;
}

.mobile-overlay-menu__section {
    margin-bottom: 30px;
}

.mobile-overlay-menu__section-title {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 15px;
    color: #333;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.mobile-overlay-menu__links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mobile-overlay-menu__links li {
    margin-bottom: 10px;
}

.mobile-overlay-menu__link {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    color: #666;
    text-decoration: none;
    font-size: 1.6rem;
    border-radius: 8px;
    transition: all 0.3s;
    background-color: transparent;
    border: none;
    text-align: left;
    width: 100%;
    cursor: pointer;
}

.mobile-overlay-menu__link i {
    margin-right: 15px;
    width: 20px;
    text-align: center;
}

.mobile-overlay-menu__link:hover,
.mobile-overlay-menu__link:active {
    background-color: #f8f9fa;
}

.mobile-overlay-menu__button {
    font-family: inherit;
}

/* Mobile Overlay Backdrop */
.mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1055;
    display: none;
}

.mobile-overlay.active {
    display: block;
}
