/* Inatips Style - Matching Reference Site */

/* CSS Variables */
:root {
    --max-width: 1200px;
    --padding-horizontal: 15px;
    
    /* Breakpoint System */
    --xs-mobile: 320px;  /* Extra Small Mobile */
    --mobile: 576px;     /* Mobile */
    --tablet: 768px;     /* Tablet */
    --desktop: 992px;    /* Desktop */
    --large: 1200px;     /* Large Desktop */
    
    /* Responsive Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    
    /* Responsive Typography */
    --font-xs: 10px;
    --font-sm: 12px;
    --font-base: 14px;
    --font-md: 16px;
    --font-lg: 18px;
    --font-xl: 20px;
    
    /* CSS Variables are now generated dynamically by generateThemeCSS() function */
    /* All color variables are injected via PHP in head.php */
    --accent-medium: var(--accent-color)80;
    
    --background-light: var(--background-color)20;
    --background-medium: var(--background-color)80;
    --background-dark: var(--background-color)F0;
    
    --text-light: var(--text-color)99;
    --text-medium: var(--text-color)CC;
    
    /* Common UI colors */
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --info-color: #17a2b8;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100vw;
    max-width: 100vw;
    margin: 0 !important;
    padding: 0 !important;
    overflow-x: hidden;
    position: relative;
    left: 0 !important;
    right: 0 !important;
}

/* Container Layout */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    box-sizing: border-box;
}

.main-container, .markets-grid, .market-card {
    box-sizing: border-box;
}

body {
    background: #000000 !important;
    color: #ffffff;
    font-family: 'Arial', sans-serif;
    font-size: 14px;
    line-height: 1.6;
}

/* Top Info Bar - Responsive design */
.top-info-bar {
    background: #000000;
    padding: 5px 0;
    font-size: 10px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.top-info-content {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--padding-horizontal);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Mobile responsive for top info bar */
/* Tablet */
@media (max-width: 768px) {
    .top-info-bar {
        padding: 4px 0;
        font-size: var(--font-xs);
    }
    
    .top-info-content {
        padding: 0 var(--space-md);
        gap: var(--space-xs);
    }
    
    .top-info-left {
        gap: var(--space-xs);
    }
    
    .separator {
        margin: 0 var(--space-xs);
    }
}

/* Mobile */
@media (max-width: 576px) {
    .top-info-bar {
        padding: 3px 0;
        font-size: 9px;
    }
    
    .top-info-content {
        padding: 0 var(--space-sm);
        gap: 2px;
    }
    
    .top-info-left {
        gap: 2px;
    }
    
    .separator {
        margin: 0 2px;
    }
}

/* Mobile Menu Stack - Hidden on Desktop */
.mobile-menu-stack {
    display: none;
}

/* Desktop: Show normal menu, hide mobile stack */
@media (min-width: 769px) {
    .top-info-left {
        display: flex !important;
    }
    
    .mobile-menu-stack {
        display: none !important;
    }
}

/* Tablet & Mobile: Hide desktop menu, show mobile stack */
@media (max-width: 768px) {
    .top-info-left {
        display: none !important;
    }
    
    .mobile-menu-stack {
        display: block;
        width: 100%;
        background: #000000;
    }
}

@media (max-width: 768px) {
    
    .menu-row {
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 0;
        gap: 6px;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        height: 23px;
        box-sizing: border-box;
    }
    
    .menu-row:last-child {
        border-bottom: none;
    }
    
    .menu-row i {
        color: var(--primary-color);
        font-size: 12px;
        display: flex;
        align-items: center;
    }
    
    .top-link-small {
        color: #ffffff;
        text-decoration: none;
        font-size: 10px;
        font-weight: 600;
        text-transform: uppercase;
        display: flex;
        align-items: center;
        line-height: 1;
    }
    
    .top-link-small:hover {
        color: var(--primary-color);
    }
    
    .separator {
        color: var(--primary-color);
        margin: 0 4px;
    }
}

.top-info-left {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--primary-color);
    font-weight: 500;
}

.top-info-left i {
    color: var(--primary-color);
    font-size: 10px;
    margin-right: 2px;
}

.top-link {
    color: #ffffff;
    text-decoration: none;
    font-size: 10px;
    font-weight: 400;
    text-transform: uppercase;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    line-height: 1;
}

.top-link:hover {
    color: var(--primary-color);
}

.separator {
    color: var(--primary-color);
    margin: 0 4px;
    font-size: 10px;
}

.top-info-right {
    display: flex;
    align-items: center;
    gap: 10px;
}



.current-time {
    color: #ccc;
    font-weight: 400;
    font-size: 10px;
}



.top-info-left span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.top-info-left i {
    color: var(--primary-color);
    font-size: 12px;
}

.top-info-right span {
    color: #ccc;
    font-weight: 500;
}

.whatsapp-btn {
    background: #075e54;
    color: white !important;
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 11px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 4px;
}

.whatsapp-btn:hover {
    background: var(--secondary-color);
    transform: scale(1.05);
}

.text-success {
    color: var(--success-color);
}

.whatsapp-btn:hover {
    background: var(--accent-color);
    transform: translateY(-1px);
}

/* Welcome Section */
.welcome-section {
    background: linear-gradient(135deg, var(--background-color), #000000);
    padding: 15px 0;
    text-align: center;
    border-bottom: 2px solid #ffd700;
}

.welcome-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--padding-horizontal);
}

.welcome-text {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.welcome-greeting {
    font-size: 18px;
    font-weight: bold;
    color: #ffd700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.welcome-desc {
    font-size: 12px;
    color: #bdc3c7;
    line-height: 1.4;
}

/* Welcome Section Responsive */
/* Tablet */
@media (max-width: 768px) {
    .welcome-section {
        padding: var(--space-md) 0;
    }
    
    .welcome-container {
        padding: 0 var(--space-md);
    }
    
    .welcome-greeting {
        font-size: var(--font-md);
    }
    
    .welcome-desc {
        font-size: var(--font-sm);
    }
}

/* Mobile */
@media (max-width: 576px) {
    .welcome-section {
        padding: var(--space-sm) 0;
    }
    
    .welcome-container {
        padding: 0 var(--space-sm);
    }
    
    .welcome-greeting {
        font-size: var(--font-base);
    }
    
    .welcome-desc {
        font-size: 11px;
    }
}

/* Extra Small Mobile */
@media (max-width: 480px) {
    .welcome-greeting {
        font-size: var(--font-sm);
    }
    
    .welcome-desc {
        font-size: var(--font-xs);
        display: none; /* Hide description on very small screens */
    }
}

/* Banner Section - Responsive */
.banner-section {
    background: #000000;
    padding: 10px 0;
}

.banner-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--padding-horizontal);
}

.banner-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

/* Banner Responsive */
/* Tablet */
@media (max-width: 768px) {
    .banner-section {
        padding: var(--space-sm) 0;
    }
    
    .banner-container {
        padding: 0 var(--space-md);
    }
    
    .banner-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-sm);
    }
    
    .banner-item img {
        height: 140px;
        object-fit: cover;
    }
}

/* Mobile */
@media (max-width: 576px) {
    .banner-section {
        padding: 5px 0;
    }
    
    .banner-container {
        padding: 0 var(--space-sm);
    }
    
    .banner-grid {
        grid-template-columns: 1fr;
        gap: var(--space-sm);
    }
    
    .banner-item img {
        height: 231px;
        object-fit: cover;
    }
}

/* Extra Small Mobile */
@media (max-width: 480px) {
    .banner-grid {
        gap: 5px;
    }
    
    .banner-item img {
        height: 231px;
    }
}

.banner-item {
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    border: 1px solid rgba(255,255,255,0.05);
}

.banner-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.banner-item img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

.banner-item:hover img {
    transform: scale(1.02);
}

.banner-item a {
    display: block;
}

/* Marquee Section */
.marquee-section {
    padding: 8px 0;
}

.marquee-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0px var(--padding-horizontal);
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.1), rgba(0,0,0,0.1));
    border-top: 1px solid var(--primary-color);
    border-bottom: 1px solid var(--primary-color);
    border-radius: 0;
    overflow: hidden;
}

.marquee-text {
    display: inline-block;
    white-space: nowrap;
    animation: marqueeMove 25s linear infinite;
    color: #ffffff;
    font-weight: 600;
    font-size: 14px;
}

/* Marquee Responsive */
/* Tablet */
@media (max-width: 768px) {
    .marquee-section {
        padding: var(--space-xs) 0;
    }
    
    .marquee-container {
        padding: var(--space-xs) var(--space-md);
    }
    
    .marquee-text {
        font-size: var(--font-sm);
        animation: marqueeMove 22s linear infinite;
    }
}

/* Mobile */
@media (max-width: 576px) {
    .marquee-container {
        padding: var(--space-xs) var(--space-sm);
    }
    
    .marquee-text {
        font-size: var(--font-sm);
        animation: marqueeMove 20s linear infinite;
    }
}

/* Extra Small Mobile */
@media (max-width: 480px) {
    .marquee-text {
        font-size: 11px;
        animation: marqueeMove 15s linear infinite;
    }
}

@keyframes marqueeMove {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

/* Banner Carousel */
.banner-carousel {
    background: #000000;
    padding: 15px 0;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

/* Action Buttons */
/* Action Buttons - Exact match to reference */
.action-buttons-section {
    background: #000000;
    padding: 8px 0;
}

.action-buttons-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--padding-horizontal);
    display: flex;
    justify-content: space-between;
    gap: 8px;
}

.action-btn {
    flex: 1;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    font-size: var(--font-sm);
    text-transform: uppercase;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-xs);
    text-align: center;
    border: 1px solid transparent;
    min-height: 45px;
}

.action-btn i {
    font-size: var(--font-sm);
}

.action-btn span {
    font-size: var(--font-lg);
    font-weight: 600;
}

/* Action Buttons Responsive */
/* Tablet */
@media (max-width: 768px) {
    .action-buttons-container {
        padding: 0 var(--space-md);
        gap: var(--space-xs);
    }
    
    .action-btn {
        padding: var(--space-sm) var(--space-md);
        font-size: 11px;
        min-height: 40px;
        gap: var(--space-xs);
    }
    
    .action-btn span {
        font-size: var(--font-md);
    }
}

/* Mobile */
@media (max-width: 576px) {
    .action-buttons-section {
        padding: 0;
    }
    
    .action-buttons-container {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: var(--space-sm);
        padding: var(--space-md) var(--space-sm);
    }
    
    .action-btn {
        padding: var(--space-sm) var(--space-xs);
        font-size: var(--font-xs);
        min-height: 40px;
        flex-direction: row;
        gap: 6px;
    }
    
    .action-btn i {
        font-size: var(--font-sm);
    }
    
    .action-btn span {
        font-size: var(--font-sm);
        line-height: 1.2;
    }
}

.action-btn.login {
    background: rgba(0,0,0,0.1);
    box-shadow: 0 1px 3px 0 var(--primary-color), 0 1px 2px -1px var(--primary-color);
}

.action-btn.promo {
    background: rgba(0,0,0,0.1);
    box-shadow: 0 1px 3px 0 var(--primary-color), 0 1px 2px -1px var(--primary-color);
}

.action-btn.rtp {
    background: rgba(0,0,0,0.1);
    box-shadow: 0 1px 3px 0 var(--primary-color), 0 1px 2px -1px var(--primary-color);
}

.action-btn.jackpot {
    background: rgba(0,0,0,0.1);
    box-shadow: 0 1px 3px 0 var(--primary-color), 0 1px 2px -1px var(--primary-color);
}

.action-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    opacity: 0.9;
}

/* Main Navigation - Exact match to reference */
.main-navigation {
    background: #000000;
    padding: 0px 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.nav-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--padding-horizontal);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-left .logo {
    display: block;
}

.logo-img {
    height: 32px;
    width: auto;
}

.nav-center {
    flex: 1;
    display: flex;
    justify-content: center;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 15px;
}

.nav-link {
    color: #ccc;
    text-decoration: none;
    font-size: 12px;
    font-weight: 400;
    padding: 6px 10px;
    border-radius: 4px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 4px;
    text-transform: capitalize;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
    background: rgba(37, 211, 102, 0.1);
}

.nav-link i {
    font-size: 11px;
}

.nav-link .fa-chevron-down {
    font-size: 8px;
    margin-left: 2px;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Dropdown Menu */
.nav-dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-toggle {
    cursor: pointer;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: #2c3e50;
    min-width: 200px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    border-radius: 8px;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    border: 1px solid rgba(255,255,255,0.1);
}

.nav-dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    color: #ccc;
    text-decoration: none;
    font-size: 13px;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-item:hover {
    background: rgba(255, 215, 0, 0.1);
    color: var(--primary-color);
}

.dropdown-item i {
    font-size: 12px;
    width: 14px;
}

/* Tablet & Mobile Navigation Styles */
@media (max-width: 768px) {
    /* Tablet & Mobile Header Layout */
    .top-info-bar {
        padding: 0;
    }
    
    .top-info-content {
        flex-direction: column;
        gap: 0;
        text-align: center;
        padding: 0;
        max-width: 100%;
        margin: 0;
    }
    
    /* Hide time on mobile */
    .current-time {
        display: none;
    }
    
    /* Mobile WhatsApp Full Width */
    .top-info-right {
        width: 100%;
        justify-content: stretch;
        order: -1;
        padding: 0;
        margin: 0;
    }
    
    .whatsapp-btn {
        width: 100% !important;
        margin: 0 !important;
        justify-content: center !important;
        padding: 0 !important;
        font-size: 11px !important;
        font-weight: 700 !important;
        text-transform: uppercase !important;
        border-radius: 0 !important;
        display: flex !important;
        align-items: center !important;
        text-align: center !important;
        height: 23px !important;
        line-height: 23px !important;
        box-sizing: border-box !important;
    }
    
    /* Mobile Top Links */
    .top-info-left {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
        gap: 8px;
        margin-top: 8px;
    }
    
    .top-link {
        font-size: 11px;
    }
    
    .separator {
        margin: 0 4px;
    }
    
    /* Mobile Navigation */
    .nav-container {
        padding: 0px 10px;
        position: relative;
    }
    
    .nav-center {
        display: none;
        position: fixed;
        top: 95px;
        left: -280px;
        width: 280px;
        height: calc(100vh - 95px);
        background: #000000;
        flex-direction: column;
        padding: 0;
        box-shadow: 2px 0 10px rgba(0,0,0,0.3);
        z-index: 1000;
        transition: left 0.3s ease;
        overflow-y: auto;
    }
    
    .nav-center.show-mobile {
        display: flex;
        left: 0;
    }
    
    .nav-menu {
        flex-direction: column;
        gap: 0;
        width: 100%;
    }
    
    .nav-link {
        width: 100%;
        justify-content: flex-start;
        padding: 15px 20px;
        border-radius: 0;
        background: transparent;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        font-size: 14px;
    }
    
    .nav-link:hover {
        background: rgba(37, 211, 102, 0.1);
    }
    
    /* Mobile Dropdown Items as Regular Menu Items */
    .nav-dropdown {
        display: contents;
    }
    
    .nav-dropdown .dropdown-menu {
        position: static;
        display: block;
        opacity: 1;
        visibility: visible;
        transform: none;
        background: transparent;
        box-shadow: none;
        border: none;
        min-width: auto;
        width: 100%;
    }
    
    .dropdown-item {
        padding: 12px 30px;
        border-bottom: 1px solid rgba(255,255,255,0.05);
        background: rgba(255,255,255,0.02);
        font-size: 13px;
    }
    
    .dropdown-item:hover {
        background: rgba(37, 211, 102, 0.1);
    }
    
    /* Mobile Menu Overlay */
    .mobile-menu-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0,0,0,0.5);
        z-index: 999;
    }
    
    .mobile-menu-overlay.show {
        display: block;
    }
    
    .nav-right {
        gap: 15px;
    }
    
    /* Mobile Toggle Button */
    .mobile-toggle {
        display: block !important;
        background: rgba(255,255,255,0.1);
        border: none;
        color: #ccc;
        padding: 10px;
        border-radius: 6px;
        cursor: pointer;
        transition: all 0.3s ease;
        font-size: 16px;
        min-width: 40px;
        height: 40px;
    }
    
    .mobile-toggle:hover {
        background: rgba(37, 211, 102, 0.2);
        color: var(--primary-color);
    }
    
    /* Mobile Banner - Full Width */
    .banner-section {
        padding: 0;
    }
    
    .banner-container {
        max-width: none;
        padding: 0;
        margin: 0;
    }
    
    .banner-grid {
        display: block;
        position: relative;
    }
    
    .banner-item {
        display: none;
        width: 100%;
        margin-bottom: 0;
    }
    
    .banner-item.active {
        display: block;
    }
    
    .banner-item img {
        width: 100%;
        height: auto;
        border-radius: 0;
        display: block;
    }
    
    /* Mobile action buttons handled by the responsive section above */
}

/* Hide mobile toggle on desktop */
.mobile-toggle {
    display: none;
}

@media (max-width: 768px) {
    .mobile-toggle {
        display: block !important;
    }
    
    /* Ensure nav-center mobile behavior works for all mobile sizes */
    .nav-center {
        display: none !important;
        position: fixed !important;
        top: 95px !important;
        left: -280px !important;
        width: 280px !important;
        height: calc(100vh - 95px) !important;
        background: #000000 !important;
        flex-direction: column !important;
        padding: 0 !important;
        box-shadow: 2px 0 10px rgba(0,0,0,0.3) !important;
        z-index: 1000 !important;
        transition: left 0.3s ease !important;
        overflow-y: auto !important;
    }
    
    .nav-center.show-mobile {
        display: flex !important;
        left: 0 !important;
    }
}

@media (min-width: 769px) {
    .mobile-toggle {
        display: none !important;
    }
}

.nav-left {
    display: flex;
    align-items: center;
}

.site-logo {
    height: 35px;
    width: auto;
    margin-right: 20px;
}

.logo-text {
    font-size: 24px;
    font-weight: bold;
    color: #ffd700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}



.nav-item {
    color: #ffffff;
    text-decoration: none;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 8px;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    position: relative;
}

.nav-item:hover,
.nav-item.active {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.nav-item i {
    font-size: 14px;
}

.nav-dropdown {
    position: relative;
}



.nav-dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}



.dropdown-item:hover {
    background: var(--primary-color);
    color: #1a1a2e;
}



.mobile-menu-toggle {
    display: none;
    background: none;
    border: 1px solid #34495e;
    color: white;
    width: 35px;
    height: 35px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.mobile-menu-toggle:hover {
    background: #34495e;
}

.mobile-menu-toggle.active {
    background: #ffd700;
    color: #1a1a2e;
    border-color: #ffd700;
}

/* Player Win Section */
.player-win-section {
    background: #2c3e50;
    padding: 15px 0;
    border-top: 2px solid #ffd700;
    border-bottom: 2px solid #ffd700;
}

.player-win-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--padding-horizontal);
    display: flex;
    align-items: center;
    gap: 20px;
}

.player-win-label {
    background: #ffd700;
    color: #1a1a2e;
    padding: 8px 20px;
    border-radius: 20px;
    font-weight: bold;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 8px;
}

.player-win-marquee {
    flex: 1;
    overflow: hidden;
    height: 40px;
    position: relative;
}

.marquee-content {
    display: flex;
    animation: marquee 60s linear infinite;
    gap: 50px;
    white-space: nowrap;
}

@keyframes marquee {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

.win-item {
    color: #ffffff;
    font-size: 14px;
}

/* Filter Section */
.filter-container {
    background: #1e2a3a;
    padding: 20px 0;
}

.filter-header {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--padding-horizontal) 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #34495e;
    margin-bottom: 15px;
}

.filter-header h3 {
    color: #ffd700;
    font-size: 18px;
    margin: 0;
}

.clear-filter-btn {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    text-transform: uppercase;
}

.filter-grid {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--padding-horizontal);
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 10px;
}

.filter-btn {
    background: #34495e;
    color: white;
    border: 1px solid #2c3e50;
    padding: 10px 15px;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
    font-size: 12px;
}

.filter-btn:hover,
.filter-btn.active {
    background: #ffd700;
    color: #1a1a2e;
}

/* Live Draw Container */
.live-draw-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 20px var(--padding-horizontal);
}

.live-draw-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

/* Market Card */
.market-card {
    background: linear-gradient(145deg, #1a2332 0%, #243447 100%);
    border: 1px solid #3d5a7a;
    border-radius: 8px;
    padding: 8px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 
        0 2px 8px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    width: 269px;
    display: flex;
    flex-direction: column;
}

.market-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
    border-color: #ffd700;
}

.next-draw {
    background: linear-gradient(135deg, #000000, #4b5563);
    color: #ffd700;
    padding: 4px 8px;
    border-radius: 4px;
    margin-bottom: 6px;
    text-align: center;
    font-size: 10px;
    font-weight: bold;
    border: 1px solid #1a1a2e;
}



.date-info {
    text-align: center;
    color: #bdc3c7;
    font-size: 10px;
    margin-bottom: 6px;
    line-height: 1.2;
}

.market-logo {
    display: flex;
    justify-content: center;
    margin-bottom: 8px;
    flex-shrink: 0;
}

.logo-icon {
    width: 163px;
    height: 105px;
    border-radius: 6px;
    object-fit: cover;
}

.market-name {
    color: #ffd700;
    font-weight: bold;
    font-size: 16px;
    text-align: center;
    margin-bottom: 6px;
    line-height: 1.2;
    width: 253px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.market-time {
    color: #bdc3c7;
    font-size: 12px;
}

.result-display {
    background: #000000;
    border-radius: 6px;
    padding: 8px;
    margin-bottom: 8px;
    text-align: center;
    border: 1px solid #3d5a7a;
    width: 253px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.result-numbers {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    height: 100%;
    align-items: center;
}

.result-number {
    background: #ffd700;
    color: #1a1a2e;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.3);
}

.result-date {
    color: #bdc3c7;
    font-size: 10px;
    margin-bottom: 4px;
    line-height: 1.1;
}

.market-status {
    text-align: center;
    margin-bottom: 15px;
    padding: 8px;
    border-radius: 5px;
    font-weight: bold;
    font-size: 12px;
}

.market-schedule {
    color: #bdc3c7;
    font-size: 10px;
    text-align: center;
    margin-bottom: 8px;
    line-height: 1.1;
}

.logo-placeholder {
    width: 163px;
    height: 105px;
    background: linear-gradient(135deg, #34495e, #2c3e50);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffd700;
    font-weight: bold;
    font-size: 16px;
    border: 1px solid #3d5a7a;
}

.market-actions {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 12px; /* Desktop spacing */
}

.market-btn-group {
    display: flex;
    gap: 4px;
}

.market-btn {
    flex: 1;
    padding: 6px 8px;
    border-radius: 4px;
    text-decoration: none;
    text-align: center;
    font-size: 10px;
    font-weight: bold;
    transition: all 0.3s;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
}

.market-btn i {
    font-size: 8px;
    margin-right: 4px;
}

.market-btn.live {
    background: linear-gradient(135deg, #000000, #616b7a);
    color: #00ff13;
    border: 1px solid #1a1a2e;
}

.market-btn.prediksi {
    background: linear-gradient(135deg, #616b7a, #000000);
    color: #ff9800;
    border: 1px solid #1a1a2e;
}

.market-btn.history {
    background: linear-gradient(135deg, #000000, #616b7a);
    color: #008eff;
    border: 1px solid #1a1a2e;
}

.market-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(0,0,0,0.3);
}

.market-btn.live:hover {
    background: #229954;
    color: #ffffff;
}

.market-btn.prediksi:hover {
    background: #e2a03f;
    color: #ffffff;
}

.market-btn.history:hover {
    background: #2196f3;
    color: #ffffff;
}

/* Responsive Design */
@media (max-width: 768px) {
    .top-info-content {
        flex-direction: column;
        gap: 0px;
        text-align: center;
    }
    
    .top-info-left {
        flex-wrap: wrap;
        justify-content: center;
        gap: 5px;
    }
    
    .top-info-right {
        justify-content: center;
    }
    
    .nav-center {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: #000000;
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    }
    
    .nav-center.show-mobile {
        display: flex;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }
    
    .welcome-greeting {
        font-size: 16px;
    }
    
    .welcome-desc {
        font-size: 11px;
    }
    
    .action-buttons-container {
        flex-wrap: wrap;
        gap: 10px;
        justify-content: center;
    }
    
    .player-win-container {
        flex-direction: column;
        gap: 10px;
    }
    
    .filter-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 8px;
    }
    
    .live-draw-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .market-actions {
        flex-direction: column;
        gap: 6px;
        margin-top: 8px; /* Mobile: jarak lebih kecil */
    }
    
    .market-btn-group {
        display: flex;
        gap: 4px;
    }
    
    .market-btn {
        font-size: 9px;
        height: 26px;
        padding: 4px 6px;
    }
    
    .market-btn i {
        font-size: 7px;
        margin-right: 3px;
    }
    
    .banner-slide {
        width: 100%;
        min-width: 300px;
        height: 172px;
    }
}

@media (max-width: 480px) {
    .action-buttons-container {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .filter-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .banner-slide {
        width: 100%;
        min-width: 280px;
        height: 160px;
    }
}

/* Additional styles for better compatibility */
.action-buttons-grid {
    display: none;
}

@media (max-width: 768px) {
    .action-buttons {
        display: none;
    }
    
    .action-buttons-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        padding: 15px;
        background: #2c3e50;
    }
}



/* Hide elements that might conflict */
.menu-grid {
    display: none;
}

/* Player Win Inline with Tabs */
.player-win-inline {
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.1), rgba(0,0,0,0.1));
    padding: 8px 16px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: #FFFFFF;
    font-weight: 600;
    flex: 1;
    min-width: 0;
    height: 44px;
    box-sizing: border-box;
    border: 1px solid var(--primary-color)
}

.player-win-inline .winner-badge {
    background: var(--primary-color);
    color: #1a1a2e;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.player-win-inline .winner-badge i {
    font-size: 10px;
}

.player-win-inline .winner-message {
    font-size: 14px;
    font-weight: 600;
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    transition: opacity 0.3s ease;
}

/* Ensure proper spacing */
body, html {
    margin: 0;
    padding: 0;
}

/* Fix any layout issues */
.live-draw-container {
    background: transparent;
}

/* Status indicators */
.status-open {
    background: #27ae60 !important;
}

.status-closed {
    background: #e74c3c !important;
}

.status-waiting {
    background: #f39c12 !important;
}

/* Footer Styles */
.main-footer {
    background: #16213e;
    color: #ffffff;
    padding: 40px 0 20px;
    margin-top: 50px;
    border-top: 3px solid #ffd700;
}

.footer-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--padding-horizontal);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.footer-section h4 {
    color: #ffd700;
    margin-bottom: 15px;
    font-size: 18px;
    font-weight: bold;
}

.footer-section p {
    color: #bdc3c7;
    line-height: 1.6;
    margin-bottom: 15px;
}

.footer-social {
    display: flex;
    gap: 15px;
}

.footer-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: #34495e;
    color: #ffffff;
    border-radius: 50%;
    text-decoration: none;
    transition: all 0.3s;
}

.footer-social a:hover {
    background: #ffd700;
    color: #1a1a2e;
    transform: translateY(-2px);
}

.footer-menu {
    list-style: none;
    padding: 0;
}

.footer-menu li {
    margin-bottom: 8px;
}

.footer-menu a {
    color: #bdc3c7;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-menu a:hover {
    color: #ffd700;
}

.footer-contact {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #bdc3c7;
}

.contact-item i {
    color: #ffd700;
    width: 20px;
}

.footer-bottom {
    border-top: 1px solid #34495e;
    padding-top: 20px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-copyright {
    flex: 1;
}

.footer-copyright p {
    margin: 0;
    color: #bdc3c7;
}

.footer-disclaimer {
    margin-top: 10px;
}

.footer-disclaimer small {
    color: #95a5a6;
    font-size: 11px;
}

.footer-links {
    display: flex;
    gap: 15px;
    align-items: center;
    flex-wrap: wrap;
}

.footer-links a {
    color: #bdc3c7;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: #ffd700;
}

.footer-links span {
    color: #34495e;
}

/* Mobile Footer Responsive */
@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .footer-bottom {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .footer-links {
        justify-content: center;
    }
    
    .footer-social {
        justify-content: center;
    }
}

/* Visibility Classes for Desktop/Mobile */
.desktop-only {
    display: block;
}

.mobile-only {
    display: none;
}

@media (max-width: 768px) {
    .desktop-only {
        display: none !important;
    }
    
    .mobile-only {
        display: block;
    }
    
    /* Mobile nav items styling */
    .mobile-only.nav-link {
        display: block;
        width: 100%;
        justify-content: flex-start;
        padding: 15px 20px;
        border-radius: 0;
        background: transparent;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        font-size: 14px;
    }
}

/* Main Content Styling - Matching Reference Site */
.main-content {
    background: #000000;
    min-height: 100vh;
    padding: 0;
}

/* Filter Section - Matching Action Buttons Section */
.filter-section {
    background: #000000;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
    margin-bottom: 10px;
}

.filter-container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0; /* HAPUS PADDING CONTAINER DESKTOP */
}

.filter-content {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0; /* HAPUS PADDING CONTAINER DESKTOP */
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 15px;
    flex-direction: column-reverse;
    box-sizing: border-box;
}

/* Desktop - tombol dulu, player win kemudian */
@media (min-width: 769px) {
    .filter-content {
        flex-direction: row-reverse;
    }
}

.filter-tabs {
    display: flex;
    gap: 6px; /* KECIL aja gap nya */
    flex-shrink: 0;
    justify-content: flex-start; /* MULAI DARI KIRI - biar Player Win ada ruang */
    align-items: center;
    margin: 0;
    padding: 0;
    width: auto; /* AUTO WIDTH - biar pendek */
}

/* Filter Tablet Responsive - 577px to 768px */
@media (max-width: 768px) and (min-width: 577px) {
    .filter-section {
        position: relative;
    }
    
    .filter-content {
        flex-direction: column-reverse;
        gap: 15px;
    }
    
    .filter-tabs {
        display: flex !important;
        gap: 10px !important;
        flex-wrap: nowrap;
        justify-content: flex-start;
    }
    
    .filter-tab {
        padding: 10px 16px;
        font-size: 11px;
        min-height: 44px;
        flex-shrink: 0;
    }
}

/* Filter Mobile Responsive - Only for mobile below 576px */
@media (max-width: 576px) {
    .filter-section {
        position: relative;
    }
    
    .filter-content {
        flex-direction: column-reverse;
        gap: 15px;
    }
}

/* Mobile */
@media (max-width: 576px) {
    .filter-tabs {
        display: grid !important;
        grid-template-columns: 1fr 1fr;
        gap: var(--space-sm) !important; /* Force gap on mobile grid */
    }
    
    .filter-tab {
        padding: 10px 12px;
        font-size: 10px;
        min-height: 40px;
    }
}

/* FILTER TABS - SERAGAM DENGAN ACTION BUTTONS */
.filter-tab {
    background: rgba(0,0,0,0.1);
    color: #ffffff;
    padding: 12px 20px; /* SAMA DENGAN ACTION BUTTONS */
    font-size: 12px; /* PERBESAR FONT */
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    border-radius: 6px; /* SAMA DENGAN ACTION BUTTONS */
    min-height: 44px; /* SAMA DENGAN ACTION BUTTONS */
    display: flex;
    align-items: center;
    justify-content: center;
    flex: none;
    min-width: auto;
    box-shadow: 0 1px 3px 0 var(--primary-color), 0 1px 2px -1px var(--primary-color);
}

/* Keep original colors - ONLY fix gap/spacing */

.filter-tab.active {
    background: rgba(0,0,0,0.1) !important; /* Keep original active color */
    color: white !important;
}

.filter-tab:hover {
    background: var(--primary-color) !important; /* Keep original hover color */
    border-color: var(--primary-color) !important;
    color: white !important;
}

.filter-tab.active:hover {
    background: var(--primary-color)  !important; /* Keep original active hover */
    border-color: var(--primary-color)  !important;
}



.filter-dropdown {
    position: relative;
}

.filter-dropdown select {
    width: 100%;
    padding: 10px 15px;
    background: #000000;
    color: white;
    border: 1px solid var(--primary-color);
    border-radius: 6px;
    font-size: 12px;
    appearance: none;
    cursor: pointer;
}

.filter-dropdown i {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #ccc;
    pointer-events: none;
}

/* Custom dropdown enhancements - menggunakan style filter-dropdown yang sudah ada */
.dropdown-wrapper {
    position: relative;
    width: 100%;
}

.custom-select-button {
    width: 100%;
    padding: 10px 45px 10px 15px;
    background: #2c2c54;
    color: white;
    border: 1px solid #3d3d6b;
    border-radius: 6px;
    font-size: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
}

.custom-select-button:hover {
    background: #3d3d6b;
}

.clear-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    margin-left: 8px;
}

.clear-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

.custom-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #2c2c54;
    border: 1px solid #3d3d6b;
    border-radius: 6px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    display: none;
    margin-top: 2px;
}

.custom-dropdown-menu.show {
    display: block;
}

.search-container {
    position: relative;
    padding: 8px;
    border-bottom: 1px solid #3d3d6b;
    background: #2c2c54;
}

.search-container input {
    width: 100%;
    padding: 8px 30px 8px 10px;
    border: 1px solid #3d3d6b;
    border-radius: 4px;
    font-size: 12px;
    outline: none;
    background: #40407a;
    color: white;
}

.search-container input:focus {
    border-color: #5c5ce0;
}

.search-container input::placeholder {
    color: #ccc;
}

.search-container i {
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    font-size: 11px;
}

.clear-filter-container {
    background: #2c2c54;
    border-bottom: 1px solid #3d3d6b;
    padding: 0;
}

.clear-filter-button {
    background: #2c2c54;
    color: white;
    padding: 10px 15px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    text-align: left;
    transition: background-color 0.2s ease;
    border: none;
    width: 100%;
}

.clear-filter-button:hover {
    background: #40407a;
}

.options-list {
    max-height: 150px;
    overflow-y: auto;
    background: #2c2c54;
}

.option-item {
    padding: 10px 15px;
    cursor: pointer;
    font-size: 12px;
    color: white;
    border-bottom: 1px solid #3d3d6b;
}

.option-item:hover {
    background-color: #40407a;
}

.option-item:last-child {
    border-bottom: none;
}

.option-item.selected {
    background-color: #5c5ce0;
    color: white;
    font-weight: 500;
}

.option-item.hidden {
    display: none;
}

/* Markets Grid - 4 cards per row desktop (following card-only.css reference) */
.markets-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin: 8px auto 0 auto;
    max-width: 1200px;
    padding: 0;
    width: 100%;
    box-sizing: border-box;
}

/* Market Card - Tight Layout */
.market-card {
    background: linear-gradient(135deg, #000000, #4b5563);
    border: 1px solid #1a1a2e;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 2px 3px rgba(0,0,0,0.1);
    min-height: 220px;
    width: 100%;
    flex: 1;
    box-sizing: border-box;
}

.market-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    border-color: var(--primary-color);
}

/* Card Header - Horizontal Layout */
.card-header {
    background: linear-gradient(90deg, #ff9500, #ff7300);
    padding: 6px 10px;
    color: white;
    text-align: center;
}

.next-draw-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2px;
}

.next-draw-label {
    font-size: 8px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.countdown-timer {
    color: var(--primary-color);
    font-size: 10px;
    font-weight: bold;
    font-family: inherit;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}

.date-row {
    font-size: 10px;
    opacity: 0.9;
    line-height: 1.1;
    font-weight: 600;
}

/* Card Body - No Wasted Space */
.card-body {
    padding: 2px 10px 0px 10px;
}

.market-logo-section {
    text-align: center;
    margin-bottom: 0px;
}

.market-logo-img {
    width: 100px;
    height: 60px;
    border-radius: 6px;
    object-fit: cover;
    border: 1px solid rgba(255,255,255,0.1);
    display: block;
    margin: 0 auto 1px auto;
}

.market-logo-placeholder {
    width: 100px;
    height: 60px;
    background: linear-gradient(45deg, #ff9500, #ff7300);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 800;
    font-size: 14px;
    margin: 0 auto 1px auto;
}

/* Mobile Logo Sizing */
@media (max-width: 639px) {
    .market-logo-img,
    .market-logo-placeholder {
        width: 80px;
        height: 50px;
    }
    
    .market-logo-placeholder {
        font-size: 12px;
    }
}

.market-title {
    color: white;
    font-size: 13px;
    font-weight: 700;
    margin: 0;
    text-transform: uppercase;
    line-height: 1.2;
    text-align: center;
}



/* Result Display - No Wasted Space */
.result-display {
    text-align: center;
    margin: 0;
    padding: 0;
}

.result-numbers-grid {
    display: flex;
    justify-content: center;
    gap: 5px;
    margin: 8px 0;
}

.result-ball {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 800;
    font-size: 14px;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
    border: 1px solid rgba(255,255,255,0.2);
    box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}

/* Mobile Result Balls */
@media (max-width: 639px) {
    .result-ball {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }
    
    .result-numbers-grid {
        gap: 3px;
        margin: 6px 0;
    }
}

.result-ball.green {
    background: linear-gradient(145deg, var(--primary-color), #20b358);
}

.result-ball.blue {
    background: linear-gradient(145deg, #007bff, #0056b3);
}

.result-ball.red {
    background: linear-gradient(145deg, #dc3545, #c82333);
}

.result-ball.orange {
    background: linear-gradient(145deg, #fd7e14, #e66100);
}

/* Card Footer - Large Buttons */
.card-footer {
    background: rgba(0,0,0,0.1);
    padding: 10px 8px;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.action-buttons-row {
    display: flex;
    justify-content: space-between;
    gap: 5px;
}

.action-btn-small {
    flex: 1;
    background: rgba(255,255,255,0.1);
    color: white;
    border: none;
    padding: 12px 8px;
    border-radius: 5px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    min-height: 36px;
}

.action-btn-small:hover {
    background: rgba(255,255,255,0.2);
    transform: translateY(-1px);
}

.live-btn:hover {
    background: rgba(37,211,102,0.2);
}

.prediksi-btn:hover {
    background: rgba(255,149,0,0.2);
}

.history-btn:hover {
    background: rgba(0,123,255,0.2);
}

/* DESKTOP - 4 cards per row */
@media (min-width: 1025px) {
    .markets-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 12px;
        max-width: 1200px;
        margin: 0 auto;
    }
}

/* LARGE TABLET - 3 cards per row */
@media (min-width: 769px) and (max-width: 1024px) {
    .markets-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 10px;
        max-width: 900px;
        margin: 0 auto;
        padding: 10px;
    }
}

/* TABLET - 2 cards per row */
@media (min-width: 481px) and (max-width: 768px) {
    .container {
        max-width: 100%;
        padding: 0 10px;
    }
    
    .markets-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        margin: 0 auto;
        padding: 8px;
        max-width: 100%;
    }
    
    .logo-icon, .logo-placeholder {
        width: 130px;
        height: 85px;
    }
}
    
    .market-name {
        width: 100%;
        height: 22px;
        font-size: 15px;
    }
    
    .result-display {
        width: 100%;
        height: 45px;
    }
    
    .result-number {
        width: 26px;
        height: 26px;
        font-size: 12px;
    }
    
    .market-btn {
        font-size: 10px;
        height: 28px;
        padding: 4px 6px;
    }

/* FORCE NO MARGIN FOR ALL ABOVE 480PX */
@media (min-width: 481px) {
    .market-card {
        margin: 0 !important;
    }
}

/* MOBILE - 2 cards per row */
@media (max-width: 480px) {
    .container {
        max-width: 100%;
        padding: 0 8px;
    }
    
    .markets-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
        margin: 0;
        padding: 0;
    }
    
    .market-card {
        width: 100%;
        margin: 0;
        box-sizing: border-box;
    }
    
    .logo-icon, .logo-placeholder {
        width: 110px;
        height: 72px;
    }
}


/* Very small mobile screens - Stack History button */
@media (max-width: 530px) {
    .container {
        padding-left: 4px !important;
        padding-right: 4px !important;
        max-width: 100%;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }
    
    .main-container {
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }
    
    .markets-grid {
        gap: 2px;
        max-width: 100%;
        overflow-x: hidden;
        padding: 0;
        margin: 0 auto;
    }
    
    .market-card {
        padding: 6px;
        width: 100%;
        min-height: 200px;
        flex: 1;
        box-sizing: border-box;
    }
    
    .market-actions {
        display: flex;
        flex-direction: column;
        gap: 4px;
        margin-top: 6px; /* Mobile kecil: jarak minimal */
        width: 100%;
    }
    
    .market-btn-group {
        display: flex;
        gap: 3px;
        width: 100%;
    }
    
    .market-btn {
        flex: 1;
        font-size: 8px;
        height: 24px;
        padding: 3px 4px;
        box-sizing: border-box;
    }
    
    .market-btn i {
        font-size: 6px;
        margin-right: 2px;
    }
    
    .market-btn.history {
        width: 100%;
    }
    
    .filter-content {
        flex-direction: column;
        gap: 10px;
        align-items: stretch;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }
    
    /* Filter tabs handled by @media (max-width: 576px) above */
}
    
    .player-win-inline {
        order: -1;
        margin-bottom: 5px;
    }
    
    .player-win-inline .winner-message {
        font-size: 10px;
    }
    
    .card-body {
        padding: 15px 12px;
    }
    
    .result-ball {
        width: 35px;
        height: 35px;
        font-size: 14px;
    }

/* No Data Message */
.no-data-message {
    text-align: center;
    padding: 60px 20px;
    color: #ccc;
}

.no-data-content i {
    font-size: 48px;
    color: #666;
    margin-bottom: 20px;
}

.no-data-content h3 {
    color: white;
    margin-bottom: 10px;
}

.retry-btn {
    background: #ff9500;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    margin-top: 20px;
    transition: all 0.3s ease;
}

.retry-btn:hover {
    background: #e68400;
}

/* REMOVED - CONFLICTING WITH MAIN MEDIA QUERIES */

/* Large mobile screens (641px to 768px) */
@media (max-width: 768px) and (min-width: 641px) {
    body {
        font-size: 13px;
        margin: 0 !important;
        padding: 0 !important;
    }
    
    .container, .main-container {
        width: 100vw !important;
        max-width: 100vw !important;
        margin: 0 !important;
        padding: 0 5px !important;
        position: relative !important;
        left: 0 !important;
        box-sizing: border-box !important;
    }
    
    .markets-grid {
        width: 100%;
        max-width: 100vw;
        padding: 0;
        margin: 0;
        gap: 8px;
        grid-template-columns: repeat(2, 1fr);
        box-sizing: border-box;
    }
}

/* Medium mobile screens (531px to 640px) */
@media (max-width: 640px) and (min-width: 531px) {
    body {
        font-size: 12px;
        margin: 0 !important;
        padding: 0 !important;
    }
    
    .container, .main-container {
        width: 100vw !important;
        max-width: 100vw !important;
        margin: 0 !important;
        padding: 0 4px !important;
        position: relative !important;
        left: 0 !important;
        box-sizing: border-box !important;
    }
    
    .markets-grid {
        width: 100%;
        max-width: 100vw;
        padding: 0;
        margin: 0;
        gap: 6px;
        grid-template-columns: repeat(2, 1fr);
        box-sizing: border-box;
    }
}

/* Small mobile screens (481px to 530px) */
@media (max-width: 530px) and (min-width: 481px) {
    body {
        font-size: 11px;
        margin: 0 !important;
        padding: 0 !important;
    }
    
    .container, .main-container {
        width: 100vw !important;
        max-width: 100vw !important;
        margin: 0 !important;
        padding: 0 3px !important;
        position: relative !important;
        left: 0 !important;
        box-sizing: border-box !important;
    }
    
    .markets-grid {
        width: 100%;
        max-width: 100vw;
        padding: 0;
        margin: 0;
        gap: 4px;
        grid-template-columns: repeat(2, 1fr);
        box-sizing: border-box;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 11px;
        line-height: 1.4;
        padding: 0;
        margin: 0;
    }
    
    .container, .main-container {
        padding-left: 8px !important;
        padding-right: 8px !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        width: 100%;
        max-width: 100%;
    }
    
    /* Mobile: 2 cards per row (following card-only.css reference) */
    .markets-grid {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 4px !important;
        padding: 0 !important;
    }
}

/* =================================================================
   RESPONSIVE UTILITY CLASSES & IMPROVEMENTS
   ================================================================= */

/* Touch-friendly improvements */
@media (max-width: 768px) {
    /* Remove all highlight effects */
    * {
        -webkit-tap-highlight-color: transparent !important;
        -webkit-touch-callout: none !important;
        -webkit-user-select: none !important;
        -khtml-user-select: none !important;
        -moz-user-select: none !important;
        -ms-user-select: none !important;
        user-select: none !important;
    }
    
    /* Increase touch target sizes */
    a, button, .clickable {
        min-height: 23px;
        min-width: 23px;
    }
    
    /* Improve text legibility on mobile */
    body {
        -webkit-text-size-adjust: 100%;
        -ms-text-size-adjust: 100%;
        text-size-adjust: 100%;
    }
    
    /* Better tap highlights */
    a, button {
        -webkit-tap-highlight-color: rgba(255, 215, 0, 0.2);
    }
    
    /* Smoother scrolling on mobile */
    * {
        -webkit-overflow-scrolling: touch;
        scroll-behavior: smooth;
    }
}

/* Container helpers */
.container-fluid {
    width: 100%;
    padding: 0 var(--space-sm);
}

.container-sm {
    max-width: 576px;
    margin: 0 auto;
    padding: 0 var(--space-md);
}

.container-md {
    max-width: 768px;
    margin: 0 auto;
    padding: 0 var(--space-md);
}

/* Spacing utilities */
.p-xs { padding: var(--space-xs); }
.p-sm { padding: var(--space-sm); }
.p-md { padding: var(--space-md); }
.p-lg { padding: var(--space-lg); }

.m-xs { margin: var(--space-xs); }
.m-sm { margin: var(--space-sm); }
.m-md { margin: var(--space-md); }
.m-lg { margin: var(--space-lg); }

/* Text utilities */
.text-xs { font-size: var(--font-xs); }
.text-sm { font-size: var(--font-sm); }
.text-base { font-size: var(--font-base); }
.text-md { font-size: var(--font-md); }
.text-lg { font-size: var(--font-lg); }
.text-xl { font-size: var(--font-xl); }

/* Responsive visibility helpers */
.d-mobile-none { display: none; }
.d-tablet-none { display: initial; }
.d-desktop-none { display: initial; }

@media (max-width: 576px) {
    .d-mobile-none { display: none !important; }
    .d-mobile-block { display: block !important; }
    .d-mobile-flex { display: flex !important; }
}

@media (max-width: 768px) and (min-width: 577px) {
    .d-tablet-none { display: none !important; }
    .d-tablet-block { display: block !important; }
    .d-tablet-flex { display: flex !important; }
}

@media (min-width: 769px) {
    .d-desktop-none { display: none !important; }
    .d-desktop-block { display: block !important; }
    .d-desktop-flex { display: flex !important; }
}

/* Focus improvements for accessibility */
@media (max-width: 768px) {
    input, textarea, select {
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    /* Remove highlight effects on mobile */
    button:focus,
    a:focus,
    input:focus,
    textarea:focus,
    button:active,
    a:active,
    .whatsapp-btn:focus,
    .whatsapp-btn:active,
    .top-link:focus,
    .top-link:active,
    .top-link-small:focus,
    .top-link-small:active {
        outline: none !important;
        -webkit-tap-highlight-color: transparent !important;
        -webkit-user-select: none;
        -moz-user-select: none;
        -ms-user-select: none;
        user-select: none;
    }
}

/* Enhanced Filter Dropdown - Specific to filter section only */
.filter-dropdown {
    position: relative;
    margin: 20px 0;
    z-index: 999;
}

.filter-dropdown .dropdown-container {
    position: relative;
    width: 100%;
    z-index: 999;
}

.filter-dropdown .dropdown-trigger {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    padding: 15px 20px;
    cursor: pointer;
    display: flex !important;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s ease;
    color: #fff;
    min-height: 55px;
    min-width: 400px;
    user-select: none;
    font-size: 16px;
}

.filter-dropdown .dropdown-trigger:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: #4a90e2;
    transform: translateY(-1px);
}

.filter-dropdown .dropdown-trigger.active {
    border-color: #4a90e2;
    background: rgba(74, 144, 226, 0.1);
}

.filter-dropdown .dropdown-trigger i {
    transition: transform 0.3s ease;
    color: #4a90e2;
    font-size: 14px;
}

.filter-dropdown .dropdown-trigger.active i {
    transform: rotate(180deg);
}

.filter-dropdown .dropdown-menu {
    position: absolute !important;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.95);
    border: 2px solid rgba(74, 144, 226, 0.5);
    border-radius: 10px;
    border-top: none;
    border-top-left-radius: 0;
    border-top-right-radius: 0;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
    z-index: 1000 !important;
    backdrop-filter: blur(10px);
    max-height: 350px;
    overflow: hidden;
    min-width: 400px;
    visibility: visible;
    opacity: 1;
}

.filter-dropdown .dropdown-header {
    padding: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    position: relative;
}

.filter-dropdown .dropdown-search {
    width: 100%;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 8px 45px 8px 12px;
    color: #fff;
    font-size: 14px;
    outline: none;
    transition: all 0.3s ease;
    margin-right: 10px;
}

.filter-dropdown .dropdown-search::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.filter-dropdown .dropdown-search:focus {
    border-color: #4a90e2;
    background: rgba(255, 255, 255, 0.15);
}

.filter-dropdown .clear-filter-btn {
    position: absolute;
    right: 25px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(220, 53, 69, 0.8);
    border: none;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    cursor: pointer;
    color: #fff;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

.filter-dropdown .clear-filter-btn:hover {
    background: rgba(220, 53, 69, 1);
    transform: translateY(-50%) scale(1.1);
}

.filter-dropdown .dropdown-options {
    max-height: 200px;
    overflow-y: auto;
    padding: 5px 0;
}

.filter-dropdown .dropdown-option {
    padding: 12px 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.filter-dropdown .dropdown-option:hover {
    background: rgba(74, 144, 226, 0.2);
}

.filter-dropdown .dropdown-option.selected {
    background: rgba(74, 144, 226, 0.3);
    color: #4a90e2;
    font-weight: bold;
}

.filter-dropdown .dropdown-option:last-child {
    border-bottom: none;
}

/* Custom Scrollbar for Filter Dropdown Options only */
.filter-dropdown .dropdown-options::-webkit-scrollbar {
    width: 6px;
}

.filter-dropdown .dropdown-options::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.filter-dropdown .dropdown-options::-webkit-scrollbar-thumb {
    background: rgba(74, 144, 226, 0.6);
    border-radius: 3px;
}

.filter-dropdown .dropdown-options::-webkit-scrollbar-thumb:hover {
    background: rgba(74, 144, 226, 0.8);
}

/* Disable hover effects on touch devices to prevent conflicts */
@media (hover: none) and (pointer: coarse) {
    .filter-dropdown .dropdown-trigger:hover {
        background: #1a1a2e !important;
        color: #fff !important;
        transform: none !important;
        box-shadow: none !important;
    }
    
    .filter-dropdown .dropdown-option:hover {
        background: rgba(255, 215, 0, 0.1) !important;
        color: #ffd700 !important;
        transform: none !important;
    }
}

/* Mobile Responsive for Filter Dropdown */
@media (max-width: 768px) {
    /* Prevent filter dropdown from inheriting navigation hover styles */
    .filter-dropdown {
        isolation: isolate;
        contain: layout;
    }
    
    .filter-dropdown .dropdown-container {
        min-width: 100%;
        width: 100%;
    }
    
    .filter-dropdown .dropdown-trigger {
        min-width: 100% !important;
        width: 100% !important;
        padding: 12px 15px !important;
        font-size: 14px !important;
        min-height: 48px !important;
        box-sizing: border-box !important;
        background: #1a1a2e !important;
        border: 1px solid #444 !important;
        color: #fff !important;
        position: relative !important;
        z-index: 1 !important;
    }
    
    /* Override any navigation hover that might affect filter dropdown */
    .filter-dropdown .dropdown-trigger:hover,
    .filter-dropdown .dropdown-trigger:focus {
        background: #1a1a2e !important;
        color: #fff !important;
        border-color: #ffd700 !important;
        transform: none !important;
        box-shadow: 0 0 0 2px rgba(255, 215, 0, 0.2) !important;
    }
    
    .filter-dropdown .dropdown-menu {
        min-width: 100% !important;
        width: 100% !important;
        left: 0 !important;
        right: 0 !important;
        box-sizing: border-box !important;
        background: #1a1a2e !important;
        border: 1px solid #444 !important;
        z-index: 9999 !important;
        position: absolute !important;
    }
    
    .filter-dropdown .dropdown-header {
        padding: 10px !important;
        background: #16213e !important;
        color: #fff !important;
        border-bottom: 1px solid #444 !important;
    }
    
    .filter-dropdown .dropdown-search {
        padding: 10px 40px 10px 12px !important;
        font-size: 16px !important; /* Prevent zoom on iOS */
        background: #1a1a2e !important;
        color: #fff !important;
        border: 1px solid #444 !important;
        outline: none !important;
    }
    
    .filter-dropdown .clear-filter-btn {
        right: 20px !important;
        width: 28px !important;
        height: 28px !important;
        font-size: 14px !important;
        background: #444 !important;
        color: #fff !important;
        border: none !important;
    }
    
    .filter-dropdown .dropdown-option {
        padding: 15px 12px !important;
        font-size: 14px !important;
        min-height: 44px !important;
        display: flex !important;
        align-items: center !important;
        background: #1a1a2e !important;
        color: #fff !important;
        border-bottom: 1px solid #444 !important;
        transition: background 0.2s ease !important;
    }
    
    /* Ensure filter dropdown options have their own hover behavior */
    .filter-dropdown .dropdown-option:hover,
    .filter-dropdown .dropdown-option:active {
        background: rgba(255, 215, 0, 0.1) !important;
        color: #ffd700 !important;
        transform: none !important;
    }
}

@media (max-width: 480px) {
    .filter-dropdown .dropdown-trigger {
        padding: 10px 12px !important;
        font-size: 13px !important;
        min-height: 44px !important;
    }
    
    .filter-dropdown .dropdown-search {
        padding: 8px 35px 8px 10px !important;
        font-size: 16px !important;
    }
    
    .filter-dropdown .clear-filter-btn {
        right: 15px !important;
        width: 24px !important;
        height: 24px !important;
        font-size: 12px !important;
    }
    
    .filter-dropdown .dropdown-option {
        padding: 12px 10px !important;
        font-size: 13px !important;
        min-height: 40px !important;
    }
}

/* Tambahan: Memastikan filter dropdown tidak terpengaruh oleh CSS tombol live/market */
.filter-dropdown .dropdown-trigger:not(.market-btn),
.filter-dropdown .dropdown-option:not(.market-btn) {
    background: #1a1a2e !important;
    color: #fff !important;
}

.filter-dropdown .dropdown-trigger:not(.market-btn):hover,
.filter-dropdown .dropdown-option:not(.market-btn):hover {
    background: rgba(255, 215, 0, 0.1) !important;
    color: #ffd700 !important;
    transform: none !important;
}

/* Pastikan market button hover tidak mempengaruhi filter dropdown */
.market-btn:hover:not(.filter-dropdown *) {
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(0,0,0,0.3);
}

.market-btn.live:hover:not(.filter-dropdown *) {
    background: #229954;
    color: #ffffff;
}

