/* Modern Sidebar Styling */

/* Enhanced Sidebar Container */
#mySidebar {
    background: linear-gradient(145deg, #0f172a 0%, #1e293b 50%, #334155 100%) !important;
    backdrop-filter: blur(15px);
    box-shadow: 4px 0 25px rgba(0, 0, 0, 0.15);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    color: white !important;
    position: relative;
    overflow: hidden;
}

/* Add subtle pattern overlay */
#mySidebar::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20px 20px, rgba(255,255,255,0.05) 1px, transparent 1px),
        radial-gradient(circle at 60px 60px, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 40px 40px, 80px 80px;
    pointer-events: none;
    z-index: 1;
}

/* Company Logo/Name Section */
#mySidebar h3 {
    position: relative;
    z-index: 2;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    margin: 20px 15px;
    padding: 25px 20px !important;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    font-family: 'Raleway', sans-serif;
    font-size: 28px !important;
    font-weight: 700 !important;
    color: white !important;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}

#mySidebar h3:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
    background: rgba(255, 255, 255, 0.15);
}

/* Add maritime icon to company name */
#mySidebar h3::before {
    content: "🌊";
    font-size: 24px;
    display: block;
    margin-bottom: 10px;
    animation: wave 3s ease-in-out infinite;
}

@keyframes wave {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-3px); }
}

/* Navigation Menu Items */
#mySidebar .w3-bar-item {
    position: relative;
    z-index: 2;
    color: rgba(255, 255, 255, 0.9) !important;
    background: transparent !important;
    border: none !important;
    margin: 8px 15px !important;
    padding: 15px 20px !important;
    border-radius: 12px;
    font-family: 'Raleway', sans-serif;
    font-weight: 600 !important;
    font-size: 16px !important;
    text-decoration: none !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: flex-start;
    text-align: left !important;
    backdrop-filter: blur(5px);
    border: 1px solid transparent;
}

/* Add icons to menu items */
#mySidebar .w3-bar-item::before {
    font-size: 18px;
    margin-right: 12px;
    opacity: 0.8;
    transition: all 0.3s ease;
}

#mySidebar .w3-bar-item[onclick="w3_close()"][href="#"]::before {
    content: "🏠"; /* Home icon */
}

#mySidebar .w3-bar-item[href="#about"]::before {
    content: "ℹ️"; /* About icon */
}

#mySidebar .w3-bar-item[href="#contact"]::before {
    content: "📞"; /* Contact icon */
}

#mySidebar .w3-bar-item[onclick="w3_close()"]:not([href])::before {
    content: "✕"; /* Close icon */
}

/* Hover Effects */
#mySidebar .w3-bar-item:hover {
    background: rgba(255, 255, 255, 0.15) !important;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transform: translateX(5px);
    color: white !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

#mySidebar .w3-bar-item:hover::before {
    transform: scale(1.2);
    opacity: 1;
}

/* Active State */
#mySidebar .w3-bar-item:active {
    background: rgba(255, 255, 255, 0.2) !important;
    transform: translateX(3px) scale(0.98);
}

/* Focus State for Accessibility */
#mySidebar .w3-bar-item:focus {
    outline: 2px solid rgba(255, 255, 255, 0.5);
    outline-offset: 2px;
}

/* Close Button Special Styling */
#mySidebar .w3-hide-large {
    background: rgba(255, 255, 255, 0.1) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    margin-top: 10px !important;
}

#mySidebar .w3-hide-large:hover {
    background: rgba(255, 87, 87, 0.2) !important;
    border-color: rgba(255, 87, 87, 0.3) !important;
}

/* Mobile Responsive Adjustments */
@media (max-width: 768px) {
    #mySidebar {
        width: 280px !important;
    }
    
    #mySidebar h3 {
        font-size: 24px !important;
        margin: 15px 10px;
        padding: 20px 15px !important;
    }
    
    #mySidebar .w3-bar-item {
        margin: 6px 10px !important;
        padding: 12px 16px !important;
        font-size: 15px !important;
    }
}

/* Animation for sidebar open/close */
#mySidebar.w3-animate-left {
    animation: slideInFromLeft 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideInFromLeft {
    0% {
        transform: translateX(-100%);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Top Mobile Header Enhancement */
.w3-hide-large.w3-white {
    background: linear-gradient(90deg, #0f172a 0%, #1e293b 100%) !important;
    color: white !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.w3-hide-large.w3-white .w3-left {
    font-weight: 700;
    font-family: 'Raleway', sans-serif;
}

.w3-hide-large.w3-white .w3-button {
    background: rgba(255, 255, 255, 0.1) !important;
    color: white !important;
    border-radius: 8px;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.w3-hide-large.w3-white .w3-button:hover {
    background: rgba(255, 255, 255, 0.2) !important;
    transform: scale(1.05);
}

/* Smooth scrolling for anchor links */
html {
    scroll-behavior: smooth;
}

/* Add subtle pulse animation to company name */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.8; }
}

#mySidebar h3 b {
    animation: pulse 4s ease-in-out infinite;
}