/* ローディング画面 */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #FFB800 0%, #FF9500 30%, #FF6B35 60%, #0EA5E9 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loading-screen.fade-out {
    opacity: 0;
    visibility: hidden;
}

.loading-content {
    text-align: center;
}

/* 太陽ローダー */
.sun-loader {
    position: relative;
    width: 120px;
    height: 120px;
    margin: 0 auto 30px;
}

.sun-core {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 60px;
    height: 60px;
    background: white;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 0 40px rgba(255, 255, 255, 0.8);
    animation: pulse-sun 2s ease-in-out infinite;
}

.sun-ray {
    position: absolute;
    top: 0;
    left: 50%;
    width: 4px;
    height: 40px;
    background: white;
    border-radius: 2px;
    transform-origin: center 60px;
    margin-left: -2px;
}

.sun-ray:nth-child(2) { transform: rotate(0deg); }
.sun-ray:nth-child(3) { transform: rotate(45deg); }
.sun-ray:nth-child(4) { transform: rotate(90deg); }
.sun-ray:nth-child(5) { transform: rotate(135deg); }
.sun-ray:nth-child(6) { transform: rotate(180deg); }
.sun-ray:nth-child(7) { transform: rotate(225deg); }
.sun-ray:nth-child(8) { transform: rotate(270deg); }
.sun-ray:nth-child(9) { transform: rotate(315deg); }

.sun-loader {
    animation: rotate-rays 3s linear infinite;
}

@keyframes pulse-sun {
    0%, 100% {
        transform: translate(-50%, -50%) scale(1);
        box-shadow: 0 0 40px rgba(255, 255, 255, 0.8);
    }
    50% {
        transform: translate(-50%, -50%) scale(1.15);
        box-shadow: 0 0 60px rgba(255, 255, 255, 1);
    }
}

@keyframes rotate-rays {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.loading-text {
    font-family: 'Fredoka', 'Noto Sans JP', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: white;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    animation: fade-in-out 2s ease-in-out infinite;
}

@keyframes fade-in-out {
    0%, 100% {
        opacity: 0.6;
    }
    50% {
        opacity: 1;
    }
}
