/* ============================================
   Simon Game Styles
   ============================================ */

.simon-game {
    width: 100%;
    max-width: 550px;
    margin: 0 auto;
}

.simon-header {
    text-align: center;
    margin-bottom: var(--spacing-lg);
}

.simon-header h2 {
    font-size: 1.75rem;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: var(--spacing-xs);
}

.simon-instruction {
    font-size: 1rem;
    color: var(--color-text-dark);
    opacity: 0.8;
    margin: 0 0 var(--spacing-sm) 0;
}

.simon-progress {
    margin-top: var(--spacing-sm);
}

.round-counter {
    font-size: 0.875rem;
    color: var(--color-text-dark);
}

.round-counter strong {
    color: var(--color-secondary);
    font-weight: 700;
    font-size: 1.125rem;
}

/* Simon Board */
.simon-board {
    position: relative;
    width: 100%;
    max-width: 400px;
    margin: 0 auto var(--spacing-lg);
    aspect-ratio: 1;
    transition: opacity 600ms ease;
}

/* Simon Grid (2x2) */
.simon-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 12px;
    width: 100%;
    height: 100%;
    padding: var(--spacing-md);
    background: linear-gradient(135deg, #FFFFFF, #F0F8F9);
    border-radius: 50%;
    box-shadow: 0 8px 24px var(--color-shadow-teal);
    border: 4px solid rgba(77, 184, 196, 0.3);
}

/* Simon Buttons */
.simon-button {
    border: none;
    cursor: pointer;
    border-radius: 12px;
    transition: all 150ms ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.simon-button:hover {
    transform: scale(1.05);
}

.simon-button:active {
    transform: scale(0.95);
}

/* Individual colors */
.simon-red {
    background: linear-gradient(135deg, #FF6B6B, #EE5A6F);
}

.simon-blue {
    background: linear-gradient(135deg, #4ECDC4, #44A08D);
}

.simon-green {
    background: linear-gradient(135deg, #95E1D3, #38D39F);
}

.simon-yellow {
    background: linear-gradient(135deg, #FFE66D, #FFC93C);
}

/* Active state (lighting up) */
.simon-button.active {
    transform: scale(1.1);
    box-shadow: 0 0 30px currentColor, 0 0 50px currentColor;
    filter: brightness(1.5);
}

.simon-red.active {
    box-shadow: 0 0 30px #FF6B6B, 0 0 50px #FF6B6B;
}

.simon-blue.active {
    box-shadow: 0 0 30px #4ECDC4, 0 0 50px #4ECDC4;
}

.simon-green.active {
    box-shadow: 0 0 30px #95E1D3, 0 0 50px #95E1D3;
}

.simon-yellow.active {
    box-shadow: 0 0 30px #FFE66D, 0 0 50px #FFE66D;
}

/* Error state */
.simon-button.error {
    animation: errorShake 400ms;
    filter: grayscale(1) brightness(0.5);
}

@keyframes errorShake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

/* Center Circle */
.simon-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120px;
    height: 120px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    z-index: 10;
}

/* Start Button */
.simon-start-btn {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    color: white;
    font-weight: 700;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 200ms ease;
    box-shadow: 0 4px 12px rgba(77, 184, 196, 0.4);
}

.simon-start-btn:hover:not(:disabled) {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(77, 184, 196, 0.6);
}

.simon-start-btn:active:not(:disabled) {
    transform: scale(0.95);
}

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

/* Status Message */
.simon-status {
    text-align: center;
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-secondary);
    min-height: 30px;
    margin-bottom: var(--spacing-md);
}

/* Success Message */
.simon-success {
    text-align: center;
    padding: var(--spacing-lg);
    background: rgba(26, 188, 156, 0.1);
    border-radius: 16px;
    opacity: 1;
    transform: scale(1);
    transition: all 600ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.simon-success.hidden {
    opacity: 0;
    transform: scale(0.8);
    display: none;
}

.simon-success h3 {
    font-size: 1.5rem;
    color: var(--color-secondary);
    margin-bottom: var(--spacing-md);
}

.success-message {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--color-text-dark);
}

/* Responsive */
@media (max-width: 768px) {
    .simon-board {
        max-width: 320px;
    }
    
    .simon-grid {
        gap: 8px;
        padding: var(--spacing-sm);
    }
    
    .simon-center {
        width: 100px;
        height: 100px;
    }
    
    .simon-start-btn {
        width: 75px;
        height: 75px;
        font-size: 0.75rem;
    }
}
