/* =========================================
   全局重置与变量定义
========================================= */
:root {
    --primary-color: #FF5252;
    --primary-hover: #E03E3E;
    --secondary-color: #222222;
    --text-color: #222222;
    --text-light: #555555;
    --bg-color: #FFF8EC;
    --bg-light: #FFF0D4;
    --border-color: #EEDCC1;
    --border-radius: 16px;
    --transition: all 0.3s ease;
    --memphis-yellow: #FFD93D;
    --memphis-blue: #4D96FF;
    --memphis-green: #6BCB77;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--bg-color);
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: var(--transition);
}

a:hover {
    color: var(--primary-hover);
}

ul {
    list-style: none;
}

/* =========================================
   布局容器 (Container & Grid)
========================================= */
.container {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

.text-center { text-align: center; }
.bg-light { background-color: var(--bg-light); }
.bg-primary { background-color: var(--primary-color); color: white; }

/* Grid 布局 */
.grid-3, .grid-2 {
    display: grid;
    gap: 30px;
}
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

/* =========================================
   组件 (Components)
========================================= */
/* 按钮 */
.btn {
    display: inline-block;
    padding: 10px 24px;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    border: 2px solid transparent;
}

.btn-large {
    padding: 14px 32px;
    font-size: 18px;
}

.btn-full {
    display: block;
    width: 100%;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}
.btn-primary:hover {
    background-color: var(--primary-hover);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 107, 43, 0.3);
}

.btn-secondary {
    background-color: var(--bg-light);
    color: var(--text-color);
    border-color: var(--border-color);
}
.btn-secondary:hover {
    background-color: #e2e6ea;
}

.btn-outline {
    background-color: transparent;
    color: var(--primary-color);
    border-color: var(--primary-color);
}
.btn-outline:hover {
    background-color: var(--primary-color);
    color: white;
}

.btn-white {
    background-color: white;
    color: var(--primary-color);
}
.btn-white:hover {
    background-color: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* 卡片 */
.card {
    background: white;
    border-radius: var(--border-radius);
    padding: 30px;
    box-shadow: 0 10px 30px rgba(255, 82, 82, 0.08);
    transition: var(--transition);
    border: 2px solid var(--border-color);
}
.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
}

.icon {
    font-size: 40px;
    margin-bottom: 20px;
}

/* =========================================
   区块样式 (Sections)
========================================= */
section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    font-size: 32px;
    margin-bottom: 15px;
    color: var(--secondary-color);
}
.section-subtitle {
    text-align: center;
    color: var(--text-light);
    margin-bottom: 50px;
    font-size: 18px;
}

/* 导航栏 */
.navbar {
    padding: 20px 0;
    background: white;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
}
.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.logo {
    font-size: 24px;
    font-weight: 800;
    color: var(--primary-color);
}
.nav-links {
    display: flex;
    gap: 25px;
    align-items: center;
}
.nav-links a {
    color: var(--secondary-color);
    font-weight: 600;
    font-size: 16px;
}
.nav-links a:hover {
    color: var(--primary-color);
}

/* 主视觉 (Hero) */
.hero {
    text-align: center;
    padding: 100px 0;
    background: transparent;
}
.hero h1 {
    font-size: 48px;
    color: var(--secondary-color);
    margin-bottom: 20px;
    line-height: 1.2;
}
.hero .subtitle {
    font-size: 20px;
    color: var(--text-light);
    max-width: 700px;
    margin: 0 auto 40px;
}
.hero-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}
.hero-note {
    color: var(--text-light);
    font-size: 14px;
}

/* 优势与流媒体 (Features & Streaming) */
.feature-card h3, .media-card h3 {
    margin-bottom: 15px;
    font-size: 20px;
    color: var(--secondary-color);
}
.feature-card p, .media-card p {
    color: var(--text-light);
}
.media-card p {
    margin-bottom: 20px;
}
.text-link {
    font-weight: 600;
}

/* 价格 (Pricing) */
.pricing-card {
    text-align: center;
    position: relative;
}
.pricing-card.popular {
    border: 2px solid var(--primary-color);
    transform: scale(1.05);
}
.pricing-card.popular:hover {
    transform: scale(1.05) translateY(-5px);
}
.badge {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary-color);
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
}
.pricing-card h3 {
    font-size: 22px;
    margin-bottom: 15px;
}
.pricing-card .price {
    font-size: 28px;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 20px;
}
.pricing-features {
    text-align: left;
    margin-bottom: 30px;
}
.pricing-features li {
    margin-bottom: 12px;
    color: var(--text-light);
}

/* 评价 (Reviews) */
.review-card .stars {
    margin-bottom: 15px;
    font-size: 20px;
}
.review-card p {
    font-style: italic;
    color: var(--text-light);
    margin-bottom: 20px;
}
.review-card .user {
    font-weight: bold;
    color: var(--secondary-color);
}

/* 常见问题 (FAQ) */
.faq-list {
    max-width: 800px;
    margin: 0 auto;
}
.faq-item {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-bottom: 15px;
    overflow: hidden;
}
.faq-item summary {
    padding: 20px;
    font-weight: 600;
    font-size: 18px;
    cursor: pointer;
    color: var(--secondary-color);
    list-style: none; /* 隐藏默认箭头，部分浏览器生效 */
    position: relative;
    user-select: none;
}
.faq-item summary::-webkit-details-marker {
    display: none; /* 隐藏 Webkit 默认箭头 */
}
.faq-item summary::after {
    content: '+';
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 24px;
    color: var(--primary-color);
    transition: var(--transition);
}
.faq-item[open] summary::after {
    content: '-';
}
.faq-item[open] summary {
    border-bottom: 1px solid var(--border-color);
}
.faq-content {
    padding: 20px;
    color: var(--text-light);
    line-height: 1.8;
}

/* 底部 CTA (Bottom CTA) */
.bottom-cta h2 {
    font-size: 36px;
    margin-bottom: 15px;
}
.bottom-cta p {
    font-size: 18px;
    margin-bottom: 30px;
    opacity: 0.9;
}

/* 页脚 (Footer) */
.footer {
    background: #1a252f;
    color: #a0aec0;
    padding: 60px 0 20px;
}
.footer-grid {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}
.footer-brand .logo {
    color: white;
    margin-bottom: 10px;
}
.footer-links {
    display: flex;
    gap: 30px;
}
.footer-links a {
    color: #a0aec0;
    font-size: 15px;
}
.footer-links a:hover {
    color: white;
}
.footer-bottom {
    text-align: center;
    font-size: 14px;
}

/* =========================================
   孟菲斯波普风背景装饰 (Memphis Decorations)
========================================= */
.memphis-decorations {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    pointer-events: none; z-index: -1; overflow: hidden;
}

.decor { position: absolute; }

/* 右上角静态半调波点 */
.halftone-dots {
    top: -50px; right: -50px; width: 350px; height: 350px;
    background-image: radial-gradient(rgba(0,0,0,0.15) 15%, transparent 16%);
    background-size: 15px 15px; opacity: 0.7;
}

/* 浮动与摇摆动画 */
@keyframes float-wobble {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-25px) rotate(5deg); }
}

@keyframes float-wobble-alt {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(20px) rotate(-5deg); }
}

/* 匀速自转动画 */
@keyframes spin-linear {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 几何小元素样式与定位 */
.shape.solid-red-circle {
    width: 45px; height: 45px; background: var(--primary-color);
    border-radius: 50%; top: 15%; left: 8%;
    animation: float-wobble 7s ease-in-out infinite;
}

.shape.blue-ring {
    width: 55px; height: 55px; border: 7px solid var(--memphis-blue);
    border-radius: 50%; top: 75%; left: 12%;
    animation: float-wobble-alt 8.5s ease-in-out infinite;
}

.shape.yellow-triangle {
    width: 0; height: 0;
    border-left: 28px solid transparent; border-right: 28px solid transparent;
    border-bottom: 48px solid var(--memphis-yellow);
    top: 22%; right: 12%;
    animation: float-wobble 9s ease-in-out infinite;
}

.shape.green-cross {
    width: 45px; height: 45px; background: var(--memphis-green);
    clip-path: polygon(33% 0, 66% 0, 66% 33%, 100% 33%, 100% 66%, 66% 66%, 66% 100%, 33% 100%, 33% 66%, 0 66%, 0 33%, 33% 33%);
    top: 65%; right: 9%;
    animation: float-wobble-alt 6.5s ease-in-out infinite;
}

.shape.black-dot {
    width: 18px; height: 18px; background: var(--secondary-color);
    border-radius: 50%; bottom: 12%; left: 25%;
    animation: float-wobble 6s ease-in-out infinite;
}

.shape.red-square {
    width: 25px; height: 25px; background: var(--primary-color);
    top: 45%; left: 6%;
    animation: spin-linear 7s linear infinite;
}

.shape.blue-square {
    width: 32px; height: 32px; background: var(--memphis-blue);
    bottom: 25%; right: 18%;
    animation: spin-linear 9s linear infinite reverse;
}

/* 降级动画处理 */
@media (prefers-reduced-motion: reduce) {
    .decor.shape { animation: none !important; transform: none !important; }
}

/* =========================================
   响应式设计 (Media Queries) 移动端适配
========================================= */
@media (max-width: 768px) {
    .nav-container {
        flex-direction: column;
        gap: 15px;
    }
    
    /* 强行转为单栏布局 */
    .grid-3, .grid-2 {
        grid-template-columns: 1fr;
    }
    
    /* 按钮优化：适合手指点击，撑满屏幕 */
    .btn {
        padding: 14px 24px;
        font-size: 18px;
    }
    
    section {
        padding: 50px 0;
    }
    
    .hero {
        padding: 60px 0;
    }
    
    .hero h1 {
        font-size: 32px;
    }
    
    .hero .subtitle {
        font-size: 16px;
        margin-bottom: 30px;
    }
    
    .hero-actions {
        flex-direction: column;
        gap: 15px;
    }
    
    .pricing-card.popular {
        transform: none;
    }
    .pricing-card.popular:hover {
        transform: translateY(-5px);
    }
    
    .footer-grid {
        flex-direction: column;
        text-align: center;
        gap: 30px;
    }
    
    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: 20px;
    }
}

/* =========================================
   无障碍：跳过导航链接 (Skip Link)
========================================= */
.skip-link {
    position: absolute;
    top: -100px;
    left: 16px;
    background: var(--primary-color);
    color: #fff;
    padding: 10px 20px;
    border-radius: 0 0 8px 8px;
    font-weight: 700;
    font-size: 15px;
    z-index: 9999;
    transition: top 0.2s ease;
    text-decoration: none;
}
.skip-link:focus {
    top: 0;
}

/* =========================================
   无障碍：键盘焦点样式 (Focus Visible)
========================================= */
:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 3px;
    border-radius: 4px;
}
a:focus-visible,
button:focus-visible,
summary:focus-visible,
.btn:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 3px;
}

/* =========================================
   锚点 scroll-margin-top（防止固定导航遮挡）
========================================= */
#features,
#pricing,
#main-content {
    scroll-margin-top: 80px;
}

/* 确保按钮触摸区不小于 44px */
.btn {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
