/* ======= General Styling ======= */
body {
    font-family: 'Poppins', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f8f9fa;
}

/* ======= Header Styling ======= */
header {
    background: white;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.1);
}

.container {
    height: 100px;
    max-width: 1200px;
    margin: auto;
    padding: 0 20px;
}

/* ======= Logo Styling =======*/
.logo img {
    height: auto;  /* Maintain aspect ratio */
    width: 100%;  /* Make the logo fill the container width */
    max-width: 200px;  /* Optional: limit the maximum width */
}


/* ======= Navbar Styling ======= */
nav ul {
    list-style: none;
    padding: 0;
    display: flex;
    gap: 20px;
}

nav ul li {
    display: inline;
}

nav ul li a {
    text-decoration: none;
    font-weight: 600;
    color: #333;
    transition: color 0.3s ease;
}

nav ul li a:hover {
    color: #007bff;
}

/* ======= Search Bar Styling ======= */
.search-bar {
    position: relative;
    width: 100%;
    max-width: 400px;
}

.search-bar input {
    width: 100%;
    padding: 10px;
    border: 2px solid #007bff;
    border-radius: 5px;
    font-size: 16px;
    outline: none;
    transition: all 0.3s ease-in-out;
}

.search-bar input:focus {
    border-color: #0056b3;
    box-shadow: 0px 0px 8px rgba(0, 91, 187, 0.4);
}

/* ======= Search Results ======= */
#search-results {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: white;
    border: 1px solid #ddd;
    border-radius: 5px;
    max-height: 300px;
    overflow-y: auto;
    display: none;
    z-index: 1000;
    box-shadow: 0px 5px 10px rgba(0, 0, 0, 0.1);
}

.search-result-item {
    display: flex;
    align-items: center;
    padding: 12px;
    border-bottom: 1px solid #eee;
    transition: background 0.3s ease-in-out;
    cursor: pointer;
}

.search-result-item:hover {
    background: #f8f9fa;
}

.search-result-item img {
    width: 50px;
    height: 50px;
    object-fit: cover;
    border-radius: 5px;
    margin-right: 15px;
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.2);
}

.search-result-item a {
    text-decoration: none;
    font-weight: bold;
    font-size: 14px;
    color: #333;
    transition: color 0.3s ease-in-out;
}

.search-result-item a:hover {
    color: #007bff;
}

/* ======= Categories Section ======= */
.categories-section {
    padding: 10px 0;
    background-color: #ffffff;
}

.section-title {
    text-align: center;
    margin-bottom: 30px;
    color: #333;
    font-size: 24px;
    font-weight: 600;
}

.categories-container {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 0px;
    padding: 10px 0;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

.categories-container::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

.category-item {
    flex: 0 0 auto;
    text-align: center;
    width: 120px;
}

.category-link {
    text-decoration: none;
    color: #333;
}

.category-image {
    width: 80px;
    height: 80px;
    margin: auto;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid #fff;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s;
}

.category-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.category-item:hover .category-image {
    transform: scale(1.05);
}

.category-name {
    font-size: 14px;
    font-weight: 500;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ======= Responsive Styles for Header ======= */
@media (max-width: 992px) {
    .container {
        flex-direction: column;
        align-items: flex-start;
        justify-content: center;
    }

    nav ul {
        flex-direction: column;
        gap: 15px;
        align-items: center;
        margin: 20px 0;
    }

    .logo img {
        max-width: 150px;
    }

    .search-bar {
        max-width: 90%;
        margin-top: 10px;
    }
}

@media (max-width: 768px) {
    nav ul {
        gap: 10px;
    }

    .search-bar {
        width: 100%;
        margin-top: 15px;
    }
}

@media (max-width: 576px) {
    .logo img {
        height: 40px;
        max-width: 100px;
    }

    nav ul {
        gap: 8px;
    }

    nav ul li a {
        font-size: 14px;
    }
}

@media (max-width: 400px) {
    .container {
        padding: 0 5px;
    }

    nav ul {
        flex-direction: column;
        gap: 8px;
    }

    .logo img {
        max-width: 90px;
    }

    .search-bar {
        max-width: 90%;
        margin-top: 10px;
    }
}
