/* dh6 导航主题 - 清爽工具风格自定义CSS */

/* ==================== 基础重置 ==================== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: #f5f5f5;
    min-height: 100vh;
    color: #333;
    line-height: 1.5;
}

a {
    text-decoration: none;
    color: inherit;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

[x-cloak] {
    display: none !important;
}

/* ==================== 顶部信息栏 ==================== */
.top-bar {
    background: #f8f8f8;
    border-bottom: 1px solid #e8e8e8;
    font-size: 12px;
    color: #666;
}

.top-bar-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 8px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.top-bar-right {
    color: #16a34a;
}

/* ==================== 头部 ==================== */
.header {
    background: white;
    border-bottom: 1px solid #e8e8e8;
}

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

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

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

.logo-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-icon svg {
    width: 24px;
    height: 24px;
    color: white;
}

.logo-text {
    font-size: 20px;
    font-weight: 700;
    color: #1f2937;
}

/* 导航链接 */
.nav-menu {
    display: none;
    align-items: center;
    gap: 4px;
}

@media (min-width: 768px) {
    .nav-menu {
        display: flex;
    }
}

.nav-link {
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 14px;
    color: #333;
    transition: all 0.2s ease;
}

.nav-link:hover {
    color: #16a34a;
    background: #f5f5f5;
}

.nav-link.active {
    color: #16a34a;
    font-weight: 500;
}

/* 移动端菜单按钮 - 只在手机端显示 */
.mobile-menu-btn {
    display: block;
    padding: 8px;
    color: #4b5563;
}

@media (min-width: 768px) {
    .mobile-menu-btn {
        display: none;
    }
}

.mobile-menu-btn svg {
    width: 24px;
    height: 24px;
}

/* ==================== 移动端菜单 ==================== */
.mobile-menu {
    border-top: 1px solid #e5e7eb;
    padding: 12px 16px;
}

.mobile-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.mobile-nav .nav-link {
    font-size: 13px;
}

/* ==================== 主内容区 ==================== */
.main {
    max-width: 1400px;
    margin: 0 auto;
    padding: 24px 16px;
}

/* ==================== 搜索区域 ==================== */
.search-section {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    padding: 24px;
    margin-bottom: 32px;
}

.search-title {
    font-size: 24px;
    font-weight: 700;
    text-align: center;
    color: #1f2937;
    margin-bottom: 16px;
}

/* 搜索引擎图标 */
.engines {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 16px;
}

.engine-link {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 13px;
    color: #666;
    transition: all 0.2s ease;
}

.engine-link:hover {
    background: #f5f5f5;
    color: #16a34a;
}

.engine-dot {
    margin-right: 4px;
}

.engine-dot.blue {
    color: #3b82f6;
}

.engine-dot.green {
    color: #22c55e;
}

.engine-dot.yellow {
    color: #eab308;
}

.engine-dot.purple {
    color: #a855f7;
}

.engine-dot.red {
    color: #ef4444;
}

.engine-dot.teal {
    color: #14b8a6;
}

/* 搜索框 */
.search-box {
    display: flex;
    max-width: 672px;
    margin: 0 auto;
}

.search-input {
    flex: 1;
    padding: 12px 16px;
    border: 2px solid #22c55e;
    border-radius: 4px 0 0 4px;
    font-size: 14px;
    transition: all 0.2s ease;
}

.search-input:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.1);
}

.search-btn {
    background: #22c55e;
    color: white;
    border: none;
    border-radius: 0 4px 4px 0;
    padding: 0 24px;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s;
}

.search-btn:hover {
    background: #16a34a;
}

/* 搜索结果提示 */
.search-result-tip {
    margin-bottom: 24px;
    padding: 16px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
}

.search-result-text {
    color: #15803d;
    font-size: 14px;
}

.search-result-count {
    font-weight: 600;
}

/* ==================== 行业区块 ==================== */
.industry-section {
    margin-bottom: 32px;
}

.industry-header {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
}

.industry-header::before {
    content: '';
    width: 4px;
    height: 18px;
    background: #f97316;
    margin-right: 8px;
    border-radius: 2px;
}

.industry-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.industry-count {
    font-size: 13px;
    color: #999;
    font-weight: normal;
    margin-left: 8px;
}

/* ==================== 站点网格 ==================== */
.sites-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

@media (min-width: 768px) {
    .sites-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .sites-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1280px) {
    .sites-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* ==================== 站点卡片 - 带图标版 ==================== */
.site-card {
    display: flex;
    align-items: flex-start;
    padding: 16px;
    background: white;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.site-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

/* 图标区域 */
.site-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    flex-shrink: 0;
    margin-right: 12px;
}

/* 内容区域 */
.site-content {
    flex: 1;
    min-width: 0;
}

.site-name {
    font-size: 15px;
    font-weight: 600;
    color: #333;
    margin-bottom: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    transition: color 0.2s;
}

.site-card:hover .site-name {
    color: #16a34a;
}

.site-description {
    font-size: 13px;
    color: #666;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.site-description.empty {
    color: #999;
    font-style: italic;
}

/* ==================== 空状态 ==================== */
.empty-state {
    text-align: center;
    padding: 80px 20px;
}

.empty-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 16px;
    border-radius: 8px;
    background: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
}

.empty-icon svg {
    width: 32px;
    height: 32px;
    color: #9ca3af;
}

.empty-title {
    font-size: 18px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 8px;
}

.empty-text {
    color: #6b7280;
}

/* 搜索空状态 */
.search-empty .empty-icon {
    background: #f0fdf4;
}

.search-empty .empty-icon svg {
    color: #22c55e;
}

.clear-search-btn {
    margin-top: 16px;
    padding: 10px 20px;
    border-radius: 4px;
    background: #22c55e;
    color: white;
    font-size: 14px;
    transition: background 0.2s;
}

.clear-search-btn:hover {
    background: #16a34a;
}

/* ==================== 底部 ==================== */
.footer {
    background: white;
    border-top: 1px solid #e5e7eb;
    margin-top: auto;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 24px 16px;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    font-size: 14px;
    color: #6b7280;
}

@media (min-width: 768px) {
    .footer-content {
        flex-direction: row;
        justify-content: space-between;
    }
}

/* 友情链接 */
.footer-links {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

.footer-links-label {
    color: #9ca3af;
}

.footer-links a {
    color: #6b7280;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: #16a34a;
}

/* 版权信息 */
.footer-info {
    text-align: center;
}

@media (min-width: 768px) {
    .footer-info {
        text-align: right;
    }
}

.footer-info p {
    margin-bottom: 4px;
}

.footer-info a {
    transition: color 0.2s;
}

.footer-info a:hover {
    color: #16a34a;
}

.footer-divider {
    margin: 0 8px;
}

/* ==================== 滚动条 ==================== */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f5f5f5;
}

::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #999;
}