/*
Theme Name: 快速收录导航
Theme URI: https://example.com/
Description: 一个专为网址导航设计的WordPress主题，支持秒收录、自动收录、分类目录、友情链接、自动获取TDK和自动检测友情链接。
Version: 1.0.0
Author: Jiemi
Author URI: https://example.com/
License: GPLv2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Tags: 导航, 网址导航, 分类目录, 友情链接, 响应式, 多语言
Text Domain: jiemi
*/

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    background-color: #f5f7fa;
}

a {
    color: #0066cc;
    text-decoration: none;
    transition: color 0.2s ease, background-color 0.2s ease;
}

a:hover {
    color: #004085;
    text-decoration: underline;
}

img {
    max-width: 100%;
    height: auto;
}

/* 容器样式 */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 头部样式 */
.site-header {
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

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

.site-branding {
    display: flex;
    align-items: center;
}

.site-logo {
    width: 40px;
    height: 40px;
    margin-right: 15px;
}

.site-title {
    font-size: 24px;
    font-weight: 600;
    color: #333;
}

.site-description {
    font-size: 14px;
    color: #666;
    margin-top: 5px;
}

/* 导航菜单样式 */
.main-navigation {
    display: flex;
    align-items: center;
}

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

.nav-menu li {
    margin-left: 20px;
}

.nav-menu a {
    display: block;
    padding: 8px 12px;
    color: #333;
    font-weight: 500;
    border-radius: 4px;
}

.nav-menu a:hover,
.nav-menu .current-menu-item a {
    background-color: #f0f0f0;
    color: #0066cc;
    text-decoration: none;
}

/* 移动端菜单按钮 */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #333;
    padding: 5px;
}

/* 搜索表单样式 */
.search-form {
    display: flex;
    margin-left: 20px;
    position: relative;
}

.search-form input[type="search"] {
    width: 200px;
    padding: 8px 40px 8px 15px;
    border: 1px solid #ddd;
    border-radius: 20px;
    font-size: 14px;
    outline: none;
}

.search-form input[type="search"]:focus {
    border-color: #0066cc;
    box-shadow: 0 0 0 2px rgba(0, 102, 204, 0.1);
}

.search-form button {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    font-size: 16px;
}

/* 英雄区域样式 */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 60px 0;
    text-align: center;
}

.hero h1 {
    font-size: 42px;
    margin-bottom: 20px;
    font-weight: 700;
}

.hero p {
    font-size: 18px;
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.submit-button {
    display: inline-block;
    background-color: #fff;
    color: #0066cc;
    padding: 12px 30px;
    border-radius: 30px;
    font-size: 16px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.submit-button:hover {
    background-color: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    text-decoration: none;
    color: #0066cc;
}

/* 主要内容样式 */
.site-content {
    padding: 40px 0;
}

.content-area {
    width: 100%;
}

/* 网站卡片样式 */
.sites-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 30px;
}

.site-card {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    padding: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.site-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.12);
}

.site-card-header {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.site-favicon {
    width: 32px;
    height: 32px;
    margin-right: 12px;
    border-radius: 4px;
}

.site-card-title {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
}

.site-card-title a {
    color: #333;
}

.site-card-title a:hover {
    color: #0066cc;
    text-decoration: none;
}

.site-card-meta {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
}

.site-category {
    display: inline-block;
    background-color: #e8f0fe;
    color: #0066cc;
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 12px;
    margin-right: 5px;
    margin-bottom: 5px;
}

.site-card-description {
    color: #555;
    margin-bottom: 15px;
    line-height: 1.5;
}

.site-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    color: #777;
}

.site-visit-button {
    display: inline-block;
    background-color: #0066cc;
    color: white;
    padding: 6px 15px;
    border-radius: 20px;
    font-size: 13px;
    transition: background-color 0.2s ease;
}

.site-visit-button:hover {
    background-color: #004085;
    color: white;
    text-decoration: none;
}

/* 分类目录样式 */
.category-section {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    padding: 30px;
    margin-bottom: 30px;
}

.category-section h2 {
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f0f0;
    color: #333;
}

.category-hierarchy {
    list-style: none;
}

.category-hierarchy > li {
    margin-bottom: 15px;
}

.category-item {
    padding: 10px 15px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
    cursor: pointer;
}

.category-item:hover {
    background-color: #f5f5f5;
}

.category-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
}

.category-count {
    background-color: #e8f0fe;
    color: #0066cc;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 12px;
}

.category-children {
    list-style: none;
    margin-left: 20px;
    margin-top: 10px;
    display: none;
}

.category-children.active {
    display: block;
}

.category-expand {n    transform: rotate(0deg);
    transition: transform 0.3s ease;
}

.category-expand.expanded {
    transform: rotate(90deg);
}

/* 友情链接样式 */
.friend-links {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    padding: 30px;
    margin-bottom: 30px;
}

.friend-links h2 {
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f0f0;
    color: #333;
}

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

.friend-link-item {
    text-align: center;
    padding: 15px;
    border: 1px solid #eee;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.friend-link-item:hover {
    border-color: #0066cc;
    box-shadow: 0 2px 8px rgba(0, 102, 204, 0.1);
}

.friend-link-logo {
    width: 48px;
    height: 48px;
    margin: 0 auto 10px;
    border-radius: 4px;
}

.friend-link-name {
    font-weight: 500;
    margin-bottom: 5px;
}

.friend-link-status {
    font-size: 12px;
    color: #777;
}

.status-active {
    color: #4caf50;
}

.status-warning {
    color: #ff9800;
}

.status-error {
    color: #f44336;
}

/* 单页样式 */
.single-site-content {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    padding: 30px;
    margin-bottom: 30px;
}

.site-header-info {
    display: flex;
    align-items: flex-start;
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.site-full-favicon {
    width: 64px;
    height: 64px;
    margin-right: 20px;
    border-radius: 6px;
}

.site-header-details {
    flex: 1;
}

.site-full-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 10px;
    color: #333;
}

.site-url {
    font-size: 16px;
    color: #0066cc;
    margin-bottom: 15px;
    word-break: break-all;
}

.site-meta-info {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    color: #666;
    font-size: 14px;
}

.site-description-full {
    margin-bottom: 25px;
    line-height: 1.8;
    color: #555;
}

.site-tags {
    margin-bottom: 25px;
}

/* 网站提交表单样式 */
.site-submit-form {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    padding: 30px;
    margin-bottom: 30px;
}

.site-submit-form h2 {
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f0f0;
    color: #333;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
}

.form-group input[type="url"],
.form-group input[type="text"],
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.2s ease;
}

.form-group input[type="url"]:focus,
.form-group input[type="text"]:focus,
.form-group textarea:focus,
.form-group select:focus {
    border-color: #0066cc;
    outline: none;
    box-shadow: 0 0 0 2px rgba(0, 102, 204, 0.1);
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
}

.form-group.checkbox-group {
    display: flex;
    align-items: center;
}

.form-group.checkbox-group input[type="checkbox"] {
    margin-right: 10px;
}

.form-group.checkbox-group label {
    margin-bottom: 0;
}

.submit-form-button {
    display: inline-block;
    background-color: #0066cc;
    color: white;
    padding: 12px 30px;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.submit-form-button:hover {
    background-color: #004085;
}

.submit-form-button:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

.form-response {
    margin-top: 20px;
    padding: 15px;
    border-radius: 4px;
}

.form-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.form-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* 分页样式 */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 40px;
    margin-bottom: 20px;
}

.pagination .page-numbers {
    display: inline-block;
    padding: 8px 15px;
    margin: 0 5px;
    border-radius: 4px;
    color: #333;
    background-color: #fff;
    border: 1px solid #ddd;
    transition: all 0.2s ease;
}

.pagination .page-numbers:hover {
    background-color: #f5f5f5;
    border-color: #0066cc;
    color: #0066cc;
    text-decoration: none;
}

.pagination .page-numbers.current {
    background-color: #0066cc;
    color: white;
    border-color: #0066cc;
}

/* 侧边栏样式 */
.sidebar {
    margin-top: 30px;
}

.widget {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    padding: 20px;
    margin-bottom: 20px;
}

.widget h3 {
    font-size: 18px;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f0f0;
    color: #333;
}

.widget ul {
    list-style: none;
}

.widget li {
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid #f5f5f5;
}

.widget li:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.widget a {
    color: #333;
    transition: color 0.2s ease;
}

.widget a:hover {
    color: #0066cc;
    text-decoration: none;
}

/* 页脚样式 */
.site-footer {
    background-color: #2d3748;
    color: #a0aec0;
    padding: 40px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 30px;
}

.footer-column h3 {
    color: white;
    font-size: 18px;
    margin-bottom: 20px;
}

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

.footer-column li {
    margin-bottom: 10px;
}

.footer-column a {
    color: #a0aec0;
    transition: color 0.2s ease;
}

.footer-column a:hover {
    color: white;
    text-decoration: none;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #4a5568;
    font-size: 14px;
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .container {
        max-width: 100%;
    }
    
    .sites-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .site-header .container {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .site-branding {
        margin-bottom: 15px;
        width: 100%;
    }
    
    .menu-toggle {
        display: block;
        position: absolute;
        top: 20px;
        right: 20px;
    }
    
    .main-navigation {
        width: 100%;
        display: none;
    }
    
    .main-navigation.toggled {
        display: block;
    }
    
    .nav-menu {
        flex-direction: column;
        width: 100%;
    }
    
    .nav-menu li {
        margin-left: 0;
        margin-bottom: 5px;
    }
    
    .search-form {
        margin-left: 0;
        margin-top: 15px;
        width: 100%;
    }
    
    .search-form input[type="search"] {
        width: 100%;
    }
    
    .hero h1 {
        font-size: 32px;
    }
    
    .hero p {
        font-size: 16px;
    }
    
    .sites-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
    
    .site-header-info {
        flex-direction: column;
        text-align: center;
    }
    
    .site-full-favicon {
        margin-right: 0;
        margin-bottom: 15px;
    }
    
    .category-section,
    .friend-links,
    .site-submit-form,
    .single-site-content {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .hero {
        padding: 40px 0;
    }
    
    .hero h1 {
        font-size: 28px;
    }
    
    .submit-button {
        padding: 10px 20px;
        font-size: 14px;
    }
    
    .site-full-title {
        font-size: 24px;
    }
    
    .site-meta-info {
        flex-direction: column;
        gap: 10px;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.5s ease-out;
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #0066cc;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 20px auto;
    display: block;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 回到顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #0066cc;
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 20px;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    z-index: 999;
}

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

.back-to-top:hover {
    background-color: #004085;
    transform: translateY(-5px);
}

/* 标签云样式 */
.tag-cloud {
    margin-top: 15px;
}

.tag-cloud a {
    display: inline-block;
    background-color: #f0f0f0;
    color: #333;
    padding: 5px 12px;
    border-radius: 3px;
    margin-right: 8px;
    margin-bottom: 8px;
    font-size: 14px;
    transition: all 0.2s ease;
}

.tag-cloud a:hover {
    background-color: #0066cc;
    color: white;
    text-decoration: none;
}