/* ============================================================
           SECTION 1 — CSS VARIABLES & THEME
           Để thay đổi màu sắc toàn app, chỉ cần sửa tại đây.
           - :root          → Dark Mode (mặc định)
           - body.light-mode → Light Mode (kích hoạt bằng nút 🌙/☀️)
           - body.high-contrast → Tương phản cao (Accessibility)
        ============================================================ */
        :root {
            /* Brand Colors — KHÔNG thay đổi khi đổi theme */
            --primary:        #026680;
            --primary-dark:   #004d61;
            --primary-glow:   rgba(2, 102, 128, 0.35);
            --secondary:      #00ea9f;     /* Mint Neon — màu nhấn */
            --success:        #10b981;
            --danger:         #ef4444;

            /* Dark Mode — Nền đại dương thẳm */
            --bg-dark:        #0b111e;
            --bg-card:        #131c2e;
            --card-bg:        rgba(19, 28, 46, 0.7);
            --card-hover:     rgba(30, 41, 59, 0.9);
            --border:         rgba(255, 255, 255, 0.08);
            --text-main:      #f8fafc;
            --text-muted:     #94a3b8;
            --shadow:         transparent;
            --shadow-menu:    0 8px 22px rgba(0, 0, 0, 0.4);

            /* Misc */
            --font-scale:     1;
            --safe-bottom:    env(safe-area-inset-bottom, 0px);
        }

        /* Light Mode — Nền trắng tinh tế */
        body.light-mode {
            --bg-dark:        #ffffff;
            --bg-card:        #f1f5f9;
            --card-bg:        rgba(241, 245, 249, 0.7);
            --card-hover:     rgba(226, 232, 240, 0.9);
            --border:         rgba(0, 0, 0, 0.06);
            --text-main:      #0f172a;
            --text-muted:     #64748b;
            --shadow:         0 4px 12px rgba(2, 102, 128, 0.05);
            --shadow-menu:    0 8px 22px rgba(2, 102, 128, 0.08);
            /* Giữ nguyên --primary, --secondary để brand nhất quán */
        }

        /* High-Contrast Mode — Hỗ trợ người khiếm thị */
        body.high-contrast {
            --bg-dark: #000; --bg-card: #111; --card-bg: #111;
            --border: #fff; --text-main: #fff; --text-muted: #ddd;
            --primary: #00ea9f;
        }

        /* Nút đổi theme (Dark/Light) */
        .theme-toggle-btn {
            background: rgba(255,255,255,0.06); border: 1px solid var(--border);
            border-radius: 9px; padding: 6px 9px; cursor: pointer;
            display: flex; align-items: center; justify-content: center;
            color: var(--text-main); font-size: 14px; transition: all 0.15s;
        }
        .theme-toggle-btn:hover { background: rgba(255,255,255,0.12); }


        /* ============================================================
           SECTION 2 — BASE RESET & TYPOGRAPHY
        ============================================================ */
        *, *::before, *::after {
            box-sizing: border-box; margin: 0; padding: 0;
            font-family: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
            -webkit-tap-highlight-color: transparent;
            -webkit-font-smoothing: antialiased;
            -moz-osx-font-smoothing: grayscale;
            text-rendering: optimizeLegibility;
        }
        html {
            height: 100%;
            overflow: hidden;
        }
        body {
            background: var(--bg-dark); color: var(--text-main);
            height: 100%; overflow: hidden;
            font-size: calc(16px * var(--font-scale));
            max-width: 430px; margin: 0 auto; position: relative;
        }


        /* ============================================================
           SECTION 3 — LANDING PAGE
           Màn hình đầu tiên người dùng thấy khi mở app.
           Bao gồm: Header, Hero, Stats, Connect Button,
                    Promo Slideshow, Price Ticker, Trust Items, Footer
        ============================================================ */
        #portal-landing {
            display: flex; flex-direction: column; height: 100%;
            overflow-y: auto; -webkit-overflow-scrolling: touch;
            background: linear-gradient(180deg, var(--bg-card) 0%, var(--bg-dark) 100%);
        }

        /* -- Header -- */
        .lp-header {
            display: flex; justify-content: space-between; align-items: center;
            padding: 14px 18px; border-bottom: 1px solid var(--border);
            background: var(--bg-card); box-shadow: var(--shadow);
            backdrop-filter: blur(10px); position: sticky; top: 0; z-index: 50;
        }
        .lp-logo { display: flex; align-items: center; gap: 9px; font-size: 21px; font-weight: 800; color: var(--text-main); }
        .lp-logo img { height: 30px; width: 30px; border-radius: 7px; background: transparent; object-fit: contain; }
        .lp-hamburger { background: rgba(255,255,255,0.06); border: 1px solid var(--border); border-radius: 9px; padding: 7px; cursor: pointer; display: flex; flex-direction: column; gap: 4px; }
        .lp-hamburger span { display: block; width: 18px; height: 2px; background: var(--text-main); border-radius: 2px; }

        /* -- Hamburger Dropdown Menu -- */
        .lp-menu-dropdown {
            position: fixed; top: 59px; left: 0; right: 0; max-width: 430px; margin: 0 auto;
            background: var(--bg-card); border-bottom: 1px solid var(--border);
            border-radius: 0 0 14px 14px; box-shadow: var(--shadow-menu);
            z-index: 48; display: none; flex-direction: column; overflow: hidden;
        }
        .lp-menu-dropdown.open { display: flex; }
        .lp-menu-link { padding: 14px 18px; font-size: 14px; font-weight: 600; color: var(--text-muted); border-bottom: 1px solid var(--border); cursor: pointer; transition: all 0.15s; }
        .lp-menu-link:last-child { border-bottom: none; }
        .lp-menu-link:hover { background: rgba(255,255,255,0.04); color: var(--text-main); }

        /* -- Hero Section -- */
        .lp-hero { padding: 32px 20px 24px; text-align: center; }
        .lp-hero-badge {
            display: inline-flex; align-items: center; gap: 6px;
            background: rgba(2,102,128,0.12);
            border: 1px solid rgba(2,102,128,0.25);
            border-radius: 20px; padding: 5px 13px;
            font-size: 11px; font-weight: 700; color: var(--accent);
            margin-bottom: 16px;
        }
        .lp-hero-badge i, .lp-hero-badge svg { font-size: 12px; }
        .lp-hero-badge svg { width: 12px; height: 12px; stroke-width: 2.5; }
        .lp-hero-title {
            font-size: 30px; font-weight: 900; line-height: 1.15;
            letter-spacing: -0.5px; margin-bottom: 12px;
            color: var(--text-main);
        }
        .lp-hero-accent { color: var(--accent); }
        .lp-hero-desc {
            font-size: 14px; color: var(--text-muted);
            line-height: 1.6; max-width: 300px;
            margin: 0 auto 24px;
        }
        .lp-hero-ctas { display: flex; gap: 10px; margin-bottom: 14px; }
        .lp-cta-primary {
            flex: 1; background: var(--primary); color: white;
            border: none; padding: 14px; border-radius: 12px;
            font-size: 14px; font-weight: 800;
            display: flex; align-items: center; justify-content: center; gap: 8px;
            transition: opacity 0.15s;
            cursor: pointer;
        }
        .lp-cta-primary:hover { opacity: 0.88; }
        .lp-cta-secondary {
            flex: 1; background: rgba(255,255,255,0.05);
            border: 1px solid var(--border); color: var(--text-main);
            padding: 14px; border-radius: 12px;
            font-size: 14px; font-weight: 800;
            display: flex; align-items: center; justify-content: center; gap: 8px;
            transition: all 0.15s;
            cursor: pointer;
        }
        .lp-cta-primary svg, .lp-cta-secondary svg { width: 16px; height: 16px; stroke-width: 2.5; }
        .lp-cta-secondary:hover { border-color: var(--primary); color: var(--primary); }
        .lp-hero-trust {
            font-size: 11px; color: var(--text-muted);
            display: flex; align-items: center; justify-content: center; gap: 5px;
        }
        .lp-hero-trust svg { width: 13px; height: 13px; stroke-width: 2; }

        /* -- Pi Map Preview -- */
        .lp-map-preview { padding: 0 20px 28px; }
        .lp-section-label {
            display: flex; align-items: center; gap: 6px;
            font-size: 11px; font-weight: 700;
            color: var(--primary); text-transform: uppercase;
            letter-spacing: 0.5px; margin-bottom: 8px;
        }
        .lp-section-label svg { width: 12px; height: 12px; stroke-width: 2.5; }
        .lp-section-title {
            font-size: 20px; font-weight: 800; margin-bottom: 8px;
            color: var(--text-main);
        }
        .lp-section-desc {
            font-size: 13px; color: var(--text-muted);
            line-height: 1.6; margin-bottom: 14px;
        }
        .lp-map-thumb { position: relative; margin-bottom: 14px; }
        .lp-map-overlay {
            position: absolute; inset: 0; border-radius: 14px;
            background: rgba(11,17,30,0.55);
            display: flex; align-items: center; justify-content: center;
            backdrop-filter: blur(2px);
        }
        .lp-map-cta {
            background: var(--primary); color: white; border: none;
            padding: 10px 18px; border-radius: 10px;
            font-size: 13px; font-weight: 800;
            display: flex; align-items: center; gap: 7px;
            cursor: pointer;
        }
        .lp-map-cta svg { width: 15px; height: 15px; stroke-width: 2.5; }
        .lp-feature-pills { display: flex; gap: 8px; flex-wrap: wrap; }
        .lp-pill {
            display: flex; align-items: center; gap: 5px;
            background: var(--bg-card); border: 1px solid var(--border);
            border-radius: 20px; padding: 5px 12px;
            font-size: 12px; font-weight: 700; color: var(--text-muted);
        }
        .lp-pill i, .lp-pill svg { font-size: 13px; color: var(--primary); }
        .lp-pill svg { width: 13px; height: 13px; stroke-width: 2.5; }

        /* -- Merchant Section -- */
        .lp-merchant-section { padding: 0 20px 28px; }
        .lp-merchant-bg {
            background: linear-gradient(135deg,
                rgba(2,102,128,0.1) 0%,
                rgba(0,234,159,0.05) 100%);
            border: 1px solid rgba(2,102,128,0.2);
            border-radius: 16px; padding: 20px;
        }
        .lp-benefits { display: flex; flex-direction: column; gap: 14px; margin: 16px 0; }
        .lp-benefit {
            display: flex; align-items: flex-start; gap: 12px;
            text-align: left;
        }
        .lp-benefit-icon {
            width: 38px; height: 38px; border-radius: 10px;
            display: flex; align-items: center; justify-content: center;
            flex-shrink: 0;
        }
        .lp-benefit-icon i, .lp-benefit-icon svg { font-size: 18px; }
        .lp-benefit-icon svg { width: 20px; height: 20px; stroke-width: 2; }
        .lp-benefit-title { font-size: 13px; font-weight: 700; margin-bottom: 2px; color: var(--text-main); }
        .lp-benefit-desc  { font-size: 11px; color: var(--text-muted); line-height: 1.4; }
        .lp-ranking-note {
            display: flex; align-items: flex-start; gap: 8px;
            background: rgba(0,234,159,0.06);
            border: 1px solid rgba(0,234,159,0.15);
            border-radius: 10px; padding: 10px 12px;
            font-size: 11px; color: var(--text-muted); line-height: 1.5;
            text-align: left;
        }
        .lp-ranking-note i, .lp-ranking-note svg { flex-shrink: 0; margin-top: 1px; }
        .lp-ranking-note svg { width: 14px; height: 14px; stroke-width: 2; }

        /* -- Live Price Ticker -- */
        .lp-ticker-wrap { padding: 0 20px 22px; }
        .lp-ticker-title { font-size: 12px; font-weight: 700; color: var(--text-muted); margin-bottom: 9px; text-transform: uppercase; letter-spacing: 0.5px; }
        .lp-ticker-scroll { display: flex; gap: 9px; overflow-x: auto; padding-bottom: 3px; scrollbar-width: none; }
        .lp-ticker-scroll::-webkit-scrollbar { display: none; }
        .lp-ticker-card { flex-shrink: 0; background: var(--bg-card); border: 1px solid var(--border); border-radius: 11px; padding: 11px 14px; min-width: 120px; }
        .lp-ticker-card-pi { border: 1px solid rgba(0, 234, 159, 0.3); background: linear-gradient(135deg, var(--bg-card), rgba(0, 234, 159, 0.04)); }
        .lp-ticker-name  { font-size: 12px; font-weight: 700; margin-bottom: 3px; }
        .lp-ticker-price { font-size: 14px; font-weight: 800; }
        .lp-ticker-change{ font-size: 11px; font-weight: 700; margin-top: 2px; }
        .change-up   { color: var(--success); }
        .change-down { color: var(--danger); }
        .change-flat { color: var(--text-muted); }

        /* -- Quick Converter Widget (v1.8.7) -- */
        .lp-quick-converter {
            margin-top: 15px; background: var(--bg-card); border: 1px solid var(--border);
            border-radius: 12px; padding: 14px 16px; text-align: left;
        }
        .qc-label { font-size: 12px; font-weight: 700; color: var(--text-muted); margin-bottom: 8px; text-transform: uppercase; letter-spacing: 0.5px; }
        .qc-row { display: flex; align-items: center; gap: 10px; }
        .qc-input-group, .qc-result-group {
            flex: 1; display: flex; align-items: center; background: rgba(0, 0, 0, 0.2);
            border: 1px solid var(--border); border-radius: 8px; padding: 6px 10px; height: 38px;
        }
        .qc-pi-icon { font-size: 16px; font-weight: 700; color: var(--primary); margin-right: 6px; }
        .qc-input {
            width: 100%; background: transparent; border: none; outline: none;
            color: var(--text); font-family: 'Outfit', sans-serif; font-size: 14px; font-weight: 600;
        }
        .qc-input::placeholder { color: var(--text-muted); }
        .qc-eq { font-size: 16px; font-weight: 700; color: var(--text-muted); }
        .qc-result { font-size: 14px; font-weight: 700; color: var(--success); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
        .qc-select {
            background: transparent; border: none; outline: none; color: var(--text);
            font-family: 'Outfit', sans-serif; font-size: 13px; font-weight: 700; cursor: pointer;
            margin-left: auto; padding-left: 5px;
        }
        .qc-select option { background: var(--bg-card); color: var(--text); }
        .qc-disclaimer { font-size: 9px; color: var(--text-muted); margin-top: 8px; text-align: center; }

        /* -- Header Pi Rate Badge (v1.8.7) -- */
        .pi-rate-badge {
            font-size: 11px; font-weight: 700; padding: 4px 8px; border-radius: 20px;
            background: rgba(255, 255, 255, 0.05); border: 1px solid var(--border);
            display: inline-flex; align-items: center; justify-content: center;
            height: 24px; white-space: nowrap; font-family: 'Outfit', sans-serif;
            transition: all 0.3s ease; margin-right: 6px;
        }
        .pi-rate-badge.rate-up { color: var(--success); border-color: rgba(0, 234, 159, 0.25); background: rgba(0, 234, 159, 0.04); }
        .pi-rate-badge.rate-down { color: var(--danger); border-color: rgba(255, 75, 75, 0.25); background: rgba(255, 75, 75, 0.04); }


        /* -- Trust Bar -- */
        .lp-trust-bar {
            display: flex; align-items: center; justify-content: center;
            gap: 12px; padding: 16px 20px;
            border-top: 1px solid var(--border);
            margin: 0 0 8px;
        }
        .lp-trust-item {
            display: flex; align-items: center; gap: 5px;
            font-size: 11px; font-weight: 700; color: var(--text-muted);
        }
        .lp-trust-item i, .lp-trust-item svg { font-size: 14px; color: var(--primary); }
        .lp-trust-item svg { width: 14px; height: 14px; stroke-width: 2.5; }
        .lp-trust-divider {
            width: 1px; height: 14px;
            background: var(--border);
        }

        /* -- Footer -- */
        .lp-footer { text-align: center; padding: 18px; font-size: 12px; color: var(--text-muted); border-top: 1px solid var(--border); }

        /* -- Fade-out khi chuyển sang Dashboard -- */
        @keyframes fadeOut { to { opacity: 0; transform: translateY(-8px); } }
        .fade-out { animation: fadeOut 0.4s ease forwards; }


        /* ============================================================
           SECTION 4 — APP SHELL (Header, Sidebar, Bottom Nav)
           Bố cục khung chính của Dashboard sau khi đăng nhập.
           - Sidebar chỉ hiện trên Desktop (≥1024px)
           - Bottom Nav chỉ hiện trên Mobile
        ============================================================ */
        #pioneer-app-container, #merchant-app-container, #admin-app-container {
            height: 100%;
            width: 100%;
        }

        #app-wrapper {
            display: none; flex-direction: row; width: 100%;
            height: 100%; max-width: 430px; margin: 0 auto;
            background: var(--bg-dark); position: relative; overflow: hidden;
        }

        /* Desktop Sidebar */
        .sidebar-pc { width: 210px; background: var(--bg-card); border-right: 1px solid var(--border); padding: 18px 13px; flex-direction: column; justify-content: space-between; height: 100%; z-index: 10; display: none; }
        @media (min-width: 1024px) {
            body { max-width: 100%; }
            #app-wrapper { max-width: 100%; }
            .sidebar-pc { display: flex; }
            .nav-bar-mobile { display: none !important; }
            .header-logo-mobile { display: none !important; }
        }
        .sidebar-logo { font-size: 18px; font-weight: 800; color: var(--text-main); display: flex; align-items: center; gap: 9px; margin-bottom: 24px; padding-left: 5px; }
        .sidebar-logo img { height: 28px; width: 28px; border-radius: 7px; background: transparent; object-fit: contain; }
        .sidebar-menu { display: flex; flex-direction: column; gap: 3px; }
        .sidebar-item { display: flex; align-items: center; gap: 9px; padding: 11px 13px; border-radius: 9px; color: var(--text-muted); font-size: 13px; font-weight: 600; cursor: pointer; transition: all 0.2s; }
        .sidebar-item:hover, .sidebar-item.active { color: var(--text-main); background: rgba(2,102,128,0.15); box-shadow: inset 3px 0 0 var(--primary); }
        .sidebar-item svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2; }

        /* App Header */
        .main-container { flex: 1; display: flex; flex-direction: column; height: 100%; overflow: hidden; background: radial-gradient(circle at 50% 0%, var(--bg-card) 0%, var(--bg-dark) 100%); position: relative; }
        .app-header { padding: 13px 16px; display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--border); background: var(--bg-card); box-shadow: var(--shadow); backdrop-filter: blur(10px); z-index: 10; flex-shrink: 0; }
        .header-logo-mobile { display: flex; align-items: center; gap: 7px; font-size: 17px; font-weight: 800; }
        .header-logo-mobile img { height: 24px; width: 24px; border-radius: 6px; background: transparent; object-fit: contain; }
        .header-right { display: flex; align-items: center; gap: 8px; }
        .location-badge { background: rgba(255,255,255,0.05); padding: 5px 11px; border-radius: 16px; font-size: 11px; font-weight: 600; border: 1px solid var(--border); }
        .user-profile-badge { background: var(--primary-glow); padding: 5px 11px; border-radius: 16px; font-size: 11px; font-weight: 700; border: 1px solid var(--primary); }

        /* Tab Content Area */
        .app-content { flex: 1; overflow-y: auto; padding: 14px; padding-bottom: 85px; display: none; -webkit-overflow-scrolling: touch; }
        .app-content.active { display: block; }

        /* Mobile Bottom Navigation */
        .nav-bar-mobile {
            position: absolute; bottom: 0; left: 0; right: 0;
            height: calc(62px + var(--safe-bottom)); padding-bottom: var(--safe-bottom);
            background: var(--bg-card); border-top: 1px solid var(--border);
            box-shadow: var(--shadow); display: flex; justify-content: space-around;
            align-items: center; z-index: 80;
        }
        .nav-item { display: flex; flex-direction: column; align-items: center; gap: 3px; color: var(--text-muted); cursor: pointer; font-size: 10px; font-weight: 600; padding: 5px 8px; border-radius: 9px; transition: all 0.2s; flex: 1; position: relative; }
        .nav-item.active { color: var(--primary); }
        .nav-item svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; }
        /* Vạch chỉ báo active trên Bottom Nav */
        .nav-item.active::before { content: ''; position: absolute; top: -1px; left: 50%; transform: translateX(-50%); width: 22px; height: 3px; background: var(--primary); border-radius: 0 0 4px 4px; box-shadow: 0 0 8px var(--primary-glow); }

        /* Empty States */
        .empty-state { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px 20px; text-align: center; gap: 10px; }
        .empty-state-icon { font-size: 40px; opacity: 0.5; }
        .empty-state-title { font-size: 14px; font-weight: 700; color: var(--text-main); }
        .empty-state-desc  { font-size: 12px; color: var(--text-muted); line-height: 1.5; }

        /* Skeleton Shimmer Loading */
        .skeleton { background: linear-gradient(90deg, var(--bg-card) 25%, rgba(255,255,255,0.06) 50%, var(--bg-card) 75%); background-size: 200% 100%; animation: shimmer 1.5s infinite; border-radius: 10px; }
        @keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
        .skeleton-card { height: 72px; margin-bottom: 10px; }
        .skeleton-map  { height: 250px; margin-bottom: 16px; border-radius: 14px; }

        /* Logo Fallback — khi pipay_logo.png lỗi */
        .logo-fallback { display: inline-flex; width: 28px; height: 28px; background: var(--primary); border-radius: 7px; align-items: center; justify-content: center; font-size: 16px; font-weight: 900; color: var(--secondary); font-style: italic; }

        /* Horizontal scroll for Recent Merchants on Home tab */
        .merchant-recent-scroll { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 5px; scrollbar-width: none; }
        .merchant-recent-scroll::-webkit-scrollbar { display: none; }
        .recent-merchant-card { flex-shrink: 0; background: var(--card-bg); border: 1px solid var(--border); border-radius: 14px; padding: 12px 10px 14px; width: 110px; text-align: center; cursor: pointer; transition: all 0.2s cubic-bezier(0.16,1,0.3,1); }
        .recent-merchant-card:hover { border-color: var(--primary); transform: translateY(-1px); background: var(--bg-card); }
        .recent-merchant-icon { display: flex; align-items: center; justify-content: center; height: 32px; margin-bottom: 8px; color: var(--primary); }
        .recent-merchant-icon i { width: 22px; height: 22px; stroke-width: 2.2; }
        .recent-merchant-name { font-size: 12px; font-weight: 700; color: var(--text-main); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
        .recent-merchant-dist { font-size: 10px; color: var(--text-muted); margin-top: 3px; }

        /* Pull-to-refresh Visual Spinner */
        .ptr-spinner {
            display: flex; justify-content: center; align-items: center;
            height: 0; overflow: hidden; transition: height 0.2s ease, margin 0.2s ease;
            background: transparent; width: 100%;
        }
        .ptr-spinner.active { height: 40px; margin-top: 5px; margin-bottom: 5px; }
        .spinner-circle {
            width: 20px; height: 20px;
            border: 2px solid rgba(255,255,255,0.1);
            border-top-color: var(--primary);
            border-radius: 50%;
            animation: spin 0.8s linear infinite;
        }


        /* ============================================================
           SECTION 5 — TAB CONTENT
           Styles cho từng màn hình (tab) bên trong Dashboard.
        ============================================================ */

        /* -- Shared Components -- */
        .section-title { font-size: 15px; font-weight: 800; margin-bottom: 12px; letter-spacing: -0.3px; }

        /* -- Tab: Shops (Danh sách cửa hàng) -- */
        .app-promo-slider {
            background: linear-gradient(135deg, var(--primary) 0%, var(--bg-card) 100%);
            border-radius: 16px;
            margin-bottom: 6px;
            border: 1px solid rgba(255,255,255,0.1);
            position: relative;
            overflow: hidden;
            min-height: 125px;
        }
        .app-promo-slide {
            position: absolute;
            inset: 16px;
            opacity: 0;
            pointer-events: none;
            transition: opacity 0.4s ease-in-out;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }
        .app-promo-slide.active {
            opacity: 1;
            pointer-events: auto;
            position: relative;
            inset: 0;
            padding: 16px;
        }
        .app-promo-slide h3 {
            font-weight: 800;
            font-size: 14px;
            margin-top: 6px;
            margin-bottom: 3px;
        }
        .app-promo-slide p {
            font-size: 11px;
            color: rgba(255,255,255,0.8);
            line-height: 1.4;
            max-width: 220px;
        }
        .promo-badge {
            background: rgba(255,255,255,0.12);
            color: var(--accent);
            padding: 4px 9px;
            border-radius: 7px;
            font-weight: 800;
            font-size: 10px;
            display: inline-flex;
            align-items: center;
            gap: 5px;
            width: fit-content;
        }
        .promo-badge i {
            font-size: 12px;
            stroke-width: 2.5;
        }
        .banner-cta {
            display: inline-flex;
            align-items: center;
            gap: 4px;
            margin-top: 8px;
            padding: 6px 14px;
            background: var(--primary);
            color: white;
            border: none;
            border-radius: 8px;
            font-size: 12px;
            font-weight: 700;
            cursor: pointer;
            transition: opacity 0.15s;
        }
        .banner-cta:hover { opacity: 0.85; }
        .promo-hot-badge {
            background: var(--accent); /* #00ea9f brand */
            color: #000;
            font-weight: 800;
            font-size: 10px;
            padding: 3px 9px;
            border-radius: 6px;
            align-self: flex-start;
        }
        .banner-dots {
            display: flex;
            justify-content: center;
            gap: 6px;
            margin-top: 6px;
            margin-bottom: 16px;
        }
        .banner-dot {
            width: 6px; height: 6px;
            border-radius: 50%;
            background: var(--border);
            transition: all 0.2s;
        }
        .banner-dot.active {
            width: 18px;
            border-radius: 3px;
            background: var(--primary);
        }

        .quick-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 18px; }
        .action-button-card { background: var(--card-bg); border: 1px solid var(--border); border-radius: 14px; padding: 14px; text-align: center; cursor: pointer; transition: all 0.2s; display: flex; flex-direction: column; align-items: center; gap: 7px; }
        .action-button-card:hover { border-color: var(--primary); background: var(--card-hover); transform: translateY(-2px); }
        .action-icon-circle { width: 42px; height: 42px; border-radius: 50%; background: rgba(2,102,128,0.15); display: flex; justify-content: center; align-items: center; color: var(--primary); }
        .action-icon-circle svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 2; }

        /* --- Search + Filter Chips --- */
        .shop-search-wrap { position: relative; margin-bottom: 11px; }
        .shop-search-input { width: 100%; background: var(--card-bg); border: 1px solid var(--border); border-radius: 11px; padding: 10px 12px 10px 36px; font-size: 13px; color: var(--text-main); outline: none; transition: border-color 0.2s; }
        .shop-search-input:focus { border-color: var(--primary); }
        .shop-search-icon { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--text-muted); pointer-events: none; }
        .shop-filter-row { display: flex; gap: 7px; overflow-x: auto; padding-bottom: 6px; margin-bottom: 11px; scrollbar-width: none; }
        .shop-filter-row::-webkit-scrollbar { display: none; }
        .filter-chip {
            flex-shrink: 0;
            display: flex; align-items: center; gap: 5px;
            background: var(--card-bg);
            border: 1px solid var(--border);
            border-radius: 20px;
            padding: 5px 12px;
            font-size: 12px; font-weight: 600;
            color: var(--text-muted);
            cursor: pointer;
            transition: all 0.18s ease;
            white-space: nowrap;
            user-select: none;
        }
        .filter-chip i { width: 13px; height: 13px; flex-shrink: 0; stroke: currentColor; stroke-width: 2.2; }
        .filter-chip:hover { border-color: var(--primary); color: var(--primary); background: rgba(2,102,128,0.08); }
        .filter-chip.active { background: var(--primary); border-color: var(--primary); color: white; }
        .filter-chip.active i { stroke: white; }
        .shop-sort-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
        .shop-sort-label { font-size: 11px; color: var(--text-muted); }
        .shop-sort-btns { display: flex; gap: 5px; }
        .sort-btn { background: var(--card-bg); border: 1px solid var(--border); border-radius: 7px; padding: 4px 10px; font-size: 11px; font-weight: 600; color: var(--text-muted); cursor: pointer; transition: all 0.15s; }
        .sort-btn.active { background: rgba(2,102,128,0.2); border-color: var(--primary); color: var(--primary); }

        /* --- Shop Card nâng cấp --- */
        .shop-list-vertical { display: flex; flex-direction: column; gap: 10px; }
        .shop-card { background: var(--card-bg); border-radius: 14px; padding: 13px; border: 1px solid var(--border); display: flex; gap: 12px; align-items: center; cursor: pointer; transition: all 0.2s; position: relative; }
        .shop-card:hover { border-color: var(--primary); background: var(--card-hover); }
        .shop-img { width: 52px; height: 52px; border-radius: 10px; background: #151a2e; display: flex; justify-content: center; align-items: center; font-size: 22px; border: 1px solid var(--border); overflow: hidden; flex-shrink: 0; }
        .shop-img img { width: 100%; height: 100%; object-fit: cover; }
        .shop-img i { width: 22px; height: 22px; stroke: var(--primary); stroke-width: 2.2; }
        .shop-name { font-size: 14px; font-weight: 700; margin-bottom: 3px; }
        .shop-meta { font-size: 11px; color: var(--text-muted); display: flex; gap: 7px; align-items: center; flex-wrap: wrap; }
        .shop-rating-badge { color: var(--secondary); font-weight: 700; display: inline-flex; align-items: center; gap: 3px; }
        .shop-open-badge  { background: rgba(16,185,129,0.15); color: #10b981; border: 1px solid rgba(16,185,129,0.3); border-radius: 5px; padding: 1px 6px; font-size: 10px; font-weight: 700; }
        .shop-closed-badge { background: rgba(239,68,68,0.12); color: #ef4444; border: 1px solid rgba(239,68,68,0.25); border-radius: 5px; padding: 1px 6px; font-size: 10px; font-weight: 700; }
        .shop-card-actions { display: flex; gap: 6px; margin-left: auto; flex-shrink: 0; align-items: center; }
        .shop-action-btn { background: rgba(255,255,255,0.05); border: 1px solid var(--border); border-radius: 8px; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: all 0.15s; color: var(--text-muted); }
        .shop-action-btn:hover { background: rgba(255,255,255,0.1); border-color: var(--primary); color: var(--text-main); }
        .shop-action-btn svg { width: 15px; height: 15px; stroke: currentColor; fill: none; stroke-width: 2.2; }
        .shop-action-btn.fav-active { background: rgba(239,68,68,0.15); border-color: rgba(239,68,68,0.35); color: var(--secondary); }
        .shop-action-btn.fav-active svg { fill: var(--secondary); }

        /* Leaflet Map Customization */
        #shops-map {
            width: 100%;
            height: 250px;
            border-radius: 14px;
            border: 1px solid var(--border);
            margin-bottom: 16px;
            z-index: 1;
            overflow: hidden;
            box-shadow: var(--shadow);
            transition: filter 0.3s ease;
        }
        .leaflet-container {
            background: var(--bg-card) !important;
        }
        /* Map tile filter cho dark mode */
        body:not(.light-mode) .leaflet-tile-container {
            filter: invert(100%) hue-rotate(180deg) brightness(95%) contrast(90%);
        }
        .leaflet-popup-content-wrapper {
            background: var(--bg-card) !important;
            color: var(--text-main) !important;
            border: 1px solid var(--border);
            border-radius: 10px;
            box-shadow: var(--shadow-menu);
        }
        .leaflet-popup-tip {
            background: var(--bg-card) !important;
            border: 1px solid var(--border);
        }

        /* -- Tab: Wallet Card -- */
        .wallet-card-container {
            background: linear-gradient(135deg, var(--primary-dark) 0%, #064050 100%);
            color: #ffffff;
            border-radius: 18px;
            padding: 18px 20px 14px;
            border: 1px solid rgba(255, 255, 255, 0.12);
            margin-bottom: 16px;
            box-shadow: 0 8px 32px rgba(2, 102, 128, 0.25);
        }
        /* Dòng 1: Badge + Địa chỉ ví */
        .wallet-card-row-1 {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 10px;
        }
        .wallet-verified-badge {
            display: inline-flex;
            align-items: center;
            gap: 5px;
            font-size: 10.5px;
            font-weight: 700;
            padding: 3px 9px;
            border-radius: 20px;
            letter-spacing: 0.3px;
        }
        .wallet-verified-badge.verified {
            background: rgba(34, 197, 94, 0.18);
            color: #4ade80;
            border: 1px solid rgba(74, 222, 128, 0.3);
        }
        .wallet-verified-badge.sandbox {
            background: rgba(250, 204, 21, 0.15);
            color: #fde047;
            border: 1px solid rgba(253, 224, 71, 0.25);
        }
        .badge-dot {
            width: 6px; height: 6px; border-radius: 50%;
            background: currentColor;
            animation: pulse-dot 2s infinite;
        }
        @keyframes pulse-dot {
            0%, 100% { opacity: 1; } 50% { opacity: 0.4; }
        }
        .wallet-addr-capsule {
            display: inline-flex;
            align-items: center;
            gap: 5px;
            font-size: 11px;
            background: rgba(255,255,255,0.1);
            padding: 3px 9px;
            border-radius: 20px;
            cursor: pointer;
            color: rgba(255,255,255,0.85);
            border: 1px solid rgba(255,255,255,0.12);
            transition: background 0.2s;
        }
        .wallet-addr-capsule:hover { background: rgba(255,255,255,0.18); }
        /* Dòng 2: Số Pi + Quy đổi / Chi tiêu */
        .wallet-card-row-2 {
            display: flex;
            justify-content: space-between;
            align-items: flex-end;
            margin-bottom: 12px;
        }
        .wallet-balance-left { display: flex; flex-direction: column; }
        .wallet-balance-value { font-size: 36px; font-weight: 800; letter-spacing: -1.5px; color: #ffffff; line-height: 1; }
        .wallet-balance-converted {
            font-size: 12px;
            color: rgba(255,255,255,0.6);
            margin-top: 4px;
            font-weight: 500;
            letter-spacing: 0.1px;
        }
        .wallet-spend-right { text-align: right; }
        .spend-row { font-size: 10px; color: rgba(255,255,255,0.55); line-height: 1.2; }
        .spend-val-big { font-size: 13px; font-weight: 700; color: #ffffff; line-height: 1.3; }
        /* Dòng 3: Tỷ giá OKX footer */
        .wallet-card-row-3 {
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding-top: 10px;
            border-top: 1px solid rgba(255,255,255,0.08);
        }
        .card-pi-rate-text {
            font-size: 10.5px;
            color: rgba(255,255,255,0.55);
            display: flex;
            align-items: center;
        }
        .card-pi-change-badge {
            font-size: 10px;
            font-weight: 700;
            padding: 2px 7px;
            border-radius: 10px;
        }
        .card-pi-change-badge.up   { background: rgba(34,197,94,0.18); color: #4ade80; }
        .card-pi-change-badge.down { background: rgba(239,68,68,0.18);  color: #f87171; }
        .card-pi-change-badge.neutral { background: rgba(255,255,255,0.1); color: rgba(255,255,255,0.5); }

        /* Shortcut Buttons trong thẻ Ví */
        .wallet-shortcuts { display: flex; gap: 10px; margin-top: 14px; }
        .shortcut-btn { flex: 1; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.12); border-radius: 12px; padding: 10px 6px; display: flex; flex-direction: column; align-items: center; gap: 5px; cursor: pointer; transition: all 0.2s; }
        .shortcut-btn:hover { background: rgba(2,102,128,0.25); border-color: var(--primary); }
        .shortcut-btn span:first-child { font-size: 20px; }
        .shortcut-btn span:last-child  { font-size: 11px; font-weight: 700; color: var(--text-muted); }
        .chart-card { background: var(--card-bg); border: 1px solid var(--border); border-radius: 16px; padding: 16px; }

        /* Bento Grid Quick Actions */
        .quick-actions-row {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 10px;
            margin-bottom: 16px;
        }
        .qa-item {
            background: var(--card-bg);
            border: 1px solid var(--border);
            border-radius: 14px;
            padding: 12px 14px 14px;
            display: flex;
            flex-direction: row;
            align-items: center;
            gap: 12px;
            cursor: pointer;
            transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
            position: relative;
            overflow: hidden;
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
        }
        .qa-item:hover {
            border-color: rgba(2, 102, 128, 0.4);
            transform: translateY(-1px);
            background: var(--bg-card);
        }
        .qa-icon {
            width: 38px; height: 38px;
            border-radius: 10px;
            display: flex; align-items: center; justify-content: center;
            flex-shrink: 0;
        }
        .qa-icon i {
            width: 18px; height: 18px;
            stroke: currentColor;
            stroke-width: 2.2;
        }
        .qa-item:active {
            transform: scale(0.97);
        }
        .qa-item span {
            font-size: 12px;
            font-weight: 800;
            color: var(--text-main);
            text-align: left;
            white-space: nowrap;
        }

        /* Language Selector (FIX 1) */
        .lang-selector { display: flex; gap: 8px; margin-bottom: 14px; }
        .lang-btn {
            flex: 1; padding: 10px; border-radius: 10px;
            border: 1px solid var(--border);
            background: var(--card-bg); color: var(--text-muted);
            font-size: 13px; font-weight: 700; cursor: pointer;
            transition: all 0.2s;
        }
        .lang-btn.active {
            background: rgba(2,102,128,0.15);
            border-color: var(--primary);
            color: var(--primary);
        }

        /* -- Tab: Scan (QR Quét / Nhận) -- */
        .qr-tab-container { text-align: center; }
        .market-toggle { display: flex; background: rgba(255,255,255,0.03); border: 1px solid var(--border); border-radius: 11px; padding: 4px; margin-bottom: 16px; }
        .market-toggle-btn { flex: 1; background: transparent; border: none; color: var(--text-muted); padding: 9px; border-radius: 8px; font-size: 13px; font-weight: 700; cursor: pointer; transition: all 0.2s; }
        .market-toggle-btn.active { background: var(--primary); color: white; }
        .qr-scanner-box { width: 100%; height: 220px; background: #090d16; border: 2px dashed rgba(255,255,255,0.15); border-radius: 14px; display: flex; justify-content: center; align-items: center; position: relative; overflow: hidden; margin-bottom: 11px; }
        .scanner-laser { position: absolute; width: 85%; height: 2px; background: var(--primary); box-shadow: 0 0 8px var(--primary); animation: scanLaser 2s infinite linear; }
        @keyframes scanLaser { 0%{top:10%} 50%{top:88%} 100%{top:10%} }
        .qr-receive-card { background: var(--card-bg); padding: 18px; border-radius: 16px; border: 1px solid var(--border); display: flex; flex-direction: column; align-items: center; gap: 11px; }
        .qr-canvas-holder { background: white; padding: 9px; border-radius: 11px; display: inline-block; }

        /* -- Tab: Market (Sản phẩm & Đồ ăn) -- */
        .grid-container { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
        .product-card { background: var(--card-bg); border: 1px solid var(--border); border-radius: 14px; padding: 11px; text-align: center; display: flex; flex-direction: column; justify-content: space-between; min-height: 200px; transition: all 0.2s; }
        .product-card:hover { transform: translateY(-2px); border-color: var(--primary); }
        .product-img   { width: 100%; height: 72px; background: rgba(255,255,255,0.02); border-radius: 9px; margin-bottom: 9px; display: flex; justify-content: center; align-items: center; font-size: 32px; }
        .product-name  { font-size: 12px; font-weight: 600; margin-bottom: 5px; }
        .product-price { color: var(--secondary); font-weight: 800; font-size: 13px; }

        /* -- Tab: Profile (Hồ sơ & Cài đặt) -- */
                .profile-card {
            background: linear-gradient(135deg, var(--primary-dark) 0%, #064050 100%);
            color: #ffffff;
            border-radius: 16px;
            padding: 18px;
            border: 1px solid rgba(255, 255, 255, 0.12);
            display: flex;
            align-items: center;
            gap: 14px;
            margin-bottom: 18px;
            box-shadow: 0 8px 24px rgba(2, 102, 128, 0.12);
        }
        .profile-avatar { width: 50px; height: 50px; border-radius: 50%; background: rgba(255,255,255,0.1); display: flex; justify-content: center; align-items: center; font-size: 26px; }
        .profile-tier { font-size: 10px; background: var(--secondary); color: #000; padding: 2px 7px; border-radius: 5px; font-weight: 800; display: inline-block; margin-top: 3px; }
        .settings-list { display: flex; flex-direction: column; gap: 9px; }
        .settings-item { background: var(--card-bg); padding: 13px 15px; border-radius: 12px; border: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; cursor: pointer; transition: all 0.2s; }
        .settings-item:hover { border-color: var(--primary); background: var(--card-hover); }
        .settings-item-title { font-weight: 600; font-size: 13px; }
        .settings-item-desc  { font-size: 11px; color: var(--text-muted); margin-top: 3px; }


        /* ============================================================
           SECTION 6 — OVERLAYS (Cart Bar, Menu Modal, Modals, AI Chat, Toast)
           Tất cả các lớp nổi phía trên app (z-index > 80)
        ============================================================ */

        /* Cart Bar — Thanh giỏ hàng nổi khi có món */
        .cart-bar {
            position: absolute; bottom: 72px; left: 12px; right: 12px;
            background: linear-gradient(135deg, #10b981 0%, #059669 100%);
            border-radius: 13px; padding: 11px 15px;
            display: flex; justify-content: space-between; align-items: center;
            z-index: 90; box-shadow: 0 5px 18px rgba(16,185,129,0.35);
            transform: translateY(200%); opacity: 0; pointer-events: none;
            transition: transform 0.3s cubic-bezier(0.16,1,0.3,1), opacity 0.3s ease; cursor: pointer;
        }
        .cart-bar.active { transform: translateY(0); opacity: 1; pointer-events: auto; }
        .checkout-btn { background: white; color: #047857; border: none; padding: 6px 12px; border-radius: 8px; font-weight: 800; font-size: 11px; }

        /* Menu Modal — Thực đơn cửa hàng thiết kế mới cực xịn */
        .menu-modal { position: absolute; bottom: -100%; left: 0; width: 100%; height: 78%; background: var(--bg-card); border-radius: 18px 18px 0 0; box-shadow: var(--shadow-menu); transition: bottom 0.3s ease-in-out; z-index: 100; padding: 18px; display: flex; flex-direction: column; border-top: 1px solid var(--border); }
        .menu-modal.active { bottom: 0; }
        .menu-list { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 9px; margin-top: 11px; }
        
        .menu-item {
            background: var(--bg-card);
            padding: 12px;
            border-radius: 14px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            border: 1px solid var(--border);
            gap: 12px;
            margin-bottom: 4px;
            transition: transform 0.2s ease, border-color 0.2s ease;
        }
        .menu-item:hover {
            border-color: rgba(0, 234, 159, 0.25);
        }
        .menu-item-info {
            flex: 1;
            display: flex;
            flex-direction: column;
            text-align: left;
        }
        .menu-item-title {
            font-size: 13px;
            font-weight: 700;
            color: var(--text-main);
            margin-bottom: 3px;
        }
        .menu-item-desc {
            font-size: 10.5px;
            color: var(--text-muted);
            line-height: 1.45;
            margin-bottom: 6px;
            display: -webkit-box;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
            overflow: hidden;
        }
        .menu-item-price {
            font-size: 12px;
            font-weight: 800;
            color: var(--secondary);
        }
        .menu-item-img-wrap {
            position: relative;
            width: 72px;
            height: 72px;
            flex-shrink: 0;
            border-radius: 10px;
            overflow: hidden;
            background: var(--bg-dark);
            border: 1px solid var(--border);
        }
        .menu-item-img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            transition: transform 0.3s ease;
        }
        .menu-item:hover .menu-item-img {
            transform: scale(1.08);
        }
        
        /* Bộ số lượng đè lên ảnh gọn gàng */
        .menu-qty-control {
            position: absolute;
            bottom: 3px;
            left: 50%;
            transform: translateX(-50%);
            background: rgba(11, 17, 30, 0.82) !important;
            border: 1px solid rgba(255,255,255,0.18) !important;
            padding: 1px 3px !important;
            border-radius: 5px !important;
            display: flex;
            align-items: center;
            gap: 4px;
            backdrop-filter: blur(4px);
            width: 82%;
            justify-content: space-between;
        }
        .menu-qty-control .qty-btn {
            width: 15px;
            height: 15px;
            font-size: 10px;
            border-radius: 3px;
            display: flex;
            align-items: center;
            justify-content: center;
            background: var(--primary);
            color: white;
            border: none;
            cursor: pointer;
            font-weight: 800;
        }
        .menu-qty-control span {
            font-size: 10px;
            color: white !important;
            min-width: 10px;
            font-weight: 700;
            text-align: center;
        }

        /* Generic Popup Modal (Transfer, Onboarding) */
        .modal-popup { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.75); z-index: 120; display: none; justify-content: center; align-items: center; padding: 14px; }
        .modal-popup-content { background: var(--bg-card); border: 1px solid var(--border); border-radius: 16px; padding: 18px; width: 100%; max-width: 370px; display: flex; flex-direction: column; gap: 10px; box-shadow: var(--shadow-menu); }
        .form-input { width: 100%; background: var(--bg-dark); border: 1px solid var(--border); border-radius: 9px; padding: 11px; font-size: 13px; outline: none; color: var(--text-main); transition: all 0.2s; }
        .form-input:focus { border-color: var(--primary); background: var(--bg-card); }
        .form-btn-group  { display: flex; gap: 7px; margin-top: 5px; }
        .form-btn-cancel { flex: 1; background: var(--bg-dark); border: 1px solid var(--border); color: var(--text-main); padding: 10px; border-radius: 8px; cursor: pointer; font-weight: 700; font-size: 13px; }
        .form-btn-save   { flex: 1; background: var(--primary); border: none; color: white; padding: 10px; border-radius: 8px; cursor: pointer; font-weight: 700; font-size: 13px; }

        /* Receipt Modal — Thiết kế hóa đơn răng cưa gấp nếp Glassmorphism cổ điển */
        .receipt-modal { 
            position: absolute; 
            bottom: 0; 
            left: 0; 
            width: 100%; 
            background: var(--bg-card); 
            border-radius: 22px 22px 0 0; 
            border-top: 1px solid var(--border); 
            box-shadow: 0 -8px 30px rgba(0,0,0,0.45); 
            z-index: 130; 
            padding: 24px 18px 28px; 
            transform: translateY(calc(100% + 15px)); 
            transition: transform 0.35s cubic-bezier(0.16,1,0.3,1); 
            display: flex; 
            flex-direction: column; 
            gap: 12px; 
            backdrop-filter: blur(16px);
        }
        .receipt-modal.active { transform: translateY(0); }
        
        /* Viền răng cưa hóa đơn */
        .receipt-modal::before {
            content: "";
            position: absolute;
            top: -9px;
            left: 0;
            width: 100%;
            height: 10px;
            background-image: 
                linear-gradient(135deg, var(--bg-card) 25%, transparent 25%), 
                linear-gradient(225deg, var(--bg-card) 25%, transparent 25%);
            background-position: 0 0;
            background-size: 14px 20px;
            background-repeat: repeat-x;
            filter: drop-shadow(0 -3px 3px rgba(0,0,0,0.12));
        }
        
        .receipt-header { text-align: center; }
        .receipt-check  { width: 46px; height: 46px; background: rgba(16,185,129,0.15); border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 8px; font-size: 22px; }
        .receipt-title  { font-size: 16px; font-weight: 800; margin-bottom: 2px; }
        .receipt-sub    { font-size: 11px; color: var(--text-muted); }
        .receipt-divider { border: none; border-top: 1.5px dashed var(--border); margin: 2px 0; }
        .receipt-row    { display: flex; justify-content: space-between; align-items: baseline; font-size: 12px; }
        .receipt-row-label { color: var(--text-muted); }
        .receipt-row-val   { font-weight: 700; }
        .receipt-total  { display: flex; justify-content: space-between; align-items: center; background: rgba(2,102,128,0.1); border: 1px solid rgba(2,102,128,0.2); border-radius: 11px; padding: 10px 14px; }
        .receipt-total-label { font-size: 12px; font-weight: 700; }
        .receipt-total-val   { font-size: 18px; font-weight: 800; color: var(--secondary); }
        .receipt-review { text-align: center; }
        .receipt-review-label { font-size: 11px; color: var(--text-muted); margin-bottom: 8px; }
        .star-row { display: flex; justify-content: center; gap: 8px; }
        
        /* Hiệu ứng bay vào giỏ hàng */
        .cart-fly-dot {
            position: fixed;
            z-index: 9999;
            width: 22px;
            height: 22px;
            background: var(--primary);
            color: white;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 10px;
            font-weight: 800;
            box-shadow: 0 0 12px var(--primary);
            pointer-events: none;
            transition: transform 0.65s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.65s ease;
        }
        @keyframes cartBump {
            0%, 100% { transform: scale(1); }
            50% { transform: scale(1.08); box-shadow: 0 -3px 15px rgba(0, 234, 159, 0.35); }
        }
        .cart-bump {
            animation: cartBump 0.3s ease;
        }

        .star-btn { font-size: 26px; cursor: pointer; opacity: 0.3; transition: all 0.15s; line-height: 1; }
        .star-btn.active, .star-btn:hover ~ .star-btn { opacity: 1; }
        .star-btn.active { transform: scale(1.15); }

        /* Split Bill Modal */
        .split-result-row { display: flex; justify-content: space-between; align-items: center; background: rgba(0,234,159,0.06); border: 1px solid rgba(0,234,159,0.2); border-radius: 10px; padding: 11px 14px; margin-top: 6px; }
        .split-per-person { font-size: 20px; font-weight: 800; color: var(--secondary); }

        /* Settings Overlay Sub-page (Cài đặt hệ thống phụ) */
        .settings-overlay {
            position: absolute; top: 0; bottom: 0; left: 0; right: 0;
            background: var(--bg-dark); z-index: 110;
            display: flex; flex-direction: column;
            transform: translateX(100%);
            transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
        }
        .settings-overlay.active {
            transform: translateX(0);
        }
        .settings-overlay-header {
            display: flex; align-items: center; justify-content: space-between;
            padding: 13px 16px; border-bottom: 1px solid var(--border);
            background: var(--bg-card); box-shadow: var(--shadow);
            flex-shrink: 0;
        }
        .settings-back-btn {
            background: transparent; border: none; color: var(--text-main);
            font-size: 14px; font-weight: 700; cursor: pointer;
            display: flex; align-items: center; gap: 4px; padding: 5px 0;
        }
        .settings-overlay-title {
            font-size: 14px; font-weight: 800; color: var(--text-main);
            margin: 0;
        }
        .settings-overlay-content {
            flex: 1; overflow-y: auto; padding: 14px;
        }

        /* Map Pinning Banner (hien khi merchant chon vi tri) */
        .map-pinning-banner { position: absolute; top: 0; left: 0; width: 100%; background: linear-gradient(135deg, var(--primary) 0%, #015a72 100%); color: white; padding: 12px 16px; display: none; align-items: center; justify-content: space-between; z-index: 200; box-shadow: 0 3px 16px rgba(2,102,128,0.5); }
        .map-pinning-banner.active { display: flex; }
        .map-pinning-banner-text { font-size: 13px; font-weight: 700; display: flex; align-items: center; gap: 7px; }
        .map-pinning-cancel-btn { background: rgba(255,255,255,0.2); border: 1px solid rgba(255,255,255,0.35); color: white; border-radius: 8px; padding: 5px 14px; font-size: 12px; font-weight: 700; cursor: pointer; white-space: nowrap; }
        /* Location Pin Status Row trong form dang ky */
        .location-status-row { display: flex; align-items: center; justify-content: space-between; background: var(--bg-dark); border: 1px solid var(--border); border-radius: 9px; padding: 10px 12px; gap: 8px; }
        .location-status-text { font-size: 12px; color: var(--text-muted); flex: 1; }
        .location-status-text.pinned { color: var(--secondary); font-weight: 700; }
        .pin-map-btn { background: rgba(2,102,128,0.18); border: 1px solid rgba(2,102,128,0.4); color: var(--primary); border-radius: 7px; padding: 5px 12px; font-size: 12px; font-weight: 700; cursor: pointer; white-space: nowrap; transition: all 0.2s; }
        .pin-map-btn:hover { background: rgba(2,102,128,0.35); }

        /* AI Chat Floating Button & Panel */
        .ai-chat-bubble { position: absolute; bottom: 80px; right: 14px; width: 44px; height: 44px; border-radius: 50%; background: var(--primary); display: flex; justify-content: center; align-items: center; box-shadow: 0 4px 13px rgba(2,102,128,0.4); cursor: pointer; z-index: 85; transition: transform 0.2s; }
        .ai-chat-bubble:hover { transform: scale(1.05); }
        .ai-chat-bubble svg { width: 21px; height: 21px; fill: white; }
        .voice-mic-bubble { position: absolute; bottom: 80px; left: 14px; width: 44px; height: 44px; border-radius: 50%; background: #ef4444; display: flex; justify-content: center; align-items: center; box-shadow: 0 4px 13px rgba(239,68,68,0.4); cursor: pointer; z-index: 85; transition: transform 0.2s; }
        .voice-mic-bubble.listening { animation: pulseRec 1.5s infinite ease-in-out; }

        .ai-chat-panel { position: absolute; bottom: 0; left: 0; width: 100%; height: 78%; background: var(--bg-card); border-top: 1px solid var(--border); border-radius: 18px 18px 0 0; z-index: 110; box-shadow: var(--shadow-menu); display: flex; flex-direction: column; padding: 16px; transition: transform 0.3s ease-in-out; transform: translateY(100%); }
        .ai-chat-panel.active { transform: translateY(0); }
        .ai-chat-messages { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 9px; padding: 7px 0; }
        .chat-bubble { padding: 8px 12px; border-radius: 11px; font-size: 12px; max-width: 82%; line-height: 1.5; }
        .chat-bubble.bot  { background: rgba(255,255,255,0.05); align-self: flex-start; }
        .chat-bubble.user { background: var(--primary); color: white; align-self: flex-end; }
        .ai-chat-input-container { display: flex; gap: 7px; margin-top: 9px; }

        /* Toast Notification */
        .status-toast { position: fixed; top: 18px; left: 50%; transform: translateX(-50%); background: rgba(2,102,128,0.92); color: white; padding: 9px 18px; border-radius: 16px; font-size: 12px; font-weight: 700; box-shadow: 0 4px 13px rgba(0,0,0,0.3); display: none; z-index: 999; backdrop-filter: blur(5px); white-space: nowrap; max-width: 88%; text-align: center; }

        /* Shared Overlay Utilities */
        .menu-header { display: flex; justify-content: space-between; align-items: flex-start; }
        .close-btn { background: var(--bg-dark); color: var(--text-main); border: 1px solid var(--border); padding: 6px 13px; border-radius: 8px; cursor: pointer; font-weight: 700; font-size: 12px; }


        /* ============================================================
           SECTION 7 — ANIMATIONS & UTILITIES
        ============================================================ */
        @keyframes pulseRec {
            0%   { transform: scale(1);   box-shadow: 0 0 0 0   rgba(239,68,68,0.7); }
            70%  { transform: scale(1.1); box-shadow: 0 0 0 8px rgba(239,68,68,0); }
            100% { transform: scale(1);   box-shadow: 0 0 0 0   rgba(239,68,68,0); }
        }

        /* ============================================================
           SECTION 8 — ICON SYSTEM (Lucide) & NEW COMPONENTS
        ============================================================ */
        /* Icon wrapper tròn cho settings items */
        .settings-icon-wrap {
            width: 36px; height: 36px; border-radius: 10px;
            display: flex; align-items: center; justify-content: center; flex-shrink: 0;
        }
        .settings-icon-wrap i { width: 18px; height: 18px; stroke: currentColor; stroke-width: 2; }
        .icon-teal   { background: rgba(2,102,128,0.15);   color: var(--primary); }
        .icon-green  { background: rgba(16,185,129,0.12);  color: #10b981; }
        .icon-amber  { background: rgba(245,158,11,0.12);  color: #f59e0b; }
        .icon-red    { background: rgba(239,68,68,0.12);   color: #ef4444; }
        .icon-purple { background: rgba(139,92,246,0.12);  color: #8b5cf6; }
        .icon-blue   { background: rgba(59,130,246,0.12);  color: #3b82f6; }

        /* Nav icon size (Lucide trong Bottom Nav & Sidebar) */
        .nav-item i, .sidebar-item i {
            width: 22px; height: 22px; stroke: currentColor; stroke-width: 2;
        }

        /* Smooth theme transition (B4) */
        body,
        .app-header,
        .bottom-nav,
        .sidebar,
        .tab-content,
        .wallet-card,
        .shop-card,
        .settings-item,
        .modal-overlay,
        .landing-page {
            transition:
                background-color 0.25s ease,
                border-color     0.25s ease,
                color            0.15s ease;
        }

        /* Không transition cho elements cần instant response */
        button,
        .nav-item,
        .qa-item .qa-icon {
            transition:
                background-color 0.15s ease,
                opacity          0.15s ease,
                transform        0.15s ease;
        }

        /* Settings back button Lucide style */
        .settings-back-btn {
            display: flex; align-items: center; gap: 6px;
            background: none; border: none; color: var(--text-muted);
            font-size: 13px; font-weight: 600; cursor: pointer; padding: 0;
        }
        .settings-back-btn i { width: 18px; height: 18px; stroke: currentColor; stroke-width: 2; }
        .settings-back-btn:hover { color: var(--text-main); }

        /* Sidebar username avatar */
        .sidebar-avatar {
            width: 28px; height: 28px; border-radius: 50%;
            background: rgba(2,102,128,0.2); display: flex;
            align-items: center; justify-content: center; flex-shrink: 0;
        }
        .sidebar-avatar i { width: 14px; height: 14px; stroke: #026680; stroke-width: 2; }

        /* Transaction Success Overlay (B2) */
        #success-overlay {
            position: fixed; inset: 0; z-index: 9999;
            background: var(--bg-main, #0b111e);
            display: none; flex-direction: column;
            align-items: center; justify-content: center; gap: 16px;
        }
        #success-overlay.active { display: flex; animation: fadeInScale 0.3s ease; }
        #success-icon-wrap {
            width: 80px; height: 80px; border-radius: 50%;
            background: rgba(16,185,129,0.15);
            display: flex; align-items: center; justify-content: center;
        }
        #success-icon-wrap i { width: 42px; height: 42px; stroke: #10b981; stroke-width: 2.5; }
        #success-title { font-size: 22px; font-weight: 800; }
        #success-amount { font-size: 34px; font-weight: 900; color: #10b981; }
        #success-shop, #success-time { color: var(--text-muted); }
        #success-shop { font-size: 15px; }
        #success-time { font-size: 12px; margin-top: -4px; }

        /* Onboarding Splash (B3) */
        #onboarding-splash {
            position: fixed; inset: 0; z-index: 9998;
            background: var(--bg-dark, #0b111e);
            display: none; flex-direction: column;
            align-items: center; justify-content: center; gap: 24px;
            padding: 32px 0;
        }
        #onboarding-splash.active { display: flex; }
        .splash-slides { width: 100%; }
        .splash-slide { display: none; flex-direction: column; align-items: center;
            gap: 16px; text-align: center; padding: 0 28px; }
        .splash-slide.active { display: flex; }
        .splash-icon { width: 120px; height: 120px; border-radius: 32px;
            background: rgba(2,102,128,0.1); display: flex;
            align-items: center; justify-content: center; }
        .splash-icon i { width: 60px; height: 60px; stroke: #026680; stroke-width: 1.5; }
        .splash-title { font-size: 20px; font-weight: 800; color: var(--text-main); }
        .splash-desc  { font-size: 14px; color: var(--text-muted); line-height: 1.65; max-width: 320px; }
        .splash-dots  { display: flex; gap: 8px; justify-content: center; }
        .splash-dot   { width: 8px; height: 8px; border-radius: 50%;
            background: var(--border); transition: all 0.25s ease; }
        .splash-dot.active { width: 24px; border-radius: 4px; background: #026680; }
        .splash-actions { display: flex; justify-content: space-between;
            width: 100%; padding: 0 28px; gap: 12px; }
        #splash-skip  { background: transparent; border: 1px solid var(--border);
            color: var(--text-muted); padding: 12px 24px; border-radius: 12px;
            font-size: 14px; font-weight: 600; cursor: pointer; flex: 1; }
        #splash-next  { background: var(--primary); color: white;
            border: none; padding: 12px 24px; border-radius: 12px;
            font-size: 14px; font-weight: 700; cursor: pointer; flex: 2; }

        /* Pi Near Me card (B5) */
        #pi-near-me { margin: 0 0 16px; }
        #near-me-card {
            background: linear-gradient(135deg, rgba(2,102,128,0.18), rgba(2,102,128,0.06));
            border: 1px solid rgba(2,102,128,0.3); border-radius: 14px;
            padding: 14px 16px; display: flex; align-items: center; gap: 14px;
            cursor: pointer; transition: opacity 0.2s;
        }
        #near-me-card:active { opacity: 0.8; }
        #near-me-pay-btn {
            background: #026680; color: white; border: none;
            padding: 9px 14px; border-radius: 10px;
            font-size: 12px; font-weight: 700; white-space: nowrap;
            display: flex; align-items: center; gap: 5px; cursor: pointer;
        }
        #near-me-pay-btn i { width: 13px; height: 13px; stroke: white; stroke-width: 2; }

        @keyframes fadeInScale {
            from { opacity: 0; transform: scale(0.93); }
            to   { opacity: 1; transform: scale(1); }
        }

        /* ===================== GPS PULSE USER MARKER ===================== */
        /* Chấm định vị người dùng: SVG với hiệu ứng sóng tỏa ra */
        @keyframes gps-pulse-ring {
            0%   { transform: scale(0.5); opacity: 0.8; }
            100% { transform: scale(2.2); opacity: 0; }
        }
        @keyframes gps-pulse-dot {
            0%, 100% { transform: scale(1);    opacity: 1; }
            50%       { transform: scale(1.15); opacity: 0.85; }
        }
        .user-gps-pulse {
            position: relative;
            width: 20px;
            height: 20px;
        }
        .user-gps-pulse .gps-ring {
            position: absolute;
            inset: 0;
            border-radius: 50%;
            background: rgba(59, 130, 246, 0.45);
            animation: gps-pulse-ring 1.6s cubic-bezier(0.22, 0.61, 0.36, 1) infinite;
        }
        .user-gps-pulse .gps-dot {
            position: absolute;
            inset: 4px;
            border-radius: 50%;
            background: #3b82f6;
            border: 2.5px solid #ffffff;
            box-shadow: 0 0 0 2px rgba(59,130,246,0.4), 0 2px 6px rgba(0,0,0,0.35);
            animation: gps-pulse-dot 2s ease-in-out infinite;
        }

        /* ===================== NAV INSTRUCTION PANEL ===================== */
        /* Bảng chỉ đường nổi ở trên bản đồ */
        #nav-instruction-panel {
            display: none;
            position: absolute;
            top: 12px;
            left: 50%;
            transform: translateX(-50%);
            z-index: 800;
            background: var(--bg-card, #1a2130);
            border: 1.5px solid #00ea9f;
            border-radius: 14px;
            padding: 10px 16px 10px 12px;
            min-width: 220px;
            max-width: 300px;
            box-shadow: 0 4px 20px rgba(0,234,159,0.18), 0 2px 8px rgba(0,0,0,0.4);
            display: none;
            align-items: center;
            gap: 10px;
        }
        #nav-instruction-panel.visible {
            display: flex !important;
            animation: fadeInScale 0.22s ease both;
        }
        .nav-panel-icon {
            flex-shrink: 0;
            width: 34px;
            height: 34px;
            background: rgba(0,234,159,0.15);
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        .nav-panel-icon svg { width: 18px; height: 18px; stroke: #00ea9f; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
        .nav-panel-info { flex: 1; }
        .nav-panel-name { font-size: 12px; font-weight: 700; color: var(--text-main, #e2e8f0); margin-bottom: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 160px; }
        .nav-panel-meta { font-size: 11px; color: #00ea9f; font-weight: 600; }
        .nav-panel-close {
            flex-shrink: 0;
            background: rgba(255,255,255,0.07);
            border: none;
            border-radius: 50%;
            width: 26px;
            height: 26px;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: background 0.2s;
        }
        .nav-panel-close:hover { background: rgba(255,255,255,0.15); }
        .nav-panel-close svg { width: 13px; height: 13px; stroke: var(--text-muted, #94a3b8); fill: none; stroke-width: 2.5; stroke-linecap: round; }

        /* Map wrapper cần position:relative để panel absolute hoạt động */
        #shops-map { position: relative; }


        /* ==================== MERCHANT PORTAL STYLES (v1.6.0) ==================== */

        /* Shell container */
        .merchant-shell {
            min-height: 100vh;
            background: var(--bg-dark);
            padding: 0 0 100px 0;
            font-family: var(--font-main, system-ui, sans-serif);
        }

        /* Header Merchant */
        .merchant-header {
            background: linear-gradient(135deg, #0b2a20 0%, #0d3d2a 100%);
            border-bottom: 1px solid rgba(0,234,159,0.15);
            padding: 16px 20px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            position: sticky;
            top: 0;
            z-index: 100;
        }
        .merchant-header-left { display: flex; align-items: center; gap: 12px; }
        .merchant-logo-wrap {
            width: 40px; height: 40px;
            background: rgba(0,234,159,0.15);
            border: 1px solid rgba(0,234,159,0.3);
            border-radius: 10px;
            display: flex; align-items: center; justify-content: center;
        }
        .merchant-logo-wrap svg { width: 20px; height: 20px; stroke: var(--secondary); }
        .merchant-header-name { font-size: 15px; font-weight: 800; color: #fff; }
        .merchant-header-status { display: flex; align-items: center; gap: 5px; font-size: 11px; color: var(--secondary); margin-top: 2px; }
        .merchant-open-dot {
            width: 7px; height: 7px; border-radius: 50%;
            background: var(--secondary);
            box-shadow: 0 0 6px var(--secondary);
            animation: pulse-dot 1.5s infinite;
        }
        @keyframes pulse-dot { 0%,100%{opacity:1;} 50%{opacity:0.4;} }
        .merchant-header-actions { display: flex; align-items: center; gap: 8px; }
        .merchant-toggle-open-btn {
            font-size: 11px; font-weight: 700;
            padding: 6px 12px; border-radius: 8px;
            border: 1px solid rgba(255,100,100,0.4);
            background: rgba(255,100,100,0.1);
            color: #ff8080; cursor: pointer;
            transition: all 0.2s;
        }
        .merchant-toggle-open-btn:hover { background: rgba(255,100,100,0.2); }
        .merchant-toggle-open-btn.is-open {
            border-color: rgba(0,234,159,0.4);
            background: rgba(0,234,159,0.1);
            color: var(--secondary);
        }
        .merchant-back-btn {
            display: flex; align-items: center; gap: 5px;
            font-size: 11px; font-weight: 700;
            padding: 6px 12px; border-radius: 8px;
            border: 1px solid var(--border);
            background: rgba(255,255,255,0.05);
            color: var(--text-muted); cursor: pointer;
            transition: all 0.2s;
        }
        .merchant-back-btn svg { width: 13px; height: 13px; stroke: currentColor; }
        .merchant-back-btn:hover { border-color: var(--primary); color: var(--text-main); }

        /* Thẻ thống kê nhanh */
        .merchant-stats-row {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 10px;
            padding: 16px 16px 0;
        }
        .merchant-stat-card {
            background: var(--card-bg);
            border: 1px solid var(--border);
            border-radius: 12px;
            padding: 12px 10px;
            text-align: center;
        }
        .merchant-stat-label { font-size: 10px; color: var(--text-muted); margin-bottom: 4px; }
        .merchant-stat-value { font-size: 14px; font-weight: 800; color: var(--secondary); line-height: 1.2; }
        .merchant-stat-sub { font-size: 10px; color: var(--text-muted); margin-top: 3px; }

        /* Section chung */
        .merchant-section { padding: 16px 16px 0; }
        .merchant-section-title {
            display: flex; align-items: center; gap: 8px;
            font-size: 13px; font-weight: 700; color: var(--text-main);
            margin-bottom: 12px;
            padding-bottom: 8px;
            border-bottom: 1px solid var(--border);
        }
        .merchant-section-title svg { width: 15px; height: 15px; stroke: var(--primary); }

        /* Trình tạo QR động */
        .merchant-bill-generator {
            background: var(--card-bg);
            border: 1px solid var(--border);
            border-radius: 14px;
            padding: 16px;
        }
        .merchant-qr-wrap {
            background: white;
            padding: 12px;
            border-radius: 12px;
            display: inline-block;
            box-shadow: 0 4px 20px rgba(0,0,0,0.3);
        }
        .merchant-qr-wrap canvas { display: block; }
        .merchant-qr-amount {
            font-size: 22px; font-weight: 800;
            color: var(--secondary);
            margin-top: 12px;
        }
        .merchant-qr-note {
            font-size: 12px; color: var(--text-muted);
            margin-top: 4px;
        }

        /* Lịch sử đơn hàng */
        .merchant-sale-row {
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 10px 12px;
            background: var(--card-bg);
            border: 1px solid var(--border);
            border-radius: 10px;
            margin-bottom: 8px;
            animation: fadeInScale 0.3s ease;
        }
        .merchant-sale-row.new-flash { border-color: var(--secondary); background: rgba(0,234,159,0.05); }
        .merchant-sale-from { font-size: 13px; font-weight: 700; color: var(--text-main); }
        .merchant-sale-time { font-size: 10px; color: var(--text-muted); margin-top: 2px; }
        .merchant-sale-amount { font-size: 15px; font-weight: 800; color: var(--secondary); }

        /* Modal đăng ký Merchant */
        #merchant-register-modal {
            display: none;
            position: fixed; inset: 0; z-index: 9999;
            background: rgba(0,0,0,0.75);
            backdrop-filter: blur(6px);
            align-items: flex-end;
            justify-content: center;
        }
        #merchant-register-modal.active { display: flex; }
        .merchant-register-sheet {
            background: var(--card-bg);
            border-radius: 20px 20px 0 0;
            border-top: 1px solid var(--border);
            padding: 24px 20px 40px;
            width: 100%; max-width: 480px;
            max-height: 90vh; overflow-y: auto;
            animation: slideUp 0.35s cubic-bezier(0.34,1.56,0.64,1);
        }
        .merchant-register-title {
            font-size: 18px; font-weight: 800;
            margin-bottom: 4px; color: var(--text-main);
        }
        .merchant-register-sub {
            font-size: 12px; color: var(--text-muted);
            margin-bottom: 20px; line-height: 1.5;
        }
        .merchant-form-label {
            font-size: 11px; font-weight: 700;
            color: var(--text-muted);
            text-transform: uppercase;
            letter-spacing: 0.5px;
            margin-bottom: 6px;
            display: block;
        }
        .merchant-form-group { margin-bottom: 14px; }
        .merchant-upload-btn {
            width: 100%; padding: 12px;
            border: 1.5px dashed var(--border);
            border-radius: 10px;
            background: rgba(255,255,255,0.02);
            color: var(--text-muted);
            font-size: 12px; cursor: pointer;
            text-align: center;
            transition: all 0.2s;
        }
        .merchant-upload-btn:hover { border-color: var(--primary); color: var(--text-main); }
        .merchant-upload-btn.has-file { border-color: var(--secondary); color: var(--secondary); background: rgba(0,234,159,0.05); }
        .merchant-submit-btn {
            width: 100%; padding: 14px;
            background: var(--primary);
            color: white; font-size: 14px; font-weight: 800;
            border: none; border-radius: 12px; cursor: pointer;
            margin-top: 8px;
            transition: opacity 0.2s;
        }
        .merchant-submit-btn:hover { opacity: 0.88; }
        .merchant-gps-row {
            display: flex; gap: 8px; align-items: center;
        }
        .merchant-gps-status {
            font-size: 10px; color: var(--text-muted);
            flex: 1;
        }
        .merchant-gps-status.pinned { color: var(--secondary); font-weight: 700; }


        /* ==================== ADMIN PORTAL STYLES (v1.7.0) ==================== */
        .admin-shell {
            min-height: 100vh;
            background: var(--bg-dark);
            padding: 0 0 100px 0;
            font-family: var(--font-main, system-ui, sans-serif);
        }
        .admin-header {
            background: linear-gradient(135deg, #2b1c05 0%, #3d280d 100%);
            border-bottom: 1px solid rgba(255,167,0,0.15);
            padding: 16px 20px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            position: sticky;
            top: 0;
            z-index: 100;
        }
        .admin-logo-wrap {
            width: 40px; height: 40px;
            background: rgba(255,167,0,0.1);
            border: 1px solid rgba(255,167,0,0.25);
            border-radius: 10px;
            display: flex; align-items: center; justify-content: center;
        }
        .admin-logo-wrap svg { width: 20px; height: 20px; stroke: #ffa700; }
        .admin-header-name { font-size: 15px; font-weight: 800; color: #fff; }
        .admin-header-status { font-size: 10px; color: #ffa700; margin-top: 2px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; }

        /* Admin Tab Buttons */
        .admin-tab-btn {
            flex: 1; padding: 10px;
            background: rgba(255,255,255,0.03);
            border: 1px solid var(--border);
            border-radius: 8px;
            color: var(--text-muted);
            font-size: 11px; font-weight: 700;
            cursor: pointer; transition: all 0.2s;
            text-align: center;
        }
        .admin-tab-btn.active {
            background: rgba(255,167,0,0.1);
            border-color: #ffa700;
            color: #ffa700;
        }

        /* Card đơn đăng ký */
        .admin-request-card {
            background: var(--card-bg);
            border: 1px solid var(--border);
            border-radius: 14px;
            padding: 16px;
            margin-bottom: 12px;
        }
        .admin-req-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 12px; }
        .admin-req-title { font-size: 14px; font-weight: 800; color: #fff; }
        .admin-req-category { font-size: 10px; background: rgba(255,255,255,0.08); color: var(--text-muted); padding: 2px 7px; border-radius: 6px; margin-top: 3px; display: inline-block; }
        .admin-req-meta { font-size: 11px; color: var(--text-muted); margin-bottom: 6px; display: flex; align-items: center; gap: 6px; }
        .admin-req-meta svg { width: 12px; height: 12px; stroke: var(--primary); }
        
        /* Thumbnails hình ảnh để admin phóng to */
        .admin-req-images { display: flex; gap: 8px; margin: 12px 0; }
        .admin-img-thumb {
            width: 80px; height: 80px;
            border-radius: 8px;
            border: 1px solid var(--border);
            object-fit: cover;
            cursor: pointer;
            transition: opacity 0.2s;
        }
        .admin-img-thumb:hover { opacity: 0.8; }
        .admin-img-label { font-size: 9px; color: var(--text-muted); text-align: center; margin-top: 3px; }

        /* Nút hành động */
        .admin-action-row { display: flex; gap: 8px; margin-top: 14px; }
        .admin-btn-approve {
            flex: 1; padding: 10px;
            background: rgba(0,234,159,0.12);
            border: 1px solid rgba(0,234,159,0.3);
            border-radius: 8px;
            color: var(--secondary);
            font-size: 12px; font-weight: 800;
            cursor: pointer; transition: all 0.2s;
        }
        .admin-btn-approve:hover { background: rgba(0,234,159,0.2); }
        .admin-btn-reject {
            flex: 1; padding: 10px;
            background: rgba(255,100,100,0.1);
            border: 1px solid rgba(255,100,100,0.3);
            border-radius: 8px;
            color: #ff8080;
            font-size: 12px; font-weight: 800;
            cursor: pointer; transition: all 0.2s;
        }
        .admin-btn-reject:hover { background: rgba(255,100,100,0.18); }

        /* Card shop hoạt động phía admin */
        .admin-shop-row {
            display: flex; align-items: center; justify-content: space-between;
            padding: 12px; background: var(--card-bg);
            border: 1px solid var(--border); border-radius: 12px;
            margin-bottom: 8px;
        }
        .admin-shop-info { flex: 1; }
        .admin-shop-name { font-size: 13px; font-weight: 800; color: #fff; }
        .admin-shop-desc { font-size: 10px; color: var(--text-muted); margin-top: 2px; }
        .admin-btn-ban {
            background: rgba(255,100,100,0.1);
            border: 1px solid rgba(255,100,100,0.3);
            color: #ff8080; padding: 6px 12px;
            border-radius: 6px; font-size: 11px; font-weight: 700;
            cursor: pointer; transition: all 0.2s;
        }
        .admin-btn-ban:hover { background: rgba(255,100,100,0.2); }

        /* Chú thích đồng thuận Pi (v1.7.4) */
        .pi-consensus-disclaimer {
            font-size: 9px;
            color: var(--text-muted);
            text-align: center;
            margin: 8px 0;
            opacity: 0.7;
            font-style: italic;
            line-height: 1.3;
        }

        /* ===== Map Bottom Sheet Glassmorphism (v1.7.6) ===== */
        #map-bottom-sheet {
            position: fixed;
            bottom: 60px; left: 0; right: 0;
            z-index: 9999;
            transform: translateY(100%);
            transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
            pointer-events: none;
        }
        #map-bottom-sheet.active {
            transform: translateY(0);
            pointer-events: all;
        }
        .mbs-handle {
            width: 36px; height: 4px;
            background: rgba(255,255,255,0.25);
            border-radius: 2px;
            margin: 0 auto 10px;
        }
        .mbs-body {
            background: rgba(12, 20, 44, 0.82);
            backdrop-filter: blur(20px);
            -webkit-backdrop-filter: blur(20px);
            border-top: 1px solid rgba(255,255,255,0.10);
            border-radius: 20px 20px 0 0;
            padding: 10px 16px 22px;
            box-shadow: 0 -8px 32px rgba(0,0,0,0.45);
        }
        .mbs-header {
            display: flex; align-items: center; gap: 12px;
            margin-bottom: 10px;
        }
        .mbs-icon-wrap {
            width: 44px; height: 44px; flex-shrink: 0;
            border-radius: 12px;
            background: rgba(2,102,128,0.25);
            border: 1px solid rgba(2,102,128,0.4);
            display: flex; align-items: center; justify-content: center;
            color: var(--primary);
        }
        .mbs-icon-wrap i { width: 20px; height: 20px; stroke-width: 2.2; }
        .mbs-info { flex: 1; min-width: 0; }
        .mbs-name { font-size: 15px; font-weight: 800; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
        .mbs-meta { font-size: 11px; color: var(--text-muted); margin-top: 2px; display: flex; align-items: center; gap: 6px; }
        .mbs-close {
            background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.12);
            border-radius: 8px; width: 32px; height: 32px;
            display: flex; align-items: center; justify-content: center;
            cursor: pointer; flex-shrink: 0; color: var(--text-muted);
            transition: all 0.15s;
        }
        .mbs-close:hover { background: rgba(255,255,255,0.15); color: #fff; }
        .mbs-status-row {
            display: flex; align-items: center; gap: 8px;
            margin-bottom: 12px; font-size: 11px;
        }
        .mbs-hours { color: var(--text-muted); }
        .mbs-actions { display: flex; gap: 10px; }
        .mbs-btn {
            flex: 1; padding: 11px 0;
            border-radius: 12px; border: none;
            font-size: 13px; font-weight: 700;
            cursor: pointer;
            display: flex; align-items: center; justify-content: center; gap: 7px;
            transition: all 0.18s ease;
        }
        .mbs-btn-primary {
            background: var(--primary); color: white;
        }
        .mbs-btn-primary:hover { background: rgba(2,102,128,0.85); }
        .mbs-btn-nav {
            background: rgba(0,234,159,0.12);
            color: var(--secondary);
            border: 1px solid rgba(0,234,159,0.35) !important;
        }
        .mbs-btn-nav:hover { background: rgba(0,234,159,0.22); }


/* ============================================================
   SECTION — PIN CONSOLE MODAL (v1.7.8)
   Hộp thoại nhập mã PIN bảo vệ Debug Console
============================================================ */
        #pin-console-modal {
            display: none;
        }
        #pin-console-modal.active {
            display: flex !important;
        }
        /* Dot chỉ thị PIN */
        .pin-dot {
            width: 14px;
            height: 14px;
            border-radius: 50%;
            border: 2px solid rgba(255,255,255,0.25);
            background: transparent;
            display: inline-block;
            transition: background 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
        }
        .pin-dot.filled {
            background: #7c3aed;
            border-color: #7c3aed;
            transform: scale(1.15);
        }
        .pin-dot.error {
            background: #ff4b4b;
            border-color: #ff4b4b;
            animation: pin-shake 0.4s ease;
        }
        @keyframes pin-shake {
            0%,100% { transform: translateX(0); }
            20%      { transform: translateX(-5px); }
            40%      { transform: translateX(5px); }
            60%      { transform: translateX(-4px); }
            80%      { transform: translateX(4px); }
        }
        /* Numpad keys */
        .pin-key {
            background: rgba(255,255,255,0.07);
            border: 1px solid rgba(255,255,255,0.1);
            border-radius: 12px;
            color: #fff;
            cursor: pointer;
            font-size: 18px;
            font-weight: 600;
            padding: 12px 0;
            transition: background 0.12s ease, transform 0.08s ease;
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
        }
        .pin-key:hover  { background: rgba(255,255,255,0.13); }
        .pin-key:active { transform: scale(0.92); background: rgba(124,58,237,0.35); }
        .pin-key-cancel { background: rgba(255,75,75,0.12);  border-color: rgba(255,75,75,0.2);  color: #ff4b4b; font-size:14px; }
        .pin-key-del    { background: rgba(255,255,255,0.04); border-color: rgba(255,255,255,0.08); color: rgba(255,255,255,0.55); font-size:14px; }

/* ============================================================
   SECTION — STARS LOYALTY (v1.9.6)
   CSS cho Card ví Stars, Leaderboard, Stars Shop & Gacha trượt ngang
============================================================ */

/* Giao diện Card ví Stars ở bên phải */
.wallet-stars-right {
    text-align: right;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: center;
}
.stars-counter-row {
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 4px 10px;
    border-radius: 20px;
    transition: background 0.2s ease, transform 0.15s ease;
}
.stars-counter-row:hover {
    background: rgba(255, 255, 255, 0.16);
    transform: translateY(-1px);
}
.stars-gold-icon {
    font-size: 13px;
    animation: gold-pulse 1.8s infinite;
}
@keyframes gold-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}
.stars-value-text {
    font-size: 15px;
    font-weight: 800;
    color: #f1c40f;
    letter-spacing: -0.2px;
}
.stars-unit-text {
    font-size: 11px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.8);
}
.user-tier-badge {
    font-size: 10px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 4px;
    letter-spacing: 0.2px;
}

/* Biểu tượng SVG (!) Cẩm nang */
.stars-info-trigger {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.45);
    margin-left: 2px;
    transition: color 0.15s;
}
.stars-info-trigger:hover {
    color: #f1c40f;
}
.info-svg {
    width: 12px;
    height: 12px;
    stroke-width: 2.5;
}

/* Modals Stars chung */
.stars-modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.72);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    z-index: 1500;
    display: none; /* Khắc phục lỗi Safari backdrop-filter chặn click */
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
}
.stars-modal-overlay.active {
    display: flex !important;
    opacity: 1;
}
.stars-modal-content {
    background: rgba(12, 19, 36, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    width: 90%;
    max-width: 390px;
    padding: 22px;
    position: relative;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6);
    transform: scale(0.92);
    transition: transform 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.stars-modal-overlay.active .stars-modal-content {
    transform: scale(1);
}
.stars-modal-close {
    position: absolute;
    top: 15px; right: 18px;
    background: none; border: none;
    color: rgba(255, 255, 255, 0.4);
    font-size: 26px; cursor: pointer;
    transition: color 0.15s;
}
.stars-modal-close:hover {
    color: #ffffff;
}
.stars-modal-header {
    text-align: center;
    margin-bottom: 16px;
}
.stars-header-icon {
    font-size: 32px;
    display: block;
    margin-bottom: 6px;
}
.stars-modal-header h2 {
    color: #ffffff;
    font-size: 17px;
    font-weight: 800;
    margin: 0;
    letter-spacing: 0.3px;
}
.stars-modal-header p {
    color: rgba(255, 255, 255, 0.55);
    font-size: 11px;
    margin: 4px 0 0 0;
}

/* Tabs trong modal */
.stars-modal-tabs {
    display: flex;
    gap: 6px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 10px;
    margin-bottom: 14px;
}
.tab-btn {
    flex: 1;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 10px;
    color: rgba(255, 255, 255, 0.55);
    font-size: 10px;
    font-weight: 700;
    padding: 7px 2px;
    cursor: pointer;
    transition: all 0.15s ease;
}
.tab-btn.active {
    background: linear-gradient(135deg, #f1c40f 0%, #d4ac0d 100%);
    color: #0c1324;
    border-color: transparent;
    box-shadow: 0 4px 10px rgba(241, 196, 15, 0.15);
}

/* Nội dung đổi tab */
.guide-tab-content, .shop-tab-content {
    display: none;
}
.guide-tab-content.active, .shop-tab-content.active {
    display: block;
    animation: starsFadeIn 0.22s ease-out;
}
@keyframes starsFadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Hướng dẫn chi tiết */
.guide-item {
    display: flex;
    gap: 12px;
    margin-bottom: 14px;
}
.guide-item:last-child {
    margin-bottom: 4px;
}
.guide-num {
    width: 22px; height: 22px;
    border-radius: 50%;
    background: rgba(241, 196, 15, 0.12);
    color: #f1c40f;
    font-weight: 800;
    font-size: 11px;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.guide-txt h4 {
    color: #ffffff; font-size: 12px; font-weight: 700; margin: 0 0 3px 0;
}
.guide-txt p {
    color: rgba(255, 255, 255, 0.5); font-size: 11px; line-height: 1.45; margin: 0;
}
.badge-x2 {
    background: rgba(239, 68, 68, 0.15);
    color: #f87171;
    font-weight: 700;
    font-size: 9px;
    padding: 1px 4px;
    border-radius: 4px;
    border: 1px solid rgba(239, 68, 68, 0.25);
}
.rule-box {
    padding: 10px 12px;
    border-radius: 10px;
    margin-bottom: 10px;
    border: 1px solid transparent;
}
.rule-box.warning {
    background: rgba(245, 158, 11, 0.08);
    border-color: rgba(245, 158, 11, 0.15);
    color: #f59e0b;
}
.rule-box.info {
    background: rgba(59, 130, 246, 0.08);
    border-color: rgba(59, 130, 246, 0.15);
    color: #60a5fa;
}
.rule-box strong { font-size: 11.5px; display: block; margin-bottom: 3px; }
.rule-box p { font-size: 10.5px; line-height: 1.4; margin: 0; color: rgba(255, 255, 255, 0.65); }

/* Bể thưởng tuần Card */
.pool-info-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 14px;
    padding: 12px;
}
.pool-stat {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11.5px;
    margin-bottom: 8px;
}
.pool-stat:last-child {
    margin-bottom: 0;
}
.pool-stat span { color: rgba(255, 255, 255, 0.55); }
.pool-stat strong { color: #ffffff; font-weight: 700; }
#pool-total-pi { color: var(--secondary); font-size: 13px; }
#pool-user-stars { color: #f1c40f; }

/* Item đổi thưởng */
.voucher-list-shop, .vip-list-shop {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.shop-item-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 10px 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.item-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.item-info strong { color: #ffffff; font-size: 12px; font-weight: 700; }
.item-info span { color: rgba(255, 255, 255, 0.45); font-size: 10px; }
.shop-buy-btn {
    background: rgba(241, 196, 15, 0.12);
    border: 1px solid rgba(241, 196, 15, 0.25);
    border-radius: 8px;
    color: #f1c40f;
    font-size: 11px;
    font-weight: 700;
    padding: 6px 10px;
    cursor: pointer;
    transition: all 0.15s;
}
.shop-buy-btn:hover {
    background: #f1c40f;
    color: #0c1324;
}

/* VIP Preview */
.vip-preview-box {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 16px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
.preview-avatar-container {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}
.preview-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.2);
    object-fit: cover;
}
/* Khung vàng lấp lánh (hiệu ứng CSS) */
.preview-avatar.gold-frame {
    border: 3px solid #f1c40f;
    box-shadow: 0 0 10px rgba(241, 196, 15, 0.6);
    animation: gold-glow-pulse 1.5s infinite alternate;
}
@keyframes gold-glow-pulse {
    from { box-shadow: 0 0 4px rgba(241, 196, 15, 0.4); }
    to { box-shadow: 0 0 14px rgba(241, 196, 15, 0.8); }
}
.preview-name {
    font-size: 12px;
    font-weight: 700;
    color: #ffffff;
}
.preview-name.purple-name {
    color: #c084fc !important;
    text-shadow: 0 0 8px rgba(192, 132, 252, 0.4);
}

/* ================== LEADERBOARD TOP 10 ================== */
.leaderboard-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 14px;
}
.leaderboard-season-tag {
    font-size: 9px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.05);
    padding: 1px 6px;
    border-radius: 4px;
    float: right;
}
.leaderboard-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 8px;
    max-height: 280px;
    overflow-y: auto;
    padding-right: 4px;
}
/* Scrollbar nhỏ cho bảng xếp hạng */
.leaderboard-list::-webkit-scrollbar { width: 3px; }
.leaderboard-list::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.1); border-radius: 2px; }

.leaderboard-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 8px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.015);
    border: 1px solid rgba(255, 255, 255, 0.02);
}
.leaderboard-row.top-1 {
    background: rgba(241, 196, 15, 0.04);
    border-color: rgba(241, 196, 15, 0.12);
}
.leaderboard-row.top-2 {
    background: rgba(148, 163, 184, 0.04);
    border-color: rgba(148, 163, 184, 0.12);
}
.leaderboard-row.top-3 {
    background: rgba(202, 138, 4, 0.03);
    border-color: rgba(202, 138, 4, 0.1);
}
.leaderboard-row-left {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}
.leaderboard-rank {
    font-size: 11px;
    font-weight: 800;
    width: 16px;
    text-align: center;
    color: rgba(255, 255, 255, 0.4);
}
.leaderboard-row.top-1 .leaderboard-rank { color: #f1c40f; }
.leaderboard-row.top-2 .leaderboard-rank { color: #94a3b8; }
.leaderboard-row.top-3 .leaderboard-rank { color: #b45309; }

.leaderboard-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,0.1);
    object-fit: cover;
}
.leaderboard-avatar.gold-frame {
    border: 2px solid #f1c40f;
    box-shadow: 0 0 6px rgba(241, 196, 15, 0.4);
}
.leaderboard-username {
    font-size: 11.5px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.leaderboard-username.purple-name {
    color: #c084fc !important;
}
.leaderboard-title-badge {
    font-size: 8px;
    font-weight: 800;
    padding: 1px 4px;
    border-radius: 3px;
    text-transform: uppercase;
}
.leaderboard-title-badge.king { background: rgba(241, 196, 15, 0.15); color: #f1c40f; border: 1px solid rgba(241, 196, 15, 0.25); }
.leaderboard-title-badge.knight { background: rgba(192, 132, 252, 0.12); color: #c084fc; border: 1px solid rgba(192, 132, 252, 0.2); }
.leaderboard-title-badge.hunter { background: rgba(255, 255, 255, 0.05); color: rgba(255, 255, 255, 0.5); }

.leaderboard-stars-val {
    font-size: 11.5px;
    font-weight: 700;
    color: #f1c40f;
}

/* Trạng thái cá nhân ở chân Leaderboard */
.leaderboard-my-status {
    margin-top: 10px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 10px;
    padding: 8px 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
}
.my-status-left {
    color: rgba(255, 255, 255, 0.55);
}
.my-status-left strong {
    color: #ffffff;
    font-weight: 700;
}
.my-status-expiry {
    color: rgba(239, 68, 68, 0.7);
    font-weight: 700;
    font-size: 10px;
}

/* ================== GACHA REEL (MỞ HÒM) ================== */
.gacha-modal-content {
    background: rgba(8, 12, 22, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 28px;
    width: 90%;
    max-width: 440px;
    padding: 24px;
    text-align: center;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.8);
    position: relative;
    pointer-events: auto;
}
.gacha-header h3 {
    color: var(--secondary);
    font-size: 16px; font-weight: 800; margin: 0; letter-spacing: 0.5px;
}
.gacha-header p {
    color: rgba(255,255,255,0.6); font-size: 11.5px; margin: 4px 0 0 0;
}
.gacha-reel-container {
    position: relative;
    width: 100%;
    height: 76px;
    margin: 18px 0;
    background: rgba(255, 255, 255, 0.02);
    border: 2px solid rgba(255, 255, 255, 0.06);
    border-radius: 14px;
    overflow: hidden;
}
/* Kim chỉ vị trí dừng */
.gacha-pointer {
    position: absolute;
    top: 0; left: 50%;
    width: 4px; height: 100%;
    background: #f1c40f;
    transform: translateX(-50%);
    z-index: 10;
    box-shadow: 0 0 10px #f1c40f;
}
/* Dải băng các ô thưởng */
.gacha-reel {
    display: flex;
    position: absolute;
    top: 8px; left: 0;
    height: 60px;
    will-change: transform;
    transition: transform 0s ease;
}
.gacha-card {
    width: 60px;
    height: 60px;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    margin-right: 6px;
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
}
.gacha-card.common    { border-color: rgba(148,163,184,0.15); color: #94a3b8; }
.gacha-card.uncommon  { border-color: rgba(59,130,246,0.3);   color: #3b82f6; background: rgba(59,130,246,0.03); }
.gacha-card.rare      { border-color: rgba(168,85,247,0.4);   color: #a855f7; background: rgba(168,85,247,0.03); }
.gacha-card.legendary { border-color: rgba(241,196,15,0.5);   color: #f1c40f; background: rgba(241,196,15,0.04); }

.gacha-card span { font-size: 14px; line-height: 1.1; }
.gacha-card label { font-size: 8px; font-weight: 700; text-transform: uppercase; margin-top: 2px; }

.gacha-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}
.gacha-result-congrats {
    font-size: 13px;
    font-weight: 700;
    color: #ffffff;
    min-height: 20px;
}

