/* GhanaRoll Mobile Menu Styles */
:root {
    --ghana-red: #EF3340;
    --ghana-yellow: #FFD100;
    --ghana-green: #009739;
    --black: #000000;
    --white: #FFFFFF;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    color: var(--white);
    font-size: 1.1rem;
}

.hamburger-icon,
.hamburger-icon::before,
.hamburger-icon::after {
    display: block;
    width: 25px;
    height: 3px;
    background: var(--white);
    transition: all 0.3s ease;
}

.hamburger-icon {
    position: relative;
}

.hamburger-icon::before,
.hamburger-icon::after {
    content: '';
    position: absolute;
    left: 0;
}

.hamburger-icon::before {
    top: -8px;
}

.hamburger-icon::after {
    top: 8px;
}

.menu-toggle.active .hamburger-icon {
    background: transparent;
}

.menu-toggle.active .hamburger-icon::before {
    transform: rotate(45deg);
    top: 0;
}

.menu-toggle.active .hamburger-icon::after {
    transform: rotate(-45deg);
    top: 0;
}

/* Mobile Menu Toggle */
@media (max-width: 768px) {
    .menu-toggle {
        display: block;
        order: 3;
    }

    .primary-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background-color: var(--ghana-red);
        padding: 0.5rem;
        z-index: 1000;
    }

    .primary-menu.active {
        display: block;
    }

    .primary-menu li {
        margin: 0.5rem 0;
    }
}

/* Mobile Bottom Menu */
.mobile-bottom-menu {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: #fff;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 10px 0;
    box-shadow: 0 -2px 5px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    border-top: 1px solid #EF3340;
    height: 60px; /* Fixed height for consistency */
}

.mobile-menu-item {
    text-decoration: none;
    color: #333;
    text-align: center;
    flex: 1;
    padding: 5px;
    transition: color 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.mobile-menu-item i {
    font-size: 20px;
    display: block;
    margin-bottom: 2px;
}

.mobile-menu-item .menu-label {
    font-size: 12px;
    display: block;
}

.mobile-menu-item.active {
    color: #EF3340;
    border: 2px solid #EF3340; /* Highlight with border rectangle */
    border-radius: 8px;
    padding: 3px; /* Adjust padding to fit border */
}

.mobile-menu-item.active .menu-label {
    font-weight: bold;
}

/* Style for centered Dashboard */
.menu-center {
    flex: 1.5; /* Make it slightly wider */
    background: linear-gradient(90deg, #009739, #007d2f); /* Unique background */
    border-radius: 10px;
    padding: 8px 0;
    color: #fff !important; /* Force white text */
}

.menu-center i {
    font-size: 24px; /* Larger icon */
}

.menu-center .menu-label {
    font-size: 14px; /* Larger text */
    font-weight: bold;
}

.menu-center.active {
    border-color: #FFD100; /* Gold border for active state */
}

.menu-center:hover {
    background: linear-gradient(90deg, #007d2f, #005b22); /* Darker gradient on hover */
}

/* Hide on desktop */
@media (min-width: 601px) {
    .mobile-bottom-menu {
        display: none;
    }
}

/* Ensure footer visibility */
body {
    padding-bottom: 70px; /* Match menu height + buffer, overridden by JS if needed */
    margin-bottom: 0; /* Remove default margin */
}

footer {
    position: relative;
    z-index: 1; /* Ensure footer stays above menu if overlapped */
}

/* PWA Install Button */
#install-pwa {
    position: fixed;
    bottom: 70px;
    right: 10px;
    padding: 10px 20px;
    background: #EF3340;
    color: #fff;
    border: none;
    border-radius: 4px;
    z-index: 1001;
    cursor: pointer;
    transition: background 0.3s ease;
    font-size: 14px;
}

#install-pwa:hover {
    background: #FFD100;
    color: #000;
}

/* Ensure compatibility with mobile menu */
@media (max-width: 600px) {
    #install-pwa {
        bottom: 80px; /* Adjust to avoid mobile menu overlap */
    }
}