/* style.css - Rust泯灭社区 | 整页背景固定 + 标题超慢速跳动 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 背景图固定在 body 上，覆盖整个视口，滚动时不动 */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #fff;
    background: url('../assets/images/bj.jpg') no-repeat center center fixed;
    background-size: cover;
    background-color: #1a2a3a;
    overflow-x: hidden;
}

/* 半透明遮罩层，提高文字可读性 */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.2);
    pointer-events: none;
    z-index: -1;
}

body.modal-open {
    overflow: hidden;
}

/* 导航栏：半透明毛玻璃 */
.navbar {
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
}

.logo {
    font-size: 1.8rem;
    font-weight: bold;
    color: #e74c3c;
    text-decoration: none;
    letter-spacing: 1px;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    color: #ecf0f1;
    text-decoration: none;
    transition: color 0.3s ease;
    font-weight: 500;
}

.nav-links a:hover {
    color: #e74c3c;
}

.main-content {
    margin-top: 80px;
}

/* 英雄区：内容居中 */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

/* ===== 标题动画：淡入上浮 + 超慢速跳动 (4秒周期) ===== */
.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    text-shadow: 0 4px 12px rgba(0, 0, 0, 0.6);
    animation: titleFloat 0.8s ease-out, titleBounce 4s ease-in-out infinite;
}

/* 入场：淡入上浮 */
@keyframes titleFloat {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 跳动效果：超慢速，上下弹跳幅度保持8px */
@keyframes titleBounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-8px);
    }
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-button {
    display: inline-block;
    background: linear-gradient(45deg, #e74c3c, #c0392b);
    color: white;
    padding: 15px 30px;
    text-decoration: none;
    border-radius: 25px;
    font-weight: bold;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(231, 76, 60, 0.4);
}

/* 所有内容区块背景完全透明 */
.server-info,
.announcements,
.features,
.community {
    padding: 4rem 0;
    background: transparent;
    color: white;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* 卡片网格 */
.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

/* 卡片：完全透明，仅白色边框和文字阴影 */
.info-card {
    background: transparent;
    backdrop-filter: none;
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.3);
    transition: transform 0.2s ease, border-color 0.2s;
    color: #fff;
}

.info-card:hover {
    transform: translateY(-5px);
    border-color: #e74c3c;
    background: rgba(0,0,0,0.1);
}

.info-card h3 {
    color: #e74c3c;
    margin-bottom: 1rem;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.info-card p {
    margin: 0.5rem 0;
    line-height: 1.5;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.button-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 16px 0 10px 0;
}

.join-server-btn, .copy-server-btn, .copy-qq-btn {
    width: 100%;
    border: none;
    padding: 12px 0;
    font-size: 1rem;
    font-weight: bold;
    color: white;
    text-align: center;
    border-radius: 40px;
    cursor: pointer;
    transition: all 0.25s ease;
    font-family: inherit;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.join-server-btn {
    background: linear-gradient(135deg, #e74c3c, #b03a2e);
}

.join-server-btn:hover {
    transform: scale(1.02);
    background: linear-gradient(135deg, #c0392b, #a82315);
    box-shadow: 0 8px 18px rgba(231,76,60,0.3);
}

.copy-server-btn {
    background: linear-gradient(135deg, #2c3e50, #1e2a36);
    border: 1px solid rgba(255,255,255,0.3);
}

.copy-server-btn:hover {
    transform: scale(1.02);
    background: linear-gradient(135deg, #1e2a36, #141f28);
    box-shadow: 0 8px 18px rgba(0,0,0,0.3);
}

.copy-qq-btn {
    background: linear-gradient(135deg, #27ae60, #1e8449);
    border: 1px solid rgba(255,255,255,0.3);
}

.copy-qq-btn:hover {
    transform: scale(1.02);
    background: linear-gradient(135deg, #1e8449, #196f3d);
    box-shadow: 0 8px 18px rgba(39,174,96,0.3);
}

.wipe-datetime {
    background: rgba(0,0,0,0.4);
    padding: 0.5rem;
    border-radius: 8px;
    margin: 12px 0;
    font-weight: bold;
    text-align: center;
    font-size: 1rem;
    letter-spacing: 1px;
}

.countdown-timer {
    font-size: 1.8rem;
    font-weight: bold;
    text-align: center;
    background: linear-gradient(135deg, #f39c12, #e67e22);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: none;
    margin: 15px 0 5px;
    font-family: monospace;
    letter-spacing: 2px;
}

.countdown-label {
    text-align: center;
    font-size: 0.9rem;
    opacity: 0.9;
}

/* 特色卡片 */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.feature-item {
    text-align: center;
    padding: 2rem;
    background: transparent;
    backdrop-filter: none;
    border-radius: 24px;
    border: 1px solid rgba(255,255,255,0.3);
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
    color: #fff;
}

.feature-item:hover {
    transform: translateY(-5px);
    border-color: #e74c3c;
    background: rgba(0,0,0,0.1);
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(45deg, #e74c3c, #c0392b);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 2rem;
    color: white;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.feature-item h3 {
    margin-bottom: 0.5rem;
    color: #fff;
}

.feature-item p {
    flex-grow: 1;
    margin-bottom: 1rem;
}

.detail-btn {
    background: linear-gradient(135deg, #3498db, #2980b9);
    border: none;
    color: white;
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 10px;
    align-self: center;
    width: auto;
    display: inline-block;
    text-decoration: none;
}

.detail-btn:hover {
    transform: translateY(-2px);
    background: linear-gradient(135deg, #2980b9, #1f6a9e);
    box-shadow: 0 4px 12px rgba(52,152,219,0.3);
}

/* 公告列表 */
.announcement-list {
    max-width: 900px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.announcement-item {
    background: transparent;
    backdrop-filter: none;
    border-radius: 20px;
    padding: 18px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: all 0.25s ease;
    border: 1px solid rgba(255,255,255,0.3);
    color: #fff;
}

.announcement-item:hover {
    transform: translateX(6px);
    border-color: #e74c3c;
    background: rgba(0,0,0,0.1);
}

.announcement-title {
    font-size: 1.2rem;
    font-weight: 600;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 12px;
}

.announcement-title .title-icon {
    font-size: 1.4rem;
}

.announcement-date {
    font-size: 0.85rem;
    color: #ddd;
    background: rgba(0,0,0,0.4);
    padding: 4px 12px;
    border-radius: 40px;
}

.view-more-btn {
    text-align: center;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    color: white;
    padding: 12px;
    border-radius: 40px;
    cursor: pointer;
    transition: 0.2s;
    margin-top: 10px;
    font-weight: bold;
    border: 1px solid rgba(255,255,255,0.2);
}

.view-more-btn:hover {
    background: #e74c3c;
    border-color: transparent;
}

/* 社区链接 */
.community h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: white;
    text-shadow: 0 2px 5px rgba(0,0,0,0.5);
}

.community-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.community-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(5px);
    padding: 1rem 2rem;
    border-radius: 40px;
    text-decoration: none;
    color: white;
    transition: all 0.3s ease;
    border: 1px solid rgba(255,255,255,0.2);
}

.community-link:hover {
    background: #e74c3c;
    transform: translateY(-3px);
    border-color: transparent;
}

/* 页脚 */
.footer {
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(5px);
    color: #ecf0f1;
    text-align: center;
    padding: 2rem 0;
    border-top: 1px solid rgba(255,255,255,0.1);
}

/* 模态框（保持白色背景） */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-container {
    background: #fff;
    width: 90%;
    max-width: 550px;
    border-radius: 32px;
    box-shadow: 0 25px 50px rgba(0,0,0,0.3);
    transform: scale(0.96);
    transition: transform 0.25s cubic-bezier(0.2, 0.9, 0.4, 1.1);
    overflow: hidden;
}

.modal-overlay.active .modal-container {
    transform: scale(1);
}

.modal-header {
    padding: 1.5rem 1.8rem 0.8rem 1.8rem;
    border-bottom: 1px solid #eef2f6;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    font-size: 1.65rem;
    color: #2c3e50;
    margin: 0;
    font-weight: 700;
    line-height: 1.3;
}

.modal-close {
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: #95a5a6;
    transition: color 0.2s;
    line-height: 1;
    padding: 0 6px;
}

.modal-close:hover {
    color: #e74c3c;
}

.modal-date {
    padding: 0 1.8rem;
    font-size: 0.85rem;
    color: #e67e22;
    font-weight: 500;
    background: #fef5e8;
    display: inline-block;
    margin: 0.2rem 1.8rem 0.8rem 1.8rem;
    border-radius: 30px;
    width: fit-content;
}

.modal-content {
    padding: 0.5rem 1.8rem 2rem 1.8rem;
    font-size: 1rem;
    line-height: 1.65;
    color: #2c3e50;
    white-space: pre-wrap;
    word-break: break-word;
    max-height: 60vh;
    overflow-y: auto;
}

.modal-content p {
    margin-bottom: 1rem;
}

.modal-footer {
    padding: 0.8rem 1.8rem 1.8rem 1.8rem;
    text-align: right;
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

.modal-footer button {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    border: none;
    color: white;
    padding: 8px 28px;
    border-radius: 60px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.9rem;
}

.modal-footer button:hover {
    transform: scale(1.02);
    background: linear-gradient(135deg, #c0392b, #a82315);
}

/* 提示弹窗内容 */
.notice-content {
    padding-bottom: 0.5rem;
}
.notice-content strong {
    color: #e74c3c;
}

/* 模态框文字颜色修复 */
.modal-container {
    color: #2c3e50 !important;
}

.modal-container .modal-content {
    color: #2c3e50 !important;
}

.modal-container p {
    color: #2c3e50 !important;
}

/* VIP页面样式 */
.vip-hero {
    padding: 3rem 0;
    text-align: center;
}

.vip-hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: #f39c12;
    text-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

.vip-hero p {
    font-size: 1.3rem;
    color: #ecf0f1;
}

.vip-content {
    padding: 3rem 0;
}

.vip-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
}

.vip-card {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 24px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.vip-card:hover {
    transform: translateY(-5px);
    border-color: #f39c12;
    box-shadow: 0 10px 30px rgba(243, 156, 18, 0.2);
}

.vip-image-wrapper {
    position: relative;
    width: 100%;
    padding-top: 66.67%;
    background: rgba(0, 0, 0, 0.3);
}

.vip-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.vip-info {
    padding: 1.5rem;
}

.vip-info h3 {
    font-size: 1.5rem;
    color: #f39c12;
    margin-bottom: 0.5rem;
}

.vip-info p {
    color: #ecf0f1;
    line-height: 1.6;
}

.vip-notice {
    padding: 3rem 0;
}

.notice-box {
    background: rgba(0, 0, 0, 0.6);
    border: 2px solid #f39c12;
    border-radius: 24px;
    padding: 2rem;
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
    max-width: 700px;
    margin: 0 auto;
}

.notice-icon {
    font-size: 3rem;
    flex-shrink: 0;
}

.notice-content h3 {
    font-size: 1.5rem;
    color: #f39c12;
    margin-bottom: 1rem;
}

.notice-content p {
    color: #ecf0f1;
    line-height: 1.8;
    margin-bottom: 0.8rem;
}

.notice-content p:last-child {
    margin-bottom: 0;
}

.notice-content strong {
    color: #f39c12;
    font-weight: bold;
}

/* 移动端优化 */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .hero-content h1 {
        font-size: 2.5rem;
        animation: titleFloat 0.8s ease-out, titleBounceMobile 4s ease-in-out infinite;
    }
    
    /* 移动端同样超慢速，幅度减为5px */
    @keyframes titleBounceMobile {
        0%, 100% {
            transform: translateY(0);
        }
        50% {
            transform: translateY(-5px);
        }
    }
    
    .hero-content p {
        font-size: 1rem;
    }
    
    .community-links {
        flex-direction: column;
        align-items: center;
    }
    
    .info-grid {
        grid-template-columns: 1fr;
    }
    
    .countdown-timer {
        font-size: 1.4rem;
    }
    
    .announcement-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    .announcement-date {
        align-self: flex-start;
    }
    .announcements h2 {
        font-size: 1.9rem;
    }
    
    .modal-footer {
        flex-direction: column;
    }
    .modal-footer button {
        width: 100%;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeInUp 0.6s ease-out;
}