/* =========================================
   CH Restaurant - KFC Style Theme
   ========================================= */

:root {
    /* Light Theme (Default: Premium Emerald Gold) */
    --primary-color: #00695c; /* Emerald Green */
    --primary-rgb: 0, 105, 92; /* For rgba() usage */
    --primary-hover: #004d40;
    --accent-color: #D4AF37; /* Gold */
    --bg-color: #fdfdfd;
    --card-bg: #ffffff;
    --text-main: #111111;
    --text-muted: #666666;
    --border-color: #e8e8e8;
    --header-bg: #ffffff;
    --drawer-bg: #ffffff;
    --overlay-bg: rgba(0, 0, 0, 0.5);
    --shadow-sm: 0 4px 12px rgba(0,0,0,0.04);
    --shadow-md: 0 8px 24px rgba(0,0,0,0.08);
    --shadow-up: 0 -4px 16px rgba(0,0,0,0.08);
}

.night-theme {
    /* Dark Theme: Deep Midnight & Gold */
    --primary-color: #00897b;
    --primary-hover: #00695c;
    --accent-color: #D4AF37;
    --bg-color: #0a0c10;
    --card-bg: #151921;
    --text-main: #f0f0f0;
    --text-muted: #94a3b8;
    --border-color: #242933;
    --header-bg: #0f131a;
    --drawer-bg: #0f131a;
    --overlay-bg: rgba(0, 0, 0, 0.8);
    --shadow-sm: 0 4px 12px rgba(0,0,0,0.4);
    --shadow-md: 0 8px 24px rgba(0,0,0,0.5);
    --shadow-up: 0 -4px 16px rgba(0,0,0,0.5);
}

/* Bakery Brand Overrides - Premium Espresso & Gold */
.brand-bakery {
    --primary-color: #8d6e63; /* Cocoa brown for light mode */
    --accent-color: #5d4037;
}

.brand-bakery.night-theme {
    --primary-color: #c4a45a; /* Metallic Gold */
    --primary-hover: #b39349;
    --accent-color: #f1dec9;
    --bg-color: #1a120f; /* Deep Espresso */
    --card-bg: #281b17; /* Dark Chocolate */
    --text-main: #f1f1f1;
    --text-muted: #a3948b;
    --border-color: #3d2b24;
    --header-bg: #150f0d;
    --drawer-bg: #150f0d;
    --overlay-bg: rgba(0, 0, 0, 0.85);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    -webkit-user-select: none;
}

input, textarea {
    user-select: text;
    -webkit-user-select: text;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    transition: background-color 0.3s, color 0.3s;
    overflow-x: hidden;
}

/* Utilities */
.w-100 { width: 100%; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.ms-auto { margin-left: auto; }
.text-center { text-align: center; }
.text-danger { color: var(--primary-color); }
.text-success { color: #28a745; }
.text-muted { color: var(--text-muted); }
.font-bold { font-weight: 700; }
.letter-spacing-2 { letter-spacing: 2px; }

/* Buttons */
.btn {
    padding: 12px 20px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}
.btn-primary:active {
    background-color: var(--primary-hover);
    transform: scale(0.98);
}

.btn-outline {
    background-color: transparent;
    border: 1.5px solid var(--primary-color);
    color: var(--primary-color);
}
.btn-outline:active {
    background-color: var(--primary-color);
    color: white;
}

.btn-text {
    background: transparent;
    color: var(--text-main);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.85rem;
    border-radius: 4px;
}

/* AAA Animations */
.btn-animated {
    position: relative;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}
.btn-animated:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}
.btn-animated:active:not(:disabled) {
    transform: scale(0.96);
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}
.btn-animated::after {
    content: '';
    position: absolute;
    top: 50%; left: 50%;
    width: 0; height: 0;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.4s ease, height 0.4s ease;
    pointer-events: none;
}
.btn-animated:focus:not(:disabled)::after {
    width: 300px;
    height: 300px;
    opacity: 0;
}

@keyframes slideUpFade {
    0% { opacity: 0; transform: translateY(25px); }
    100% { opacity: 1; transform: translateY(0); }
}

/* Loader Styles */
.loader-ring {
    position: absolute;
    border-radius: 50%;
    border: 3px solid transparent;
    border-top-color: var(--primary-color);
    animation: spin 2s linear infinite;
}
.ring-1 {
    width: 180px; height: 180px;
    border-top-color: var(--primary-color);
    animation-duration: 2s;
}
.ring-2 {
    width: 150px; height: 150px;
    border-top-color: var(--accent-color);
    animation-duration: 1.5s;
    animation-direction: reverse;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
@keyframes pulse {
    0% { opacity: 0.6; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.05); }
    100% { opacity: 0.6; transform: scale(1); }
}

/* Horizontal Category Pills */
.cat-pill {
    padding: 8px 16px;
    background: var(--bg-color);
    border: 1.5px solid var(--border-color);
    border-radius: 20px;
    white-space: nowrap;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
}
.cat-pill.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    box-shadow: 0 4px 8px rgba(0, 105, 92, 0.2);
}
.cat-pill img {
    width: 18px;
    height: 18px;
    object-fit: contain;
}

/* Forms */
.form-group {
    margin-bottom: 15px;
}
.form-group label {
    display: block;
    margin-bottom: 5px;
    font-size: 0.85rem;
    color: var(--text-muted);
}
.form-control {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background-color: var(--card-bg);
    color: var(--text-main);
    font-size: 1rem;
    transition: border-color 0.2s;
}
.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* Screens / Views Management */
.screen {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: var(--bg-color);
    display: none;
    z-index: 10;
}
.screen.active {
    display: flex;
    flex-direction: column;
}

.view {
    display: none;
    flex: 1;
    overflow-y: auto;
    padding-bottom: 80px; /* space for cart */
    animation: slideUpFade 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.view.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Splash Screen */
#splash-screen {
    padding: 30px 20px;
    text-align: center;
    justify-content: center;
    z-index: 1000;
}
.splash-header h2 {
    color: var(--primary-color);
    font-size: 2.5rem;
    font-weight: 800;
}
.splash-header p {
    color: var(--text-muted);
    margin-bottom: 30px;
}
.splash-logo {
    width: 200px;
    height: auto;
    object-fit: contain;
    margin-bottom: 20px;
}
.brand-cards {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 40px;
}
.brand-card {
    background-color: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 16px;
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    cursor: pointer;
    transition: transform 0.2s, border-color 0.2s;
    box-shadow: var(--shadow-sm);
}
.brand-card:active {
    transform: scale(0.96);
}
.brand-card:hover {
    border-color: var(--primary-color);
}
.brand-icon {
    width: 60px; height: 60px;
    background-color: rgba(0, 105, 92, 0.1);
    color: var(--primary-color);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.8rem;
}
.brand-card h3 {
    font-size: 1.3rem; 
    font-weight: 700;
    margin: 0;
}
.splash-footer {
    display: flex; flex-direction: column; gap: 15px;
}
.splash-profile-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 20px;
    margin-bottom: 20px;
    animation: slideUpFade 0.6s ease;
}
.night-theme .splash-profile-card {
    background: rgba(255, 255, 255, 0.03);
}
.splash-profile-card h4 { font-size: 1.1rem; margin-bottom: 5px; color: var(--text-main); }
.splash-profile-card p { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 15px; }

/* Badge Improvements */
#cart-badge-bakery {
    position: absolute;
    top: -8px;
    right: -8px;
    background: #c4a141; /* Gold for bakery */
    color: white;
    font-size: 0.65rem;
    font-weight: 800;
    height: 18px;
    min-width: 18px;
    padding: 0 4px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid var(--bg-color);
}
.badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--primary-color);
    color: white;
    font-size: 0.65rem;
    font-weight: 800;
    height: 18px;
    min-width: 18px;
    padding: 0 4px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid var(--bg-color);
}

/* Main App Header */
.app-header {
    background-color: var(--header-bg);
    padding: 12px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow-sm);
    z-index: 50;
    position: sticky;
    top: 0;
    min-height: 60px;
}
.header-left {
    display: flex; align-items: center; gap: 15px;
}
.menu-btn {
    background: transparent; border: none;
    font-size: 1.4rem; color: var(--text-main);
    cursor: pointer; padding: 5px;
}
.deliver-to {
    display: flex; flex-direction: column; cursor: pointer;
}
.deliver-to .label {
    font-size: 0.75rem; font-weight: 600; color: var(--text-main);
}
.deliver-to .address-text {
    font-size: 0.85rem; color: var(--text-muted);
    max-width: 150px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.header-logo {
    width: 65px;
    height: 65px;
    object-fit: contain;
}
.logo-text {
    color: var(--primary-color); font-weight: 800; font-size: 1.5rem;
    font-style: italic; letter-spacing: -1px;
}

/* Order Type Toggle (Delivery/Pickup) */
.order-type-toggle {
    display: flex;
    background-color: var(--header-bg);
    padding: 10px 20px;
    gap: 10px;
    border-bottom: 1px solid var(--border-color);
}
.toggle-btn {
    flex: 1;
    padding: 10px;
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-muted);
    font-weight: 600; font-size: 0.95rem;
    display: flex; align-items: center; justify-content: center; gap: 8px;
    cursor: pointer;
    transition: all 0.2s;
}
.toggle-btn.active {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background-color: rgba(0, 105, 92, 0.05);
}

/* Content Area */
.content-area {
    flex: 1;
    overflow-y: auto;
    background-color: var(--bg-color);
}
.section {
    padding: 20px;
    border-bottom: 8px solid var(--border-color);
}
.section-header {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 15px;
}
.section-title {
    font-size: 1.2rem; font-weight: 700;
    position: relative;
    display: inline-block;
    margin-bottom: 15px;
}
.section-title::after {
    content: ''; position: absolute; left: 0; bottom: -5px;
    height: 3px; width: 30px; background-color: var(--primary-color);
}
.view-all {
    color: var(--text-main); font-size: 0.8rem; font-weight: 600; text-decoration: none;
}

/* Slider */
.slider-container {
    width: 100%; overflow: hidden; position: relative; border-radius: 12px;
}
.slider-wrap {
    display: flex; transition: transform 0.5s ease;
}
.slide {
    min-width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}
.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px;
    display: block;
}
.slider-dots {
    position: absolute; bottom: 10px; left: 0; right: 0;
    display: flex; justify-content: center; gap: 6px;
}
.dot {
    width: 6px; height: 6px; border-radius: 50%; background: rgba(255,255,255,0.5);
}
.dot.active { background: white; }

/* Category Grid */
.explore-grid {
    display: grid; grid-template-columns: 1fr 1fr; gap: 15px;
}
.cat-card {
    background-color: var(--card-bg);
    border: 1px dashed var(--border-color);
    border-radius: 12px;
    padding: 15px; text-align: center;
    cursor: pointer;
    height: 120px; display: flex; flex-direction: column; align-items: center; justify-content: center;
}
.cat-card img { width: 60px; height: 60px; object-fit: contain; margin-bottom: 10px; }
.cat-card h4 { font-size: 0.85rem; font-weight: 600; margin: 0; line-height: 1.2;}

/* Horizontal Scroll Items */
.horizontal-scroll {
    display: flex; overflow-x: auto; gap: 15px; padding-bottom: 10px;
    scroll-snap-type: x mandatory;
}
.horizontal-scroll::-webkit-scrollbar { display: none; }
.item-card-v {
    min-width: 150px; background-color: var(--card-bg);
    border: 1px dashed var(--border-color); border-radius: 12px;
    padding: 15px; text-align: center; scroll-snap-align: start;
    position: relative;
}
.ribbon {
    position: absolute; top: 10px; center: 0; display:flex; justify-content: center; width: 100%;
}
.ribbon-blocks { display: flex; gap: 2px; }
.ribbon-block { width: 10px; height: 10px; background-color: var(--accent-color);}
.item-card-v h4 { font-size: 0.95rem; font-weight: 700; margin-top: 25px; margin-bottom: 5px; min-height: 42px;}
.item-price-tag {
    background-color: var(--accent-color); color: #000;
    padding: 4px 10px; font-weight: 700; font-size: 0.85rem;
    display: inline-block; transform: rotate(-3deg); margin-top: 10px;
}
.item-img-placeholder {
    height: 90px; width: 50px; background-color: #e0e0e0; margin: 10px auto; opacity: 0.5; border-radius: 4px;
}
.menu-item-img {
    width: 100%;
    height: 100px;
    object-fit: contain;
    margin: 10px auto;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.1));
    transition: transform 0.3s ease;
    display: block;
}
.item-card-v:hover .menu-item-img {
    transform: scale(1.08);
}

/* List Deals */
.deals-list { display: flex; flex-direction: column; gap: 15px; }
.deal-card {
    display: flex; background: var(--card-bg); border: 1px dashed var(--border-color); border-radius: 12px;
    overflow: hidden; padding: 15px; align-items: center; gap: 15px;
}
.deal-img { 
    width: 100px; 
    height: 100px; 
    object-fit: contain; 
    border-radius: 8px; 
    background: radial-gradient(circle, rgba(0,105,92,0.06) 0%, rgba(255,255,255,0) 70%);
}
.deal-info { flex: 1; }
.deal-info h4 { font-size: 1rem; font-weight: 700; margin-bottom: 5px;}
.deal-info p { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 10px; }
.deal-bottom { display: flex; justify-content: space-between; align-items: center; }
.deal-bottom .price { font-weight: 700; font-size: 1rem;}
.btn-view { border: 1px solid var(--primary-color); color: var(--primary-color); background: transparent; padding: 4px 15px; border-radius: 4px; font-weight: 600; font-size:0.8rem;}

/* List Items (Category View) */
.category-items-list { padding: 15px; display: flex; flex-direction: column; gap: 15px; }

/* Back Header */
.back-header {
    display: flex; align-items: center; gap: 15px;
    padding: 12px 20px;
    min-height: 56px;
    background: var(--header-bg); border-bottom: 1px solid var(--border-color);
    position: sticky; top: 0; z-index: 10;
}
.back-btn { background: transparent; border: none; font-size: 1.2rem; cursor: pointer; color: var(--text-main); width: 36px; height: 36px; display:flex; align-items:center; justify-content:center; border-radius:50%; transition: background 0.2s;}
.back-btn:active { background: rgba(0,0,0,0.06); }
.back-header h3 { font-size: 1.1rem; font-weight: 700; }

/* Floating Cart */
.floating-cart {
    position: fixed; bottom: 20px; left: 20px; right: 20px;
    background-color: var(--primary-color); color: white;
    border-radius: 30px; padding: 12px 25px;
    display: flex; align-items: center; justify-content: space-between;
    box-shadow: var(--shadow-up); z-index: 100; cursor: pointer;
    transform: translateY(150%); transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.floating-cart.visible { transform: translateY(0); }
.cart-icon-wrapper { position: relative; font-size: 1.5rem; }
.cart-badge {
    position: absolute; top: -5px; right: -10px;
    background-color: white; color: var(--primary-color);
    font-size: 0.7rem; font-weight: 700; height: 20px; min-width: 20px; padding: 0 6px;
    border-radius: 10px; display: flex; align-items: center; justify-content: center;
}
.cart-info { display: flex; align-items: center; gap: 15px; }
.cart-total { font-weight: 700; font-size: 1.1rem; }
.cart-view-text { font-size: 0.85rem; font-weight: 600;}

/* Side Drawer */
.drawer-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: var(--overlay-bg); backdrop-filter: blur(2px);
    z-index: 200; display: none; opacity: 0; transition: opacity 0.3s;
}
.drawer-overlay.active { display: block; opacity: 1; }
.side-drawer {
    position: fixed; top: 0; left: -300px; bottom: 0; width: 280px;
    background: var(--drawer-bg); z-index: 201; box-shadow: var(--shadow-md);
    transition: transform 0.3s ease; display: flex; flex-direction: column;
}
.side-drawer.active { transform: translateX(300px); }
.drawer-header {
    padding: 30px 20px 20px; border-bottom: 1px solid var(--border-color);
    display: flex; justify-content: space-between; align-items: flex-start;
}
.user-profile { display: flex; gap: 15px; align-items: center; }
.avatar {
    width: 50px; height: 50px; border-radius: 50%; border: 2px solid var(--text-main);
    display: flex; align-items: center; justify-content: center; font-size: 1.5rem; color: var(--text-main);
}
.user-info h4 { font-size: 1.1rem; margin-bottom: 2px;}
.user-info p { font-size: 0.85rem; color: var(--text-muted); cursor: pointer;}
.drawer-menu { padding: 20px 0; overflow-y: auto; }
.drawer-item {
    display: flex; align-items: center; gap: 15px; padding: 15px 25px;
    color: var(--text-main); text-decoration: none; font-weight: 600; font-size: 1rem;
}
.drawer-item i { width: 20px; text-align: center; color: var(--text-muted); font-size: 1.2rem;}
.drawer-item:active { background-color: rgba(0,0,0,0.05); }

/* Theme Toggle Pill */
.theme-toggle-btn {
    background: none; border: none; cursor: pointer; padding: 0;
}
.theme-pill {
    display: flex; background: var(--border-color); border-radius: 20px; overflow: hidden;
    padding: 2px;
}
.theme-opt {
    padding: 4px 10px; font-size: 0.75rem; font-weight: 600; color: var(--text-muted); border-radius: 16px;
}
.theme-opt.active { background: var(--primary-color); color: white; }

/* Modals (Center & Bottom Sheets) */
.modal-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: var(--overlay-bg); backdrop-filter: blur(2px);
    z-index: 2000; display: none; opacity: 0; transition: opacity 0.3s;
}
.modal-overlay.active { display: block; opacity: 1; }

.bottom-sheet {
    position: fixed; bottom: -100%; left: 0; right: 0; max-height: 90vh;
    background: var(--card-bg); border-radius: 24px 24px 0 0;
    z-index: 2001; padding: 25px 20px; transition: bottom 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow-y: auto; display: flex; flex-direction: column;
}
.bottom-sheet.active { bottom: 0; }
.close-sheet {
    position: absolute; top: 15px; right: 20px; background: rgba(0,0,0,0.05); color: var(--text-main);
    border: none; width: 36px; height: 36px; border-radius: 50%; cursor: pointer; display: flex; align-items:center; justify-content:center;
    z-index: 2010; font-size: 1.2rem; padding: 0; margin: 0; transition: background 0.2s;
}
.close-sheet:hover {
    background: rgba(0,0,0,0.1);
}

.center-modal {
    position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%) scale(0.9);
    width: 90%; max-width: 400px; background: var(--card-bg); border-radius: 16px;
    z-index: 2001; padding: 25px; display: none; opacity: 0; transition: all 0.3s; box-shadow: var(--shadow-md);
}
.center-modal.active { display: block; opacity: 1; transform: translate(-50%, -50%) scale(1); }
.close-modal {
    position: absolute; top: 15px; right: 15px; background: rgba(0,0,0,0.05); border: none; width: 36px; height: 36px; border-radius: 50%; cursor: pointer; display: flex; align-items:center; justify-content:center;
    z-index: 2010; font-size: 1.2rem; color: var(--text-muted); transition: background 0.2s;
}
.close-modal:hover {
    background: rgba(0,0,0,0.1);
}

/* Auth Modal Specifics */
.auth-tabs { display: flex; margin-bottom: 20px; border-bottom: 1px solid var(--border-color); }
.auth-tab {
    flex: 1; background: transparent; border: none; padding: 10px; font-weight: 600; font-size: 1rem; color: var(--text-muted); border-bottom: 2px solid transparent; cursor: pointer;
}
.auth-tab.active { color: var(--primary-color); border-bottom-color: var(--primary-color); }
.auth-form { display: none; }
.auth-form.active { display: block; }

/* Item Details Customizations */
.item-detail-img { 
    width: 100%; 
    height: 200px; 
    object-fit: contain; 
    margin-bottom: 15px; 
    background: radial-gradient(circle, rgba(0,105,92,0.05) 0%, rgba(255,255,255,0) 80%);
    filter: drop-shadow(0 8px 16px rgba(0,0,0,0.12));
}
.item-detail-title { font-size: 1.4rem; font-weight: 700; margin-bottom: 5px; }
.item-detail-desc { font-size: 0.9rem; color: var(--text-muted); margin-bottom: 20px; }
.options-group { margin-bottom: 20px; }
.options-group h5 { font-size: 1rem; font-weight: 600; margin-bottom: 10px; }
.radio-tile-group { display: flex; flex-wrap: wrap; gap: 10px; }
.radio-tile {
    flex: 1; min-width: 80px; border: 1px solid var(--border-color); border-radius: 8px; padding: 10px; text-align: center; cursor: pointer; transition: all 0.2s;
}
.radio-tile.selected { border-color: var(--primary-color); background: rgba(0, 105, 92, 0.05); }
.radio-tile input { display: none; }
.radio-tile .tile-label { font-size: 0.85rem; font-weight: 600; display: block; margin-bottom: 5px; }
.radio-tile .tile-price { font-size: 0.75rem; color: var(--text-muted); }

/* Cart Sheet Customizations */
.cart-sheet { height: 80vh; }
.cart-items { flex: 1; overflow-y: auto; padding: 10px 0; margin-bottom: 20px; border-top: 1px solid var(--border-color); border-bottom: 1px solid var(--border-color);}
.cart-item { display: flex; align-items: center; gap: 15px; padding: 15px 0; border-bottom: 1px solid var(--border-color); }
.cart-item:last-child { border-bottom: none; }
.cart-item-info { flex: 1; }
.cart-item-title { font-weight: 600; font-size: 0.95rem; }
.cart-item-variant { font-size: 0.8rem; color: var(--text-muted); }
.cart-item-price { font-weight: 700; margin-top: 5px; color: var(--primary-color); }
.qty-controls { display: flex; align-items: center; gap: 12px; background: var(--bg-color); padding: 5px 10px; border-radius: 20px; }
.qty-btn { background: transparent; border: none; font-size: 1rem; cursor: pointer; color: var(--text-main); width: 24px; height: 24px; display:flex; align-items:center; justify-content:center;}
.qty-btn i { font-size: 0.8rem; }
.cart-summary-line { display: flex; justify-content: space-between; font-size: 1.1rem; margin-top: 10px; }

/* Checkout View */
.checkout-container { padding: 20px; }
.checkout-section { background: var(--card-bg); border-radius: 12px; padding: 15px; margin-bottom: 15px; box-shadow: var(--shadow-sm); }
.checkout-section h4 { font-size: 1rem; font-weight: 700; margin-bottom: 15px; border-bottom: 1px solid var(--border-color); padding-bottom: 10px;}
.checkout-address-box { display: flex; align-items: center; gap: 15px; cursor: pointer; }
.summary-row { display: flex; justify-content: space-between; margin-bottom: 10px; font-size: 0.9rem;}
.summary-row.total { font-weight: 700; font-size: 1.1rem; margin-top: 15px; padding-top: 15px; border-top: 1px dashed var(--border-color); color: var(--primary-color);}

/* Coming Soon & Empty States */
.coming-soon { text-align: center; padding: 50px 20px; color: var(--text-muted); }
.coming-soon i { margin-bottom: 20px; opacity: 0.5; }

/* Toast */
.toast {
    position: fixed; top: 20px; left: 50%; transform: translateX(-50%) translateY(-100px);
    background: #333; color: white; padding: 12px 24px; border-radius: 8px; font-weight: 500;
    z-index: 9999; transition: transform 0.3s; box-shadow: var(--shadow-md); font-size: 0.9rem;
}
.toast.show { transform: translateX(-50%) translateY(0); }

/* Orders List */
.orders-list { padding: 20px; }
.order-card { background: var(--card-bg); border-radius: 12px; padding: 15px; margin-bottom: 15px; box-shadow: var(--shadow-sm); border-left: 4px solid var(--primary-color);}
.order-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; border-bottom: 1px dashed var(--border-color); padding-bottom: 10px; }
.order-id { font-weight: 700; }
.order-status { background: #e0f2f1; color: #00897b; padding: 4px 8px; border-radius: 4px; font-size: 0.75rem; font-weight: 600; }
.order-status.pending { background: #fff8e1; color: #f57f17; }
.order-items-preview { font-size: 0.85rem; color: var(--text-muted); margin-bottom: 10px; }
.order-footer { display: flex; justify-content: space-between; font-weight: 700; }

/* Responsive adjustments for Tablets & PC */
@media (min-width: 768px) {
    body { max-width: 100%; height: 100vh; display: flex; box-shadow: none; margin: 0; }
    .screen { position: fixed; }
    .app-header { padding: 20px 50px; }
    .section { padding: 40px 50px; border-bottom: 2px solid var(--border-color); }
    
    /* Layout enhancements */
    .explore-grid { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 30px; }
    .deals-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(350px, 1fr)); gap: 25px; }
    .category-items-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(350px, 1fr)); gap: 25px; padding: 30px 50px; }
    .deals-list .deal-card, .category-items-list .deal-card { height: 100%; border-radius: 16px; }
    .slide img { height: 350px; } /* larger slider on PC */
    .checkout-container { max-width: 800px; margin: 0 auto; padding: 40px; }
    
    /* Cart behaves mostly same but wider and positioned nicely */
    .floating-cart { left: auto; right: 50px; bottom: 50px; width: 350px; box-shadow: var(--shadow-md); padding: 15px 30px;}
    
    /* Bottom sheets become Side Panels on Desktop */
    .bottom-sheet { border-radius: 24px 0 0 24px; top: 0; bottom: 0; left: auto; right: -450px; width: 450px; max-height: 100vh; transition: right 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
    .bottom-sheet.active { right: 0; bottom: auto; }
    
    /* Adjust Modals specifically */
    .center-modal { max-width: 500px; padding: 40px; }
    #item-modal { width: 450px; padding: 40px; }
    .item-detail-img { height: 250px; }
    .orders-list { max-width: 900px; margin: 0 auto; padding: 40px; display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
}

@media (min-width: 1200px) {
    .section { padding: 40px 10%; }
    .app-header { padding: 20px 10%; }
    .category-items-list { padding: 30px 10%; }
    .slider-container { max-width: 1200px; margin: 0 auto; }
}

/* ===== Logo Styles ===== */
.splash-logo {
    width: 150px;
    height: 150px;
    object-fit: contain;
    border-radius: 50%;
    margin: 0 auto 15px;
    display: block;
    animation: slideUpFade 0.6s ease;
}

.header-logo {
    width: 48px;
    height: 48px;
    object-fit: contain;
    border-radius: 50%;
}

/* ===== Favourite Button ===== */
.fav-btn {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(255,255,255,0.9);
    border: none;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.9rem;
    color: #ccc;
    transition: all 0.2s;
    box-shadow: 0 1px 4px rgba(0,0,0,0.15);
    z-index: 5;
}
.fav-btn:active { transform: scale(0.85); }
.fav-btn.active { color: #ffca28; }
.fav-btn.active i { animation: heartPop 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); }

@keyframes heartPop {
    0% { transform: scale(1); }
    50% { transform: scale(1.5); }
    100% { transform: scale(1); }
}

/* ===== Info Pages (Terms, Privacy, About) ===== */
.info-page-content {
    padding: 20px;
    max-width: 800px;
    margin: 0 auto;
}
.info-page-content h4 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-top: 20px;
    margin-bottom: 8px;
}
.info-page-content p {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.7;
    margin-bottom: 5px;
}

/* ===== Store Card ===== */
.store-card {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 25px;
    box-shadow: var(--shadow-md);
    border-left: 4px solid var(--primary-color);
    margin-top: 10px;
}

/* ===== Brand Specific Overrides ===== */
body.brand-bakery #main-global-header,
body.brand-bakery #main-order-toggle,
body.brand-general-store #main-global-header,
body.brand-general-store #main-order-toggle {
    display: none !important;
}

/* Bakery Category Card Layout */
.bakery-cat-card {
    background-color: #f5f5f5;
    padding: 15px;
    border-radius: 0;
    text-align: center;
    cursor: pointer;
    transition: transform 0.2s;
    height: 100%;
    display: flex;
    flex-direction: column;
}
.bakery-cat-card:active {
    transform: scale(0.98);
}
.bakery-cat-card img {
    width: 100%;
    height: 110px;
    object-fit: contain;
    margin-bottom: 15px;
    mix-blend-mode: multiply;
}
.bakery-cat-card h4 {
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 2px;
    margin-top: auto;
    color: #111;
}

/* Glassmorphism Auth */
.glass-auth {
    background: rgba(10, 10, 10, 0.5) !important;
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.4);
}
.glass-input {
    background: rgba(255, 255, 255, 0.1) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    color: #fff !important;
}
.glass-input::placeholder {
    color: rgba(255, 255, 255, 0.5) !important;
}
.glass-tabs {
    background: transparent !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}
.glass-tabs .auth-tab {
    color: rgba(255,255,255,0.6);
}
.glass-tabs .auth-tab.active {
    color: #fff;
    border-bottom-color: #fff;
}

/* Favourites */
.fav-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255, 255, 255, 0.9);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #aaa;
    font-size: 1.1rem;
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    transition: all 0.2s;
    z-index: 5;
}
.fav-btn.active {
    color: #e74c3c;
    animation: pulse 0.3s ease-in-out;
}
.store-card h4 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-main);
}
.store-card p {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}

/* Badge System */
.badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #e74c3c;
    color: white;
    font-size: 0.7rem;
    padding: 2px 5px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
    border: 2px solid var(--header-bg);
}

/* Notifications UI */
.notif-card {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 12px;
    display: flex;
    gap: 15px;
    align-items: flex-start;
    border: 1px solid var(--border-color);
    transition: transform 0.2s;
}
.notif-card.unread {
    border-left: 4px solid var(--primary-color);
}
.notif-card:active { transform: scale(0.98); }

.notif-icon-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(0, 105, 92, 0.1);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}
.brand-bakery .notif-icon-circle {
    background: rgba(196, 164, 90, 0.1);
    color: var(--primary-color);
}

.notif-content { flex: 1; }
.notif-title {
    font-weight: 600;
    font-size: 0.95rem;
    margin-bottom: 4px;
    color: var(--text-main);
}
.notif-time {
    font-size: 0.75rem;
    color: var(--text-muted);
}
.notif-unread-dot {
    width: 8px;
    height: 8px;
    background: var(--primary-color);
    border-radius: 50%;
    align-self: center;
}

/* ===== Theme Toggle Pill Styling ===== */
.theme-pill-container {
    padding: 10px 25px;
    margin-top: 5px;
}
.theme-toggle-btn {
    background: transparent;
    border: none;
    width: 100%;
    cursor: pointer;
    padding: 0;
}
.theme-pill {
    background: var(--bg-color);
    border: 1.5px solid var(--border-color);
    border-radius: 24px;
    display: flex;
    justify-content: space-between;
    padding: 3px;
    position: relative;
    box-shadow: inset 0 2px 5px rgba(0,0,0,0.05);
}
.theme-opt {
    flex: 1;
    text-align: center;
    font-size: 0.8rem;
    padding: 8px 12px;
    border-radius: 20px;
    color: var(--text-muted);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 600;
}
.theme-opt.active {
    background: var(--primary-color);
    color: white !important;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}
.brand-bakery .theme-opt.active {
    background: #6b4d31; 
}

/* ===== Fast Food Store Footer ===== */
.ff-footer {
    background: var(--card-bg);
    border-top: 3px solid var(--primary-color);
    padding: 30px 20px;
    text-align: center;
    margin-top: 20px;
}
.ff-footer img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: contain;
    border: 3px solid var(--primary-color);
    padding: 3px;
    margin-bottom: 12px;
}
.ff-footer-brand {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--primary-color);
    letter-spacing: 1px;
    margin-bottom: 5px;
}
.ff-footer p {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 5px;
    line-height: 1.5;
}
.ff-footer-links {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin: 12px 0;
    font-size: 0.8rem;
}
.ff-footer-links a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
}
.ff-footer-links span {
    color: var(--border-color);
}
.ff-footer-credit {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 10px;
}
.ff-footer-credit strong {
    color: var(--primary-color);
}

/* ===== Invoice Print Styling ===== */
@media print {
    body * { visibility: hidden; }
    #invoice-modal, #invoice-modal * { visibility: visible; }
    #invoice-modal { position: fixed; top: 0; left: 0; width: 100%; z-index: 99999; }
}

/* ===== GENERAL STORE THEME OVERRIDES ===== */
body.brand-general-store {
    --primary-color: #4f46e5;       /* Premium Indigo primary */
    --primary-hover: #4338ca;
    --primary-light: #e0e7ff;
    --primary-glow: rgba(79, 70, 229, 0.15);
    --accent-color: #f59e0b;        /* Warm amber accent */
    --danger-color: #ef4444;
    --success-color: #10b981;
    --card-bg: #ffffff;
    --bg-color: #f8fafc;            /* Clean light slate background */
    --border-color: #e2e8f0;
    --text-main: #0f172a;
    --text-muted: #64748b;
}

body.brand-general-store.night-theme {
    --primary-color: #6366f1;
    --primary-hover: #4f46e5;
    --primary-light: #1e1b4b;
    --primary-glow: rgba(99, 102, 241, 0.2);
    --accent-color: #fbbf24;
    --danger-color: #f87171;
    --success-color: #34d399;
    --card-bg: #1e293b;             /* Dark slate card */
    --bg-color: #0f172a;            /* Dark slate background */
    --border-color: #334155;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
}

/* GS Header Search bar styling */
.gs-sticky-search-container {
    position: sticky;
    top: 0;
    z-index: 100;
    background: linear-gradient(135deg, var(--primary-color) 0%, #312e81 100%);
    box-shadow: 0 4px 20px rgba(79, 70, 229, 0.25);
    border-radius: 0 0 24px 24px;
    padding-bottom: 4px;
    padding-top: 8px;
}

/* GS Slider / Banner styles */
.gs-slider-container {
    margin: 15px;
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    aspect-ratio: 16 / 9;
    background: #e2e8f0;
}
.gs-slider-wrapper {
    display: block;
    width: 100%;
    height: 100%;
}
.gs-slide {
    min-width: 100%;
    height: 100%;
    position: relative;
}
.gs-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.gs-slider-dots {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 2;
}
.gs-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}
.gs-dot.active {
    width: 20px;
    border-radius: 4px;
    background: white;
}

/* GS Category pills styling */
.gs-categories-scroll {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 5px 15px 10px;
    scrollbar-width: none;
}
.gs-categories-scroll::-webkit-scrollbar {
    display: none;
}
.gs-cat-pill {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    padding: 12px 16px;
    border-radius: 16px;
    min-width: 85px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.02);
}
.gs-cat-pill i {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin-bottom: 8px;
    transition: transform 0.3s ease;
}
.gs-cat-pill span {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-main);
    text-align: center;
    white-space: nowrap;
}
.gs-cat-pill.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    box-shadow: 0 8px 20px var(--primary-glow);
    transform: translateY(-2px);
}
.gs-cat-pill.active i, .gs-cat-pill.active span {
    color: #ffffff;
}
.gs-cat-pill:hover i {
    transform: scale(1.1);
}

/* GS Products Grid styling */
.gs-products-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}
.gs-product-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 12px;
    position: relative;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(0,0,0,0.02);
    display: flex;
    flex-direction: column;
}
.gs-product-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.06);
    border-color: var(--primary-light);
}
.gs-product-img-container {
    width: 100%;
    height: 110px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-color);
    border-radius: 14px;
    margin-bottom: 10px;
    overflow: hidden;
}
.gs-product-img {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    mix-blend-mode: multiply;
}
.gs-product-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-main);
    line-height: 1.35;
    height: 2.7rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 4px;
}
.gs-product-weight {
    font-size: 0.72rem;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 12px;
}
.gs-product-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
}
.gs-product-price {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--primary-color);
}
.gs-add-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 10px var(--primary-glow);
    transition: all 0.2s ease;
}
.gs-add-btn:hover {
    transform: scale(1.1);
    background: var(--primary-hover);
}
.gs-add-btn i {
    font-size: 0.9rem;
}

/* =========================================
   PREMIUM DARK THEME ENHANCEMENTS
   ========================================= */
.night-theme {
    --bg-color: #0d0f12;
    --card-bg: #161b22;
    --header-bg: rgba(22, 27, 34, 0.85);
    --border-color: #30363d;
    --text-main: #f0f6fc;
    --text-muted: #8b949e;
    --primary-color: #ff3b30; /* KFC red */
    --primary-hover: #d72828;
}

.brand-bakery.night-theme {
    --bg-color: #120e0c;
    --card-bg: #1c1512;
    --header-bg: rgba(28, 21, 18, 0.85);
    --border-color: #3a2a24;
    --primary-color: #d4af37;
    --text-main: #fdfbf7;
    --text-muted: #a6968c;
}

.brand-gs.night-theme, .night-theme .view#view-general-store {
    --bg-color: #0b0f19;
    --card-bg: #131a2a;
    --header-bg: rgba(19, 26, 42, 0.85);
    --border-color: #2a3655;
    --primary-color: #6366f1;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
}

/* =========================================
   PREMIUM ITEM MODAL (GLASSMORPHISM)
   ========================================= */
.premium-item-modal {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: var(--bg-color);
    z-index: 10000;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}
.premium-item-modal.active {
    transform: translateY(0);
}

/* Glassmorphism Header */
.pim-header {
    position: absolute;
    top: 0; left: 0; right: 0;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 10;
    background: linear-gradient(to bottom, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0) 100%);
}
.pim-back {
    width: 40px; height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: white;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem;
    cursor: pointer;
    border: 1px solid rgba(255,255,255,0.2);
}

/* Hero Image Section */
.pim-hero {
    position: relative;
    width: 100%;
    height: 42vh;
    background: linear-gradient(135deg, rgba(255,255,255,0.05), rgba(255,255,255,0));
    display: flex; align-items: center; justify-content: center;
    overflow: hidden;
}
.pim-hero img {
    width: 90%;
    height: 90%;
    object-fit: contain;
    filter: drop-shadow(0 20px 30px rgba(0,0,0,0.5));
    animation: pimFloat 4s ease-in-out infinite;
}
@keyframes pimFloat {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

/* Content Area */
.pim-content {
    flex: 1;
    overflow-y: auto;
    padding: 24px 20px 100px;
    background: var(--bg-color);
    border-radius: 30px 30px 0 0;
    margin-top: -30px;
    position: relative;
    box-shadow: 0 -10px 30px rgba(0,0,0,0.1);
}
.pim-title {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 8px;
    line-height: 1.2;
}
.pim-desc {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 24px;
}

/* Addon Sections */
.pim-section-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}
.pim-section-title .badge {
    font-size: 0.7rem;
    padding: 3px 8px;
    border-radius: 10px;
    background: rgba(255,255,255,0.1);
    color: var(--text-muted);
}
.pim-addon-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 30px;
}
.pim-addon-item {
    display: flex;
    align-items: center;
    background: var(--card-bg);
    padding: 10px 14px;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    transition: all 0.2s;
    gap: 12px;
}
.pim-addon-item.selected {
    border-color: var(--primary-color);
    background: rgba(var(--primary-rgb), 0.05);
}
.pim-addon-img {
    width: 75px;
    height: 75px;
    object-fit: contain;
    border-radius: 12px;
    background: #fff;
    padding: 4px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.pim-addon-info {
    flex: 1;
}
.pim-addon-name {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-main);
}
.pim-addon-price {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 2px;
}
.pim-addon-action {
    display: flex;
    align-items: center;
    justify-content: center;
}
.pim-btn-add {
    background: rgba(255,255,255,0.1);
    color: var(--text-main);
    border: none;
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}
.pim-btn-add.selected {
    background: var(--primary-color);
    color: white;
}
.pim-btn-add:active {
    transform: scale(0.95);
}

/* Glassmorphism Bottom Sticky Bar */
.pim-bottom-bar {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: 15px 20px 25px;
    background: rgba(var(--card-bg-rgb, 22,27,34), 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255,255,255,0.05);
    display: flex;
    align-items: center;
    gap: 15px;
    z-index: 20;
}
.pim-qty-control {
    display: flex;
    align-items: center;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 12px;
    padding: 4px;
}
.pim-qty-btn {
    width: 36px; height: 36px;
    background: transparent;
    border: none;
    color: var(--text-main);
    font-size: 1.2rem;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer;
}
.pim-qty-val {
    width: 30px;
    text-align: center;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-main);
}
.pim-btn-cart {
    flex: 1;
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 14px 20px;
    border-radius: 12px;
    font-size: 1.05rem;
    font-weight: 800;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 10px 20px rgba(255,59,48,0.3);
    transition: transform 0.2s;
}
.pim-btn-cart:active {
    transform: scale(0.97);
}

/* =========================================
   GLOBAL FLOATING CART
   ========================================= */
.global-floating-cart {
    position: fixed;
    bottom: 25px;
    right: 25px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-hover));
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
    cursor: pointer;
    z-index: 9000;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 3px solid rgba(255,255,255,0.2);
}
.global-floating-cart:hover {
    transform: scale(1.08) translateY(-5px);
}
.global-floating-cart:active {
    transform: scale(0.95);
}
.global-floating-cart i {
    color: white;
    font-size: 1.8rem;
}
.global-floating-cart .gfc-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ffcc00;
    color: #000;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 800;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
    border: 2px solid var(--primary-color);
}
.gfc-bounce {
    animation: gfcBounce 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
@keyframes gfcBounce {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

/* =========================================
   7-SECOND UNIQUE SUCCESS TOAST
   ========================================= */
.cart-success-popup {
    position: fixed;
    bottom: -100px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(22, 27, 34, 0.9);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255,255,255,0.1);
    color: white;
    padding: 12px 20px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);
    z-index: 9999;
    transition: bottom 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    width: 90%;
    max-width: 400px;
    pointer-events: none;
}
.cart-success-popup.show {
    bottom: 40px;
}
.csp-icon {
    width: 36px; height: 36px;
    background: #34c759;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 1rem;
    box-shadow: 0 0 15px rgba(52, 199, 89, 0.5);
}
.csp-text {
    flex: 1;
    font-size: 0.95rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Premium modal radio tile overrides */
.premium-item-modal .radio-tile {
    border: 1.5px solid var(--border-color) !important;
    background: var(--card-bg) !important;
    border-radius: 12px;
    padding: 12px;
    transition: all 0.2s ease;
    cursor: pointer;
    display: block;
}
.premium-item-modal .radio-tile.selected {
    border-color: var(--primary-color) !important;
    background: rgba(var(--primary-rgb, 255, 59, 48), 0.1) !important;
    box-shadow: 0 0 10px rgba(var(--primary-rgb, 255, 59, 48), 0.15);
}
.night-theme .premium-item-modal .radio-tile.selected {
    background: rgba(var(--primary-rgb, 255, 59, 48), 0.2) !important;
}

/* =========================================
   GS ITEM DETAIL PAGE
   ========================================= */
#view-gs-item {
    background: #f8fafc;
}
.night-theme #view-gs-item {
    background: var(--bg-color);
}
.gs-detail-header {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    padding: 12px 20px;
    min-height: 60px;
    display: flex;
    align-items: center;
    gap: 15px;
    position: sticky;
    top: 0;
    z-index: 50;
}
.gs-detail-back-btn {
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.2s;
}
.gs-detail-back-btn:active { background: rgba(255,255,255,0.35); }
.gs-detail-image-wrap {
    background: white;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 15px;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    aspect-ratio: 1 / 1;
    max-height: 260px;
    overflow: hidden;
}
.night-theme .gs-detail-image-wrap { background: var(--card-bg); }
.gs-detail-image-wrap img {
    max-width: 100%;
    max-height: 220px;
    object-fit: contain;
}
.gs-detail-info-card {
    background: white;
    margin: 0 15px 15px;
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}
.night-theme .gs-detail-info-card { background: var(--card-bg); }
.gs-detail-category {
    color: #6366f1;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 6px;
}
.gs-detail-title {
    font-size: 1.25rem;
    font-weight: 800;
    color: #1e1b4b;
    margin-bottom: 15px;
    line-height: 1.3;
}
.night-theme .gs-detail-title { color: var(--text-main); }
.gs-detail-price {
    font-size: 2rem;
    font-weight: 800;
    color: #4f46e5;
}
.gs-detail-qty-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 15px 0;
}
.gs-detail-qty-control {
    display: flex;
    align-items: center;
    gap: 0;
    background: #f1f5f9;
    border-radius: 30px;
    padding: 6px;
    gap: 5px;
}
.night-theme .gs-detail-qty-control { background: var(--bg-color); }
.gs-detail-qty-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s;
}
.gs-detail-qty-btn:active { transform: scale(0.9); }
.gs-detail-qty-minus { background: white; color: #1e1b4b; box-shadow: 0 2px 6px rgba(0,0,0,0.1); }
.night-theme .gs-detail-qty-minus { background: var(--card-bg); color: var(--text-main); }
.gs-detail-qty-plus { background: #4f46e5; color: white; box-shadow: 0 4px 10px rgba(79,70,229,0.3); }
.gs-detail-qty-val {
    font-size: 1.15rem;
    font-weight: 700;
    color: #1e1b4b;
    min-width: 28px;
    text-align: center;
}
.night-theme .gs-detail-qty-val { color: var(--text-main); }
.gs-detail-add-btn {
    width: 100%;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: white;
    border: none;
    border-radius: 14px;
    padding: 16px 20px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 8px 20px rgba(79,70,229,0.3);
    transition: transform 0.2s, box-shadow 0.2s;
    letter-spacing: 0.5px;
}
.gs-detail-add-btn:active { transform: scale(0.98); box-shadow: 0 4px 10px rgba(79,70,229,0.2); }

/* =========================================
   RECOMMENDATIONS SECTIONS
   ========================================= */
.recommendations-section {
    padding: 20px 15px;
}
.recommendations-title {
    font-size: 1rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.recommendations-scroll {
    display: flex;
    overflow-x: auto;
    gap: 12px;
    padding-bottom: 8px;
    scrollbar-width: none;
}
.recommendations-scroll::-webkit-scrollbar { display: none; }
.reco-card {
    min-width: 130px;
    max-width: 130px;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 14px;
    overflow: hidden;
    cursor: pointer;
    flex-shrink: 0;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.night-theme .reco-card { background: var(--card-bg); }
.reco-card:active { transform: scale(0.97); }
.reco-card-img {
    width: 100%;
    height: 90px;
    object-fit: contain;
    padding: 8px;
    background: #f9f9f9;
    display: block;
}
.night-theme .reco-card-img { background: rgba(255,255,255,0.03); }
.reco-card-body {
    padding: 8px 10px 10px;
}
.reco-card-title {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-main);
    margin: 0 0 4px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2em;
}
.reco-card-price {
    font-size: 0.85rem;
    font-weight: 800;
    color: #4f46e5;
}
.bakery-reco-price { color: #aa7a47; }

/* Cart store group header */
.cart-store-group-header {
    padding: 10px 0 4px;
    font-size: 0.82rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 6px;
    border-top: 1px solid var(--border-color);
    margin-top: 8px;
}
.cart-store-group-header:first-of-type { border-top: none; margin-top: 0; }

/* =========================================
   PROFESSIONAL BAKERY FOOTER
   ========================================= */
.bakery-footer-pro {
    background: linear-gradient(160deg, #1a0f08 0%, #2e1a0e 50%, #1a0f08 100%);
    padding: 40px 20px 20px;
    margin-top: 20px;
    color: #f1e8d8;
}
.bakery-footer-brand {
    text-align: center;
    margin-bottom: 35px;
    padding-bottom: 30px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}
.bakery-footer-logo {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    object-fit: contain;
    border: 3px solid #c4a141;
    padding: 4px;
    margin-bottom: 12px;
    display: block;
    margin-left: auto;
    margin-right: auto;
    box-shadow: 0 0 20px rgba(196, 161, 65, 0.3);
}
.bakery-footer-brand h4 {
    font-size: 1.4rem;
    font-weight: 800;
    color: #d4af37;
    letter-spacing: 2px;
    margin-bottom: 6px;
    font-family: 'Georgia', serif;
}
.bakery-footer-brand p {
    font-size: 0.8rem;
    color: rgba(241,232,216,0.6);
    line-height: 1.6;
    margin-bottom: 20px;
}
.bakery-social-row {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 10px;
}
.bakery-social-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.1rem;
    text-decoration: none;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s;
    box-shadow: 0 4px 15px rgba(0,0,0,0.4);
}
.bakery-social-btn:hover, .bakery-social-btn:active {
    transform: translateY(-4px) scale(1.1);
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}
.bakery-footer-links-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 15px;
    margin-bottom: 30px;
}
.bakery-footer-col h5 {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #d4af37;
    margin-bottom: 12px;
}
.bakery-footer-col a {
    display: block;
    font-size: 0.78rem;
    color: rgba(241,232,216,0.6);
    text-decoration: none;
    padding: 4px 0;
    cursor: pointer;
    transition: color 0.2s;
    line-height: 1.4;
}
.bakery-footer-col a:hover {
    color: #d4af37;
}
.bakery-footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.08);
    padding-top: 20px;
    text-align: center;
}
.bakery-footer-bottom p {
    font-size: 0.72rem;
    color: rgba(241,232,216,0.4);
    line-height: 1.8;
}
.bakery-footer-bottom strong {
    color: #d4af37;
}

/* =========================================
   GLASSMORPHISM LIQUID GLASS EFFECTS
   ========================================= */

/* Glass card - used on category cards, deal cards etc */
.glass-card {
    background: rgba(255,255,255,0.08);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255,255,255,0.15);
    box-shadow: 0 8px 32px rgba(0,0,0,0.1), inset 0 1px 0 rgba(255,255,255,0.2);
    will-change: transform;
    transform: translateZ(0);
}
.night-theme .glass-card {
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
}

/* Glassmorphism brand cards on splash screen */
.brand-card {
    background: rgba(255,255,255,0.7);
    backdrop-filter: blur(12px) saturate(160%);
    -webkit-backdrop-filter: blur(12px) saturate(160%);
    border: 1.5px solid rgba(255,255,255,0.5);
    box-shadow: 0 8px 32px rgba(0,105,92,0.08), inset 0 1px 0 rgba(255,255,255,0.8);
}
.night-theme .brand-card {
    background: rgba(255,255,255,0.04);
    border: 1.5px solid rgba(255,255,255,0.08);
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

/* Glassmorphism GS detail image */
.gs-detail-image-wrap {
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(20px) saturate(200%);
    -webkit-backdrop-filter: blur(20px) saturate(200%);
    border: 1.5px solid rgba(255,255,255,0.6);
    box-shadow: 0 8px 32px rgba(79,70,229,0.1), inset 0 1px 0 rgba(255,255,255,0.9);
}
.night-theme .gs-detail-image-wrap {
    background: rgba(30,27,75,0.6);
    backdrop-filter: blur(20px);
    border: 1.5px solid rgba(99,102,241,0.2);
    box-shadow: 0 8px 32px rgba(0,0,0,0.4);
}

/* Glassmorphism GS info card */
.gs-detail-info-card {
    background: rgba(255,255,255,0.9);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255,255,255,0.7);
    box-shadow: 0 4px 24px rgba(79,70,229,0.08), inset 0 1px 0 rgba(255,255,255,0.95);
}
.night-theme .gs-detail-info-card {
    background: rgba(30,41,59,0.85);
    border: 1px solid rgba(99,102,241,0.15);
}

/* Glassmorphism bakery category cards */
.bakery-cat-card {
    background: rgba(245,240,235,0.7);
    backdrop-filter: blur(10px) saturate(180%);
    -webkit-backdrop-filter: blur(10px) saturate(180%);
    border: 1px solid rgba(196,161,65,0.15);
    box-shadow: 0 4px 20px rgba(0,0,0,0.05), inset 0 1px 0 rgba(255,255,255,0.8);
    transition: transform 0.2s, box-shadow 0.2s;
}
.bakery-cat-card:active {
    transform: scale(0.97);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}
.night-theme .bakery-cat-card {
    background: rgba(40,27,23,0.7);
    border: 1px solid rgba(196,161,65,0.1);
}

/* Glassmorphism splash footer */
#splash-screen .splash-footer {
    position: relative;
}

/* Glassmorphism modal overlay extra blur */
.modal-overlay {
    backdrop-filter: blur(6px) saturate(120%);
    -webkit-backdrop-filter: blur(6px) saturate(120%);
}

/* Glassmorphism cart sheet */
.bottom-sheet {
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(30px) saturate(200%);
    -webkit-backdrop-filter: blur(30px) saturate(200%);
    border-top: 1px solid rgba(255,255,255,0.6);
    box-shadow: 0 -10px 40px rgba(0,0,0,0.15);
}
.night-theme .bottom-sheet {
    background: rgba(22,27,34,0.95);
    border-top: 1px solid rgba(255,255,255,0.06);
}

/* Glassmorphism pim-bottom-bar (item modal bottom) */
.pim-bottom-bar {
    background: rgba(255,255,255,0.7);
    backdrop-filter: blur(24px) saturate(200%);
    -webkit-backdrop-filter: blur(24px) saturate(200%);
    border-top: 1px solid rgba(255,255,255,0.4);
    box-shadow: 0 -4px 20px rgba(0,0,0,0.08);
}
.night-theme .pim-bottom-bar {
    background: rgba(22,27,34,0.7);
    border-top: 1px solid rgba(255,255,255,0.05);
}

/* Glassmorphism cart success popup */
.cart-success-popup {
    background: rgba(10,20,30,0.85);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255,255,255,0.12);
}

/* Glassmorphism GS search bar */
.gs-sticky-search-container {
    background: linear-gradient(135deg, rgba(79,70,229,0.95) 0%, rgba(49,46,129,0.98) 100%);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* Glassmorphism header */
.app-header {
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    background: rgba(255,255,255,0.92);
}
.night-theme .app-header {
    background: rgba(13,15,18,0.92);
}

/* ===== SAFE AREA (Status Bar Fix for Android/iOS) ===== */
body {
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
}
.screen {
    /* Remove double-padding since header already handles it */
    padding-top: 0;
}
@supports (padding: max(0px)) {
    /* Safe area padding handled natively by React Native */
}

/* Floating global cart glassmorphism */
.global-floating-cart {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-hover));
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 10px 40px rgba(0,0,0,0.3), 0 0 0 2px rgba(255,255,255,0.1) inset;
}

/* GS product card liquid glass */
.gs-product-card {
    background: rgba(255,255,255,0.9) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.6);
    will-change: transform;
    transform: translateZ(0);
}
.night-theme .gs-product-card {
    background: rgba(15, 20, 25, 0.7) !important;
    border: 1px solid rgba(255,255,255,0.1) !important;
}
.night-theme .gs-product-card p {
    color: #ffffff !important;
}
.night-theme .gs-product-card span {
    color: #818cf8 !important; /* Lighter indigo for dark mode */
}

/* Drawer glassmorphism */
.side-drawer {
    backdrop-filter: blur(30px) saturate(200%);
    -webkit-backdrop-filter: blur(30px) saturate(200%);
    background: rgba(255,255,255,0.97);
}
.night-theme .side-drawer {
    background: rgba(15,19,26,0.97);
}
