/* 基础样式 */
body {
    font-family: 'Arial', sans-serif;
    background-color: #f8f9fa;
    position: relative;
    margin: 0;
    padding: 0;
    min-height: 100vh;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 15px;
}

h1, h2, h3, h4 {
    color: #333;
}

h1 {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 20px;
}

.table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
    background-color: white;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.table th, .table td {
    padding: 12px 15px;
    text-align: center;
    border-bottom: 1px solid #ddd;
}

.table th {
    background-color: #f8f9fa;
    font-weight: bold;
}

/* 表格行点击效果 */
.table tbody tr {
    cursor: pointer;
    transition: all 0.2s;
}

.table tbody tr:hover {
    background-color: #f0f0f8 !important;
}

.table tbody tr.copied {
    background-color: #e6f7ff !important;
    animation: copiedHighlight 1.5s ease;
}

@keyframes copiedHighlight {
    0% { background-color: #e6f7ff; }
    70% { background-color: #e6f7ff; }
    100% { background-color: transparent; }
}

.btn-purple {
    background-color: #6f42c1;
    color: white;
    border-color: #6f42c1;
}

.btn-purple:hover {
    background-color: #5a32a3;
    color: white;
}

.btn-outline-purple {
    border-color: #6f42c1;
    color: #6f42c1;
}

.btn-outline-purple:hover {
    background-color: #6f42c1;
    color: white;
}

.btn-danger {
    background-color: #ff416c;
    border-color: #ff416c;
}

.btn-danger:hover {
    background-color: #e02e57;
    border-color: #e02e57;
}

.form-control {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 16px;
    margin-bottom: 15px;
}

#loading {
    text-align: center;
    padding: 20px;
    font-size: 18px;
}

/* 提示框样式 */
.custom-toast {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translate(-50%, -20px);
    background-color: #28a745;
    color: white;
    padding: 15px 30px;
    border-radius: 8px;
    font-size: 16px;
    z-index: 99999;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    opacity: 0;
    transition: all 0.5s ease;
    text-align: center;
    min-width: 300px;
    max-width: 90%;
}

.custom-toast.error {
    background-color: #dc3545;
}

/* 新增样式 */
.stats-box {
    background-color: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-top: 30px;
}

.genre-card {
    transition: transform 0.3s, box-shadow 0.3s;
    background-color: #f8f9fa;
}

.genre-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.recent-box {
    background-color: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.progress {
    background-color: #e9ecef;
}

.recent-song-card {
    display: flex;
    align-items: center;
    background-color: #f8f9fa;
    border-radius: 8px;
    padding: 10px 15px;
    min-width: 250px;
    transition: background-color 0.3s;
    cursor: default;
}

.recent-song-card:hover {
    background-color: #e9ecef;
}

.recent-song-info {
    flex-grow: 1;
}

.recent-song-title {
    font-weight: bold;
    margin-bottom: 3px;
    color: #6f42c1;
}

.recent-song-artist {
    font-size: 0.9rem;
    color: #6c757d;
}

/* 直播相关样式 */
#liveButton, .live-card, #liveCard {
    position: relative;
    overflow: hidden;
}

#liveButton::after, .live-card::after, #liveCard::after {
    content: '';
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    background: radial-gradient(circle, rgba(255,0,0,0.4) 0%, rgba(255,0,0,0) 70%);
    border-radius: 50%;
    animation: pulse 2s infinite;
    z-index: -1;
}

.pulse-animation {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle, rgba(255,0,0,0.2) 0%, rgba(255,0,0,0) 70%);
    border-radius: 10px;
    animation: pulse 2s infinite;
    z-index: 0;
}

@keyframes pulse {
    0% {
        transform: scale(0.8);
        opacity: 0.7;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.3;
    }
    100% {
        transform: scale(0.8);
        opacity: 0.7;
    }
}

.animate-pulse {
    animation: pulse 1.5s infinite;
}

.live-card {
    background: linear-gradient(135deg, #ff416c, #ff4b2b);
    color: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
    margin-bottom: 20px;
}

.live-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.3);
}

.badge.bg-purple {
    background-color: #6f42c1;
}

/* 点歌时间样式 */
.recent-time {
    font-size: 0.8rem;
    color: #6c757d;
    margin-top: 3px;
}

/* 点歌规则框样式 */
.rules-box {
    background-color: #e6f7ff; /* 淡蓝色背景 */
    border: 1px solid #91d5ff; /* 边框 */
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.rules-box h3 {
    color: #1890ff; /* 标题蓝色 */
    margin-bottom: 15px;
    display: flex;
    align-items: center;
}

.rules-box h3 i {
    margin-right: 10px;
    font-size: 1.5rem;
}

.rules-box ul {
    list-style-type: disc; /* 圆点列表 */
    padding-left: 25px;
    margin-bottom: 0;
}

.rules-box ul li {
    margin-bottom: 8px;
    line-height: 1.6;
    color: #333;
}

/* 飘屏下雪特效 */
.floating-emoji {
    position: fixed;
    top: -50px; /* Start above the viewport */
    z-index: 9999;
    pointer-events: none;
    opacity: 0.8;
    color: #ffd700; /* Gold color */
    animation: floatDown linear infinite;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.5); /* Soft glow */
}

@keyframes floatDown {
    0% {
        transform: translate(var(--x-drift, 0), 0);
        opacity: 0;
    }
    5% {
        opacity: 0.8;
    }
    95% {
        opacity: 0.8;
    }
    100% {
        transform: translate(var(--x-drift, 0), calc(100vh + 50px)); /* End below the viewport */
        opacity: 0;
    }
}

/* 视频更新提示 */
.video-update-alert {
    position: fixed;
    bottom: 20px;
    right: 20px;
    max-width: 350px;
    z-index: 1000;
    animation: slideIn 0.5s ease-out;
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
    border-left: 4px solid #6f42c1;
}

@keyframes slideIn {
    from { transform: translateX(100%); }
    to { transform: translateX(0); }
}

.video-update-content {
    display: flex;
    align-items: center;
}

.video-thumbnail {
    width: 80px;
    height: 60px;
    border-radius: 5px;
    margin-right: 15px;
    background-color: #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
}

.video-thumbnail i {
    font-size: 24px;
    color: #6f42c1;
}

/* 移动端优化 */
@media (max-width: 768px) {
    .container {
        padding: 15px 10px;
    }
    
    h1 {
        font-size: 1.5rem;
    }
    
    .table th, .table td {
        padding: 8px 10px;
        font-size: 14px;
    }
    
    .custom-toast {
        min-width: 250px;
        padding: 12px 20px;
        font-size: 14px;
    }
    
    .stats-box > div {
        flex-direction: column;
        align-items: center;
    }
    
    .stats-box .d-flex > div {
        margin-bottom: 10px;
        width: 100%;
    }
    
    .recent-box {
        margin-top: 20px;
    }
    
    .navbar-collapse .d-flex {
        margin-top: 10px;
        width: 100%;
        justify-content: center;
    }
    
    .video-update-alert {
        bottom: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.3rem;
    }
    
    .btn-primary, .btn-danger, .btn-purple {
        width: 100%;
        padding: 12px;
        font-size: 15px;
    }
    
    .custom-toast {
        min-width: 200px;
        padding: 10px 15px;
        font-size: 13px;
    }
    
    .recent-song-card {
        width: 100%;
    }
    
    .live-card {
        padding: 15px;
    }
    
    .live-card .btn {
        width: 100%;
    }
}
