/* 키즈 영단어 퀴즈 커스텀 스타일 */

* {
    font-family: 'Noto Sans KR', sans-serif;
}

body {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    animation: gradientShift 10s ease infinite;
}

@keyframes gradientShift {
    0%, 100% {
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    }
    25% {
        background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    }
    50% {
        background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    }
    75% {
        background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    }
}

/* 게임 모드 카드 호버 효과 */
.game-mode-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 3px solid transparent;
}

.game-mode-card:hover {
    border-color: rgba(255, 255, 255, 0.8);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* 퀴즈 선택지 스타일 */
.choice-button {
    background: linear-gradient(145deg, #ffffff, #f0f0f0);
    border: 3px solid #e5e7eb;
    border-radius: 1rem;
    padding: 1.5rem;
    font-size: 1.125rem;
    font-weight: 600;
    color: #374151;
    cursor: pointer;
    transition: all 0.3s ease;
    transform: translateY(0);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.choice-button:hover {
    background: linear-gradient(145deg, #f8fafc, #e2e8f0);
    border-color: #60a5fa;
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.choice-button.selected {
    background: linear-gradient(145deg, #dbeafe, #bfdbfe);
    border-color: #3b82f6;
    color: #1e40af;
}

.choice-button.correct {
    background: linear-gradient(145deg, #dcfce7, #bbf7d0);
    border-color: #10b981;
    color: #065f46;
    animation: correctPulse 0.6s ease-in-out;
}

.choice-button.incorrect {
    background: linear-gradient(145deg, #fee2e2, #fecaca);
    border-color: #ef4444;
    color: #991b1b;
    animation: incorrectShake 0.6s ease-in-out;
}

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

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

/* 결과 메시지 스타일 */
.result-correct {
    background: linear-gradient(145deg, #ecfdf5, #d1fae5);
    border: 2px solid #10b981;
    color: #065f46;
}

.result-incorrect {
    background: linear-gradient(145deg, #fef2f2, #fee2e2);
    border: 2px solid #ef4444;
    color: #991b1b;
}

/* 성취 뱃지 스타일 */
.achievement-badge {
    display: inline-block;
    padding: 1rem 2rem;
    border-radius: 2rem;
    font-weight: bold;
    font-size: 1.25rem;
    text-align: center;
    animation: badgeBounce 1s ease-in-out;
}

.badge-perfect {
    background: linear-gradient(145deg, #fef3c7, #fde68a);
    border: 3px solid #f59e0b;
    color: #92400e;
}

.badge-great {
    background: linear-gradient(145deg, #dbeafe, #bfdbfe);
    border: 3px solid #3b82f6;
    color: #1e40af;
}

.badge-good {
    background: linear-gradient(145deg, #dcfce7, #bbf7d0);
    border: 3px solid #10b981;
    color: #065f46;
}

.badge-try-again {
    background: linear-gradient(145deg, #fee2e2, #fecaca);
    border: 3px solid #ef4444;
    color: #991b1b;
}

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

/* 진행바 애니메이션 */
.progress-bar-animated {
    background: linear-gradient(90deg, #10b981, #3b82f6, #8b5cf6);
    background-size: 300% 300%;
    animation: progressGradient 2s ease infinite;
}

@keyframes progressGradient {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* 반응형 디자인 */
@media (max-width: 768px) {
    .choice-button {
        padding: 1rem;
        font-size: 1rem;
    }
    
    h1 {
        font-size: 2.5rem !important;
    }
    
    .game-mode-card {
        padding: 1rem;
    }
    
    .game-mode-card h3 {
        font-size: 1rem;
    }
    
    .game-mode-card p {
        font-size: 0.875rem;
    }
}

/* 로딩 애니메이션 */
.loading-spinner {
    border: 4px solid #f3f4f6;
    border-top: 4px solid #3b82f6;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

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

/* 카드 그림자 효과 */
.card-shadow {
    box-shadow: 
        0 10px 15px -3px rgba(0, 0, 0, 0.1),
        0 4px 6px -2px rgba(0, 0, 0, 0.05),
        0 0 0 1px rgba(255, 255, 255, 0.05);
}

/* 버튼 호버 효과 개선 */
button {
    transition: all 0.3s ease;
}

button:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

button:active {
    transform: translateY(0);
}

/* 점수 카운터 애니메이션 */
.score-animation {
    animation: scoreCount 0.5s ease-out;
}

@keyframes scoreCount {
    0% { 
        transform: scale(1);
        color: inherit;
    }
    50% { 
        transform: scale(1.2);
        color: #10b981;
    }
    100% { 
        transform: scale(1);
        color: inherit;
    }
}

/* 문제 카드 등장 애니메이션 */
.question-enter {
    animation: questionSlideIn 0.5s ease-out;
}

@keyframes questionSlideIn {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 축하 이모지 애니메이션 */
.celebration-bounce {
    animation: celebrationBounce 2s ease-in-out infinite;
}

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

/* 통계 카드 스타일 */
.stats-card {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

/* 커스텀 스크롤바 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}