/* Reset and base styles */
* {
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}

body {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* Header section */
.header {
    text-align: center;
    margin-bottom: 20px;
    color: white;
}

.header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    background: linear-gradient(45deg, #00d4ff, #0099cc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(0, 212, 255, 0.3);
}

.header p {
    font-size: 1.1rem;
    opacity: 0.8;
    margin-bottom: 20px;
}

/* Controls section */
.controls {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    justify-content: center;
}

.btn {
    background: linear-gradient(45deg, #ff4444, #ff6666);
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 16px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(255, 68, 68, 0.3);
    position: relative;
    overflow: hidden;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 68, 68, 0.4);
    background: linear-gradient(45deg, #ff6666, #ff8888);
}

.btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(255, 68, 68, 0.3);
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

/* Simulation container */
.simulation-container {
    display: flex;
    gap: 30px;
    align-items: flex-start;
    margin-bottom: 20px;
}

/* Canvas container */
.canvas-container {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.1);
}

canvas {
    display: block;
    border-radius: 10px;
    background: #242321;
}

/* Controls panel */
.controls-panel {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 25px;
    min-width: 280px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.controls-panel h3 {
    color: #00d4ff;
    margin-bottom: 20px;
    font-size: 1.3rem;
    text-align: center;
}

/* Slider groups */
.slider-group {
    margin-bottom: 20px;
}

.slider-group label {
    display: block;
    color: white;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 0.9rem;
}

.slider-group input[type="range"] {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.2);
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    margin-bottom: 5px;
}

.slider-group input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: linear-gradient(45deg, #00d4ff, #0099cc);
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 212, 255, 0.3);
    transition: all 0.2s ease;
}

.slider-group input[type="range"]::-webkit-slider-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 212, 255, 0.4);
}

.slider-group input[type="range"]::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: linear-gradient(45deg, #00d4ff, #0099cc);
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 8px rgba(0, 212, 255, 0.3);
}

.value-display {
    color: #00d4ff;
    font-weight: 600;
    font-size: 0.9rem;
    float: right;
    background: rgba(0, 212, 255, 0.1);
    padding: 2px 8px;
    border-radius: 4px;
    border: 1px solid rgba(0, 212, 255, 0.3);
}

/* Checkbox styling */
.checkbox-group {
    margin-bottom: 20px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    color: white;
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    position: relative;
    padding-left: 35px;
}

.checkbox-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: absolute;
    left: 0;
    top: 0;
    height: 20px;
    width: 20px;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    transition: all 0.3s ease;
}

.checkbox-label:hover .checkmark {
    background: rgba(0, 212, 255, 0.1);
    border-color: rgba(0, 212, 255, 0.5);
}

.checkbox-label input:checked ~ .checkmark {
    background: linear-gradient(45deg, #00d4ff, #0099cc);
    border-color: #00d4ff;
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
    left: 6px;
    top: 2px;
    width: 6px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.checkbox-label input:checked ~ .checkmark:after {
    display: block;
}

/* Action buttons */
.action-buttons {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 25px;
    margin-top: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    width: 100%;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.action-buttons h3 {
    color: #00d4ff;
    margin-bottom: 20px;
    font-size: 1.3rem;
    text-align: center;
}

.button-group {
    display: flex;
    flex-direction: row;
    gap: 20px;
    justify-content: center;
    align-items: center;
}

.action-btn {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
    padding: 15px 30px;
    font-size: 18px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    position: relative;
    overflow: hidden;
    min-width: 200px;
}

.action-btn:hover {
    background: rgba(0, 212, 255, 0.1);
    border-color: rgba(0, 212, 255, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 212, 255, 0.3);
}

.action-btn.active {
    background: linear-gradient(45deg, #00d4ff, #0099cc);
    border-color: #00d4ff;
    box-shadow: 0 4px 15px rgba(0, 212, 255, 0.4);
}

.action-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.action-btn:hover::before {
    left: 100%;
}

/* Instructions panel */
.instructions {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 20px;
    margin-top: 20px;
    color: white;
    max-width: 600px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.instructions h3 {
    margin-bottom: 15px;
    color: #00d4ff;
    font-size: 1.3rem;
}

.instructions ul {
    list-style: none;
    text-align: left;
    display: inline-block;
}

.instructions li {
    margin-bottom: 8px;
    padding-left: 20px;
    position: relative;
}

.instructions li::before {
    content: '•';
    color: #00d4ff;
    font-weight: bold;
    position: absolute;
    left: 0;
}

/* Responsive design */
@media (max-width: 768px) {
    .header h1 {
        font-size: 2rem;
    }
    
    .controls {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        width: 200px;
    }
    
    .simulation-container {
        flex-direction: column;
        align-items: center;
    }
    
    .controls-panel {
        min-width: 100%;
        max-width: 400px;
    }
    
    .action-buttons {
        max-width: 100%;
        padding: 20px;
    }
    
    .button-group {
        flex-direction: column;
        gap: 12px;
    }
    
    .action-btn {
        min-width: 100%;
        padding: 12px 20px;
        font-size: 16px;
    }
    
    canvas {
        width: 100%;
        height: auto;
    }
}

/* Animation for particles */
@keyframes particle-glow {
    0% { opacity: 0.8; }
    50% { opacity: 1; }
    100% { opacity: 0.8; }
}

/* Loading animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #00d4ff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
} 