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

:root {
    --primary: #6c5ce7;
    --primary-light: #a29bfe;
    --secondary: #00cec9;
    --accent: #fd79a8;
    --dark: #2d3436;
    --light: #f9f9f9;
    --gradient-1: linear-gradient(135deg, #6c5ce7, #a29bfe);
    --gradient-2: linear-gradient(135deg, #00cec9, #81ecec);
    --gradient-3: linear-gradient(135deg, #fd79a8, #fab1a0);
    --shadow: 0 10px 30px rgba(108, 92, 231, 0.15);
    --radius: 12px;
    --transition: all 0.3s ease;
}

body {
    font-family: 'PingFang SC', 'Microsoft YaHei', sans-serif;
    line-height: 1.6;
    color: var(--dark);
    background-color: var(--light);
}

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

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

ul {
    list-style: none;
}
.jiazai_btn {
    padding: 10px 20px;
    background: var(--gradient-2);
    color: white;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
    width: 200px;
    justify-content: center;
    margin: auto;
}
/* 顶部导航栏 */
.header {
    background-color: #fff;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 15px 0;
}

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

.logo {
    display: flex;
    align-items: center;
}

.logo-img {
    height: 40px;
    margin-right: 10px;
}

.logo h1 {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary);
}

.logo h1 span {
    font-weight: 400;
    color: var(--dark);
}

.main-nav ul {
    display: flex;
}

.main-nav li {
    margin-left: 30px;
}

.main-nav a {
    font-weight: 500;
    padding: 8px 0;
    position: relative;
    font-size: 1.05rem;
}

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

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-1);
    transition: var(--transition);
}

.main-nav a.active::after,
.main-nav a:hover::after {
    width: 100%;
}

/* 搜索英雄区 */
.search-hero {
    background: var(--gradient-1);
    padding: 80px 0;
    color: white;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.search-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zM32 63c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='rgba(255,255,255,.075)' fill-rule='evenodd'/%3E%3C/svg%3E");
    animation: move-bg 30s linear infinite;
    opacity: 0.5;
}

@keyframes move-bg {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

.search-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

.search-content h2 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 15px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.search-content h2 span {
    color: var(--secondary);
    position: relative;
    display: inline-block;
}

.search-content h2 span::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 0;
    width: 100%;
    height: 8px;
    background: var(--accent);
    z-index: -1;
    opacity: 0.5;
    border-radius: 10px;
}

.search-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.search-box-container {
    max-width: 600px;
    margin: 0 auto 30px;
}

.search-box {
    display: flex;
    position: relative;
    background: white;
    border-radius: 50px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    overflow: hidden;
}

#search-input {
    width: 100%;
    padding: 18px 25px;
    border: none;
    font-size: 1.1rem;
    background: transparent;
}

#search-input:focus {
    outline: none;
}

#search-button {
    background: var(--gradient-2);
    border: none;
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: var(--transition);
    margin: 5px;
}

#search-button:hover {
    transform: scale(1.05);
}

/* 搜索建议 */
.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: white;
    border-radius: 0 0 var(--radius) var(--radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-top: 5px;
    z-index: 100;
    display: none;
}

.search-suggestions.active {
    display: block;
}

.search-suggestions ul {
    padding: 10px 0;
}

.search-suggestions li {
    padding: 12px 20px;
    cursor: pointer;
    transition: var(--transition);
    text-align: left;
}

.search-suggestions li:hover {
    background: #f5f5f5;
    color: var(--primary);
}

.search-suggestions i {
    margin-right: 10px;
    color: #7f8c8d;
}

/* 热门标签 */
.popular-tags {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

.tag-label {
    font-weight: 500;
    opacity: 0.8;
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.tag {
    display: inline-block;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 30px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
    backdrop-filter: blur(5px);
}

.tag:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

/* 主体内容区 */
.main-content {
    padding: 50px 0;
    background: var(--light);
}

/* 筛选区域 */
.filter-section {
    margin-bottom: 40px;
}

.filter-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 20px;
}

.time-filter {
    display: flex;
    gap: 15px;
}

.time-btn {
    padding: 10px 20px;
    background: #f1f1f1;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    font-size: 0.95rem;
    transition: var(--transition);
    font-weight: 500;
}

.time-btn:hover {
    background: #e0e0e0;
}

.time-btn.active {
    background: var(--gradient-1);
    color: white;
}

.reset-btn {
    padding: 10px 20px;
    background: var(--gradient-3);
    color: white;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 500;
    transition: var(--transition);
}

.reset-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(253, 121, 168, 0.3);
}

/* SVG素材列表 */
.svg-gallery {
    margin-bottom: 40px;
}

.svg-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.svg-item {
    background: white;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    cursor: pointer;
}

.svg-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(108, 92, 231, 0.2);
}

.svg-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: var(--gradient-1);
    z-index: 1;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s ease;
}

.svg-item:hover::before {
    transform: scaleX(1);
}

.svg-thumbnail {
    position: relative;
    padding-top: 75%; /* 4:3 比例 */
    background: #f9f9f9;
    overflow: hidden;
}

.svg-thumbnail img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 20px;
    transition: var(--transition);
}

.svg-item:hover .svg-thumbnail img {
    transform: scale(1.05);
}

.svg-info {
    padding: 20px;
}

.svg-title {
    margin-bottom: 15px;
    color: var(--dark);
    font-size: 16px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.svg-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 20px;
}

.svg-tag {
    font-size: 0.75rem;
    padding: 4px 10px;
    background: #f1f1f1;
    border-radius: 20px;
    color: #7f8c8d;
}

.svg-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.download-btn {
    padding: 10px 20px;
    background: var(--gradient-2);
    color: white;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
    width: 100%;
    justify-content: center;
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 206, 201, 0.3);
}

/* 加载指示器 */
.loading-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 50px;
    opacity: 0;
    transition: opacity 0.3s;
}

.loading-indicator.active {
    opacity: 1;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(108, 92, 231, 0.2);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading-indicator p {
    color: var(--primary);
    font-weight: 500;
}

/* 加载完成提示 */
.loading-complete {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 50px;
    opacity: 0;
    transition: opacity 0.3s;
}

.loading-complete.active {
    opacity: 1;
}

.loading-complete i {
    font-size: 50px;
    color: var(--secondary);
    margin-bottom: 15px;
}

.loading-complete p {
    color: var(--dark);
    font-weight: 500;
}

/* 底部区域 */
.footer {
    background: var(--dark);
    color: #ecf0f1;
    padding: 70px 0 20px;
}

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

.footer-section h3 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    color: var(--primary-light);
    position: relative;
    padding-bottom: 10px;
}

.footer-section h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 2px;
    background: var(--primary-light);
}

.footer-section ul li {
    margin-bottom: 12px;
}

.footer-section a {
    color: #ecf0f1;
    transition: var(--transition);
}

.footer-section a:hover {
    color: var(--primary-light);
    padding-left: 5px;
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transition: var(--transition);
    font-size: 1.2rem;
}

.social-links a:hover {
    background: var(--primary);
    transform: translateY(-5px);
}

.copyright {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
    color: #bdc3c7;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        align-items: center;
    }
    
    .logo {
        margin-bottom: 15px;
    }
    
    .main-nav {
        width: 100%;
    }
    
    .main-nav ul {
        justify-content: center;
    }
    
    .main-nav li {
        margin: 0 10px;
    }
    
    .search-content h2 {
        font-size: 2.5rem;
    }
    
    .filter-container {
        flex-direction: column;
        gap: 20px;
    }
    
    .time-filter {
        width: 100%;
        justify-content: center;
    }
    
    .reset-btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .search-content h2 {
        font-size: 2rem;
    }
    
    .search-content p {
        font-size: 1rem;
    }
    
    .main-nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
    }
    
    .main-nav li {
        margin: 5px;
    }
    
    .svg-grid {
        grid-template-columns: 1fr;
    }
    
    .search-hero {
        padding: 50px 0;
    }
}

/* 无结果提示 */
.no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 50px 0;
    color: var(--dark);
    font-size: 1.2rem;
}

.no-results i {
    font-size: 50px;
    color: var(--primary-light);
    margin-bottom: 20px;
    display: block;
}