body {
    font-family: 'Arial', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    margin: 0;
    padding: 20px;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* 575特別演出 */
.special-575 {
    font-size: 1.5em !important;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4, #ffeaa7);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: rainbow-pulse 1s ease-in-out, text-glow 0.5s ease-in-out;
    text-shadow: 0 0 20px rgba(255, 107, 107, 0.5);
}

.animation-575 {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 4em;
    font-weight: bold;
    z-index: 1000;
    pointer-events: none;
    animation: bounce-575 2s ease-out forwards;
    text-shadow: 
        0 0 10px rgba(255, 107, 107, 0.8),
        0 0 20px rgba(78, 205, 196, 0.6),
        0 0 30px rgba(69, 183, 209, 0.4);
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.8));
}

@keyframes bounce-575 {
    0% {
        transform: translate(-50%, -50%) scale(0) rotate(0deg);
        opacity: 0;
    }
    15% {
        transform: translate(-50%, -50%) scale(1.3) rotate(15deg);
        opacity: 1;
    }
    30% {
        transform: translate(-50%, -50%) scale(0.8) rotate(-10deg);
        opacity: 1;
    }
    45% {
        transform: translate(-50%, -50%) scale(1.1) rotate(5deg);
        opacity: 1;
    }
    60% {
        transform: translate(-50%, -50%) scale(0.95) rotate(-2deg);
        opacity: 1;
    }
    75% {
        transform: translate(-50%, -50%) scale(1.05) rotate(1deg);
        opacity: 1;
    }
    90% {
        transform: translate(-50%, -50%) scale(1) rotate(0deg);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scale(0.7) rotate(0deg);
        opacity: 0;
    }
}

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

@keyframes text-glow {
    0%, 100% {
        text-shadow: 0 0 5px rgba(255, 107, 107, 0.5);
    }
    50% {
        text-shadow: 
            0 0 10px rgba(255, 107, 107, 0.8),
            0 0 20px rgba(78, 205, 196, 0.6),
            0 0 30px rgba(69, 183, 209, 0.4);
    }
}

/* 紙吹雪エフェクト */
.confetti {
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    pointer-events: none;
    z-index: 999;
    animation: confetti-fall linear forwards;
    box-shadow: 0 0 6px rgba(255, 255, 255, 0.8);
}

.confetti:nth-child(odd) {
    width: 6px;
    height: 12px;
    border-radius: 0;
}

.confetti:nth-child(3n) {
    width: 10px;
    height: 4px;
    border-radius: 2px;
}

@keyframes confetti-fall {
    0% {
        transform: translateY(-100vh) rotate(0deg) scale(1);
        opacity: 1;
    }
    50% {
        opacity: 1;
        transform: translateY(50vh) rotate(360deg) scale(0.8);
    }
    100% {
        transform: translateY(120vh) rotate(720deg) scale(0.3);
        opacity: 0;
    }
}

/* ゲームコンテナを相対位置に設定（演出用） */
.game-container {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    text-align: center;
    max-width: 600px;
    width: 100%;
    position: relative;
    overflow: hidden;
}

.title {
    font-size: 2.5em;
    color: #333;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.stage-buttons {
    display: flex;
    gap: 30px;
    justify-content: center;
    flex-wrap: wrap;
}

.stage-btn {
    background: white;
    border: 3px solid #ddd;
    border-radius: 15px;
    padding: 30px;
    width: 250px;
    text-align: center;
    transition: all 0.3s;
    cursor: pointer;
    font-size: 1em;
}

.stage-btn:hover {
    border-color: #2196F3;
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.stage-title {
    font-size: 1.5em;
    font-weight: bold;
    margin-bottom: 15px;
    color: #333;
}

.stage-desc {
    font-size: 1em;
    color: #666;
    line-height: 1.4;
}

.stage-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 15px;
    background: #f0f8ff;
    border-radius: 10px;
    font-weight: bold;
}

.btn-back {
    background: #666;
    color: white;
    padding: 8px 16px;
    font-size: 0.9em;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.game-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 30px;
    font-size: 1.2em;
    font-weight: bold;
}

.score { 
    color: #4CAF50; 
}

.time { 
    color: #FF5722; 
}

.text-display {
    background: #f5f5f5;
    border: 2px solid #ddd;
    border-radius: 10px;
    padding: 20px;
    margin: 20px 0;
    font-size: 1.5em;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    word-break: break-all;
}

.buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin: 30px 0;
}

.btn {
    padding: 15px 30px;
    font-size: 1.2em;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: bold;
}

.btn-yes {
    background: #4CAF50;
    color: white;
}

.btn-no {
    background: #f44336;
    color: white;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.start-btn {
    background: #2196F3;
    color: white;
    padding: 20px 40px;
    font-size: 1.5em;
}

.result {
    margin: 20px 0;
    font-size: 1.3em;
    font-weight: bold;
    min-height: 30px;
}

.correct { 
    color: #4CAF50; 
}

.incorrect { 
    color: #f44336; 
}

.ending {
    display: none;
    text-align: center;
}

.ending h2 {
    font-size: 2em;
    margin-bottom: 20px;
}

.ending-excellent {
    background: linear-gradient(45deg, #FFD700, #FFA500);
    color: #333;
}

.ending-good {
    background: linear-gradient(45deg, #87CEEB, #4682B4);
    color: white;
}

.ending-normal {
    background: linear-gradient(45deg, #98FB98, #32CD32);
    color: #333;
}

.ending-poor {
    background: linear-gradient(45deg, #FFB6C1, #FF69B4);
    color: #333;
}

.progress-bar {
    width: 100%;
    height: 10px;
    background: #ddd;
    border-radius: 5px;
    overflow: hidden;
    margin: 20px 0;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #4CAF50, #45a049);
    transition: width 0.1s linear;
}
.note {
    font-size: 0.9em;
    color: #666;
    margin-bottom: 20px;
    text-align: center;
    background-color: rgba(255, 255, 255, 0.7);
    padding: 8px;
    border-radius: 5px;
    max-width: 90%;
    margin-left: auto;
    margin-right: auto;
}
