/* ===================================
   甘言普通话测试 - 样式文件
   =================================== */

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

:root {
    /* 主题色 - 蓝色系 */
    --primary-color: #5B77F2;
    --primary-light: #7B93F5;
    --primary-dark: #4A5FD9;

    /* 辅助色 */
    --secondary-color: #2D3436;
    --accent-color: #00B894;

    /* 背景色 */
    --bg-primary: #FFFFFF;
    --bg-secondary: #F8F9FA;
    --bg-gradient: linear-gradient(135deg, #5B77F2 0%, #7B93F5 100%);

    /* 文字颜色 */
    --text-primary: #2D3436;
    --text-secondary: #636E72;
    --text-light: #B2BEC3;

    /* 其他 */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.15);
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    overflow-x: hidden;
}

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

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

img {
    max-width: 100%;
    height: auto;
}

/* ===================================
   导航栏
   =================================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-color);
}

.logo-img {
    height: 40px;
    width: auto;
    object-fit: contain;
}

.logo-icon {
    font-size: 28px;
}

.nav {
    display: flex;
    gap: 32px;
}

.nav-link {
    font-size: 15px;
    font-weight: 500;
    color: var(--text-secondary);
    padding: 8px 0;
    position: relative;
}

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

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: var(--transition);
}

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

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.menu-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    transition: var(--transition);
}

/* ===================================
   Hero区域
   =================================== */
.hero {
    position: relative;
    min-height: 100vh;
    background: var(--bg-gradient);
    padding-top: 70px;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    padding: 60px 0;
}

.hero-text {
    color: white;
}

.hero-title {
    font-size: 56px;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 24px;
}

.hero-title .highlight {
    display: block;
    color: #FFE5D9;
}

.hero-desc {
    font-size: 18px;
    opacity: 0.9;
    margin-bottom: 32px;
    max-width: 480px;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    margin-bottom: 48px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    border: none;
}

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

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.5);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.3);
}

.hero-stats {
    display: flex;
    gap: 40px;
}

.stat-item {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 32px;
    font-weight: 700;
}

.stat-label {
    font-size: 14px;
    opacity: 0.8;
}

/* 手机模型 */
.hero-image {
    display: flex;
    justify-content: center;
}

.hero-phone-img {
    max-width: 280px;
    width: 100%;
    height: auto;
    border-radius: 40px;
    box-shadow: var(--shadow-lg);
    animation: float 6s ease-in-out infinite;
}

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

.hero-wave {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
}

.hero-wave svg {
    display: block;
    width: 100%;
    height: 120px;
}

/* ===================================
   功能特点
   =================================== */
.features {
    padding: 100px 0;
    background: var(--bg-primary);
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-title {
    font-size: 40px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 16px;
}

.section-desc {
    font-size: 18px;
    color: var(--text-secondary);
}

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

.feature-card {
    background: var(--bg-primary);
    padding: 40px 30px;
    border-radius: var(--border-radius);
    text-align: center;
    transition: var(--transition);
    border: 1px solid #eee;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-md);
    border-color: transparent;
}

.feature-icon {
    font-size: 48px;
    margin-bottom: 20px;
}

.feature-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.feature-desc {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* ===================================
   考试资讯（列表样式）
   =================================== */
.news {
    padding: 100px 0;
    background: var(--bg-secondary);
}

.news-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.news-item {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    padding: 20px 24px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: var(--transition);
}

.news-item:hover {
    transform: translateX(8px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.news-item-tag {
    flex-shrink: 0;
    padding: 4px 12px;
    background: rgba(255, 107, 53, 0.1);
    color: var(--primary-color);
    font-size: 12px;
    font-weight: 500;
    border-radius: 20px;
}

.news-item-tag.hot {
    background: var(--primary-color);
    color: white;
}

.news-item-content {
    flex: 1;
    min-width: 0;
}

.news-item-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
    transition: var(--transition);
}

.news-item:hover .news-item-title {
    color: var(--primary-color);
}

.news-item-excerpt {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-item-meta {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    font-size: 13px;
    color: var(--text-light);
}

.news-more {
    text-align: center;
    margin-top: 40px;
}

.btn-outline {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    padding: 12px 32px;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-block;
}

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

/* ===================================
   用户使用场景
   =================================== */
.scenarios {
    padding: 100px 0;
    background: var(--bg-secondary);
}

.scenario-cards {
    display: flex;
    flex-direction: column;
    gap: 60px;
}

.scenario-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
    background: white;
    border-radius: 20px;
    padding: 48px;
    box-shadow: var(--shadow-sm);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    /* 滚动动画初始状态 */
    opacity: 0;
    transform: translateY(40px);
}

.scenario-card.animate-in {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.scenario-card.scenario-reverse .scenario-content {
    order: 2;
}

.scenario-card.scenario-reverse .scenario-gallery {
    order: 1;
}

.scenario-badge {
    display: inline-block;
    padding: 6px 20px;
    background: var(--bg-gradient);
    color: white;
    font-size: 14px;
    font-weight: 600;
    border-radius: 20px;
    margin-bottom: 16px;
}

.scenario-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 24px;
}

.scenario-detail {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.scenario-detail-item {
    padding-left: 16px;
    border-left: 3px solid var(--primary-light);
    transition: border-color 0.3s ease;
}

.scenario-card:hover .scenario-detail-item {
    border-left-color: var(--primary-color);
}

.detail-label {
    display: inline-block;
    font-size: 13px;
    font-weight: 600;
    color: var(--primary-color);
    background: rgba(91, 119, 242, 0.08);
    padding: 2px 10px;
    border-radius: 4px;
    margin-bottom: 6px;
}

.detail-text {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* 图片画廊 - 手机截图并排展示 */
.scenario-gallery {
    display: flex;
    justify-content: center;
    align-items: stretch;
    gap: 16px;
}

.gallery-item {
    flex: 1;
    max-width: 200px;
    overflow: hidden;
    border-radius: 16px;
    background: var(--bg-secondary);
    position: relative;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.gallery-item img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 16px;
}

.gallery-item:hover {
    transform: translateY(-6px) scale(1.03);
    box-shadow: 0 8px 24px rgba(91, 119, 242, 0.2);
}

/* ===================================
   常见问题
   =================================== */
.faq {
    padding: 100px 0;
    background: var(--bg-primary);
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faq-item {
    background: white;
    border-radius: 12px;
    border: 1px solid #eee;
    overflow: hidden;
    transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

.faq-item:hover {
    border-color: rgba(91, 119, 242, 0.2);
}

.faq-item.active {
    box-shadow: 0 4px 16px rgba(91, 119, 242, 0.1);
    border-color: var(--primary-light);
}

.faq-question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    cursor: pointer;
    user-select: none;
    gap: 16px;
}

.faq-question h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.5;
}

.faq-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    position: relative;
    transition: transform 0.3s ease;
}

.faq-icon::before,
.faq-icon::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    background: var(--primary-color);
    border-radius: 2px;
    transition: transform 0.3s ease;
}

.faq-icon::before {
    width: 14px;
    height: 2px;
    transform: translate(-50%, -50%);
}

.faq-icon::after {
    width: 2px;
    height: 14px;
    transform: translate(-50%, -50%);
}

.faq-item.active .faq-icon::after {
    transform: translate(-50%, -50%) rotate(90deg);
    opacity: 0;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.3s ease;
}

.faq-item.active .faq-answer {
    max-height: 300px;
}

.faq-answer p {
    padding: 0 24px 20px;
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.8;
}

/* ===================================
   用户评价
   =================================== */
.testimonials {
    padding: 100px 0;
    background: var(--bg-primary);
}

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

.testimonial-card {
    background: white;
    padding: 32px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.stars {
    color: #FFC107;
    font-size: 18px;
    margin-bottom: 16px;
}

.testimonial-text {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 24px;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 12px;
}

.author-avatar {
    width: 48px;
    height: 48px;
    background: var(--bg-secondary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.author-name {
    display: block;
    font-weight: 600;
    font-size: 15px;
}

.author-title {
    font-size: 13px;
    color: var(--text-light);
}

/* ===================================
   下载区域
   =================================== */
.download {
    padding: 100px 0;
    background: var(--bg-gradient);
    color: white;
}

.download-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.download-title {
    font-size: 40px;
    font-weight: 700;
    margin-bottom: 16px;
}

.download-desc {
    font-size: 18px;
    opacity: 0.9;
    margin-bottom: 40px;
}

.download-buttons {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 40px;
}

.download-btn {
    display: flex;
    align-items: center;
    gap: 16px;
    background: rgba(255, 255, 255, 0.15);
    border: 2px solid rgba(255, 255, 255, 0.3);
    padding: 16px 24px;
    border-radius: 12px;
    transition: var(--transition);
}

.download-btn:hover {
    background: rgba(255, 255, 255, 0.25);
}

.btn-icon-large {
    font-size: 36px;
}

.btn-text {
    text-align: left;
}

.btn-small {
    display: block;
    font-size: 12px;
    opacity: 0.8;
}

.btn-large {
    display: block;
    font-size: 20px;
    font-weight: 600;
}

.download-qr {
    text-align: center;
}

.qr-code {
    width: 140px;
    height: 140px;
    background: white;
    border-radius: 12px;
    margin: 0 auto 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qr-placeholder {
    color: var(--text-secondary);
    font-size: 14px;
}

.download-qr p {
    font-size: 14px;
    opacity: 0.8;
}

.download-image {
    display: flex;
    justify-content: center;
}

.phones-group {
    position: relative;
    width: 300px;
    height: 500px;
}

.phones-group .phone {
    position: absolute;
    width: 220px;
    height: 440px;
    background: #1a1a1a;
    border-radius: 32px;
    box-shadow: var(--shadow-lg);
}

.phones-group .phone::after {
    content: '';
    position: absolute;
    inset: 8px;
    background: white;
    border-radius: 26px;
}

.phones-group .phone-1 {
    left: 0;
    top: 30px;
    transform: rotate(-8deg);
    background: var(--bg-gradient);
}

.phones-group .phone-2 {
    right: 0;
    top: 0;
    transform: rotate(8deg);
    background: linear-gradient(135deg, #00B894 0%, #00D9A5 100%);
}

/* ===================================
   关于我们
   =================================== */
.about {
    padding: 100px 0;
    background: var(--bg-secondary);
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.about-text p {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 20px;
}

.about-stats {
    display: flex;
    justify-content: center;
    gap: 60px;
    margin-top: 48px;
}

.about-stat {
    text-align: center;
}

.about-stat-number {
    display: block;
    font-size: 36px;
    font-weight: 700;
    color: var(--primary-color);
}

.about-stat-label {
    font-size: 14px;
    color: var(--text-secondary);
}

/* ===================================
   页脚
   =================================== */
.footer {
    background: #1a1a1a;
    color: white;
    padding: 80px 0 30px;
}

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

.footer-brand .logo {
    margin-bottom: 16px;
}

.footer-desc {
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 20px;
}

.social-links {
    display: flex;
    gap: 16px;
}

.social-link {
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    font-size: 14px;
}

.social-link:hover {
    background: var(--primary-color);
}

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

.footer-column h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 20px;
}

.footer-column a,
.footer-column .footer-text {
    display: block;
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
    padding: 6px 0;
}

.footer-column a:hover {
    color: var(--primary-color);
}

.footer-qr-img {
    width: 120px;
    height: 120px;
    background: white;
    border-radius: 8px;
    padding: 6px;
    margin-top: 4px;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
    text-align: center;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.4);
}

/* ===================================
   返回顶部
   =================================== */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    box-shadow: var(--shadow-md);
    z-index: 999;
}

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

.back-to-top:hover {
    background: var(--primary-dark);
    transform: translateY(-3px);
}

/* ===================================
   下载弹窗
   =================================== */
.download-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 15vh;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    cursor: pointer;
}

.download-modal.active {
    opacity: 1;
    visibility: visible;
}

.download-modal-content {
    background: white;
    width: 90%;
    max-width: 360px;
    padding: 40px 30px;
    border-radius: 20px;
    text-align: center;
    transform: scale(0.9);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.download-modal.active .download-modal-content {
    transform: scale(1);
    opacity: 1;
}

.download-qr-img {
    width: 200px;
    height: 200px;
    margin: 0 auto 20px;
    background: #f5f5f5;
    border-radius: 12px;
    object-fit: contain;
}

.download-qr-text {
    font-size: 16px;
    color: var(--text-primary);
    font-weight: 500;
}

/* ===================================
   响应式设计
   =================================== */
@media (max-width: 1024px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-text {
        order: 1;
    }

    .hero-image {
        order: 2;
    }

    .hero-desc {
        margin: 0 auto 32px;
    }

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

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

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

    .news-list {
        gap: 12px;
    }

    .news-item {
        flex-direction: column;
        gap: 12px;
    }

    .news-item-meta {
        flex-direction: row;
        gap: 16px;
    }

    .scenario-card {
        grid-template-columns: 1fr;
        gap: 32px;
        padding: 32px;
    }

    .scenario-card.scenario-reverse .scenario-content,
    .scenario-card.scenario-reverse .scenario-gallery {
        order: unset;
    }

    .scenario-gallery {
        justify-content: center;
    }

    .gallery-item {
        max-width: 180px;
    }

    .testimonials-slider {
        grid-template-columns: 1fr;
    }

    .download-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .download-buttons {
        align-items: center;
    }

    .download-qr {
        margin-top: 32px;
    }

    .footer-content {
        grid-template-columns: 1fr;
    }

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

@media (max-width: 768px) {
    .nav {
        display: none;
        position: absolute;
        top: 70px;
        left: 0;
        right: 0;
        background: white;
        flex-direction: column;
        padding: 20px;
        gap: 16px;
        box-shadow: var(--shadow-md);
    }

    .nav.active {
        display: flex;
    }

    .menu-toggle {
        display: flex;
    }

    .hero-title {
        font-size: 36px;
    }

    .hero-stats {
        flex-direction: column;
        gap: 20px;
    }

    .section-title {
        font-size: 32px;
    }

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

    .news-item {
        flex-direction: column;
        gap: 12px;
        padding: 16px;
    }

    .news-item-meta {
        flex-direction: row;
        gap: 16px;
    }

    .scenario-title {
        font-size: 24px;
    }

    .scenario-gallery {
        flex-wrap: nowrap;
        gap: 10px;
    }

    .gallery-item {
        max-width: 140px;
    }

    .scenario-card {
        padding: 24px;
        gap: 24px;
    }

    .download-title {
        font-size: 32px;
    }

    .about-stats {
        flex-direction: column;
        gap: 30px;
    }

    .footer-links {
        grid-template-columns: 1fr 1fr;
        gap: 30px;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 28px;
    }

    .hero-desc {
        font-size: 16px;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }

    .hero-phone-img {
        max-width: 240px;
    }

    .footer-links {
        grid-template-columns: 1fr;
    }

    .scenario-gallery {
        gap: 8px;
    }

    .gallery-item {
        max-width: 120px;
    }

}
