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

:root {
    --primary: #173926;
    --primary-dark: #0d2618;
    --primary-light: #1e5a3a;
    --gold: #ffd700;
    --gold-light: #ffed4e;
    --red: #ff4444;
    --white: #ffffff;
    --gray: #888888;
    --light-gray: #f5f5f5;
    --text: #333333;
    --text-light: #666666;
}

body {
    font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
    background: #fff;
}

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

/* ========== Navbar ========== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(23, 57, 38, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    transition: all 0.3s;
    border-bottom: 1px solid rgba(255, 215, 0, 0.2);
}

.navbar.scrolled {
    background: rgba(23, 57, 38, 0.98);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 24px;
    font-weight: bold;
    color: var(--gold);
    display: flex;
    align-items: center;
}

.logo .logo-img {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid rgba(212, 163, 64, 0.4);
    box-shadow: 0 0 8px rgba(212, 163, 64, 0.2);
}

.logo span {
    margin-left: 8px;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
    align-items: center;
}

.nav-menu a {
    color: #fff;
    text-decoration: none;
    font-size: 15px;
    transition: color 0.3s;
}

.nav-menu a:hover {
    color: var(--gold);
}

.nav-play {
    background: var(--gold);
    color: var(--primary) !important;
    padding: 8px 20px;
    border-radius: 20px;
    font-weight: bold;
    transition: all 0.3s;
}

.nav-play:hover {
    background: var(--gold-light);
    transform: scale(1.05);
}

.nav-login {
    background: transparent;
    color: var(--gold) !important;
    padding: 8px 20px;
    border-radius: 20px;
    font-weight: bold;
    border: 1px solid var(--gold);
    margin-right: 8px;
    transition: all 0.3s;
}
.nav-login:hover {
    background: rgba(212, 163, 64, 0.1);
    transform: scale(1.05);
}

/* ========== Hero Section ========== */
.hero {
    min-height: 100vh;
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 50%, var(--primary-light) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding-top: 80px;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(255, 215, 0, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(255, 215, 0, 0.08) 0%, transparent 50%);
}

.hero-content {
    text-align: center;
    z-index: 1;
    padding: 40px 20px;
}

.floating-cards {
    position: relative;
    width: 300px;
    height: 120px;
    margin: 0 auto 40px;
}

.card-fan {
    position: absolute;
    width: 50px;
    height: 80px;
    background: linear-gradient(145deg, #2c3e50, #1a252f);
    border-radius: 8px;
    border: 2px solid var(--gold);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.4);
    animation: float 3s ease-in-out infinite;
}

.card-fan.c1 { left: 30px; top: 10px; animation-delay: 0s; }
.card-fan.c2 { left: 90px; top: 30px; animation-delay: 0.5s; }
.card-fan.c3 { left: 150px; top: 20px; animation-delay: 1s; }
.card-fan.c4 { left: 210px; top: 40px; animation-delay: 1.5s; }

.card-fan::before {
    content: '🎴';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 24px;
}

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-15px) rotate(5deg); }
}

.hero-title {
    margin-bottom: 20px;
}

.title-main {
    display: block;
    font-size: 64px;
    font-weight: bold;
    color: var(--gold);
    text-shadow: 0 0 30px rgba(255, 215, 0, 0.5);
    letter-spacing: 10px;
}

.title-sub {
    display: block;
    font-size: 28px;
    color: #fff;
    margin-top: 10px;
    letter-spacing: 5px;
}

.hero-desc {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 40px;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 60px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s;
    font-family: inherit;
}

.btn-lg {
    padding: 18px 40px;
    font-size: 18px;
}

.btn-xl {
    padding: 22px 50px;
    font-size: 20px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--gold), var(--gold-light));
    color: var(--primary);
    box-shadow: 0 5px 20px rgba(255, 215, 0, 0.4);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.6);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-3px);
}

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

.btn-outline:hover {
    background: var(--primary);
    color: #fff;
}

.btn-arrow {
    transition: transform 0.3s;
}

.btn-primary:hover .btn-arrow {
    transform: translateX(5px);
}

.hero-stats {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 40px;
    background: rgba(0, 0, 0, 0.2);
    padding: 20px 40px;
    border-radius: 15px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 215, 0, 0.2);
}

.stat-item {
    text-align: center;
}

.stat-num {
    display: block;
    font-size: 32px;
    font-weight: bold;
    color: var(--gold);
}

.stat-label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
}

.stat-divider {
    width: 1px;
    height: 40px;
    background: rgba(255, 255, 255, 0.2);
}

.hero-scroll {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(10px); }
}

/* ========== Section Title ========== */
.section-title {
    text-align: center;
    font-size: 36px;
    color: var(--primary);
    margin-bottom: 50px;
    position: relative;
    padding-bottom: 20px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: var(--gold);
    border-radius: 2px;
}

/* ========== Features ========== */
.features {
    padding: 100px 0;
    background: #fff;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.feature-card {
    background: #fff;
    border-radius: 15px;
    padding: 40px 30px;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.08);
    transition: all 0.3s;
    border: 1px solid rgba(23, 57, 38, 0.1);
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
    border-color: var(--gold);
}

.feature-icon {
    font-size: 48px;
    text-align: center;
    margin-bottom: 20px;
}

.feature-card h3 {
    font-size: 24px;
    color: var(--primary);
    text-align: center;
    margin-bottom: 15px;
}

.feature-card > p {
    text-align: center;
    color: var(--text-light);
    margin-bottom: 20px;
}

.feature-list {
    list-style: none;
    padding: 0;
}

.feature-list li {
    padding: 8px 0;
    text-align: center;
    color: var(--text-light);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.feature-list li:first-child {
    border-top: none;
}

/* ========== Rules Preview ========== */
.rules-preview {
    padding: 100px 0;
    background: var(--light-gray);
}

.rules-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.rule-card {
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    transition: all 0.3s;
    border-top: 4px solid transparent;
}

.rule-card:hover {
    border-top-color: var(--gold);
    transform: translateY(-5px);
}

.rule-num {
    font-size: 48px;
    font-weight: bold;
    color: rgba(23, 57, 38, 0.1);
    margin-bottom: 15px;
}

.rule-card h3 {
    font-size: 22px;
    color: var(--primary);
    margin-bottom: 10px;
}

.rule-card p {
    color: var(--text-light);
}

.rules-more {
    text-align: center;
}

/* ========== Ranking ========== */
.ranking {
    padding: 100px 0;
    background: #fff;
}

.ranking-table {
    max-width: 700px;
    margin: 0 auto;
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.ranking-header {
    display: grid;
    grid-template-columns: 80px 1fr 120px 120px;
    background: var(--primary);
    color: #fff;
    padding: 18px 20px;
    font-weight: bold;
    font-size: 15px;
}

.ranking-list {
    max-height: 500px;
    overflow-y: auto;
}

.ranking-item {
    display: grid;
    grid-template-columns: 80px 1fr 120px 120px;
    padding: 15px 20px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: background 0.3s;
    align-items: center;
}

.ranking-item:hover {
    background: rgba(23, 57, 38, 0.05);
}

.ranking-item.top-1 { background: rgba(255, 215, 0, 0.1); }
.ranking-item.top-2 { background: rgba(192, 192, 192, 0.1); }
.ranking-item.top-3 { background: rgba(205, 127, 50, 0.1); }

.col-rank {
    font-weight: bold;
    color: var(--primary);
}

.top-1 .col-rank::before { content: '🥇 '; }
.top-2 .col-rank::before { content: '🥈 '; }
.top-3 .col-rank::before { content: '🥉 '; }

.col-player {
    color: var(--text);
    font-weight: 500;
}

.col-score {
    color: var(--gold);
    font-weight: bold;
}

.col-win {
    color: var(--text-light);
}

.ranking-loading {
    padding: 40px;
    text-align: center;
    color: var(--gray);
}

.ranking-tip {
    text-align: center;
    color: var(--gray);
    font-size: 13px;
    margin-top: 20px;
}

/* ========== CTA Section ========== */
.cta {
    padding: 80px 0;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    text-align: center;
}

.cta h2 {
    font-size: 36px;
    color: var(--gold);
    margin-bottom: 15px;
}

.cta p {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 30px;
}

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

/* ========== Footer ========== */
.footer {
    background: var(--primary-dark);
    color: rgba(255, 255, 255, 0.7);
    padding: 60px 0 20px;
}

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

.footer-brand .logo-sm {
    font-size: 20px;
    font-weight: bold;
    color: var(--gold);
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-brand .logo-img-sm {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid rgba(212, 163, 64, 0.3);
}

.footer-brand p {
    margin-top: 10px;
    font-size: 14px;
}

.footer-links h4,
.footer-contact h4,
.footer-share h4 {
    color: #fff;
    margin-bottom: 15px;
    font-size: 15px;
}

.footer-links a {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    margin-bottom: 8px;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--gold);
}

.share-buttons {
    display: flex;
    gap: 10px;
}

.share-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    padding: 8px 15px;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 13px;
}

.share-btn:hover {
    background: rgba(255, 215, 0, 0.2);
    border-color: var(--gold);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 13px;
}

/* ========== Hamburger Menu ========== */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 5px;
    background: none;
    border: none;
    z-index: 1001;
}

.hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--gold);
    border-radius: 2px;
    transition: all 0.3s;
}

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

/* ========== Responsive ========== */
@media (max-width: 768px) {
    .hamburger { display: flex; }
    
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        max-width: 300px;
        height: 100vh;
        background: var(--primary-dark);
        flex-direction: column;
        padding: 80px 30px 30px;
        gap: 20px;
        transition: right 0.3s ease;
        z-index: 1000;
        border-left: 1px solid rgba(255, 215, 0, 0.2);
    }
    
    .nav-menu.open {
        right: 0;
    }
    
    .nav-menu a {
        font-size: 18px;
    }
    
    .nav-play {
        display: inline-block !important;
        text-align: center;
        padding: 12px 20px !important;
    }
    
    .nav-login {
        display: inline-block !important;
        text-align: center;
        padding: 12px 20px !important;
        margin-right: 0;
    }
    
    .nav-menu a:not(.nav-play):not(.nav-login) { display: block; }
    
    .title-main {
        font-size: 42px;
        letter-spacing: 5px;
    }
    
    .title-sub {
        font-size: 20px;
    }
    
    .hero-desc {
        font-size: 16px;
    }
    
    .hero-stats {
        gap: 20px;
        padding: 15px 25px;
    }
    
    .stat-num {
        font-size: 24px;
    }
    
    .floating-cards {
        transform: scale(0.7);
    }
    
    .section-title {
        font-size: 28px;
    }
    
    .features,
    .rules-preview,
    .ranking {
        padding: 60px 0;
    }
    
    .ranking-header,
    .ranking-item {
        grid-template-columns: 60px 1fr 80px 80px;
        font-size: 13px;
        padding: 12px 15px;
    }
    
    .col-win {
        display: none;
    }
    
    .ranking-header .col-win {
        display: none;
    }
    
    .footer-content {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 480px) {
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn-lg {
        width: 100%;
        max-width: 280px;
        justify-content: center;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 15px;
    }
    
    .stat-divider {
        width: 40px;
        height: 1px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
}
