@charset "UTF-8";

/* Base styles and variables */
:root {
    --primary-color: #017439;
    --secondary-color: #FFFFFF;
    --register-color: #C30808;
    --login-color: #C30808;
    --bg-color: #FFFFFF; /* General page background, not header/marquee */
    --login-register-font-color: #FFFF00;

    /* Neon Colors based on primary/auxiliary and vibrant complements */
    --neon-green: #00FF00; /* Vibrant green */
    --neon-cyan: #00FFFF; /* Vibrant cyan */
    --neon-magenta: #FF00FF; /* Vibrant magenta */
    --neon-yellow: #FFFF00; /* Vibrant yellow */
    --neon-red: #FF0000; /* Vibrant red */
    --neon-orange: #FFA500; /* Vibrant orange */

    /* Dynamic Neon Flow for general elements (e.g., buttons, marquee text) */
    --neon-flow-color-1: var(--neon-green);
    --neon-flow-color-2: var(--neon-cyan);
    --neon-flow-color-3: var(--neon-magenta);

    /* Header Offset Calculation */
    --marquee-height: 45px; /* Estimated marquee height */
    --header-top-desktop-height: 60px; /* Estimated header top bar height */
    --main-nav-desktop-height: 50px; /* Estimated main nav height */
    --mobile-header-top-height: 50px; /* Estimated mobile header top bar height */
    --mobile-nav-buttons-height: 55px; /* Estimated mobile buttons section height */

    --header-offset: calc(var(--marquee-height) + var(--header-top-desktop-height) + var(--main-nav-desktop-height)); /* Desktop */
}

@media (max-width: 768px) {
    :root {
        --header-offset: calc(var(--marquee-height) + var(--mobile-header-top-height) + var(--mobile-nav-buttons-height)); /* Mobile */
    }
}

/* Base Styles */
html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    -moz-text-size-adjust: 100%;
    text-size-adjust: 100%;
    box-sizing: border-box;
    font-family: 'Arial', sans-serif; /* Fallback font */
    line-height: 1.6;
    color: #fff; /* Default text color for dark backgrounds */
    background-color: #0a0a0a; /* Default dark background */
    -webkit-tap-highlight-color: transparent;
    lang: vi-VN; /* HTML lang attribute is set on the html tag */
}

*, *::before, *::after {
    box-sizing: inherit;
    margin: 0;
    padding: 0;
}

body {
    padding-top: var(--header-offset); /* Ensure content is not hidden by fixed header */
    line-height: 1.6;
    overflow-x: hidden; /* Prevent horizontal scroll on body */
    background-color: #0a0a0a; /* Ensure dark background */
}

/* Prevent scroll when mobile menu is active */
body.no-scroll {
    overflow: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

/* WCAG AA contrast for general text on dark background */
p, li, span {
    color: rgba(255, 255, 255, 0.9); /* High contrast white on dark */
}

h1, h2, h3, h4, h5, h6 {
    color: var(--secondary-color); /* White for headings */
    margin-bottom: 0.5em;
    line-height: 1.2;
}

/* Animations for dynamic neon effects */
@keyframes theme-colors {
    0%, 100% {
        border-color: var(--neon-flow-color-1);
        box-shadow: 
            0 0 10px var(--neon-flow-color-1),
            0 0 20px var(--neon-flow-color-1);
    }
    33% {
        border-color: var(--neon-flow-color-2);
        box-shadow: 
            0 0 10px var(--neon-flow-color-2),
            0 0 20px var(--neon-flow-color-2);
    }
    66% {
        border-color: var(--neon-flow-color-3);
        box-shadow: 
            0 0 10px var(--neon-flow-color-3),
            0 0 20px var(--neon-flow-color-3);
    }
}

@keyframes text-glow-flow {
    0% {
        text-shadow: 
            0 0 5px var(--neon-flow-color-1),
            0 0 10px var(--neon-flow-color-1),
            0 0 15px var(--neon-flow-color-1);
        color: #ffffff;
    }
    50% {
        text-shadow: 
            0 0 5px var(--neon-flow-color-2),
            0 0 10px var(--neon-flow-color-2),
            0 0 15px var(--neon-flow-color-2);
        color: #ffffff;
    }
    100% {
        text-shadow: 
            0 0 5px var(--neon-flow-color-3),
            0 0 10px var(--neon-flow-color-3),
            0 0 15px var(--neon-flow-color-3);
        color: #ffffff;
    }
}

@keyframes marquee-pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.15);
        opacity: 0.9;
    }
}

@keyframes marquee-scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* Marquee Section */
.marquee-section {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(135deg, #0a0a0a, #1a1a2e, #16213e);
    color: #ffffff;
    overflow: hidden;
    border-bottom: 2px solid;
    animation: theme-colors 4s ease-in-out infinite;
    box-shadow: 
        0 0 10px var(--neon-flow-color-1),
        0 0 20px var(--neon-flow-color-1),
        0 0 30px var(--neon-flow-color-1),
        inset 0 0 20px rgba(var(--neon-flow-color-1), 0.1);
    z-index: 1001;
    height: var(--marquee-height); /* Fixed height */
    display: flex;
    align-items: center;
    padding: 0 20px; /* Add padding to prevent content from touching edges */
}

.marquee-container {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 15px;
}

.marquee-icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px; /* Smaller icon for marquee */
    height: 24px;
    z-index: 2;
    position: relative;
}

.marquee-icon-emoji {
    font-size: 20px;
    display: inline-block;
    animation: marquee-pulse 2s ease-in-out infinite, text-glow-flow 3s ease-in-out infinite alternate;
    text-shadow: 
        0 0 5px var(--neon-flow-color-1),
        0 0 10px var(--neon-flow-color-1),
        0 0 15px var(--neon-flow-color-1);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.marquee-wrapper {
    flex: 1;
    overflow: hidden;
    position: relative;
    height: 100%; /* Ensure wrapper takes full height */
    display: flex;
    align-items: center;
}

.marquee-content {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    animation: marquee-scroll 30s linear infinite;
    gap: 30px;
    height: 100%; /* Ensure content takes full height */
}

.marquee-text {
    font-size: 15px; /* Slightly smaller font for marquee */
    font-weight: 600;
    color: #ffffff;
    text-decoration: none;
    animation: text-glow-flow 3s ease-in-out infinite alternate;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex; /* Use flex to vertically center content if needed */
    align-items: center;
    height: 100%; /* Take full height of wrapper */
}

.marquee-text:hover {
    text-shadow: 
        0 0 10px var(--neon-flow-color-1),
        0 0 20px var(--neon-flow-color-1),
        0 0 30px var(--neon-flow-color-1),
        0 0 40px var(--neon-flow-color-1);
    transform: scale(1.05);
    color: #ffffff;
}

.marquee-separator {
    font-size: 15px;
    color: rgba(255, 255, 255, 0.6);
    margin: 0 15px;
    text-shadow: 
        0 0 3px var(--neon-flow-color-1),
        0 0 6px var(--neon-flow-color-1);
}

/* Site Header */
.site-header {
    position: fixed;
    top: var(--marquee-height); /* Position below marquee */
    left: 0;
    width: 100%;
    z-index: 1000; /* Below marquee, above page content */
    background: linear-gradient(135deg, #0a0a0a, #1a1a2e, #16213e);
    color: var(--secondary-color);
}

/* Header Top Bar (Desktop) */
.header-top {
    display: flex; /* Desktop default */
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, #0a0a0a, #1a1a2e, #16213e);
    border-bottom: 2px solid;
    animation: theme-colors 4s ease-in-out infinite;
    box-shadow: 
        0 0 10px var(--neon-yellow), /* Neon yellow glow for top bar */
        0 0 20px var(--neon-yellow),
        inset 0 0 10px rgba(255, 255, 0, 0.1);
    height: var(--header-top-desktop-height);
}

.header-container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px; /* Padding for logo and buttons */
}

.logo {
    font-size: 28px;
    font-weight: bold;
    color: var(--secondary-color); /* White for logo, no neon effect */
    text-decoration: none;
    display: block; /* Ensure it's block for proper alignment */
}

.logo img {
    display: block;
    max-width: 100%;
    height: auto;
    max-height: 40px; /* Desktop logo height */
}

/* Desktop Navigation Buttons */
.desktop-nav-buttons {
    display: flex; /* Desktop default */
    gap: 10px;
    align-items: center;
}

/* Mobile Navigation Buttons (Hidden on Desktop) */
.mobile-nav-buttons {
    display: none; /* Hidden on desktop */
}

/* Main Navigation (Desktop) */
.main-nav {
    display: flex; /* Desktop default */
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, #1a1a2e, #16213e, #0f3460); /* Slightly different dark gradient */
    border-top: 2px solid;
    border-bottom: 2px solid;
    animation: theme-colors 5s ease-in-out infinite alternate; /* Dynamic border color, different animation speed */
    box-shadow: 
        0 0 8px var(--neon-red), /* Neon red glow for main nav */
        0 0 16px var(--neon-red),
        inset 0 0 8px rgba(255, 0, 0, 0.1);
    height: var(--main-nav-desktop-height);
}

.nav-container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 20px;
    gap: 25px; /* Spacing between nav links */
}

.nav-link {
    font-size: 16px;
    font-weight: 500;
    color: var(--secondary-color); /* White for nav links, no neon */
    padding: 10px 0;
    transition: color 0.3s ease, transform 0.3s ease;
    white-space: nowrap;
}

.nav-link:hover {
    color: var(--primary-color); /* Hover effect using primary color */
    transform: translateY(-2px);
}

/* Hamburger Menu (Hidden on Desktop) */
.hamburger-menu {
    display: none; /* Hidden on desktop */
    cursor: pointer;
    width: 30px;
    height: 24px;
    position: relative;
    z-index: 1002; /* Above mobile overlay */
    transition: all 0.3s ease;
    padding: 5px; /* Add padding for clickable area */
}

.hamburger-menu span {
    display: block;
    position: absolute;
    height: 3px;
    width: 100%;
    background: var(--neon-flow-color-1); /* Dynamic neon color */
    border-radius: 3px;
    opacity: 1;
    left: 0;
    transform: rotate(0deg);
    transition: 0.25s ease-in-out;
    animation: text-glow-flow 3s ease-in-out infinite alternate; /* Dynamic glow */
}

.hamburger-menu span:nth-child(1) { top: 0px; }
.hamburger-menu span:nth-child(2) { top: 10px; }
.hamburger-menu span:nth-child(3) { top: 20px; }

.hamburger-menu.active span:nth-child(1) { top: 10px; transform: rotate(135deg); background: var(--neon-red); }
.hamburger-menu.active span:nth-child(2) { opacity: 0; left: -60px; }
.hamburger-menu.active span:nth-child(3) { top: 10px; transform: rotate(-135deg); background: var(--neon-red); }

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    display: none; /* Hidden on desktop */
    position: fixed;
    top: var(--header-offset); /* Below fixed header */
    left: 0;
    width: 100%;
    height: calc(100% - var(--header-offset));
    background: rgba(0, 0, 0, 0.7);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Buttons */
.btn {
    position: relative;
    background: linear-gradient(135deg, var(--login-color), var(--register-color)); /* Red gradient */
    padding: 10px 20px; /* Adjusted padding for buttons */
    color: var(--login-register-font-color); /* Yellow font color */
    text-decoration: none;
    border-radius: 5px;
    border: 2px solid;
    animation: theme-colors 4s ease-in-out infinite; /* Dynamic border color */
    text-shadow: 
        0 0 5px var(--login-register-font-color),
        0 0 10px var(--login-register-font-color);
    transition: all 0.3s ease;
    font-size: 15px; /* Slightly smaller font size */
    font-weight: bold;
    white-space: nowrap; /* Prevent text wrapping on desktop */
}

.btn:hover {
    animation-duration: 2s;
    transform: translateY(-2px);
    box-shadow: 
        0 0 15px var(--login-register-font-color),
        0 0 30px var(--login-register-font-color),
        inset 0 0 15px rgba(255, 255, 0, 0.3);
}

/* Footer Section */
.site-footer {
    background-color: #1a1a1a; /* Dark background for footer */
    color: var(--secondary-color);
    padding: 40px 20px 20px;
    font-size: 14px;
    line-height: 1.8;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* Four columns */
    gap: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-col {
    padding: 10px 0;
}

.footer-logo {
    font-size: 24px;
    font-weight: bold;
    color: var(--primary-color); /* Primary green for footer logo */
    margin-bottom: 15px;
    display: block;
}

.footer-description {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    word-wrap: break-word; /* Ensure full text display */
    overflow-wrap: break-word;
}

.site-footer h4 {
    font-size: 16px;
    color: var(--secondary-color);
    margin-bottom: 15px;
    font-weight: bold;
}

.footer-nav ul {
    list-style: none;
}

.footer-nav li {
    margin-bottom: 8px;
}

.footer-nav a {
    color: rgba(255, 255, 255, 0.7);
    transition: color 0.3s ease;
}

.footer-nav a:hover {
    color: var(--primary-color);
}

/* Payment Methods, Game Providers, Social Media Sections */
.payment-methods, .game-providers-section, .social-media-section {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.payment-methods h4, .game-providers-section h4, .social-media-section h4 {
    text-align: left;
}

.payment-icons, .game-providers-icons, .social-media-icons {
    display: flex;
    flex-wrap: wrap;
    flex-direction: row;
    align-items: flex-start;
    gap: 8px; /* Consistent gap for icons */
    width: 100%;
}

.payment-icons img, .game-providers-icons img, .social-media-icons img {
    max-height: 50px;
    height: auto;
    width: auto;
    object-fit: contain;
    filter: brightness(0.8); /* Slightly dim icons for dark background */
    transition: filter 0.3s ease;
}

.payment-icons img:hover, .game-providers-icons img:hover, .social-media-icons img:hover {
    filter: brightness(1); /* Brighten on hover */
}

/* Copyright Section */
.footer-bottom {
    text-align: center;
    padding-top: 20px;
    margin-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.5);
    font-size: 13px;
}

/* Responsive Styles */
@media (max-width: 768px) {
    /* Marquee Section Mobile Adjustments */
    .marquee-section {
        height: 40px; /* Slightly smaller marquee on mobile */
        padding: 0 10px;
    }
    .marquee-icon {
        width: 20px;
        height: 20px;
    }
    .marquee-icon-emoji {
        font-size: 16px;
    }
    .marquee-text {
        font-size: 13px;
    }
    .marquee-separator {
        font-size: 13px;
        margin: 0 10px;
    }
    .marquee-content {
        gap: 20px;
        animation: marquee-scroll 25s linear infinite;
    }

    /* Header Top Bar Mobile */
    .site-header {
        height: calc(var(--mobile-header-top-height) + var(--mobile-nav-buttons-height)); /* Total fixed header height */
    }

    .header-top {
        height: var(--mobile-header-top-height); /* Fixed height for mobile header top */
        border-bottom: none;
        box-shadow: none;
        animation: none;
        position: relative;
    }
    
    .header-container {
        padding: 0 15px;
        width: 100%;
        max-width: none; /* Important: no max-width on mobile */
        justify-content: flex-start;
        height: 100%;
    }

    .hamburger-menu {
        display: block;
        margin-right: auto;
        order: 1;
        z-index: 1002;
    }

    .logo {
        flex: 1 !important;
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        order: 2;
        font-size: 24px;
        text-align: center;
        max-width: calc(100% - 60px); /* Limit logo width to prevent overlap with hamburger */
    }

    .logo img {
        max-height: 35px;
    }

    .desktop-nav-buttons {
        display: none;
    }

    /* Mobile Navigation Buttons (Always visible) */
    .mobile-nav-buttons {
        display: flex !important;
        justify-content: center;
        align-items: center;
        gap: 10px;
        padding: 10px 15px;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        background: linear-gradient(135deg, #0a0a0a, #1a1a2e, #16213e);
        border-bottom: 2px solid;
        animation: theme-colors 4s ease-in-out infinite;
        box-shadow: 
            0 0 5px var(--neon-yellow),
            0 0 10px var(--neon-yellow),
            inset 0 0 5px rgba(255, 255, 0, 0.1);
        height: var(--mobile-nav-buttons-height);
    }

    .mobile-nav-buttons .btn {
        flex: 1;
        min-width: 0;
        max-width: calc(50% - 5px); /* Half width minus gap */
        padding: 8px 12px;
        font-size: 13px;
        white-space: normal;
        word-wrap: break-word;
        overflow-wrap: break-word;
        text-align: center;
    }

    /* Main Navigation Mobile */
    .main-nav {
        display: none; /* Hidden by default on mobile */
        flex-direction: column;
        position: fixed;
        top: var(--header-offset); /* Below fixed header and mobile buttons */
        left: 0;
        width: 75%; /* Slide-in menu width */
        max-width: 300px;
        height: calc(100% - var(--header-offset)); /* Full height below header */
        background: linear-gradient(135deg, #0a0a0a, #1a1a2e, #16213e);
        border-right: 2px solid;
        animation: theme-colors 4s ease-in-out infinite;
        box-shadow: 
            0 0 10px var(--neon-cyan),
            0 0 20px var(--neon-cyan),
            inset 0 0 10px rgba(0, 255, 255, 0.1);
        transform: translateX(-100%); /* Start off-screen */
        transition: transform 0.3s ease;
        z-index: 1000;
        overflow-y: auto;
        align-items: flex-start;
        padding: 20px 0;
    }

    .main-nav.active {
        display: flex; /* Show menu when active */
        transform: translateX(0);
    }

    .nav-container {
        flex-direction: column;
        align-items: flex-start;
        padding: 0 20px;
        gap: 0;
        width: 100%;
        max-width: none;
    }

    .nav-link {
        width: 100%;
        padding: 12px 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        font-size: 16px;
    }
    .nav-link:last-child {
        border-bottom: none;
    }

    /* Footer Responsive */
    .footer-container {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .footer-col.footer-about {
        order: -1;
    }

    .payment-methods, .game-providers-section, .social-media-section {
        margin-top: 15px;
        padding-top: 15px;
    }

    .footer-bottom {
        padding-top: 15px;
        margin-top: 15px;
    }

    /* Mobile content overflow prevention */
    .page-content img {
      max-width: 100% !important;
      height: auto !important;
      display: block;
    }
    .page-content {
      overflow-x: hidden;
      max-width: 100%;
    }
    body {
      overflow-x: hidden;
    }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@media (max-width: 768px) {
  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }
  body {
    overflow-x: hidden;
  }
}
