/* ===== 黑桃视频 - 创意短视频工坊 完整样式表 ===== */
/* ===== 基础变量与全局设置 ===== */
:root {
    --primary: #6B4CFF;
    --primary-light: #9B7FFF;
    --primary-dark: #4A2FBF;
    --accent: #FF6B9D;
    --accent-gold: #FFB84D;
    --bg-main: #F8F4FF;
    --bg-card: #FFFFFF;
    --bg-soft: #F0EBFF;
    --bg-hover: #E8E0FF;
    --text-main: #1A1A2E;
    --text-secondary: #2D2D44;
    --text-muted: #6B6B8E;
    --text-light: #B8B0D0;
    --border-light: #E0D9F0;
    --shadow-sm: 0 2px 12px rgba(0,0,0,0.08);
    --shadow-md: 0 4px 20px rgba(0,0,0,0.04);
    --shadow-lg: 0 8px 30px rgba(0,0,0,0.12);
    --shadow-hover: 0 12px 30px rgba(107,76,255,0.15);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
    --gradient-primary: linear-gradient(135deg, #6B4CFF 0%, #4A4AF0 100%);
    --gradient-accent: linear-gradient(135deg, #FF6B9D 0%, #FFB84D 100%);
    --gradient-dark: linear-gradient(135deg, #1A1A2E 0%, #2D2D44 100%);
    --glass-bg: rgba(255,255,255,0.7);
    --glass-border: rgba(255,255,255,0.3);
    --glass-shadow: 0 8px 32px rgba(31,38,135,0.1);
}

/* 暗色模式 */
[data-theme="dark"] {
    --bg-main: #0D0820;
    --bg-card: #1A1A2E;
    --bg-soft: #2D2D44;
    --bg-hover: #3D3D54;
    --text-main: #F0EBFF;
    --text-secondary: #B8B0D0;
    --text-muted: #8A84A8;
    --text-light: #6B6B8E;
    --border-light: #2D2D44;
    --shadow-sm: 0 2px 12px rgba(0,0,0,0.2);
    --shadow-md: 0 4px 20px rgba(0,0,0,0.3);
    --shadow-lg: 0 8px 30px rgba(0,0,0,0.4);
    --shadow-hover: 0 12px 30px rgba(107,76,255,0.3);
    --glass-bg: rgba(26,26,46,0.7);
    --glass-border: rgba(255,255,255,0.1);
    --glass-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

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

html {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
    background-color: var(--bg-main);
    background-image: 
        radial-gradient(circle at 20% 20%, rgba(107,76,255,0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 50%, rgba(255,107,157,0.05) 0%, transparent 40%),
        radial-gradient(circle at 50% 80%, rgba(255,184,77,0.05) 0%, transparent 50%);
    color: var(--text-main);
    line-height: 1.6;
    min-height: 100vh;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* 链接样式 */
a {
    color: var(--primary);
    text-decoration: none;
    transition: color var(--transition-fast), text-decoration var(--transition-fast), opacity var(--transition-fast);
}

a:hover {
    color: var(--primary-light);
    text-decoration: underline;
}

/* 图片样式 */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* 容器 */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 标题样式 */
h1, h2, h3, h4, h5, h6 {
    color: var(--text-main);
    line-height: 1.3;
    font-weight: 700;
    transition: color 0.3s ease;
}

h1 {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-fill-color: transparent;
}

h2 {
    font-size: 1.8rem;
    margin: 2rem 0 1rem;
    border-left: 6px solid var(--primary);
    padding-left: 16px;
    position: relative;
    overflow: hidden;
}

h2::after {
    content: '';
    position: absolute;
    left: 16px;
    bottom: -4px;
    width: 60px;
    height: 3px;
    background: var(--gradient-accent);
    border-radius: 2px;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s ease;
}

h2:hover::after {
    transform: scaleX(1);
}

h3 {
    font-size: 1.3rem;
    margin: 1.5rem 0 0.8rem;
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-main);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 5px;
    transition: background 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-light);
}

/* 选择文本样式 */
::selection {
    background: var(--primary);
    color: #FFFFFF;
}

/* ===== 顶部导航 ===== */
.site-header {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.site-header:hover {
    box-shadow: var(--shadow-lg);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    padding: 12px 20px;
    max-width: 1400px;
    margin: 0 auto;
    gap: 12px;
}

.logo-area h1 {
    font-size: 1.8rem;
    margin: 0;
    background: none;
    -webkit-background-clip: initial;
    -webkit-text-fill-color: var(--text-main);
    background-clip: initial;
    text-fill-color: initial;
}

.logo-area h1 a {
    color: var(--text-main);
    position: relative;
    display: inline-block;
    transition: all 0.3s ease;
}

.logo-area h1 a::before {
    content: '♠';
    display: inline-block;
    margin-right: 6px;
    color: var(--primary);
    font-size: 1.2em;
    transition: transform 0.3s ease;
}

.logo-area h1 a:hover {
    text-decoration: none;
    color: var(--primary);
    transform: scale(1.02);
}

.logo-area h1 a:hover::before {
    transform: rotate(90deg) scale(1.2);
}

.nav-menu {
    display: flex;
    list-style: none;
    flex-wrap: wrap;
    gap: 6px;
    padding: 4px;
    background: var(--bg-soft);
    border-radius: 30px;
    padding: 4px;
}

.nav-menu li a {
    display: block;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--text-secondary);
    background: transparent;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.nav-menu li a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--gradient-primary);
    transition: left 0.3s ease;
    z-index: -1;
    border-radius: 20px;
}

.nav-menu li a:hover {
    background: var(--gradient-primary);
    color: #FFFFFF;
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(107,76,255,0.3);
}

.nav-menu li a:hover::before {
    left: 0;
}

.nav-menu li a:active {
    transform: translateY(0);
}

/* ===== 主体布局 ===== */
.main-layout {
    display: flex;
    gap: 30px;
    margin: 30px 0;
    flex-wrap: wrap;
    animation: fadeInUp 0.6s ease both;
}

.content-area {
    flex: 1;
    min-width: 0;
}

.sidebar {
    width: 320px;
    flex-shrink: 0;
    animation: fadeInUp 0.6s ease 0.2s both;
}

/* ===== 卡片区域 ===== */
.section-block {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-md);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.section-block::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s ease;
}

.section-block:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.section-block:hover::before {
    transform: scaleX(1);
}

/* ===== 漫画网格 ===== */
.comic-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
}

.comic-card {
    background: var(--bg-soft);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    border: 1px solid transparent;
    cursor: pointer;
}

.comic-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gradient-primary);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1;
    pointer-events: none;
}

.comic-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.comic-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: var(--shadow-hover);
    border-color: var(--primary);
}

.comic-card:hover::before {
    opacity: 0.1;
}

.comic-card:hover img {
    transform: scale(1.1);
}

.comic-info {
    padding: 12px;
    position: relative;
    z-index: 2;
}

.comic-info h3 {
    font-size: 1rem;
    margin-bottom: 6px;
    transition: color 0.3s ease;
}

.comic-card:hover .comic-info h3 {
    color: var(--primary);
}

.comic-info p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 2px;
}

.comic-info .meta {
    color: var(--primary);
    font-weight: 500;
    display: inline-block;
    margin-top: 6px;
    padding: 2px 10px;
    background: rgba(107,76,255,0.1);
    border-radius: 12px;
    font-size: 0.8rem;
}

/* ===== 推荐区域 ===== */
.featured-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 24px;
}

.featured-card {
    background: var(--bg-soft);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    border: 1px solid transparent;
}

.featured-card::after {
    content: '★';
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    background: var(--gradient-accent);
    color: #FFFFFF;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    box-shadow: 0 4px 12px rgba(255,107,157,0.4);
    opacity: 0;
    transform: scale(0) rotate(90deg);
    transition: all 0.4s ease;
    z-index: 2;
}

.featured-card:hover::after {
    opacity: 1;
    transform: scale(1) rotate(0deg);
}

.featured-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.featured-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
    border-color: var(--accent);
}

.featured-card:hover img {
    transform: scale(1.05);
}

.featured-info {
    padding: 16px;
    background: linear-gradient(to top, var(--bg-soft) 0%, transparent 100%);
}

.featured-info h3 {
    font-size: 1.1rem;
    margin-bottom: 8px;
    transition: color 0.3s ease;
}

.featured-card:hover .featured-info h3 {
    color: var(--accent);
}

.featured-info p {
    margin-top: 8px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ===== 角色区域 ===== */
.character-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.character-card {
    background: var(--bg-soft);
    border-radius: var(--radius-md);
    padding: 20px 16px;
    text-align: center;
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
    border: 1px solid transparent;
}

.character-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 80px;
    background: var(--gradient-primary);
    border-radius: 50%;
    opacity: 0.05;
    transition: all 0.4s ease;
}

.character-card img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 12px;
    border: 4px solid var(--bg-card);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: all 0.4s ease;
    position: relative;
    z-index: 1;
}

.character-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-hover);
    border-color: var(--primary);
}

.character-card:hover::before {
    transform: translateX(-50%) scale(1.5);
    opacity: 0.1;
}

.character-card:hover img {
    transform: scale(1.1);
    border-color: var(--primary);
    box-shadow: 0 8px 25px rgba(107,76,255,0.3);
}

.character-card h3 {
    margin-bottom: 8px;
    font-size: 1.1rem;
    transition: color 0.3s ease;
}

.character-card:hover h3 {
    color: var(--primary);
}

.character-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ===== 评论区域 ===== */
.comment-list {
    list-style: none;
}

.comment-list li {
    background: var(--bg-soft);
    border-radius: var(--radius-sm);
    padding: 16px;
    margin-bottom: 12px;
    transition: all 0.3s ease;
    border-left: 4px solid transparent;
    position: relative;
    overflow: hidden;
}

.comment-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: var(--gradient-primary);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.comment-list li:hover {
    background: var(--bg-hover);
    transform: translateX(6px);
    box-shadow: var(--shadow-sm);
    border-left-color: var(--primary);
}

.comment-list li:hover::before {
    transform: scaleY(1);
}

.comment-list .user {
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.comment-list .user::before {
    content: '👤';
    font-size: 1.1rem;
}

.comment-list .time {
    font-size: 0.8rem;
    color: var(--primary);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.comment-list .time::before {
    content: '🕐';
}

.comment-list .content {
    font-size: 0.95rem;
    color: var(--text-main);
    line-height: 1.6;
}

/* ===== 侧边栏 ===== */
.sidebar-widget {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: var(--glass-shadow);
    border: 1px solid var(--glass-border);
    transition: all 0.3s ease;
}

.sidebar-widget:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.sidebar-widget h3 {
    border-bottom: 2px solid var(--primary);
    padding-bottom: 8px;
    margin-bottom: 16px;
    font-size: 1.1rem;
    position: relative;
    display: inline-block;
}

.sidebar-widget h3::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 60%;
    height: 2px;
    background: var(--gradient-accent);
}

.rank-list {
    list-style: none;
    counter-reset: rank;
}

.rank-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 8px;
    border-bottom: 1px dashed var(--border-light);
    font-size: 0.95rem;
    transition: all 0.3s ease;
    counter-increment: rank;
    border-radius: 6px;
}

.rank-list li:last-child {
    border-bottom: none;
}

.rank-list li:hover {
    background: var(--bg-soft);
    padding-left: 12px;
    transform: translateX(4px);
}

.rank-list li span:first-child {
    display: flex;
    align-items: center;
    gap: 8px;
}

.rank-list li span:first-child::before {
    content: counter(rank);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: var(--bg-soft);
    color: var(--primary);
    border-radius: 6px;
    font-weight: 700;
    font-size: 0.85rem;
    transition: all 0.3s ease;
}

.rank-list li:hover span:first-child::before {
    background: var(--gradient-primary);
    color: #FFFFFF;
    transform: scale(1.1);
}

.rank-list .num {
    color: var(--primary);
    font-weight: 700;
    background: rgba(107,76,255,0.1);
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 0.85rem;
}

.stats-box {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-soft);
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.stat-item:hover {
    background: var(--bg-hover);
    border-color: var(--primary);
    transform: scale(1.02);
}

.stat-item .label {
    font-weight: 500;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.stat-item .value {
    font-weight: 700;
    color: var(--primary);
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.stat-item:hover .value {
    transform: scale(1.1);
}

/* ===== 下载区域 ===== */
.download-area {
    background: var(--gradient-primary);
    border-radius: var(--radius-xl);
    padding: 50px 40px;
    color: #FFFFFF;
    text-align: center;
    position: relative;
    overflow: hidden;
    transition: all 0.4s ease;
}

.download-area::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 50%);
    animation: rotate 20s linear infinite;
}

.download-area::after {
    content: '';
    position: absolute;
    bottom: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.05) 0%, transparent 50%);
    animation: rotate 30s linear infinite reverse;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.download-area h2 {
    color: #FFFFFF;
    border: none;
    position: relative;
    z-index: 1;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.download-area h2::after {
    background: #FFFFFF;
}

.download-area p {
    margin-bottom: 24px;
    font-size: 1.1rem;
    position: relative;
    z-index: 1;
    text-shadow: 0 1px 5px rgba(0,0,0,0.2);
}

.download-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

.btn-download {
    background: #FFFFFF;
    color: var(--primary);
    padding: 14px 32px;
    border-radius: 30px;
    font-weight: 700;
    font-size: 1rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    position: relative;
    overflow: hidden;
}

.btn-download::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(107,76,255,0.1);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.5s ease, height 0.5s ease;
}

.btn-download:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 8px 30px rgba(0,0,0,0.3);
    color: var(--primary-dark);
    text-decoration: none;
}

.btn-download:hover::before {
    width: 300px;
    height: 300px;
}

.btn-download:active {
    transform: translateY(-2px) scale(0.98);
}

/* ===== 页脚 ===== */
.site-footer {
    background: var(--gradient-dark);
    color: var(--text-light);
    padding: 50px 0 20px;
    margin-top: 40px;
    position: relative;
    overflow: hidden;
}

.site-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    margin-bottom: 30px;
}

.footer-links a {
    color: var(--text-light);
    transition: all 0.3s ease;
    position: relative;
    padding: 4px 8px;
}

.footer-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 8px;
    right: 8px;
    height: 2px;
    background: var(--gradient-accent);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.footer-links a:hover {
    color: #FFFFFF;
    text-decoration: none;
    transform: translateY(-2px);
}

.footer-links a:hover::after {
    transform: scaleX(1);
}

.footer-bottom {
    text-align: center;
    font-size: 0.85rem;
    border-top: 1px solid var(--border-light);
    padding-top: 20px;
}

.footer-bottom p {
    margin-bottom: 8px;
    color: var(--text-light);
}

.footer-bottom a {
    color: var(--text-light);
    margin: 0 8px;
    transition: all 0.3s ease;
}

.footer-bottom a:hover {
    color: #FFFFFF;
    text-decoration: none;
}

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

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@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);
    }
}

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

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@keyframes shimmer {
    0% { background-position: -1000px 0; }
    100% { background-position: 1000px 0; }
}

/* 滚动动画 */
.section-block {
    animation: fadeInUp 0.6s ease both;
}

.section-block:nth-child(2) {
    animation-delay: 0.1s;
}

.section-block:nth-child(3) {
    animation-delay: 0.2s;
}

.section-block:nth-child(4) {
    animation-delay: 0.3s;
}

.section-block:nth-child(5) {
    animation-delay: 0.4s;
}

.section-block:nth-child(6) {
    animation-delay: 0.5s;
}

/* 滚动进入动画 */
@media (prefers-reduced-motion: no-preference) {
    .comic-card, .featured-card, .character-card {
        animation: fadeInUp 0.6s ease both;
    }

    .comic-card:nth-child(odd) {
        animation-delay: 0.1s;
    }

    .comic-card:nth-child(even) {
        animation-delay: 0.2s;
    }

    .featured-card:nth-child(1) { animation-delay: 0.1s; }
    .featured-card:nth-child(2) { animation-delay: 0.2s; }
    .featured-card:nth-child(3) { animation-delay: 0.3s; }
    .featured-card:nth-child(4) { animation-delay: 0.4s; }

    .character-card:nth-child(1) { animation-delay: 0.1s; }
    .character-card:nth-child(2) { animation-delay: 0.2s; }
    .character-card:nth-child(3) { animation-delay: 0.3s; }
    .character-card:nth-child(4) { animation-delay: 0.4s; }
}

/* 暗色模式切换按钮 */
.theme-toggle {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--gradient-primary);
    color: #FFFFFF;
    border: none;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    transition: all 0.4s ease;
}

.theme-toggle:hover {
    transform: scale(1.1) rotate(180deg);
    box-shadow: 0 8px 30px rgba(107,76,255,0.4);
}

/* ===== 响应式布局 ===== */
@media (max-width: 1200px) {
    .comic-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    }

    .featured-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    }
}

@media (max-width: 992px) {
    .sidebar {
        width: 100%;
    }

    .sidebar-widget {
        display: inline-block;
        width: calc(33.333% - 14px);
        margin-right: 14px;
        vertical-align: top;
    }

    .sidebar-widget:last-child {
        margin-right: 0;
    }
}

@media (max-width: 768px) {
    h1 {
        font-size: 1.6rem;
    }

    h2 {
        font-size: 1.4rem;
    }

    .nav-container {
        flex-direction: column;
        gap: 16px;
    }

    .main-layout {
        flex-direction: column;
        gap: 20px;
    }

    .comic-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 12px;
    }

    .featured-grid {
        grid-template-columns: 1fr;
    }

    .character-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

    .section-block {
        padding: 16px;
        border-radius: var(--radius-md);
    }

    .download-area {
        padding: 30px 20px;
    }

    .download-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .btn-download {
        text-align: center;
    }

    .sidebar-widget {
        width: 100%;
        margin-right: 0;
    }

    .nav-menu {
        justify-content: center;
        gap: 4px;
    }

    .nav-menu li a {
        padding: 6px 12px;
        font-size: 0.85rem;
    }

    .comic-card img {
        height: 180px;
    }

    .featured-card img {
        height: 140px;
    }

    .character-card img {
        width: 100px;
        height: 100px;
    }

    .footer-links {
        gap: 12px;
    }

    .footer-links a {
        font-size: 0.85rem;
    }

    .theme-toggle {
        bottom: 20px;
        right: 20px;
        width: 44px;
        height: 44px;
        font-size: 20px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 12px;
    }

    .comic-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .comic-card img {
        height: 160px;
    }

    .comic-info {
        padding: 8px;
    }

    .comic-info h3 {
        font-size: 0.9rem;
    }

    .comic-info p {
        font-size: 0.75rem;
    }

    .character-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    h1 {
        font-size: 1.3rem;
    }

    h2 {
        font-size: 1.2rem;
    }

    .logo-area h1 {
        font-size: 1.5rem;
    }

    .nav-menu li a {
        padding: 5px 10px;
        font-size: 0.8rem;
    }
}

/* 打印样式 */
@media print {
    .site-header,
    .sidebar,
    .download-area,
    .site-footer,
    .theme-toggle {
        display: none !important;
    }

    .main-layout {
        flex-direction: column;
    }

    .content-area {
        width: 100%;
    }

    .section-block {
        box-shadow: none;
        border: 1px solid #ddd;
        break-inside: avoid;
    }

    .comic-card,
    .featured-card,
    .character-card {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ddd;
    }

    body {
        background: #FFFFFF;
        color: #000000;
    }

    a {
        color: #000000;
        text-decoration: underline;
    }
}

/* 无障碍访问 */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* 焦点可见性 */
a:focus-visible,
button:focus-visible {
    outline: 3px solid var(--primary);
    outline-offset: 2px;
    border-radius: 4px;
}

/* 暗色模式自动适配 */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --bg-main: #0D0820;
        --bg-card: #1A1A2E;
        --bg-soft: #2D2D44;
        --bg-hover: #3D3D54;
        --text-main: #F0EBFF;
        --text-secondary: #B8B0D0;
        --text-muted: #8A84A8;
        --text-light: #6B6B8E;
        --border-light: #2D2D44;
        --shadow-sm: 0 2px 12px rgba(0,0,0,0.2);
        --shadow-md: 0 4px 20px rgba(0,0,0,0.3);
        --shadow-lg: 0 8px 30px rgba(0,0,0,0.4);
        --shadow-hover: 0 12px 30px rgba(107,76,255,0.3);
        --glass-bg: rgba(26,26,46,0.7);
        --glass-border: rgba(255,255,255,0.1);
        --glass-shadow: 0 8px 32px rgba(0,0,0,0.3);
    }
}

/* 工具类 */
.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-fill-color: transparent;
}

.text-gradient-accent {
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-fill-color: transparent;
}

.glass-effect {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
}

.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

/* 自定义滚动容器 */
.scroll-container {
    scrollbar-width: thin;
    scrollbar-color: var(--primary) var(--bg-soft);
}

.scroll-container::-webkit-scrollbar {
    width: 6px;
}

.scroll-container::-webkit-scrollbar-track {
    background: var(--bg-soft);
}

.scroll-container::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 3px;
}

/* 加载动画 */
.loading {
    position: relative;
    overflow: hidden;
}

.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    animation: shimmer 1.5s infinite;
}

/* 徽章 */
.badge {
    display: inline-block;
    padding: 4px 12px;
    background: var(--gradient-primary);
    color: #FFFFFF;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(107,76,255,0.3);
}

.badge-accent {
    background: var(--gradient-accent);
    box-shadow: 0 2px 8px rgba(255,107,157,0.3);
}

/* 分割线 */
.divider {
    height: 1px;
    background: linear-gradient(to right, transparent, var(--primary), transparent);
    margin: 20px 0;
    border: none;
}

/* 圆角变化 */
.rounded-full {
    border-radius: 9999px;
}

.rounded-lg {
    border-radius: var(--radius-lg);
}

.rounded-md {
    border-radius: var(--radius-md);
}

/* 阴影变化 */
.shadow-hover {
    transition: box-shadow 0.3s ease;
}

.shadow-hover:hover {
    box-shadow: var(--shadow-hover);
}

/* 渐变边框 */
.gradient-border {
    border: 2px solid transparent;
    background: linear-gradient(var(--bg-card), var(--bg-card)) padding-box,
                var(--gradient-primary) border-box;
}

/* 悬停缩放 */
.scale-hover {
    transition: transform 0.3s ease;
}

.scale-hover:hover {
    transform: scale(1.05);
}

/* 旋转动画 */
.spin {
    animation: spin 10s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* 呼吸动画 */
.breathe {
    animation: breathe 3s ease-in-out infinite;
}

@keyframes breathe {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* 结束 */