/* 下载页样式 */

/* 产品下载 */
.download-section {
    padding: 100px 0;
    background: linear-gradient(180deg, #f0f4f9 0%, #e8edf4 100%);
}

[data-theme="dark"] .download-section {
    background: linear-gradient(180deg, #0f1e2e 0%, #0a1520 100%);
}

.download-buttons {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
    margin-bottom: 60px;
}

.download-btn-large {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    padding: 32px 28px;
    display: flex;
    align-items: center;
    gap: 22px;
    box-shadow: 0 4px 24px rgba(26, 59, 93, 0.09);
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
    border: 1.5px solid rgba(212, 175, 55, 0.08);
}

.download-btn-large:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 56px rgba(26, 59, 93, 0.18);
    border-color: rgba(212, 175, 55, 0.32);
}

.download-btn-large::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--accent-color);
    opacity: 0;
    transition: opacity var(--transition-normal);
}

.download-btn-large:hover::before {
    opacity: 1;
}

.btn-icon {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    color: white;
    flex-shrink: 0;
}

.windows .btn-icon {
    background: #0078D7;
}

.mac .btn-icon {
    background: #111111;
}

.linux .btn-icon {
    background: #E95420;
}

.btn-content {
    flex: 1;
}

.btn-content h3 {
    font-size: 22px;
    margin-bottom: 8px;
    color: var(--primary-color);
}

.btn-content p {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 15px;
}

.btn-meta {
    display: flex;
    gap: 20px;
    font-size: 12px;
    color: var(--text-light);
}

.btn-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.download-action {
    padding: 12px 24px;
    background: var(--accent-color);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-normal);
    white-space: nowrap;
    display: inline-block;
    text-decoration: none;
    text-align: center;
    min-width: 120px;
    line-height: 1.2;
    margin-left: 0;
}

.download-action:hover {
    background: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(212, 175, 55, 0.3);
}

.download-action:active {
    transform: translateY(0) scale(0.98);
    box-shadow: 0 2px 10px rgba(212, 175, 55, 0.3);
    background: var(--accent-color);
}

.download-action:focus {
    outline: 2px solid var(--accent-color);
    outline-offset: 2px;
}

.download-action:visited {
    background: var(--accent-color);
    color: white;
}

/* 版本更新日志 */
.changelog-section {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    padding: 40px;
    box-shadow: var(--shadow-light);
}

.timeline-scroll {
    max-height: 400px;
    overflow-y: auto;
    padding-right: 20px;
    scrollbar-width: thin;
    scrollbar-color: var(--accent-color) var(--secondary-color);
}

.timeline-scroll::-webkit-scrollbar {
    width: 6px;
}

.timeline-scroll::-webkit-scrollbar-track {
    background: var(--secondary-color);
    border-radius: 3px;
}

.timeline-scroll::-webkit-scrollbar-thumb {
    background: var(--accent-color);
    border-radius: 3px;
}

.timeline-item {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 30px;
    padding: 25px 0;
    border-bottom: 1px solid var(--secondary-color);
    position: relative;
}

.timeline-item:last-child {
    border-bottom: none;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 120px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--accent-color);
    opacity: 0.3;
}

.timeline-date {
    font-size: 14px;
    font-weight: 600;
    color: var(--accent-color);
    padding-top: 5px;
}

.timeline-content h4 {
    font-size: 18px;
    margin-bottom: 10px;
    color: var(--primary-color);
}

.timeline-content ul {
    list-style: none;
    padding-left: 20px;
}

.timeline-content li {
    margin-bottom: 8px;
    color: var(--text-secondary);
    font-size: 14px;
    position: relative;
}

.timeline-content li::before {
    content: '•';
    position: absolute;
    left: -20px;
    color: var(--accent-color);
    font-size: 20px;
}

/* 配套资源 */
.resources-section {
    padding: 100px 0;
    background: var(--bg-light);
}

.resources-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 50px;
}

.resource-card {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-light);
    transition: all var(--transition-normal);
}

.resource-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
}

/* 翻转卡片 */
.flip-card .flip-card-inner {
    position: relative;
    width: 100%;
    height: 300px;
    text-align: center;
    transition: transform 0.8s;
    transform-style: preserve-3d;
}

.flip-card:hover .flip-card-inner {
    transform: rotateY(180deg);
}

.flip-card .flip-card-front,
.flip-card .flip-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    padding: 40px 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.flip-card .flip-card-front {
    background: var(--primary-color);
    color: white;
}

.flip-card .flip-card-back {
    background: var(--card-bg);
    color: var(--text-primary);
    transform: rotateY(180deg);
}

.flip-card .card-icon {
    width: 70px;
    height: 70px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 25px;
    font-size: 28px;
}

.flip-card .flip-card-front h3 {
    font-size: 22px;
    margin-bottom: 15px;
    color: white;
}

.flip-card .flip-card-front p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 20px;
    font-size: 14px;
}

.card-tag {
    display: inline-block;
    padding: 5px 15px;
    background: var(--accent-color);
    color: white;
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 600;
    margin-top: 10px;
}

.flip-card .flip-card-back h4 {
    font-size: 20px;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.flip-card .flip-card-back p {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 25px;
    text-align: center;
}

.card-btn {
    padding: 10px 30px;
    background: var(--accent-color);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-normal);
}

.card-btn:hover {
    background: #FFD700;
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(212, 175, 55, 0.3);
}

/* 可展开卡片 */
.expandable .card-header {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 30px;
    cursor: pointer;
}

.expandable .card-icon {
    width: 60px;
    height: 60px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: white;
    flex-shrink: 0;
}

.expandable h3 {
    font-size: 20px;
    color: var(--primary-color);
    flex: 1;
    margin: 0;
}

.expand-btn {
    width: 40px;
    height: 40px;
    background: var(--secondary-color);
    border: none;
    border-radius: 50%;
    color: var(--text-secondary);
    font-size: 16px;
    cursor: pointer;
    transition: all var(--transition-normal);
}

.expand-btn:hover {
    background: var(--accent-color);
    color: white;
    transform: rotate(180deg);
}

.card-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease;
    padding: 0 30px;
}

.expandable.active .card-content {
    max-height: 300px;
    padding-bottom: 30px;
}

.solution-list {
    list-style: none;
}

.solution-list li {
    margin-bottom: 12px;
}

.solution-list a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    transition: color var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 10px;
}

.solution-list a::before {
    content: '→';
    color: var(--accent-color);
    font-weight: bold;
}

.solution-list a:hover {
    color: var(--primary-color);
}

/* 代码预览卡片 */
.code-preview .card-header {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 30px 30px 0;
}

.code-preview .card-icon {
    width: 60px;
    height: 60px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: white;
    flex-shrink: 0;
}

.code-preview h3 {
    font-size: 20px;
    color: var(--primary-color);
    flex: 1;
    margin: 0;
}

.code-snippet {
    padding: 25px 30px;
    background: var(--bg-dark);
    border-radius: var(--radius-md);
    margin: 25px 30px;
    overflow-x: auto;
}

.code-snippet pre {
    margin: 0;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 14px;
    line-height: 1.6;
}

.code-snippet code {
    color: #E6E6E6;
}

.code-snippet .keyword {
    color: #569CD6;
}

.code-snippet .string {
    color: #CE9178;
}

.code-snippet .comment {
    color: #6A9955;
}

.code-preview .download-btn {
    margin: 0 30px 30px;
    width: calc(100% - 60px);
    padding: 12px;
    background: var(--accent-color);
    border: none;
    border-radius: var(--radius-md);
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-normal);
}

.code-preview .download-btn:hover {
    background: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(212, 175, 55, 0.3);
}

/* 下载指南 */
.guide-section {
    padding: 100px 0;
    background: var(--secondary-color);
}

.guide-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
}

.guide-illustration {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
}

.guide-illustration::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-color), var(--primary-color));
    z-index: 1;
}

.illustration-step {
    position: relative;
    z-index: 2;
    text-align: center;
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    padding: 25px 15px;
    width: 120px;
    box-shadow: var(--shadow-light);
}

.step-number {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 30px;
    background: var(--accent-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    box-shadow: 0 4px 15px rgba(212, 175, 55, 0.3);
}

.step-icon {
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
    font-size: 20px;
    color: white;
}

.illustration-step p {
    font-size: 14px;
    color: var(--text-primary);
    margin: 0;
}

.illustration-arrow {
    position: relative;
    z-index: 2;
    background: var(--secondary-color);
    padding: 0 10px;
}

.illustration-arrow i {
    font-size: 20px;
    color: var(--accent-color);
}

/* 常见问题 */
.faq-section {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    padding: 40px;
    box-shadow: var(--shadow-light);
}

.faq-accordion {
    border-radius: var(--radius-md);
    overflow: hidden;
}

.faq-item {
    border-bottom: 1px solid var(--secondary-color);
}

.faq-item:last-child {
    border-bottom: none;
}

.faq-question {
    width: 100%;
    padding: 20px 0;
    background: none;
    border: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    color: var(--text-primary);
    font-size: 16px;
    font-weight: 600;
    text-align: left;
    transition: color var(--transition-fast);
}

.faq-question:hover {
    color: var(--accent-color);
}

.faq-question i {
    transition: transform var(--transition-normal);
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease;
}

.faq-item.active .faq-answer {
    max-height: 200px;
}

.faq-answer p {
    padding: 0 0 20px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 0;
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .download-buttons {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .resources-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 992px) {
    .guide-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .guide-illustration {
        justify-content: center;
        gap: 20px;
        flex-wrap: wrap;
    }
    
    .guide-illustration::before {
        display: none;
    }
    
    .illustration-arrow {
        display: none;
    }
}

@media (max-width: 768px) {
    .download-buttons {
        grid-template-columns: 1fr;
    }
    
    .resources-grid {
        grid-template-columns: 1fr;
    }
    
    .timeline-item {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .timeline-item::before {
        display: none;
    }
    
    .download-btn-large {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
    
    .btn-icon {
        width: 60px;
        height: 60px;
        font-size: 28px;
    }
    
    .btn-content h3 {
        font-size: 20px;
    }
    
    .btn-meta {
        justify-content: center;
    }
    
    .download-action {
        width: 100%;
    }
    
    .flip-card .flip-card-inner {
        height: 280px;
    }
    
    .illustration-step {
        width: 100px;
        padding: 20px 10px;
    }
    
    .step-icon {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .download-btn-large {
        padding: 25px 20px;
    }
    
    .btn-content h3 {
        font-size: 18px;
    }
    
    .btn-content p {
        font-size: 13px;
    }
    
    .changelog-section {
        padding: 30px 20px;
    }
    
    .timeline-content h4 {
        font-size: 16px;
    }
    
    .timeline-content li {
        font-size: 13px;
    }
    
    .flip-card .flip-card-front,
    .flip-card .flip-card-back {
        padding: 30px 20px;
    }
    
    .flip-card .card-icon {
        width: 60px;
        height: 60px;
        font-size: 24px;
    }
    
    .flip-card .flip-card-front h3,
    .flip-card .flip-card-back h4 {
        font-size: 18px;
    }
    
    .expandable .card-header {
        padding: 25px 20px;
    }
    
    .expandable .card-icon {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }
    
    .expandable h3 {
        font-size: 18px;
    }
    
    .code-preview .card-header {
        padding: 25px 20px 0;
    }
    
    .code-preview .card-icon {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }
    
    .code-preview h3 {
        font-size: 18px;
    }
    
    .code-snippet {
        padding: 20px;
        margin: 20px;
    }
    
    .code-snippet pre {
        font-size: 13px;
    }
    
    .code-preview .download-btn {
        margin: 0 20px 20px;
        width: calc(100% - 40px);
    }
    
    .faq-section {
        padding: 30px 20px;
    }
    
    .faq-question {
        font-size: 15px;
        padding: 18px 0;
    }
}

/* 动画效果 */
@keyframes downloadPulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.download-btn-large:hover .btn-icon {
    animation: downloadPulse 0.6s ease;
}

@keyframes expandIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card-content {
    animation: expandIn 0.3s ease;
}

@keyframes codeHighlight {
    0% {
        background: transparent;
    }
    50% {
        background: rgba(212, 175, 55, 0.1);
    }
    100% {
        background: transparent;
    }
}

.code-snippet:hover {
    animation: codeHighlight 2s ease;
}

/* 加载动画 */
.download-loading {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.download-loading::after {
    content: '';
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: rotate 1s linear infinite;
}

/* 进度指示器 */
.download-progress-indicator {
    position: fixed;
    top: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--accent-color);
    z-index: 3000;
    transition: width 0.3s ease;
}

/* 悬停效果增强 */
.download-btn-large::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(212, 175, 55, 0.05) 0%, 
        rgba(26, 59, 93, 0.05) 100%);
    opacity: 0;
    transition: opacity var(--transition-normal);
    pointer-events: none;
}

.download-btn-large:hover::after {
    opacity: 1;
}

/* 工具提示 */
.download-tooltip {
    position: relative;
}

.download-tooltip:hover::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary-color);
    color: white;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 14px;
    white-space: nowrap;
    margin-bottom: 10px;
    box-shadow: var(--shadow-light);
    z-index: 1000;
}

.download-tooltip:hover::after {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: var(--primary-color);
    margin-bottom: -2px;
    z-index: 1000;
}
       