/* General Reset & Body Styles */
:root {
    --primary-color: #ffd700; /* Warm Gold */
    --secondary-color: #008080; /* Emerald Green */
    --dark-bg: #1a1a1a;
    --light-text: #f0f0f0;
    --grey-text: #b0b0b0;
    --border-color: #333;
    --hover-color: #ffe033;
    --button-bg: var(--primary-color);
    --button-text: var(--dark-bg);
    --font-family: 'Arial', sans-serif;
}

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

body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--light-text);
    background-color: #0d0d0d;
}

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

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

ul {
    list-style: none;
}

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

/* Header Styles */
.main-header {
    background-color: var(--dark-bg);
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

.header-topbar {
    background-color: #111;
    padding: 8px 0;
    font-size: 0.85em;
    border-bottom: 1px solid #222;
}

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

.topbar-left span {
    margin-right: 20px;
    color: var(--grey-text);
}

.topbar-left i {
    margin-right: 5px;
    color: var(--primary-color);
}

.topbar-right {
    display: flex;
    align-items: center;
}

.topbar-link {
    margin-right: 15px;
    color: var(--grey-text);
}

.language-selector select {
    background-color: #222;
    color: var(--light-text);
    border: 1px solid #444;
    padding: 5px 10px;
    border-radius: 4px;
    cursor: pointer;
}

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

.navbar-brand .site-logo {
    height: 50px; /* Adjust as needed */
    width: auto;
    display: block;
}

.main-navigation {
    flex-grow: 1;
    text-align: center;
}

.nav-list {
    display: flex;
    justify-content: center;
    gap: 25px;
}

.nav-item {
    position: relative;
}

.nav-link {
    color: var(--light-text);
    font-weight: bold;
    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-color);
    transition: width 0.3s ease;
}

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

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #2a2a2a;
    min-width: 180px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    border-radius: 5px;
    padding: 10px 0;
}

.nav-item.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: block;
    padding: 10px 20px;
    color: var(--light-text);
    white-space: nowrap;
}

.dropdown-item:hover {
    background-color: #3a3a3a;
    color: var(--primary-color);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn {
    padding: 8px 15px;
    border-radius: 5px;
    font-weight: bold;
    text-align: center;
    transition: background-color 0.3s ease, color 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn-login {
    background-color: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

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

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

.btn-register:hover {
    background-color: #00a0a0;
}

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

.menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--primary-color);
    margin: 5px 0;
    transition: all 0.3s ease;
}

/* Marquee Styles */
.marquee-section {
    background-color: #222;
    padding: 8px 0;
    overflow: hidden;
    border-top: 1px solid #333;
    color: var(--grey-text);
    margin-bottom: 20px; /* Add some space below marquee */
}

.marquee-wrapper-content {
    display: flex;
    align-items: center;
    white-space: nowrap;
}

.marquee-icon {
    font-size: 1.2em;
    margin-right: 10px;
    color: var(--primary-color);
    flex-shrink: 0;
}

.marquee-content-scroll {
    overflow: hidden;
    flex-grow: 1;
}

.marquee-content-scroll p {
    display: inline-block;
    padding-left: 100%; /* Start off-screen */
    animation: marquee-scroll 25s linear infinite;
}

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

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

.footer-top {
    padding-bottom: 30px;
    border-bottom: 1px solid #222;
    margin-bottom: 20px;
}

.footer-columns {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 20px;
}

.footer-col {
    flex: 1;
    min-width: 200px;
    margin-bottom: 20px;
}

.footer-col h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.1em;
    position: relative;
    padding-bottom: 5px;
}

.footer-col h3::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40px;
    height: 2px;
    background-color: var(--secondary-color);
}

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

.footer-logo img {
    height: 40px;
    margin-bottom: 15px;
}

.footer-col ul {
    padding: 0;
}

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

.footer-col ul li a {
    color: var(--grey-text);
}

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

.social-links a {
    display: inline-block;
    width: 35px;
    height: 35px;
    line-height: 35px;
    text-align: center;
    background-color: #333;
    color: var(--light-text);
    border-radius: 50%;
    margin-right: 10px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

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

.payment-icons img,
.certification-icons img {
    height: 30px;
    margin: 0 10px 10px 0;
    filter: grayscale(80%) brightness(120%);
    transition: filter 0.3s ease;
}

.payment-icons img:hover,
.certification-icons img:hover {
    filter: grayscale(0%) brightness(100%);
}

.footer-bottom {
    text-align: center;
    padding-top: 15px;
}

.copyright {
    color: var(--grey-text);
    font-size: 0.8em;
}

/* Responsive adjustments */
@media (max-width: 992px) {
    .nav-list {
        gap: 15px;
    }
    .main-navigation {
        text-align: right; /* Adjust for mobile menu toggle */
    }
    .header-main .container {
        justify-content: space-between;
    }
    .navbar-brand {
        flex-grow: 1;
    }
}

@media (max-width: 768px) {
    .topbar-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    .topbar-right {
        width: 100%;
        justify-content: space-between;
    }
    .topbar-link {
        margin-right: 0;
    }

    .main-navigation {
        display: none; /* Hide navigation by default on small screens */
        flex-direction: column;
        width: 100%;
        position: absolute;
        top: 100%; /* Position below the header */
        left: 0;
        background-color: #2a2a2a;
        padding: 10px 0;
        box-shadow: 0 4px 8px rgba(0, 0, 0, 0.4);
        z-index: 999;
    }

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

    .nav-list {
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
    }

    .nav-item {
        width: 100%;
    }

    .nav-link {
        padding: 12px 20px;
        border-bottom: 1px solid #333;
    }

    .nav-link::after {
        display: none; /* Remove underline animation for mobile */
    }

    .dropdown-menu {
        position: static; /* Make dropdowns expand inline */
        box-shadow: none;
        background-color: #3a3a3a;
        padding: 0;
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease-out;
    }

    .nav-item.dropdown.active .dropdown-menu {
        max-height: 200px; /* Adjust as needed */
    }

    .dropdown-item {
        padding-left: 30px; /* Indent dropdown items */
    }

    .header-actions {
        order: 3; /* Move buttons below logo/toggle if needed */
        margin-left: auto; /* Push to right */
    }

    .menu-toggle {
        display: block; /* Show menu toggle on small screens */
        margin-left: 15px; /* Space from buttons */
    }

    .menu-toggle.active span:nth-child(1) { transform: rotate(-45deg) translate(-5px, 6px); }
    .menu-toggle.active span:nth-child(2) { opacity: 0; }
    .menu-toggle.active span:nth-child(3) { transform: rotate(45deg) translate(-5px, -6px); }

    .footer-columns {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .footer-col {
        min-width: unset;
        width: 100%;
    }

    .footer-col h3::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .social-links, .payment-icons, .certification-icons {
        justify-content: center;
        display: flex;
        flex-wrap: wrap;
    }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@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;
  }
}
