/* Alphabet Teacher Plugin Styles */

.alphabet-teacher-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    min-height: 600px;
    position: relative;
    overflow: hidden;
}

.alphabet-teacher-container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: float 6s ease-in-out infinite;
    pointer-events: none;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(180deg); }
}

.game-header {
    text-align: center;
    margin-bottom: 30px;
    color: white;
}

.game-title {
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

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

.control-btn {
    background: linear-gradient(45deg, #3B82F6, #1D4ED8);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
    position: relative;
    overflow: hidden;
}

.control-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.4);
}

.control-btn:active {
    transform: translateY(0);
}

.control-btn.active {
    background: linear-gradient(45deg, #10B981, #059669);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

.progress-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.95);
    padding: 20px;
    border-radius: 15px;
    margin-bottom: 30px;
    backdrop-filter: blur(10px);
}

.progress-bar {
    width: 200px;
    height: 8px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #10B981, #34D399);
    border-radius: 4px;
    transition: width 0.5s ease;
}

.score-display {
    font-size: 1.2rem;
    font-weight: bold;
    color: #1F2937;
}

.game-area {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 30px;
    min-height: 400px;
    backdrop-filter: blur(10px);
    position: relative;
}

.letter-display {
    text-align: center;
    margin-bottom: 30px;
}

.current-letter {
    font-size: 8rem;
    font-weight: bold;
    color: #1F2937;
    margin-bottom: 10px;
    transition: all 0.3s ease;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.current-letter.geez {
    font-family: 'Noto Sans Ethiopic', serif;
    font-size: 6rem;
}

.letter-name {
    font-size: 1.5rem;
    color: #6B7280;
    font-weight: 500;
}

.options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
    max-width: 600px;
    margin: 0 auto;
}

.option-btn {
    background: linear-gradient(45deg, #F3F4F6, #E5E7EB);
    border: 3px solid #D1D5DB;
    border-radius: 15px;
    padding: 20px;
    font-size: 2rem;
    font-weight: bold;
    color: #374151;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.option-btn:hover {
    background: linear-gradient(45deg, #DBEAFE, #BFDBFE);
    border-color: #3B82F6;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.2);
}

.option-btn.correct {
    background: linear-gradient(45deg, #D1FAE5, #A7F3D0);
    border-color: #10B981;
    animation: correctAnswer 0.6s ease;
}

.option-btn.incorrect {
    background: linear-gradient(45deg, #FEE2E2, #FECACA);
    border-color: #EF4444;
    animation: incorrectAnswer 0.6s ease;
}

@keyframes correctAnswer {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

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

.feedback-message {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(16, 185, 129, 0.95);
    color: white;
    padding: 20px 40px;
    border-radius: 25px;
    font-size: 1.5rem;
    font-weight: bold;
    z-index: 100;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.feedback-message.show {
    opacity: 1;
}

.feedback-message.incorrect {
    background: rgba(239, 68, 68, 0.95);
}

.next-btn {
    background: linear-gradient(45deg, #F97316, #EA580C);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 25px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 20px auto;
    display: block;
    box-shadow: 0 4px 15px rgba(249, 115, 22, 0.3);
}

.next-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(249, 115, 22, 0.4);
}

.achievement-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(45deg, #8B5CF6, #7C3AED);
    color: white;
    padding: 30px;
    border-radius: 20px;
    text-align: center;
    z-index: 1000;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.5);
    transition: all 0.5s ease;
}

.achievement-popup.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.achievement-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.stats-display {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.9);
    padding: 15px;
    border-radius: 10px;
    text-align: center;
    backdrop-filter: blur(5px);
}

.stat-value {
    font-size: 2rem;
    font-weight: bold;
    color: #3B82F6;
    display: block;
}

.stat-label {
    font-size: 0.9rem;
    color: #6B7280;
    margin-top: 5px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .alphabet-teacher-container {
        padding: 15px;
        margin: 10px;
        border-radius: 15px;
    }
    
    .game-title {
        font-size: 2rem;
    }
    
    .current-letter {
        font-size: 5rem;
    }
    
    .current-letter.geez {
        font-size: 4rem;
    }
    
    .options-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .option-btn {
        padding: 15px;
        font-size: 1.5rem;
    }
    
    .game-controls {
        flex-direction: column;
        align-items: center;
    }
    
    .control-btn {
        width: 200px;
        margin: 5px 0;
    }
}

@media (max-width: 480px) {
    .current-letter {
        font-size: 4rem;
    }
    
    .current-letter.geez {
        font-size: 3rem;
    }
    
    .options-grid {
        grid-template-columns: 1fr;
    }
    
    .progress-section {
        flex-direction: column;
        gap: 15px;
    }
    
    .stats-display {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Loading Animation */
.loading {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3B82F6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Celebration Animation */
.celebration {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 50;
}

.confetti {
    position: absolute;
    width: 10px;
    height: 10px;
    background: #F97316;
    animation: confetti-fall 3s linear infinite;
}

.confetti:nth-child(2n) { background: #3B82F6; animation-delay: 0.5s; }
.confetti:nth-child(3n) { background: #10B981; animation-delay: 1s; }
.confetti:nth-child(4n) { background: #8B5CF6; animation-delay: 1.5s; }

@keyframes confetti-fall {
    0% {
        transform: translateY(-100vh) rotate(0deg);
        opacity: 1;
    }
    100% {
        transform: translateY(100vh) rotate(720deg);
        opacity: 0;
    }
}

/* Accessibility */
.option-btn:focus,
.control-btn:focus,
.next-btn:focus {
    outline: 3px solid #FBBF24;
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    .alphabet-teacher-container {
        background: white;
        box-shadow: none;
    }
    
    .control-btn,
    .next-btn {
        display: none;
    }
}