:root {
    --primary-color: #2F4F4F; /* Dark Slate Green */
    --secondary-color: #C07F00; /* Rich Gold/Mustard */
    --accent-color: #E2703A; /* Terracotta */
    --bg-color: #F8F5F0; /* Off-white warm */
    --text-color: #333333;
    --text-light: #666666;
    --white: #FFFFFF;
    --border-color: #E0DCD3;
    
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.05);
    --shadow-md: 0 8px 24px rgba(47, 79, 79, 0.08);
    --shadow-lg: 0 12px 32px rgba(192, 127, 0, 0.15);
    
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

/* Top Banner */
.top-banner {
    background-color: var(--secondary-color);
    color: var(--white);
    text-align: center;
    padding: 0.6rem 1rem;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* Navbar */
.navbar {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
}

.nav-container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: 0.5px;
    white-space: nowrap;
    flex-shrink: 0;
}

.menu-toggle {
    display: none;
    font-size: 1.5rem;
    color: var(--primary-color);
    cursor: pointer;
}

.nav-links {
    display: flex;
    gap: 1.2rem;
}

.nav-links a {
    font-weight: 600;
    font-size: 1rem;
    color: var(--text-color);
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -4px;
    left: 0;
    background-color: var(--secondary-color);
    transition: var(--transition);
}

.nav-links a:hover::after {
    width: 100%;
}

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

.desktop-auth-links {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.mobile-auth-links {
    display: none;
}

.cart-icon {
    position: relative;
    font-size: 1.2rem;
    color: var(--primary-color);
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -10px;
    background: var(--accent-color);
    color: var(--white);
    font-size: 0.7rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 50%;
}

/* Main Content */
.main-content {
    min-height: calc(100vh - 300px);
    padding: 3rem 0;
}

/* Shop Layout */
.shop-container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 3rem;
}

/* Sidebar */
.sidebar {
    background: var(--white);
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    height: fit-content;
}

.sidebar h3 {
    font-size: 1.1rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--border-color);
    margin-top: 2rem;
}

.sidebar h3:first-child {
    margin-top: 0;
}

.category-list {
    list-style: none;
}

.category-list li {
    margin-bottom: 0.8rem;
}

.category-list a {
    color: var(--text-light);
    display: block;
    padding: 0.3rem 0;
}

.category-list a:hover, .category-list a.active {
    color: var(--secondary-color);
    font-weight: 600;
    padding-left: 5px;
}

.filter-form .price-inputs {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.filter-form input[type="number"] {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    outline: none;
    font-family: 'Outfit', sans-serif;
}

.filter-form input[type="number"]:focus {
    border-color: var(--secondary-color);
}

.filter-form label {
    color: var(--text-light);
    cursor: pointer;
    display: block;
    margin-bottom: 0.5rem;
}

.btn-filter {
    width: 100%;
    padding: 0.8rem;
    margin-top: 1rem;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
}

.btn-filter:hover {
    background: var(--secondary-color);
}

/* Product Grid Section */
.shop-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.shop-header h2 {
    color: var(--primary-color);
}

.limit-selector a {
    padding: 0.3rem 0.6rem;
    border-radius: var(--radius-sm);
    background: var(--white);
    color: var(--text-light);
    margin-left: 0.5rem;
    box-shadow: var(--shadow-sm);
}

.limit-selector a.active, .limit-selector a:hover {
    background: var(--secondary-color);
    color: var(--white);
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

/* Product Card */
.product-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    border: 1px solid transparent;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(192, 127, 0, 0.2);
}

.product-image {
    position: relative;
    height: 250px;
    background: #f0f0f0;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

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

.badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    z-index: 10;
}

.in-stock {
    background: rgba(255, 255, 255, 0.9);
    color: var(--primary-color);
    backdrop-filter: blur(4px);
}

.out-of-stock {
    background: var(--accent-color);
    color: var(--white);
}

.product-info {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.product-category {
    font-size: 0.8rem;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.product-title {
    font-size: 1.1rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-weight: 600;
    flex-grow: 1;
}

.product-price {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--secondary-color);
    margin-bottom: 1.5rem;
}

.product-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-add-cart {
    flex-grow: 1;
    padding: 0.8rem;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
}

.btn-add-cart:hover:not(.disabled) {
    background: var(--secondary-color);
}

.btn-add-cart.disabled {
    background: var(--text-light);
    cursor: not-allowed;
}

.btn-icon {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-light);
    cursor: pointer;
    transition: var(--transition);
}

.btn-icon:hover {
    background: var(--secondary-color);
    color: var(--white);
    border-color: var(--secondary-color);
}

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

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

.footer-column h4 {
    color: var(--secondary-color);
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
}

.footer-column p {
    margin-bottom: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    color: #e0e0e0;
}

.footer-column a {
    display: block;
    margin-bottom: 0.8rem;
    color: #e0e0e0;
}

.footer-column a:hover {
    color: var(--secondary-color);
    padding-left: 5px;
}

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

/* Notifications */
.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: var(--primary-color);
    color: var(--white);
    padding: 1rem 2rem;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    transform: translateY(100px);
    opacity: 0;
    transition: var(--transition);
    z-index: 2000;
}

.toast.show {
    transform: translateY(0);
    opacity: 1;
}

/* Floating Buttons */
.floating-buttons {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 999;
}

.float-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
}

.float-btn:hover {
    transform: translateY(-5px);
    color: white;
}

.whatsapp-btn {
    background-color: #25d366;
}

.whatsapp-btn:hover {
    background-color: #1ebe5d;
}

.scroll-top-btn {
    background-color: var(--secondary-color);
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
}

.scroll-top-btn.visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.scroll-top-btn:hover {
    background-color: #a06a00;
}

/* Responsive */
@media (max-width: 900px) {
    .footer {
        padding-bottom: 80px; /* Leave space for floating buttons */
    }
    .shop-container {
        grid-template-columns: 1fr;
    }
    .sidebar {
        margin-bottom: 2rem;
    }
    .menu-toggle {
        display: block;
    }
    .desktop-auth-links {
        display: none;
    }
    .mobile-auth-links {
        display: flex;
        flex-direction: column;
        gap: 1rem;
        margin-top: 1rem;
        border-top: 1px solid var(--border-color);
        padding-top: 1rem;
    }
    .nav-actions {
        gap: 1rem;
    }
    .nav-links {
        display: flex;
        visibility: hidden;
        opacity: 0;
        pointer-events: none;
        transform: translateY(-10px);
        transition: all 0.3s ease;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--white);
        flex-direction: column;
        padding: 1rem 2rem;
        box-shadow: var(--shadow-sm);
        gap: 1rem;
    }
    .nav-links.active {
        visibility: visible;
        opacity: 1;
        pointer-events: auto;
        transform: translateY(0);
    }
    
    /* Utility classes for inline grid overwrites on mobile */
    .responsive-grid-2 {
        grid-template-columns: 1fr !important;
    }
    
    /* Cart & Checkout Responsive Fixes */
    .cart-actions, .checkout-grid {
        flex-direction: column !important;
        grid-template-columns: 1fr !important;
    }
    .cart-totals {
        width: 100% !important;
    }
    
    /* Cart Table Responsive */
    .cart-table {
        min-width: 100% !important;
    }
    .cart-table thead {
        display: none;
    }
    .cart-table, .cart-table tbody, .cart-table tr, .cart-table td {
        display: block;
        width: 100%;
        box-sizing: border-box;
    }
    .cart-table tr {
        margin-bottom: 1.5rem;
        border: 1px solid var(--border-color) !important;
        border-radius: var(--radius-sm);
        padding: 1rem;
        background: var(--white);
    }
    .cart-table td {
        display: flex !important;
        justify-content: space-between;
        align-items: center;
        text-align: right;
        padding: 0.8rem 0 !important;
        border-bottom: 1px solid #f0f0f0 !important;
    }
    .cart-table td:last-child {
        border-bottom: none !important;
    }
    .cart-table td:before {
        content: attr(data-label);
        font-weight: bold;
        color: var(--text-light);
        flex-shrink: 0;
    }
    .cart-table td[data-label="Product"] {
        justify-content: flex-start;
    }
    .cart-table td[data-label="Product"]:before {
        display: none;
    }
}
