* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background: linear-gradient(135deg, #6a11cb 0%, #2575fc 100%);
    color: white;
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 500px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    margin-bottom: 30px;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
}

.menu {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 40px;
}

.btn-primary, .btn-secondary {
    padding: 15px 20px;
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.btn-primary {
    background-color: #FF5722;
    color: white;
}

.btn-secondary {
    background-color: transparent;
    color: white;
    border: 2px solid white;
}

.btn-small {
    padding: 8px 15px;
    border: none;
    border-radius: 20px;
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
    cursor: pointer;
    font-size: 0.9rem;
}

.btn-primary:hover, .btn-secondary:hover, .btn-small:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3);
}

.btn-primary:active, .btn-secondary:active, .btn-small:active {
    transform: translateY(0);
}

.instructions {
    background-color: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 15px;
    text-align: center;
}

.instructions h2 {
    margin-bottom: 10px;
}

/* Estilos para el juego */
.game-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.score-display {
    font-size: 1.2rem;
    font-weight: bold;
}

.game-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.image-container {
    width: 100%;
    height: 250px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

#anatomy-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.question-container {
    text-align: center;
    padding: 10px;
}

.options-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.option-btn {
    padding: 15px;
    border: none;
    border-radius: 10px;
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.option-btn:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

.option-btn.correct {
    background-color: #4CAF50;
}

.option-btn.incorrect {
    background-color: #F44336;
}

.feedback-container {
    text-align: center;
    min-height: 30px;
}

#feedback-text {
    font-size: 1.1rem;
    font-weight: bold;
}

.next-container {
    text-align: center;
}

/* Estilos para la pantalla de puntuaciones */
.score-form {
    background-color: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 15px;
    margin-bottom: 30px;
}

.score-form h2 {
    margin-bottom: 15px;
    text-align: center;
}

#save-score-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

#player-name {
    padding: 12px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    text-align: center;
}

.scores-list h2 {
    text-align: center;
    margin-bottom: 15px;
}

#scores-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.score-item {
    display: flex;
    justify-content: space-between;
    padding: 12px 15px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
}

.score-name {
    font-weight: bold;
}

.score-value {
    color: #FFC107;
}

/* Responsive */
@media (max-width: 480px) {
    .container {
        padding: 10px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    .image-container {
        height: 200px;
    }
}

/* ==================== */
/* ANIMACIONES MEJORADAS */
/* ==================== */

/* Fondo animado con gradiente */
body {
    background: linear-gradient(-45deg, #6a11cb, #2575fc, #6a11cb, #2575fc);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
}

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

/* Elementos flotantes con formas de anatomía */
.floating-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.floating-shape {
    position: absolute;
    opacity: 0.3;
    border-radius: 50%;
    filter: blur(1px);
    animation: float 20s infinite linear;
}

.heart {
    width: 80px;
    height: 80px;
    background: radial-gradient(circle, #ff4081, #f50057);
    top: 10%;
    left: 5%;
    animation-duration: 25s;
    animation-delay: 0s;
}

.brain {
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, #7e57c2, #5e35b1);
    top: 70%;
    left: 85%;
    animation-duration: 30s;
    animation-delay: 2s;
    border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%;
}

.lung {
    width: 120px;
    height: 80px;
    background: radial-gradient(circle, #4fc3f7, #0288d1);
    top: 20%;
    left: 80%;
    animation-duration: 35s;
    animation-delay: 1s;
    border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
}

.bone {
    width: 120px;
    height: 40px;
    background: radial-gradient(circle, #f5f5f5, #bdbdbd);
    top: 80%;
    left: 10%;
    animation-duration: 40s;
    animation-delay: 3s;
    border-radius: 20px;
}

.stomach {
    width: 90px;
    height: 90px;
    background: radial-gradient(circle, #ffb74d, #f57c00);
    top: 50%;
    left: 15%;
    animation-duration: 28s;
    animation-delay: 4s;
    border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
}

.kidney {
    width: 70px;
    height: 100px;
    background: radial-gradient(circle, #4db6ac, #00897b);
    top: 30%;
    left: 90%;
    animation-duration: 32s;
    animation-delay: 5s;
    border-radius: 50% 50% 50% 70% / 60% 60% 40% 40%;
}

.eye {
    width: 60px;
    height: 60px;
    background: radial-gradient(circle, #f06292, #e91e63);
    top: 85%;
    left: 75%;
    animation-duration: 26s;
    animation-delay: 6s;
    border-radius: 50%;
}

.tooth {
    width: 40px;
    height: 60px;
    background: radial-gradient(circle, #ffffff, #e0e0e0);
    top: 15%;
    left: 20%;
    animation-duration: 22s;
    animation-delay: 7s;
    border-radius: 40% 40% 60% 60% / 40% 40% 60% 60%;
}

@keyframes float {
    0% {
        transform: translate(0, 0) rotate(0deg);
    }
    25% {
        transform: translate(10px, 10px) rotate(5deg);
    }
    50% {
        transform: translate(20px, 5px) rotate(0deg);
    }
    75% {
        transform: translate(10px, 0px) rotate(-5deg);
    }
    100% {
        transform: translate(0, 0) rotate(0deg);
    }
}

/* Partículas animadas */
.particles-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.particle {
    position: absolute;
    background-color: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    animation: particleFloat 15s infinite linear;
}

.particle:nth-child(1) {
    width: 5px;
    height: 5px;
    top: 10%;
    left: 20%;
    animation-duration: 20s;
    animation-delay: 0s;
}

.particle:nth-child(2) {
    width: 8px;
    height: 8px;
    top: 30%;
    left: 80%;
    animation-duration: 25s;
    animation-delay: 2s;
}

.particle:nth-child(3) {
    width: 6px;
    height: 6px;
    top: 70%;
    left: 10%;
    animation-duration: 18s;
    animation-delay: 1s;
}

.particle:nth-child(4) {
    width: 7px;
    height: 7px;
    top: 50%;
    left: 90%;
    animation-duration: 22s;
    animation-delay: 3s;
}

.particle:nth-child(5) {
    width: 4px;
    height: 4px;
    top: 20%;
    left: 50%;
    animation-duration: 30s;
    animation-delay: 4s;
}

.particle:nth-child(6) {
    width: 9px;
    height: 9px;
    top: 80%;
    left: 60%;
    animation-duration: 17s;
    animation-delay: 5s;
}

.particle:nth-child(7) {
    width: 5px;
    height: 5px;
    top: 40%;
    left: 30%;
    animation-duration: 28s;
    animation-delay: 2s;
}

.particle:nth-child(8) {
    width: 6px;
    height: 6px;
    top: 60%;
    left: 70%;
    animation-duration: 24s;
    animation-delay: 6s;
}

.particle:nth-child(9) {
    width: 7px;
    height: 7px;
    top: 90%;
    left: 40%;
    animation-duration: 19s;
    animation-delay: 7s;
}

.particle:nth-child(10) {
    width: 8px;
    height: 8px;
    top: 10%;
    left: 70%;
    animation-duration: 26s;
    animation-delay: 8s;
}

@keyframes particleFloat {
    0% {
        transform: translateY(0) translateX(0);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-100px) translateX(50px);
        opacity: 0;
    }
}

/* Título animado */
.animated-title {
    background: linear-gradient(90deg, #ff8a00, #e52e71, #ff8a00);
    background-size: 200% auto;
    color: transparent;
    -webkit-background-clip: text;
    background-clip: text;
    animation: shine 3s linear infinite;
    text-shadow: 0 0 10px rgba(255, 138, 0, 0.3);
}

@keyframes shine {
    to {
        background-position: 200% center;
    }
}

/* Efecto de pulso para el subtítulo */
.pulse {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        opacity: 0.7;
    }
    50% {
        opacity: 1;
    }
    100% {
        opacity: 0.7;
    }
}

/* Efecto de rebote para botones */
.bounce {
    animation: bounce 2s infinite;
}

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

/* Elementos decorativos circulares */
.decorative-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.deco-circle {
    position: absolute;
    border-radius: 50%;
    filter: blur(10px);
    opacity: 0.1;
}

.deco-1 {
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, #ff4081, transparent);
    top: -50px;
    left: -50px;
    animation: decoPulse 8s infinite ease-in-out;
}

.deco-2 {
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, #7e57c2, transparent);
    bottom: -100px;
    right: -100px;
    animation: decoPulse 10s infinite ease-in-out;
    animation-delay: 1s;
}

.deco-3 {
    width: 150px;
    height: 150px;
    background: radial-gradient(circle, #4fc3f7, transparent);
    top: 50%;
    left: -50px;
    animation: decoPulse 12s infinite ease-in-out;
    animation-delay: 2s;
}

.deco-4 {
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, #ffb74d, transparent);
    bottom: -50px;
    left: 50%;
    animation: decoPulse 9s infinite ease-in-out;
    animation-delay: 3s;
}

@keyframes decoPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.1;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.15;
    }
}

/* Mejoras para pantallas táctiles */
@media (max-width: 768px) {
    .floating-shape {
        width: 60px !important;
        height: 60px !important;
    }
    
    .deco-circle {
        display: none;
    }
}