/* Basic Resets & Global Styles */
:root {
    --primary-gold: #FFD700; /* Warm Gold */
    --secondary-red: #DC143C; /* Crimson Red */
    --dark-bg: #1a1a1a;
    --light-text: #f0f0f0;
    --gray-text: #aaaaaa;
    --accent-blue: #007bff;
    --border-color: rgba(255, 255, 255, 0.1);
    --font-family-sans: 'Arial', sans-serif;
    --font-family-serif: 'Georgia', serif;
}

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

body {
    font-family: var(--font-family-sans);
    line-height: 1.6;
    color: var(--light-text);
    background-color: #0d0d0d;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: var(--primary-gold);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--secondary-red);
}

ul {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: bold;
    text-align: center;
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease;
    border: none;
}

.btn-primary {
    background-color: var(--primary-gold);
    color: var(--dark-bg);
}

.btn-primary:hover {
    background-color: #e6c200; /* Slightly darker gold */
}

.btn-secondary {
    background-color: var(--secondary-red);
    color: var(--light-text);
}

.btn-secondary:hover {
    background-color: #b00f2e; /* Slightly darker red */
}

/* Header Styles */
.main-header {
    background-color: var(--dark-bg);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-top-bar {
    background-color: #0a0a0a;
    padding: 10px 0;
    font-size: 0.9em;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.language-selector {
    position: relative;
    display: inline-block;
}

.lang-btn {
    background: none;
    border: none;
    color: var(--gray-text);
    cursor: pointer;
    padding: 5px 10px;
    display: flex;
    align-items: center;
}

.lang-btn .flag-icon {
    width: 20px;
    height: 15px;
    margin-right: 8px;
    border: 1px solid var(--gray-text);
}

.lang-btn i {
    margin-left: 5px;
    font-size: 0.8em;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--dark-bg);
    border: 1px solid var(--border-color);
    border-radius: 5px;
    min-width: 150px;
    display: none;
    z-index: 100;
    padding: 5px 0;
}

.language-selector:hover .dropdown-menu,
.lang-btn[aria-expanded="true"] + .dropdown-menu {
    display: block;
}

.dropdown-menu li a {
    display: flex;
    align-items: center;
    padding: 8px 15px;
    color: var(--light-text);
    white-space: nowrap;
}

.dropdown-menu li a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--primary-gold);
}

.dropdown-menu li a .flag-icon {
    width: 20px;
    height: 15px;
    margin-right: 8px;
}

.user-actions {
    display: flex;
    gap: 10px;
}

.header-main-nav {
    padding: 15px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-main-nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    display: flex;
    align-items: center;
    font-size: 1.8em;
    font-weight: bold;
    color: var(--primary-gold);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.logo-img {
    height: 40px; /* Adjust as needed */
    margin-right: 10px;
}

.logo-text {
    color: var(--light-text);
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}

.main-navigation .nav-list {
    display: flex;
    gap: 25px;
}

.nav-item {
    position: relative;
}

.nav-link {
    color: var(--light-text);
    font-weight: 500;
    padding: 10px 0;
    display: block;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-gold);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link.dropdown-toggle::after {
    content: '\f078'; /* Font Awesome chevron-down */
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    font-size: 0.7em;
    margin-left: 8px;
    display: inline-block;
    width: auto; /* Override ::after width */
    background: none;
    position: static;
    transform: rotate(0deg);
    transition: transform 0.3s ease;
}

.nav-link.dropdown-toggle[aria-expanded="true"]::after {
    transform: rotate(180deg);
}

.submenu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--dark-bg);
    border: 1px solid var(--border-color);
    border-radius: 5px;
    min-width: 180px;
    display: none;
    z-index: 90;
    padding: 10px 0;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.nav-item.dropdown:hover .submenu {
    display: block;
}

.submenu li a {
    padding: 8px 15px;
    color: var(--light-text);
    display: block;
    white-space: nowrap;
}

.submenu li a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--primary-gold);
}

.hamburger-menu {
    display: none; /* Hidden on desktop */
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    position: relative;
    z-index: 1010;
}

.hamburger-menu span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--light-text);
    margin-bottom: 5px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.hamburger-menu.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}
.hamburger-menu.active span:nth-child(2) {
    opacity: 0;
}
.hamburger-menu.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

.mobile-only {
    display: none;
}

/* Footer Styles */
.main-footer {
    background-color: var(--dark-bg);
    padding: 40px 0 20px;
    border-top: 1px solid var(--border-color);
    font-size: 0.9em;
    color: var(--gray-text);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.footer-col h3 {
    color: var(--primary-gold);
    margin-bottom: 15px;
    font-size: 1.1em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.footer-col p {
    margin-bottom: 10px;
}

.footer-col ul {
    padding-left: 0;
}

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

.footer-col ul li a {
    color: var(--gray-text);
    transition: color 0.3s ease;
}

.footer-col ul li a:hover {
    color: var(--primary-gold);
}

.social-links {
    margin-top: 20px;
    display: flex;
    gap: 15px;
}

.social-links a {
    color: var(--light-text);
    font-size: 1.5em;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.social-links a:hover {
    background-color: var(--primary-gold);
    color: var(--dark-bg);
}

.footer-bottom {
    border-top: 1px solid var(--border-color);
    padding-top: 20px;
    text-align: center;
}

.payment-methods {
    margin-bottom: 20px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
}

.payment-icon {
    height: 30px;
    filter: grayscale(100%) brightness(150%);
    transition: filter 0.3s ease;
}

.payment-icon:hover {
    filter: grayscale(0%) brightness(100%);
}

.licensing-info {
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.license-logo {
    height: 50px;
    margin-top: 10px;
}

.copyright {
    font-size: 0.85em;
    color: var(--gray-text);
}

/* Responsive Styles */
@media (max-width: 992px) {
    .main-navigation {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%; /* Below header */
        left: 0;
        width: 100%;
        background-color: var(--dark-bg);
        border-top: 1px solid var(--border-color);
        box-shadow: 0 5px 15px rgba(0,0,0,0.5);
        padding-bottom: 20px;
        z-index: 999;
    }

    .main-navigation.active {
        display: flex;
    }

    .main-navigation .nav-list {
        flex-direction: column;
        gap: 0;
        padding: 15px 0;
    }

    .nav-item {
        width: 100%;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }

    .nav-item:last-child {
        border-bottom: none;
    }

    .nav-link {
        padding: 12px 20px;
    }

    .nav-link::after {
        display: none; /* Hide underline on mobile */
    }

    .nav-link.dropdown-toggle::after {
        position: absolute;
        right: 20px;
        top: 50%;
        transform: translateY(-50%) rotate(0deg);
    }

    .nav-link.dropdown-toggle[aria-expanded="true"]::after {
        transform: translateY(-50%) rotate(180deg);
    }

    .submenu {
        position: static;
        display: none;
        background-color: rgba(0,0,0,0.3);
        border: none;
        border-radius: 0;
        box-shadow: none;
        padding: 0;
        width: 100%;
    }

    .nav-item.dropdown .submenu {
        padding-left: 20px;
        border-top: 1px solid rgba(255, 255, 255, 0.05);
    }

    .nav-item.dropdown.active .submenu {
        display: block;
    }

    .hamburger-menu {
        display: block; /* Show on mobile */
    }

    .user-actions {
        display: none; /* Hide desktop login/register */
    }

    .mobile-only {
        display: block;
        margin-top: 15px;
        padding: 0 20px;
    }

    .btn-mobile-login, .btn-mobile-register {
        display: block;
        width: 100%;
        margin-bottom: 10px;
    }

    .logo {
        font-size: 1.5em;
    }

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

@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .social-links {
        justify-content: center;
    }

    .footer-col ul {
        max-width: 300px;
        margin: 0 auto;
    }

    .footer-col ul li {
        display: inline-block;
        margin: 0 10px 8px;
    }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@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;
  }
}
