/* 全局变量 */
:root {
    --primary-color: #4f46e5;
    --secondary-color: #8b5cf6;
    --accent-color: #06b6d4;
    --bg-color: #0f172a;
    --surface-color: #1e293b;
    --text-primary: #f1f5f9;
    --text-secondary: #cbd5e1;
    --border-color: #334155;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --border-radius: 8px;
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* 容器样式 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* 头部样式 */
.header {
    text-align: center;
    margin-bottom: 0.5rem;
    opacity: 0;
    transform: translateY(-20px);
    animation: fadeInUp 0.8s ease-out forwards;
}

.title {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.25rem;
    letter-spacing: -0.025em;
}

.subtitle {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 400;
    margin-bottom: 0.25rem;
}

.author-info {
    font-size: 0.875rem;
    color: var(--accent-color);
    font-weight: 500;
    margin: 0;
}

/* 主内容样式 */
.main-content {
    display: grid;
    gap: 2rem;
}

.intro-section {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    background: var(--surface-color);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s ease-out 0.2s forwards;
    flex: 1;
}

@media (min-width: 768px) {
    .intro-section {
        grid-template-columns: 1fr auto;
        align-items: start;
    }
    
    .video-section {
        order: 2;
        width: 480px;
    }
    
    .text-content {
        order: 1;
    }
}

/* 文本内容样式 */
.text-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.intro-text {
    font-size: 1rem;
    color: var(--text-primary);
    line-height: 1.6;
}

/* 技巧列表样式 */
.tips-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.tip-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.75rem;
    background: rgba(79, 70, 229, 0.1);
    border-radius: var(--border-radius);
    border-left: 4px solid var(--primary-color);
    transition: var(--transition);
    opacity: 0;
    transform: translateX(-20px);
    animation: fadeInLeft 0.6s ease-out forwards;
}

.tip-item:nth-child(1) {
    animation-delay: 0.4s;
}

.tip-item:nth-child(2) {
    animation-delay: 0.6s;
}

.tip-item:nth-child(3) {
    animation-delay: 0.8s;
}

.tip-item:hover {
    transform: translateX(4px);
    box-shadow: var(--shadow-md);
    background: rgba(79, 70, 229, 0.15);
}

.tip-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border-radius: 50%;
    font-weight: 700;
    font-size: 0.875rem;
    flex-shrink: 0;
}

.tip-text {
    font-size: 1rem;
    color: var(--text-primary);
    line-height: 1.5;
}

/* 结论文本样式 */
.conclusion-text {
    font-size: 1rem;
    color: var(--text-primary);
    line-height: 1.6;
    font-weight: 500;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease-out 1s forwards;
}

/* 视频区域样式 */
.video-section {
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transform: scale(0.95);
    animation: fadeInScale 0.8s ease-out 0.4s forwards;
}

.video-container {
    position: relative;
    width: 100%;
    max-width: 600px;
    aspect-ratio: 16 / 9;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border-color);
}

.demo-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--border-radius);
}

.video-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.1), rgba(139, 92, 246, 0.1));
    pointer-events: none;
    border-radius: var(--border-radius);
}

/* 页脚样式 */
.footer {
    text-align: center;
    margin-top: 1rem;
    padding-top: 1rem;
    padding-bottom: 0.5rem;
    border-top: 1px solid var(--border-color);
    opacity: 0;
    animation: fadeIn 0.8s ease-out 1.2s forwards;
}

.footer-text {
    color: var(--text-secondary);
    font-size: 0.75rem;
    margin: 0.25rem 0;
}

/* 动画定义 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

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

/* 响应式设计 */
@media (min-width: 768px) {
    .intro-section {
        grid-template-columns: 1fr 1fr;
        gap: 2.5rem;
        padding: 2.5rem;
    }
    
    .title {
        font-size: 3rem;
    }
    
    .subtitle {
        font-size: 1.5rem;
    }
    
    .intro-text,
    .conclusion-text {
        font-size: 1.25rem;
    }
    
    .tip-text {
        font-size: 1.125rem;
    }
}

@media (min-width: 1024px) {
    .container {
        padding: 3rem 1rem;
    }
    
    .header {
        margin-bottom: 4rem;
    }
    
    .intro-section {
        gap: 3rem;
        padding: 3rem;
    }
}

@media (max-width: 640px) {
    .container {
        padding: 1rem;
    }
    
    .header {
        margin-bottom: 2rem;
    }
    
    .title {
        font-size: 2rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    .intro-section {
        padding: 1.5rem;
    }
    
    .tip-item {
        padding: 1rem 0.75rem;
    }
    
    .tip-number {
        width: 1.75rem;
        height: 1.75rem;
        font-size: 0.75rem;
    }
}

/* 视频占位符样式 */
video {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    font-weight: 600;
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

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

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

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