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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    min-height: 100vh;
    color: #fff;
}

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

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

.game-header h1 {
    font-size: 2.5rem;
    margin-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.score-board {
    display: flex;
    justify-content: center;
    gap: 30px;
    background: rgba(255,255,255,0.15);
    padding: 15px 30px;
    border-radius: 15px;
    backdrop-filter: blur(10px);
}

.score-board > div {
    text-align: center;
}

.score-board .label {
    display: block;
    font-size: 0.9rem;
    opacity: 0.8;
    margin-bottom: 5px;
}

.score-board .score {
    display: block;
    font-size: 2rem;
    font-weight: bold;
    color: #ffd700;
}

.game-field {
    margin-bottom: 20px;
}

.cricket-ground {
    position: relative;
    width: 100%;
    height: 400px;
    background: linear-gradient(180deg, #4a7c59 0%, #3d6b4a 100%);
    border-radius: 50% / 20%;
    border: 4px solid #2d5a3d;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.pitch {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60%;
    height: 80%;
    background: linear-gradient(90deg, #d4a574 0%, #c49a6c 50%, #d4a574 100%);
    border-radius: 5px;
    border: 2px solid #8b7355;
}

.crease {
    position: absolute;
    width: 80px;
    height: 40px;
    background: #fff;
    border: 2px solid #8b7355;
    border-radius: 3px;
}

.batsman-crease {
    bottom: 10%;
    left: 50%;
    transform: translateX(-50%);
}

.bowler-crease {
    top: 10%;
    left: 50%;
    transform: translateX(-50%);
}

.batsman, .bowler {
    position: absolute;
    font-size: 2.5rem;
    transform: translate(-50%, -50%);
}

.batsman {
    top: 50%;
    left: 50%;
}

.bowler {
    top: 50%;
    left: 50%;
}

.ball {
    position: absolute;
    font-size: 1.2rem;
    opacity: 0;
    z-index: 10;
}

.fielders {
    position: absolute;
    width: 100%;
    height: 100%;
}

.fielder {
    position: absolute;
    font-size: 1.8rem;
    transform: translate(-50%, -50%);
    filter: drop-shadow(2px 2px 2px rgba(0,0,0,0.3));
}

.game-status {
    text-align: center;
    margin-top: 15px;
    padding: 10px;
    background: rgba(255,255,255,0.1);
    border-radius: 10px;
}

.game-status p {
    font-size: 1.2rem;
    font-weight: 500;
}

.controls {
    background: rgba(255,255,255,0.1);
    padding: 20px;
    border-radius: 15px;
    margin-bottom: 20px;
}

.shot-buttons h3 {
    margin-bottom: 15px;
    text-align: center;
}

.button-row {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.shot-btn {
    padding: 12px 20px;
    font-size: 1rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    background: linear-gradient(145deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 600;
    transition: all 0.3s ease;
    min-width: 100px;
}

.shot-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

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

.shot-btn.active {
    background: linear-gradient(145deg, #f093fb 0%, #f5576c 100%);
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.action-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
}

.primary-btn, .secondary-btn {
    padding: 15px 30px;
    font-size: 1.1rem;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.primary-btn {
    background: linear-gradient(145deg, #11998e 0%, #38ef7d 100%);
    color: white;
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(17, 153, 142, 0.4);
}

.secondary-btn {
    background: linear-gradient(145deg, #ff6b6b 0%, #ee5a5a 100%);
    color: white;
}

.secondary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(255, 107, 107, 0.4);
}

.commentary {
    background: rgba(0,0,0,0.3);
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    text-align: center;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.commentary p {
    font-size: 1.1rem;
    font-style: italic;
}

.stats {
    background: rgba(255,255,255,0.1);
    padding: 15px;
    border-radius: 10px;
    text-align: center;
}

.stats h3 {
    margin-bottom: 10px;
}

.over-stats {
    font-size: 1.2rem;
    color: #ffd700;
    font-weight: bold;
}

/* Animations */
@keyframes bowl {
    0% { top: 10%; left: 50%; opacity: 1; }
    100% { top: 85%; left: 50%; opacity: 1; }
}

@keyframes hit {
    0% { top: 85%; left: 50%; opacity: 1; }
    25% { top: 60%; left: 50%; }
    100% { opacity: 0; }
}

@keyframes wicket {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(90deg); }
}

.bowling .ball {
    animation: bowl 0.8s ease-in forwards;
}

.hit .ball {
    animation: hit 1s ease-out forwards;
}

.wicket .batsman {
    animation: wicket 0.5s ease-out forwards;
}

/* Responsive */
@media (max-width: 600px) {
    .game-header h1 {
        font-size: 1.8rem;
    }
    
    .score-board {
        gap: 15px;
        padding: 10px 15px;
    }
    
    .score-board .score {
        font-size: 1.5rem;
    }
    
    .cricket-ground {
        height: 300px;
    }
    
    .shot-btn {
        padding: 10px 15px;
        font-size: 0.9rem;
        min-width: 80px;
    }
}