:root {
    --bg-body: #002B2B;
    --bg-sidebar: #004242;
    --bg-header: #003333;
    --bg-card: #005252;
    --bg-sidebar-btn: #003838;
    
    --primary: #FFD700;
    --primary-hover: #FFC107;
    --secondary: #00E5FF; /* Cyan/Teal for buttons */
    --secondary-dark: #00B8D4;
    --danger: #FF4444;
    
    --text-main: #FFFFFF;
    --text-muted: #B2DFDB;
    
    --sidebar-width: 280px;
    --header-height: 70px;
}

body {
    background-color: var(--bg-body);
    background-image: linear-gradient(rgba(0, 43, 43, 0.7), rgba(0, 43, 43, 0.7)), url('https://www.ck444app.net/img/common-bg.a7e43c94.jpg');
    background-attachment: fixed;
    background-size: cover;
    background-position: center;
    color: var(--text-main);
    font-family: 'Roboto', sans-serif;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* --- SCROLLBARS --- */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(0, 229, 255, 0.2); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary); }
* { scrollbar-width: thin; scrollbar-color: rgba(0, 229, 255, 0.2) transparent; }

/* --- SIDEBAR --- */
#sidebar {
    background-color: var(--bg-sidebar);
    width: var(--sidebar-width);
    transition: transform 0.3s ease, width 0.3s ease;
    position: fixed;
    top: var(--header-height);
    bottom: 0;
    left: 0;
    z-index: 40;
    overflow-y: auto;
    border-right: 1px solid rgba(255,255,255,0.05);
    padding: 10px;
}

body.sidebar-hidden #sidebar { width: 0; padding: 0; overflow: hidden; border: none; }
body.sidebar-hidden #main-content { margin-left: 0; }

.sidebar-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.sidebar-item {
    background-color: #053b3b;
    border-radius: 12px;
    padding: 15px 5px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    border: 1px solid rgba(255,255,255,0.05);
    height: 95px;
    position: relative;
    box-shadow: 0 4px 0 rgba(0,0,0,0.2);
}
.sidebar-item:active { transform: translateY(2px); box-shadow: 0 2px 0 rgba(0,0,0,0.2); }
.sidebar-item:hover { background-color: #074e4e; border-color: var(--secondary); }
.sidebar-item.active-mark { background: linear-gradient(180deg, #095c5c 0%, #053b3b 100%); border-color: var(--secondary); }
.sidebar-item i { font-size: 1.8rem; margin-bottom: 8px; filter: drop-shadow(0 2px 2px rgba(0,0,0,0.3)); }
.sidebar-item span { font-size: 0.8rem; font-weight: 500; line-height: 1.2; color: #e0f7fa; }

/* --- HEADER --- */
#header { height: var(--header-height); background-color: var(--bg-header); border-bottom: 1px solid rgba(255,255,255,0.05); z-index: 1200; position: fixed; width: 100%; }

/* Dropdown */
.dropdown-menu {
    position: absolute; top: 100%; right: 0; width: 260px;
    background-color: #002222; border: 1px solid var(--secondary);
    border-radius: 8px; box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    opacity: 0; visibility: hidden; transform: translateY(10px);
    transition: all 0.2s; z-index: 100; overflow: hidden; margin-top: 5px;
}
.dropdown-menu.active { opacity: 1; visibility: visible; transform: translateY(0); }
.dropdown-item { padding: 12px 20px; display: flex; align-items: center; color: var(--text-main); transition: background 0.2s; border-bottom: 1px solid rgba(255,255,255,0.05); cursor: pointer; font-size: 0.9rem; }
.dropdown-item:last-child { border-bottom: none; }
.dropdown-item:hover { background-color: rgba(0, 229, 255, 0.1); color: var(--secondary); }
.dropdown-item i { width: 24px; margin-right: 10px; text-align: center; }

/* Modals Generic */
.modal-backdrop {
    position: fixed; inset: 0; background: rgba(0,0,0,0.8); z-index: 2000;
    display: flex; align-items: center; justify-content: center; opacity: 0; pointer-events: none;
    transition: opacity 0.3s; backdrop-filter: blur(3px);
}
.modal-backdrop.open { opacity: 1; pointer-events: auto; }

/* Standard Modal (Notifications etc) */
.modal-content {
    background: var(--bg-sidebar); width: 450px; max-width: 95%; border-radius: 16px;
    border: 1px solid var(--primary); overflow: hidden; box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    transform: scale(0.95); transition: transform 0.3s; display: flex; flex-direction: column; max-height: 90vh;
}
.modal-backdrop.open .modal-content { transform: scale(1); }

/* Search Modal Styles */
.search-modal-content {
    background: var(--bg-sidebar); width: 600px; max-width: 95%; border-radius: 16px;
    border: 1px solid var(--primary); overflow: hidden; box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    transform: scale(0.95); transition: transform 0.3s; display: flex; flex-direction: column; max-height: 85vh;
}
.search-header-area { padding: 20px; background: rgba(0,0,0,0.2); border-bottom: 1px solid rgba(255,255,255,0.1); }
.search-input-wrapper { position: relative; width: 100%; }
.search-input-wrapper i { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); color: var(--primary); }
.search-input-field { width: 100%; background: #002222; border: 1px solid var(--secondary); border-radius: 50px; padding: 12px 40px 12px 45px; color: white; outline: none; font-size: 1rem; }
.search-input-field:focus { box-shadow: 0 0 0 2px rgba(0, 229, 255, 0.3); }
.search-close-btn { position: absolute; right: 30px; top: 50%; transform: translateY(-50%); color: #ccc; cursor: pointer; }
.search-close-btn:hover { color: var(--danger); }
.search-results-area { padding: 20px; overflow-y: auto; flex: 1; }
.search-section-title { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 15px; text-transform: uppercase; letter-spacing: 1px; font-weight: bold; }
.search-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }

/* TASK: View All Modal Styles (Reusing Search Modal Styles for consistency) */
.view-all-modal-content {
    background: var(--bg-sidebar); 
    width: 800px; /* Wider for full grid */
    max-width: 95%; 
    border-radius: 16px;
    border: 1px solid var(--primary); 
    overflow: hidden; 
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    transform: scale(0.95); 
    transition: transform 0.3s; 
    display: flex; 
    flex-direction: column; 
    height: 85vh;
}
.view-all-header {
    padding: 15px 20px;
    background: rgba(0,0,0,0.2);
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.view-all-title {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--primary);
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 10px;
}
.view-all-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}
.view-all-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr); /* 5 cards per row desktop */
    gap: 12px;
}

/* Auth Modal */
.auth-modal-content { background: #003B3B; border: 1px solid #005f5f; color: white; }
.auth-header { display: flex; justify-content: space-between; align-items: center; padding: 15px 20px; border-bottom: none; }
.auth-title { font-size: 1.5rem; color: var(--primary); font-weight: bold; }
.auth-body { padding: 20px; }
.auth-input-group { position: relative; margin-bottom: 15px; }
.auth-input-group i { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); color: #00E5FF; z-index: 10; }
.auth-input-prefix { position: absolute; left: 45px; top: 50%; transform: translateY(-50%); color: #ccc; font-weight: 500; font-size: 0.95rem; z-index: 10; }
.auth-input { width: 100%; background: #002222; border: 1px solid #004444; border-radius: 8px; padding: 12px 15px 12px 45px; color: white; outline: none; transition: 0.2s; }
.auth-input.has-prefix { padding-left: 90px; }
.auth-input:focus { border-color: var(--primary); }
.auth-btn { width: 100%; background: linear-gradient(180deg, #FFEB3B 0%, #FFC107 100%); color: #3e2723; font-weight: bold; padding: 12px; border-radius: 8px; box-shadow: 0 4px 0 #b78900; margin-top: 10px; margin-bottom: 20px; }
.auth-btn:active { transform: translateY(2px); box-shadow: 0 2px 0 #b78900; }
.social-btn { width: 100%; padding: 10px; border-radius: 8px; color: white; font-weight: bold; display: flex; align-items: center; justify-content: center; gap: 10px; cursor: pointer; box-shadow: 0 3px 0 rgba(0,0,0,0.2); }
.social-google { background-color: #DB4437; }
.social-fb { background-color: #4267B2; }

/* MMB Profile Modal Styles */
.mmb_profile-modal-content { background: #002222; width: 640px; max-width: 95%; border-radius: 16px; border: 1px solid var(--secondary); overflow: hidden; display: flex; flex-direction: column; max-height: 90vh; }
.mmb_profile-header-bg { background: linear-gradient(to bottom, #004d40, #002222); padding: 20px; display: flex; align-items: center; gap: 15px; position: relative; }
.mmb_profile-avatar { width: 60px; height: 60px; border-radius: 50%; border: 2px solid var(--primary); padding: 2px; }
.mmb_profile-avatar img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.mmb_profile-info h3 { color: white; font-weight: bold; margin: 0; font-size: 1.1rem; }
.mmb_profile-info p { color: var(--text-muted); font-size: 0.8rem; margin: 2px 0 0 0; }
.mmb_vip-badge { background: linear-gradient(90deg, #FFD700, #FFA000); color: black; font-weight: bold; font-size: 0.7rem; padding: 2px 8px; border-radius: 10px; margin-top: 5px; display: inline-block; }
.mmb_profile-close-btn { position: absolute; top: 15px; right: 15px; color: rgba(255,255,255,0.6); cursor: pointer; font-size: 1.2rem; }
.mmb_profile-close-btn:hover { color: white; }
.mmb_profile-body { padding: 20px; overflow-y: auto; flex: 1; }

.mmb_wallet-card { background: linear-gradient(135deg, #3E2723, #5D4037); border-radius: 12px; padding: 15px; color: #FFD700; margin-bottom: 20px; position: relative; box-shadow: 0 4px 10px rgba(0,0,0,0.3); border: 1px solid rgba(255, 215, 0, 0.3); }
.mmb_wallet-label { font-size: 0.8rem; opacity: 0.8; display: flex; align-items: center; gap: 5px; }
.mmb_wallet-amount { font-size: 1.8rem; font-weight: bold; margin-top: 5px; color: white; }
.mmb_wallet-refresh { cursor: pointer; transition: transform 0.5s; }
.mmb_wallet-refresh:hover { transform: rotate(180deg); }

.mmb_profile-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; margin-bottom: 25px; }
.mmb_p-action-btn { padding: 12px; border-radius: 8px; text-align: center; font-weight: bold; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px; box-shadow: 0 4px 0 rgba(0,0,0,0.2); transition: transform 0.1s; }
.mmb_p-btn-dep { background: linear-gradient(180deg, #FFEB3B 0%, #FBC02D 100%); color: #3E2723; }
.mmb_p-btn-wdr { background: linear-gradient(180deg, #4DD0E1 0%, #0097A7 100%); color: #004D40; }
.mmb_p-action-btn:active { transform: translateY(2px); box-shadow: 0 2px 0 rgba(0,0,0,0.2); }

.mmb_profile-menu-container { background: rgba(255,255,255,0.02); border-radius: 12px; padding: 15px; margin-bottom: 20px; border: 1px solid rgba(255,255,255,0.05); }
.mmb_profile-menu-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 15px 10px; }
.mmb_p-menu-item { display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 8px; cursor: pointer; text-align: center; }
.mmb_p-menu-icon-box { width: 45px; height: 45px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 1.5rem; transition: 0.2s; background: rgba(255,255,255,0.05); color: white; box-shadow: 0 4px 6px rgba(0,0,0,0.2); }
.mmb_p-menu-item:hover .mmb_p-menu-icon-box { transform: translateY(-3px); filter: brightness(1.2); }

.mmb_icon-history { color: #FF9800; background: rgba(255, 152, 0, 0.1); }
.mmb_icon-trans { color: #4CAF50; background: rgba(76, 175, 80, 0.1); }
.mmb_icon-reward { color: #E91E63; background: rgba(233, 30, 99, 0.1); }
.mmb_icon-inbox { color: #2196F3; background: rgba(33, 150, 243, 0.1); }
.mmb_icon-safe { color: #9C27B0; background: rgba(156, 39, 176, 0.1); }
.mmb_icon-support { color: #00BCD4; background: rgba(0, 188, 212, 0.1); }
.mmb_icon-ref { color: #FFC107; background: rgba(255, 193, 7, 0.1); }
.mmb_icon-about { color: #607D8B; background: rgba(96, 125, 139, 0.1); }
.mmb_p-menu-text { font-size: 0.7rem; color: var(--text-muted); font-weight: 500; line-height: 1.1; }

.mmb_profile-list-menu { display: flex; flex-direction: column; gap: 8px; }
.mmb_p-list-item { display: flex; justify-content: space-between; align-items: center; padding: 12px 15px; background: rgba(255,255,255,0.03); border-radius: 8px; color: white; cursor: pointer; transition: 0.2s; border: 1px solid rgba(255,255,255,0.02); }
.mmb_p-list-item:hover { background: rgba(255,255,255,0.08); }
.mmb_logout-btn { width: 100%; padding: 12px; text-align: center; color: #ff4444; border: 1px solid #ff4444; border-radius: 8px; font-weight: bold; margin-top: 20px; cursor: pointer; transition: 0.2s; background: rgba(255, 68, 68, 0.05); }
.mmb_logout-btn:hover { background: rgba(255, 68, 68, 0.1); }

.mmb_support-btn { width: 100%; padding: 15px; border-radius: 12px; color: white; font-weight: bold; font-size: 1.1rem; display: flex; align-items: center; justify-content: center; gap: 15px; cursor: pointer; box-shadow: 0 4px 0 rgba(0,0,0,0.3); transition: transform 0.1s; margin-bottom: 15px; text-decoration: none; }
.mmb_support-btn:active { transform: translateY(2px); box-shadow: 0 2px 0 rgba(0,0,0,0.3); }
.mmb_btn-whatsapp { background: linear-gradient(180deg, #25D366 0%, #128C7E 100%); }
.mmb_btn-telegram { background: linear-gradient(180deg, #0088cc 0%, #005f8f 100%); }
.mmb_btn-livechat { background: linear-gradient(180deg, #FF9800 0%, #F57C00 100%); }

.mmb_list-card { background: rgba(255,255,255,0.05); border-radius: 8px; padding: 12px; margin-bottom: 10px; border: 1px solid rgba(255,255,255,0.05); }
.mmb_list-row { display: flex; justify-content: space-between; font-size: 0.9rem; margin-bottom: 5px; }
.mmb_list-label { color: var(--text-muted); }
.mmb_list-val { color: white; font-weight: bold; }
.mmb_status-win { color: #00E676; }
.mmb_status-loss { color: #FF5252; }
.mmb_status-pending { color: #FFC107; }

.mmb_table-container { width: 100%; overflow-x: auto; }
.mmb_custom-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; color: #ddd; }
.mmb_custom-table th { background: rgba(255,255,255,0.05); color: var(--secondary); padding: 12px; text-align: left; font-weight: bold; border-bottom: 1px solid rgba(255,255,255,0.1); }
.mmb_custom-table td { padding: 12px; border-bottom: 1px solid rgba(255,255,255,0.05); }
.mmb_custom-table tr:hover { background: rgba(255,255,255,0.02); }

/* Announcement Modal */
.announcement-modal { width: 800px; height: 500px; display: flex; flex-direction: row; background: #003333; border: 1px solid var(--secondary); }
.announcement-sidebar { width: 250px; background: #002222; display: flex; flex-direction: column; border-right: 1px solid rgba(255,255,255,0.1); overflow-y: auto; }
.ann-header { padding: 15px; color: var(--primary); font-size: 1.2rem; font-weight: bold; border-bottom: 1px solid rgba(255,255,255,0.1); background: rgba(0,0,0,0.2); }
.ann-item { padding: 15px; color: #b2dfdb; border-bottom: 1px solid rgba(255,255,255,0.05); cursor: pointer; transition: all 0.2s; display: flex; align-items: center; gap: 12px; font-size: 0.9rem; position: relative; }
.ann-item:hover { background: rgba(255,255,255,0.05); }
.ann-item.active { background: linear-gradient(90deg, #FFEB3B, #FFC107); color: #3e2723; font-weight: bold; }
.ann-item.active::after { content: ''; position: absolute; right: 0; top: 0; bottom: 0; width: 4px; background: #FF5722; }
.announcement-body { flex: 1; padding: 25px; overflow-y: auto; background: #003333; position: relative; display: flex; flex-direction: column; gap: 15px; }
.ann-close-btn { position: absolute; top: 10px; right: 10px; width: 30px; height: 30px; border-radius: 50%; background: rgba(0,0,0,0.4); color: white; display: flex; align-items: center; justify-content: center; cursor: pointer; z-index: 20; transition: 0.2s; }
.ann-close-btn:hover { background: var(--danger); transform: rotate(90deg); }
.ann-content-section.hidden { display: none; }
.announcement-footer { display: none; padding: 15px; gap: 10px; justify-content: space-between; margin-top: auto; }
.ann-nav-btn { flex: 1; background: linear-gradient(180deg, #FFEB3B 0%, #FFC107 100%); color: #b71c1c; font-weight: 900; border-radius: 50px; padding: 10px; box-shadow: 0 4px 0 #b78900; text-align: center; font-size: 1rem; cursor: pointer; transition: transform 0.1s; }
.ann-nav-btn:active { transform: translateY(2px); box-shadow: 0 2px 0 #b78900; }

/* General UI Elements - Task 1: Fixed Notification */
.sticky-notification-bar {
    position: relative; /* its can be sticky */
    top: 0px; /* Just below header */
    z-index: 45;
    background: rgba(0, 43, 43, 0.95); /* Better visibility */
    backdrop-filter: blur(5px);
    border-radius: 30px;
}

.marquee-container { background: transparent; overflow: hidden; white-space: nowrap; position: relative; }
.marquee-content { display: inline-block; animation: marquee 20s linear infinite; }
@keyframes marquee { 0% { transform: translateX(100%); } 100% { transform: translateX(-100%); } }

.btn-gold { background: linear-gradient(180deg, #FFEB3B 0%, #FFC107 100%); color: #3e2723; font-weight: bold; box-shadow: 0 4px 0 #b78900; border-radius: 8px; transition: all 0.1s; flex-shrink: 0; }
.btn-gold:active { transform: translateY(2px); box-shadow: 0 2px 0 #b78900; }
.btn-gold:hover { filter: brightness(1.1); }

.btn-cyan { background: linear-gradient(180deg, #4DD0E1 0%, #00BCD4 100%); color: #004D40; font-weight: bold; box-shadow: 0 4px 0 #008ba3; border-radius: 8px; transition: all 0.1s; flex-shrink: 0; }
.btn-cyan:active { transform: translateY(2px); box-shadow: 0 2px 0 #008ba3; }
.btn-cyan:hover { filter: brightness(1.1); }

.nav-btn-box { background-color: #004D40; color: var(--secondary); border: 1px solid rgba(255,255,255,0.1); border-radius: 8px; box-shadow: 0 3px 0 rgba(0,0,0,0.3); transition: all 0.1s; flex-shrink: 0; }
.nav-btn-box:hover { background-color: #00695C; color: white; }
.nav-btn-box:active { transform: translateY(2px); box-shadow: 0 1px 0 rgba(0,0,0,0.3); }

.game-card { border-radius: 12px; overflow: hidden; aspect-ratio: 1/1; background-size: cover; background-position: center; position: relative; transition: transform 0.2s; width: 100%; box-shadow: 0 4px 6px rgba(0,0,0,0.3); }
.game-card:hover { transform: translateY(-3px); z-index: 10; box-shadow: 0 10px 20px rgba(0,0,0,0.5); border: 2px solid var(--secondary); }
.game-card .overlay { position: absolute; inset: 0; background: rgba(0,0,0,0.6); display: flex; flex-direction: column; align-items: center; justify-content: center; opacity: 0; transition: 0.3s; }
.game-card:hover .overlay { opacity: 1; }
.fav-btn { position: absolute; top: 10px; right: 10px; color: white; z-index: 20; cursor: pointer; transition: transform 0.2s; text-shadow: 0 2px 4px rgba(0,0,0,0.8); }
.fav-btn:hover { transform: scale(1.2); }
.fav-btn.active { color: var(--danger); }

@keyframes shine-periodic-anim { 0% { transform: translateX(-150%) skewX(-25deg); } 20% { transform: translateX(250%) skewX(-25deg); } 100% { transform: translateX(250%) skewX(-25deg); } }
.game-card::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.4) 50%, rgba(255,255,255,0) 100%); transform: translateX(-150%) skewX(-25deg); pointer-events: none; z-index: 15; will-change: transform; animation: shine-periodic-anim 10s infinite linear; }
@keyframes shine-hover-anim { 0% { transform: translateY(-150%); opacity: 0; } 10% { opacity: 1; } 100% { transform: translateY(150%); opacity: 1; } }
.game-card::after { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(to bottom, rgba(255,255,255,0) 0%, rgba(255,255,255,0.6) 50%, rgba(255,255,255,0) 100%); transform: translateY(-150%); pointer-events: none; z-index: 16; will-change: transform; }
.game-card:hover::after { animation: shine-hover-anim 0.6s ease-out forwards; }

.trending-section { display: flex; align-items: stretch; background: rgba(0,0,0,0.2); border-radius: 12px; overflow: hidden; border: 1px solid rgba(255,255,255,0.05); }
.jackpot-box { width: 220px; flex-shrink: 0; background: linear-gradient(135deg, #0f2027 0%, #203a43 50%, #2c5364 100%); position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; z-index: 10; box-shadow: 5px 0 15px rgba(0,0,0,0.5); border-right: 1px solid var(--primary); padding: 10px; }
.jackpot-plane { font-size: 3rem; color: #ff4444; animation: float 3s ease-in-out infinite; text-shadow: 0 5px 10px rgba(0,0,0,0.5); margin-bottom: 5px; }
@keyframes float { 0% { transform: translateY(0px) rotate(0deg); } 50% { transform: translateY(-5px) rotate(2deg); } 100% { transform: translateY(0px) rotate(0deg); } }
.jackpot-text { color: var(--primary); font-weight: 900; font-size: 1.2rem; text-transform: uppercase; letter-spacing: 1px; }
.jackpot-counter { background: white; color: black; font-family: monospace; font-weight: bold; padding: 2px 8px; border-radius: 4px; font-size: 1.1rem; margin-top: 5px; box-shadow: 0 2px 5px rgba(0,0,0,0.5); }
.trending-slider-wrapper { flex: 1; min-width: 0; position: relative; background: rgba(0,0,0,0.1); padding: 10px 0; overflow: hidden; }
.trending-slider-wrapper .swiper-slide { height: auto; display: flex; align-items: center; justify-content: center; padding: 5px 10px; }
.trending-slider-wrapper:hover .swiper-wrapper { animation-play-state: paused !important; }
.game-slider { overflow: hidden !important; padding: 15px 10px !important; margin: 0 -10px; }

.mob-bottom-nav { position: fixed; bottom: 0; left: 0; width: 100%; height: 70px; background-color: var(--bg-header); display: none; justify-content: space-around; align-items: center; z-index: 1300; border-top: 1px solid rgba(255,255,255,0.1); padding-bottom: 5px; box-shadow: 0 -5px 15px rgba(0,0,0,0.5); border-top-left-radius: 20px; border-top-right-radius: 20px; }
.mob-nav-item { display: flex; flex-direction: column; align-items: center; justify-content: center; color: var(--text-muted); font-size: 0.7rem; cursor: pointer; width: 20%; transition: 0.2s; position: relative; }
.mob-nav-item i { font-size: 1.4rem; margin-bottom: 4px; }
.mob-nav-item.active { color: var(--primary); font-weight: bold; }
.mob-nav-item.center-item { position: relative; }
.mob-center-circle { width: 65px; height: 65px; background: linear-gradient(135deg, var(--secondary), #00ACC1); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #002B2B; font-size: 1.8rem; margin-bottom: -25px; transform: translateY(-25px); border: 6px solid var(--bg-body); box-shadow: 0 -5px 15px rgba(0,229,255,0.4); position: relative; z-index: 1350; }
.mob-nav-item.center-item span { margin-top: 10px; font-weight: bold; color: var(--text-main); }

.notif-item { padding: 15px; border-bottom: 1px solid rgba(255,255,255,0.1); transition: background 0.2s; cursor: pointer; }
.notif-item:hover { background-color: rgba(255,255,255,0.02); }
.notif-item.unread { background-color: rgba(0, 229, 255, 0.05); border-left: 3px solid var(--secondary); }
.notif-item.unread h4 { color: var(--secondary); font-weight: 700; }

/* Main Content */
#main-content { margin-left: var(--sidebar-width); margin-top: var(--header-height); transition: margin-left 0.3s ease; min-height: calc(100vh - var(--header-height)); display: flex; flex-direction: column; }
/* Task 2: Body Content Padding (Enhanced) */
.content-body { flex: 1; padding: 20px; width: 100%; max-width: 1600px; margin: 0 auto; box-sizing: border-box; }
.scroll-menu { display: flex; overflow-x: auto; gap: 10px; padding-bottom: 5px; }

/* Updated Menu Pill - Task 3 fix */
.menu-pill { 
    background: var(--bg-card); color: var(--text-muted); padding: 10px; min-width: 80px; 
    border-radius: 8px; border: 1px solid rgba(255,255,255,0.05); display: flex; 
    flex-direction: column; align-items: center; justify-content: center; transition: 0.2s; 
    white-space: nowrap; box-shadow: 0 2px 0 rgba(0,0,0,0.2); 
    flex-shrink: 0; /* Important: Prevents squashing on mobile */
    cursor: pointer; 
}
.menu-pill.active, .menu-pill:hover { background: linear-gradient(145deg, #00695c, #004d40); border-color: var(--secondary); color: white; transform: translateY(1px); }

@media (max-width: 1024px) {
    body.sidebar-hidden #sidebar { 
        width: 280px;
        padding-top: 10px;
        padding-bottom: 20px;
        overflow-y: auto;
        border-right: none;
    }
    /* Task 3 & FIX: Mobile Sidebar Anchor Logic */
    #sidebar { 
        transform: translateX(-100%); 
        width: 280px; 
        
        /* Anchoring top and bottom is more robust than calc(100vh) for scrolling */
        top: var(--header-height); /* 70px */
        bottom: 0; 
        height: auto; /* Let top/bottom define the height */
        
        z-index: 1400; /* Above Bottom Nav (1300) */
        border-right: none; 
        
        /* Force Scroll */
        overflow-y: auto; 
        -webkit-overflow-scrolling: touch; /* Smooth scrolling */
        overscroll-behavior: contain; /* Prevents body scroll when sidebar ends */
        
        /* Updated Padding as requested */
        padding-top: 10px;
        padding-bottom: 20px;
        
        display: block;
        transition: transform 0.3s ease;
        background-color: var(--bg-sidebar); /* Ensure bg covers full height */
    }
    #sidebar.mobile-open { transform: translateX(0); }
    #main-content { margin-left: 0 !important; padding-bottom: 90px; }
    #sidebar-overlay { position: fixed; inset: 0; top: var(--header-height); background: rgba(0,0,0,0.5); z-index: 1050; display: none; }
    #sidebar-overlay.active { display: block; }
    .trending-section { flex-direction: column; height: auto; }
    .jackpot-box { width: 100%; height: auto; border-right: none; border-bottom: 1px solid var(--primary); flex-direction: row; justify-content: space-between; gap: 10px; padding: 15px; }
    .jackpot-plane { font-size: 2rem; margin-bottom: 0; }
    .jackpot-text { font-size: 1rem; }
    .jackpot-counter { font-size: 1rem; margin-top: 0; }
    .trending-slider-wrapper { height: auto; padding: 15px 0; }
    .mob-bottom-nav { display: flex; }
    
    #modal-announcement .modal-content { width: 95% !important; height: 80vh !important; max-width: 500px !important; border-radius: 16px !important; border: 1px solid var(--secondary) !important; display: flex !important; flex-direction: column !important; margin: auto; }
    
    /* Full screen modals for Profile Sub-menus */
    #modal-login .modal-content, 
    #modal-register .modal-content, 
    #modal-notification .modal-content, 
    #modal-profile .mmb_profile-modal-content,
    #modal-bet-history .mmb_profile-modal-content,
    #modal-transaction .mmb_profile-modal-content,
    #modal-rewards .mmb_profile-modal-content,
    #modal-inbox .mmb_profile-modal-content,
    #modal-safe .mmb_profile-modal-content,
    #modal-support .mmb_profile-modal-content,
    #modal-referral .mmb_profile-modal-content,
    #modal-about .mmb_profile-modal-content,
    #modal-deposit .mmb_profile-modal-content,
    #modal-view-all .view-all-modal-content,
    #modal-search .search-modal-content,
    #modal-withdraw .mmb_profile-modal-content { 
        width: 100% !important; height: 100% !important; max-width: none !important; max-height: none !important; border-radius: 0 !important; border: none !important; 
    }
    .search-modal-content { width: 95% !important; height: auto !important; max-height: 80vh !important; margin: auto; }
    .search-grid { grid-template-columns: repeat(3, 1fr); }
    .announcement-sidebar { display: none; }
    .announcement-footer { display: flex; }
    .ann-content-section { height: 100%; overflow-y: auto; padding-top: 10px; }
    .auth-header, .bg-\[var\(--bg-header\)\] { padding-top: 20px; }
    #modal-profile .mmb_profile-body { padding-bottom: 50px; }
    
    /* Task 2: Mobile Padding */
    .content-body { padding: 10px; } 
}