/* Background Cards Animation - Optimized for Mobile & Desktop */
.background-cards {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none; /* Allows clicking through the animation */
}

.card-bg {
    position: absolute;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.1) 0%, rgba(59, 130, 246, 0.1) 100%);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    animation: floatLeft var(--duration) linear infinite;
    animation-delay: var(--delay);
    opacity: 0.3;
    transform: translateX(-200px);
    will-change: transform; /* Optimizes animation performance */
    backface-visibility: hidden; /* Prevents flickering on mobile */
}

/* Animation */
@keyframes floatLeft {
    0% {
        transform: translateX(-200px) translateY(var(--y, 0)) rotate(0deg);
    }
    100% {
        transform: translateX(calc(100vw + 200px)) translateY(var(--y, 0)) rotate(360deg);
    }
}

/* Mobile Optimization */
@media (max-width: 767px) {
    .card-bg {
        width: 80px !important;
        height: 48px !important;
        animation-duration: 90s !important; /* Slower movement */
        opacity: 0.5 !important; /* More transparent */
    }
    
    /* Reduce number of cards on mobile */
    .background-cards .card-bg:nth-child(n+10) {
        display: none;
    }
}

/* Tablet Styles */
@media (min-width: 768px) and (max-width: 1023px) {
    .card-bg {
        width: 120px !important;
        height: 72px !important;
        animation-duration: 60s !important;
    }
}

/* Desktop Styles */
@media (min-width: 1024px) {
    .card-bg {
        width: 150px;
        height: 90px;
        animation-duration: 40s;
    }
}

/* Performance Tuning for Low-end Devices 
@media (max-width: 767px) and (prefers-reduced-motion: reduce) {
    .background-cards {
        display: none;  Disable for users who prefer reduced motion 
    }
} */

/*cart section */
.floating-cart {
    transition: all 0.3s ease;
    animation: pulse 2s infinite;
}

.floating-cart:hover {
    transform: scale(1.1);
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.cart-badge {
    box-shadow: 0 0 0 2px rgba(0,0,0,0.1);
}
/* Add to your existing CSS */
.logout-confirm-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
}

.logout-confirm-dialog {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #1f2937;
    padding: 1.5rem;
    border-radius: 0.5rem;
    z-index: 1001;
    min-width: 300px;
}

.logout-confirm-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 1rem;
}

.logout-confirm-no {
    padding: 0.5rem 1rem;
    background-color: #4b5563;
    color: white;
    border-radius: 0.375rem;
}

.logout-confirm-yes {
    padding: 0.5rem 1rem;
    background-color: #dc2626;
    color: white;
    border-radius: 0.375rem;
}
/* Giga Menu Styles */
.giga-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    overflow-y: auto;
    transform: translateX(-100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 1rem;
    box-sizing: border-box;
}

.giga-menu.open {
    transform: translateX(0);
}

.giga-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 1.5rem;
}

.giga-menu-logo {
    font-size: 1.5rem;
    font-weight: bold;
    background: linear-gradient(to right, #8B5CF6, #3B82F6);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.giga-menu-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
}

.giga-menu-sections {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

.giga-menu-section {
    margin-bottom: 2rem;
}

.giga-menu-section-title {
    color: #8B5CF6;
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(139, 92, 246, 0.3);
}

.giga-menu-links {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
}

.giga-menu-link {
    color: white;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
}

.giga-menu-link:hover {
    background: rgba(139, 92, 246, 0.2);
    transform: translateX(5px);
}

.giga-menu-link i {
    margin-right: 0.75rem;
    width: 1.5rem;
    text-align: center;
}

.giga-menu-cta {
    background: linear-gradient(to right, #8B5CF6, #3B82F6);
    color: white;
    font-weight: 600;
    text-align: center;
    padding: 1rem;
    border-radius: 0.5rem;
    margin-top: 2rem;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.giga-menu-cta:hover {
    transform: translateY(-2px);
    opacity: 0.9;
}
/* Add this to your existing giga-menu CSS */
.giga-menu-language-selector select {
    width: 100%;
    padding: 12px 16px;
    border-radius: 6px;
    border: 1px solid rgba(139, 92, 246, 0.5);
    background-color: rgba(30, 30, 30, 0.8);
    color: white;
    font-size: 16px;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%238B5CF6' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 12px;
}

.giga-menu-language-selector select:hover {
    border-color: #8B5CF6;
    background-color: rgba(40, 40, 40, 0.9);
}

.giga-menu-language-selector select:focus {
    outline: none;
    border-color: #8B5CF6;
    box-shadow: 0 0 0 2px rgba(139, 92, 246, 0.3);
}

/* Style the options dropdown */
.giga-menu-language-selector select option {
    background-color: rgba(20, 20, 20, 0.95);
    color: white;
    padding: 10px;
}

/* Remove the default dropdown arrow in IE */
.giga-menu-language-selector select::-ms-expand {
    display: none;
}

/* Animation for menu items */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.giga-menu-link {
    animation: slideIn 0.3s ease forwards;
    opacity: 0;
}

.giga-menu-link:nth-child(1) { animation-delay: 0.1s; }
.giga-menu-link:nth-child(2) { animation-delay: 0.2s; }
.giga-menu-link:nth-child(3) { animation-delay: 0.3s; }
.giga-menu-link:nth-child(4) { animation-delay: 0.4s; }
.giga-menu-link:nth-child(5) { animation-delay: 0.5s; }
.giga-menu-link:nth-child(6) { animation-delay: 0.6s; }


#scroll-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #8a2be2; /* Purple base color */
    color: white;
    border: none;
    padding: 12px 16px;
    font-size: 22px;
    border-radius: 50%;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
    box-shadow: 0 4px 12px rgba(138, 43, 226, 0.3);
    transform: translateY(20px);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
}

#scroll-top:hover {
    background-color: #9932cc; /* Darker purple on hover */
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 6px 16px rgba(138, 43, 226, 0.4);
}

#scroll-top:active {
    transform: translateY(-2px) scale(0.98);
}

#scroll-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Optional: Add a smooth arrow icon using CSS */
#scroll-top::before {
    content: "↑";
    display: block;
    font-weight: bold;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}
