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

body {
    font-family: 'Arial', sans-serif;
    //background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    /* Prevent scrolling on mobile */
    overflow-x: hidden;
    touch-action: manipulation;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    padding: 20px;
}

/* Fullscreen styles */
:fullscreen {
    background: #000;
}

:-webkit-full-screen {
    background: #000;
}

:-moz-full-screen {
    background: #000;
}

:-ms-fullscreen {
    background: #000;
}

.game-container {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    padding: 20px;
    max-width: 900px;
    width: 100%;
    margin-bottom: 30px;
}

.game-header {
    text-align: center;
    margin-bottom: 20px;
}

.game-header h1 {
    color: #333;
    font-size: 2.5em;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.score-board {
    display: flex;
    justify-content: center;
    gap: 30px;
    font-size: 1.2em;
    color: #555;
}

.score-board span {
    background: linear-gradient(45deg, #f093fb 0%, #f5576c 100%);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: bold;
}

.game-main {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 20px;
}

#gameCanvas {
    border: 3px solid #ddd;
    border-radius: 10px;
    background: linear-gradient(to bottom, #87CEEB 0%, #E0F6FF 50%, #C0E8FF 100%);
    cursor: crosshair;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    /* Prevent default touch behaviors */
    touch-action: none;
    -webkit-tap-highlight-color: transparent;
}

.game-controls {
    margin-top: 15px;
    display: flex;
    gap: 10px;
}

.game-controls button {
    background: linear-gradient(45deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 25px;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    /* Mobile-friendly button size */
    min-height: 44px;
    min-width: 44px;
}

.game-controls button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.game-controls button:active {
    transform: translateY(0);
}

.game-controls button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.game-footer {
    text-align: center;
    color: #666;
    font-size: 0.9em;
}

.game-footer p {
    margin: 5px 0;
}

/* SEO Content Section */
.seo-content {
    max-width: 900px;
    width: 100%;
    margin: 0 auto;
    padding: 20px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.seo-content .content-container {
    max-width: 800px;
    margin: 0 auto;
}

.seo-content article {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.seo-content article:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.seo-content h2 {
    color: #333;
    font-size: 1.8em;
    margin-bottom: 15px;
    text-align: center;
}

.seo-content p {
    color: #555;
    line-height: 1.6;
    margin-bottom: 15px;
    font-size: 1.1em;
}

.seo-content ul {
    color: #555;
    line-height: 1.6;
    margin-left: 20px;
    margin-bottom: 15px;
}

.seo-content li {
    margin-bottom: 8px;
}

.seo-content strong {
    color: #333;
}

/* 响应式设计 */
@media (max-width: 768px) {
    body {
        padding: 0;
        margin: 0;
        overflow: hidden;
    }
    
    .game-container {
        padding: 10px;
        margin: 0;
        border-radius: 0;
        width: 100vw;
        height: 100vh;
        max-width: none;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
    }
    
    .game-header h1 {
        font-size: 1.8em;
        margin-bottom: 5px;
    }
    
    #gameCanvas {
        width: 100%;
        height: auto;
        max-width: none;
        flex: 1;
        border: 2px solid #ddd;
    }
    
    .score-board {
        flex-direction: row;
        gap: 15px;
        font-size: 1em;
        margin-bottom: 10px;
    }
    
    .score-board span {
        padding: 6px 12px;
        font-size: 0.9em;
    }
    
    .game-controls {
        flex-wrap: nowrap;
        justify-content: space-around;
        width: 100%;
        margin-top: 10px;
    }
    
    .game-controls button {
        padding: 10px 20px;
        font-size: 0.9em;
        flex: 1;
        margin: 0 5px;
    }
    
    .game-footer {
        font-size: 0.8em;
        margin-top: 10px;
    }
    
    .game-footer p {
        margin: 3px 0;
    }
}

/* Extra small devices */
@media (max-width: 480px) {
    .game-header h1 {
        font-size: 1.5em;
    }
    
    .score-board {
        font-size: 0.9em;
        gap: 10px;
    }
    
    .game-controls button {
        padding: 8px 16px;
        font-size: 0.8em;
    }
    
    .game-footer {
        font-size: 0.7em;
    }
}

/* Landscape orientation for mobile */
@media (max-height: 500px) and (orientation: landscape) {
    .game-container {
        padding: 5px;
    }
    
    .game-header {
        margin-bottom: 5px;
    }
    
    .game-header h1 {
        font-size: 1.2em;
        margin-bottom: 2px;
    }
    
    .score-board {
        font-size: 0.8em;
        gap: 8px;
    }
    
    .game-controls {
        margin-top: 5px;
    }
    
    .game-controls button {
        padding: 6px 12px;
        font-size: 0.7em;
    }
    
    .game-footer {
        display: none; /* Hide footer in landscape to save space */
    }
}
