/* --- 全局重置与变量 --- */
:root {
    --primary-green: #27ae60;
    --primary-red: #d92b2b;
    --dark-bg: #1a1a1a;
    --light-bg: #f8f8f8;
    --text-color: #333;
    --white: #ffffff;
    --border-color: #e0e0e0;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif; color: var(--text-color); line-height: 1.6; background-color: var(--white); }
a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; }

/* --- 通用工具类 --- */
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.text-center { text-align: center; }
.mt-40 { margin-top: 40px; }
.sub-text { font-size: 0.8rem; margin-top: 10px; color: #666; }

.btn { display: inline-block; padding: 12px 24px; border-radius: 4px; font-weight: bold; text-align: center; cursor: pointer; }
.btn-green { background-color: var(--primary-green); color: white; border: none; }
.btn-green:hover { background-color: #219150; }
.btn-outline { border: 1px solid var(--primary-red); color: var(--primary-red); background: transparent; }
.btn-outline:hover { background: var(--primary-red); color: white; }
.btn-large { padding: 15px 40px; font-size: 1.2rem; }

.section-title { text-align: center; font-size: 2rem; margin-bottom: 40px; color: #222; }

/* --- Header --- */
header { background-color: var(--dark-bg); color: var(--white); position: sticky; top: 0; z-index: 1000; }
.top-bar { display: flex; justify-content: space-between; align-items: center; padding: 15px 0; }
.logo { font-size: 24px; font-weight: bold; letter-spacing: 1px; }
.logo span { color: var(--primary-red); }
nav ul { display: flex; gap: 20px; flex-wrap: wrap; justify-content: center; }
nav a { font-size: 14px; font-weight: 500; }
nav a:hover { color: var(--primary-red); }
.auth-actions { display: flex; gap: 10px; align-items: center; }
.auth-link { font-size: 13px; color: #ccc; }
.btn-register-small { background: var(--primary-red); color: white; padding: 8px 16px; border-radius: 3px; font-size: 13px; cursor: pointer; }

/* --- Hero Section --- */
.hero {
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), url('/script/xm.xmzxz.com/homepage-2023.jpg') no-repeat center center/cover;
    color: white;
    text-align: center;
    padding: 100px 20px;
}
.hero h1 { font-size: 3rem; margin-bottom: 10px; }
.hero p { font-size: 1.2rem; margin-bottom: 30px; opacity: 0.9; }
.hero .sub-text { color: #aaa; }

/* --- Stats Bar --- */
.stats-bar { background: white; padding: 30px 0; border-bottom: 1px solid var(--border-color); }
.stats-grid { display: flex; justify-content: space-around; text-align: center; flex-wrap: wrap; gap: 20px; }
.stat-item h3 { font-size: 2.5rem; color: var(--primary-red); margin-bottom: 5px; }
.stat-item p { font-size: 1rem; color: #666; font-weight: 500; }

/* --- Contest Banner --- */
.contest-banner {
    background: linear-gradient(135deg, #0c2e5c 0%, #1a4f9c 100%);
    color: white;
    padding: 50px 0;
    text-align: center;
}
.contest-content h2 { font-size: 2.2rem; margin-bottom: 10px; }
.contest-content p { margin-bottom: 25px; font-size: 1.1rem; }

/* --- Features --- */
.features { padding: 80px 0; background: #fff; }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.feature-card { display: flex; align-items: flex-start; gap: 15px; padding: 20px; border: 1px solid #eee; border-radius: 8px; transition: transform 0.2s; }
.feature-card:hover { transform: translateY(-5px); box-shadow: 0 5px 15px rgba(0,0,0,0.05); }
.feature-icon { width: 50px; height: 50px; background: #ffebeb; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: var(--primary-red); font-size: 20px; flex-shrink: 0; }
.feature-text h4 { font-size: 1.1rem; margin-bottom: 5px; }
.feature-text p { font-size: 0.9rem; color: #666; }

/* --- Platforms --- */
.platforms { padding: 80px 0; background: var(--light-bg); text-align: center; }
.platform-img-container { margin: 40px 0; }
.platform-img-container img { margin: 0 auto; max-width: 80%; box-shadow: 0 10px 30px rgba(0,0,0,0.1); border-radius: 10px; }

/* --- Markets --- */
.markets { padding: 80px 0; }
.markets-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; text-align: center; }
.market-item { padding: 30px; border: 1px solid #eee; border-radius: 8px; }
.market-icon { font-size: 40px; margin-bottom: 15px; color: var(--primary-red); }
.market-item h4 { margin-bottom: 10px; }
.market-item p { font-size: 0.9rem; color: #777; }

/* --- Footer --- */
footer { background: #222; color: #aaa; padding: 40px 0; text-align: center; font-size: 0.9rem; }
footer p { margin-top: 10px; }

/* --- 移动端适配 --- */
@media (max-width: 768px) {
    .top-bar { flex-direction: column; gap: 15px; }
    .hero h1 { font-size: 2rem; }
    .stats-grid { flex-direction: column; gap: 30px; }
    .section-title { font-size: 1.5rem; }
}