/* Import animations */
@import url('animations.css');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    font-size: 14px;
    color: #333;
    scroll-behavior: smooth;
}
  .dropdown {
    position: relative;
  }

  /* Dropdown Link Style */
  .dropdown > .nav-link {
    padding: 10px 16px;
    border-radius: 8px;
    transition: background-color 0.3s;
    cursor: pointer;
  }

  /* Dropdown Menu Style */
  .dropdown-menu {
    margin-top: 0;
    border-radius: 10px;
    overflow: hidden;
    padding: 0;
  }

  .dropdown-item {
    padding: 10px 20px;
    transition: background-color 0.2s ease;
  }

  .dropdown-item:hover {
    background-color: #f1f1f1;
    color: #007bff;
  }

  /* Hover to show dropdown */
  .dropdown:hover .dropdown-menu {
    display: block;
  }
.header {
    width: 100%;
    background: white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    animation: slideDown 0.5s ease-out;
}

/* Adjust body padding to account for fixed header */
body {
    padding-top: 80px;
}

/* Keep this for any additional styles when scrolled if needed */
.header.scrolled {
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

@keyframes slideDown {
    from { transform: translateY(-100%); }
    to { transform: translateY(0); }
}

.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 5%;
    max-width: 1600px;
    margin: 0 auto;
    border-bottom: 1px solid #f0f0f0;
    transition: padding 0.3s ease;
}

.logo {
    display: flex;
    align-items: center;
    font-size: 20px;
    font-weight: 700;
    color: #333;
    text-decoration: none;
    white-space: nowrap;
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

.logo i {
    color:#1DA1F2;
    margin-right: 8px;
    font-size: 22px;
    transition: transform 0.5s ease, color 0.3s ease;
}

.logo:hover i {
    
    color: #1DA1F2;
}

.search-bar {
    display: flex;
    width: 50%;
    max-width: 600px;
    margin: 0 20px;
    height: 42px;
}

.search-container {
    position: relative;
    width: 50%;
    max-width: 600px;
    margin: 0 20px;
}

.search-bar {
    position: relative;
    display: flex;
    width: 100%;
    height: 44px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.search-bar:focus-within {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.search-input {
    flex: 1;
    padding: 0 20px;
    border: 2px solid #e0e0e0;
    border-radius: 8px 0 0 8px;
    outline: none;
    font-size: 14px;
    color: #333;
    transition: all 0.3s ease;
    background-color: #fff;
}

.search-input:focus {
    border-color: #1DA1F2;
}

.search-btn {
    padding: 0 24px;
    background: linear-gradient(135deg, #1DA1F2, #1a91da);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-size: 16px;
    border-radius: 0 8px 8px 0;
}

.search-btn:hover {
    background: linear-gradient(135deg, #1a91da, #1DA1F2);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(29, 161, 242, 0.3);
}

/* Search Results Styles */
.search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
    max-height: 400px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    margin-top: 2px;
}

.search-results.active {
    display: block;
}

.search-result-item {
    padding: 12px 20px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    color: #333;
}

.search-result-item:last-child {
    border-bottom: none;
    border-radius: 0 0 8px 8px;
}

.search-result-item:hover {
    background-color: #f8f9fa;
}

.search-result-item img {
    width: 40px;
    height: 40px;
    object-fit: cover;
    border-radius: 4px;
    margin-right: 12px;
}

.search-result-info {
    flex: 1;
}

.search-result-name {
    font-weight: 500;
    margin-bottom: 2px;
    color: #333;
}

.search-result-category {
    font-size: 12px;
    color: #666;
}

.search-result-price {
    font-weight: 600;
    color: #1DA1F2;
    margin-left: 12px;
    white-space: nowrap;
}

.no-results {
    padding: 16px 20px;
    color: #666;
    text-align: center;
    font-style: italic;
}

/* Custom scrollbar for search results */
.search-results::-webkit-scrollbar {
    width: 6px;
}

.search-results::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 0 0 8px 0;
}

.search-results::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

.search-results::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

.nav-icons {
    display: flex;
    gap: 5px;
}

.nav-icon {
    position: relative;
    text-decoration: none;
    color: #333;
    padding: 8px 0;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
}

.nav-icon-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
}

.nav-icon i {
    font-size: 20px;
    color:#1DA1F2;
    min-width: 24px;
    text-align: center;
}

.nav-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

/* Count badges */
.wishlist-count,
.cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: #e74c3c;
    color: white;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: bold;
    line-height: 1;
}

.cart-count {
    background-color:#1DA1F2;
}

/* Active state for wishlist button */
.wishlist-btn.active i,
.wishlist-icon:hover i {
    color: #e74c3c;
}

.nav-label {
    font-size: 13px;
    font-weight: 500;
    color: #333;
}

.nav-sublabel {
    font-size: 11px;
    color: #666;
    margin-top: 2px;
}

/* Cart count badge */
.cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: #e74c3c;
    color: white;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: bold;
}

/* Specific icon styles */
.account-icon .nav-sublabel {
    color:#1DA1F2;
    font-weight: 500;
}

.wishlist-icon .nav-sublabel {
    color: #e74c3c;
}

.cart-icon .nav-sublabel {
    color: #3498db;
}

/* Responsive adjustments */
@media (max-width: 992px) {
    .nav-text {
        display: none;
    }
    
    .nav-icon {
        padding: 8px;
    }
    
    .nav-icon i {
        font-size: 18px;
    }
    
    .cart-count {
        top: -5px;
        right: -5px;
    }
}

@media (min-width: 993px) {
    .nav-icon {
        min-width: 120px;
    }
}

.nav-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 5%;
    max-width: 1600px;
    margin: 0 auto;
    border-top: 1px solid #f0f0f0;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
    padding: 0;
    margin: 0;
}

.nav-menu li {
    position: relative;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    color: #333;
    padding: 8px 0;
}

.nav-menu li:hover {
    color:#1DA1F2;
}

.nav-menu li::after {
    content: '▼';
    font-size: 8px;
    margin-left: 5px;
}

.location {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 13px;
    color: #444;
}

.location i {
    color:#1DA1F2;
    font-size: 14px;
}

.nav-grid {
    color: #555;
    font-size: 16px;
    padding: 5px 10px;
    cursor: pointer;
}

.nav-grid:hover {
    color:#1DA1F2;
}

/* Sidebar Styles */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
}

.sidebar {
    position: fixed;
    top: 0;
    left: -300px;
    width: 280px;
    height: 100%;
    background: white;
    box-shadow: 2px 0 5px rgba(0,0,0,0.1);
    transition: left 0.3s ease;
    z-index: 1000;
    overflow-y: auto;
}

.sidebar.active {
    left: 0;
}

.sidebar-header {
    padding: 15px;
    background: #f8f8f8;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sidebar-categories {
    padding: 10px 0;
}

.sidebar-category {
    padding: 12px 20px;
    display: flex;
    align-items: center;
    color: #333;
    text-decoration: none;
    transition: all 0.2s;
}

.sidebar-category i {
    margin-right: 15px;
    color: #666;
    width: 20px;
    text-align: center;
}

.sidebar-category:hover {
    background: #f5f5f5;
    color:#1DA1F2;
}

.sidebar-category:hover i {
    color:#1DA1F2;
}

#closeSidebar {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: #666;
    padding: 0 10px;
}

#closeSidebar:hover {
    color: #333;
}

/* Location Selector Styles */
.location-selector {
    position: relative;
    margin-left: 15px;
}

.location-btn {
    display: flex;
    align-items: center;
    background: none;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.location-btn:hover {
    background-color: #f5f5f5;
}

.location-btn i.fa-map-marker-alt {
    color: #FF6B6B;
    margin-right: 8px;
    font-size: 16px;
}

.location-details {
    display: flex;
    flex-direction: column;
    text-align: left;
    margin-right: 8px;
}

.location-details .deliver-to {
    font-size: 12px;
    color: #666;
    line-height: 1.2;
}

.location-details .current-location {
    font-size: 13px;
    font-weight: 500;
    color: #333;
    white-space: nowrap;
}

.location-btn .fa-chevron-down {
    font-size: 10px;
    color: #888;
}

/* Location Modal */
.location-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    justify-content: center;
    align-items: flex-start;
    padding-top: 100px;
}

.location-modal.active {
    display: flex;
}

.location-modal-content {
    background: white;
    border-radius: 8px;
    width: 100%;
    max-width: 400px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    overflow: hidden;
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.location-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid #eee;
}

.location-modal-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.close-location-modal {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
    padding: 0 8px;
    line-height: 1;
}

.close-location-modal:hover {
    color: #333;
}

.location-search {
    position: relative;
    padding: 12px 20px;
    border-bottom: 1px solid #eee;
}

.location-search i {
    position: absolute;
    left: 40px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    font-size: 14px;
}

.location-search-input {
    width: 100%;
    padding: 10px 16px 10px 40px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}

.location-search-input:focus {
    border-color:#1DA1F2;
}

.location-suggestions {
    padding: 8px 0;
    max-height: 300px;
    overflow-y: auto;
}

.suggestion {
    display: flex;
    align-items: flex-start;
    padding: 12px 24px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.suggestion:hover {
    background-color: #f9f9f9;
}

.suggestion i {
    margin-right: 16px;
    color: #666;
    font-size: 18px;
    margin-top: 2px;
}

.suggestion i.fa-map-marker-alt {
    color:#1DA1F2;
}

.suggestion i.fa-home {
    color: #2196F3;
}

.suggestion i.fa-briefcase {
    color: #FF9800;
}

.suggestion-title {
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin-bottom: 2px;
}

.suggestion-subtitle {
    font-size: 12px;
    color: #666;
    line-height: 1.4;
}
