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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

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

/* Header */
.header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 1rem 0;
}

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

.logo {
    font-size: 1.8rem;
    font-weight: bold;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav {
    display: flex;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: #555;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: #667eea;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: #667eea;
    transition: width 0.3s ease;
}

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

.nav-link.active {
    color: #667eea;
}

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

/* Main Content */
.main {
    margin-top: 80px;
    padding: 2rem 0;
}

.hero {
    text-align: center;
    padding: 4rem 0;
    color: white;
}

.hero-title {
    font-size: 3rem;
    font-weight: bold;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

/* Game Sections */
.game-section {
    padding: 4rem 0;
}

.game-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.game-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.15);
}

.game-image {
    position: relative;
    overflow: hidden;
}

.game-image-container {
    width: 100%;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    overflow: hidden;
    transition: transform 0.3s ease;
    background: linear-gradient(135deg, #667eea, #764ba2);
}

.game-image-container:hover {
    transform: scale(1.05);
}

.game-screenshot {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease, filter 0.3s ease;
}

.game-image-container:hover .game-screenshot {
    transform: scale(1.1);
    filter: brightness(1.1);
}

/* 保持旧样式以防需要 */
.game-placeholder {
    width: 100%;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.game-placeholder:hover {
    transform: scale(1.05);
}

.arena-breakout-bg {
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
}

.cat-runner-bg {
    background: linear-gradient(135deg, #f093fb, #f5576c);
}

.minecraft-web-bg {
    background: linear-gradient(135deg, #4facfe, #00f2fe);
}

.game-icon {
    font-size: 4rem;
    opacity: 0.9;
    transition: transform 0.3s ease;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
    animation: float 3s ease-in-out infinite;
}

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

.game-placeholder:hover .game-icon {
    transform: scale(1.2);
}

.game-content {
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.game-title {
    font-size: 2rem;
    font-weight: bold;
    margin-bottom: 1rem;
    color: #333;
}

.game-description {
    color: #666;
    margin-bottom: 2rem;
    line-height: 1.8;
}

.game-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 2rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #555;
}

.feature-icon {
    font-size: 1.2rem;
}

.game-controls {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 10px;
    margin-bottom: 2rem;
}

.game-controls h4 {
    color: #333;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.control-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.control-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #666;
    font-size: 0.9rem;
}

kbd {
    background: #f1f3f4;
    border: 1px solid #dadce0;
    border-radius: 4px;
    padding: 2px 6px;
    font-family: monospace;
    font-size: 0.8rem;
    color: #3c4043;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.game-items {
    margin-top: 1rem;
}

.items-list, .blocks-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.item-item, .block-item {
    color: #666;
    font-size: 0.9rem;
}

.game-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-self: flex-start;
}

.game-btn, .github-btn {
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.game-btn {
    background: linear-gradient(135deg, #667eea, #764ba2);
}

.github-btn {
    background: linear-gradient(135deg, #333, #555);
    gap: 0.5rem;
}

.github-btn::before {
    content: "🔗";
    font-size: 1rem;
}

.game-btn:hover, .github-btn:hover {
    transform: translateY(-2px);
}

.game-btn:hover {
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.4);
}

.github-btn:hover {
    box-shadow: 0 10px 25px rgba(51, 51, 51, 0.4);
}

.game-btn:active, .github-btn:active {
    transform: translateY(0);
}

/* 游戏按钮焦点状态 */
.game-btn:focus, .github-btn:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.3);
}

.github-btn:focus {
    box-shadow: 0 0 0 3px rgba(51, 51, 51, 0.3);
}

/* Footer */
.footer {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    text-align: center;
    padding: 2rem 0;
    margin-top: 4rem;
    color: #666;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .header .container {
        flex-direction: column;
        gap: 1rem;
    }
    
    .nav {
        gap: 1rem;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .main {
        margin-top: 120px;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .game-card {
        grid-template-columns: 1fr;
    }
    
    .game-content {
        padding: 2rem;
    }
    
    .game-features {
        grid-template-columns: 1fr;
    }
    
    .control-list {
        grid-template-columns: 1fr;
    }
    
    .items-list, .blocks-list {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 2rem 0;
    }
    
    .game-section {
        padding: 2rem 0;
    }
    
    .game-content {
        padding: 1.5rem;
    }
    
    .game-placeholder {
        height: 250px;
    }
    
    .game-icon {
        font-size: 3rem;
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Animation for game cards */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.game-section {
    animation: fadeInUp 0.6s ease-out;
}