* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: linear-gradient(135deg, #1a2a6c, #b21f1f, #fdbb2d);
    color: white;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.game-container {
    background: rgba(0, 0, 0, 0.7);
    border-radius: 20px;
    padding: 20px;
    max-width: 900px;
    width: 100%;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

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

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

.game-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.game-controls {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.btn {
    background: #4a4ae2;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
}

.btn:hover {
    background: #3a3ad2;
    transform: translateY(-2px);
}

.btn:active {
    transform: translateY(1px);
}

.game-board {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
    min-height: 400px;
}

.bottle {
    width: 70px;
    height: 200px;
    display: flex;
    flex-direction: column-reverse;
    border: 3px solid rgba(255, 255, 255, 0.7);
    border-bottom: 15px solid rgba(255, 255, 255, 0.7);
    border-radius: 10px 10px 30px 30px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.bottle::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px 10px 0 0;
}

.bottle.selected {
    border-color: gold;
    box-shadow: 0 0 15px gold;
}

.bottle .liquid-layer {
    height: 40px;
    transition: all 0.5s ease;
}

.tutorial-hint {
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 10px;
    text-align: center;
    margin-top: 20px;
    font-size: 1rem;
}

.help-modal, .level-complete-modal {
    display: none;
    position: fixed;
    z-index: 100;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    animation: fadeIn 0.3s;
}

.modal-content {
    background: linear-gradient(135deg, #1a2a6c, #b21f1f);
    margin: 10% auto;
    padding: 30px;
    border-radius: 15px;
    width: 80%;
    max-width: 500px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
    position: relative;
    animation: slideIn 0.3s;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    top: 10px;
    right: 15px;
}

.close:hover {
    color: white;
}

.modal-content h2 {
    margin-bottom: 15px;
    text-align: center;
}

.modal-content ul {
    text-align: left;
    margin-left: 20px;
    margin-bottom: 20px;
}

.modal-content li {
    margin-bottom: 10px;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { transform: translateY(-50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@media (max-width: 768px) {
    .game-container {
        padding: 15px;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .bottle {
        width: 60px;
        height: 180px;
    }
    
    .game-controls {
        gap: 5px;
    }
    
    .btn {
        padding: 8px 12px;
        font-size: 0.9rem;
    }
}