/* 页脚修复样式 - 修复排版混乱问题 */

.footer {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    color: #cbd5e1;
    padding: 60px 0 30px;
    margin-top: 80px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-logo {
    grid-column: span 1;
}

.footer-logo-img {
    max-width: 120px;
    margin-bottom: 20px;
    filter: brightness(0) invert(1);
}

.footer-logo p {
    font-size: 14px;
    line-height: 1.6;
    margin-top: 10px;
    color: #94a3b8;
}

.footer-links h4,
.footer-contact h4,
.footer-resources h4 {
    color: white;
    font-size: 18px;
    margin-bottom: 20px;
    font-weight: 600;
}

.footer-links ul,
.footer-contact ul,
.footer-resources ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li,
.footer-contact li,
.footer-resources li {
    margin-bottom: 12px;
}

.footer-links a,
.footer-contact a,
.footer-resources a {
    color: #cbd5e1;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
    display: inline-flex;
    align-items: center;
}

.footer-links a:hover,
.footer-contact a:hover,
.footer-resources a:hover {
    color: #60a5fa;
}

.footer-links a i,
.footer-contact a i,
.footer-resources a i {
    margin-right: 8px;
    font-size: 12px;
    width: 16px;
    text-align: center;
}

.footer-bottom {
    max-width: 1200px;
    margin: 40px auto 0;
    padding: 30px 20px 0;
    border-top: 1px solid #334155;
    text-align: center;
    color: #94a3b8;
    font-size: 14px;
}

.footer-bottom p {
    margin: 8px 0;
}

.footer-legal {
    margin-top: 20px;
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.footer-legal a {
    color: #94a3b8;
    text-decoration: none;
    font-size: 13px;
    transition: color 0.3s ease;
}

.footer-legal a:hover {
    color: #60a5fa;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
    
    .footer-logo {
        grid-column: span 2;
        text-align: center;
    }
    
    .footer-logo-img {
        margin: 0 auto 20px;
    }
}

@media (max-width: 768px) {
    .footer {
        padding: 40px 0 20px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }
    
    .footer-logo {
        grid-column: span 1;
    }
    
    .footer-links,
    .footer-contact,
    .footer-resources {
        text-align: center;
    }
    
    .footer-links a,
    .footer-contact a,
    .footer-resources a {
        justify-content: center;
    }
    
    .footer-legal {
        flex-direction: column;
        gap: 15px;
    }
}

@media (max-width: 480px) {
    .footer {
        padding: 30px 0 15px;
    }
    
    .footer-content {
        padding: 0 15px;
    }
    
    .footer-bottom {
        padding: 20px 15px 0;
    }
}

/* 动画效果 */
.footer-links a,
.footer-contact a,
.footer-resources a {
    position: relative;
    padding-left: 0;
    transition: all 0.3s ease;
}

.footer-links a:before,
.footer-contact a:before,
.footer-resources a:before {
    content: '';
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 0;
    height: 1px;
    background: #60a5fa;
    transition: width 0.3s ease;
}

.footer-links a:hover:before,
.footer-contact a:hover:before,
.footer-resources a:hover:before {
    width: 100%;
}

@media (max-width: 768px) {
    .footer-links a:before,
    .footer-contact a:before,
    .footer-resources a:before {
        display: none;
    }
}

/* 页脚图标样式 */
.footer-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    margin-right: 10px;
    transition: background 0.3s ease;
}

.footer-links a:hover .footer-icon,
.footer-contact a:hover .footer-icon,
.footer-resources a:hover .footer-icon {
    background: rgba(96, 165, 250, 0.2);
}

/* 页脚分隔线 */
.footer-divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, #334155, transparent);
    margin: 20px 0;
}

/* 页脚回到顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: #2563eb;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 20px;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
}

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

.back-to-top:hover {
    background: #1d4ed8;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}