/* ===== 茄子视频 全站样式表 ===== */
/* ===== 主题变量 ===== */
:root {
    --bg-primary: #0a0a18;
    --bg-secondary: #14142e;
    --bg-card: #1a1a35;
    --bg-card-hover: #22224a;
    --border-color: #2d2d55;
    --text-primary: #f0f0ff;
    --text-secondary: #d0d0e8;
    --text-muted: #8888aa;
    --accent-purple: #8b5cf6;
    --accent-light: #a78bfa;
    --accent-gradient: linear-gradient(135deg, #a78bfa, #8b5cf6);
    --shadow-soft: 0 20px 40px rgba(0, 0, 0, 0.5);
    --shadow-hover: 0 25px 50px rgba(139, 92, 246, 0.15);
    --radius-lg: 24px;
    --radius-md: 20px;
    --radius-sm: 16px;
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== 全局重置 ===== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
    background: var(--bg-primary);
    background-image: 
        radial-gradient(ellipse at 20% 20%, rgba(139, 92, 246, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(167, 139, 250, 0.06) 0%, transparent 50%),
        linear-gradient(145deg, #0a0a18 0%, #14142a 100%);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    padding: 0 20px;
    transition: background 0.3s ease;
}

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

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

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 10px;
    transition: var(--transition-smooth);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--accent-purple);
}

/* ===== 容器 ===== */
.container {
    max-width: 1280px;
    margin: 0 auto;
    position: relative;
}

/* ===== 头部导航 ===== */
.site-header {
    background: rgba(13, 13, 32, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 0 0 32px 32px;
    padding: 16px 28px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    border-bottom: 2px solid rgba(45, 45, 85, 0.5);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    animation: slideDown 0.6s ease-out;
}

@keyframes slideDown {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.logo h1 {
    font-size: 2.2rem;
    font-weight: 800;
    letter-spacing: 1px;
    background: linear-gradient(135deg, #c4b5fd, #a78bfa, #8b5cf6, #7c3aed);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.logo h1:hover {
    transform: scale(1.02);
}

.logo h1::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent-light), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.logo h1:hover::after {
    opacity: 1;
}

.nav-links {
    display: flex;
    flex-wrap: wrap;
    gap: 28px;
    list-style: none;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.05rem;
    padding: 6px 0;
    border-bottom: 2px solid transparent;
    transition: var(--transition-smooth);
    position: relative;
}

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

.nav-links a:hover {
    color: var(--accent-light);
    transform: translateY(-2px);
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-links .active {
    color: var(--accent-light);
    border-bottom-color: var(--accent-purple);
}

/* ===== 主区块 ===== */
main {
    margin-top: 30px;
}

section {
    background: rgba(20, 20, 46, 0.75);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    border-radius: 32px;
    padding: 28px 24px;
    margin-bottom: 40px;
    border: 1px solid rgba(45, 45, 85, 0.6);
    box-shadow: var(--shadow-soft);
    animation: fadeInUp 0.6s ease-out;
    transition: var(--transition-smooth);
}

section:hover {
    border-color: rgba(139, 92, 246, 0.3);
    box-shadow: var(--shadow-hover);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 24px;
    border-left: 6px solid var(--accent-purple);
    padding-left: 18px;
    letter-spacing: 0.5px;
    background: linear-gradient(90deg, var(--text-primary), var(--text-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
}

h2::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 18px;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-purple), transparent);
    border-radius: 3px;
}

h3 {
    font-size: 1.4rem;
    font-weight: 600;
    margin: 10px 0 8px;
    color: var(--text-primary);
}

/* ===== 卡片网格 ===== */
.grid-card {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 24px;
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: var(--transition-smooth);
    padding-bottom: 14px;
    position: relative;
    cursor: pointer;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--accent-gradient);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.card:hover {
    transform: translateY(-8px);
    border-color: rgba(139, 92, 246, 0.4);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3), 0 0 20px rgba(139, 92, 246, 0.1);
}

.card:hover::before {
    transform: scaleX(1);
}

.card img {
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
    border-bottom: 2px solid var(--border-color);
    background: #1c1c3e;
    transition: transform 0.5s ease, filter 0.3s ease;
}

.card:hover img {
    transform: scale(1.05);
    filter: brightness(1.1);
}

.card-body {
    padding: 12px 14px;
}

.card-title {
    font-weight: 600;
    font-size: 1.2rem;
    color: var(--text-primary);
    margin-bottom: 4px;
    transition: color 0.3s ease;
}

.card:hover .card-title {
    color: var(--accent-light);
}

.card-text {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-top: 6px;
    line-height: 1.4;
}

.badge {
    display: inline-block;
    background: rgba(45, 45, 85, 0.8);
    color: var(--accent-light);
    border-radius: 40px;
    padding: 4px 12px;
    font-size: 0.75rem;
    margin-top: 8px;
    border: 1px solid var(--border-color);
    transition: var(--transition-smooth);
}

.card:hover .badge {
    background: rgba(139, 92, 246, 0.2);
    border-color: var(--accent-purple);
}

/* ===== 推荐横版卡片 ===== */
.grid-recommend {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 24px;
}

.recommend-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    transition: var(--transition-smooth);
    position: relative;
}

.recommend-card::after {
    content: '推荐';
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--accent-gradient);
    color: #fff;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    opacity: 0;
    transform: translateY(-10px);
    transition: var(--transition-smooth);
}

.recommend-card:hover {
    transform: translateY(-6px);
    border-color: rgba(139, 92, 246, 0.4);
    box-shadow: var(--shadow-hover);
}

.recommend-card:hover::after {
    opacity: 1;
    transform: translateY(0);
}

.recommend-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: #181835;
    transition: transform 0.5s ease;
}

.recommend-card:hover img {
    transform: scale(1.03);
}

.recommend-body {
    padding: 16px;
}

.recommend-body h3 {
    font-size: 1.3rem;
    margin-bottom: 8px;
    transition: color 0.3s ease;
}

.recommend-card:hover .recommend-body h3 {
    color: var(--accent-light);
}

.recommend-body p {
    color: var(--text-secondary);
    margin-bottom: 6px;
}

/* ===== 详细介绍区域 ===== */
.detail-article {
    background: rgba(22, 22, 48, 0.8);
    border-radius: var(--radius-lg);
    padding: 30px;
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
}

.detail-article::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--accent-gradient);
    opacity: 0.5;
}

.detail-article p {
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.8;
}

.detail-article strong {
    color: var(--accent-light);
    font-weight: 600;
}

.detail-article h3 {
    font-size: 1.6rem;
    margin-bottom: 16px;
    color: var(--text-primary);
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 12px;
}

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

.character-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    text-align: center;
    padding: 18px 10px;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.character-card::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--accent-gradient);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.character-card:hover {
    transform: translateY(-6px);
    border-color: rgba(139, 92, 246, 0.4);
    box-shadow: var(--shadow-hover);
}

.character-card:hover::before {
    transform: scaleX(1);
}

.character-card img {
    border-radius: 50%;
    width: 120px;
    height: 120px;
    object-fit: cover;
    border: 3px solid var(--border-color);
    margin: 0 auto 12px;
    transition: var(--transition-smooth);
}

.character-card:hover img {
    border-color: var(--accent-purple);
    transform: scale(1.05);
}

.character-name {
    color: var(--accent-light);
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.character-card p {
    color: var(--text-secondary);
    margin-bottom: 4px;
    font-size: 0.9rem;
}

/* ===== 平台介绍 ===== */
.platform-box {
    background: rgba(20, 20, 46, 0.8);
    border-radius: var(--radius-lg);
    padding: 28px;
    border: 1px solid var(--border-color);
    transition: var(--transition-smooth);
}

.platform-box:hover {
    border-color: rgba(139, 92, 246, 0.3);
}

.platform-box p {
    color: var(--text-secondary);
    margin-bottom: 12px;
    line-height: 1.8;
}

.platform-box p:first-of-type {
    font-size: 1.1rem;
    color: var(--text-primary);
}

/* ===== APP下载 ===== */
.download-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    margin-top: 20px;
}

.btn {
    background: var(--accent-gradient);
    color: #ffffff;
    padding: 14px 34px;
    border-radius: 60px;
    font-weight: 600;
    font-size: 1.1rem;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition-smooth);
    display: inline-block;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
}

.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 ease;
}

.btn:hover {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.4);
}

.btn:hover::before {
    left: 100%;
}

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

/* ===== 评论 ===== */
.comment-list {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.comment-item {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    transition: var(--transition-smooth);
    animation: fadeInUp 0.5s ease-out;
    animation-fill-mode: both;
}

.comment-item:nth-child(2) { animation-delay: 0.1s; }
.comment-item:nth-child(3) { animation-delay: 0.2s; }
.comment-item:nth-child(4) { animation-delay: 0.3s; }
.comment-item:nth-child(5) { animation-delay: 0.4s; }
.comment-item:nth-child(6) { animation-delay: 0.5s; }
.comment-item:nth-child(7) { animation-delay: 0.6s; }
.comment-item:nth-child(8) { animation-delay: 0.7s; }
.comment-item:nth-child(9) { animation-delay: 0.8s; }
.comment-item:nth-child(10) { animation-delay: 0.9s; }
.comment-item:nth-child(11) { animation-delay: 1s; }
.comment-item:nth-child(12) { animation-delay: 1.1s; }

.comment-item:hover {
    transform: translateX(8px);
    border-color: rgba(139, 92, 246, 0.3);
    background: var(--bg-card-hover);
}

.comment-user {
    color: var(--accent-light);
    font-weight: 600;
    margin-bottom: 4px;
    display: inline-block;
}

.comment-time {
    color: var(--text-muted);
    font-size: 0.8rem;
    margin-left: 14px;
}

.comment-content {
    color: var(--text-secondary);
    margin-top: 6px;
}

/* ===== 侧边栏 ===== */
.sidebar-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 30px;
    align-items: start;
}

.sidebar {
    background: rgba(20, 20, 46, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px 20px;
    height: fit-content;
    position: sticky;
    top: 100px;
    transition: var(--transition-smooth);
}

.sidebar:hover {
    border-color: rgba(139, 92, 246, 0.3);
}

.sidebar h3 {
    color: var(--text-primary);
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 10px;
    margin-bottom: 18px;
    font-size: 1.2rem;
}

.rank-item {
    display: flex;
    justify-content: space-between;
    color: var(--text-secondary);
    padding: 10px 0;
    border-bottom: 1px dashed var(--border-color);
    transition: var(--transition-smooth);
    cursor: pointer;
}

.rank-item:hover {
    color: var(--accent-light);
    padding-left: 8px;
}

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

.stat-number {
    color: var(--accent-light);
    font-weight: 600;
}

/* ===== 底部 ===== */
footer {
    background: rgba(10, 10, 24, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 32px 32px 0 0;
    padding: 30px 20px;
    margin-top: 40px;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
    position: relative;
    overflow: hidden;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--accent-gradient);
    opacity: 0.3;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    margin-bottom: 20px;
}

.footer-links a {
    color: var(--accent-light);
    text-decoration: none;
    transition: var(--transition-smooth);
    position: relative;
    padding: 4px 0;
}

.footer-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--accent-light);
    transition: width 0.3s ease;
}

.footer-links a:hover {
    color: #c4b5fd;
    transform: translateY(-2px);
}

.footer-links a:hover::after {
    width: 100%;
}

.copyright {
    border-top: 1px solid #1e1e3a;
    padding-top: 20px;
    font-size: 0.9rem;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: center;
}

.copyright a {
    color: var(--accent-light);
    text-decoration: none;
    transition: color 0.3s ease;
}

.copyright a:hover {
    color: #c4b5fd;
    text-decoration: underline;
}

a {
    color: var(--accent-light);
}

/* ===== 滚动动画 ===== */
@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

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

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

@media (max-width: 800px) {
    body {
        padding: 0 12px;
    }
    
    .site-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
        padding: 16px 20px;
        border-radius: 0 0 24px 24px;
    }
    
    .nav-links {
        gap: 12px;
        width: 100%;
        overflow-x: auto;
        padding-bottom: 8px;
        scrollbar-width: thin;
    }
    
    .nav-links a {
        font-size: 0.95rem;
        white-space: nowrap;
    }
    
    .sidebar-layout {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        position: static;
        margin-top: 20px;
    }
    
    .grid-card {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 16px;
    }
    
    .grid-recommend {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
        gap: 16px;
    }
    
    .character-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 16px;
    }
    
    section {
        padding: 20px 16px;
        border-radius: 24px;
        margin-bottom: 30px;
    }
    
    h2 {
        font-size: 1.6rem;
        margin-bottom: 20px;
    }
    
    .detail-article {
        padding: 20px;
    }
    
    .download-buttons {
        flex-direction: column;
        gap: 16px;
    }
    
    .btn {
        width: 100%;
        text-align: center;
    }
    
    .comment-item {
        padding: 14px 16px;
    }
    
    .logo h1 {
        font-size: 1.8rem;
    }
}

@media (max-width: 480px) {
    body {
        padding: 0 8px;
    }
    
    .grid-card {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .grid-recommend {
        grid-template-columns: 1fr;
    }
    
    .character-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .card-title {
        font-size: 1rem;
    }
    
    .card-text {
        font-size: 0.8rem;
    }
    
    .badge {
        font-size: 0.7rem;
        padding: 3px 8px;
    }
    
    .site-header {
        padding: 12px 16px;
    }
    
    section {
        padding: 16px 12px;
    }
    
    h2 {
        font-size: 1.4rem;
        padding-left: 12px;
    }
    
    .detail-article {
        padding: 16px;
    }
    
    .platform-box {
        padding: 20px 16px;
    }
    
    .footer-links {
        gap: 12px;
    }
    
    .copyright {
        flex-direction: column;
        gap: 8px;
    }
}

/* ===== 暗色模式支持 ===== */
@media (prefers-color-scheme: dark) {
    :root {
        --bg-primary: #0a0a18;
        --bg-secondary: #14142e;
        --bg-card: #1a1a35;
        --bg-card-hover: #22224a;
        --border-color: #2d2d55;
    }
}

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

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

.card-shadow-hover {
    transition: var(--transition-smooth);
}

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

/* ===== 动画优化 ===== */
@media (hover: hover) {
    .card, .recommend-card, .character-card, .comment-item {
        will-change: transform;
    }
}

/* ===== 打印样式 ===== */
@media print {
    .site-header, .sidebar, .download-buttons, .btn, footer {
        display: none;
    }
    
    body {
        background: #fff;
        color: #000;
        padding: 20px;
    }
    
    section {
        background: #fff;
        border: 1px solid #ddd;
        box-shadow: none;
    }
}