/* ========== 全局样式 ========== */
:root {
    --primary-color: #0b74ff;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --light-bg: #f8f9fa;
    --white: #ffffff;
    --text-dark: #2b2f36;
    --text-gray: #6c757d;
    --border-color: #dee2e6;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --radius: 12px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", 
                 Roboto, Helvetica, Arial, sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
    background: var(--white);
}

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

/* ========== 导航栏 ========== */
.navbar {
    background: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 20px;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--text-dark);
}

.logo {
    font-size: 2rem;
}

/* Logo图片样式 */
.logo-img {
    height: 45px !important;
    width: auto !important;
    max-width: 45px !important;
    display: block;
    object-fit: contain;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    transition: color 0.3s;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--primary-color);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-dark);
    border-radius: 2px;
    transition: all 0.3s;
}

/* ========== Hero Section ========== */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: var(--white);
    padding: 80px 0;
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-title {
    font-size: 3rem;
    margin-bottom: 1rem;
}

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

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

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: var(--radius);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
}

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

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

.btn-secondary {
    background: transparent;
    color: var(--white);
    border: 2px solid var(--white);
}

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

.btn-secondary.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Hero Image - GIF演示 */
.hero-image {
    display: flex;
    align-items: center;
    justify-content: center;
}

.demo-gif {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

/* ========== 功能特性 ========== */
.features {
    padding: 80px 0;
    background: var(--light-bg);
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
}

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

.feature-card {
    background: var(--white);
    padding: 2rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    text-align: center;
    transition: transform 0.3s;
}

.feature-card:hover {
    transform: translateY(-5px);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.feature-card h3 {
    margin-bottom: 1rem;
    color: var(--text-dark);
}

.feature-card p {
    color: var(--text-gray);
}

/* ========== 使用场景 ========== */
.use-cases {
    padding: 80px 0;
}

.use-cases-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.use-case-card {
    text-align: center;
    padding: 2rem;
}

.use-case-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.use-case-card h3 {
    margin-bottom: 1rem;
}

/* ========== 下载区域 ========== */
.download {
    padding: 80px 0;
    background: var(--light-bg);
}

.download-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.download-card {
    background: var(--white);
    padding: 3rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    text-align: center;
}

.platform-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.download-card h3 {
    margin-bottom: 0.5rem;
}

.download-card .version {
    color: var(--text-gray);
    font-size: 0.9rem;
    margin: 1rem 0 2rem;
}

/* ========== 教程页面 ========== */
.page-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: var(--white);
    padding: 60px 0;
    text-align: center;
}

.page-header h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.tutorial-section {
    padding: 80px 0;
}

.tutorial-category {
    margin-bottom: 4rem;
}

.category-title {
    font-size: 2rem;
    margin-bottom: 2rem;
    color: var(--text-dark);
}

.videos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 2rem;
}

.video-card {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: transform 0.3s;
}

.video-card:hover {
    transform: translateY(-5px);
}

.video-thumbnail {
    position: relative;
    width: 100%;
    padding-top: 56.25%; /* 16:9 aspect ratio */
    background: var(--light-bg);
}

.video-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.play-icon {
    font-size: 3rem;
    color: var(--white);
    opacity: 0.8;
}

.video-info {
    padding: 1.5rem;
}

.video-info h3 {
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.video-info p {
    color: var(--text-gray);
    margin-bottom: 1rem;
}

.video-duration {
    display: inline-block;
    color: var(--text-gray);
    font-size: 0.9rem;
}

/* 文字教程 */
.text-tutorials {
    padding: 80px 0;
    background: var(--light-bg);
}

.text-tutorial-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.text-tutorial-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    background: var(--white);
    padding: 2rem;
    border-radius: var(--radius);
    text-decoration: none;
    color: var(--text-dark);
    transition: transform 0.3s;
}

.text-tutorial-item:hover {
    transform: translateX(10px);
}

.tutorial-icon {
    font-size: 3rem;
}

.tutorial-text h3 {
    margin-bottom: 0.5rem;
}

.tutorial-text p {
    color: var(--text-gray);
}

/* ========== 页脚 ========== */
.footer {
    background: var(--text-dark);
    color: var(--white);
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section a:hover {
    color: var(--white);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.5);
}

/* ========== 响应式设计 ========== */
@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background: var(--white);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: var(--shadow);
        padding: 2rem 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-toggle {
        display: flex;
    }

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

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

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

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

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

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

    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}

/* ========== 模态框样式 ========== */
.modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    animation: fadeIn 0.3s ease;
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-radius: 20px;
    padding: 40px;
    max-width: 700px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.4s ease;
}

.modal-content h2 {
    color: #2c3e50;
    font-size: 2rem;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 3px solid var(--primary-color);
    display: inline-block;
}

.modal-body {
    color: #555;
    font-size: 1rem;
    line-height: 1.8;
}

.modal-body p {
    margin-bottom: 18px;
    text-align: justify;
}

.modal-body p:last-child {
    margin-bottom: 0;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 25px;
    font-size: 32px;
    font-weight: bold;
    color: #999;
    cursor: pointer;
    transition: all 0.3s ease;
    line-height: 1;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: transparent;
}

.modal-close:hover {
    color: #e74c3c;
    background: rgba(231, 76, 60, 0.1);
    transform: rotate(90deg);
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

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

/* 模态框响应式 */
@media (max-width: 768px) {
    .modal-content {
        padding: 30px 25px;
        width: 95%;
        max-height: 85vh;
    }

    .modal-content h2 {
        font-size: 1.6rem;
    }

    .modal-body {
        font-size: 0.95rem;
    }

    .modal-close {
        top: 15px;
        right: 15px;
        font-size: 28px;
    }
}

/* ========== 客服支持模态框特殊样式 ========== */
.modal-contact {
    max-width: 600px;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    padding: 25px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border-left: 4px solid var(--primary-color);
}

.contact-item:hover {
    transform: translateX(5px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
}

.contact-icon {
    font-size: 2.5rem;
    margin-right: 20px;
    flex-shrink: 0;
}

.contact-details {
    flex: 1;
}

.contact-details h3 {
    color: #2c3e50;
    font-size: 1.1rem;
    margin: 0 0 8px 0;
    font-weight: 600;
}

.contact-value {
    color: #555;
    font-size: 1.05rem;
    margin: 0;
    font-family: 'Courier New', monospace;
    letter-spacing: 0.5px;
}

.contact-highlight {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1.15rem;
}

/* 可复制元素样式 */
.copyable {
    cursor: pointer;
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 8px;
    transition: all 0.3s ease;
    user-select: none;
}

.copyable:hover {
    background: rgba(52, 152, 219, 0.1);
    transform: scale(1.02);
}

.copyable:active {
    transform: scale(0.98);
}

.copy-icon {
    font-size: 1rem;
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.copyable:hover .copy-icon {
    opacity: 1;
}

/* 复制成功提示 */
.copy-toast {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(-100px);
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
    color: white;
    padding: 15px 30px;
    border-radius: 50px;
    box-shadow: 0 10px 30px rgba(46, 204, 113, 0.4);
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    font-size: 1rem;
    z-index: 10000;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.copy-toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.toast-icon {
    font-size: 1.2rem;
    animation: checkmark 0.4s ease;
}

.toast-text {
    letter-spacing: 0.5px;
}

@keyframes checkmark {
    0%, 50% {
        transform: scale(0);
    }
    100% {
        transform: scale(1);
    }
}

/* 客服支持模态框响应式 */
@media (max-width: 768px) {
    .contact-item {
        padding: 20px;
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .contact-icon {
        margin-right: 0;
        margin-bottom: 10px;
        font-size: 2rem;
    }

    .contact-details h3 {
        font-size: 1rem;
    }

    .contact-value {
        font-size: 0.95rem;
    }

    .contact-highlight {
        font-size: 1rem;
    }
    
    .copy-toast {
        padding: 12px 20px;
        font-size: 0.9rem;
    }
}

/* ========== 隐私政策模态框特殊样式 ========== */
.modal-privacy {
    max-width: 800px;
}

.privacy-content {
    text-align: left;
}

.privacy-content h3 {
    color: var(--primary-color);
    font-size: 1.3rem;
    margin-top: 25px;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 2px solid #e0e0e0;
}

.privacy-content h3:first-of-type {
    margin-top: 15px;
}

.privacy-content ul {
    margin: 15px 0;
    padding-left: 25px;
}

.privacy-content ul li {
    margin-bottom: 10px;
    line-height: 1.8;
    position: relative;
}

.privacy-content ul li::marker {
    color: var(--primary-color);
}

.privacy-footer {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px solid #e0e0e0;
    font-weight: 600;
    color: var(--primary-color);
    text-align: center;
}

/* 隐私政策模态框响应式 */
@media (max-width: 768px) {
    .modal-privacy {
        max-width: 95%;
        max-height: 90vh;
    }
    
    .privacy-content h3 {
        font-size: 1.15rem;
        margin-top: 20px;
    }
    
    .privacy-content {
        font-size: 0.9rem;
    }
}

/* ========== 视频播放器样式 ========== */
.tutorial-video {
    width: 100%;
    height: 100%;
    border-radius: 12px;
    background: #000;
    object-fit: contain; /* 完整显示视频，不裁剪 */
}

.bilibili-player {
    width: 100%;
    height: 100%;
    min-height: 400px;
    border-radius: 12px;
}

.video-thumbnail {
    position: relative;
    overflow: hidden;
    min-height: 300px; /* 确保有足够高度显示竖屏视频 */
}

/* 视频播放时的样式 */
.video-thumbnail video,
.video-thumbnail iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain; /* 完整显示，不裁剪 */
}

/* 当视频加载后，调整容器高度适应视频比例 */
.video-thumbnail.playing {
    min-height: 500px; /* 给竖屏视频更多高度 */
}

/* 响应式调整 */
@media (max-width: 768px) {
    .video-thumbnail {
        min-height: 250px;
    }
    
    .video-thumbnail.playing {
        min-height: 400px;
    }
}

/* ========== 禁用视频卡片样式 ========== */
.video-disabled {
    opacity: 0.7;
}

.video-disabled .video-placeholder {
    cursor: default;
}

.video-disabled:hover {
    transform: none;
}

.coming-soon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.75);
    color: #fff;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 1px;
    z-index: 10;
    pointer-events: none;
    backdrop-filter: blur(5px);
}

.video-disabled .play-icon {
    opacity: 0.3;
}
