/* 基础样式和重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #8865bc;
    --primary-light: #a890cc;
    --primary-dark: #6a488c;
    --secondary-color: #f0ebf8;
    --text-color: #333;
    --light-text: #666;
    --lighter-text: #999;
    --white: #fff;
    --card-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    --hover-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

body {
    font-family: 'Helvetica Neue', Arial, sans-serif;
    background-color: #f8f7fa;
    color: #333;
    line-height: 1.6;
}

a {
    color: #5e35b1;
    text-decoration: none;
}

img {
    max-width: 100%;
}

/* 容器布局 */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 头部导航 */
header {
    background-color: #5e35b1;
    color: white;
    padding: 15px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header h1 {
    font-size: 1.5rem;
    font-weight: 600;
}

header h1 i {
    margin-right: 8px;
}

/* 头部右侧区域 */
.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

/* 导航菜单 */
nav ul {
    display: flex;
    list-style: none;
}

nav ul li {
    margin-left: 30px;
}

nav ul li a {
    color: white;
    opacity: 0.8;
    transition: opacity 0.3s;
    font-size: 0.95rem;
}

nav ul li a:hover,
nav ul li a.active {
    opacity: 1;
}

nav ul li a.active {
    position: relative;
}

nav ul li a.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: #ff4081;
}

/* 用户菜单样式 */
.user-menu {
    position: relative;
}

/* 未登录状态菜单 */
.guest-menu {
    display: flex;
    gap: 10px;
}

.login-btn, .register-btn {
    padding: 8px 15px;
    border-radius: 4px;
    transition: all 0.3s;
    font-size: 0.9rem;
}

.login-btn {
    color: white;
    background-color: transparent;
    border: 1px solid rgba(255, 255, 255, 0.5);
}

.login-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.register-btn {
    color: var(--primary-color);
    background-color: white;
}

.register-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* 已登录状态菜单 */
.logged-in-menu {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.user-avatar-small {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.2);
    transition: border-color 0.3s;
}

.user-avatar-small img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.logged-in-menu:hover .user-avatar-small {
    border-color: rgba(255, 255, 255, 0.5);
}

.user-dropdown {
    position: absolute;
    top: 45px;
    right: 0;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
    width: 140px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: 100;
    overflow: hidden;
}

.logged-in-menu:hover .user-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-dropdown a {
    display: block;
    padding: 12px 15px;
    color: var(--text-color);
    font-size: 14px;
    transition: background-color 0.3s;
}

.user-dropdown a:hover {
    background-color: #f5f5f5;
}

#logoutBtn {
    border-top: 1px solid #eee;
    color: #e74c3c;
}

#logoutBtn:hover {
    background-color: #ffeaea;
}

/* 移动端菜单切换按钮 */
.mobile-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
}

@media (max-width: 768px) {
    .mobile-toggle {
        display: block;
        position: absolute;
        top: 18px;
        right: 20px;
    }
    
    .header-right {
        flex-direction: column;
        align-items: flex-start;
        display: none;
        width: 100%;
    }
    
    .header-right.active {
        display: flex;
    }
    
    nav ul {
        flex-direction: column;
        width: 100%;
    }
    
    nav ul li {
        margin: 10px 0;
        width: 100%;
    }
    
    .user-menu {
        margin-top: 15px;
        width: 100%;
    }
    
    .guest-menu {
        justify-content: center;
    }
    
    .logged-in-menu {
        justify-content: center;
    }
    
    .user-dropdown {
        width: 180px;
        left: 50%;
        transform: translateX(-50%) translateY(10px);
    }
    
    .logged-in-menu:hover .user-dropdown {
        transform: translateX(-50%) translateY(0);
    }
}

/* 按钮样式 */
button {
    cursor: pointer;
    font-family: inherit;
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    background-color: #5e35b1;
    color: white;
    border-radius: 4px;
    border: none;
    transition: background-color 0.3s;
}

.btn:hover {
    background-color: #4a278e;
}

.btn-secondary {
    background-color: #ff4081;
}

.btn-secondary:hover {
    background-color: #e6337a;
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.5s ease forwards;
}

/* 响应式设计 - 通用部分 */
@media (max-width: 768px) {
    header .container {
        flex-direction: column;
    }
    
    header h1 {
        margin-bottom: 15px;
    }
    
    nav ul li {
        margin-left: 15px;
        margin-right: 15px;
    }
}

@media (max-width: 480px) {
    nav ul {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    nav ul li {
        margin: 5px 10px;
    }
}

/* 英雄区样式 */
.hero {
    background: linear-gradient(to right, var(--primary-color), var(--primary-dark));
    color: var(--white);
    padding: 60px 0;
    text-align: center;
}

.hero h2 {
    font-size: 2.5rem;
    margin-bottom: 15px;
    font-weight: 700;
}

.hero p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto;
    opacity: 0.9;
}

/* 内容区域通用样式 */
section {
    padding: 60px 0;
}

.section-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 30px;
    position: relative;
    padding-left: 20px;
}

.section-title:before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    height: 70%;
    width: 5px;
    background-color: var(--primary-color);
    border-radius: 3px;
}

/* 推荐区样式 */
.featured {
    background-color: var(--white);
}

.featured-card {
    padding: 25px;
    border-radius: 10px;
    box-shadow: var(--card-shadow);
    background-color: var(--white);
    transition: box-shadow 0.3s, transform 0.3s;
    position: relative;
    border: 1px solid #f0f0f0;
    overflow: hidden;
}

.featured-card:before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(to right, var(--primary-color), var(--primary-light));
}

.featured-card:hover {
    box-shadow: var(--hover-shadow);
    transform: translateY(-5px);
}

/* 评论卡片样式 */
.comment-card {
    padding: 20px;
    border-radius: 10px;
    box-shadow: var(--card-shadow);
    background-color: var(--white);
    margin-bottom: 25px;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.comment-card:hover {
    box-shadow: var(--hover-shadow);
    transform: translateY(-5px);
}

.song-info {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.song-cover {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

.song-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.play-button {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
    cursor: pointer;
}

.play-button i {
    color: var(--white);
    font-size: 1.8rem;
}

.song-cover:hover .play-button {
    opacity: 1;
}

.song-details {
    margin-left: 15px;
}

.song-details h3 {
    font-size: 1.2rem;
    margin-bottom: 5px;
    color: var(--primary-dark);
}

.song-details p {
    font-size: 0.9rem;
    color: var(--light-text);
}

.comment-content {
    position: relative;
}

.comment-text {
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 15px;
    position: relative;
    padding-left: 15px;
    font-style: italic;
    color: var(--text-color);
}

.comment-text:before {
    content: """;
    position: absolute;
    top: -5px;
    left: -5px;
    font-size: 2rem;
    color: var(--primary-light);
    font-family: serif;
}

.comment-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    padding-top: 15px;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.user-info {
    display: flex;
    align-items: center;
}

.user-info img {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    margin-right: 10px;
}

.username {
    font-weight: 600;
    margin-right: 8px;
}

.location {
    color: var(--lighter-text);
    font-size: 0.8rem;
}

.comment-stats {
    display: flex;
    align-items: center;
    gap: 15px;
    color: var(--light-text);
}

.date {
    color: var(--lighter-text);
}

.likes {
    display: flex;
    align-items: center;
    color: #ff4d6d;
}

.likes i {
    margin-right: 5px;
}

.source {
    background-color: var(--secondary-color);
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    color: var(--primary-color);
}

/* 评论列表样式 */
.cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
}

.view-all-btn {
    display: inline-block;
    padding: 10px 25px;
    background: #5e35b1;
    color: white;
    border-radius: 25px;
    text-decoration: none;
    transition: background 0.3s;
    font-weight: 500;
    margin-top: 20px;
}

.view-all-btn:hover {
    background: #4a148c;
}

.view-all-btn i {
    margin-left: 5px;
    transition: transform 0.3s;
}

.view-all-btn:hover i {
    transform: translateX(3px);
}

/* 页脚样式 - 简化版 */
footer {
    background-color: #292639;
    color: #b5b3c0;
    padding: 30px 0;
    position: relative;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-light));
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 40px;
    margin-bottom: 30px;
}

.footer-logo {
    padding-right: 20px;
}

.footer-logo h2 {
    color: var(--white);
    font-size: 1.5rem;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
}

.footer-logo h2 i {
    margin-right: 10px;
    color: var(--primary-light);
}

.footer-logo p {
    opacity: 0.8;
    margin-bottom: 20px;
    line-height: 1.5;
}

.social-icons {
    display: flex;
    gap: 12px;
    margin-top: 15px;
}

.social-icons a {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.social-icons a i {
    color: var(--white);
    font-size: 1.2rem;
}

.social-icons a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(94, 53, 177, 0.3);
}

.footer-links-wrapper {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.footer-links-column h3 {
    color: var(--white);
    margin-bottom: 18px;
    font-size: 1.1rem;
    position: relative;
    padding-bottom: 10px;
}

.footer-links-column h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 30px;
    height: 2px;
    background: var(--primary-light);
}

.footer-links-column ul {
    list-style: none;
    padding: 0;
}

.footer-links-column ul li {
    margin-bottom: 10px;
}

.footer-links-column ul li a {
    color: #b5b3c0;
    transition: all 0.3s;
    position: relative;
    display: inline-block;
}

.footer-links-column ul li a:hover {
    color: var(--primary-light);
}

.footer-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    margin-bottom: 20px;
}

.footer-bottom {
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.footer-bottom p {
    font-size: 0.9rem;
}

/* 圆形悬浮返回顶部按钮 */
.back-to-top-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    z-index: 99;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.back-to-top-float a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    color: var(--white);
    font-size: 1.2rem;
}

.back-to-top-float:hover {
    background-color: var(--primary-dark);
    transform: translateY(-5px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

/* 响应式页脚样式 */
@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr;
    }
    
    .footer-logo {
        text-align: center;
        padding-right: 0;
        margin-bottom: 20px;
    }
    
    .footer-logo h2 {
        justify-content: center;
    }
    
    .social-icons {
        justify-content: center;
    }
    
    .back-to-top-float {
        width: 45px;
        height: 45px;
        bottom: 20px;
        right: 20px;
    }
}

@media (max-width: 576px) {
    .footer-links-wrapper {
        grid-template-columns: 1fr;
    }
    
    .footer-links-column h3 {
        text-align: center;
    }
    
    .footer-links-column h3::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .footer-links-column ul {
        text-align: center;
    }
    
    .back-to-top-float {
        width: 40px;
        height: 40px;
        bottom: 15px;
        right: 15px;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.comment-card {
    animation: fadeIn 0.6s ease-out forwards;
}

.login-btn, .register-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 6px 15px;
    border-radius: 20px;
    color: white;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 14px;
    display: inline-block;
    text-decoration: none;
}

.login-btn:hover, .register-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.register-btn {
    background: var(--accent-color);
    border-color: var(--accent-color);
}

.register-btn:hover {
    background: var(--accent-dark);
} 