:root {
    --primary-color: #4f46e5;
    --text-light: #878787;
    --border-color: #f0f0f0;
}

body {
    margin: 0;
    padding-bottom: 60px;
    /* Space for bottom nav */
    font-family: Roboto, Arial, sans-serif;
}

/* Header Styles */
.navbar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 0;
    height: 60px;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    position: relative;
    z-index: 100;
}

.navbar-brand {
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    color: white;
    font-weight: 600;
    font-size: 20px;
    padding: 0 20px;
    height: 100%;
    display: flex;
    align-items: center;
    letter-spacing: -0.5px;
}

.navbar-brand:hover {
    color: rgba(255, 255, 255, 0.9);
}

.search-container {
    max-width: 500px;
    width: 100%;
    margin: 0 16px;
    position: relative;
}

.search-form {
    position: relative;
    width: 100%;
}

.search-input {
    width: 100%;
    padding: 12px 16px 12px 45px;
    border: none;
    border-radius: 25px;
    font-size: 14px;
    height: 40px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.search-input:focus {
    outline: none;
    background: white;
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.15);
    transform: translateY(-1px);
}

.search-input::placeholder {
    color: #9ca3af;
    font-weight: 400;
}

.search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #6b7280;
    font-size: 16px;
    z-index: 1;
}


.nav-item .nav-link {
    color: white;
    padding: 0 20px;
    font-size: 14px;
    font-weight: 500;
    height: 60px;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
    position: relative;
}

.nav-item .nav-link:hover {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
}

.nav-item .nav-link::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 3px;
    background: white;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-item .nav-link:hover::before {
    width: 80%;
}
.account-section {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-left: auto;
    height: 100%;
    padding: 0 20px;
}

.account-section a {
    color: white;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 20px;
    transition: all 0.3s ease;
}

.account-section a:hover {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
}

/* Mobile Search */
.mobile-search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: #4f46e5;
    padding: 8px 16px;
    z-index: 1000;
    display: none;
}

.mobile-search-overlay.active {
    display: block;
}

.mobile-search-form {
    position: relative;
    width: 100%;
}

.mobile-search-input {
    width: 100%;
    padding: 8px 40px;
    border: none;
    border-radius: 2px;
    font-size: 14px;
}

.mobile-search-close {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    cursor: pointer;
}

/* Bottom Navigation */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    display: flex;
    justify-content: space-around;
    padding: 10px 0;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}


.bottom-nav-item {
    color: #666;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 0.8rem;
}

.bottom-nav-item .icon-container {
    position: relative;
    display: inline-block;
}

.bottom-nav-item .cart-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    min-width: 20px;
    height: 20px;
    border-radius: 50%;
    background-color: #ff4444;
    color: white;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
}

.bottom-nav-item span:not(.cart-badge) {
    font-size: 12px;
    margin-top: 4px;
}

.bottom-nav-item.active {
    color: #4f46e5;
}
.bottom-nav-item span {
    font-size: 12px;
}
.bottom-nav-item i {
    font-size: 1.2rem;
    margin-bottom: 4px;
}
#main-content {
    padding-bottom: 70px; /* Add padding to prevent content from being hidden behind bottom nav */
}
.cart-badge {
    position: absolute;
    top: 0;
    right: -10;
    background: #ff4444;
    color: white;
    font-size: 10px;
    padding: 1px 2px;
    border-radius: 70%;
    width: 14px;
    /* Equal width and height for a circular shape */
    height: 14px;
}

/* Footer Styles */
.footer {
    background: #172337;
    padding: 40px 0 20px;
    color: white;
    margin-top: 40px;
}

.footer-section {
    margin-bottom: 30px;
}

.footer-title {
    color: #878787;
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 12px;
    text-transform: uppercase;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 8px;
}

.footer-links a {
    color: white;
    text-decoration: none;
    font-size: 12px;
    opacity: 0.8;
}

.footer-links a:hover {
    opacity: 1;
}

.footer-address {
    font-size: 12px;
    opacity: 0.8;
    line-height: 1.5;
}

.footer-bottom {
    border-top: 1px solid #454d5e;
    padding-top: 20px;
    margin-top: 40px;
}

.footer-bottom-links {
    display: flex;
    align-items: center;
    gap: 24px;
}

.footer-bottom-links a {
    display: flex;
    align-items: center;
    gap: 8px;
    color: white;
    text-decoration: none;
    font-size: 12px;
}

@media (max-width: 768px) {
    .navbar {
        height: 56px;
    }

    .nav-item .nav-link {
        height: 56px;
    }

    .search-input {
        height: 36px;
        padding: 10px 14px 10px 40px;
        font-size: 13px;
    }

    .search-icon {
        left: 14px;
        font-size: 14px;
    }

    .navbar-brand {
        font-size: 18px;
        padding: 0 16px;
    }

    .account-section {
        padding: 0 16px;
        gap: 16px;
    }

    .search-container {
        display: flex;
    }

    .bottom-nav {
        display: flex;
    }

    .footer {
        padding: 24px 0;
        margin-bottom: 56px;
    }
}

.search-container {
    position: relative;
    margin: 0;
    max-width: none;
    width: auto;
}

.search-toggle {
    color: white;
    cursor: pointer;
    padding: 0 12px;
    height: 56px;
    display: flex;
    align-items: center;
}

.search-expanded {
    position: absolute;
    top: 50%;
    right: 100%;
    transform: translateY(-50%);
    width: 0;
    overflow: hidden;
    transition: width 0.3s ease;
    background: white;
    border-radius: 2px;
}

.search-expanded.active {
    width: 300px;
}

.search-form {
    width: 100%;
    height: 36px;
    display: flex;
    align-items: center;
}

.search-input {
    width: 100%;
    height: 100%;
    padding: 8px 16px;
    border: none;
    background: white;
}

.search-close {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    cursor: pointer;
    display: none;
}

.search-expanded.active .search-close {
    display: block;
}

@media (max-width: 768px) {
    .search-expanded.active {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        width: 100%;
        height: 48px;
        transform: none;
        z-index: 1001;
    }

    .search-form {
        height: 100%;
    }
}

.bottom-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 8px;
    color: var(--text-light);
    text-decoration: none;
    font-size: 12px;
    gap: 4px;
}

.bottom-nav-item.active {
    color: #4f46e5 !important;
    /* Added !important to ensure it overrides other styles */
}

.bottom-nav-item i {
    font-size: 16px;
    overflow: visible;
}

/* Common badge styles for both header and bottom nav */
.cart-badge {
    position: absolute;
    background-color: #ff4444;
    color: white;
    border-radius: 50%;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    font-weight: 500;
}

/* Header cart badge positioning */
.navbar .position-relative {
    position: relative;
}

.navbar .cart-badge {
    top: -8px;
    right: -8px;
}

/* Bottom navigation styles */
.bottom-nav-item {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #666;
    padding: 8px 0;
}

.bottom-nav-item.active {
    color: #007bff;
}

.bottom-nav-item .icon-container {
    position: relative;
    display: inline-block;
}

.bottom-nav-item .cart-badge {
    top: -6px;
    right: -6px;
}

.bottom-nav-item i {
    font-size: 20px;
    margin-bottom: 4px;
}

.bottom-nav-item span:not(.cart-badge) {
    font-size: 12px;
}

/* Bottom nav container */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 8px 0;
    border-top: 1px solid #eee;
    z-index: 1000;
}

/* Hide bottom nav on desktop */
@media (min-width: 768px) {
    .bottom-nav {
        display: none;
    }
}

.desktop-nav-items {
    display: none;
}

@media (min-width: 768px) {
   .desktop-nav-items {
        display: flex;
        align-items: center;
        gap: 1.5rem;
        margin-left: 1.5rem;
    }

    .desktop-nav-items a {
        color: #ffffff;
        text-decoration: none;
        display: flex;
        align-items: center;
        gap: 0.5rem;
        font-weight: 500;
        padding: 8px 16px;
        border-radius: 20px;
        transition: all 0.3s ease;
    }

    .desktop-nav-items a:hover {
        background: rgba(255, 255, 255, 0.15);
        backdrop-filter: blur(10px);
    }

    .desktop-nav-items .cart-link {
        position: relative;
    }

    .desktop-nav-items .cart-badge {
        position: absolute;
        top: -8px;
        right: -8px;
        background: #ff4757;
        color: white;
        border-radius: 50%;
        padding: 0.25rem 0.5rem;
        font-size: 0.75rem;
        font-weight: 600;
        min-width: 20px;
        height: 20px;
        display: flex;
        align-items: center;
        justify-content: center;
        box-shadow: 0 2px 10px rgba(255, 71, 87, 0.3);
    }
}

.wish-container {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin-bottom: 10px;
}

.confirm-wish-btn {
    padding: 5px 10px;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.confirm-wish-btn:hover {
    background-color: #45a049;
}

.wish-textarea {
    flex: 1;
}