/* ========================================
   Main Styles - Outdoor Furniture E-commerce
   ======================================== */

/* Color Palette - Inspired by outdoor furniture */
:root {
    --primary-color: #2c5f4d;      /* Deep forest green */
    --primary-light: #4a8b6f;      /* Light green */
    --primary-dark: #1a3f31;       /* Dark green */
    --secondary-color: #d4a574;    /* Warm beige/sand */
    --secondary-light: #e8c9a8;    /* Light beige */
    --accent-color: #f4a460;       /* Sandy brown */
    --text-dark: #2d3748;          /* Dark gray */
    --text-light: #718096;         /* Light gray */
    --text-muted: #a0aec0;         /* Muted gray */
    --background: #fafaf9;         /* Off-white */
    --white: #ffffff;
    --error: #e53e3e;
    --success: #38a169;
    --border-color: #e2e8f0;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    color: var(--text-dark);
    background: var(--background);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

button {
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
}

/* ========================================
   Header & Navigation
   ======================================== */
header {
    background: var(--white);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-top {
    background: var(--primary-color);
    color: var(--white);
    padding: 0.5rem 0;
    font-size: 0.875rem;
    text-align: center;
}

.header-main {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.logo {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo span {
    color: var(--secondary-color);
}

.search-bar {
    flex: 1;
    max-width: 500px;
    position: relative;
}

.search-bar input {
    width: 100%;
    padding: 0.75rem 1rem;
    padding-right: 3rem;
    border: 2px solid var(--border-color);
    border-radius: 50px;
    font-size: 0.95rem;
    transition: all 0.3s;
}

.search-bar input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.search-bar button {
    position: absolute;
    right: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary-color);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}

.search-bar button:hover {
    background: var(--primary-dark);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.header-action {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    color: var(--text-dark);
    transition: color 0.3s;
    position: relative;
}

.header-action:hover {
    color: var(--primary-color);
}

.header-action svg {
    width: 24px;
    height: 24px;
}

.header-action span {
    font-size: 0.75rem;
    font-weight: 500;
}

.cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--accent-color);
    color: var(--white);
    width: 20px;
    height: 20px;
    border-radius: 50%;
    font-size: 0.7rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

/* Navigation */
nav {
    background: var(--white);
    border-bottom: 1px solid var(--border-color);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    display: block;
    padding: 1rem 0;
    font-weight: 500;
    color: var(--text-dark);
    border-bottom: 3px solid transparent;
    transition: all 0.3s;
}

.nav-menu a:hover {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-light) 100%);
    color: var(--white);
    padding: 4rem 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="50" cy="50" r="40" fill="rgba(255,255,255,0.05)"/></svg>');
    background-size: 50px 50px;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    animation: fadeInUp 0.8s ease;
}

.hero p {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: 2rem;
    animation: fadeInUp 0.8s ease 0.2s both;
}

.hero-btn {
    display: inline-block;
    padding: 1rem 2.5rem;
    background: var(--secondary-color);
    color: var(--white);
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    transition: all 0.3s;
    animation: fadeInUp 0.8s ease 0.4s both;
}

.hero-btn:hover {
    background: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

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

/* ========================================
   Featured Products Carousel
   ======================================== */
.featured-section {
    padding: 4rem 2rem;
    background: var(--white);
}

.section-header {
    max-width: 1400px;
    margin: 0 auto 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-dark);
}

.section-title span {
    color: var(--primary-color);
}

.view-all {
    color: var(--primary-color);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: gap 0.3s;
}

.view-all:hover {
    gap: 1rem;
}

.carousel-container {
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.carousel-track {
    display: flex;
    gap: 2rem;
    transition: transform 0.5s ease;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--white);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: all 0.3s;
    box-shadow: var(--shadow);
}

.carousel-btn:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--white);
}

.carousel-btn.prev {
    left: 1rem;
}

.carousel-btn.next {
    right: 1rem;
}

.featured-product-card {
    flex: 0 0 calc(33.333% - 1.33rem);
    background: var(--white);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s;
    cursor: pointer;
}

.featured-product-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.featured-image-container {
    position: relative;
    height: 300px;
    overflow: hidden;
}

.featured-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.featured-product-card:hover .featured-image {
    transform: scale(1.05);
}

.featured-discount-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: var(--accent-color);
    color: var(--white);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.875rem;
}

.featured-info {
    padding: 1.5rem;
}

.featured-category {
    color: var(--primary-color);
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.featured-name {
    font-size: 1.25rem;
    margin: 0.5rem 0;
    color: var(--text-dark);
}

.featured-description {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.featured-rating {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.star {
    color: #fbbf24;
    font-size: 1rem;
}

.star.empty {
    color: var(--border-color);
}

.review-count {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.featured-price {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.featured-current-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.featured-original-price {
    color: var(--text-muted);
    text-decoration: line-through;
    font-size: 1rem;
}

.featured-btn {
    width: 100%;
    padding: 0.875rem;
    background: var(--primary-color);
    color: var(--white);
    border-radius: 8px;
    font-weight: 600;
    transition: background 0.3s;
}

.featured-btn:hover {
    background: var(--primary-dark);
}

/* ========================================
   Categories Section
   ======================================== */
.categories-section {
    padding: 4rem 2rem;
    background: var(--background);
}

.categories-grid {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1.5rem;
}

.category-card {
    background: var(--white);
    padding: 2rem 1rem;
    border-radius: 16px;
    text-align: center;
    transition: all 0.3s;
    cursor: pointer;
    border: 2px solid transparent;
}

.category-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-4px);
}

.category-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 1rem;
    background: var(--secondary-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
}

.category-name {
    font-weight: 600;
    color: var(--text-dark);
}

/* ========================================
   Products Grid
   ======================================== */
.products-section {
    padding: 4rem 2rem;
    background: var(--white);
}

.products-grid {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.product-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s;
    cursor: pointer;
    border: 1px solid var(--border-color);
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.product-image-container {
    position: relative;
    height: 250px;
    overflow: hidden;
    background: var(--background);
}

.product-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.product-card:hover .product-image {
    transform: scale(1.05);
}

.discount-badge {
    position: absolute;
    top: 0.75rem;
    left: 0.75rem;
    background: var(--error);
    color: var(--white);
    padding: 0.375rem 0.75rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.75rem;
}

.product-info {
    padding: 1.25rem;
}

.product-category {
    color: var(--primary-color);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.product-name {
    font-size: 1rem;
    margin: 0.5rem 0;
    color: var(--text-dark);
    font-weight: 600;
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    margin-bottom: 0.75rem;
}

.product-rating .star {
    font-size: 0.875rem;
}

.product-price {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.current-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-color);
}

.original-price {
    color: var(--text-muted);
    text-decoration: line-through;
    font-size: 0.875rem;
}

/* ========================================
   Trust Badges
   ======================================== */
.trust-section {
    padding: 3rem 2rem;
    background: var(--secondary-light);
}

.trust-grid {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.trust-item {
    text-align: center;
}

.trust-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 1rem;
    background: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.trust-title {
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.trust-desc {
    font-size: 0.875rem;
    color: var(--text-light);
}

/* ========================================
   Footer
   ======================================== */
footer {
    background: var(--primary-dark);
    color: var(--white);
    padding: 4rem 2rem 2rem;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-section h3 {
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    color: var(--secondary-color);
}

.footer-section p {
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.8;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--secondary-color);
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}

.social-links a:hover {
    background: var(--secondary-color);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 2rem;
    text-align: center;
}

.footer-payments {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.payment-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.1);
    padding: 0.75rem 1.25rem;
    border-radius: 8px;
    transition: all 0.3s;
}

.payment-badge:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.payment-icon {
    font-size: 1.5rem;
}

.payment-name {
    font-weight: 600;
    font-size: 0.9rem;
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.875rem;
}

/* ========================================
   Notification
   ======================================== */
.notification {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--primary-color);
    color: var(--white);
    padding: 1rem 2rem;
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
    transform: translateX(400px);
    transition: transform 0.3s ease;
    z-index: 9999;
}

.notification.show {
    transform: translateX(0);
}

/* ========================================
   Responsive Design
   ======================================== */
@media (max-width: 1024px) {
    .featured-product-card {
        flex: 0 0 calc(50% - 1rem);
    }
}

@media (max-width: 768px) {
    .header-main {
        flex-wrap: wrap;
        gap: 1rem;
    }
    
    .search-bar {
        order: 3;
        max-width: 100%;
        width: 100%;
    }
    
    .nav-menu {
        gap: 1rem;
        overflow-x: auto;
        padding-bottom: 0.5rem;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    .featured-product-card {
        flex: 0 0 100%;
    }
    
    .carousel-btn {
        display: none;
    }
    
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    }
}

@media (max-width: 480px) {
    .header-actions {
        gap: 1rem;
    }
    
    .header-action span {
        display: none;
    }
    
    .hero {
        padding: 2rem 1rem;
    }
    
    .hero h1 {
        font-size: 1.75rem;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
    }
}
