/* Reset and Base Styles */
:root[data-theme="light"] {
    --bg-color: #fff;
    --text-color: #333;
    --nav-bg: #fff;
    --card-bg: #fff;
    --footer-bg: #222;
    --footer-text: #fff;
    --accent-color: #ff4d4d;
    --section-bg: #f9f9f9;
}

:root[data-theme="dark"] {
    --bg-color: #1a1a1a;
    --text-color: #fff;
    --nav-bg: #2d2d2d;
    --card-bg: #2d2d2d;
    --footer-bg: #1a1a1a;
    --footer-text: #fff;
    --accent-color: #ff6b6b;
    --section-bg: #2d2d2d;
}

:root[data-theme="pink"] {
    --bg-color: #fff0f3;
    --text-color: #333;
    --nav-bg: #fff;
    --card-bg: #fff;
    --footer-bg: #ff4d79;
    --footer-text: #fff;
    --accent-color: #ff4d79;
    --section-bg: #fff5f7;
    --accent-color-rgb: 255, 77, 121;
}

:root[data-theme="gold"] {
    --bg-color: #fff8e6;
    --text-color: #333;
    --nav-bg: #fff;
    --card-bg: #fff;
    --footer-bg: #ffa940;
    --footer-text: #fff;
    --accent-color: #ffa940;
    --section-bg: #fff4e6;
    --accent-color-rgb: 255, 169, 64;
}

:root[data-theme="white"] {
    --bg-color: #ffffff;
    --text-color: #333;
    --nav-bg: #f8f8f8;
    --card-bg: #fff;
    --footer-bg: #222;
    --footer-text: #fff;
    --accent-color: #4d4d4d;
    --section-bg: #f9f9f9;
}

:root[data-theme="pink-dark"] {
    --bg-color: #2d2d2d;
    --text-color: #fff;
    --nav-bg: #363636;
    --card-bg: #363636;
    --footer-bg: #2d2d2d;
    --footer-text: #fff;
    --accent-color: #ff6b6b;
    --section-bg: #363636;
    --accent-color-rgb: 255, 107, 107;
}

:root[data-theme="yellow-green"] {
    --bg-color: #f6ffed;
    --text-color: #333;
    --nav-bg: #fff;
    --card-bg: #fff;
    --footer-bg: #52c41a;
    --footer-text: #fff;
    --accent-color: #52c41a;
    --section-bg: #f9fff0;
    --accent-color-rgb: 82, 196, 26;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Arial', sans-serif;
}

body {
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Header and Navigation */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 5%;
    background-color: var(--nav-bg);
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
}

.logo-image {
    width: 45px;
    height: 45px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--accent-color) 0%, var(--accent-color) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.3rem;
    font-weight: bold;
    box-shadow: 0 4px 15px rgba(255, 77, 77, 0.2);
    transition: all 0.3s ease;
}

.logo-container:hover .logo-image {
    transform: rotate(-5deg) scale(1.05);
    box-shadow: 0 6px 20px rgba(255, 77, 77, 0.3);
}

.logo {
    font-size: 1.6rem;
    font-weight: bold;
    background: linear-gradient(135deg, var(--accent-color) 0%, var(--accent-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    transition: all 0.3s ease;
}

.logo-container:hover .logo {
    transform: translateX(3px);
}

.nav-center {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex: 1;
    justify-content: center;
    max-width: 800px;
}

.search-container {
    position: relative;
    width: 100%;
    max-width: 500px;
    margin: 0 1rem;
}

.search-input {
    width: 100%;
    padding: 0.9rem 1rem 0.9rem 3rem;
    border: 2px solid transparent;
    border-radius: 25px;
    background-color: var(--bg-color);
    color: var(--text-color);
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.search-input:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.search-input::placeholder {
    color: var(--text-color);
    opacity: 0.5;
}

.search-icon {
    position: absolute;
    left: 1.2rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-color);
    opacity: 0.5;
    transition: all 0.3s ease;
    pointer-events: none;
}

.search-input:focus + .search-icon {
    color: var(--accent-color);
    opacity: 1;
}

.search-results {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;
    background-color: var(--card-bg);
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    max-height: 400px;
    overflow-y: auto;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.search-results.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.search-result-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: all 0.3s ease;
}

.search-result-item:last-child {
    border-bottom: none;
}

.search-result-item:hover {
    background-color: rgba(var(--accent-color-rgb), 0.1);
}

.search-result-image {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    object-fit: cover;
}

.search-result-info {
    flex: 1;
}

.search-result-title {
    font-weight: 500;
    margin-bottom: 0.2rem;
}

.search-result-price {
    color: var(--accent-color);
    font-weight: 600;
}

.no-results {
    padding: 2rem;
    text-align: center;
    color: var(--text-color);
    opacity: 0.7;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
    margin: 0;
    padding: 0;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-links a:hover {
    color: var(--accent-color);
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.theme-toggle-group {
    display: flex;
    gap: 0.5rem;
}

.theme-toggle {
    padding: 0.8rem;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: linear-gradient(135deg, #ff4d79 0%, #ffa940 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.theme-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.theme-toggle i {
    font-size: 1.2rem;
    transition: transform 0.5s ease;
}

.theme-toggle.gold i {
    transform: rotate(180deg);
}

.theme-toggle.active {
    transform: scale(1.1);
    box-shadow: 0 0 10px rgba(0,0,0,0.2);
}

.cart-icon {
    font-size: 1.5rem;
    cursor: pointer;
}

/* Hero Section */
.hero {
    height: 80vh;
    background: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('https://images.unsplash.com/photo-1441984904996-e0b6ba687e04');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    margin-top: 60px;
}

.hero-content {
    padding: 2rem;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.shop-now-btn {
    display: inline-block;
    padding: 1rem 2rem;
    background-color: #ff4d4d;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    margin-top: 1rem;
    transition: background-color 0.3s ease;
}

.shop-now-btn:hover {
    background-color: #ff3333;
}

/* Categories Section */
.categories {
    padding: 4rem 5%;
    text-align: center;
    background-color: var(--bg-color);
}

.categories h2 {
    margin-bottom: 2rem;
}

.category-container {
    display: flex;
    gap: 2rem;
    justify-content: center;
}

.category-card {
    flex: 1;
    max-width: 500px;
    height: 300px;
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    background-size: cover;
    background-position: center;
}

.category-card.men {
    background-image: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('https://images.unsplash.com/photo-1516257984-b1b4d707412e');
}

.category-card.women {
    background-image: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('https://images.unsplash.com/photo-1483985988355-763728e1935b');
}

.category-card h3 {
    color: white;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.8rem;
}

.category-btn {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.8rem 1.5rem;
    background-color: white;
    color: #333;
    text-decoration: none;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.category-btn:hover {
    background-color: #ff4d4d;
    color: white;
}

/* Featured Products */
.featured-products {
    padding: 4rem 5%;
    background-color: var(--section-bg);
    text-align: center;
}

.featured-products h2 {
    margin-bottom: 2rem;
}

.section-title {
    font-size: 1.8rem;
    color: var(--text-color);
    margin: 3rem 0 2rem;
    text-align: left;
    position: relative;
    padding-left: 1rem;
}

.section-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 70%;
    background-color: var(--accent-color);
    border-radius: 2px;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.product-card {
    background-color: var(--card-bg);
    padding: 1rem;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    opacity: 0;
    animation: fadeInDown 0.6s ease forwards;
}

.product-card img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.product-card.watch img,
.product-card.shoes img {
    object-fit: contain;
    background-color: var(--bg-color);
    padding: 1.5rem;
}

.product-card:hover {
    transform: translateY(5px) scale(1.02);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.product-card:hover img {
    transform: scale(1.05);
}

.product-card h3 {
    margin: 0.5rem 0;
}

.price {
    color: #ff4d4d;
    font-weight: bold;
    margin: 0.5rem 0;
}

.add-to-cart {
    width: 100%;
    padding: 0.8rem;
    background-color: #333;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.add-to-cart:hover {
    background-color: #ff4d4d;
}

.sale-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background-color: var(--accent-color);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    font-weight: bold;
    font-size: 0.9rem;
    z-index: 1;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

/* Newsletter Section */
.newsletter {
    padding: 4rem 5%;
    text-align: center;
    background-color: var(--footer-bg);
    color: var(--footer-text);
}

.newsletter-form {
    max-width: 500px;
    margin: 2rem auto;
    display: flex;
    gap: 1rem;
}

.newsletter-form input {
    flex: 1;
    padding: 0.8rem;
    border: none;
    border-radius: 5px;
}

.newsletter-form button {
    padding: 0.8rem 1.5rem;
    background-color: #ff4d4d;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.newsletter-form button:hover {
    background-color: #ff3333;
}

/* Footer */
footer {
    background-color: var(--footer-bg);
    color: var(--footer-text);
    padding: 4rem 5% 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3 {
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section a {
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: #ff4d4d;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #444;
}

/* Responsive Design */
@media (max-width: 768px) {
    .navbar {
        padding: 1rem;
    }

    .nav-links {
        display: none;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .category-container {
        flex-direction: column;
    }

    .newsletter-form {
        flex-direction: column;
    }

    .footer-content {
        grid-template-columns: 1fr;
    }

    .nav-center {
        display: none;
    }
    
    .section-title {
        text-align: center;
        margin: 2rem 0;
    }
    
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 1rem;
    }
}

/* Animation Classes */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-on-scroll.animate {
    opacity: 1;
    transform: translateY(0);
}

/* Floating Cart Animation */
.floating-cart {
    position: fixed;
    font-size: 24px;
    transition: all 0.5s ease;
    pointer-events: none;
    z-index: 1001;
}

/* Sparkle Effect */
.sparkle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    background: radial-gradient(circle, rgba(255,255,255,0.8) 0%, rgba(255,255,255,0) 70%);
    border-radius: 50%;
    pointer-events: none;
    animation: sparkleAnimation 0.5s ease-out;
}

@keyframes sparkleAnimation {
    0% {
        transform: translate(-50%, -50%) scale(0);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scale(2);
        opacity: 0;
    }
}

/* Cart Icon Enhancement */
.cart-icon {
    position: relative;
    z-index: 1000;
    transition: all 0.3s ease;
}

/* Product Card Enhancements */
.product-card {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.product-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    transition: 0.5s;
}

.product-card:hover::before {
    left: 100%;
}

/* Category Card Enhancements */
.category-card {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.category-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: 0.5s;
}

.category-card:hover::after {
    transform: translateX(100%);
}

/* Newsletter Form Enhancement */
.newsletter-form {
    transition: all 0.3s ease;
}

.newsletter-form input {
    transition: all 0.3s ease;
}

.newsletter-form input:focus {
    transform: scale(1.02);
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.1);
}

/* Logo Animation */
.logo {
    transition: color 0.5s ease;
}

/* Hero Section Enhancement */
.hero {
    transition: background-position 0.5s ease-out;
}

/* Button Animations */
.shop-now-btn, .category-btn, .add-to-cart, .newsletter-form button {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.shop-now-btn::before,
.category-btn::before,
.add-to-cart::before,
.newsletter-form button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    transition: 0.5s;
}

.shop-now-btn:hover::before,
.category-btn:hover::before,
.add-to-cart:hover::before,
.newsletter-form button:hover::before {
    left: 100%;
}

/* Add animation classes to existing elements */
.hero-content {
    animation: fadeInUp 1s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Price tag animation */
.price {
    transition: all 0.3s ease;
}

.product-card:hover .price {
    transform: scale(1.1);
    color: var(--accent-color);
}

/* Product Animation */
@keyframes productFloat {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.product-card {
    animation: productFloat 3s ease-in-out infinite;
    animation-play-state: paused;
}

.product-card:hover {
    animation-play-state: running;
}

/* New Product Styles */
.product-card.watch img,
.product-card.shoes img {
    object-fit: contain;
    background-color: #f8f8f8;
    padding: 1rem;
}

.product-card .sale-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: var(--accent-color);
    color: white;
    padding: 0.5rem;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

/* Product Animations */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Staggered animation delay for products */
.product-grid .product-card:nth-child(1) { animation-delay: 0.1s; }
.product-grid .product-card:nth-child(2) { animation-delay: 0.2s; }
.product-grid .product-card:nth-child(3) { animation-delay: 0.3s; }
.product-grid .product-card:nth-child(4) { animation-delay: 0.4s; }
.product-grid .product-card:nth-child(5) { animation-delay: 0.5s; }

/* Add animation when products come into view */
.product-card.animate {
    animation: fadeInDown 0.6s ease forwards;
}

/* Enhanced hover effect */
.product-card:hover {
    transform: translateY(5px) scale(1.02);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.product-card:hover img {
    transform: scale(1.05);
}

/* Add shimmer effect on hover */
.product-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255,255,255,0.2),
        transparent
    );
    transition: 0.5s;
}

.product-card:hover::after {
    left: 100%;
} 