/* 新增：加载动画 */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #9890e3, #b1f4cf);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.3s, visibility 0.3s;
}

.loader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader-inner {
    position: relative;
    width: 120px;
    height: 120px;
}

.loader-block {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 4px solid transparent;
    border-top-color: #4CAF50;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loader-block:nth-child(1) {
    animation-delay: -0.15s;
    border-top-color: #FFD700;
}

.loader-block:nth-child(2) {
    animation-delay: -0.3s;
    border-top-color: #FF6347;
}

.loader-block:nth-child(3) {
    animation-delay: -0.45s;
    border-top-color: #1E90FF;
}

.loader-block:nth-child(4) {
    animation-delay: -0.6s;
    border-top-color: #32CD32;
}

.loader-block:nth-child(5) {
    animation-delay: -0.75s;
    border-top-color: #BA55D3;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

.loader-text {
    margin-top: 30px;
    font-size: 1.5rem;
    color: white;
    text-align: center;
    font-weight: bold;
    text-shadow: 0 0 10px rgba(255,255,255,0.7);
    letter-spacing: 2px;
}

.progress-bar {
    width: 300px;
    height: 8px;
    background: rgba(255,255,255,0.2);
    border-radius: 4px;
    margin-top: 30px;
    overflow: hidden;
}

.progress {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #4CAF50, #FFD700);
    border-radius: 4px;
    transition: width 0.3s ease;
}

/* 通用样式 */
:root {
    --primary-color: #4CAF50; /* 绿色 */
    --secondary-color: #3f51b5; /* 蓝色 */
    --text-color: #333;
    --light-bg: #f8f8f8;
    --dark-bg: #222;
    --accent-color: #ff6b6b;
    --card-shadow: 0 10px 30px rgba(0,0,0,0.1);
    --transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #fff;
    scroll-behavior: smooth; /* 平滑滚动 */
    overflow-x: hidden;
    position: relative;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

h1, h2, h3, h4 {
    color: var(--secondary-color);
    text-align: center;
    margin-bottom: 20px;
    position: relative;
}

h2:after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    border-radius: 2px;
}

p {
    margin-bottom: 15px;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    text-decoration: underline;
    color: var(--accent-color);
}

/* 按钮样式 - 矩形胶囊形状 */
.btn {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary-color), #45a049);
    color: white;
    padding: 14px 30px;
    border-radius: 50px;
    text-align: center;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    font-weight: bold;
    box-shadow: var(--card-shadow);
    position: relative;
    overflow: hidden;
    text-decoration: none;
    z-index: 1;
}

.btn:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #45a049, var(--primary-color));
    opacity: 0;
    z-index: -1;
    transition: var(--transition);
}

.btn:hover:before {
    opacity: 1;
}

.btn:hover {
    text-decoration: none;
    transform: translateY(-5px);
    box-shadow: 0 12px 20px rgba(0,0,0,0.2);
}

.btn:active {
    transform: translateY(2px);
}

.btn.pulse {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(76, 175, 80, 0.7);
    }
    70% {
        box-shadow: 0 0 0 15px rgba(76, 175, 80, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(76, 175, 80, 0);
    }
}

/* 导航栏 */
.navbar {
    background: linear-gradient(90deg, var(--dark-bg), #1a1a2e);
    color: white;
    padding: 15px 0;
    position: sticky;
    top: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    transition: all 0.3s ease;
}

.navbar.scrolled {
    padding: 10px 0;
    background: rgba(34, 34, 34, 0.95);
    backdrop-filter: blur(10px);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar .logo {
    display: flex;
    align-items: center;
    font-size: 1.5rem;
    font-weight: bold;
    color: white;
    transition: transform 0.3s ease;
}

.navbar .logo:hover {
    transform: scale(1.05);
}

.navbar .logo img {
    height: 45px;
    margin-right: 12px;
    border-radius: 50%;
    transition: var(--transition);
}

.navbar .logo:hover img {
    transform: rotate(15deg);
}

.navbar ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
}

.navbar ul li {
    margin-left: 25px;
    position: relative;
}

.navbar ul li a {
    color: white;
    padding: 8px 5px;
    transition: all 0.3s ease;
    font-weight: 500;
    font-size: 1.1rem;
}

.navbar ul li a:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    transition: width 0.3s ease;
}

.navbar ul li a:hover {
    color: #4CAF50;
    text-decoration: none;
}

.navbar ul li a:hover:after {
    width: 100%;
}

.menu-toggle {
    display: none;
    color: white;
    font-size: 1.8rem;
    cursor: pointer;
}

/* 英雄区 */
.hero-section {
    background: linear-gradient(rgba(0,0,0,0.7), rgba(0,0,0,0.7)), url('../img/bg.png') no-repeat center center/cover;
    color: white;
    text-align: center;
    padding: 150px 0;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-section .gradient-overlay {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 35%;
    background: linear-gradient(to top, 
        rgba(255,255,255,1) 0%, 
        rgba(255,255,255,0.8) 20%, 
        rgba(255,255,255,0.5) 40%, 
        rgba(255,255,255,0) 100%);
    z-index: 1;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.hero-section .container {
    position: relative;
    z-index: 2;
    animation: fadeInUp 1s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-section h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    color: white;
    text-shadow: 0 0 20px rgba(0,0,0,0.8);
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    from {
        text-shadow: 0 0 10px #fff, 0 0 20px #fff, 0 0 30px #4CAF50, 0 0 40px #4CAF50;
    }
    to {
        text-shadow: 0 0 20px #fff, 0 0 30px #4CAF50, 0 0 40px #4CAF50, 0 0 50px #4CAF50;
    }
}

.hero-section p {
    font-size: 1.5rem;
    margin-bottom: 40px;
    color: #eee;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.title-image {
    max-width: 600px;
    width: 50%;
    margin-bottom: 30px;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.mouse {
    width: 30px;
    height: 50px;
    border: 2px solid #fff;
    border-radius: 15px;
    position: relative;
    margin: 0 auto;
}

.wheel {
    width: 6px;
    height: 10px;
    background: #fff;
    border-radius: 3px;
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll 1.5s infinite;
}

@keyframes scroll {
    0% {
        top: 10px;
        opacity: 1;
    }
    50% {
        top: 20px;
        opacity: 0.5;
    }
    100% {
        top: 10px;
        opacity: 1;
    }
}

.arrow {
    width: 20px;
    height: 20px;
    border-right: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: rotate(45deg);
    margin: 10px auto;
    animation: bounce 1.5s infinite;
}

@keyframes bounce {
    0%, 100% {
        transform: rotate(45deg) translateY(0);
    }
    50% {
        transform: rotate(45deg) translateY(-10px);
    }
}

/* 玩法介绍区 */
.gameplay-section {
    padding: 100px 0;
    text-align: center;
    position: relative;
}

.gameplay-section:nth-of-type(odd) {
    background-color: var(--light-bg);
}

.gameplay-section h2 {
    font-size: 2.5rem;
    margin-bottom: 60px;
    position: relative;
    z-index: 2;
}

.gameplay-section h2 i {
    margin-right: 15px;
    color: var(--primary-color);
}

.content-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 60px;
    flex-wrap: wrap;
    position: relative;
    z-index: 2;
}

.content-wrapper.reverse-order {
    flex-direction: row-reverse;
}

.image-container {
    position: relative;
    flex: 1;
    min-width: 300px;
    max-width: 500px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    transition: var(--transition);
}

.image-container:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

.image-container img {
    width: 100%;
    height: auto;
    display: block;
    transition: var(--transition);
}

.image-container:hover img {
    transform: scale(1.05);
}

.image-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: white;
    opacity: 0;
    transform: translateY(20px);
    transition: var(--transition);
}

.image-container:hover .image-overlay {
    opacity: 1;
    transform: translateY(0);
}

.text-content {
    flex: 1;
    min-width: 300px;
    max-width: 600px;
    text-align: left;
}

.text-content p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 25px;
}

.features {
    list-style: none;
    padding: 0;
    margin: 25px 0;
}

.features li {
    margin-bottom: 12px;
    font-size: 1.1rem;
    padding-left: 30px;
    position: relative;
}

.features li i {
    position: absolute;
    left: 0;
    top: 5px;
    color: var(--primary-color);
    font-size: 1.2rem;
}

/* 加入我们区 */
.join-us-section {
    padding: 100px 0;
    text-align: center;
    background: linear-gradient(135deg, #f8f8f8, #e0f7fa);
    position: relative;
}

.join-us-section h2 {
    font-size: 2.8rem;
    margin-bottom: 15px;
}

.subtitle {
    font-size: 1.3rem;
    color: #555;
    margin-bottom: 50px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.join-options {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    margin-top: 50px;
    position: relative;
    z-index: 2;
}

.join-option {
    flex: 1;
    min-width: 280px;
    max-width: 350px;
    background: white;
    border-radius: 20px;
    padding: 40px 30px;
    box-shadow: var(--card-shadow);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(0,0,0,0.05);
}

.join-option:hover {
    transform: translateY(-15px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}

.icon-circle {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), #45a049);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    color: white;
    font-size: 2.2rem;
    transition: var(--transition);
}

.join-option:hover .icon-circle {
    transform: rotate(15deg) scale(1.1);
    background: linear-gradient(135deg, #45a049, var(--primary-color));
}

.join-option h3 {
    color: var(--secondary-color);
    margin-bottom: 15px;
    font-size: 1.8rem;
}

.join-option p {
    margin-bottom: 20px;
    color: #555;
    font-size: 1.1rem;
}

.join-option span {
    font-weight: bold;
    color: var(--accent-color);
    font-size: 1.2rem;
}

.qr-code {
    width: 180px;
    height: 180px;
    margin: 15px auto;
    border: 10px solid white;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border-radius: 10px;
    transition: var(--transition);
}

.qr-code:hover {
    transform: scale(1.05);
}

.server-info {
    background: white;
    border-radius: 20px;
    padding: 40px;
    margin: 70px auto 0;
    max-width: 900px;
    box-shadow: var(--card-shadow);
    text-align: left;
}

.server-info h3 {
    text-align: center;
    margin-bottom: 40px;
    font-size: 2rem;
}

.server-info h3 i {
    margin-right: 15px;
    color: var(--primary-color);
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px;
    background: rgba(76, 175, 80, 0.05);
    border-radius: 15px;
    transition: var(--transition);
}

.info-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
}

.info-item i {
    font-size: 2.5rem;
    color: var(--primary-color);
    min-width: 50px;
    text-align: center;
}

.info-item h4 {
    text-align: left;
    margin-bottom: 5px;
    font-size: 1.3rem;
}

.info-item p {
    margin: 0;
    color: #555;
    font-size: 1.1rem;
}

.join-footer {
    margin-top: 50px;
    font-size: 1.3rem;
    font-weight: bold;
    color: var(--secondary-color);
    position: relative;
    z-index: 2;
}

/* 页脚 */
footer {
    background: linear-gradient(90deg, var(--dark-bg), #1a1a2e);
    color: white;
    padding: 70px 0 0;
    font-size: 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    margin-bottom: 50px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 20px;
}

.footer-logo img {
    width: 70px;
    height: 70px;
    border-radius: 50%;
}

.footer-logo h3 {
    color: white;
    text-align: left;
    margin-bottom: 10px;
    font-size: 1.8rem;
}

.footer-logo p {
    color: #bbb;
    margin: 0;
}

.footer-links h4, .footer-contact h4 {
    color: white;
    font-size: 1.5rem;
    margin-bottom: 25px;
    text-align: left;
}

.footer-links ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 15px;
}

.footer-links a {
    color: #bbb;
    display: block;
    padding: 8px 0;
    transition: var(--transition);
    text-align: left;
}

.footer-links a:hover {
    color: var(--primary-color);
    padding-left: 10px;
    text-decoration: none;
}

.footer-links a i {
    margin-right: 10px;
    width: 25px;
    text-align: center;
}

.footer-contact p {
    color: #bbb;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.social-icons {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background: rgba(255,255,255,0.1);
    color: white;
    border-radius: 50%;
    font-size: 1.3rem;
    transition: var(--transition);
}

.social-icons a:hover {
    background: var(--primary-color);
    transform: translateY(-5px);
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding: 25px 0;
    text-align: center;
    font-size: 1rem;
    color: #999;
}

.footer-bottom p {
    margin: 5px 0;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .navbar ul {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(34, 34, 34, 0.95);
        flex-direction: column;
        padding: 20px 0;
        box-shadow: 0 10px 15px rgba(0,0,0,0.3);
    }
    
    .navbar ul.active {
        display: flex;
    }
    
    .navbar ul li {
        margin: 15px 0;
        text-align: center;
    }
    
    .menu-toggle {
        display: block;
    }
    
    .hero-section h1 {
        font-size: 2.8rem;
    }
    
    .title-image {
        width: 70%;
    }
}

@media (max-width: 768px) {
    .content-wrapper, .content-wrapper.reverse-order {
        flex-direction: column;
    }
    
    .image-container, .text-content {
        max-width: 100%;
    }
    
    .hero-section h1 {
        font-size: 2.3rem;
    }
    
    .hero-section p {
        font-size: 1.2rem;
    }
    
    .join-option {
        min-width: 100%;
    }
    
    .server-info {
        padding: 30px 20px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .hero-section h1 {
        font-size: 2rem;
    }
    
    .title-image {
        width: 90%;
    }
    
    .btn {
        padding: 12px 25px;
        font-size: 1rem;
    }
    
    .gameplay-section h2 {
        font-size: 2rem;
    }
    
    .join-us-section h2 {
        font-size: 2.3rem;
    }
}