/* General Body Styles */
body {
    margin: 0;
    padding: 0;
    font-family: 'Open Sans', sans-serif;
    background-color: #180279; /* Light grey background */
    color: #333;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh; /* Full viewport height */
    overflow-x: hidden; /* Prevent horizontal scroll */
}

/* Main Container */
#main-container {
    width: 100%;
    max-width: 1200px; /* Max width for content */
    padding: 20px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: linear-gradient(135deg, #30029c 0%, #2f02ad 100%); /* Green gradient */
    border-radius: 15px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    position: relative; /* For dvPartner positioning */
}

/* Header Section */
.main-header {
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    margin-bottom: 40px;
    flex-wrap: wrap; /* Allow wrapping on smaller screens */
    color: #fff;
    padding: 20px;
    width: 100%;
}

.main-header .logo-area {
    padding: 0 20px;
}

.main-header .logo-area img {
    max-width: 100px;
    height: auto;
}

.main-header .title-area {
    flex-grow: 1; /* Allows title to take available space */
    padding: 0 20px;
}

.main-header h1 {
    font-size: 2.5em;
    margin: 0;
    font-weight: 700;
}

.main-header h2 {
    font-size: 2em;
    margin: 5px 0;
    font-weight: 700;
}

.main-header h3 {
    font-size: 1.5em;
    margin: 0;
    font-weight: 400;
    opacity: 0.9;
}

/* Menu Grid */
.menu-grid {
    display: flex;
    flex-direction: column; /* Stack categories vertically */
    gap: 30px; /* Space between categories */
    width: 100%;
    align-items: center;
}

.menu-category {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); /* Responsive columns */
    gap: 20px;
    width: 100%;
    justify-items: center; /* Center items within grid cells */
    max-width: 1000px; /* Limit width of menu rows */
}

.menu-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    background-color: rgba(255, 255, 255, 0.15); /* Slightly transparent white */
    padding: 15px;
    border-radius: 10px;
    transition: all 0.3s ease;
    width: 100%; /* Take full width of grid cell */
    box-sizing: border-box;
    color: #fff; /* Text color for menu items */
    text-align: center;
    min-height: 120px; /* Ensure consistent height */
    justify-content: center;
}

.menu-item:hover {
    background-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.3);
}

.menu-item img {
    max-width: 80px; /* Max size for menu icons */
    height: auto;
    margin-bottom: 10px;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2)); /* Subtle shadow for icons */
}

.menu-item span {
    font-size: 0.9em;
    font-weight: 600;
    white-space: nowrap; /* Prevent text wrapping */
    overflow: hidden;
    text-overflow: ellipsis; /* Add ellipsis if text is too long */
}

/* Partner Info Section */
#dvPartner {
    background-color: rgba(0, 0, 0, 0.4); /* Darker transparent background */
    color: #fff;
    padding: 10px;
    border-radius: 8px;
    font-size: 0.85em;
    font-family: Tahoma, sans-serif;
    margin-top: 30px;
    width: 100%;
    max-width: 300px; /* Limit width */
    box-sizing: border-box;
    text-align: center;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);
}

/* Responsiveness */
@media (max-width: 768px) {
    .main-header {
        flex-direction: column;
    }

    .main-header .logo-area {
        margin-bottom: 20px;
    }

    .main-header h1 {
        font-size: 1.6em;
    }

    .main-header h2 {
        font-size: 1.8em;
    }

    .main-header h3 {
        font-size: 1.2em;
    }

    .menu-category {
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr)); /* Smaller items on small screens */
        gap: 15px;
    }

    .menu-item img {
        max-width: 60px;
    }

    .menu-item span {
        font-size: 0.8em;
    }
}

@media (max-width: 450px) {
    #main-container {
        padding: 15px;
    }

    .main-header h1 {
        font-size: 1.8em;
    }

    .main-header h2 {
        font-size: 1.4em;
    }

    .main-header h3 {
        font-size: 1em;
    }

    .menu-category {
        grid-template-columns: repeat(auto-fit, minmax(80px, 1fr)); /* Even smaller items */
        gap: 10px;
    }

    .menu-item {
        padding: 10px;
        min-height: 90px;
    }

    .menu-item img {
        max-width: 50px;
    }
}

/* Existing scripts and their functions (ensure these are loaded and working) */
/* Assuming vtip.js, ajax.js, bgstretcher.js, and index.js contain necessary functions */

/* For vtip.js (tooltip styling, make sure it looks good with new design) */
.vtip { /* You might need to adjust this based on your vtip.css */
    cursor: help;
}

/* bgstretcher.js related styles might be managed by the script itself */
/* but ensure no conflicts with body styles */