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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
    background-color: #fff;
}

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

/* 主题色变量 */
:root {
    --primary-color: #b38500;
    --primary-color-rgb: 179,133,0;
    --primary-color-light: #c89726;
    --primary-color-dark: #8d6800;
    --primary-gradient: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-color-light) 100%);
    /* Accent (secondary) color palette */
    --accent-color: #3d6af2;
    --accent-color-light: #6f8ff9;
    --accent-color-dark: #1d49b0;
    --accent-gradient: linear-gradient(90deg, var(--accent-color) 0%, var(--accent-color-light) 100%);
    --theme-transition: background-color .35s ease, color .35s ease, box-shadow .35s ease;
    /* 自适应 HERO 内边距 (F)：随视口高度在手机与桌面之间平滑过渡 */
    --hero-pad-top: clamp(72px, 14vh, 120px);
    --hero-pad-bottom: clamp(56px, 10vh, 90px);
}

/* 导航栏 */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    /* 初始透明导航 (C) */
    background: transparent;
    border-bottom: none;
    box-shadow: none;
    padding: 1rem 0;
    transition: all 0.3s ease;
    z-index: 1000;
}

.navbar::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 0;
  pointer-events: none;
  background: linear-gradient(to bottom, rgba(0,0,0,0.18), rgba(0,0,0,0));
  opacity: .55;
  transition: opacity .35s ease;
}
/* 导航底部分隔渐变 (B) 仅在未滚动时出现 */
.navbar.scrolled::after { opacity: 0; }
.navbar.scrolled {
    background: rgba(255,255,255,0.95);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

/* 透明态下导航文字与按钮调白提高可读性 (C) */
.navbar:not(.scrolled) .brand { color: #fff; }
.navbar:not(.scrolled) .nav-links a { color: rgba(255,255,255,0.9); }
.navbar:not(.scrolled) .nav-links a:hover { color: #fff; }
.navbar:not(.scrolled) .theme-toggle { background: rgba(0,0,0,0.35); backdrop-filter: blur(6px); box-shadow: 0 4px 16px rgba(0,0,0,0.35); }
html[data-theme="dark"] .navbar:not(.scrolled) .theme-toggle { background: rgba(255,255,255,0.17); }

/* 导航栏内容 */
.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    object-fit: cover;
}

.brand {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2d3748;
    text-decoration: none;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    text-decoration: none;
    color: #4a5568;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-links a:hover {
    color: var(--primary-color);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    /* 使用强调色渐变而非主色，突出交互层级 */
    background: var(--accent-gradient);
    transition: width 0.3s ease;
}

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

/* 首页横幅 */
.hero {
    /* 移除原来的 margin-top: 80px 以消除顶部“缝” */
    margin-top: 0;
    /* 保留原有的上下内边距，若需要保持原视觉下移可把 padding-top 改为 120px */
    padding: var(--hero-pad-top) 0 var(--hero-pad-bottom);
    background: var(--primary-gradient);
    color: white;
    overflow: hidden;
    position: relative;
}

.hero::after { /* Vignette 顶部/边缘渐晕聚焦内容 */
  content: '';
  position: absolute; inset: 0;
  pointer-events: none;
  background:
    radial-gradient(120% 90% at 50% 0%, rgba(0,0,0,0.30), rgba(0,0,0,0) 55%),
    linear-gradient(to bottom, rgba(0,0,0,0.30), rgba(0,0,0,0) 38%);
  mix-blend-mode: normal;
}

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

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-content {
    animation: slideInLeft 1s ease-out;
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.hero-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    line-height: 1.6;
}

.hero-features {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 2.5rem;
}

.feature-tag {
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn-primary {
    background: linear-gradient(45deg, var(--primary-color), var(--primary-color-light));
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(var(--primary-color-rgb), 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(var(--primary-color-rgb), 0.4);
}

.btn-secondary {
    background: transparent;
    color: white;
    border: 2px solid white;
    padding: 12px 26px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: white;
    color: var(--primary-color);
}

/* 新增强调色按钮样式 */
.btn-accent {
    background: linear-gradient(45deg, var(--accent-color), var(--accent-color-light));
    color: #fff;
    border: none;
    padding: 14px 28px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .3s ease;
    box-shadow: 0 4px 15px rgba(61,106,242,0.35);
}

.btn-accent:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(61,106,242,0.45);
}

/* 显式主题覆盖（优先级高于 prefers-color-scheme） */
html[data-theme="dark"] {
  color-scheme: dark;
}
html[data-theme="dark"] body { background:#111; color:#e8e8e8; transition: var(--theme-transition); }
html[data-theme="dark"] .hero { background: var(--primary-gradient); }
html[data-theme="dark"] .feature-card,
html[data-theme="dark"] .screenshot-item img,
html[data-theme="dark"] .qr-code,
html[data-theme="dark"] .modal-content,
html[data-theme="dark"] .content-container,
html[data-theme="dark"] .qr-code-overlay-inner { background:#1c1c1c; box-shadow:0 10px 28px rgba(0,0,0,.55); border:1px solid #2a2a2a; }
html[data-theme="dark"] .content-text { background:#181818; border-left:4px solid var(--primary-color); color:#f1f1f1; }
html[data-theme="dark"] .btn-secondary { background:#222; color:#ddd; border:1px solid #333; }
html[data-theme="dark"] .btn-secondary:hover { background:#2b2b2b; }
html[data-theme="dark"] .nav-links a { color:#c8c8c8; }
html[data-theme="dark"] .nav-links a:hover { color: var(--accent-color-light); }
html[data-theme="dark"] .footer { background:#141414; }
html[data-theme="dark"] .footer-bottom { border-top:1px solid #2a2a2a; }
html[data-theme="dark"] .modal { background: rgba(0,0,0,0.6); }
html[data-theme="dark"] .theme-toggle { background:linear-gradient(45deg,#333,#222); color:#f5f5f5; }

/* 亮色强制模式（覆盖系统暗色） */
html[data-theme="light"] body { background:#fff; color:#333; transition: var(--theme-transition); }
html[data-theme="light"] .theme-toggle { background:linear-gradient(45deg,var(--accent-color),var(--accent-color-light)); color:#fff; }

/* 主题切换按钮基础样式 */
.theme-toggle {
  cursor:pointer;
  padding:8px 18px;
  border:none;
  border-radius:28px;
  font-size:13px;
  font-weight:600;
  display:inline-flex;
  align-items:center;
  gap:6px;
  background:linear-gradient(45deg,var(--accent-color),var(--accent-color-light));
  color:#fff;
  box-shadow:0 4px 12px rgba(0,0,0,.15);
  transition:all .3s ease;
}
.theme-toggle:hover { transform:translateY(-2px); box-shadow:0 6px 18px rgba(0,0,0,.25); }
.theme-toggle:active { transform:translateY(0) scale(.97); }
.theme-toggle .mode-icon { font-size:16px; line-height:1; }

/* Ripple 容器补充（若按钮有 overflow hidden 仍需适配） */
.btn-primary, .btn-secondary, .btn-accent, .theme-toggle { position:relative; overflow:hidden; }

/* 功能特色 */
.features {
    padding: 100px 0;
    background: #f8fafc;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 3rem;
    color: #2d3748;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-color-light));
    border-radius: 2px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
}

.feature-card {
    background: white;
    padding: 40px 30px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid #e2e8f0;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    display: block;
}

.feature-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #2d3748;
}

.feature-card p {
    color: #718096;
    line-height: 1.7;
    font-size: 1rem;
}

/* 产品截图 */
.screenshots {
    padding: 100px 0;
    background: white;
}

.screenshots-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.screenshot-item {
    text-align: center;
    transition: transform 0.3s ease;
}

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

.screenshot-item img {
    width: 100%;
    max-width: 250px;
    height: auto;
    border-radius: 20px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    margin-bottom: 1rem;
}

.screenshot-item p {
    font-weight: 500;
    color: #4a5568;
    font-size: 1rem;
}

/* 数据统计 */
.stats {
    padding: 80px 0;
    background: var(--primary-gradient);
    color: white;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
}

.stat-item {
    text-align: center;
    padding: 20px;
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    background: linear-gradient(45deg, #fff, #f0f8ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 1.1rem;
    opacity: 0.9;
    font-weight: 500;
}

/* 下载体验 */
.download {
    padding: 100px 0;
    background: #f8fafc;
    text-align: center;
}

.download-content h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: #2d3748;
}

.download-content p {
    font-size: 1.2rem;
    color: #718096;
    margin-bottom: 3rem;
}

.qr-code-container {
    margin: 3rem 0;
}

.qr-code {
    display: inline-block;
    background: white;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

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

.qr-code img {
    width: 200px;
    height: 200px;
    border-radius: 10px;
}

.qr-code p {
    margin-top: 15px;
    font-weight: 500;
    color: #4a5568;
}

.download-features {
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
    margin-top: 3rem;
}

.download-feature {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.1rem;
    font-weight: 500;
    color: #4a5568;
}

.check-icon {
    color: #38a169;
    font-weight: 700;
    font-size: 1.2rem;
}

/* 页脚 */
.footer {
    background: #2d3748;
    color: white;
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 60px;
    margin-bottom: 40px;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.footer-logo {
    width: 40px;
    height: 40px;
    border-radius: 10px;
}

.footer-brand p {
    color: #a0aec0;
    font-size: 1rem;
    line-height: 1.6;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 40px;
}

.footer-section h4 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: white;
}

.footer-section a {
    display: block;
    color: #a0aec0;
    text-decoration: none;
    margin-bottom: 0.5rem;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: #63b3ed;
}

.footer-bottom {
    border-top: 1px solid #4a5568;
    padding-top: 20px;
    text-align: center;
}

.footer-bottom p {
    color: #a0aec0;
    font-size: 0.9rem;
}

/* 二维码弹窗 */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
}

.modal-content {
    background-color: white;
    margin: 10% auto;
    padding: 40px;
    border-radius: 20px;
    width: 90%;
    max-width: 400px;
    text-align: center;
    position: relative;
    animation: modalSlideIn 0.3s ease-out;
}

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

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    position: absolute;
    right: 20px;
    top: 15px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close:hover {
    color: #333;
}

.modal-content h3 {
    margin-bottom: 2rem;
    color: #2d3748;
    font-size: 1.5rem;
}

.modal-qr img {
    width: 200px;
    height: 200px;
    border-radius: 10px;
    margin-bottom: 1rem;
}

.modal-qr p {
    color: #718096;
    font-weight: 500;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-actions {
        justify-content: center;
    }

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

    .screenshots-gallery {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 20px;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .download-features {
        flex-direction: column;
        gap: 20px;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }

    .footer-brand {
        align-items: center; /* 居中内部元素，修复移动端错位 */
    }

    .footer-links {
        display: flex; /* 改为 flex 便于水平居中换行 */
        flex-wrap: wrap;
        justify-content: center;
        gap: 32px 48px; /* 行列间距 */
    }

    .footer-section {
        min-width: 120px; /* 防止过窄导致换行不均匀 */
    }

    .footer-section h4 {
        margin-bottom: 0.75rem; /* 移动端稍微紧凑 */
    }

    .footer-logo {
        margin-bottom: 4px; /* 让 Logo 和文字间距更协调 */
    }

    /* .hero { padding: 90px 0 70px; } 由 clamp 接管 */
}

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

    /* .hero { padding: 72px 0 56px; } 由 clamp 接管 */

    .hero-title {
        font-size: 2rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .features, .screenshots, .download {
        padding: 60px 0;
    }

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

    .modal-content {
        margin: 20% auto;
        padding: 30px 20px;
    }
}
