/* style.css - 江门嘉权知识产权运营有限公司 */
/* 全局重置与基础 */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #1a3a5c;
    --primary-light: #2a5a8c;
    --primary-dark: #0f2440;
    --accent: #c0392b;
    --accent-light: #e74c3c;
    --bg-light: #f5f7fa;
    --bg-white: #ffffff;
    --text-dark: #333333;
    --text-muted: #555555;
    --text-light: #999999;
    --border-color: #eef2f7;
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.08);
    --shadow-md: 0 4px 20px rgba(0,0,0,0.1);
    --shadow-lg: 0 8px 40px rgba(0,0,0,0.15);
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    color: var(--text-dark);
    line-height: 1.8;
    background: var(--bg-light);
    overflow-x: hidden;
    min-height: 100vh;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
}

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

img, svg {
    max-width: 100%;
    height: auto;
    display: block;
}

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

/* 导航吸顶与头部 */
.header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 2px solid var(--primary);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
    flex-wrap: wrap;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 10px;
    letter-spacing: 0.5px;
}

.logo svg {
    width: 40px;
    height: 40px;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
}

.nav {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.nav a {
    padding: 8px 16px;
    font-size: 0.95rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    position: relative;
    font-weight: 500;
    color: var(--text-dark);
}

.nav a::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: var(--transition);
    transform: translateX(-50%);
    border-radius: 2px;
}

.nav a:hover {
    background: rgba(26, 58, 92, 0.08);
    color: var(--primary);
}

.nav a:hover::after {
    width: 60%;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.8rem;
    cursor: pointer;
    color: var(--primary);
    padding: 5px 10px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.menu-toggle:hover {
    background: rgba(26, 58, 92, 0.08);
}

/* 移动菜单 */
@media (max-width: 768px) {
    .header-inner {
        height: auto;
        padding: 12px 0;
    }
    
    .nav {
        display: none;
        width: 100%;
        flex-direction: column;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        padding: 20px;
        border-top: 1px solid var(--border-color);
        border-radius: 0 0 var(--radius-md) var(--radius-md);
        box-shadow: var(--shadow-md);
        gap: 4px;
    }
    
    .nav.active {
        display: flex;
        animation: slideDown 0.3s ease;
    }
    
    .menu-toggle {
        display: block;
    }
    
    .nav a {
        padding: 12px 16px;
        border-radius: var(--radius-sm);
    }
    
    .nav a::after {
        display: none;
    }
}

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

/* 面包屑 */
.breadcrumb {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    padding: 14px 0;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.9rem;
}

.breadcrumb a {
    color: var(--primary);
    font-weight: 500;
}

.breadcrumb span {
    margin: 0 8px;
    color: var(--text-light);
}

/* Banner 轮播 - 渐变风格 */
.banner {
    position: relative;
    overflow: hidden;
    height: 480px;
    background: linear-gradient(135deg, #1a3a5c 0%, #2a5a8c 50%, #1a3a5c 100%);
}

.banner::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 20% 50%, rgba(255,255,255,0.08) 0%, transparent 50%),
                radial-gradient(circle at 80% 50%, rgba(255,255,255,0.05) 0%, transparent 50%);
    pointer-events: none;
}

.banner-slide {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.8s ease, transform 0.8s ease;
    color: #fff;
    text-align: center;
    padding: 60px 40px;
    transform: scale(0.98);
}

.banner-slide.active {
    opacity: 1;
    transform: scale(1);
}

.banner-slide > div {
    max-width: 800px;
    animation: fadeUp 0.8s ease;
}

.banner-slide h2 {
    font-size: 2.6rem;
    margin-bottom: 20px;
    text-shadow: 0 4px 12px rgba(0,0,0,0.3);
    font-weight: 800;
    letter-spacing: 1px;
    background: linear-gradient(135deg, #fff 0%, #e0e8f0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.banner-slide p {
    font-size: 1.2rem;
    max-width: 650px;
    margin: 0 auto;
    opacity: 0.9;
    text-shadow: 0 2px 8px rgba(0,0,0,0.2);
    line-height: 1.8;
}

.banner-dots {
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 10;
}

.banner-dots span {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
}

.banner-dots span.active {
    background: #fff;
    border-color: rgba(255,255,255,0.6);
    transform: scale(1.2);
    box-shadow: 0 0 20px rgba(255,255,255,0.3);
}

.banner-dots span:hover {
    background: rgba(255, 255, 255, 0.7);
    transform: scale(1.1);
}

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

@media (max-width: 768px) {
    .banner {
        height: 360px;
    }
    
    .banner-slide h2 {
        font-size: 1.6rem;
    }
    
    .banner-slide p {
        font-size: 1rem;
    }
    
    .banner-slide {
        padding: 40px 20px;
    }
}

/* 通用区块 */
.section {
    padding: 70px 0;
    background: var(--bg-white);
    transition: var(--transition);
}

.section:nth-child(even) {
    background: var(--bg-light);
}

.section-title {
    text-align: center;
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 45px;
    position: relative;
    font-weight: 700;
}

.section-title:after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--accent), var(--accent-light));
    margin: 18px auto 0;
    border-radius: 4px;
}

/* 网格系统 */
.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

@media (max-width: 992px) {
    .grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }
}

/* 卡片 - 毛玻璃与圆角 */
.card {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: var(--radius-md);
    padding: 30px 25px;
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(255, 255, 255, 0.6);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    opacity: 0;
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-md);
    border-color: rgba(26, 58, 92, 0.15);
}

.card:hover::before {
    opacity: 1;
}

.card h3 {
    color: var(--primary);
    margin-bottom: 14px;
    font-size: 1.2rem;
    font-weight: 600;
}

.card p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.7;
}

.card svg {
    display: block;
    margin: 0 auto 18px;
    transition: var(--transition);
}

.card:hover svg {
    transform: scale(1.1);
}

/* 按钮 */
.btn {
    display: inline-block;
    padding: 12px 32px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(26, 58, 92, 0.3);
    border: none;
    cursor: pointer;
    letter-spacing: 0.5px;
}

.btn:hover {
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(192, 57, 43, 0.4);
}

/* 文章列表 */
.article-item {
    border-bottom: 1px solid var(--border-color);
    padding: 22px 0;
    transition: var(--transition);
    position: relative;
    padding-left: 0;
}

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

.article-item:hover {
    padding-left: 12px;
    border-bottom-color: var(--primary);
}

.article-item h4 {
    font-size: 1.1rem;
    color: var(--primary);
    margin-bottom: 6px;
    font-weight: 600;
}

.article-item .meta {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.article-item p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.article-item .read-more {
    color: var(--accent);
    font-size: 0.9rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: var(--transition);
}

.article-item .read-more:hover {
    gap: 8px;
    color: var(--primary);
}

/* FAQ */
.faq-item {
    border-bottom: 1px solid var(--border-color);
    padding: 20px 0;
    transition: var(--transition);
}

.faq-item:first-child {
    border-top: 1px solid var(--border-color);
}

.faq-question {
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--primary);
    font-size: 1.05rem;
    padding: 4px 0;
    transition: var(--transition);
}

.faq-question:hover {
    color: var(--accent);
}

.faq-question .icon {
    font-size: 1rem;
    transition: transform 0.4s ease;
    color: var(--primary);
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(26, 58, 92, 0.06);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease, padding 0.4s ease, opacity 0.4s ease;
    padding-left: 0;
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.8;
    opacity: 0;
}

.faq-item.active .faq-answer {
    max-height: 600px;
    padding-top: 16px;
    opacity: 1;
}

.faq-item.active .faq-question .icon {
    transform: rotate(180deg);
    background: rgba(192, 57, 43, 0.1);
    color: var(--accent);
}

/* HowTo 步骤 */
.howto-step {
    display: flex;
    gap: 22px;
    margin-bottom: 28px;
    align-items: flex-start;
    transition: var(--transition);
    padding: 16px 20px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.5);
}

.howto-step:hover {
    background: rgba(255, 255, 255, 0.9);
    box-shadow: var(--shadow-sm);
    transform: translateX(6px);
}

.howto-step .step-num {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    flex-shrink: 0;
    font-size: 1.1rem;
    box-shadow: 0 4px 12px rgba(26, 58, 92, 0.25);
}

.howto-step .step-content h4 {
    color: var(--primary);
    margin-bottom: 6px;
    font-weight: 600;
}

/* 数字动画统计 */
.stats {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 30px;
    padding: 40px 0;
}

.stat-item {
    text-align: center;
    padding: 20px 30px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(8px);
    min-width: 140px;
    transition: var(--transition);
}

.stat-item:hover {
    transform: translateY(-4px);
    background: rgba(255, 255, 255, 0.9);
    box-shadow: var(--shadow-md);
}

.stat-item .num {
    font-size: 2.8rem;
    font-weight: 700;
    color: var(--primary);
    display: block;
    line-height: 1.2;
}

.stat-item .label {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-top: 6px;
    font-weight: 500;
}

/* 页脚 */
.footer {
    background: linear-gradient(135deg, #0f2440 0%, #1a3a5c 50%, #0f2440 100%);
    color: #ccc;
    padding: 60px 0 30px;
    font-size: 0.9rem;
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--accent), var(--primary-light), var(--accent));
}

.footer a {
    color: #aaa;
    transition: var(--transition);
}

.footer a:hover {
    color: #fff;
    padding-left: 4px;
}

.footer .grid-4 h4 {
    color: #fff;
    margin-bottom: 18px;
    font-size: 1.05rem;
    font-weight: 600;
}

.footer .grid-4 > div {
    line-height: 2.2;
}

.footer .copyright {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    margin-top: 35px;
    color: #999;
    font-size: 0.85rem;
    line-height: 1.8;
}

/* 返回顶部 */
.back-top {
    position: fixed;
    bottom: 40px;
    right: 30px;
    width: 52px;
    height: 52px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 999;
    border: none;
    box-shadow: 0 4px 20px rgba(26, 58, 92, 0.35);
}

.back-top.show {
    opacity: 1;
    visibility: visible;
}

.back-top:hover {
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    transform: translateY(-3px);
    box-shadow: 0 6px 25px rgba(192, 57, 43, 0.4);
}

/* 暗黑模式切换按钮 */
.dark-mode-toggle {
    position: fixed;
    bottom: 105px;
    right: 30px;
    width: 52px;
    height: 52px;
    background: #333;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    cursor: pointer;
    z-index: 999;
    border: none;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    transition: var(--transition);
}

.dark-mode-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 25px rgba(0,0,0,0.3);
}

/* 暗黑模式 */
body.dark {
    --bg-light: #1a1a2e;
    --bg-white: #16213e;
    --text-dark: #e0e0e0;
    --text-muted: #bbb;
    --text-light: #888;
    --border-color: #2a3a5c;
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.3);
    --shadow-md: 0 4px 20px rgba(0,0,0,0.4);
    background: #1a1a2e;
    color: #e0e0e0;
}

body.dark .header {
    background: rgba(22, 33, 62, 0.95);
    border-bottom-color: #2a3a5c;
}

body.dark .header .logo {
    color: #e0e0e0;
}

body.dark .nav a {
    color: #ccc;
}

body.dark .nav a:hover {
    background: rgba(255,255,255,0.06);
    color: #fff;
}

body.dark .breadcrumb {
    background: rgba(22, 33, 62, 0.9);
    border-bottom-color: #2a3a5c;
}

body.dark .breadcrumb a {
    color: #8ab4f8;
}

body.dark .section {
    background: #16213e;
}

body.dark .section:nth-child(even) {
    background: #0f3460;
}

body.dark .section-title {
    color: #e0e0e0;
}

body.dark .card {
    background: rgba(26, 26, 46, 0.85);
    backdrop-filter: blur(12px);
    border-color: #2a3a5c;
}

body.dark .card h3 {
    color: #e0e0e0;
}

body.dark .card p {
    color: #bbb;
}

body.dark .article-item {
    border-bottom-color: #2a3a5c;
}

body.dark .article-item h4 {
    color: #e0e0e0;
}

body.dark .article-item p {
    color: #bbb;
}

body.dark .faq-item {
    border-bottom-color: #2a3a5c;
}

body.dark .faq-question {
    color: #e0e0e0;
}

body.dark .faq-answer {
    color: #bbb;
}

body.dark .howto-step {
    background: rgba(26, 26, 46, 0.5);
}

body.dark .howto-step:hover {
    background: rgba(26, 26, 46, 0.8);
}

body.dark .stat-item {
    background: rgba(26, 26, 46, 0.6);
}

body.dark .stat-item .num {
    color: #8ab4f8;
}

body.dark .stat-item .label {
    color: #bbb;
}

body.dark .footer {
    background: linear-gradient(135deg, #0a0a1a 0%, #16213e 50%, #0a0a1a 100%);
}

body.dark .menu-toggle {
    color: #e0e0e0;
}

body.dark .menu-toggle:hover {
    background: rgba(255,255,255,0.06);
}

body.dark .search-results {
    background: #16213e;
    border-color: #2a3a5c;
}

body.dark .search-box input {
    background: #2a3a5c;
    color: #fff;
    border-color: #2a3a5c;
}

body.dark .lazy-placeholder {
    background: #2a3a5c;
}

/* 滚动动画 */
.fade-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* 站内搜索 */
.search-box {
    display: flex;
    gap: 8px;
    margin: 10px 0;
}

.search-box input {
    flex: 1;
    padding: 10px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 0.95rem;
    transition: var(--transition);
    background: rgba(255, 255, 255, 0.9);
    color: var(--text-dark);
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(26, 58, 92, 0.1);
}

.search-box button {
    padding: 10px 20px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
}

.search-box button:hover {
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
}

.search-results {
    background: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px;
    max-height: 320px;
    overflow-y: auto;
    display: none;
    box-shadow: var(--shadow-md);
    margin-top: 8px;
}

.search-results a {
    display: block;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-color);
    color: var(--primary);
    font-weight: 500;
    transition: var(--transition);
}

.search-results a:last-child {
    border-bottom: none;
}

.search-results a:hover {
    padding-left: 8px;
    color: var(--accent);
}

/* 图片懒加载占位 */
.lazy-placeholder {
    background: var(--border-color);
    border-radius: var(--radius-md);
    min-height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-light);
    font-size: 0.9rem;
}

/* 响应式微调 */
@media (max-width: 480px) {
    .section {
        padding: 50px 0;
    }
    
    .section-title {
        font-size: 1.5rem;
        margin-bottom: 30px;
    }
    
    .banner {
        height: 300px;
    }
    
    .banner-slide h2 {
        font-size: 1.3rem;
    }
    
    .banner-slide p {
        font-size: 0.95rem;
    }
    
    .stats {
        gap: 16px;
        padding: 20px 0;
    }
    
    .stat-item {
        padding: 16px 20px;
        min-width: 100px;
    }
    
    .stat-item .num {
        font-size: 2rem;
    }
    
    .back-top,
    .dark-mode-toggle {
        width: 44px;
        height: 44px;
        font-size: 1.2rem;
        right: 16px;
    }
    
    .back-top {
        bottom: 30px;
    }
    
    .dark-mode-toggle {
        bottom: 85px;
    }
    
    .search-box {
        flex-direction: column;
    }
    
    .search-box button {
        width: 100%;
    }
}

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

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

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

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

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

/* 打印样式 */
@media print {
    .back-top,
    .dark-mode-toggle,
    .search-box,
    .search-results,
    .banner-dots,
    .menu-toggle {
        display: none !important;
    }
    
    .header {
        position: static;
        box-shadow: none;
    }
    
    .section {
        padding: 30px 0;
        page-break-inside: avoid;
    }
}