/**
 * Little Scribleer - Custom Styles
 * Playful, colorful, kid-friendly design for kindergarten learners
 */

/* =====================================================
   1. CSS VARIABLES & COLORS
   ===================================================== */
:root {
    /* Primary Palette - Playful & Vibrant */
    --color-primary: #FF6B9D;
    --color-secondary: #FFA07A;
    --color-success: #90EE90;
    --color-warning: #FFD700;
    --color-danger: #FF6B6B;
    --color-info: #87CEEB;
    
    /* Gradient Backgrounds */
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-alphabet: linear-gradient(135deg, #FF6B9D 0%, #FF8E53 100%);
    --gradient-numbers: linear-gradient(135deg, #4FACFE 0%, #00F2FE 100%);
    --gradient-colors: linear-gradient(135deg, #FA709A 0%, #FEE140 100%);
    --gradient-shapes: linear-gradient(135deg, #A8EDEA 0%, #FED6E3 100%);
    
    /* Neutrals */
    --color-light: #FFF9F0;
    --color-dark: #2D3748;
    --color-muted: #718096;
    
    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2.5rem;
    --spacing-xl: 4rem;
    
    /* Typography */
    --font-primary: 'Fredoka', sans-serif;
    --font-secondary: 'Nunito', sans-serif;
    
    /* Border Radius */
    --radius-sm: 0.5rem;
    --radius-md: 1rem;
    --radius-lg: 1.5rem;
    --radius-xl: 2rem;
    --radius-full: 9999px;
    
    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.2);
    
    /* Animation Duration */
    --duration-fast: 200ms;
    --duration-normal: 300ms;
    --duration-slow: 500ms;
}

/* =====================================================
   2. GLOBAL STYLES
   ===================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-secondary);
    background: linear-gradient(180deg, #FFF9F0 0%, #FFE5E5 100%);
    color: var(--color-dark);
    min-height: 100vh;
    overflow-x: hidden;
}

#app-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.main-content {
    flex: 1;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-primary);
    font-weight: 700;
    line-height: 1.2;
}

/* =====================================================
   3. NAVIGATION - MODERN & CLEAN
   ===================================================== */
.navbar-custom {
    background: white;
    border-bottom: 3px solid var(--color-primary);
}

.logo-circle {
    width: 50px;
    height: 50px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: var(--shadow-md);
}

.app-title-text {
    font-family: var(--font-primary);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-dark);
    letter-spacing: -0.5px;
}

.btn-toggle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 2px solid #e2e8f0;
    background: white;
    color: var(--color-dark);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    transition: all var(--duration-normal);
}

.btn-toggle:hover {
    transform: scale(1.1);
    background: var(--color-primary);
    color: white;
    border-color: var(--color-primary);
}

.btn-toggle.muted {
    background: #e2e8f0;
    color: #718096;
}

/* =====================================================
   4. HERO SECTION - ENGAGING & FUN
   ===================================================== */
.hero-section {
    padding: 3rem 0 2rem;
}

.hero-content {
    max-width: 700px;
    margin: 0 auto;
}

.mascot-emoji {
    font-size: 5rem;
    line-height: 1;
}

.hero-title {
    font-family: var(--font-primary);
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--color-dark);
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--color-muted);
}

/* =====================================================
   5. CATEGORY CARDS - MODERN & PLAYFUL
   ===================================================== */
.categories-section {
    padding-bottom: 3rem;
}

.category-link {
    text-decoration: none;
    display: block;
    transition: transform var(--duration-normal);
}

.category-link:hover {
    transform: translateY(-8px);
}

.category-card {
    background: white;
    border-radius: var(--radius-xl);
    padding: 2rem 1.5rem;
    text-align: center;
    box-shadow: var(--shadow-md);
    transition: all var(--duration-normal);
    min-height: 280px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.category-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 6px;
    background: var(--gradient-primary);
}

.category-card.card-alphabet::before {
    background: var(--gradient-alphabet);
}

.category-card.card-numbers::before {
    background: var(--gradient-numbers);
}

.category-card.card-colors::before {
    background: var(--gradient-colors);
}

.category-card.card-shapes::before {
    background: var(--gradient-shapes);
}

.category-icon-wrapper {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    position: relative;
}

.card-alphabet .category-icon-wrapper {
    background: linear-gradient(135deg, rgba(255,107,157,0.15) 0%, rgba(255,142,83,0.15) 100%);
}

.card-numbers .category-icon-wrapper {
    background: linear-gradient(135deg, rgba(79,172,254,0.15) 0%, rgba(0,242,254,0.15) 100%);
}

.card-colors .category-icon-wrapper {
    background: linear-gradient(135deg, rgba(250,112,154,0.15) 0%, rgba(254,209,64,0.15) 100%);
}

.card-shapes .category-icon-wrapper {
    background: linear-gradient(135deg, rgba(168,237,234,0.15) 0%, rgba(254,214,227,0.15) 100%);
}

.category-icon {
    font-size: 3rem;
    font-weight: 700;
    font-family: var(--font-primary);
}

.card-alphabet .category-icon {
    background: var(--gradient-alphabet);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.card-numbers .category-icon {
    background: var(--gradient-numbers);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.card-colors .category-icon {
    background: var(--gradient-colors);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.card-shapes .category-icon {
    background: var(--gradient-shapes);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.category-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-dark);
    margin-bottom: 0.5rem;
}

.category-desc {
    font-size: 1rem;
    color: var(--color-muted);
    margin: 0;
}

.category-card:hover {
    box-shadow: var(--shadow-lg);
}

/* =====================================================
   6. GAME PAGE LAYOUTS
   ===================================================== */
.game-container {
    max-width: 1200px;
    margin: 0 auto;
}

.game-header {
    background: white;
    border-radius: var(--radius-xl);
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-sm);
}

.difficulty-selector {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

.difficulty-btn {
    min-width: 180px;
    font-size: 1.5rem;
    padding: 1.5rem 3rem;
    border: 5px solid transparent;
    font-family: var(--font-primary);
    font-weight: 800;
    border-radius: var(--radius-full);
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
    position: relative;
    overflow: hidden;
}

.difficulty-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255,255,255,0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.difficulty-btn:hover::before {
    width: 300px;
    height: 300px;
}

.difficulty-btn:hover {
    transform: translateY(-8px) scale(1.1);
    box-shadow: 0 12px 30px rgba(0,0,0,0.25);
}

.difficulty-btn:active {
    transform: translateY(-4px) scale(1.05);
}

.difficulty-btn.active {
    border-width: 6px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.3), 0 0 0 4px rgba(255,255,255,0.5);
    animation: pulse-active 1s ease-in-out infinite;
}

@keyframes pulse-active {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.btn-easy {
    background: linear-gradient(135deg, #90EE90 0%, #98FB98 100%);
    color: white;
    border-color: #32CD32;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.btn-easy::after {
    content: '⭐';
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.5rem;
}

.btn-medium {
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: white;
    border-color: #FF8C00;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.btn-medium::after {
    content: '⭐⭐';
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.2rem;
}

.btn-hard {
    background: linear-gradient(135deg, #FF6B9D 0%, #FF8787 100%);
    color: white;
    border-color: #FF4444;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.2);
}

.btn-hard::after {
    content: '🔥';
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.5rem;
    animation: fire-flicker 1s ease-in-out infinite;
}

@keyframes fire-flicker {
    0%, 100% { transform: translateY(-50%) scale(1); }
    50% { transform: translateY(-50%) scale(1.2); }
}

/* Level Selector - Fun Circles! */
.level-selector {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.level-btn {
    width: 70px;
    height: 70px;
    font-size: 1.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #fff 0%, #f0f9ff 100%);
    color: var(--color-dark);
    border: 4px solid #87CEEB;
    border-radius: 50%;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    position: relative;
    overflow: visible;
    font-family: var(--font-primary);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.level-btn::before {
    content: '';
    position: absolute;
    inset: -8px;
    border-radius: 50%;
    background: linear-gradient(45deg, transparent, transparent);
    opacity: 0;
    transition: opacity 0.3s;
    z-index: -1;
}

.level-btn:hover {
    transform: scale(1.25) rotate(10deg);
    border-color: #FFD700;
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    color: white;
}

.level-btn:hover::before {
    opacity: 1;
    background: linear-gradient(45deg, #FF6B9D, #FFA07A, #FFD700);
    animation: spin-border 2s linear infinite;
}

@keyframes spin-border {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.level-btn.completed {
    background: linear-gradient(135deg, #90EE90 0%, #98FB98 100%);
    color: white;
    border-color: #32CD32;
    animation: bounce-level 2s ease-in-out infinite;
}

.level-btn.completed::after {
    content: '⭐';
    position: absolute;
    top: -8px;
    right: -8px;
    font-size: 1.2rem;
    animation: twinkle 1.5s ease-in-out infinite;
}

@keyframes bounce-level {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

@keyframes twinkle {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.3); }
}

/* Game Stats - Fun & Colorful! */
.game-stats {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 2rem;
}

.stat-item {
    text-align: center;
    padding: 1.5rem 2.5rem;
    background: linear-gradient(135deg, #fff 0%, #fef3c7 100%);
    border-radius: var(--radius-xl);
    min-width: 140px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    border: 3px solid #FFD700;
    transition: all 0.3s ease;
    animation: float 3s ease-in-out infinite;
}

.stat-item:nth-child(1) {
    animation-delay: 0s;
    border-color: #FF6B9D;
    background: linear-gradient(135deg, #fff 0%, #ffe5e5 100%);
}

.stat-item:nth-child(2) {
    animation-delay: 0.2s;
    border-color: #FFA07A;
    background: linear-gradient(135deg, #fff 0%, #fff4e6 100%);
}

.stat-item:nth-child(3) {
    animation-delay: 0.4s;
    border-color: #90EE90;
    background: linear-gradient(135deg, #fff 0%, #e6fffa 100%);
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-5px); }
}

.stat-item:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--color-muted);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.stat-value {
    font-size: 2rem;
    font-weight: 800;
    background: linear-gradient(45deg, #FF6B9D, #FFA07A);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-family: var(--font-primary);
}

/* Progress Bar - Enhanced! */
.progress-container {
    margin-bottom: 2rem;
}

.progress {
    height: 35px;
    border-radius: var(--radius-full);
    background: linear-gradient(135deg, #e2e8f0 0%, #f0f9ff 100%);
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.1);
    border: 3px solid #fff;
}

.progress-bar {
    background: linear-gradient(90deg, #FF6B9D 0%, #FFA07A 25%, #FFD700 50%, #90EE90 75%, #87CEEB 100%);
    background-size: 200% 100%;
    animation: progress-shimmer 3s linear infinite;
    transition: width var(--duration-slow);
    font-weight: 800;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
    position: relative;
    overflow: hidden;
}

.progress-bar::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    animation: progress-shine 2s infinite;
}

@keyframes progress-shimmer {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes progress-shine {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* =====================================================
   7. GAME PLAY AREA - ENHANCED FOR KIDS! 🎨
   ===================================================== */
.game-play-area {
    background: linear-gradient(135deg, #fff 0%, #f8f9fa 100%);
    border-radius: var(--radius-xl);
    padding: 3rem;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    min-height: 500px;
    position: relative;
    border: 4px solid transparent;
    background-clip: padding-box;
}

.game-play-area::before {
    content: '';
    position: absolute;
    top: -4px; right: -4px; bottom: -4px; left: -4px;
    background: linear-gradient(45deg, #FF6B9D, #FFA07A, #FFD700, #90EE90, #87CEEB, #FF6B9D);
    border-radius: var(--radius-xl);
    z-index: -1;
    opacity: 0.3;
    animation: rainbow-border 3s linear infinite;
    background-size: 300% 300%;
}

@keyframes rainbow-border {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.game-question {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem;
    background: linear-gradient(135deg, #fff5f7 0%, #fff9e6 100%);
    border-radius: var(--radius-lg);
    border: 3px dashed #FF6B9D;
    animation: gentle-pulse 2s ease-in-out infinite;
}

@keyframes gentle-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.02); }
}

.question-text {
    font-size: 2.5rem;
    font-weight: 800;
    background: linear-gradient(45deg, #FF6B9D, #FFA07A, #FFD700);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
    animation: text-shimmer 3s ease-in-out infinite;
}

@keyframes text-shimmer {
    0% { filter: brightness(1); }
    50% { filter: brightness(1.2); }
    100% { filter: brightness(1); }
}

.question-image {
    max-width: 300px;
    height: auto;
    border-radius: var(--radius-lg);
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    margin: 0 auto;
    border: 4px solid white;
    transition: transform 0.3s ease;
}

.question-image:hover {
    transform: rotate(2deg) scale(1.05);
}

/* Answer Options - Super Fun & Colorful! */
.answer-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.answer-option {
    background: linear-gradient(135deg, #ffffff 0%, #f0f9ff 100%);
    border: 5px solid transparent;
    border-radius: var(--radius-xl);
    padding: 2.5rem 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    min-height: 200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 20px rgba(0,0,0,0.1);
    position: relative;
    overflow: hidden;
}

/* Colorful gradient borders for each option */
.answer-option:nth-child(1) {
    background: linear-gradient(135deg, #fff5f7 0%, #ffe5e5 100%);
    border-color: #FF6B9D;
}

.answer-option:nth-child(2) {
    background: linear-gradient(135deg, #fffbf0 0%, #fff4e6 100%);
    border-color: #FFA07A;
}

.answer-option:nth-child(3) {
    background: linear-gradient(135deg, #f0fff4 0%, #e6fffa 100%);
    border-color: #90EE90;
}

.answer-option:nth-child(4) {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border-color: #87CEEB;
}

/* Sparkle effect on hover */
.answer-option::before {
    content: '✨';
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 1.5rem;
    opacity: 0;
    transform: scale(0) rotate(0deg);
    transition: all 0.3s ease;
}

.answer-option:hover {
    transform: translateY(-10px) scale(1.05);
    box-shadow: 0 15px 40px rgba(0,0,0,0.2);
    border-width: 6px;
}

.answer-option:hover::before {
    opacity: 1;
    transform: scale(1) rotate(20deg);
}

.answer-option:active {
    transform: translateY(-5px) scale(1.02);
}

/* Correct Answer - CELEBRATION! */
.answer-option.correct {
    background: linear-gradient(135deg, #90EE90 0%, #98FB98 100%) !important;
    border-color: #32CD32 !important;
    animation: celebrate-correct 0.6s ease-out;
    color: white;
    box-shadow: 0 0 30px rgba(144, 238, 144, 0.8);
}

.answer-option.correct::after {
    content: '🎉';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 4rem;
    animation: explode 0.5s ease-out;
}

@keyframes celebrate-correct {
    0% { transform: scale(1); }
    25% { transform: scale(1.2) rotate(5deg); }
    50% { transform: scale(1.15) rotate(-5deg); }
    75% { transform: scale(1.2) rotate(3deg); }
    100% { transform: scale(1.1); }
}

@keyframes explode {
    0% { opacity: 0; transform: translate(-50%, -50%) scale(0); }
    50% { opacity: 1; transform: translate(-50%, -50%) scale(1.5); }
    100% { opacity: 0; transform: translate(-50%, -50%) scale(2); }
}

/* Incorrect Answer - Gentle Shake */
.answer-option.incorrect {
    background: linear-gradient(135deg, #FF6B6B 0%, #FF8787 100%) !important;
    border-color: #FF4444 !important;
    animation: gentle-shake 0.5s ease-in-out;
    color: white;
    box-shadow: 0 0 20px rgba(255, 107, 107, 0.6);
}

@keyframes gentle-shake {
    0%, 100% { transform: translateX(0) rotate(0deg); }
    25% { transform: translateX(-15px) rotate(-2deg); }
    75% { transform: translateX(15px) rotate(2deg); }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

.answer-option-text {
    font-size: 1.8rem;
    font-weight: 800;
    margin-top: 1rem;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
    font-family: var(--font-primary);
}

.answer-option-image {
    width: 120px;
    height: 120px;
    object-fit: contain;
    transition: transform 0.3s ease;
    filter: drop-shadow(2px 4px 6px rgba(0,0,0,0.1));
}

.answer-option:hover .answer-option-image {
    transform: scale(1.1) rotate(5deg);
}

/* =====================================================
   8. NOTIFIER MODAL
   ===================================================== */
.notifier-modal .modal-content {
    background: linear-gradient(135deg, #fff 0%, #f7fafc 100%);
}

#notifier-icon {
    font-size: 5rem;
}

#notifier-icon.success {
    color: var(--color-success);
    animation: bounce 1s;
}

#notifier-icon.error {
    color: var(--color-danger);
    animation: shake 0.5s;
}

#notifier-title {
    font-size: 2.5rem;
    color: var(--color-dark);
}

#notifier-message {
    color: var(--color-muted);
}

/* =====================================================
   9. CONFETTI CANVAS
   ===================================================== */
#confetti-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
}

/* =====================================================
   10. FOOTER
   ===================================================== */
.footer {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

/* =====================================================
   11. RESPONSIVE DESIGN
   ===================================================== */

/* Tablets */
@media (max-width: 992px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .category-card {
        min-height: 240px;
    }
    
    .category-icon-wrapper {
        width: 100px;
        height: 100px;
    }
    
    .category-icon {
        font-size: 2.5rem;
    }
    
    .difficulty-selector {
        gap: 0.75rem;
    }
    
    .difficulty-btn {
        min-width: 120px;
        font-size: 1.1rem;
        padding: 0.875rem 1.5rem;
    }
}

@media (max-width: 768px) {
    .app-title-text {
        font-size: 1.25rem;
    }
    
    .logo-circle {
        width: 45px;
        height: 45px;
        font-size: 1.25rem;
    }
    
    .btn-toggle {
        width: 45px;
        height: 45px;
        font-size: 1.1rem;
    }
    
    .hero-title {
        font-size: 1.75rem;
    }
    
    .mascot-emoji {
        font-size: 4rem;
    }
    
    .category-card {
        min-height: 220px;
        padding: 1.5rem 1rem;
    }
    
    .category-icon-wrapper {
        width: 90px;
        height: 90px;
        margin-bottom: 1rem;
    }
    
    .category-title {
        font-size: 1.25rem;
    }
    
    .category-desc {
        font-size: 0.9rem;
    }
    
    .question-text {
        font-size: 1.5rem;
    }
    
    .answer-options {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .level-selector {
        grid-template-columns: repeat(5, 1fr);
        gap: 0.75rem;
    }
    
    .game-stats {
        gap: 0.75rem;
    }
    
    .stat-item {
        min-width: 100px;
        padding: 0.75rem;
    }
}

/* Mobile */
@media (max-width: 576px) {
    html {
        font-size: 14px;
    }
    
    .hero-section {
        padding: 2rem 0 1rem;
    }
    
    .hero-title {
        font-size: 1.5rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .mascot-emoji {
        font-size: 3rem;
    }
    
    .category-card {
        min-height: 200px;
    }
    
    .category-icon-wrapper {
        width: 80px;
        height: 80px;
    }
    
    .category-icon {
        font-size: 2rem;
    }
    
    .difficulty-selector {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .difficulty-btn {
        width: 100%;
        min-width: auto;
        font-size: 1.1rem;
    }
    
    .level-selector {
        grid-template-columns: repeat(5, 1fr);
        gap: 0.5rem;
    }
    
    .level-btn {
        font-size: 1.25rem;
    }
    
    .game-play-area {
        padding: 1.5rem;
    }
    
    .answer-option {
        min-height: 120px;
        padding: 1.25rem;
    }
    
    .answer-option-text {
        font-size: 1.25rem;
    }
    
    .stat-value {
        font-size: 1.5rem;
    }
    
    .stat-label {
        font-size: 0.8rem;
    }
    
    .game-header {
        padding: 1.5rem;
    }
}

/* =====================================================
   12. ACCESSIBILITY
   ===================================================== */

/* Focus States */
*:focus {
    outline: 3px solid var(--color-primary);
    outline-offset: 3px;
}

button:focus, a:focus {
    outline: 3px solid var(--color-primary);
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    :root {
        --color-primary: #E91E63;
        --color-secondary: #FF5722;
    }
    
    .btn {
        border: 2px solid currentColor;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* =====================================================
   13. UTILITY CLASSES & ANIMATIONS
   ===================================================== */
.rounded-4 {
    border-radius: var(--radius-xl) !important;
}

.shadow-lg {
    box-shadow: var(--shadow-lg) !important;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.animate-bounce {
    animation: bounce 2s ease-in-out infinite;
}

/* Fade in animation for page load */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-section, .categories-section, .game-container {
    animation: fadeInUp 0.6s ease-out;
}

/* Stagger animation for category cards */
.category-card {
    animation: fadeInUp 0.6s ease-out;
}

.category-card:nth-child(1) { animation-delay: 0.1s; }
.category-card:nth-child(2) { animation-delay: 0.2s; }
.category-card:nth-child(3) { animation-delay: 0.3s; }
.category-card:nth-child(4) { animation-delay: 0.4s; }

.text-gradient-alphabet {
    background: var(--gradient-alphabet);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.text-gradient-numbers {
    background: var(--gradient-numbers);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.text-gradient-colors {
    background: var(--gradient-colors);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Loading Spinner */
.spinner {
    width: 60px;
    height: 60px;
    border: 6px solid #f3f3f3;
    border-top: 6px solid var(--color-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 2rem auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Hidden but accessible */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
} 

/* =====================================================
   14. SHAPES THEME (Background Decorations)
   ===================================================== */
.bg-shapes {
    position: fixed;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.bg-shapes .shape {
    position: absolute;
    opacity: 0.15;
    filter: blur(0.5px);
    animation: float-slow 18s ease-in-out infinite;
}

/* Circles */
.shape-circle {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: radial-gradient( circle at 30% 30%, rgba(255,255,255,0.9), rgba(255,255,255,0) 60% ), var(--gradient-alphabet);
}

/* Squares */
.shape-square {
    width: 160px;
    height: 160px;
    border-radius: 24px;
    background: radial-gradient( circle at 30% 30%, rgba(255,255,255,0.9), rgba(255,255,255,0) 60% ), var(--gradient-numbers);
}

/* Triangles using clip-path */
.shape-triangle {
    width: 0;
    height: 0;
    border-left: 110px solid transparent;
    border-right: 110px solid transparent;
    border-bottom: 190px solid #FEE140;
    filter: drop-shadow(0 8px 20px rgba(0,0,0,0.2));
    opacity: 0.2;
}

/* Blobs (organic) */
.shape-blob {
    width: 260px;
    height: 260px;
    border-radius: 45% 55% 65% 35% / 50% 40% 60% 50%;
    background: var(--gradient-colors);
}

/* Shapes placement */
.shape.s1 { top: -40px; left: -30px; animation-delay: 0s; }
.shape.s2 { top: 20%; right: -60px; animation-delay: 4s; }
.shape.s3 { bottom: 10%; left: -80px; animation-delay: 8s; }
.shape.s4 { bottom: -70px; right: 5%; animation-delay: 2s; }
.shape.s5 { top: 45%; left: 40%; transform: translate(-50%, -50%); animation-delay: 6s; }

@keyframes float-slow {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-12px) rotate(3deg); }
    50% { transform: translateY(-24px) rotate(-3deg); }
    75% { transform: translateY(-12px) rotate(2deg); }
}

/* Elevate main content above shapes */
#app-container, .main-content, .game-container { position: relative; z-index: 1; }

/* Shape badges for category icons */
.category-icon.shape-badge {
    position: relative;
}
.category-icon.shape-badge::after {
    content: '';
    position: absolute;
    inset: -8px;
    border-radius: 50%;
    background: rgba(255,255,255,0.25);
    z-index: -1;
}

/* Shapes header ribbon */
.shapes-ribbon {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 0 auto 1.25rem;
}
.shapes-ribbon .pill {
    height: 12px;
    border-radius: 9999px;
    background: var(--gradient-primary);
}
.shapes-ribbon .pill.p1 { width: 80px; background: var(--gradient-alphabet); }
.shapes-ribbon .pill.p2 { width: 120px; background: var(--gradient-numbers); }
.shapes-ribbon .pill.p3 { width: 60px; background: var(--gradient-colors); }

/* PopIn animation for new features */
@keyframes popIn {
    0% { transform: scale(0.9); opacity: 0; }
    50% { transform: scale(1.05); opacity: 0.7; }
    100% { transform: scale(1); opacity: 1; }
}

/* Shake animation for notifications */
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
} 