/* ==============================================
   K41ru Entertainment - Advanced Styles
   高度な機能用スタイル
   ============================================== */

/* パーティクルキャンバス */
.particle-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

/* ダークモードトグル */
.dark-mode-toggle {
    position: fixed;
    top: 90px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: white;
    border: 2px solid var(--primary-purple);
    font-size: 24px;
    cursor: pointer;
    z-index: 1001;
    transition: all var(--transition-normal);
    box-shadow: var(--shadow-md);
    display: flex;
    align-items: center;
    justify-content: center;
}

.dark-mode-toggle:hover {
    transform: scale(1.1) rotate(20deg);
    box-shadow: var(--shadow-xl);
}

/* ダークモード */
body.dark-mode {
    --text-dark: #f0f0f0;
    --text-medium: #b0b0b0;
    --text-light: #808080;
    --bg-white: #1a1a2e;
    --bg-light: #16213e;
    --bg-gradient: linear-gradient(135deg, #0f3460 0%, #16213e 100%);
    --glass-bg: rgba(26, 26, 46, 0.85);
    --glass-border: rgba(255, 255, 255, 0.1);
}

body.dark-mode .header {
    background: rgba(26, 26, 46, 0.95);
}

body.dark-mode .section {
    background: var(--bg-white);
}

body.dark-mode .about,
body.dark-mode .vision,
body.dark-mode .music {
    background: var(--bg-light);
}

body.dark-mode .artist-card,
body.dark-mode .music-card,
body.dark-mode .news-card {
    background: rgba(26, 26, 46, 0.8);
    border-color: rgba(255, 255, 255, 0.1);
}

body.dark-mode .artist-card:hover,
body.dark-mode .music-card:hover,
body.dark-mode .news-card:hover {
    background: rgba(26, 26, 46, 0.95);
}

/* アーティストモーダル */
.artist-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-normal);
}

.artist-modal.active {
    opacity: 1;
    visibility: visible;
}

.artist-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
}

.artist-modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    background: white;
    border-radius: var(--radius-xxl);
    box-shadow: var(--shadow-2xl);
    overflow-y: auto;
    transition: transform var(--transition-normal);
}

.artist-modal.active .artist-modal-content {
    transform: translate(-50%, -50%) scale(1);
}

body.dark-mode .artist-modal-content {
    background: var(--bg-white);
    color: var(--text-dark);
}

.artist-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.1);
    border: none;
    font-size: 28px;
    cursor: pointer;
    transition: all var(--transition-normal);
    z-index: 10;
}

.artist-modal-close:hover {
    background: rgba(0, 0, 0, 0.2);
    transform: rotate(90deg);
}

.artist-modal-header {
    display: flex;
    gap: var(--spacing-lg);
    align-items: center;
    padding: var(--spacing-xxl);
    background: linear-gradient(135deg, var(--primary-purple), var(--primary-violet));
    color: white;
    border-radius: var(--radius-xxl) var(--radius-xxl) 0 0;
}

.artist-modal-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-weight: 700;
    color: white;
    box-shadow: var(--shadow-lg);
}

.artist-modal-name {
    font-size: 28px;
    margin-bottom: var(--spacing-xs);
}

.artist-modal-genre {
    font-size: 14px;
    opacity: 0.9;
}

.artist-modal-body {
    padding: var(--spacing-xxl);
}

.artist-modal-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-xxl);
}

.modal-stat {
    text-align: center;
    padding: var(--spacing-lg);
    background: var(--glass-bg);
    border-radius: var(--radius-lg);
    border: 1px solid var(--glass-border);
}

.modal-stat-number {
    display: block;
    font-size: 32px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-purple), var(--accent-pink));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: var(--spacing-xs);
}

.modal-stat-label {
    display: block;
    font-size: 12px;
    color: var(--text-medium);
    font-weight: 500;
}

.artist-modal-description {
    margin-bottom: var(--spacing-xl);
    line-height: 1.8;
}

.artist-modal-description p {
    margin-bottom: var(--spacing-md);
    color: var(--text-medium);
}

.artist-modal-songs h3 {
    font-size: 20px;
    margin-bottom: var(--spacing-md);
    color: var(--text-dark);
}

.modal-song-list {
    list-style: none;
    display: grid;
    gap: var(--spacing-sm);
}

.modal-song-list li {
    padding: var(--spacing-sm) var(--spacing-md);
    background: rgba(102, 126, 234, 0.05);
    border-radius: var(--radius-md);
    transition: all var(--transition-normal);
}

.modal-song-list li:hover {
    background: rgba(102, 126, 234, 0.1);
    transform: translateX(5px);
}

/* 音楽プレイヤーボタン */
.music-play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    font-size: 20px;
    cursor: pointer;
    transition: all var(--transition-normal);
    opacity: 0;
    box-shadow: var(--shadow-lg);
}

.music-card:hover .music-play-btn {
    opacity: 1;
}

.music-play-btn:hover {
    transform: translate(-50%, -50%) scale(1.1);
    background: white;
}

.music-card.playing .music-cover {
    animation: music-pulse 1s ease-in-out infinite;
}

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

/* スクロール進行バー */
.scroll-progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-purple), var(--primary-violet));
    z-index: 1002;
    transition: width 0.2s ease;
    width: 0;
}

/* カーソルトレイル */
.cursor-trail-dot {
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary-purple);
    pointer-events: none;
    z-index: 9999;
    transition: all 0.5s ease;
    transform: scale(1);
    opacity: 0.6;
}

/* ライブ統計 */
.live-stat {
    position: relative;
}

.live-stat::after {
    content: '';
    position: absolute;
    top: -5px;
    right: -5px;
    width: 10px;
    height: 10px;
    background: #4ade80;
    border-radius: 50%;
    animation: live-pulse 2s ease-in-out infinite;
}

@keyframes live-pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.5;
        transform: scale(1.2);
    }
}

/* 高度なホバーエフェクト */
.artist-card {
    overflow: visible;
}

.artist-card::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg,
        var(--primary-purple),
        var(--primary-violet),
        var(--accent-pink),
        var(--primary-purple)
    );
    border-radius: var(--radius-xl);
    z-index: -1;
    opacity: 0;
    transition: opacity var(--transition-normal);
    background-size: 200% 200%;
    animation: gradient-rotate 3s linear infinite;
}

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

.artist-card:hover::after {
    opacity: 0.5;
}

/* パルス通知バッジ */
.notification-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #ff4757;
    color: white;
    padding: 4px 8px;
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: 600;
    animation: badge-pulse 2s ease-in-out infinite;
}

@keyframes badge-pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 71, 87, 0.7);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 0 10px rgba(255, 71, 87, 0);
    }
}

/* スキューエフェクト */
.skew-card {
    transition: all var(--transition-normal);
}

.skew-card:hover {
    transform: skew(-2deg, -2deg) scale(1.02);
}

/* レスポンシブ */
@media (max-width: 768px) {
    .dark-mode-toggle {
        top: 80px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 20px;
    }

    .artist-modal-content {
        width: 95%;
        max-height: 85vh;
    }

    .artist-modal-header {
        flex-direction: column;
        text-align: center;
    }

    .artist-modal-avatar {
        width: 80px;
        height: 80px;
        font-size: 28px;
    }

    .artist-modal-stats {
        grid-template-columns: 1fr;
    }

    .cursor-trail-dot {
        display: none;
    }
}

@media (max-width: 480px) {
    .artist-modal-body {
        padding: var(--spacing-lg);
    }

    .modal-stat-number {
        font-size: 24px;
    }
}
