/* ============================================
   ECOCART LITE - COMPLETE STYLESHEET
   ============================================ */

/* --------------------------------------------
   RESET & BASE
   -------------------------------------------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.5;
    background: #ffffff;
    color: #111827;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --------------------------------------------
   UTILITY CLASSES
   -------------------------------------------- */
.text-center { text-align: center; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }

/* --------------------------------------------
   HEADER / NAVIGATION BAR
   -------------------------------------------- */
.site-header {
    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
}

.logo a {
    font-size: 24px;
    font-weight: bold;
    text-decoration: none;
    color: #111827;
}

.main-nav {
    display: flex;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 32px;
}

.nav-links a {
    text-decoration: none;
    color: #4b5563;
    font-size: 15px;
}

.nav-links a:hover {
    color: #111827;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.cart-link {
    text-decoration: none;
    color: #4b5563;
    font-size: 15px;
}

.cart-link:hover {
    color: #111827;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #111827;
}

/* --------------------------------------------
   HERO SECTION
   -------------------------------------------- */
.hero {
    padding: 60px 0;
    background: linear-gradient(135deg, #f9fafb 0%, #ffffff 100%);
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
}

.hero-title {
    font-size: 48px;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
    color: #111827;
}

.hero-description {
    font-size: 18px;
    color: #6b7280;
    margin-bottom: 32px;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 16px;
}

.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s;
}

.btn-primary {
    background: #111827;
    color: #ffffff;
    border: 1px solid #111827;
}

.btn-primary:hover {
    background: #374151;
    border-color: #374151;
}

.btn-secondary {
    background: transparent;
    color: #111827;
    border: 1px solid #e5e7eb;
}

.btn-secondary:hover {
    background: #f9fafb;
    border-color: #d1d5db;
}

.hero-visual {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.hero-image {
    background: #f3f4f6;
    border-radius: 24px;
    padding: 40px;
    text-align: center;
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-image img {
    max-width: 100%;
    height: auto;
}

.hero-stats {
    display: flex;
    justify-content: space-between;
    gap: 16px;
}

.stat-item {
    flex: 1;
    text-align: center;
    padding: 16px;
    background: #f9fafb;
    border-radius: 16px;
}

.stat-number {
    display: block;
    font-size: 28px;
    font-weight: 800;
    color: #111827;
}

.stat-label {
    font-size: 14px;
    color: #6b7280;
}

/* --------------------------------------------
   TRUST BADGES SECTION
   -------------------------------------------- */
.trust-badges {
    padding: 40px 0;
    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
}

.badges-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.badge {
    text-align: center;
    padding: 20px;
}

.badge-icon {
    font-size: 36px;
    margin-bottom: 12px;
}

.badge h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #111827;
}

.badge p {
    font-size: 13px;
    color: #6b7280;
}

/* --------------------------------------------
   FILTER SECTION
   -------------------------------------------- */
.filter-section {
    padding: 40px 0 20px 0;
    border-bottom: 1px solid #e5e7eb;
}

.filter-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}

.filter-btn {
    padding: 8px 20px;
    border: 1px solid #e5e7eb;
    background: #ffffff;
    border-radius: 40px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
    color: #4b5563;
}

.filter-btn .count {
    font-size: 12px;
    color: #9ca3af;
}

.filter-btn:hover {
    border-color: #111827;
    background: #f9fafb;
}

.filter-btn.active {
    background: #111827;
    border-color: #111827;
    color: #ffffff;
}

.filter-btn.active .count {
    color: #9ca3af;
}

.brand-filter-container {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e5e7eb;
}

/* --------------------------------------------
   PRODUCTS GRID
   -------------------------------------------- */
.products-section,
.best-sellers,
.on-sale,
.cart-page,
.checkout-page {
    padding: 48px 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
}

.section-header h2 {
    font-size: 28px;
    font-weight: 600;
}

.view-all {
    color: #4b5563;
    text-decoration: none;
    font-size: 14px;
}

.view-all:hover {
    color: #111827;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.product-card {
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.2s;
    background: #ffffff;
}

.product-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transform: translateY(-2px);
}

.product-image {
    position: relative;
    background: #f9fafb;
    padding: 24px;
    text-align: center;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-image img {
    max-width: 100%;
    max-height: 150px;
    object-fit: contain;
}

.image-placeholder {
    font-size: 48px;
}

.sale-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: #ef4444;
    color: white;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
}

.product-info {
    padding: 16px;
}

.product-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
    color: #111827;
}

.product-brand {
    font-size: 13px;
    color: #6b7280;
    margin-bottom: 12px;
}

.product-price {
    margin-bottom: 16px;
}

.price {
    font-size: 20px;
    font-weight: 700;
    color: #111827;
}

.price-old {
    font-size: 14px;
    color: #9ca3af;
    text-decoration: line-through;
    margin-right: 8px;
}

.price-sale {
    font-size: 20px;
    font-weight: 700;
    color: #ef4444;
}

.add-to-cart {
    width: 100%;
    padding: 10px;
    background: #111827;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}

.add-to-cart:hover {
    background: #374151;
}

/* --------------------------------------------
   BANNER FULL WIDTH
   -------------------------------------------- */
.banner-full {
    background-size: cover;
    background-position: center;
    padding: 100px 0;
    margin: 48px 0;
    text-align: center;
    color: white;
}

.banner-full-content h2 {
    font-size: 42px;
    font-weight: 800;
    margin-bottom: 16px;
}

.banner-full-content p {
    font-size: 18px;
    margin-bottom: 24px;
    opacity: 0.95;
}

.banner-full-content .btn {
    background: white;
    color: #111827;
    border: none;
}

.banner-full-content .btn:hover {
    background: #f3f4f6;
}

/* --------------------------------------------
   BANNER SPLIT
   -------------------------------------------- */
.banner-split {
    padding: 48px 0;
    margin: 48px 0;
    background: #f9fafb;
}

.banner-split-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
}

.banner-split.reverse .banner-split-grid {
    direction: rtl;
}

.banner-split.reverse .banner-split-grid > * {
    direction: ltr;
}

.banner-split-image img {
    width: 100%;
    height: auto;
    border-radius: 16px;
}

.banner-split-content h2 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 16px;
    color: #111827;
}

.banner-split-content p {
    font-size: 16px;
    color: #6b7280;
    margin-bottom: 24px;
    line-height: 1.6;
}

/* --------------------------------------------
   CART PAGE
   -------------------------------------------- */
.cart-empty {
    text-align: center;
    padding: 60px 0;
}

.cart-empty h2 {
    font-size: 28px;
    margin-bottom: 16px;
}

.cart-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 48px;
}

.cart-items {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    overflow: hidden;
}

.cart-item {
    display: grid;
    grid-template-columns: 100px 1fr auto;
    gap: 20px;
    padding: 20px;
    border-bottom: 1px solid #e5e7eb;
    align-items: center;
}

.cart-item:last-child {
    border-bottom: none;
}

.cart-item-image {
    width: 80px;
    height: 80px;
    background: #f9fafb;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-item-image img {
    max-width: 100%;
    max-height: 60px;
    object-fit: contain;
}

.cart-item-details h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
}

.cart-item-details p {
    font-size: 13px;
    color: #6b7280;
}

.cart-item-quantity {
    display: flex;
    align-items: center;
    gap: 12px;
}

.qty-btn {
    width: 32px;
    height: 32px;
    border: 1px solid #e5e7eb;
    background: #ffffff;
    border-radius: 8px;
    cursor: pointer;
    font-size: 18px;
}

.qty-btn:hover {
    background: #f9fafb;
}

.cart-item-price {
    font-weight: 600;
    min-width: 80px;
    text-align: right;
}

.cart-item-remove {
    color: #ef4444;
    cursor: pointer;
    font-size: 20px;
}

.cart-summary {
    background: #f9fafb;
    border-radius: 16px;
    padding: 24px;
    position: sticky;
    top: 100px;
}

.cart-summary h3 {
    font-size: 20px;
    margin-bottom: 20px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid #e5e7eb;
}

.summary-row.total {
    font-weight: 700;
    font-size: 18px;
    border-bottom: none;
    padding-top: 16px;
}

.checkout-btn {
    display: block;
    width: 100%;
    text-align: center;
    background: #111827;
    color: white;
    padding: 14px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    margin-top: 20px;
}

.checkout-btn:hover {
    background: #374151;
}

/* --------------------------------------------
   CHECKOUT PAGE
   -------------------------------------------- */
.checkout-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
}

.checkout-form {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    padding: 32px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 6px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #111827;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.order-summary {
    background: #f9fafb;
    border-radius: 16px;
    padding: 32px;
    position: sticky;
    top: 100px;
}

.order-item {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid #e5e7eb;
}

.shipping-methods {
    margin: 20px 0;
}

.shipping-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin-bottom: 12px;
    cursor: pointer;
}

.shipping-option.selected {
    border-color: #111827;
    background: #f9fafb;
}

.payment-methods {
    margin: 20px 0;
}

.payment-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin-bottom: 12px;
    cursor: pointer;
}

.payment-option.selected {
    border-color: #111827;
    background: #f9fafb;
}

.place-order-btn {
    width: 100%;
    background: #111827;
    color: white;
    border: none;
    padding: 14px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 20px;
}

.place-order-btn:hover {
    background: #374151;
}

/* --------------------------------------------
   FOOTER
   -------------------------------------------- */
.site-footer {
    background: #f9fafb;
    border-top: 1px solid #e5e7eb;
    padding: 48px 0 24px;
    margin-top: 48px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 32px;
    margin-bottom: 32px;
}

.footer-col h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
}

.footer-col p,
.footer-col ul {
    font-size: 14px;
    color: #6b7280;
}

.footer-col ul {
    list-style: none;
}

.footer-col li {
    margin-bottom: 8px;
}

.footer-col a {
    text-decoration: none;
    color: #6b7280;
}

.footer-col a:hover {
    color: #111827;
}

.footer-bottom {
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid #e5e7eb;
    font-size: 14px;
    color: #6b7280;
}

.social-links {
    display: flex;
    gap: 16px;
}

.social-link {
    text-decoration: none;
    color: #6b7280;
}

.social-link:hover {
    color: #111827;
}

/* --------------------------------------------
   MOBILE RESPONSIVE
   -------------------------------------------- */
@media (max-width: 1024px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .cart-grid,
    .checkout-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }
    
    .main-nav {
        position: fixed;
        top: 0;
        left: -280px;
        width: 280px;
        height: 100%;
        background: #ffffff;
        box-shadow: 2px 0 12px rgba(0, 0, 0, 0.1);
        transition: left 0.3s ease;
        z-index: 200;
        padding: 80px 20px 20px;
    }
    
    .main-nav.open {
        left: 0;
    }
    
    .nav-links {
        flex-direction: column;
        gap: 20px;
    }
    
    .menu-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 150;
    }
    
    .menu-overlay.active {
        display: block;
    }
    
    .hero-grid,
    .banner-split-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }
    
    .hero-title {
        font-size: 36px;
    }
    
    .hero-stats {
        flex-wrap: wrap;
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .badges-grid,
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .banner-full {
        padding: 60px 0;
    }
    
    .banner-full-content h2 {
        font-size: 28px;
    }
    
    .cart-item {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 12px;
    }
    
    .cart-item-price {
        text-align: center;
    }
    
    .cart-item-quantity {
        justify-content: center;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
}

@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .badges-grid,
    .footer-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-buttons {
        flex-direction: column;
    }
    
    .btn {
        text-align: center;
    }
}

/* Center filter buttons */
.filter-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
    justify-content: center;
}

/* Improved checkout page - Address left, Order summary right with payment */
.checkout-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: start;
}

.checkout-form {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    padding: 32px;
}

.order-summary {
    background: #f9fafb;
    border-radius: 16px;
    padding: 32px;
    position: sticky;
    top: 100px;
}

.order-summary h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e5e7eb;
}

.order-items-list {
    max-height: 300px;
    overflow-y: auto;
    margin-bottom: 20px;
}

.order-item {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid #e5e7eb;
}

.order-item:last-child {
    border-bottom: none;
}

.shipping-methods {
    margin: 20px 0;
    padding: 16px 0;
    border-top: 1px solid #e5e7eb;
    border-bottom: 1px solid #e5e7eb;
}

.shipping-methods h4,
.payment-methods h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 12px;
}

.shipping-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin-bottom: 12px;
    cursor: pointer;
    background: #ffffff;
}

.shipping-option.selected {
    border-color: #111827;
    background: #f9fafb;
}

.payment-methods {
    margin: 20px 0;
}

.payment-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin-bottom: 12px;
    cursor: pointer;
    background: #ffffff;
}

.payment-option.selected {
    border-color: #111827;
    background: #f9fafb;
}

.place-order-btn {
    width: 100%;
    background: #111827;
    color: white;
    border: none;
    padding: 14px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 20px;
}

.place-order-btn:hover {
    background: #374151;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
}

.summary-row.total {
    font-weight: 700;
    font-size: 18px;
    border-top: 1px solid #e5e7eb;
    margin-top: 12px;
    padding-top: 16px;
}

/* Product card stock badge */
.product-stock {
    font-size: 12px;
    color: #10b981;
    margin-bottom: 8px;
}

.product-stock.low {
    color: #f59e0b;
}

.product-stock.out {
    color: #ef4444;
}
.product-category {
    font-size: 12px;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.product-stock {
    font-size: 12px;
    margin-bottom: 8px;
    text-align: left;
}

.product-stock:not(.low):not(.out) {
    color: #10b981;
}

.product-stock.low {
    color: #f59e0b;
}

.product-stock.out {
    color: #ef4444;
}