/* 3D动态交互风格 - 极光蓝主题 */
:root {
    --primary-3d: #00b4d8;  /* 极光蓝 */
    --secondary-3d: #0077b6;
    --dark-3d: #03045e;
    --light-3d: #caf0f8;
    --accent-3d: #48cae4;
    --text-3d: #ffffff;
    --shadow-3d: 0 10px 20px rgba(0, 0, 0, 0.3);
    --perspective: 1000px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600;700&display=swap');

body {
    background: linear-gradient(135deg, var(--dark-3d) 0%, #023e8a 100%);
    color: var(--text-3d);
    min-height: 100vh;
    perspective: var(--perspective);
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: var(--accent-3d);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

a:hover {
    color: var(--light-3d);
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* 3D浮动头部 */
header {
    background: rgba(3, 4, 94, 0.7);
    backdrop-filter: blur(10px);
    padding: 25px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.4);
    transform-style: preserve-3d;
    transform: translateZ(50px);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    transform-style: preserve-3d;
}

.logo {
    font-size: 28px;
    font-weight: 700;
    background: linear-gradient(to right, var(--primary-3d), var(--light-3d));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: 2px;
    text-shadow: 0 2px 10px rgba(0, 180, 216, 0.4);
    transform: translateZ(30px);
}

nav ul {
    display: flex;
    list-style: none;
    gap: 25px;
    transform: translateZ(30px);
}

nav ul li a {
    padding: 10px 20px;
    border-radius: 50px;
    font-weight: 600;
    background: rgba(0, 180, 216, 0.2);
    border: 1px solid var(--primary-3d);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

nav ul li a:hover {
    background: var(--primary-3d);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 8px 15px rgba(0, 180, 216, 0.4);
}

/* 3D主要内容区域 */
.main-content {
    background: rgba(2, 62, 138, 0.6);
    border-radius: 20px;
    padding: 40px;
    margin: 120px 0 50px;
    backdrop-filter: blur(8px);
    border: 1px solid rgba(202, 240, 248, 0.1);
    box-shadow: var(--shadow-3d);
    transform-style: preserve-3d;
    transition: transform 0.5s;
}

.main-content:hover {
    transform: translateY(-10px) rotateX(5deg);
}

.section-title {
    font-size: 32px;
    margin-bottom: 30px;
    padding-bottom: 15px;
    position: relative;
    text-transform: uppercase;
    letter-spacing: 2px;
    transform: translateZ(40px);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100px;
    height: 3px;
    background: linear-gradient(to right, var(--primary-3d), transparent);
    border-radius: 3px;
}

/* 3D卡片式文章列表 */
.article-grid-3d {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    perspective: var(--perspective);
}

.article-card-3d {
    background: rgba(0, 119, 182, 0.3);
    border-radius: 15px;
    overflow: hidden;
    transition: all 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    transform-style: preserve-3d;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(202, 240, 248, 0.1);
    position: relative;
}

.article-card-3d::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent 0%, rgba(0, 180, 216, 0.1) 100%);
    opacity: 0;
    transition: opacity 0.4s;
}

.article-card-3d:hover {
    transform: translateY(-15px) rotateX(10deg) scale(1.03);
    box-shadow: 0 20px 30px rgba(0, 0, 0, 0.4);
}

.article-card-3d:hover::before {
    opacity: 1;
}

.card-image-3d {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-bottom: 1px solid rgba(202, 240, 248, 0.1);
    transform: translateZ(30px);
}

.card-body-3d {
    padding: 25px;
    transform: translateZ(30px);
}

.card-title-3d {
    font-size: 20px;
    margin-bottom: 15px;
    font-weight: 600;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    position: relative;
}

.card-title-3d::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--primary-3d);
    transition: width 0.4s;
}

.article-card-3d:hover .card-title-3d::after {
    width: 80px;
}

.card-meta-3d {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
    color: var(--light-3d);
    margin-top: 20px;
    opacity: 0.8;
}

/* 3D分类标签 */
.category-tag-3d {
    display: inline-block;
    padding: 5px 15px;
    background: linear-gradient(to right, var(--primary-3d), var(--secondary-3d));
    color: white;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 15px;
    transform: translateZ(20px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* 3D文章详情页 */
.article-detail-3d {
    max-width: 800px;
    margin: 0 auto;
    transform-style: preserve-3d;
}

.article-header-3d {
    margin-bottom: 50px;
    text-align: center;
    transform: translateZ(50px);
}

.article-title-3d {
    font-size: 42px;
    margin-bottom: 25px;
    line-height: 1.3;
    text-shadow: 0 2px 10px rgba(0, 180, 216, 0.4);
    position: relative;
    display: inline-block;
}

.article-title-3d::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 3px;
    background: var(--primary-3d);
    border-radius: 3px;
}

.article-meta-3d {
    display: flex;
    justify-content: center;
    gap: 30px;
    color: var(--light-3d);
    margin-bottom: 30px;
    flex-wrap: wrap;
    transform: translateZ(40px);
}

.article-image-3d {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
    border-radius: 15px;
    margin-bottom: 40px;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
    transform: translateZ(60px);
    border: 2px solid rgba(202, 240, 248, 0.2);
}

.article-content-3d {
    line-height: 1.9;
    font-size: 18px;
    transform: translateZ(30px);
}

.article-content-3d p {
    margin-bottom: 25px;
    position: relative;
    padding-left: 20px;
}

.article-content-3d p::before {
    content: '';
    position: absolute;
    left: 0;
    top: 10px;
    width: 8px;
    height: 8px;
    background: var(--primary-3d);
    border-radius: 50%;
}

.article-content-3d img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    margin: 30px 0;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    transform: translateZ(40px);
    transition: transform 0.4s;
}

.article-content-3d img:hover {
    transform: translateZ(60px) scale(1.02);
}

/* 3D分页导航 */
.pagination-3d {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 50px;
    transform: translateZ(40px);
}

.pagination-3d a {
    padding: 12px 25px;
    border-radius: 50px;
    background: rgba(0, 180, 216, 0.3);
    border: 1px solid var(--primary-3d);
    font-weight: 600;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.pagination-3d a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(202, 240, 248, 0.4), transparent);
    transition: all 0.6s;
}

.pagination-3d a:hover {
    background: var(--primary-3d);
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 10px 20px rgba(0, 180, 216, 0.4);
}

.pagination-3d a:hover::before {
    left: 100%;
}

/* 3D友情链接 */
.friend-links-3d {
    background: rgba(0, 119, 182, 0.3);
    border-radius: 15px;
    padding: 30px;
    margin: 50px 0;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(202, 240, 248, 0.1);
    box-shadow: var(--shadow-3d);
    transform-style: preserve-3d;
}

.friend-links-3d h3 {
    margin-bottom: 25px;
    font-size: 24px;
    transform: translateZ(30px);
}

.friend-links-container-3d {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    transform: translateZ(20px);
}

.friend-links-container-3d a {
    padding: 10px 20px;
    background: rgba(0, 180, 216, 0.2);
    border-radius: 50px;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid var(--primary-3d);
    transition: all 0.3s;
}

.friend-links-container-3d a:hover {
    background: var(--primary-3d);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 5px 10px rgba(0, 180, 216, 0.3);
}

/* 3D浮动页脚 */
footer {
    background: rgba(3, 4, 94, 0.8);
    padding: 30px 0;
    text-align: center;
    margin-top: 80px;
    backdrop-filter: blur(5px);
    border-top: 1px solid rgba(202, 240, 248, 0.1);
    transform-style: preserve-3d;
    transform: translateZ(40px);
}

.copyright {
    font-size: 14px;
    color: var(--light-3d);
}

/* 3D背景元素 */
.background-element {
    position: fixed;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(0, 180, 216, 0.1) 0%, transparent 70%);
    z-index: -1;
    animation: float 15s infinite ease-in-out;
}

.background-element:nth-child(1) {
    top: 20%;
    left: 10%;
    width: 400px;
    height: 400px;
    animation-delay: 0s;
}

.background-element:nth-child(2) {
    top: 60%;
    right: 10%;
    width: 300px;
    height: 300px;
    animation-delay: 3s;
}

.background-element:nth-child(3) {
    bottom: 10%;
    left: 30%;
    width: 500px;
    height: 500px;
    animation-delay: 6s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-30px) rotate(5deg);
    }
}

/* 响应式设计 */
@media (max-width: 992px) {
    .header-content {
        flex-direction: column;
        gap: 20px;
    }
    
    nav ul {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .article-grid-3d {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
    
    .article-title-3d {
        font-size: 32px;
    }
}

@media (max-width: 768px) {
    .article-grid-3d {
        grid-template-columns: 1fr;
    }
    
    .article-title-3d {
        font-size: 28px;
    }
    
    .article-meta-3d {
        gap: 15px;
    }
    
    .main-content {
        padding: 30px 20px;
        margin-top: 100px;
    }
}