/* General Styles */
:root {
    --primary-color: #28a745;
    --secondary-color: #6c757d;
    --dark-color: #343a40;
    --light-color: #f8f9fa;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    overflow-x: hidden;
}

/* Header Styles */
.navbar {
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.navbar-brand img {
    height: 40px;
}

/* Hero Section */
.hero-section {
    margin-bottom: 30px;
}

.carousel-item {
    height: 500px;
}

.carousel-item img {
    object-fit: cover;
    height: 100%;
    width: 100%;
}

.carousel-caption {
    background: rgba(0,0,0,0.5);
    border-radius: 10px;
    padding: 20px;
}

/* Category Cards */
.category-card {
    transition: transform 0.3s ease;
    padding: 15px;
}

.category-card:hover {
    transform: translateY(-5px);
}

.category-card img {
    width: 100px;
    height: 100px;
    object-fit: cover;
}

/* Product Cards */
.product-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 20px;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

.product-image {
    position: relative;
    overflow: hidden;
    padding-top: 100%;
}

.product-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.sale-badge, .new-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 12px;
    font-weight: bold;
    color: white;
}

.sale-badge {
    background: var(--danger-color);
}

.new-badge {
    background: var(--primary-color);
}

.product-info {
    padding: 15px;
}

.product-info h5 {
    font-size: 16px;
    margin-bottom: 10px;
    color: var(--dark-color);
}

.price {
    margin-bottom: 10px;
}

.old-price {
    text-decoration: line-through;
    color: var(--secondary-color);
    margin-right: 10px;
}

.new-price, .price span:first-child {
    color: var(--primary-color);
    font-weight: bold;
    font-size: 18px;
}

/* Cart Styles */
.cart-item {
    background: white;
    padding: 15px;
    margin-bottom: 15px;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.cart-item-image {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 5px;
}

.cart-item-title {
    font-size: 16px;
    font-weight: 500;
    margin-bottom: 5px;
}

.cart-item-price {
    color: var(--primary-color);
    font-weight: bold;
}

.cart-summary {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* Checkout Form */
.checkout-form {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Order Tracking */
.tracking-timeline {
    position: relative;
    padding: 20px 0;
}

.tracking-step {
    position: relative;
    padding-left: 50px;
    margin-bottom: 30px;
}

.tracking-step:before {
    content: '';
    position: absolute;
    left: 20px;
    top: 0;
    bottom: -30px;
    width: 2px;
    background: var(--secondary-color);
}

.tracking-step:last-child:before {
    display: none;
}

.tracking-step .step-icon {
    position: absolute;
    left: 10px;
    top: 0;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--secondary-color);
    color: white;
    text-align: center;
    line-height: 20px;
    font-size: 12px;
}

.tracking-step.completed .step-icon {
    background: var(--primary-color);
}

.tracking-step.active .step-icon {
    background: var(--warning-color);
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 193, 7, 0.4);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(255, 193, 7, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(255, 193, 7, 0);
    }
}

/* Blog Styles */
.blog-post-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.blog-post-image {
    height: 250px;
    overflow: hidden;
}

.blog-post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.blog-post-card:hover .blog-post-image img {
    transform: scale(1.05);
}

.blog-post-content {
    padding: 20px;
}

.blog-post-title {
    font-size: 20px;
    margin-bottom: 10px;
}

.blog-post-meta {
    color: var(--secondary-color);
    font-size: 14px;
    margin-bottom: 15px;
}

/* Account Dashboard */
.account-sidebar {
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.account-sidebar .nav-link {
    color: var(--dark-color);
    padding: 10px 15px;
    border-radius: 5px;
    transition: background 0.3s ease;
}

.account-sidebar .nav-link:hover,
.account-sidebar .nav-link.active {
    background: var(--primary-color);
    color: white;
}

/* Responsive */
@media (max-width: 768px) {
    .carousel-item {
        height: 300px;
    }
    
    .product-card {
        margin-bottom: 15px;
    }
    
    .cart-item {
        flex-direction: column;
        text-align: center;
    }
    
    .cart-item-image {
        margin-bottom: 10px;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease forwards;
}

/* Loading Spinner */
.spinner {
    border: 3px solid rgba(0,0,0,0.1);
    border-radius: 50%;
    border-top: 3px solid var(--primary-color);
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}