/* Shop Page Styles - Vibrant Glassy Theme */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700;800&family=Open+Sans:wght@400;600&display=swap');

:root {
    --primary: #1a472a;
    --primary-light: #2d5a3a;
    --primary-dark: #0f2d1a;
    --accent: #fbbf24;
    --accent-light: #fcd34d;
    --accent-dark: #f59e0b;
    --gold: #eab308;
    --gold-light: #facc15;
    --gold-dark: #ca8a04;
    --cream: #fef9e7;
    --text: #1f2937;
    --text-light: #4b5563;
    --light-bg: linear-gradient(135deg, #fefce8 0%, #fef3c7 50%, #f0fdf4 100%);
    --white: #fff;
    --glass: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(234, 179, 8, 0.2);
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.08);
    --shadow-glow: 0 4px 30px rgba(26, 71, 42, 0.2);
    --shadow-gold: 0 4px 20px rgba(234, 179, 8, 0.25);
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Open Sans', sans-serif;
}

* { box-sizing: border-box; }

html, body {
    height: 100%;
    margin: 0;
    overflow-x: hidden;
}

body {
    background: var(--light-bg);
    background-attachment: fixed;
    font-family: var(--font-body);
    color: var(--text);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Main content wrapper - grows to push footer down */
#mainPage,
main,
.main-content {
    flex: 1 0 auto;
    display: flex;
    flex-direction: column;
}

/* Hide original topArea */
#topArea { display: none; }

/* ===================
   HEADER BAR
   =================== */
#topHeaderBar {
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    padding: 10px 24px;
    gap: 20px;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 20px rgba(45, 90, 39, 0.3);
}

.header-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}
.header-logo img {
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    background: var(--primary);
    padding: 2px;
}
.header-logo-text {
    font: 800 22px var(--font-heading);
    color: var(--white);
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.header-nav-links {
    display: flex;
    align-items: center;
    gap: 4px;
}
.header-nav-links > a,
.dropdown-toggle-link {
    font: 600 13px var(--font-heading);
    color: var(--white);
    text-decoration: none;
    padding: 8px 14px;
    border-radius: 25px;
    white-space: nowrap;
    transition: all 0.2s ease;
}
.header-nav-links > a:hover,
.dropdown-toggle-link:hover {
    background: rgba(255,255,255,0.2);
    transform: translateY(-1px);
}
.header-nav-links > a.nav-active {
    background: rgba(255,255,255,0.25);
    border-radius: 25px;
}

/* Dropdown */
.header-dropdown { position: relative; }
.dropdown-toggle-link { display: flex; align-items: center; gap: 4px; }
.dropdown-toggle-link i { font-size: 10px; }
.header-dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 12px;
    box-shadow: var(--shadow-glow);
    border: 1px solid var(--glass-border);
    min-width: 200px;
    padding: 8px 0;
    z-index: 1001;
}
.header-dropdown:hover .header-dropdown-menu { display: block; }
.header-dropdown-menu a {
    display: block;
    padding: 12px 18px;
    color: var(--text);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s ease;
}
.header-dropdown-menu a:hover {
    background: linear-gradient(90deg, var(--primary-light), transparent);
    color: var(--white);
    padding-left: 22px;
}

/* Search */
#headerSearchWrapper, #userSearchWrapper {
    display: flex;
    align-items: center;
    background: var(--white);
    border-radius: 30px;
    flex: 1;
    max-width: 400px;
    min-width: 120px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
    border: 2px solid transparent;
    transition: all 0.3s ease;
    padding: 0 16px;
}
#headerSearchWrapper:focus-within, #userSearchWrapper:focus-within {
    border-color: var(--accent);
    box-shadow: var(--shadow-gold);
}
#searchIcon, #userSearchIcon {
    color: var(--text-light);
    font-size: 16px;
    flex-shrink: 0;
}
#headerSearchWrapper:focus-within #searchIcon, #userSearchWrapper:focus-within #userSearchIcon {
    color: var(--accent);
}
#navInvSearchTxt, #userChoiceInput {
    flex: 1;
    border: none;
    padding: 12px 12px;
    font-size: 14px;
    outline: none;
    background: transparent;
    min-width: 0;
}

/* Cart Section */
.header-cart-section {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-left: auto;
}
.header-cart-link { text-decoration: none; }
.header-cart-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    padding: 6px 10px;
    cursor: pointer;
    border-radius: 12px;
    transition: all 0.2s ease;
}
.header-cart-item:hover {
    background: rgba(255,255,255,0.15);
    transform: translateY(-2px);
}
.header-cart-item i { font-size: 24px; color: var(--white); }
.header-cart-badge {
    position: absolute;
    top: -2px;
    right: 4px;
    font: 700 11px var(--font-heading);
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    color: var(--primary-dark);
    padding: 2px 7px;
    border-radius: 12px;
    min-width: 18px;
    text-align: center;
    box-shadow: var(--shadow-gold);
}
.header-cart-label {
    font-size: 10px;
    color: rgba(255,255,255,0.9);
    margin-top: 3px;
    font-weight: 600;
}

/* Test Mode Toggle */
.test-mode-toggle {
    background: rgba(255,255,255,0.2);
    border-radius: 25px;
    padding: 8px 14px !important;
    flex-direction: row !important;
    gap: 6px;
    border: 2px solid rgba(255,255,255,0.3);
    margin-right: 8px;
}
.test-mode-toggle:hover {
    background: rgba(255,255,255,0.3);
    border-color: rgba(255,255,255,0.5);
}
.test-mode-toggle i {
    font-size: 16px !important;
}
.test-mode-toggle .header-cart-label {
    margin-top: 0;
    font-size: 12px;
    font-weight: 700;
}
.test-mode-toggle.customer-mode {
    background: linear-gradient(135deg, #6366f1, #818cf8);
    border-color: #818cf8;
}
.test-mode-toggle.customer-mode:hover {
    background: linear-gradient(135deg, #4f46e5, #6366f1);
}

/* User Section */
#headerUserSection { margin-left: 16px; }
.header-user-link {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 30px;
    transition: all 0.2s ease;
}
.header-user-link:hover {
    background: rgba(255,255,255,0.2);
}
.header-user-img {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.5);
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}
.header-user-name {
    font: 600 14px var(--font-heading);
    color: var(--white);
    white-space: nowrap;
}

/* User Dropdown */
.header-user-dropdown {
    position: relative;
    margin-left: 16px;
}
.header-user-trigger {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.2s ease;
}
.header-user-trigger:hover {
    background: rgba(255,255,255,0.2);
}
.header-user-trigger i {
    color: var(--white);
    font-size: 12px;
}
.header-user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.5);
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    object-fit: cover;
}
.header-user-menu {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: var(--glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 12px;
    box-shadow: var(--shadow-glow);
    border: 1px solid var(--glass-border);
    min-width: 180px;
    padding: 8px 0;
    z-index: 1002;
}
.header-user-menu.show {
    display: block;
}
.header-user-menu a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 18px;
    color: var(--text);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s ease;
}
.header-user-menu a:hover {
    background: linear-gradient(90deg, var(--primary-light), transparent);
    color: var(--white);
    padding-left: 22px;
}
.header-user-menu a i {
    font-size: 16px;
}
.user-menu-divider {
    height: 1px;
    background: rgba(0,0,0,0.1);
    margin: 6px 0;
}
.sign-out-link:hover {
    background: linear-gradient(90deg, #dc2626, transparent) !important;
}

/* Hamburger Menu Button - Hidden on desktop */
.hamburger-btn {
    display: none;
    background: rgba(255,255,255,0.15);
    border: none;
    color: var(--white);
    font-size: 24px;
    padding: 6px 10px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}
.hamburger-btn:hover {
    background: rgba(255,255,255,0.25);
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    z-index: 1100;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.mobile-menu-overlay.open {
    display: block;
    opacity: 1;
}

/* Mobile Menu Drawer */
.mobile-menu {
    position: fixed;
    top: 0;
    left: -280px;
    width: 280px;
    height: 100vh;
    background: var(--white);
    z-index: 1200;
    transition: left 0.3s ease;
    box-shadow: 4px 0 20px rgba(0,0,0,0.15);
    overflow-y: auto;
}
.mobile-menu.open {
    left: 0;
}
.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: var(--white);
    font: 700 18px var(--font-heading);
}
.mobile-menu-close {
    background: rgba(255,255,255,0.2);
    border: none;
    color: var(--white);
    font-size: 18px;
    padding: 6px 10px;
    border-radius: 8px;
    cursor: pointer;
}
.mobile-menu-close:hover {
    background: rgba(255,255,255,0.3);
}
.mobile-menu-links {
    padding: 12px 0;
}
.mobile-menu-links a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    color: var(--text);
    text-decoration: none;
    font: 500 15px var(--font-heading);
    transition: all 0.2s ease;
}
.mobile-menu-links a:hover {
    background: rgba(26, 71, 42, 0.08);
    color: var(--primary);
}
.mobile-menu-links a i {
    font-size: 18px;
    color: var(--primary);
    width: 24px;
    text-align: center;
}
.mobile-menu-divider {
    height: 1px;
    background: #e5e7eb;
    margin: 8px 20px;
}
.mobile-menu-section {
    padding: 12px 20px 6px;
    font: 600 11px var(--font-heading);
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ===================
   CATEGORIES BAR
   =================== */
#topBar {
    display: block;
    padding: 12px 20px;
    background: var(--glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    overflow-x: auto;
    overflow-y: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    scrollbar-width: thin;
    scrollbar-color: var(--primary-light) transparent;
    min-height: 60px;
}
#topBar::-webkit-scrollbar {
    height: 6px;
}
#topBar::-webkit-scrollbar-track {
    background: transparent;
}
#topBar::-webkit-scrollbar-thumb {
    background: var(--primary-light);
    border-radius: 3px;
}
#categoriesDiv {
    display: inline-flex;
    gap: 10px;
    flex-wrap: nowrap;
    white-space: nowrap;
}
.category-pill {
    display: inline-block;
    padding: 10px 18px;
    border: 2px solid rgba(26, 71, 42, 0.2);
    border-radius: 25px;
    background: var(--white);
    font: 600 13px var(--font-heading);
    color: var(--text);
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.category-pill:hover {
    border-color: var(--accent);
    color: var(--primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-gold);
}
.category-pill.active {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-color: transparent;
    color: var(--white);
    box-shadow: 0 4px 15px rgba(26, 71, 42, 0.3);
}
.category-pill.recurring-pill {
    border-color: rgba(34, 197, 94, 0.3);
    color: #15803d;
}
.category-pill.recurring-pill:hover {
    border-color: #22c55e;
    background: rgba(34, 197, 94, 0.1);
}
.category-pill.recurring-pill.active {
    background: linear-gradient(135deg, #15803d, #22c55e);
    border-color: transparent;
    color: var(--white);
    box-shadow: 0 4px 15px rgba(34, 197, 94, 0.3);
}
.category-pill.recurring-pill i {
    margin-right: 4px;
}

/* ===================
   PRODUCT GRID
   =================== */
#invContainer {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
    padding: 24px;
}

.invItem {
    background: var(--glass);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 14px;
    display: flex;
    flex-direction: column;
    border-radius: 14px;
    border: 1px solid var(--glass-border);
    box-shadow: var(--shadow-soft);
    transition: all 0.3s ease;
}
.invItem:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-glow);
    border-color: var(--primary-light);
}

.invImageWrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 130px;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    margin-bottom: 10px;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    overflow: hidden;
    width: 100%;
    height: 200px; /* Adjust based on your design */
}

.invImage {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}
.invItem:hover .invImage {
    transform: scale(1.05);
}

.invCardBody { flex: 1; display: flex; flex-direction: column; }

.invButtonContainer {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 10px;
}
.invQtyRow { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.invQtySelect {
    width: 50px;
    padding: 6px;
    border: 2px solid #e5e7eb;
    border-radius: 6px;
    font-weight: 600;
    font-size: 13px;
    transition: border-color 0.2s ease;
}
.invQtySelect:focus {
    border-color: var(--primary-light);
    outline: none;
}

.addToOrder {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border: none;
    border-radius: 20px;
    color: var(--white);
    font: 600 12px var(--font-heading);
    padding: 8px 14px;
    cursor: pointer;
    transition: all 0.15s ease;
    box-shadow: 0 3px 10px rgba(45, 90, 39, 0.25);
}
.addToOrder:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(45, 90, 39, 0.35);
}
.addToOrder:active {
    transform: translateY(1px) scale(0.97);
    box-shadow: 0 2px 8px rgba(45, 90, 39, 0.2);
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    color: var(--primary-dark);
}
.addToOrder.btn-success {
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    color: var(--primary-dark);
    box-shadow: 0 4px 15px rgba(251, 191, 36, 0.4);
}
.addToOrder.disabled {
    background: #d1d5db;
    cursor: not-allowed;
    box-shadow: none;
}

.invRecurringIcon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--white);
    border: 2px solid var(--gold);
    border-radius: 50%;
    color: var(--gold-dark);
    width: 32px;
    height: 32px;
    padding: 0;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
}
.invRecurringIcon:hover {
    background: var(--gold);
    color: var(--white);
    transform: scale(1.1);
}
.invRecurringIcon.text-success {
    background: var(--gold);
    color: var(--white);
    border-color: var(--gold);
}

.invPriceUnit { margin-bottom: 6px; }
.price-dollar {
    font: 700 22px var(--font-heading);
    color: var(--primary);
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.price-cents {
    font: 700 14px var(--font-heading);
    color: var(--primary);
    vertical-align: top;
}
.price-unit {
    font-size: 12px;
    color: var(--text-light);
    margin-left: 3px;
}

.invTitleDiv { margin-bottom: 4px; }
.invTitle {
    font: 600 13px var(--font-body);
    color: var(--text);
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.3;
}

.invPopularityDiv { margin-bottom: 0; }
.invStars { display: flex; gap: 2px; }
.invStars .bi-star-fill, .invStars .bi-star-half { color: var(--gold); font-size: 12px; }
.invStars .bi-star { color: #d1d5db; font-size: 12px; }

.invCategory, .invDescription, .invPopularity { display: none; }


/* Show overlay when item is out of stock */
.invItem.out-of-stock  {
    pointer-events: none;
    opacity: 1;
    visibility: visible;
}
.addToOrder.out-of-stock {
    background: red;
}
.invRecurringIcon.out-of-stock {
    display: none;
}
/* Disable interaction for out of stock items */
.invItem.out-of-stock .addToOrder,
.invItem.out-of-stock .invRecurringIcon {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
}

/* ===================
   FOOTER
   =================== */
.site-footer {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, var(--primary-light) 100%);
    color: var(--white);
    margin-top: auto;
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
}
.site-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--accent), var(--gold-light), var(--accent-dark), var(--accent));
}
.footer-main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 50px 24px 40px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 40px;
}
.footer-section h4 {
    font: 700 15px var(--font-heading);
    text-transform: uppercase;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--gold);
    letter-spacing: 1px;
}
.footer-section p, .footer-section a {
    font-size: 14px;
    color: rgba(255,255,255,0.85);
    line-height: 1.7;
}
.footer-section a {
    display: block;
    text-decoration: none;
    margin-bottom: 10px;
    transition: all 0.2s ease;
}
.footer-section a:hover {
    color: var(--gold-light);
    padding-left: 5px;
}
.footer-social { display: flex; gap: 12px; margin-top: 16px; }
.footer-social a {
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: all 0.2s ease;
}
.footer-social a:hover {
    background: linear-gradient(135deg, var(--gold), var(--accent));
    transform: translateY(-3px);
}
.footer-bottom {
    background: rgba(0,0,0,0.25);
    padding: 20px;
    text-align: center;
    font-size: 13px;
    color: rgba(255,255,255,0.75);
}

/* ===================
   MODAL
   =================== */
.modal-content {
    border-radius: 16px;
    border: none;
    box-shadow: 0 25px 50px rgba(0,0,0,0.25);
    overflow: hidden;
}
.modal-header {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: var(--white);
    border-bottom: none;
    padding: 18px 24px;
}
.modal-header .btn-close { filter: invert(1); }
.modal-body {
    padding: 24px;
}
.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid #e5e7eb;
}
.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border: none;
    border-radius: 25px;
    padding: 10px 24px;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(45, 90, 39, 0.25);
    transition: all 0.2s ease;
}
.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(45, 90, 39, 0.35);
}
.btn-secondary {
    border-radius: 25px;
    padding: 10px 24px;
}
.btn-danger {
    border-radius: 25px;
    padding: 10px 24px;
    background: linear-gradient(135deg, #ef4444, #f87171);
    border: none;
}

/* ===================
   RESPONSIVE
   =================== */
@media (max-width: 992px) {
    #invContainer {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 16px;
        padding: 16px;
    }
    #headerSearchWrapper { max-width: 300px; }
    .header-nav-links > a, .dropdown-toggle-link { padding: 6px 10px; font-size: 12px; }
}

@media (max-width: 768px) {
    /* Mobile header layout */
    #topHeaderBar {
        flex-wrap: wrap;
        padding: 10px 12px;
        gap: 10px;
    }

    /* Show hamburger, hide desktop nav */
    .hamburger-btn {
        display: flex;
        order: 2;
    }
    .header-nav-links {
        display: none;
    }

    .header-logo {
        order: 1;
    }
    .header-logo img {
        width: 40px;
        height: 40px;
    }
    .header-cart-section {
        order: 3;
        margin-left: auto;
        gap: 8px;
    }
    #headerUserSection {
        order: 4;
        margin-left: 0;
    }

    /* Second row: Search (full width) */
    #headerSearchWrapper {
        order: 5;
        width: 100%;
        max-width: none;
        flex: 1 1 100%;
    }

    .header-cart-label { display: none; }
    .header-user-name { display: none; }

    /* Test mode toggle should keep label visible */
    .test-mode-toggle {
        padding: 6px 12px !important;
        margin-right: 6px;
    }
    .test-mode-toggle .header-cart-label {
        display: block;
        font-size: 11px;
    }
    .test-mode-toggle i {
        font-size: 14px !important;
    }

    #invContainer {
        gap: 12px;
        padding: 12px;
    }
}

@media (max-width: 576px) {
    #invContainer {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        padding: 10px;
    }
    .invItem {
        padding: 14px;
        min-height: 380px;
        border-radius: 12px;
    }
    .header-logo-text { display: none; }
    .header-logo img {
        width: 38px;
        height: 38px;
    }
    #topHeaderBar {
        padding: 8px 10px;
        gap: 8px;
    }
    .header-nav-links > a, .dropdown-toggle-link {
        padding: 5px 10px;
        font-size: 11px;
    }
    #headerSearchWrapper {
        margin-top: 4px;
    }
    #navInvSearchTxt {
        padding: 10px 12px;
        font-size: 13px;
    }
    .header-cart-section {
        gap: 6px;
    }
    .header-cart-item {
        padding: 4px 6px;
    }
    .header-cart-item i { font-size: 18px; }
    .header-cart-badge {
        font-size: 9px;
        padding: 1px 5px;
        min-width: 14px;
        top: -4px;
        right: 0;
    }
    .header-cart-label {
        display: none;
    }
    /* Test mode toggle on mobile */
    .test-mode-toggle {
        padding: 6px 10px !important;
        margin-right: 4px;
        border-width: 1px;
    }
    .test-mode-toggle .header-cart-label {
        display: block;
        font-size: 10px;
    }
    .test-mode-toggle i {
        font-size: 14px !important;
    }
    .header-user-img {
        width: 30px;
        height: 30px;
    }
    .invImageWrapper { height: 140px; }
    .addToOrder { padding: 8px 14px; font-size: 12px; }
}

@media (max-width: 380px) {
    #invContainer { grid-template-columns: 1fr; }
}

/* ===================
   SETTINGS PAGE
   =================== */
#settingsPage {
    min-height: calc(100vh - 60px);
    background: linear-gradient(135deg, #f8faff 0%, #f0f4f8 100%);
    padding: 40px 20px;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

#settingsCard {
    width: 100%;
    max-width: 600px;
    background: white;
    border-radius: 24px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.settings-header {
    text-align: center;
    padding: 32px 24px 24px;
    border-bottom: 1px solid #f0f0f0;
}

.settings-header h2 {
    font-size: 28px;
    font-weight: 700;
    color: #1a472a;
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.settings-header h2 i {
    color: #fbbf24;
}

.settings-header p {
    color: #6b7280;
    margin: 0;
    font-size: 14px;
}

.settings-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: #f3f4f6;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.settings-close:hover {
    background: #e5e7eb;
}

.settings-close i {
    font-size: 18px;
    color: #6b7280;
}

.settings-progress {
    padding: 16px 24px;
    background: #fafafa;
}

.settings-progress-label {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    font-size: 13px;
    color: #6b7280;
}

.settings-progress-label span:last-child {
    background: #fbbf24;
    color: white;
    padding: 2px 10px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 12px;
}

.settings-progress-bar {
    height: 6px;
    background: #e5e7eb;
    border-radius: 3px;
    overflow: hidden;
}

.settings-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #fbbf24, #f59e0b);
    border-radius: 3px;
    transition: width 0.3s ease;
}

.settings-body {
    padding: 24px;
}

.settings-row {
    display: flex;
    gap: 16px;
    margin-bottom: 20px;
}

.settings-row.single {
    flex-direction: column;
}

.input-wrapper {
    flex: 1;
    position: relative;
}

.input-wrapper label {
    position: absolute;
    top: -8px;
    left: 12px;
    background: white;
    padding: 0 6px;
    font-size: 12px;
    color: #6b7280;
    font-weight: 500;
}

.input-wrapper .input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #d4af37;
    font-size: 16px;
}

.input-wrapper input,
.input-wrapper select {
    width: 100%;
    padding: 14px 14px 14px 42px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 14px;
    transition: all 0.2s;
    background: white;
}

.input-wrapper input:focus,
.input-wrapper select:focus {
    outline: none;
    border-color: #1a472a;
    box-shadow: 0 0 0 4px rgba(26, 71, 42, 0.1);
}

.input-wrapper input::placeholder {
    color: #9ca3af;
}

.section-title {
    font-size: 14px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.section-title .add-btn {
    background: #22c55e;
    color: white;
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.section-title .add-btn:hover {
    background: #16a34a;
}

.zelle-row,
.email-row {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
    align-items: center;
}

.zelle-row input,
.email-row input {
    flex: 1;
    padding: 12px 14px;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 14px;
    transition: all 0.2s;
}

.zelle-row input:focus,
.email-row input:focus {
    outline: none;
    border-color: #1a472a;
}

.delete-btn {
    background: none;
    border: none;
    color: #ef4444;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: all 0.2s;
}

.delete-btn:hover {
    background: #fef2f2;
}

.settings-footer {
    padding: 20px 24px 28px;
}

.save-btn {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #1a472a, #2d5a3a);
    color: white;
    border: none;
    border-radius: 14px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 4px 15px rgba(26, 71, 42, 0.3);
}

.save-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(26, 71, 42, 0.4);
}

@media (max-width: 500px) {
    .settings-row {
        flex-direction: column;
    }
    #settingsCard {
        border-radius: 16px;
        margin: 10px;
    }
    .zelle-row,
    .email-row {
        flex-wrap: wrap;
    }
    .zelle-row input,
    .email-row input {
        min-width: 0;
        flex: 1 1 45%;
    }
    .zelle-row input:first-child {
        flex: 1 1 100%;
        margin-bottom: 8px;
    }
}

/* ===================
   TOAST NOTIFICATIONS
   =================== */
#toastDiv {
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.15);
    border: none;
    min-width: 300px;
}

#toastDiv .toast-header {
    background: linear-gradient(135deg, #1a472a, #2d5a3a);
    color: white;
    border-radius: 12px 12px 0 0;
    padding: 12px 16px;
}

#toastDiv .toast-header .me-auto {
    font-size: 16px;
}

#toastDiv .toast-header .btn-close {
    filter: brightness(0) invert(1);
}

#toastDiv .toast-body {
    padding: 16px;
    font-size: 15px;
    color: #333;
}

/* ===================
   MAIN PAGE LAYOUT (from nav)
   =================== */
@media screen and (max-width: 500px) {
    .hide-on-small {
        display: none;
    }
}

/* ===================
   USERS PAGE - ZELLE SECTION
   =================== */
.userZelleHolder {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 10px;
    background: white;
    padding: 10px 12px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.userZelleHolder input {
    flex: 1;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    padding: 8px 12px;
    font-size: 14px;
}

.userZelleHolder input:focus {
    border-color: #1a472a;
    outline: none;
    box-shadow: 0 0 0 2px rgba(26, 71, 42, 0.1);
}

.zelle-delete-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: #fee2e2;
    color: #dc2626;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.zelle-delete-btn:hover {
    background: #ef4444;
    color: white;
}

/* ===================
   STYLED MODAL DIALOGS
   =================== */
.styled-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.2s ease;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.styled-modal-overlay.show {
    opacity: 1;
}

.styled-modal {
    background: white;
    border-radius: 16px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
    min-width: 320px;
    max-width: 420px;
    width: 90%;
    transform: scale(0.9) translateY(-20px);
    transition: transform 0.2s ease;
    overflow: hidden;
}

.styled-modal-overlay.show .styled-modal {
    transform: scale(1) translateY(0);
}

.styled-modal-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px 24px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    font: 600 18px var(--font-heading);
}

.styled-modal-header i {
    font-size: 24px;
}

/* Modal type variations */
.styled-modal-info .styled-modal-header {
    background: linear-gradient(135deg, #0ea5e9, #38bdf8);
}

.styled-modal-warning .styled-modal-header {
    background: linear-gradient(135deg, #f59e0b, #fbbf24);
}

.styled-modal-error .styled-modal-header {
    background: linear-gradient(135deg, #ef4444, #f87171);
}

.styled-modal-success .styled-modal-header {
    background: linear-gradient(135deg, #22c55e, #4ade80);
}

.styled-modal-body {
    padding: 24px;
    font-size: 15px;
    color: var(--text);
    line-height: 1.6;
}

.styled-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 24px;
    background: #f9fafb;
    border-top: 1px solid #e5e7eb;
}

.styled-modal-btn {
    padding: 10px 24px;
    border-radius: 25px;
    font: 600 14px var(--font-heading);
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
}

.styled-modal-btn-cancel {
    background: #e5e7eb;
    color: var(--text);
}

.styled-modal-btn-cancel:hover {
    background: #d1d5db;
}

.styled-modal-btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    box-shadow: 0 4px 15px rgba(26, 71, 42, 0.25);
}

.styled-modal-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(26, 71, 42, 0.35);
}

.styled-modal-btn.btn-danger {
    background: linear-gradient(135deg, #ef4444, #f87171);
    color: white;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.25);
}

.styled-modal-btn.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.35);
}
.users-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    margin-top: 10px;
    padding: 16px 20px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    flex-wrap: wrap;
    gap: 12px;
    }
    .users-header h1 {

        color: #1a472a;
        margin: 0;
        display: flex;
        align-items: center;
        gap: 10px;
        font: 600 13px var(--font-heading);
    }

    .users-header h1 i {
        color: #eab308;
    }
    #userChoiceInput {
        width: 100%;
        border: none;
        font-size: 14px;
        padding: 12px 12px;
    }
@media (max-width: 400px) {
    .styled-modal {
        min-width: 280px;
    }
    .styled-modal-header {
        padding: 14px 18px;
        font-size: 16px;
    }
    .styled-modal-body {
        padding: 18px;
        font-size: 14px;
    }
    .styled-modal-footer {
        padding: 12px 18px;
        flex-direction: column;
    }
    .styled-modal-btn {
        width: 100%;
        text-align: center;
    }
}
