/* 全局变量 */
:root {
    /* 浅色主题 */
    --primary-color: #007AFF;
    --secondary-color: #5856D6;
    --accent-color: #FF2D92;
    --background: #F2F2F7;
    --surface: rgba(255, 255, 255, 0.8);
    --surface-hover: rgba(255, 255, 255, 0.9);
    --text-primary: #1D1D1F;
    --text-secondary: #86868B;
    --text-tertiary: #C7C7CC;
    --border: rgba(0, 0, 0, 0.1);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 16px 48px rgba(0, 0, 0, 0.15);
    --blur: blur(20px);
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-secondary: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --gradient-accent: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --gradient-skill-1: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-skill-2: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --gradient-skill-3: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --gradient-skill-4: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    --gradient-skill-5: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
    --gradient-skill-6: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%);
}

/* 深色主题 */
[data-theme="dark"] {
    --background: #000000;
    --surface: rgba(28, 28, 30, 0.8);
    --surface-hover: rgba(28, 28, 30, 0.9);
    --text-primary: #FFFFFF;
    --text-secondary: #8E8E93;
    --text-tertiary: #3A3A3C;
    --border: rgba(255, 255, 255, 0.1);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    --shadow-hover: 0 16px 48px rgba(0, 0, 0, 0.4);
}

/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    /* 优化移动端字体渲染 */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    /* 防止文字大小在旋转设备时调整 */
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

/* 优化移动端滚动行为 */
* {
    -webkit-overflow-scrolling: touch;
}

/* 防止图片在移动设备上溢出容器 */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* 确保所有内容在移动设备上正确显示 */
body {
    min-height: 100vh;
    overflow-x: hidden;
}

/* 使用相对单位实现更流畅的响应式缩放 */
@media (max-width: 768px) {
    html {
        font-size: 15px;
    }
}

@media (max-width: 480px) {
    html {
        font-size: 14px;
    }
    
    /* 优化小屏幕设备上的触摸目标 */
    a, button, .clickable {
        min-height: 44px;
        min-width: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

@media (max-width: 360px) {
    html {
        font-size: 13px;
    }
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--background);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* 容器 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 按钮样式 */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    background: var(--surface);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--shadow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.btn-secondary {
    background: var(--surface);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--surface-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

/* 导航栏 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    transition: all 0.3s ease;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.nav-logo .logo-text {
    font-size: 24px;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 40px;
    margin: 0;
}

.nav-link {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    position: relative;
    transition: color 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: width 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

/* 下拉菜单样式 */
.nav-item.has-dropdown {
    position: relative;
}

.nav-item.has-dropdown:hover .dropdown-content {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-content {
    position: absolute;
    top: calc(100% + 5px);
    left: 0;
    min-width: 160px;
    background: var(--surface);
    -webkit-backdrop-filter: var(--blur);
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 8px 0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1), 0 1px 8px rgba(0, 0, 0, 0.06);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    list-style: none;
    margin: 0;
    overflow: hidden;
}

.dropdown-content li {
    width: 100%;
    position: relative;
}

.dropdown-content .nav-link {
    display: block;
    padding: 12px 24px;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.25s ease;
    border-radius: 0;
    position: relative;
    overflow: hidden;
}

.dropdown-content .nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.05), transparent);
    transition: all 0.5s ease;
}

.dropdown-content .nav-link:hover {
    background: var(--surface-hover);
    color: var(--text-primary);
    padding-left: 30px;
}

.dropdown-content .nav-link:hover::before {
    left: 100%;
}

/* 主题切换按钮 */
.theme-toggle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--surface);
    -webkit-backdrop-filter: var(--blur);
    backdrop-filter: var(--blur);
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow);
}

.theme-toggle:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-hover);
}

.theme-toggle i {
    font-size: 20px;
    color: var(--text-primary);
    transition: transform 0.3s ease;
}

.theme-toggle:hover i {
    transform: rotate(180deg);
}

/* 隐私政策页面样式 */
.privacy-section {
    padding: 80px 0;
    position: relative;
}

.privacy-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 10% 20%, rgba(255, 107, 107, 0.1) 0%, rgba(255, 107, 107, 0) 90%);
    z-index: -1;
}

.privacy-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
    position: relative;
    z-index: 1;
}

.privacy-card {
    background: var(--surface);
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 40px;
    box-shadow: var(--shadow);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.privacy-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.6s ease;
}

.privacy-card:hover::before {
    left: 100%;
}

.privacy-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
}

.privacy-card h3 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--text-primary);
    position: relative;
}

.privacy-card h3::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--gradient-primary);
    border-radius: 2px;
}

.privacy-card p {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.8;
    text-align: justify;
}

.privacy-card ul {
    list-style: none;
    padding-left: 20px;
}

.privacy-card li {
    position: relative;
    margin-bottom: 10px;
    color: var(--text-secondary);
}

.privacy-card li::before {
    content: '•';
    position: absolute;
    left: -20px;
    color: var(--primary);
    font-weight: bold;
}

/* 头像样式 */
.avatar-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

/* 音乐播放器 */
.music-player {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 1000;
}

.music-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--gradient-primary);
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow);
    color: white;
    font-size: 20px;
}

.music-toggle:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-hover);
}

.music-panel {
    position: absolute;
    bottom: 80px;
    left: 0;
    width: 300px;
    background: var(--surface);
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 20px;
    box-shadow: var(--shadow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.music-panel.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.music-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.music-header h3 {
    color: var(--text-primary);
    font-size: 18px;
    font-weight: 600;
}

.close-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 16px;
    transition: color 0.3s ease;
}

.close-btn:hover {
    color: var(--text-primary);
}

.music-controls {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 20px;
}

.control-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--surface);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text-primary);
}

.control-btn:hover {
    background: var(--surface-hover);
    transform: scale(1.1);
}

.play-btn {
    background: var(--gradient-primary);
    color: white;
}

.music-info {
    text-align: center;
    margin-bottom: 15px;
}

.song-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 5px;
}

.song-artist {
    font-size: 14px;
    color: var(--text-secondary);
}

.music-progress {
    margin-bottom: 20px;
}

.progress-bar {
    width: 100%;
    height: 4px;
    background: var(--border);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: var(--gradient-primary);
    width: 0%;
    transition: width 0.1s ease;
}

.time-display {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--text-secondary);
}

.music-list {
    max-height: 150px;
    overflow-y: auto;
}

.song-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s ease;
    margin-bottom: 5px;
}

.song-item:hover {
    background: var(--surface-hover);
}

.song-item.active {
    background: var(--gradient-primary);
    color: white;
}

.song-name {
    font-weight: 500;
}

.song-duration {
    font-size: 12px;
    opacity: 0.8;
}

/* 主要内容 */
.main-content {
    margin-top: 70px;
}

.section {
    padding: 100px 0;
    position: relative;
}

.section-header {
    text-align: center;
    margin-bottom: 80px;
}

.section-title {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 20px;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    font-size: 18px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* 首页部分 */
.home-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.home-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.3) 0%, transparent 50%);
    pointer-events: none;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.hero-title {
    font-size: 64px;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 30px;
}

.title-line {
    display: block;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease forwards;
}

.title-line:nth-child(2) {
    animation-delay: 0.2s;
}

.highlight {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 24px;
    color: var(--text-secondary);
    margin-bottom: 30px;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease forwards 0.4s;
}

.hero-description {
    margin-bottom: 40px;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease forwards 0.6s;
}

.hero-description p {
    font-size: 18px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.hero-actions {
    display: flex;
    gap: 20px;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease forwards 0.8s;
}

.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.floating-card {
    background: var(--surface);
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 40px;
    box-shadow: var(--shadow);
    animation: float 6s ease-in-out infinite;
}

.card-content {
    text-align: center;
}

.avatar {
    margin-bottom: 30px;
}

.avatar-circle {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    font-size: 48px;
    color: white;
}

.stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.stat-item {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 32px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 5px;
}

.stat-label {
    font-size: 14px;
    color: var(--text-secondary);
}

/* 关于部分 - 美化 */
.about-section {
    position: relative;
    overflow: hidden;
}

.about-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 400px;
    height: 400px;
    background: var(--gradient-secondary);
    border-radius: 50%;
    opacity: 0.1;
    animation: float 8s ease-in-out infinite;
}

.about-section::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 300px;
    height: 300px;
    background: var(--gradient-accent);
    border-radius: 50%;
    opacity: 0.1;
    animation: float 6s ease-in-out infinite reverse;
}

.about-content {
    display: flex;
    flex-direction: column;
    gap: 100px;
    position: relative;
    z-index: 1;
}

.about-card,
.skills-card {
    background: var(--surface);
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 50px;
    box-shadow: var(--shadow);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    margin-bottom: 50px;
}

.about-card::before,
.skills-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.6s ease;
}

.about-card:hover::before,
.skills-card:hover::before {
    left: 100%;
}

.about-card:hover,
.skills-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: var(--shadow-hover);
}

.about-card h3,
.skills-card h3 {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 25px;
    color: var(--text-primary);
    position: relative;
}

.about-card h3::after,
.skills-card h3::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--gradient-primary);
    border-radius: 2px;
}

.about-card p {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 20px;
    text-align: justify;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
}

.skill-item {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 25px;
    background: var(--surface-hover);
    border-radius: 16px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    border: 1px solid var(--border);
}

.skill-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--gradient-primary);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.skill-item:hover::before {
    transform: scaleY(1);
}

.skill-item:nth-child(1) .skill-icon {
    background: var(--gradient-skill-1);
}

.skill-item:nth-child(2) .skill-icon {
    background: var(--gradient-skill-2);
}

.skill-item:nth-child(3) .skill-icon {
    background: var(--gradient-skill-3);
}

.skill-item:nth-child(4) .skill-icon {
    background: var(--gradient-skill-4);
}

.skill-item:nth-child(5) .skill-icon {
    background: var(--gradient-skill-5);
}

.skill-item:nth-child(6) .skill-icon {
    background: var(--gradient-skill-6);
}

.skill-item:hover {
    transform: translateX(10px) translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.skill-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.skill-item:hover .skill-icon {
    transform: scale(1.1) rotate(5deg);
}

.skill-info h4 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.skill-info p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* 项目部分 - 美化 */
.projects-section {
    position: relative;
    overflow: hidden;
}

.projects-section::before {
    content: '';
    position: absolute;
    top: 20%;
    right: -10%;
    width: 200px;
    height: 200px;
    background: var(--gradient-accent);
    border-radius: 50%;
    opacity: 0.1;
    animation: float 10s ease-in-out infinite;
}

/* 项目筛选器 */
.project-filters {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 50px;
    flex-wrap: wrap;
}

.filter-btn {
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    padding: 12px 24px;
    border-radius: 25px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    position: relative;
    overflow: hidden;
}

.filter-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.filter-btn:hover::before {
    left: 100%;
}

.filter-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.filter-btn.active {
    background: var(--gradient-primary);
    color: white;
    border-color: transparent;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 40px;
    position: relative;
    z-index: 1;
    margin-bottom: 60px;
}

.project-card {
    background: var(--surface);
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    border-radius: 24px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow);
    position: relative;
    opacity: 1;
    transform: scale(1);
}

.project-card.hidden {
    opacity: 0;
    transform: scale(0.8);
    pointer-events: none;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.project-card:hover::before {
    transform: scaleX(1);
}

.project-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: var(--shadow-hover);
}

.project-image {
    height: 200px;
    background: var(--gradient-secondary);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.project-icon {
    font-size: 48px;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.project-card:hover .project-icon {
    transform: scale(1.1) rotate(5deg);
}

.project-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.1) 50%, transparent 70%);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.project-card:hover .project-image::before {
    transform: translateX(100%);
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s ease;
    -webkit-backdrop-filter: var(--blur(5px));
    /* 兼容 Safari */
    backdrop-filter: blur(5px);
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.overlay-content {
    text-align: center;
    color: white;
}

.project-links {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    justify-content: center;
}

.project-link {
    background: rgba(255, 255, 255, 0.9);
    color: var(--text-primary);
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    -webkit-backdrop-filter: var(--blur(10px));
    /* 兼容 Safari */
    backdrop-filter: blur(10px);
}

.project-link:hover {
    background: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.project-status {
    margin-top: 15px;
}

.status-badge {
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-badge.completed {
    background: linear-gradient(135deg, #43e97b, #38f9d7);
    color: white;
}

.status-badge.in-progress {
    background: linear-gradient(135deg, #fa709a, #fee140);
    color: white;
}

.project-info {
    padding: 30px;
}

.project-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.project-header h3 {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    position: relative;
}

.project-header h3::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--gradient-primary);
    border-radius: 1px;
}

.project-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 5px;
}

.project-date {
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 500;
}

.project-type {
    font-size: 11px;
    color: var(--primary-color);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.project-description {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 20px;
    text-align: justify;
}

.project-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.feature {
    background: rgba(102, 126, 234, 0.1);
    color: var(--primary-color);
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    border: 1px solid rgba(102, 126, 234, 0.2);
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag {
    background: var(--gradient-accent);
    color: white;
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 11px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.tag:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* 项目统计 */
.project-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 30px;
    margin-top: 60px;
    padding: 40px;
    background: var(--surface);
    border-radius: 24px;
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.project-stats .stat-item {
    text-align: center;
    padding: 20px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.project-stats .stat-item:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.1);
}

.project-stats .stat-number {
    display: block;
    font-size: 36px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 8px;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.project-stats .stat-label {
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* 联系部分 */
.contact-content-simple {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
    max-width: 600px;
    margin: 0 auto;
}

.contact-links {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
}

.contact-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 20px;
    background: var(--surface);
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text-primary);
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
}

.contact-link:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
    border-color: var(--primary-color);
}

.contact-link i {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
}

.contact-link span {
    font-size: 16px;
    color: var(--text-secondary);
}



/* 页脚 */
.footer {
    background: var(--surface);
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    border-top: 1px solid var(--border);
    padding: 40px 0;
    margin-top: 100px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-info p {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 5px;
}

.footer-links {
    display: flex;
    gap: 20px;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--text-primary);
}

/* 动画 */
@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* 移动菜单按钮 - 默认隐藏 */
.mobile-menu-btn {
    display: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--surface);
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow);
    z-index: 1002;
}

.mobile-menu-btn i {
    font-size: 20px;
    color: var(--text-primary);
}

/* 响应式设计 */
@media (max-width: 768px) {

    /* 移动菜单按钮显示 */
    .mobile-menu-btn {
        display: flex;
    }

    /* 桌面版导航隐藏 */
    .nav-right {
        display: none;
    }

    /* 移动端展开导航菜单样式 */
    .nav-right.active {
        display: flex;
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: var(--surface);
        -webkit-backdrop-filter: var(--blur);
        /* 兼容 Safari */
        backdrop-filter: var(--blur);
        border-bottom: 1px solid var(--border);
        padding: 20px;
        z-index: 1000;
        flex-direction: column;
        align-items: center;
        gap: 20px;
        box-shadow: var(--shadow);
    }

    .nav-right.active .nav-menu {
        flex-direction: column;
        align-items: center;
        gap: 20px;
        width: 100%;
        text-align: center;
    }

    .nav-right.active .nav-item {
        width: 100%;
    }

    .nav-right.active .nav-link {
        display: block;
        padding: 12px 20px;
        border-radius: 12px;
        transition: all 0.3s ease;
    }

    .nav-right.active .nav-link:hover {
        background: var(--surface-hover);
    }

    /* 适配6.8英寸屏幕的内容调整 */
    .hero-content {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
        padding: 0 20px;
    }

    .hero-title {
        font-size: 36px;
        line-height: 1.2;
    }

    .hero-actions {
        justify-content: center;
        flex-direction: column;
        gap: 15px;
    }

    .btn {
        padding: 12px 24px;
        font-size: 16px;
        width: 100%;
        max-width: 280px;
        margin: 0 auto;
    }

    .contact-content {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 0 20px;
    }

    .projects-simple {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 0 10px;
    }

    .project-item {
        padding: 20px;
        gap: 15px;
        /* 确保在移动设备上可点击区域足够大 */
        min-height: 100px;
        display: flex;
        align-items: center;
        justify-content: space-between;
    }

    .project-main {
        flex: 1;
        min-width: 0;
    }

    /* 确保项目描述在小屏幕上不会溢出 */
    .project-desc {
        overflow: hidden;
        text-overflow: ellipsis;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        line-clamp: 2;
        -webkit-box-orient: vertical;
    }

    .skills-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .footer-content {
        flex-direction: column;
        gap: 20px;
        text-align: center;
        padding: 0 20px;
    }

    .music-panel {
        width: 260px;
        left: -100px;
    }

    .about-card,
    .skills-card {
        padding: 25px;
        margin: 0 15px;
    }

    .section-title {
        font-size: 28px;
        text-align: center;
        margin-bottom: 25px;
    }

    .container {
        padding: 0 15px;
    }

    .section {
        padding: 60px 0;
    }

    .project-info {
        padding: 25px;
    }
}

@media (max-width: 480px) {

    /* 进一步优化小屏幕显示 */
    .container {
        padding: 0 15px;
    }

    .section {
        padding: 50px 0;
    }

    .hero-title {
        font-size: 32px;
        line-height: 1.3;
    }

    .section-title {
        font-size: 26px;
    }

    .hero-desc {
        font-size: 16px;
        line-height: 1.6;
    }

    .nav-logo .logo-text {
        font-size: 20px;
    }

    .project-icon {
        width: 50px;
        height: 50px;
        font-size: 20px;
        /* 减小图标圆角以适应小屏幕 */
        border-radius: 12px;
    }

    .project-main h3 {
        font-size: 16px;
        margin-bottom: 4px;
    }

    .project-desc {
        font-size: 14px;
        line-height: 1.4;
    }

    /* 为触摸设备优化项目卡片的点击效果 */
    .project-item:active {
        transform: scale(0.98);
        transition: transform 0.1s ease;
    }

    /* 确保状态徽章在小屏幕上位置合适 */
    .status-badge {
        padding: 2px 8px;
        font-size: 12px;
        border-radius: 10px;
    }

    /* 调整项目列表在超小屏幕上的内边距 */
    .projects-simple {
        padding: 0 8px;
        gap: 15px;
    }

    .project-item {
        padding: 16px;
        gap: 12px;
    }

    .music-panel {
        width: 90vw;
        max-width: 300px;
        left: 50%;
        transform: translateX(-50%);
    }

    .btn {
        padding: 10px 20px;
        font-size: 15px;
        max-width: 250px;
    }

    /* 确保触摸目标足够大 */
    .theme-toggle {
        width: 48px;
        height: 48px;
    }

    .mobile-menu-btn {
        width: 48px;
        height: 48px;
    }

    /* 增加所有点击元素的触摸区域 */
    a,
    button,
    .clickable {
        touch-action: manipulation;
        -webkit-tap-highlight-color: transparent;
    }

    /* 优化项目卡片布局 */
    .project-item {
        padding: 15px;
        gap: 12px;
        flex-direction: column;
        text-align: center;
    }

    /* 简化音乐播放器显示 */
    .music-toggle {
        width: 50px;
        height: 50px;
    }
}

/* 矩形包裹容器 */
.projects-container {
    background: var(--surface);
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 30px;
    box-shadow: var(--shadow);
    margin-bottom: 40px;
}

/* 简化的项目列表 - 与技能专长样式一致，改为一排三个网格布局 */
.projects-simple {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
}

.project-item {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 20px;
    padding: 25px;
    background: var(--surface-hover);
    border-radius: 16px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    border: 1px solid var(--border);
    margin-bottom: 15px;
    box-shadow: var(--shadow);
}

.project-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--gradient-primary);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.project-item:hover::before {
    transform: scaleY(1);
}

.project-item:hover {
    transform: translateX(10px) translateY(-5px);
    box-shadow: var(--shadow-hover);
}

/* 为每个项目项设置不同的图标渐变背景 */
.project-item:nth-child(1) .project-icon {
    background: var(--gradient-skill-1);
}

.project-item:nth-child(2) .project-icon {
    background: var(--gradient-skill-2);
}

.project-item:nth-child(3) .project-icon {
    background: var(--gradient-skill-3);
}

.project-item:nth-child(4) .project-icon {
    background: var(--gradient-skill-4);
}

.project-item:nth-child(5) .project-icon {
    background: var(--gradient-skill-5);
}

.project-item:nth-child(6) .project-icon {
    background: var(--gradient-skill-6);
}

.project-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    transition: all 0.3s ease;
    flex-shrink: 0;
    text-align: center;
    line-height: 60px;
    margin: 0;
    padding: 0;
    position: relative;
    overflow: hidden;
    /* 确保图标在容器中精确居中 */
    writing-mode: horizontal-tb;
    vertical-align: middle;
    display: flex;
    flex-direction: column;
}

.project-item:hover .project-icon {
    transform: scale(1.1) rotate(5deg);
}

.project-main {
    flex: 1;
    min-width: 0;
    position: relative;
}

.project-main h3 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 8px 0;
}

.project-desc {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.5;
}

/* 状态徽章位置调整 */
.status-badge {
    position: absolute;
    top: 0;
    right: 0;
}

/* 简化的项目统计 */
.project-stats-simple {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 20px;
    margin-top: 40px;
    padding: 30px;
    background: var(--surface);
    border-radius: 16px;
    -webkit-backdrop-filter: var(--blur);
    /* 兼容 Safari */
    backdrop-filter: var(--blur);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.project-stats-simple .stat-item {
    text-align: center;
}

.project-stats-simple .stat-number {
    display: block;
    font-size: 32px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 5px;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.project-stats-simple .stat-label {
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* 项目简单列表 - 与技能卡片UI保持一致 */
.projects-simple {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.project-item {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 25px;
    background: var(--surface-hover);
    border-radius: 16px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    border: 1px solid var(--border);
}

.project-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--gradient-primary);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.project-item:hover::before {
    transform: scaleY(1);
}

.project-item:hover {
    transform: translateX(10px) translateY(-5px);
    box-shadow: var(--shadow-hover);
}

/* 统一项目图标容器大小与技能专长一致 */
.project-icon {
    width: 60px;
    /* 与skill-icon相同的宽度 */
    height: 60px;
    /* 与skill-icon相同的高度 */
    border-radius: 16px;
    /* 与skill-icon相同的圆角 */
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    /* 与skill-icon相同的字体大小 */
    transition: all 0.3s ease;
    flex-shrink: 0;
    background: var(--gradient-primary);
    /* 添加渐变背景 */
    text-shadow: none;
    /* 移除阴影效果以保持一致 */
}

/* 为项目图标添加渐变背景效果，与技能图标保持一致 */
.projects-simple .project-item:nth-child(1) .project-icon {
    background: var(--gradient-skill-1);
}

.projects-simple .project-item:nth-child(2) .project-icon {
    background: var(--gradient-skill-2);
}

.projects-simple .project-item:nth-child(3) .project-icon {
    background: var(--gradient-skill-3);
}

.projects-simple .project-item:nth-child(4) .project-icon {
    background: var(--gradient-skill-4);
}

.projects-simple .project-item:nth-child(5) .project-icon {
    background: var(--gradient-skill-5);
}

.projects-simple .project-item:nth-child(6) .project-icon {
    background: var(--gradient-skill-6);
}

/* 统一悬停效果 */
.projects-simple .project-item:hover .project-icon {
    transform: scale(1.1) rotate(5deg);
}

/* 项目通知框样式 */
.project-notification {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1000;
    opacity: 1;
    transition: opacity 0.5s ease;
}

.notification-content {
    background: var(--surface);
    border-radius: 16px;
    padding: 20px 30px;
    box-shadow: var(--shadow-hover);
    border: 1px solid var(--border);
    -webkit-backdrop-filter: var(--blur);
    backdrop-filter: var(--blur);
    display: flex;
    align-items: center;
    gap: 15px;
    min-width: 20px;
}

.notification-text {
    color: var(--text-primary);
    font-size: 16px;
    font-weight: 500;
}

.notification-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 20px;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.notification-close:hover {
    background: var(--border);
    color: var(--text-primary);
}