* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Plus Jakarta Sans', sans-serif;
    -webkit-tap-highlight-color: transparent;
}

body {
    background: #f7f1f6;
    color: #333;
    padding-bottom: 95px;
}

/* Header */
.top-header {
    background: #ffffff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid #f0e1ec;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(255, 77, 148, 0.05);
}

.header-logo {
    font-weight: 800;
    font-size: 17px;
    color: #ff4d94;
    letter-spacing: 0.5px;
}

.header-actions {
    display: flex;
    gap: 8px;
}

.icon-btn {
    background: #fcf2fa;
    border: 1px solid #f5d0ec;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 15px;
    cursor: pointer;
    position: relative;
    color: #d63384;
    transition: 0.2s;
}

.badge-btn .badge-count {
    position: absolute;
    top: -2px; right: -2px;
    background: #ff3366; color: white;
    font-size: 9px; padding: 2px 5px;
    border-radius: 10px; font-weight: 700;
}

/* Sidebar Menu Trượt */
.sidebar-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5); backdrop-filter: blur(4px);
    z-index: 998; display: none; transition: 0.3s ease;
}
.sidebar-overlay.open { display: block; }

.sidebar {
    position: fixed; top: 0; left: -290px; bottom: 0;
    width: 290px; background: #ffffff; z-index: 999;
    box-shadow: 5px 0 30px rgba(255, 77, 148, 0.15);
    transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex; flex-direction: column;
}
.sidebar.open { left: 0; }

.sidebar-header {
    background: linear-gradient(135deg, #ff3399, #ff66b2);
    color: white; padding: 22px 18px;
    display: flex; justify-content: space-between; align-items: center;
}
.sidebar-header h3 { font-size: 16px; font-weight: 800; }
.close-sidebar {
    background: rgba(255,255,255,0.2); border: none; color: white;
    width: 30px; height: 30px; border-radius: 50%; cursor: pointer; font-weight: bold;
}

.sidebar-user-card {
    padding: 16px; background: #fcf2fa; border-bottom: 1px solid #f2d9eb;
    display: flex; align-items: center; gap: 14px;
}
.s-avatar {
    width: 45px; height: 45px; background: #ff3399; color: white;
    border-radius: 50%; display: flex; justify-content: center; align-items: center; font-size: 20px;
}
.s-info h4 { font-size: 14px; color: #2b1b26; font-weight: 700; }
.s-info p { font-size: 11px; color: #8c7886; margin-top: 3px; }
.hl-money { color: #ff3366; font-weight: 800; }

.sidebar-menu-list { padding: 12px 0; overflow-y: auto; flex: 1; }
.sidebar-menu-list a {
    display: flex; align-items: center; gap: 14px;
    padding: 14px 22px; text-decoration: none; color: #4a3847;
    font-size: 13px; font-weight: 700; transition: 0.2s;
}
.sidebar-menu-list a:hover { background: #fcf2fa; color: #ff3399; }
.m-icon { font-size: 18px; }

/* Main Content & Tabs */
.main-content { padding: 16px; max-width: 600px; margin: 0 auto; }
.tab-content { display: none; animation: fadeIn 0.3s ease; }
.tab-content.active { display: block; }

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

/* Categories Filter Buttons */
.categories {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    overflow-x: auto;
    padding-bottom: 5px;
}

.cat-btn {
    background: #ffffff;
    border: 1px solid #f2d9eb;
    color: #8c7886;
    padding: 8px 14px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.25s;
    white-space: nowrap;
}

.cat-btn.active, .cat-btn:hover {
    background: linear-gradient(135deg, #ff3399, #ff66b2);
    color: #fff;
    border-color: #ff3399;
    box-shadow: 0 4px 12px rgba(255, 51, 153, 0.3);
}

/* Product Grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.acc-card {
    background: #ffffff;
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid #f2d9eb;
    box-shadow: 0 6px 20px rgba(255, 77, 148, 0.06);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    transition: 0.25s ease;
}

.acc-card:active { transform: scale(0.97); }

.acc-thumb { height: 120px; position: relative; }
.thumb-bg {
    width: 100%; height: 100%;
    display: flex; justify-content: center; align-items: center; font-size: 36px;
}

.price-tag {
    position: absolute; top: 10px; left: 10px;
    background: #ff3366; color: white;
    font-size: 11px; font-weight: 800; padding: 5px 11px; border-radius: 9px;
}
.price-tag.special { background: #b833ff; }
.price-tag.vip { background: #ff9900; }

.acc-info { padding: 12px; display: flex; flex-direction: column; justify-content: space-between; flex: 1; }
.acc-info h3 {
    font-size: 13px; font-weight: 700; color: #2b1b26; margin-bottom: 8px;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.acc-stats { display: flex; justify-content: space-between; font-size: 11px; color: #8c7886; font-weight: 600; }
.stock.out { color: #ff3333; }

/* Sublist Header & Button */
.sublist-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}
.btn-back {
    background: #ffffff;
    border: 1px solid #f2d9eb;
    color: #ff3399;
    padding: 6px 12px;
    border-radius: 10px;
    font-weight: 700;
    font-size: 12px;
    cursor: pointer;
}
.btn-sub-buy {
    width: 100%;
    background: linear-gradient(135deg, #3366ff, #5599ff);
    border: none;
    color: white;
    padding: 8px;
    border-radius: 8px;
    font-weight: 800;
    font-size: 11px;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(51, 102, 255, 0.25);
}
.btn-sub-buy:active { transform: scale(0.96); }

/* Giao diện nạp tiền cao cấp (Đã xóa nút check sepay thủ công) */
.wallet-card {
    background: linear-gradient(135deg, #ff4d94, #ff80bf);
    border-radius: 22px;
    padding: 28px;
    color: white;
    text-align: center;
    box-shadow: 0 12px 30px rgba(255, 77, 148, 0.3);
    margin-bottom: 20px;
}
.wallet-label { font-size: 13px; opacity: 0.85; font-weight: 600; }
.balance-amount { font-size: 34px; font-weight: 800; margin: 8px 0 14px 0; }
.wallet-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
}
.deposit-container { display: flex; flex-direction: column; gap: 14px; }
.bank-card-box {
    background: #ffffff; border-radius: 18px; padding: 18px;
    border: 1px solid #f2d9eb; box-shadow: 0 4px 15px rgba(255, 77, 148, 0.04);
    display: flex; flex-direction: column; gap: 12px;
}
.bank-row {
    display: flex; justify-content: space-between; align-items: center;
    font-size: 13px; border-bottom: 1px dashed #f7f1f6; padding-bottom: 8px;
}
.bank-row:last-child { border-bottom: none; padding-bottom: 0; }
.b-label { color: #8c7886; font-weight: 600; }
.b-value { color: #2b1b26; font-weight: 700; }
.hl-copy {
    color: #ff3366; background: #ffe6f2; padding: 3px 8px;
    border-radius: 6px; cursor: pointer; transition: 0.2s;
}
.hl-copy:active { transform: scale(0.95); }
.qr-box {
    background: #ffffff; border-radius: 18px; padding: 20px;
    border: 1px solid #f2d9eb; text-align: center; box-shadow: 0 4px 15px rgba(255, 77, 148, 0.04);
}
.qr-title { font-size: 13px; font-weight: 700; color: #2b1b26; margin-bottom: 12px; }
.qr-img-placeholder {
    background: #fcf2fa; border: 2px dashed #ffb3d9; padding: 20px;
    border-radius: 14px; color: #ff3366; font-weight: 700; font-size: 13px; margin-bottom: 10px;
    display: flex; justify-content: center; align-items: center; min-height: 180px;
}
.qr-note { font-size: 11px; color: #8c7886; font-style: italic; }

/* Auth Forms */
.auth-tabs { display: flex; gap: 10px; margin-bottom: 16px; }
.auth-tab-btn {
    flex: 1; background: #f0e1ec; border: none; padding: 14px;
    border-radius: 14px; font-weight: 700; color: #8c7886; cursor: pointer; font-size: 13px;
}
.auth-tab-btn.active {
    background: linear-gradient(135deg, #ff3399, #ff66b2); color: white;
    box-shadow: 0 6px 18px rgba(255, 51, 153, 0.3);
}

.auth-box { background: white; border-radius: 20px; padding: 24px; border: 1px solid #f2d9eb; display: none; }
.auth-box.active { display: block; }
.auth-box h3 { font-size: 16px; color: #2b1b26; margin-bottom: 18px; font-weight: 800; }

.form-group { margin-bottom: 14px; }
.form-group label { display: block; font-size: 12px; font-weight: 700; color: #665263; margin-bottom: 6px; }
.form-group input {
    width: 100%; padding: 13px 15px; border: 1px solid #f0e1ec;
    border-radius: 12px; font-size: 13px; background: #fcf2fa; outline: none;
}
.form-group input:focus { border-color: #ff3399; background: white; }

.pass-wrapper { position: relative; display: flex; align-items: center; }
.pass-wrapper input { width: 100%; padding-right: 45px !important; }
.toggle-pass { position: absolute; right: 12px; cursor: pointer; font-size: 16px; user-select: none; opacity: 0.7; }

.btn-auth-submit {
    width: 100%; background: linear-gradient(135deg, #ff3399, #ff66b2);
    border: none; color: white; padding: 14px; border-radius: 14px;
    font-weight: 800; font-size: 14px; cursor: pointer; margin-top: 10px;
}

/* Profile */
.profile-header-box {
    background: white; border-radius: 20px; padding: 22px;
    border: 1px solid #f2d9eb; display: flex; align-items: center; gap: 16px; margin-bottom: 16px;
}
.avatar {
    font-size: 38px; background: #fcf2fa; width: 65px; height: 65px;
    border-radius: 50%; display: flex; justify-content: center; align-items: center; border: 2px solid #f5d0ec;
}
.p-details h3 { font-size: 16px; color: #2b1b26; font-weight: 800; }
.p-details p { font-size: 12px; color: #8c7886; margin-top: 3px; }

.profile-menu { background: white; border-radius: 20px; border: 1px solid #f2d9eb; overflow: hidden; }
.p-menu-item { padding: 16px 20px; font-size: 13px; font-weight: 700; color: #2b1b26; border-bottom: 1px solid #f7f1f6; cursor: pointer; }
.p-menu-item:active { background: #fcf2fa; color: #ff3399; }
.p-menu-item.logout { color: #ff3333; }

/* History */
.history-list { display: flex; flex-direction: column; gap: 12px; }
.history-item {
    background: white; padding: 16px; border-radius: 16px; border: 1px solid #f2d9eb;
    display: flex; justify-content: space-between; align-items: center;
}
.section-title { font-size: 15px; font-weight: 800; color: #2b1b26; margin-bottom: 14px; }
.h-info { display: flex; flex-direction: column; gap: 4px; }
.h-title { font-size: 13px; font-weight: 700; color: #2b1b26; }
.h-date { font-size: 11px; color: #8c7886; }
.h-status { font-size: 13px; font-weight: 800; }
.h-status.success { color: #00cc66; }
.h-status.minus { color: #ff3333; }

/* Bottom Nav */
.bottom-nav {
    position: fixed; bottom: 0; left: 0; right: 0;
    background: rgba(255, 255, 255, 0.95); backdrop-filter: blur(12px);
    border-top: 1px solid #f0e1ec; display: flex; justify-content: space-around;
    padding: 10px 0 18px 0; z-index: 100; box-shadow: 0 -4px 20px rgba(255, 77, 148, 0.08);
}
.nav-item {
    display: flex; flex-direction: column; align-items: center;
    text-decoration: none; color: #9c8a98; font-size: 11px; font-weight: 600; gap: 4px;
}
.nav-icon { font-size: 20px; }
.nav-item.active { color: #ff3399; }
.nav-item.active .nav-icon {
    background: #ff3399; color: white; width: 44px; height: 44px;
    border-radius: 50%; display: flex; justify-content: center; align-items: center;
    margin-top: -18px; box-shadow: 0 6px 18px rgba(255, 51, 153, 0.4); font-size: 18px; border: 3px solid #fff;
}

/* Floating Socials */
.floating-socials {
    position: fixed; right: 16px; bottom: 100px;
    display: flex; flex-direction: column; gap: 10px; z-index: 99;
}
.social-icon {
    width: 42px; height: 42px; border-radius: 50%;
    display: flex; justify-content: center; align-items: center;
    color: white; font-weight: 800; font-size: 16px; box-shadow: 0 4px 15px rgba(0,0,0,0.15); text-decoration: none;
}
.social-icon.zalo { background: #0068ff; font-size: 14px; }
.social-icon.tele { background: #24a1de; font-size: 14px; }

/* Modal & Toast */
.modal-bg {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5); backdrop-filter: blur(5px);
    display: none; justify-content: center; align-items: center; padding: 20px; z-index: 1000;
}
.modal-box {
    background: #ffffff; border-radius: 22px; width: 100%; max-width: 350px;
    padding: 26px; text-align: center; border: 1px solid #f2d9eb; box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}
.modal-box h2 { font-size: 17px; color: #2b1b26; margin-bottom: 8px; font-weight: 800; }
.modal-box p { font-size: 12px; color: #7a6876; margin-bottom: 16px; line-height: 1.5; }
.modal-price-tag { font-size: 24px; font-weight: 800; color: #ff3366; margin-bottom: 22px; }
.modal-btns { display: flex; gap: 10px; }
.btn-buy-ok {
    flex: 1; background: linear-gradient(135deg, #ff3399, #ff66b2);
    border: none; color: white; padding: 13px; border-radius: 14px; font-weight: 800; cursor: pointer;
}
.btn-buy-cancel {
    flex: 1; background: #f5e6f1; border: none; color: #b0578d; padding: 13px; border-radius: 14px; font-weight: 800; cursor: pointer;
}

.toast {
    position: fixed; bottom: -60px; left: 50%; transform: translateX(-50%);
    background: #2b1b26; color: white; padding: 12px 24px; border-radius: 30px;
    font-size: 12px; font-weight: 700; box-shadow: 0 8px 25px rgba(0,0,0,0.25); transition: 0.3s; z-index: 2000;
}
.toast.show { bottom: 95px; }
