/* CSS Variables */
:root {
    --primary-blue: #004B8D;
    --primary-dark: #003366;
    --accent-yellow: #F4B324;
    --accent-yellow-hover: #DFA01E;
    /* Slightly darker for hover */
    --badge-red: #D32F2F;
    --text-dark: #333333;
    --text-gray: #757575;
    --bg-light: #F5F6FA;
    --white: #FFFFFF;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.1);
    --radius-md: 8px;
    --radius-pill: 50px;
}

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

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

/* Utilities */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.main-header {
    background-color: var(--white);
    padding: 15px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-container {
    display: flex;
    align-items: center;
}

.logo-text {
    display: flex;
    align-items: center;
}

.logo-brand {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.logo-brand h1 {
    font-size: 24px;
    line-height: 1;
    color: var(--primary-blue);
    font-weight: 800;
    letter-spacing: -0.5px;
}

.logo-brand p {
    font-size: 10px;
    color: var(--text-gray);
    letter-spacing: 1px;
    text-transform: uppercase;
    font-weight: 600;
}

.logo-icon {
    font-size: 32px;
    color: var(--accent-yellow);
    /* Using SVG placeholder or icon font if available, simulating the stack icon */
    /* background-image: url('...'); */
    /* For now, just a nice icon styling */
    width: 40px;
    height: 40px;
    /* background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path d="M20,80 Q10,50 50,20 L80,20 Q90,50 50,80 L20,80 Z" fill="%23E65100"/><path d="M10,70 Q20,30 50,10" stroke="%231565C0" stroke-width="15" fill="none"/></svg>'); */
    /* Abstract shape placeholder */
    background-size: contain;
    background-repeat: no-repeat;
    vertical-align: middle;
    margin-right: 10px;
    float: left;
}


.header-actions {
    display: flex;
    gap: 20px;
    align-items: center;
}

.icon-btn {
    font-size: 20px;
    color: var(--text-gray);
    position: relative;
    transition: color 0.3s;
    background: none;
    border: none;
    cursor: pointer;
}

.icon-btn:hover {
    color: var(--primary-blue);
}

.cart-badge {
    position: absolute;
    top: -5px;
    right: -8px;
    background-color: var(--badge-red);
    color: white;
    font-size: 10px;
    font-weight: bold;
    height: 16px;
    width: 16px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(to right, #1E4D8C, #4A90E2 60%, #1E4D8C);
    /* Gradient approximation */
    color: white;
    padding: 60px 0;
    position: relative;
    overflow: hidden;
    height: 700px;
}

.hero-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 2;
}

.hero-text {
    width: 50%;
}

.hero-text h2 {
    font-size: 42px;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 20px;
}

.divider {
    height: 1px;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.3);
    margin: 20px 0;
}

.hero-text p {
    font-size: 16px;
    margin-bottom: 30px;
}

.btn-primary {
    display: inline-block;
    background-color: var(--accent-yellow);
    color: var(--text-dark);
    padding: 12px 30px;
    border-radius: var(--radius-md);
    font-weight: 600;
    text-transform: capitalize;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, background-color 0.2s;
    text-decoration: none;
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    background-color: var(--accent-yellow-hover);
    transform: translateY(-2px);
}

.hero-image-container {
    width: 40%;
    display: flex;
    justify-content: center;
    position: relative;
}

/* Simulated bag with CSS/Icons */
.bag-illustration {
    font-size: 200px;
    color: rgba(255, 255, 255, 0.2);
    position: relative;
}

.bag-illustration .fa-bag-shopping {
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.2));
}

.heart-icon {
    position: absolute;
    top: 55%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: rgba(255, 255, 255, 0.4);
    font-size: 80px;
}

.slider-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: background-color 0.3s;
}

.dot.active {
    background-color: var(--white);
}

/* Navigation Categories */
.category-nav {
    background-color: var(--white);
    padding: 15px 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    overflow-x: auto;
    /* Allow Scroll on mobile */
    white-space: nowrap;
}

.nav-pills {
    display: flex;
    justify-content: center;
    /* Center on desktop */
    min-width: min-content;
    list-style: none;
    /* Remove bullets */
}

.category-nav .container {
    padding-bottom: 5px;
    /* Scrollbar space */
}

/* Mobile alignment fix */
@media (max-width: 768px) {
    .nav-pills {
        justify-content: flex-start;
        padding-left: 20px;
    }
}

.nav-pills li {
    margin: 0 5px;
}

.nav-pills a {
    display: block;
    padding: 8px 24px;
    border-radius: var(--radius-pill);
    color: var(--text-gray);
    font-weight: 500;
    transition: all 0.3s;
    text-decoration: none;
}

.nav-pills li.active a,
.nav-pills a:hover {
    background-color: var(--primary-blue);
    color: white;
    box-shadow: 0 4px 6px rgba(0, 75, 141, 0.2);
}

/* Featured Products */
.featured-products {
    padding: 40px 0 60px;
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
    position: relative;
}

.section-title h3 {
    font-size: 24px;
    color: var(--text-dark);
    display: inline-block;
    padding: 10px 30px;
    background-color: var(--accent-yellow);
    border-radius: var(--radius-md);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    position: relative;
    z-index: 1;
}

/* Line behind title */
.section-title::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 1px;
    background-color: #ddd;
    z-index: 0;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.product-card {
    background: white;
    border-radius: var(--radius-md);
    padding: 15px;
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
    display: flex;
    flex-direction: column;
}

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

.badge {
    position: absolute;
    top: 15px;
    left: 0;
    /* Ribbon style */
    padding: 4px 10px;
    color: white;
    font-weight: bold;
    font-size: 12px;
    border-radius: 0 4px 4px 0;
    z-index: 2;
}

.badge.discount {
    background-color: var(--badge-red);
}

.badge.new {
    background-color: #E64A19;
}

.product-image {
    height: 180px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 15px;
    overflow: hidden;
}

.product-image img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
    transition: transform 0.3s;
}

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

.product-info {
    text-align: center;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.brand-tag {
    background-color: var(--primary-blue);
    color: white;
    font-size: 10px;
    padding: 2px 8px;
    border-radius: 10px;
    display: inline-block;
    margin: 0 auto 8px;
    text-transform: uppercase;
}

.product-info h4 {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-dark);
    margin-bottom: 15px;
    min-height: 40px;
    /* Two lines approx */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.price-container {
    min-height: 40px;
    margin-bottom: 15px;
    display: flex;
    flex-direction: row;
    /* Side by side */
    justify-content: center;
    align-items: baseline;
    /* Align by text baseline */
    gap: 10px;
}

.price {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-dark);
}

.price.old {
    font-size: 16px;
    /* Slightly larger readable grey */
    text-decoration: line-through;
    color: #9E9E9E;
    /* Material Grey 500 */
    font-weight: 500;
    margin-bottom: 0;
}

.price.offer {
    color: #333;
    /* Darker as shown in image, or keep red if preferred but user image looked dark/greyish */
    color: var(--text-dark);
    /* Using dark text as per image provided (approx) */
    font-size: 24px;
}

/* Modern Button & Quantity Control */
.card-actions {
    margin-top: auto;
    /* Push to bottom */
    width: 100%;
    min-height: 42px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.btn-add-initial {
    width: 100%;
    padding: 12px;
    background-color: var(--primary-blue);
    color: white;
    border: none;
    border-radius: var(--radius-pill);
    /* Pill shape */
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 6px rgba(0, 51, 102, 0.2);
}

.btn-add-initial:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 8px rgba(0, 51, 102, 0.3);
}

.quantity-control {
    display: flex;
    align-items: center;
    background-color: transparent;
    /* Transparent container */
    border: none;
    box-shadow: none;
    padding: 0;
    width: auto;
    /* Fit content */
    height: 40px;
    gap: 10px;
    /* Space between buttons and input */
    margin: 0 auto;
}

.qty-btn {
    background: transparent;
    border: none;
    width: 40px;
    /* Wider clickable area */
    height: 40px;
    /* Taller clickable area */
    cursor: pointer;
    font-weight: 400;
    color: var(--text-dark);
    font-size: 28px;
    /* Larger symbol */
    line-height: 1;
    /* Reset line-height for symbol */
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: none;
    padding: 0;
    border-radius: 50%;
    /* Hover effect circle */
    position: relative;
    /* Ensure stacking */
    z-index: 10;
}

.qty-btn:hover {
    color: var(--primary-blue);
    background-color: rgba(0, 0, 0, 0.05);
    /* Subtle hover bg */
    transform: scale(1.1);
}

.qty-btn:active {
    transform: scale(0.95);
}

.qty-input {
    flex: none;
    width: 80px;
    height: 36px;
    background-color: #f5f5f5;
    border: 1px solid #e0e0e0;
    border-radius: 50px;
    text-align: center;
    font-size: 18px;
    /* Slightly larger text */
    font-weight: 600;
    color: var(--text-dark);
    padding: 0;
    line-height: normal;
    /* Browser default */
    display: flex;
    /* Flexbox centering for text */
    align-items: center;
    justify-content: center;
    /* Remove arrows in Chrome/Safari/Edge/Opera */
    -webkit-appearance: none;
    margin: 0;
}

/* Remove arrows for input type number across browsers */
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

input[type=number] {
    -moz-appearance: textfield;
}

.qty-input:focus {
    outline: none;
    border-color: #bbb;
}

/* Badge Low Stock - Absolute positioning */
.badge.low-stock {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 20;
    background: linear-gradient(135deg, #FF9800, #F57C00);
    color: white;
    font-size: 10px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.legal-text {
    text-align: center;
    color: var(--text-gray);
    font-size: 14px;
    border-top: 1px solid #eee;
    padding-top: 20px;
}

/* Footer */
.main-footer {
    background-color: #1a2a40;
    /* Dark Blue */
    color: white;
    text-align: center;
    padding: 20px 0;
    font-size: 12px;
    letter-spacing: 0.5px;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .hero-content {
        flex-direction: column;
        text-align: center;
    }

    .hero-text {
        width: 100%;
        margin-bottom: 40px;
    }

    .hero-image-container {
        width: 100%;
    }

    .hero-text h2 {
        font-size: 32px;
    }
}

/* Inline Low Stock Badge override - MOVED OUTSIDE MEDIA QUERY */
.badge.low-stock-inline {
    position: static !important;
    display: inline-block;
    background-color: #FFF3E0;
    color: #E65100;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 4px;
    border: 1px solid #FFCC80;
    margin-bottom: 8px;
    text-transform: uppercase;
    box-shadow: none;
}

/* Load More Button Elegant Style */
.btn-secondary {
    display: inline-block;
    background-color: transparent;
    color: var(--primary-blue);
    border: 2px solid var(--primary-blue);
    padding: 10px 40px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    outline: none;
}

.btn-secondary:hover {
    background-color: var(--primary-blue);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 75, 141, 0.2);
}

.btn-secondary:active {
    transform: translateY(0);
}