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

body {
    font-family: 'Arial', sans-serif;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: #fff;
    padding: 20px;
    min-height: 100vh;
}

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

h1 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.game-info {
    display: flex;
    justify-content: space-around;
    background: rgba(0, 0, 0, 0.3);
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
}

.info-item {
    font-size: 1.2rem;
    font-weight: bold;
}

.label {
    color: #aaa;
    margin-right: 10px;
}

.game-area {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

#gameCanvas {
    border: 3px solid #fff;
    border-radius: 10px;
    background: #2a2a2a;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

.controls {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.towers-panel,
.skills-panel,
.wave-control {
    background: rgba(0, 0, 0, 0.3);
    padding: 15px;
    border-radius: 10px;
}

h3 {
    margin-bottom: 10px;
    font-size: 1.2rem;
    text-align: center;
}

.tower-btn,
.skill-btn {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    border: 2px solid #fff;
    border-radius: 5px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s;
}

.tower-btn:hover,
.skill-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
}

.tower-btn:active,
.skill-btn:active {
    transform: scale(0.95);
}

.tower-btn.selected {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    border-color: #ff0;
    box-shadow: 0 0 15px rgba(255, 255, 0, 0.7);
}

.tower-btn:disabled,
.skill-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.tower-name,
.skill-name {
    font-weight: bold;
    margin-bottom: 5px;
}

.tower-cost,
.skill-cooldown {
    font-size: 0.9rem;
    color: #ddd;
}

.start-wave-btn {
    width: 100%;
    padding: 20px;
    border: 3px solid #fff;
    border-radius: 10px;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: #fff;
    font-size: 1.5rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
}

.start-wave-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.7);
}

.start-wave-btn:active {
    transform: scale(0.95);
}

.start-wave-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.messages {
    background: rgba(0, 0, 0, 0.5);
    padding: 15px;
    border-radius: 10px;
    min-height: 60px;
    font-size: 1.1rem;
    text-align: center;
}

.wave-control {
    display: flex;
    align-items: center;
    justify-content: center;
}

@media (max-width: 900px) {
    .controls {
        grid-template-columns: 1fr;
    }

    #gameCanvas {
        width: 100%;
        height: auto;
    }
}
