:root {
    --bg-dark: #0f172a;
    --bg-card: rgba(30, 41, 59, 0.7);
    --bg-card-hover: rgba(51, 65, 85, 0.8);
    --border-color: rgba(255, 255, 255, 0.1);
    --border-glow: rgba(99, 102, 241, 0.4);
    
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    
    --accent-primary: #6366f1;
    --accent-secondary: #8b5cf6;
    --accent-cyan: #06b6d4;
    --accent-emerald: #10b981;
    --accent-amber: #f59e0b;
    --accent-rose: #f43f5e;

    --gradient-hero: linear-gradient(135deg, #6366f1 0%, #a855f7 50%, #ec4899 100%);
    --gradient-card: linear-gradient(180deg, rgba(30, 41, 59, 0.8) 0%, rgba(15, 23, 42, 0.9) 100%);

    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-full: 9999px;

    --shadow-glow: 0 0 25px rgba(99, 102, 241, 0.25);
    --shadow-card: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    
    --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

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

body {
    font-family: var(--font-body);
    background-color: var(--bg-dark);
    color: var(--text-primary);
    min-height: 100vh;
    background-image: 
        radial-gradient(at 0% 0%, rgba(99, 102, 241, 0.15) 0px, transparent 50%),
        radial-gradient(at 100% 0%, rgba(236, 72, 153, 0.12) 0px, transparent 50%),
        radial-gradient(at 50% 100%, rgba(6, 182, 212, 0.1) 0px, transparent 50%);
    background-attachment: fixed;
    line-height: 1.5;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Header Navbar */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 0;
    border-bottom: 1px solid var(--border-color);
    backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(15, 23, 42, 0.75);
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.brand-logo-img {
    height: 45px;
    width: auto;
    object-fit: contain;
    display: block;
    transition: transform 0.2s ease;
}

.brand-logo-img:hover {
    transform: scale(1.05);
}

.brand-name {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary);
}

.brand-name span {
    background: var(--gradient-hero);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-badges {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.live-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.85rem;
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: var(--radius-full);
    color: var(--accent-emerald);
    font-size: 0.8rem;
    font-weight: 600;
}

.pulse-dot {
    width: 8px;
    height: 8px;
    background: var(--accent-emerald);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 8px rgba(16, 185, 129, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* Hero Section */
.hero-section {
    padding: 3.5rem 0 2rem;
    text-align: center;
}

.hero-title {
    font-family: var(--font-heading);
    font-size: 2.75rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 0.75rem;
}

.hero-title span {
    background: var(--gradient-hero);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 650px;
    margin: 0 auto 2rem;
}

/* Search Box Container */
.search-wrapper {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
}

.search-form-bar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
}

.category-select-wrapper {
    flex-shrink: 0;
}

.category-dropdown {
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.18);
    color: var(--text-primary);
    padding: 0.85rem 1.15rem;
    border-radius: var(--radius-lg);
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 600;
    outline: none;
    cursor: pointer;
    backdrop-filter: blur(16px);
    box-shadow: var(--shadow-card);
    transition: all 0.3s ease;
    min-width: 210px;
}

.category-dropdown:hover {
    border-color: var(--accent-primary);
    box-shadow: var(--shadow-glow);
    background: rgba(30, 41, 59, 0.9);
}

.category-dropdown:focus {
    border-color: var(--accent-primary);
    box-shadow: var(--shadow-glow);
}

.category-dropdown option {
    background: #0f172a;
    color: #f8fafc;
    padding: 0.5rem;
}

.search-input-box {
    display: flex;
    align-items: center;
    flex: 1;
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: var(--radius-lg);
    padding: 0.5rem 1rem 0.5rem 0;
    box-shadow: var(--shadow-card);
    backdrop-filter: blur(16px);
    transition: all 0.3s ease;
}

.search-input-box:focus-within {
    border-color: var(--accent-primary);
    box-shadow: var(--shadow-glow);
}

.search-input-icon {
    padding: 0 1rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
}

.search-input {
    width: 100%;
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-primary);
    font-size: 1.1rem;
    font-family: var(--font-body);
}

.search-input::placeholder {
    color: var(--text-muted);
}

.btn-search {
    background: var(--gradient-hero);
    border: none;
    color: white;
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 600;
    padding: 0.85rem 1.75rem;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
    flex-shrink: 0;
    box-shadow: var(--shadow-card);
}

.btn-search:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.45);
}

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

/* Quick Search Suggestions */
.suggestion-pills {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1rem;
}

.pill-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    align-self: center;
}

.pill {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-secondary);
    padding: 0.35rem 0.85rem;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pill:hover {
    background: rgba(99, 102, 241, 0.15);
    border-color: rgba(99, 102, 241, 0.4);
    color: var(--text-primary);
}

/* Store & Stock Filter Bar */
.store-filter-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1.25rem;
    margin: 2rem 0;
    padding: 1rem 1.25rem;
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
}

/* Collapsible header (desktop: inline with stores, mobile: tap to toggle) */
.store-filter-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: default;
}

.store-filter-arrow {
    display: none; /* Hidden on desktop */
}

.store-count-badge {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-muted);
}

.store-filter-body {
    display: contents; /* On desktop, acts as if unwrapped — stores flow inline */
}

.filter-group {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.6rem;
}

.filter-divider {
    width: 1px;
    height: 28px;
    background: var(--border-color);
}

.filter-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-right: 0.25rem;
}

.store-toggle {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.85rem;
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s ease;
    user-select: none;
}

.store-toggle input {
    accent-color: var(--accent-primary);
    cursor: pointer;
}

.store-toggle:hover {
    border-color: rgba(255, 255, 255, 0.25);
}

.store-toggle.active {
    background: rgba(99, 102, 241, 0.15);
    border-color: var(--accent-primary);
    color: var(--text-primary);
}

.btn-store-action {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.3rem 0.75rem;
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: var(--radius-full);
    color: var(--accent-emerald);
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    font-family: var(--font-body);
}

.btn-store-action:hover {
    background: rgba(16, 185, 129, 0.22);
    border-color: var(--accent-emerald);
}

.btn-store-action--deselect {
    background: rgba(239, 68, 68, 0.08);
    border-color: rgba(239, 68, 68, 0.25);
    color: #f87171;
}

.btn-store-action--deselect:hover {
    background: rgba(239, 68, 68, 0.18);
    border-color: #f87171;
}

/* In-Stock Toggle Switch */
.stock-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.85rem;
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid rgba(16, 185, 129, 0.25);
    border-radius: var(--radius-full);
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    transition: all 0.2s ease;
    user-select: none;
}

.stock-toggle input {
    accent-color: var(--accent-emerald);
    cursor: pointer;
    width: 15px;
    height: 15px;
}

.stock-toggle:hover {
    border-color: var(--accent-emerald);
    color: var(--text-primary);
}

.stock-toggle.active {
    background: rgba(16, 185, 129, 0.2);
    border-color: var(--accent-emerald);
    color: var(--accent-emerald);
    box-shadow: 0 0 12px rgba(16, 185, 129, 0.2);
}

/* Results Controls Bar */
.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.results-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.results-count {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 700;
}

.lowest-price-tag {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.4);
    color: var(--accent-emerald);
    padding: 0.35rem 0.85rem;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    cursor: pointer;
    user-select: none;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.lowest-price-tag:hover {
    background: rgba(16, 185, 129, 0.25);
    border-color: var(--accent-emerald);
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.35);
    transform: translateY(-1px);
}

.lowest-price-tag:active {
    transform: translateY(0);
}

.tag-target-icon {
    display: inline-block;
    transition: transform 0.2s ease;
}

.lowest-price-tag:hover .tag-target-icon {
    transform: scale(1.2) rotate(12deg);
}

.results-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.sort-dropdown {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 0.45rem 1rem;
    border-radius: var(--radius-md);
    outline: none;
    font-family: var(--font-body);
    font-size: 0.9rem;
    cursor: pointer;
}

/* View Toggle Buttons */
.view-toggles {
    display: flex;
    gap: 0.25rem;
    background: var(--bg-card);
    padding: 0.25rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

.btn-view {
    background: transparent;
    border: none;
    color: var(--text-muted);
    padding: 0.35rem 0.65rem;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
}

.btn-view.active {
    background: var(--accent-primary);
    color: white;
}

/* Product Grid Layout */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.product-grid.list-view {
    grid-template-columns: 1fr;
}

/* Product Card */
.product-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    position: relative;
    backdrop-filter: blur(10px);
}

.product-card:hover {
    transform: translateY(-6px);
    border-color: var(--border-glow);
    box-shadow: var(--shadow-card), var(--shadow-glow);
}

.product-card.is-lowest-price {
    border: 1.5px solid var(--accent-emerald);
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.15);
}

.product-card.is-lowest-price:hover {
    border-color: var(--accent-emerald);
    box-shadow: 0 8px 30px rgba(16, 185, 129, 0.35);
}

.product-card.lowest-highlight {
    animation: lowestCardPulse 1.2s ease-in-out 2 alternate;
}

@keyframes lowestCardPulse {
    0% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 0 30px 10px rgba(16, 185, 129, 0.5);
        transform: scale(1.02);
    }
    100% {
        box-shadow: 0 0 15px 4px rgba(16, 185, 129, 0.3);
        transform: scale(1);
    }
}

.card-badge-best {
    position: absolute;
    top: 10px;
    left: 10px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 0.65rem;
    border-radius: var(--radius-full);
    z-index: 2;
    box-shadow: 0 4px 10px rgba(16, 185, 129, 0.4);
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.card-image-wrapper {
    width: 100%;
    height: 190px;
    background: rgba(15, 23, 42, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    overflow: hidden;
    position: relative;
}

.product-card.list-view .card-image-wrapper {
    width: 160px;
    height: 120px;
    flex-shrink: 0;
}

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

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

.card-content {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-card.list-view {
    flex-direction: row;
    align-items: center;
}

.product-card.list-view .card-content {
    padding: 1rem 1.5rem;
}

.store-chip {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0.2rem 0.6rem;
    border-radius: var(--radius-sm);
    margin-bottom: 0.5rem;
    width: fit-content;
}

.store-chip.quartzcomponents { background: rgba(230, 57, 70, 0.2); color: #ff6b6b; border: 1px solid rgba(230, 57, 70, 0.3); }
.store-chip.robocraze { background: rgba(76, 201, 240, 0.2); color: #4cc9f0; border: 1px solid rgba(76, 201, 240, 0.3); }
.store-chip.makerbazar { background: rgba(42, 157, 143, 0.2); color: #2a9d8f; border: 1px solid rgba(42, 157, 143, 0.3); }
.store-chip.electronicscomp { background: rgba(244, 162, 97, 0.2); color: #f4a261; border: 1px solid rgba(244, 162, 97, 0.3); }
.store-chip.robu { background: rgba(231, 111, 81, 0.2); color: #e76f51; border: 1px solid rgba(231, 111, 81, 0.3); }
.store-chip.flyrobo { background: rgba(255, 112, 166, 0.2); color: #ff70a6; border: 1px solid rgba(255, 112, 166, 0.3); }

.product-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-card.list-view .product-title {
    -webkit-line-clamp: 1;
    font-size: 1.05rem;
}

/* Price row: visible on both desktop and mobile, but styled differently */
.card-price-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.35rem;
}

/* Expand hint arrow: hidden on desktop, shown on mobile */
.mobile-expand-hint {
    display: none;
    font-size: 0.7rem;
    color: var(--text-muted);
    transition: transform 0.2s ease;
    margin-left: auto;
}

/* Details section: always visible on desktop, collapsible on mobile */
.card-details {
    display: block;
}

@keyframes slideDown {
    from { opacity: 0; max-height: 0; }
    to { opacity: 1; max-height: 200px; }
}

.card-footer {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.price-display {
    display: flex;
    flex-direction: column;
}

.price-amount {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text-primary);
}

.price-amount.lowest-price-text {
    color: var(--accent-emerald);
}

.product-card.out-of-stock {
    opacity: 0.72;
    border-color: rgba(255, 255, 255, 0.06);
    background: rgba(15, 23, 42, 0.6);
}

.product-card.out-of-stock:hover {
    opacity: 0.95;
}

.stock-status {
    font-size: 0.75rem;
    font-weight: 500;
}

.gst-badge {
    font-size: 0.7rem;
    font-weight: 600;
    padding: 0.12rem 0.45rem;
    border-radius: var(--radius-sm);
    display: inline-block;
    margin: 0.15rem 0 0.35rem 0;
    width: fit-content;
}

.gst-badge.gst-inclusive {
    background: rgba(16, 185, 129, 0.12);
    color: var(--accent-emerald);
    border: 1px solid rgba(16, 185, 129, 0.25);
}

.gst-badge.gst-exclusive {
    background: rgba(245, 158, 11, 0.15);
    color: var(--accent-amber);
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.stock-status.in-stock {
    color: var(--accent-emerald);
}

.stock-status.out-of-stock {
    color: var(--accent-rose);
}


.btn-buy {
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid var(--accent-primary);
    color: white;
    padding: 0.45rem 0.9rem;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.btn-buy:hover {
    background: var(--accent-primary);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.4);
}

.btn-buy.btn-buy-lowest {
    background: rgba(16, 185, 129, 0.18);
    border-color: var(--accent-emerald);
    color: white;
}

.btn-buy.btn-buy-lowest:hover {
    background: var(--accent-emerald);
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.45);
}

.btn-buy.btn-buy-out-of-stock {
    background: rgba(244, 63, 94, 0.1);
    border-color: rgba(244, 63, 94, 0.3);
    color: var(--text-secondary);
}

.btn-buy.btn-buy-out-of-stock:hover {
    background: rgba(244, 63, 94, 0.25);
    border-color: var(--accent-rose);
    color: white;
}

/* Skeleton Loading State */
.skeleton-card {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    height: 320px;
    animation: skeleton-pulse 1.5s infinite ease-in-out;
}

@keyframes skeleton-pulse {
    0% { opacity: 0.4; }
    50% { opacity: 0.8; }
    100% { opacity: 0.4; }
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px dashed var(--border-color);
}

.empty-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--text-muted);
}

.empty-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.empty-text {
    color: var(--text-secondary);
    max-width: 400px;
    margin: 0 auto;
}

/* Footer */
footer {
    text-align: center;
    padding: 2.5rem 0;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero-title { font-size: 2rem; }
    .search-form-bar { flex-direction: column; gap: 0.75rem; }
    .category-dropdown { width: 100%; min-width: 0; }
    .search-input-box { width: 100%; flex-direction: column; padding: 0.75rem; gap: 0.75rem; }
    .btn-search { width: 100%; justify-content: center; }
    .search-input-icon { display: none; }
    
    /* Store Filter Bar — collapsible on mobile */
    .store-filter-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 0;
        margin: 1rem 0;
    }
    .store-filter-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 0.75rem 1rem;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
    }
    .store-filter-arrow {
        display: inline-block;
        font-size: 0.85rem;
        color: var(--text-muted);
        transition: transform 0.25s ease;
    }
    .store-filter-bar.open .store-filter-arrow {
        transform: rotate(180deg);
    }
    .store-filter-body {
        display: none;
        padding: 0 1rem 1rem;
    }
    .store-filter-bar.open .store-filter-body {
        display: block;
        animation: slideDown 0.25s ease-out;
    }
    .filter-divider {
        display: none;
    }
    .filter-group {
        justify-content: center;
        width: 100%;
    }
    .filter-title {
        width: auto;
        text-align: left;
        margin-bottom: 0;
    }
    
    /* Results control adjustments */
    .results-header {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
    }
    .results-meta {
        flex-direction: column;
        align-items: center;
        gap: 0.5rem;
    }
    .results-controls {
        flex-direction: row;
        justify-content: space-between;
        width: 100%;
    }
    .sort-dropdown {
        flex-grow: 1;
    }
    
    /* Navbar adjust */
    .navbar .container {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }
    .nav-badges {
        width: 100%;
        justify-content: center;
        gap: 1rem;
    }

    /* ── Mobile Compact Card Layout ── */
    .product-grid {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
    .product-grid.list-view {
        grid-template-columns: 1fr;
    }

    .product-card,
    .product-card.list-view {
        flex-direction: row;
        align-items: center;
        border-radius: var(--radius-sm);
        padding: 0;
        cursor: pointer;
        position: relative;
    }
    .product-card:hover {
        transform: none;
    }

    /* Thumbnail: small square on the left */
    .card-image-wrapper,
    .product-card.list-view .card-image-wrapper {
        width: 60px;
        height: 60px;
        min-width: 60px;
        flex-shrink: 0;
        padding: 0.35rem;
        border-radius: var(--radius-sm) 0 0 var(--radius-sm);
    }

    .card-content {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        padding: 0.5rem 0.65rem;
        gap: 0.15rem;
        min-width: 0;
        flex: 1;
    }

    /* Store chip: inline, tiny */
    .card-content .store-chip {
        font-size: 0.6rem;
        padding: 0.1rem 0.4rem;
        margin-bottom: 0;
        order: 1;
    }

    /* Title: single line, truncated */
    .product-title {
        width: 100%;
        -webkit-line-clamp: 1;
        font-size: 0.82rem;
        margin-bottom: 0;
        order: 2;
    }

    /* Price row: inline with expand hint */
    .card-price-row {
        order: 3;
    }
    .card-price-row .price-amount {
        font-size: 0.95rem;
    }

    /* Show the expand arrow */
    .mobile-expand-hint {
        display: inline-block !important;
    }

    /* Hide the "Lowest Price" badge on compact rows (still visible when expanded) */
    .card-badge-best {
        position: static;
        font-size: 0.6rem;
        padding: 0.15rem 0.5rem;
        order: 0;
        box-shadow: none;
        margin-bottom: 0;
        align-self: center;
        flex-shrink: 0;
    }

    /* Details: hidden by default, slide open */
    .card-details {
        display: none;
        width: 100%;
        order: 10;
    }
    .product-card.expanded .card-details {
        display: block;
        animation: slideDown 0.2s ease-out;
    }
    .product-card.expanded .mobile-expand-hint {
        transform: rotate(180deg);
    }

    .card-details .card-footer {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 0.5rem;
        padding: 0.5rem 0 0.25rem 0;
        border-top: 1px solid rgba(255,255,255,0.06);
        margin-top: 0.35rem;
    }
    .card-details .card-actions {
        display: flex;
        gap: 0.5rem;
        width: 100%;
    }
    .card-details .btn-buy {
        flex: 1;
        justify-content: center;
        font-size: 0.8rem;
        padding: 0.4rem;
    }
    .card-details .btn-add-cart {
        font-size: 0.8rem;
        padding: 0.4rem 0.7rem;
    }
}


/* ==========================================================================
   BOM Cart Optimizer Workspace Layout
   ========================================================================== */
.bom-workspace-grid {
    display: grid;
    grid-template-columns: 360px 1fr;
    gap: 2rem;
    margin-bottom: 4rem;
    align-items: start;
}

@media (max-width: 992px) {
    .bom-workspace-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

.panel-title {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    color: var(--text-primary);
}

.panel-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.bom-textarea {
    width: 100%;
    height: 240px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1rem;
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 0.95rem;
    line-height: 1.5;
    resize: vertical;
    outline: none;
    transition: border-color 0.2s ease;
    margin-bottom: 1rem;
}

.bom-textarea:focus {
    border-color: var(--accent-primary);
}

.bom-input-actions {
    display: flex;
    gap: 0.75rem;
}

.bom-placeholder-state, .bom-loading-state {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 5rem 2rem;
    text-align: center;
    backdrop-filter: blur(10px);
}

.bom-placeholder-state h3, .bom-loading-state h3 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.bom-placeholder-state p, .bom-loading-state p {
    color: var(--text-secondary);
    max-width: 400px;
    margin: 0 auto;
}

/* Spinner */
.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top: 4px solid var(--accent-primary);
    border-radius: 50%;
    margin: 0 auto;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Plan Comparison Tabs */
.plan-tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.plan-tab {
    flex: 1;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1rem;
    color: var(--text-secondary);
    cursor: pointer;
    text-align: left;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
}

.plan-tab:hover {
    border-color: var(--border-glow);
}

.plan-tab.active {
    background: rgba(99, 102, 241, 0.1);
    border-color: var(--accent-primary);
    color: var(--text-primary);
    box-shadow: var(--shadow-glow);
}

.plan-tab-title {
    font-weight: 700;
    font-size: 0.95rem;
    margin-bottom: 0.25rem;
}

.plan-tab-sub {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text-primary);
}

.plan-tab.active .plan-tab-sub {
    color: var(--accent-cyan);
}

/* Plan Summary Metrics */
.plan-summary-card {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.9) 0%, rgba(15, 23, 42, 0.95) 100%);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    margin-bottom: 2rem;
    backdrop-filter: blur(10px);
}

.summary-metric-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 1.5rem;
    align-items: center;
}

@media (max-width: 576px) {
    .summary-metric-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}

.summary-metric {
    display: flex;
    flex-direction: column;
}

.metric-label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.25rem;
}

.metric-value {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--text-primary);
}

.summary-metric:first-child .metric-value {
    color: var(--accent-cyan);
    text-shadow: 0 0 15px rgba(6, 182, 212, 0.25);
}

/* Store Order breakdowns */
.store-order-grid {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.store-order-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    backdrop-filter: blur(10px);
}

.store-order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.store-item-count {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 600;
}

.store-order-items {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.store-order-item {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    padding: 0.5rem 0;
}

.store-order-item:not(:last-child) {
    border-bottom: 1px dashed rgba(255, 255, 255, 0.03);
}

.item-meta {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.bom-query-ref {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 0.15rem;
}

.item-link {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.4;
    transition: color 0.15s ease;
}

.item-link:hover {
    color: var(--accent-primary);
}

.item-pricing {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    flex-shrink: 0;
}

.item-final-price {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-primary);
}

.store-order-summary {
    background: rgba(15, 23, 42, 0.6);
    border-radius: var(--radius-md);
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.summary-line {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.summary-line span:last-child {
    color: var(--text-primary);
}

/* Mobile-specific adjustments for BOM Workspace */
@media (max-width: 600px) {
    .bom-workspace-grid {
        gap: 1rem;
        margin-bottom: 2rem;
    }
    
    .bom-textarea {
        height: 180px;
    }
    
    .bom-input-actions {
        flex-direction: column;
    }
    
    .bom-input-actions button {
        width: 100%;
    }
    
    .plan-tabs {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .plan-tab {
        padding: 0.75rem;
    }
    
    .plan-tab-sub {
        font-size: 1.15rem;
    }
    
    .summary-metric-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
        text-align: center;
    }
    
    .store-order-card {
        padding: 1rem;
    }
    
    .store-order-item {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }
    
    .item-pricing {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        margin-top: 0.25rem;
    }
}


/* ==========================================================================
   Cart Feature Styles
   ========================================================================== */

/* Navbar cart button */
.nav-link-pill {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: color 0.2s;
}

.nav-cart-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.85rem;
    background: rgba(6, 182, 212, 0.1);
    border: 1px solid rgba(6, 182, 212, 0.3);
    border-radius: var(--radius-full);
    color: var(--accent-cyan);
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
    position: relative;
}

.nav-cart-btn:hover {
    background: rgba(6, 182, 212, 0.2);
    border-color: var(--accent-cyan);
    box-shadow: 0 0 12px rgba(6, 182, 212, 0.25);
    color: white;
}

.nav-cart-btn.active {
    background: rgba(6, 182, 212, 0.18);
    border-color: var(--accent-cyan);
    color: white;
}

/* Cart count badge on nav icon */
.cart-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    background: var(--accent-rose);
    color: white;
    border-radius: var(--radius-full);
    font-size: 0.72rem;
    font-weight: 700;
    animation: badgePop 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes badgePop {
    0%   { transform: scale(0); }
    100% { transform: scale(1); }
}

/* Add to Cart button on product cards */
.card-actions {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    align-items: stretch;
}

.btn-add-cart {
    background: rgba(6, 182, 212, 0.12);
    border: 1px solid rgba(6, 182, 212, 0.35);
    color: var(--accent-cyan);
    padding: 0.38rem 0.7rem;
    border-radius: var(--radius-sm);
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.18s ease;
    white-space: nowrap;
    font-family: var(--font-body);
    letter-spacing: 0.2px;
}

.btn-add-cart:hover {
    background: rgba(6, 182, 212, 0.25);
    border-color: var(--accent-cyan);
    box-shadow: 0 3px 10px rgba(6, 182, 212, 0.3);
    transform: translateY(-1px);
}

.btn-add-cart.in-cart {
    background: rgba(16, 185, 129, 0.12);
    border-color: rgba(16, 185, 129, 0.35);
    color: var(--accent-emerald);
    cursor: default;
    opacity: 0.85;
}

.btn-add-cart.in-cart:hover {
    transform: none;
    box-shadow: none;
    background: rgba(16, 185, 129, 0.12);
}

/* ── Cart Page ──────────────────────────────────────────────────────────── */

/* Cart action bar */
.cart-action-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 0.5rem;
}

.cart-meta-row {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.cart-stores-tag {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-full);
}

.cart-actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    flex-wrap: wrap;
}

.cart-action-btn {
    padding: 0.55rem 1.1rem;
    border-radius: var(--radius-md);
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    font-family: var(--font-body);
}

.btn-secondary {
    background: rgba(99, 102, 241, 0.12);
    border: 1px solid rgba(99, 102, 241, 0.4);
    color: var(--accent-primary);
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: var(--font-body);
    font-size: 0.88rem;
    font-weight: 600;
}

.btn-secondary:hover {
    background: rgba(99, 102, 241, 0.22);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.btn-danger {
    background: rgba(244, 63, 94, 0.1);
    border: 1px solid rgba(244, 63, 94, 0.35);
    color: var(--accent-rose);
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.btn-danger:hover {
    background: rgba(244, 63, 94, 0.22);
    box-shadow: 0 4px 12px rgba(244, 63, 94, 0.3);
}

.btn-primary {
    background: var(--gradient-hero);
    color: white;
    border: none;
    padding: 0.65rem 1.4rem;
    border-radius: var(--radius-md);
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: var(--font-body);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
}

/* Store order card override for cart */
.cart-store-card {
    border-color: rgba(255, 255, 255, 0.08);
    transition: box-shadow 0.2s ease;
}

.cart-store-card:hover {
    box-shadow: var(--shadow-card);
}

/* Cart item list */
.cart-item-list {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-bottom: 1.25rem;
}

/* Individual cart item row */
.cart-item-row {
    display: grid;
    grid-template-columns: 60px 1fr auto;
    gap: 1rem;
    align-items: center;
    padding: 0.85rem 0;
    border-bottom: 1px dashed rgba(255, 255, 255, 0.05);
    transition: background 0.15s ease;
}

.cart-item-row:last-child {
    border-bottom: none;
}

.cart-item-row:hover {
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--radius-sm);
}

.cart-item-thumb {
    width: 60px;
    height: 60px;
    background: rgba(15, 23, 42, 0.8);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
    padding: 4px;
}

.cart-item-thumb img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 4px;
}

.cart-item-meta {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    min-width: 0;
}

.cart-item-title {
    font-size: 0.92rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
}

.cart-item-badges {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* Cart item controls (qty + price + remove) */
.cart-item-controls {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    flex-shrink: 0;
}

/* Quantity stepper */
.qty-control {
    display: flex;
    align-items: center;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.qty-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 1.1rem;
    width: 30px;
    height: 30px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
    font-family: var(--font-body);
    flex-shrink: 0;
}

.qty-btn:hover {
    background: rgba(99, 102, 241, 0.2);
    color: var(--text-primary);
}

.qty-input {
    width: 38px;
    text-align: center;
    background: transparent;
    border: none;
    border-left: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
    color: var(--text-primary);
    font-size: 0.88rem;
    font-weight: 600;
    font-family: var(--font-body);
    outline: none;
    padding: 0;
    height: 30px;
    -moz-appearance: textfield;
}

.qty-input::-webkit-inner-spin-button,
.qty-input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.cart-item-line-total {
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    min-width: 75px;
    text-align: right;
}

/* Remove item button */
.cart-item-remove {
    background: transparent;
    border: 1px solid rgba(244, 63, 94, 0.2);
    color: rgba(244, 63, 94, 0.5);
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    transition: all 0.15s ease;
    flex-shrink: 0;
    font-family: var(--font-body);
}

.cart-item-remove:hover {
    background: rgba(244, 63, 94, 0.15);
    border-color: var(--accent-rose);
    color: var(--accent-rose);
}

/* Shipping hint text */
.cart-shipping-hint {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 400;
}

/* Cart Grand Summary Card */
.cart-grand-summary {
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.08) 0%, rgba(99, 102, 241, 0.06) 100%);
    border: 1px solid rgba(6, 182, 212, 0.2);
    border-radius: var(--radius-lg);
    padding: 1.75rem 2rem;
    margin-top: 2rem;
    backdrop-filter: blur(10px);
}

.cart-summary-title {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 1.25rem;
    color: var(--text-primary);
}

.cart-disclaimer {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 1.25rem;
}

/* ── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
    .cart-item-row {
        grid-template-columns: 50px 1fr;
        grid-template-rows: auto auto;
    }
    .cart-item-controls {
        grid-column: 1 / -1;
        justify-content: flex-end;
        gap: 0.65rem;
    }
    .cart-item-line-total {
        min-width: 60px;
    }
    .cart-action-bar {
        flex-direction: column;
        align-items: stretch;
    }
    .cart-actions {
        justify-content: stretch;
    }
    .cart-action-btn {
        flex: 1;
        justify-content: center;
    }
    .cart-meta-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.4rem;
    }
    .cart-grand-summary {
        padding: 1.25rem;
    }
    .card-actions {
        flex-direction: column;
    }
}


/* ==========================================================================
   Feedback Page Styles
   ========================================================================== */
.feedback-card input[type="text"],
.feedback-card input[type="email"],
.feedback-card input[type="tel"],
.feedback-card textarea {
    border: 1px solid var(--border-color);
    background: rgba(15, 23, 42, 0.6);
    color: var(--text-primary);
    border-radius: var(--radius-sm);
    padding: 0.75rem;
    font-family: var(--font-body);
    transition: border-color 0.2s, box-shadow 0.2s;
}

.feedback-card input[type="text"]:focus,
.feedback-card input[type="email"]:focus,
.feedback-card input[type="tel"]:focus,
.feedback-card textarea:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.2);
    outline: none;
}

.type-pill-label:hover {
    border-color: var(--accent-primary);
    background: rgba(99, 102, 241, 0.05);
}

.file-upload-wrapper:hover {
    background: rgba(255, 255, 255, 0.02);
}
