* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Fredoka', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 25%, #f093fb 50%, #f5576c 75%, #ffc857 100%);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

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

.floating-shapes {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.shape {
    position: absolute;
    opacity: 0.1;
    animation: float 20s infinite ease-in-out;
}

.shape-1 { width: 100px; height: 100px; background: radial-gradient(circle, #ff6b6b, transparent); border-radius: 50%; top: 10%; left: 10%; animation-delay: 0s; }
.shape-2 { width: 150px; height: 150px; background: radial-gradient(circle, #4ecdc4, transparent); border-radius: 50%; top: 70%; right: 10%; animation-delay: 2s; }
.shape-3 { width: 80px; height: 80px; background: radial-gradient(circle, #45b7d1, transparent); border-radius: 50%; top: 30%; right: 20%; animation-delay: 4s; }
.shape-4 { width: 120px; height: 120px; background: radial-gradient(circle, #96ceb4, transparent); border-radius: 50%; bottom: 20%; left: 15%; animation-delay: 6s; }
.shape-5 { width: 90px; height: 90px; background: radial-gradient(circle, #feca57, transparent); border-radius: 50%; top: 50%; left: 50%; animation-delay: 8s; }
.shape-6 { width: 110px; height: 110px; background: radial-gradient(circle, #ff9ff3, transparent); border-radius: 50%; top: 80%; left: 40%; animation-delay: 10s; }
.shape-7 { width: 70px; height: 70px; background: radial-gradient(circle, #74b9ff, transparent); border-radius: 50%; top: 20%; left: 70%; animation-delay: 12s; }

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); opacity: 0.1; }
    25% { transform: translateY(-20px) rotate(90deg); opacity: 0.2; }
    50% { transform: translateY(0px) rotate(180deg); opacity: 0.1; }
    75% { transform: translateY(20px) rotate(270deg); opacity: 0.2; }
}

.main-container {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 25px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 1000px;
    width: 100%;
    padding: 30px;
    backdrop-filter: blur(10px);
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.header {
    text-align: center;
    margin-bottom: 30px;
    background: linear-gradient(45deg, #74b9ff, #0984e3, #00b894, #00a085);
    background-size: 300% 300%;
    animation: gradientMove 8s ease infinite;
    padding: 25px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

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

.game-title {
    font-size: 2.5em;
    font-weight: 700;
    color: white;
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.3);
    margin-bottom: 20px;
    letter-spacing: 2px;
    animation: pulse 2s ease-in-out infinite;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

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

.score-board {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.score, .timer, .accuracy {
    background: rgba(255, 255, 255, 0.9);
    padding: 12px 20px;
    border-radius: 15px;
    font-size: 1.1em;
    font-weight: 600;
    color: #333;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.score:hover, .timer:hover, .accuracy:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.score i, .timer i, .accuracy i {
    color: #00b894;
    margin-right: 8px;
}

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

.btn {
    padding: 15px 30px;
    font-size: 1.1em;
    font-weight: 600;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.3);
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

.btn-primary { background: linear-gradient(45deg, #00b894, #00a085); color: white; }
.btn-secondary { background: linear-gradient(45deg, #ff6b6b, #ee5a6f); color: white; }
.btn-music { background: linear-gradient(45deg, #96ceb4, #88b0a3); color: white; }
.btn-home { background: linear-gradient(45deg, #ff9ff3, #ee5a6f); color: white; }
.btn-submit { background: linear-gradient(45deg, #74b9ff, #0984e3); color: white; }

.game-area {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.quiz-section {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.question-number {
    text-align: center;
    font-size: 1.3em;
    font-weight: 700;
    color: #00b894;
    margin-bottom: 20px;
}

.image-display {
    width: 100%;
    height: 300px;
    background: rgba(240, 240, 240, 0.5);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-bottom: 30px;
}

.placeholder-image {
    text-align: center;
    color: #999;
}

.placeholder-image i {
    font-size: 4em;
    margin-bottom: 20px;
    color: #ddd;
}

.image-display img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 10px;
}

.answer-section h3 {
    text-align: center;
    font-size: 1.5em;
    font-weight: 700;
    color: #2d3436;
    margin-bottom: 20px;
}

.input-container {
    display: flex;
    gap: 15px;
    justify-content: center;
    align-items: center;
}

.answer-input {
    flex: 1;
    max-width: 400px;
    padding: 15px 20px;
    font-size: 1.2em;
    font-weight: 600;
    border: 3px solid #00b894;
    border-radius: 15px;
    text-align: center;
    transition: all 0.3s ease;
}

.answer-input:focus {
    outline: none;
    border-color: #74b9ff;
    transform: scale(1.02);
    box-shadow: 0 5px 15px rgba(116, 185, 255, 0.3);
}

.feedback-section {
    text-align: center;
}

.feedback-message {
    background: linear-gradient(45deg, #00b894, #74b9ff, #0984e3);
    background-size: 300% 300%;
    animation: gradientMove 6s ease infinite;
    color: white;
    padding: 20px 30px;
    border-radius: 20px;
    font-size: 1.4em;
    font-weight: 600;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    display: inline-block;
    margin-bottom: 20px;
}

.letter-hints {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    min-height: 40px;
}

.hint-letter {
    width: 40px;
    height: 40px;
    background: rgba(116, 185, 255, 0.2);
    border: 2px solid #74b9ff;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2em;
    font-weight: 700;
    color: #0984e3;
    animation: fadeIn 0.3s ease;
}

.progress-section {
    margin-top: 20px;
    text-align: center;
}

.progress-bar {
    width: 100%;
    height: 30px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 10px;
    box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.1);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #00b894, #74b9ff, #0984e3);
    border-radius: 15px;
    transition: width 0.5s ease;
    width: 0%;
}

.progress-text {
    font-size: 1.1em;
    font-weight: 600;
    color: #2d3436;
}

.results-section {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
    animation: slideInUp 0.6s ease;
}

.results-title {
    text-align: center;
    font-size: 2em;
    font-weight: 700;
    color: #00b894;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.result-card {
    background: linear-gradient(135deg, #74b9ff, #0984e3);
    color: white;
    padding: 25px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease;
}

.result-card:hover {
    transform: translateY(-5px);
}

.result-card i {
    font-size: 2.5em;
    margin-bottom: 15px;
}

.result-card h3 {
    font-size: 1.1em;
    font-weight: 600;
    margin-bottom: 10px;
}

.result-card p {
    font-size: 1.8em;
    font-weight: 700;
}

.result-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.btn-review, .btn-restart {
    background: linear-gradient(45deg, #00b894, #74b9ff);
    color: white;
}

.confetti {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    z-index: 9999;
}

.confetti-piece {
    position: absolute;
    width: 10px;
    height: 10px;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4);
    animation: confettiFall 3s ease-in-out;
}

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

.game-footer {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 15px;
    padding: 20px;
    margin-top: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(5px);
}

.game-footer .creator-credit {
    text-align: center;
    margin: 0;
    padding: 0;
    border: none;
}

.game-footer .made-by {
    font-size: 0.8em;
    color: #666;
    margin-bottom: 3px;
    font-weight: 500;
}

.game-footer .creator-name {
    color: #00b894;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.game-footer .creator-name:hover {
    color: #74b9ff;
}

.game-footer .visit-site {
    font-size: 0.7em;
    color: #888;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    transition: all 0.3s ease;
}

.game-footer .visit-site:hover {
    color: #00b894;
}

.game-footer .creator-link {
    color: #00b894;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border-bottom: 1px solid transparent;
}

.game-footer .creator-link:hover {
    color: #74b9ff;
    border-bottom-color: #74b9ff;
}

.game-footer .visit-site i {
    color: #feca57;
    font-size: 0.8em;
}

@media (max-width: 768px) {
    .main-container {
        padding: 20px;
    }

    .game-title {
        font-size: 2em;
        flex-direction: column;
        gap: 10px;
    }

    .score-board {
        flex-direction: column;
        gap: 15px;
        align-items: center;
    }

    .game-controls {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 200px;
        justify-content: center;
    }

    .input-container {
        flex-direction: column;
        gap: 15px;
    }

    .answer-input {
        max-width: 100%;
    }

    .results-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .main-container {
        padding: 15px;
    }

    .game-title {
        font-size: 1.5em;
    }

    .results-grid {
        grid-template-columns: 1fr;
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}