/* 基础样式 */
:root {
    --primary-color: #4a6baf;
    --secondary-color: #6c757d;
    --accent-color: #f8c630;
    --text-color: #333;
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --success-color: #28a745;
    --info-color: #17a2b8;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --border-radius: 8px;
    --box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'PingFang SC', 'Microsoft YaHei', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #f9f9f9;
    overflow-x: hidden;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: var(--transition);
}

a:hover {
    color: var(--accent-color);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

button {
    cursor: pointer;
    border: none;
    outline: none;
    transition: var(--transition);
}

.section {
    padding: 80px 0;
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 50px;
    position: relative;
    color: var(--primary-color);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--accent-color);
    border-radius: 2px;
}

.highlight {
    color: var(--primary-color);
    font-weight: 700;
}

/* 加载动画 */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.preloader.hide {
    opacity: 0;
    visibility: hidden;
}

.loader {
    text-align: center;
}

#loader-circle {
    fill: none;
    stroke: var(--primary-color);
    stroke-width: 4;
    stroke-dasharray: 150, 200;
    stroke-dashoffset: 0;
    stroke-linecap: round;
    animation: loader 2s ease-in-out infinite;
}

@keyframes loader {
    0% {
        stroke-dasharray: 1, 200;
        stroke-dashoffset: 0;
    }
    50% {
        stroke-dasharray: 89, 200;
        stroke-dashoffset: -35;
    }
    100% {
        stroke-dasharray: 89, 200;
        stroke-dashoffset: -124;
    }
}

.loading-text {
    margin-top: 20px;
    font-size: 18px;
    color: var(--primary-color);
}

/* 背景音乐控制 */
.music-control {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 100;
}

.music-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.music-btn:hover {
    transform: scale(1.1);
    background-color: var(--accent-color);
}

.music-btn i {
    font-size: 20px;
}

/* 导航栏 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: var(--transition);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 30px;
}

.nav-links a {
    color: var(--dark-color);
    font-size: 1.1rem;
    font-weight: 500;
    padding: 8px 0;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: var(--transition);
}

.nav-links a:hover::after {
    width: 100%;
}

.burger {
    display: none;
    cursor: pointer;
}

.burger div {
    width: 25px;
    height: 3px;
    background-color: var(--dark-color);
    margin: 5px;
    transition: var(--transition);
}

/* 头部区域 */
.hero {
    height: 100vh;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('../assets/hero-bg.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: #fff;
}

.hero h1 {
    font-size: 4rem;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero p {
    font-size: 1.5rem;
    max-width: 700px;
    margin: 0 auto;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.fade-in {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeIn 1s forwards;
}

@keyframes fadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero p {
    animation-delay: 0.5s;
}

/* 关于我 */
.about-content {
    display: flex;
    align-items: center;
    gap: 50px;
}

.about-img {
    flex: 1;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
}

.about-img img {
    transition: var(--transition);
}

.about-img:hover img {
    transform: scale(1.05);
}

.about-text {
    flex: 1;
}

.about-text h3 {
    font-size: 2rem;
    margin-bottom: 20px;
}

.about-text p {
    margin-bottom: 30px;
    color: var(--secondary-color);
    font-size: 1.1rem;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--light-color);
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--primary-color);
    transition: var(--transition);
}

.social-links a:hover {
    background-color: var(--primary-color);
    color: #fff;
    transform: translateY(-5px);
}

/* 作品展示 - 选项卡 */
.tabs {
    margin-top: 30px;
}

.tab-header {
    display: flex;
    justify-content: center;
    margin-bottom: 40px;
}

.tab-btn {
    padding: 12px 30px;
    background-color: var(--light-color);
    color: var(--secondary-color);
    font-size: 1.1rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    border-radius: var(--border-radius);
    margin: 0 10px;
}

.tab-btn.active {
    background-color: var(--primary-color);
    color: #fff;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

/* 文章卡片 */
.article-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.article-card {
    background-color: #fff;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.article-card:hover {
    transform: translateY(-10px);
}

.article-img {
    height: 200px;
    overflow: hidden;
}

.article-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.article-card:hover .article-img img {
    transform: scale(1.1);
}

.article-info {
    padding: 20px;
}

.article-info h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.article-excerpt {
    color: var(--secondary-color);
    margin-bottom: 15px;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    color: var(--secondary-color);
    font-size: 0.9rem;
    margin-bottom: 15px;
}

.read-more {
    display: inline-block;
    padding: 8px 20px;
    background-color: var(--primary-color);
    color: #fff;
    border-radius: 30px;
    font-size: 0.9rem;
    transition: var(--transition);
}

.read-more:hover {
    background-color: var(--accent-color);
    color: var(--dark-color);
}

/* 音乐卡片 */
.music-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.music-card {
    background-color: #fff;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.music-card:hover {
    transform: translateY(-10px);
}

.music-cover {
    height: 200px;
    position: relative;
    overflow: hidden;
}

.music-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: var(--transition);
}

.play-overlay i {
    color: #fff;
    font-size: 3rem;
}

.music-cover:hover .play-overlay {
    opacity: 1;
}

.music-cover:hover img {
    transform: scale(1.1);
}

.music-info {
    padding: 20px;
}

.music-info h3 {
    font-size: 1.5rem;
    margin-bottom: 5px;
}

.music-artist {
    color: var(--secondary-color);
    margin-bottom: 15px;
}

.music-player {
    margin-top: 15px;
}

.music-player audio {
    width: 100%;
}

/* 视频卡片 */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 30px;
}

.video-card {
    background-color: #fff;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.video-card:hover {
    transform: translateY(-10px);
}

.video-player {
    position: relative;
    padding-top: 56.25%; /* 16:9 比例 */
}

.video-player video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-info {
    padding: 20px;
}

.video-info h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.video-desc {
    color: var(--secondary-color);
    margin-bottom: 15px;
}

.video-meta {
    display: flex;
    justify-content: space-between;
    color: var(--secondary-color);
    font-size: 0.9rem;
}

/* 点赞和评论区 */
.interaction {
    padding: 20px;
    border-top: 1px solid #eee;
}

.like-section {
    margin-bottom: 20px;
}

.like-btn {
    background-color: transparent;
    color: var(--secondary-color);
    font-size: 1rem;
    padding: 5px 15px;
    border: 1px solid #eee;
    border-radius: 30px;
    transition: var(--transition);
}

.like-btn:hover, .like-btn.active {
    background-color: #ffecec;
    color: #ff4d4d;
    border-color: #ffcaca;
}

.like-btn.active i {
    color: #ff4d4d;
}

.comments h4 {
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.comment {
    display: flex;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.comment-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    margin-right: 15px;
}

.comment-content {
    flex: 1;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
}

.comment-author {
    font-weight: 500;
    color: var(--dark-color);
}

.comment-date {
    font-size: 0.8rem;
    color: var(--secondary-color);
}

.add-comment textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #eee;
    border-radius: var(--border-radius);
    resize: none;
    height: 80px;
    margin-bottom: 10px;
    font-family: inherit;
}

.comment-btn {
    background-color: var(--primary-color);
    color: #fff;
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 0.9rem;
}

.comment-btn:hover {
    background-color: var(--accent-color);
    color: var(--dark-color);
}

/* 图片轮播 */
.gallery {
    background-color: #f0f3f7;
}

.swiper {
    width: 100%;
    height: 500px;
    border-radius: var(--border-radius);
    overflow: hidden;
}

.swiper-slide {
    display: flex;
    justify-content: center;
    align-items: center;
}

.swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.swiper-pagination-bullet-active {
    background-color: var(--primary-color);
}

.swiper-button-next,
.swiper-button-prev {
    color: var(--primary-color);
}

/* 联系我 */
.contact-content {
    display: flex;
    gap: 50px;
}

.contact-info {
    flex: 1;
}

.contact-item {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
}

.contact-item i {
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    color: #fff;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    margin-right: 20px;
}

.contact-item p {
    font-size: 1.1rem;
}

.contact-form {
    flex: 1;
    background-color: #fff;
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.contact-form h3 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.form-group {
    margin-bottom: 20px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #eee;
    border-radius: var(--border-radius);
    font-family: inherit;
    font-size: 1rem;
}

.form-group textarea {
    height: 150px;
    resize: none;
}

.submit-btn {
    background-color: var(--primary-color);
    color: #fff;
    padding: 12px 30px;
    border-radius: 30px;
    font-size: 1rem;
    font-weight: 500;
    transition: var(--transition);
}

.submit-btn:hover {
    background-color: var(--accent-color);
    color: var(--dark-color);
}

/* 页脚 */
.footer {
    background-color: var(--dark-color);
    color: #fff;
    padding: 60px 0 30px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
}

.footer-logo h3 {
    font-size: 1.8rem;
    margin-bottom: 15px;
}

.footer-logo p {
    color: rgba(255, 255, 255, 0.7);
}

.footer-links h4,
.footer-social h4 {
    font-size: 1.2rem;
    margin-bottom: 20px;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--accent-color);
}

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: center;
    align-items: center;
    color: #fff;
    transition: var(--transition);
}

.social-icons a:hover {
    background-color: var(--accent-color);
    transform: translateY(-5px);
}

/* 回到顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: var(--box-shadow);
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--accent-color);
    transform: translateY(-5px);
}

/* 响应式设计 */
@media screen and (max-width: 992px) {
    .section-title {
        font-size: 2rem;
    }
    
    .about-content {
        flex-direction: column;
    }
    
    .contact-content {
        flex-direction: column;
    }
    
    .swiper {
        height: 400px;
    }
}

@media screen and (max-width: 768px) {
    .navbar .container {
        height: 70px;
    }
    
    .nav-links {
        position: absolute;
        top: 70px;
        right: 0;
        width: 60%;
        height: calc(100vh - 70px);
        background-color: #fff;
        flex-direction: column;
        align-items: center;
        justify-content: flex-start;
        padding-top: 50px;
        transform: translateX(100%);
        transition: transform 0.5s ease;
        box-shadow: -5px 0 10px rgba(0, 0, 0, 0.1);
    }
    
    .nav-links.active {
        transform: translateX(0);
    }
    
    .nav-links li {
        margin: 20px 0;
    }
    
    .burger {
        display: block;
    }
    
    .burger.active .line1 {
        transform: rotate(-45deg) translate(-5px, 6px);
    }
    
    .burger.active .line2 {
        opacity: 0;
    }
    
    .burger.active .line3 {
        transform: rotate(45deg) translate(-5px, -6px);
    }
    
    .hero h1 {
        font-size: 3rem;
    }
    
    .hero p {
        font-size: 1.2rem;
    }
    
    .article-grid,
    .music-grid,
    .video-grid {
        grid-template-columns: 1fr;
    }
    
    .swiper {
        height: 300px;
    }
    
    .footer-content {
        flex-direction: column;
    }
} 