* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #0a1628 0%, #1a2942 100%);
    color: #e0e0e0;
    min-height: 100vh;
    padding: 10px;
    overflow-x: hidden;
}

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

header {
    text-align: center;
    margin-bottom: 20px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    backdrop-filter: blur(10px);
}

header h1 {
    font-size: 24px;
    font-weight: 600;
    color: #5bbad5;
    margin-bottom: 8px;
}

.status {
    font-size: 16px;
    color: #ffcc00;
    font-weight: 500;
}

.court-container {
    position: relative;
    background: #082031;
    border-radius: 12px;
    padding: 10px;
    margin-bottom: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

#court {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
}

.target-info {
    text-align: center;
    padding: 12px;
    font-size: 16px;
    font-weight: 600;
    color: #ffd27f;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    margin-top: 10px;
}

.controls-section {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 20px;
    backdrop-filter: blur(10px);
}

.control-group {
    margin-bottom: 18px;
}

.control-group:last-child {
    margin-bottom: 0;
}

.control-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 500;
    color: #aaccdd;
}

.control-group input[type="range"] {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.1);
    outline: none;
    -webkit-appearance: none;
}

.control-group input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #5bbad5;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(91, 186, 213, 0.4);
}

.control-group input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #5bbad5;
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 8px rgba(91, 186, 213, 0.4);
}

.control-group select {
    width: 100%;
    padding: 12px;
    font-size: 16px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.05);
    color: #e0e0e0;
    outline: none;
}

.toggle-section {
    width: 100%;
    padding: 12px;
    background: rgba(91, 186, 213, 0.15);
    border: 1px solid rgba(91, 186, 213, 0.3);
    border-radius: 8px;
    color: #5bbad5;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-align: left;
    margin-bottom: 8px;
}

.volume-controls {
    padding: 10px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
}

.volume-controls.hidden {
    display: none;
}

.control-group-small {
    margin-bottom: 12px;
}

.control-group-small:last-child {
    margin-bottom: 0;
}

.control-group-small label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    color: #94b6ce;
}

.control-group-small input[type="range"] {
    width: 100%;
}

.button-group {
    display: flex;
    gap: 12px;
    margin-bottom: 15px;
}

.btn {
    flex: 1;
    padding: 16px 24px;
    font-size: 18px;
    font-weight: 600;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

.btn:active {
    transform: scale(0.98);
}

.btn-primary {
    background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #45a049 0%, #3d8b40 100%);
}

.btn-secondary {
    background: linear-gradient(135deg, #f44336 0%, #da190b 100%);
    color: white;
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #da190b 0%, #c2180a 100%);
}

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

.instructions {
    text-align: center;
    padding: 15px;
    background: rgba(255, 204, 0, 0.1);
    border: 1px solid rgba(255, 204, 0, 0.3);
    border-radius: 8px;
    font-size: 13px;
    color: #ffee99;
    line-height: 1.5;
}

.instructions strong {
    color: #ffcc00;
}

/* Prevent zoom on double-tap for iOS */
button, input, select {
    touch-action: manipulation;
}

@media (max-width: 400px) {
    header h1 {
        font-size: 20px;
    }

    .btn {
        padding: 14px 20px;
        font-size: 16px;
    }
}

