/* Mobile/Tablet Navbar - Only visible on screens < 992px */
.eco-mobile-navbar {
    background-color: var(--eco-light);
    padding: 0.75rem 1.5rem;
    box-shadow: 0 2px 10px rgba(5, 111, 55, 0.08);
    position: sticky;
    top: 0;
    z-index: 999;
    display: none;
}

.eco-mobile-navbar-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

/* Logo on the left */
.eco-mobile-navbar-logo {
    height: 40px;
    width: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease-in-out;
    overflow: hidden;
    filter: drop-shadow(0px 1px 4px rgba(5, 111, 55, 0.2));
}

.eco-mobile-navbar-logo img {
    height: 100%;
    width: 100%;
    object-fit: contain;
    transition: all 0.3s ease-in-out;
   
}

.eco-mobile-navbar-logo:hover {
    transform: scale(1.05);
    filter: drop-shadow(0px 2px 12px rgba(5, 111, 55, 0.5));
}

/* Water droplet hamburger menu */
.water-droplet-menu {
    position: relative;
    width: 40px;
    height: 48px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    padding: 5px;
    outline: none;
    -webkit-tap-highlight-color: transparent;
}

.burger-lines {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    pointer-events: none;
    transition: transform 0.35s ease;
}

.burger-lines span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--eco-green);
    border-radius: 999px;
    transition: transform 0.35s ease, opacity 0.35s ease, background 0.35s ease;
}

.water-droplet-menu.active .burger-lines span:nth-child(1) {
    transform: translateY(6px) scaleX(0.45) rotate(32deg);
    background: var(--eco-blue);
}

.water-droplet-menu.active .burger-lines span:nth-child(2) {
    transform: scaleX(0.15);
    opacity: 0;
}

.water-droplet-menu.active .burger-lines span:nth-child(3) {
    transform: translateY(-6px) scaleX(0.45) rotate(-32deg);
    background: var(--eco-blue);
}

.water-droplet-menu:hover {
    transform: scale(1.1);
}

.water-droplet-menu:focus {
    outline: none;
    box-shadow: none;
}

.water-droplet-menu:active {
    outline: none;
    box-shadow: none;
}

/* Water droplet SVG */
.droplet-svg {
    width: 40px;
    height: 48px;
    transition: all 0.35s ease;
    filter: drop-shadow(0px 3px 8px rgba(5, 111, 55, 0.3));
    opacity: 0;
    transform: scale(0.7);
}

.water-droplet-menu:hover .droplet-svg {
    filter: drop-shadow(0px 4px 12px rgba(5, 111, 55, 0.5));
}

.droplet-outline {
    fill: none;
    stroke: var(--eco-green);
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: all 0.4s ease;
    stroke-dasharray: 120;
    stroke-dashoffset: 0;
}

/* Active state - drawing line effect that changes green to blue */
.water-droplet-menu.active .droplet-outline {
    stroke: var(--eco-blue);
    stroke-dasharray: 120;
    stroke-dashoffset: 120;
    animation: drawLineColorChange 0.8s ease forwards;
}

.water-droplet-menu.active .droplet-svg {
    opacity: 1;
    transform: scale(1);
}

@keyframes drawLineColorChange {
    0% {
        stroke: var(--eco-green);
        stroke-dashoffset: 0;
    }
    50% {
        stroke: var(--eco-green);
        stroke-dashoffset: -60;
    }
    100% {
        stroke: var(--eco-blue);
        stroke-dashoffset: 0;
    }
}

/* Wave fill animation - only on click */
.droplet-wave {
    fill: var(--eco-blue);
    opacity: 0;
    transform: translateY(100%);
    transition: all 0.8s ease;
}

.water-droplet-menu.active .droplet-wave {
    opacity: 0.9;
    transform: translateY(-10%);
}

/* Wave animation inside droplet */
.wave-path {
    fill: var(--eco-blue);
    opacity: 0;
}

.water-droplet-menu.active .wave-path {
    opacity: 0.8;
    animation: waveFloat 2s ease-in-out infinite;
}

@keyframes waveFloat {
    0%, 100% {
        transform: translateY(2px);
    }
    50% {
        transform: translateY(-2px);
    }
}

/* Mobile menu overlay */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1001;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Mobile menu panel - slides from left */
.mobile-menu-panel {
    position: fixed;
    top: 0;
    left: -100%;
    width: 280px;
    height: 100%;
    background: white;
    transition: all 0.6s ease;
    z-index: 1002;
    box-shadow: 4px 0 20px rgba(5, 111, 55, 0.15);
    overflow-y: auto;
}

.mobile-menu-panel.active {
    left: 0;
}

/* Mobile menu header */
.mobile-menu-header {
    padding: 1.5rem;
    border-bottom: 1px solid rgba(5, 111, 55, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.mobile-menu-title {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--eco-green);
}

.mobile-menu-close {
    width: 35px;
    height: 35px;
    background: none;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
    outline: none;
    -webkit-tap-highlight-color: transparent;
}

.mobile-menu-close:hover {
    background: rgba(5, 111, 55, 0.1);
}

.mobile-menu-close:focus {
    outline: none;
    box-shadow: none;
}

.mobile-menu-close:active {
    outline: none;
    box-shadow: none;
}

.mobile-menu-close svg {
    width: 20px;
    height: 20px;
    stroke: var(--eco-green);
}

/* Mobile menu items */
.mobile-menu-items {
    padding: 1rem 0;
}

.mobile-menu-item {
    display: block;
    padding: 1rem 1.5rem;
    color: var(--eco-green);
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(5, 111, 55, 0.05);
}

.mobile-menu-item:hover {
    background: rgba(75, 161, 248, 0.1);
    color: var(--eco-blue);
    padding-left: 2rem;
}

.mobile-menu-item.active {
    background: rgba(75, 161, 248, 0.15);
    color: var(--eco-blue);
    border-left: 4px solid var(--eco-blue);
}

/* Responsive - Show only on mobile/tablet */
@media (max-width: 991px) {
    .eco-mobile-navbar {
        display: block;
    }
}

/* Tablet adjustments */
@media (min-width: 768px) and (max-width: 991px) {
    .eco-mobile-navbar {
        padding: 1.5rem 2rem;
    }
    
    .eco-mobile-navbar-logo {
        height: 70px;
        width: 70px;
    }
    
    .water-droplet-menu {
        width: 60px;
        height: 60px;
    }
    
    .droplet-svg {
        width: 35px;
        height: 35px;
    }
    
    .mobile-menu-panel {
        width: 320px;
    }
}

/* Smooth scroll offset for sticky navbar on mobile */
html {
    scroll-behavior: smooth;
}

@media (max-width: 991px) {
    html {
        scroll-padding-top: 65px;
    }
    
    section[id] {
        scroll-margin-top: 65px;
    }
}
