  /* 1. 头部固定并加底色 */
header { background-color: #111827 !important; position: sticky; top: 0; z-index: 9999; }



/* 3. 中间和右边所有的简介，强制限制最高高度（自动防溢出） */
.site-main .grid > a .text-gray-500, 
.sticky-sidebar .text-gray-500 { 
    display: -webkit-box; 
    -webkit-line-clamp: 2; /* 限制2行，中间太短可以改成3 */
    -webkit-box-orient: vertical; 
    overflow: hidden; 
    height: 40px; /* 强制高度，整齐划一 */
} 
   
    /* === 全局链接重置：去除下划线 + 统一颜色 === */
    a {
        text-decoration: none !important;
        color: inherit !important;
        transition: color 0.2s ease;
    }
    
    /* === 顶部导航链接精确控制 === */
    header .flex.items-center.gap-6 a {
        text-decoration: none !important;
        color: #94a3b8 !important;  /* 默认浅灰色 */
        font-size: 14px;
        font-weight: 500;
        position: relative;
        padding-bottom: 2px;
    }
    
    /* 鼠标悬停时变紫色 */
    header .flex.items-center.gap-6 a:hover {
        color: #818cf8 !important;
    }
    
    /* 首页（当前页）保持紫色 */
    header .flex.items-center.gap-6 a.text-indigo-500 {
        color: #818cf8 !important;
    }
    
    /* 搜索按钮文字也确保无下划线 */
    header form button {
        text-decoration: none !important;
    }
    
    /* === 侧边栏链接重置 === */
    .sidebar-fixed a {
        text-decoration: none !important;
        color: inherit !important;
    }
    
    /* === 底部友情链接重置 === */
    footer a {
        text-decoration: none !important;
        color: inherit !important;
    }
    
    /* === 主内容区链接悬停紫色 === */
    main a:hover {
        color: #818cf8 !important;
    }
    
    /* ============================================
       传统 CSS 替代 Tailwind CDN
       提供与 Tailwind 相同的样式效果
       ============================================ */
    /* --- 自定义样式补充 --- */

    /* 页面整体居中容器 */
    .page-wrapper {
        max-width: 1600px;
        margin: 0 auto;
        display: flex;
        width: 100%;
        box-sizing: border-box;
        padding-left: 0;
        padding-right: 0;
    }
    main { padding: 2rem; box-sizing: border-box; }
    
    /* 侧边栏样式 - 暗黑主题 */
    .sidebar-fixed {
        width: 280px;
        background: #111827;
        height: 100vh;
        position: fixed;
        left: 0;
        top: 0;
        border-right: 1px solid #1f2937;
        z-index: 50;
        overflow-y: auto;
        display: flex;
        flex-direction: column;
    }
    
    /* 折叠菜单细节 */
    details summary { list-style: none; cursor: pointer; }
    details summary::-webkit-details-marker { display: none; }
    .nav-main { padding: 10px 12px; font-weight: 600; color: #cbd5e1; display: flex; justify-content: space-between; align-items: center; border-left: 3px solid transparent; }
    .nav-main:hover { background: #1e293b; color: #818cf8; }
    details[open] > .nav-main { background: #1e1b4b; color: #818cf8; border-left-color: #818cf8; }
    .nav-sub { padding: 6px 12px 6px 24px; font-size: 13px; color: #94a3b8; display: block; text-decoration: none; }
    .nav-sub:hover { color: #818cf8; padding-left: 40px; background: #1e293b; border-left: 3px solid #818cf8; }
    
    /* 主内容区偏移 */
    .main-content { flex: 1; margin-left: 280px; min-height: 100vh; display: flex; flex-direction: column; width: 100%; box-sizing: border-box; }
    
    /* 卡片效果 - 暗黑主题 */

    
    /* === 页面布局宽度控制（传统CSS，替代Tailwind的max-w/mx-auto） === */
    .site-header {
        max-width: 1600px;
        margin: 0 auto;
        width: 100%;
        display: block;
        box-sizing: border-box;
    }
    .site-main {
        max-width: 1600px;
        width: 100%;
        margin: 0 auto;
    }

    /* === 响应式适配 === */
    /* iPad 及平板 */
    @media (max-width: 1024px) {
        .sidebar-fixed {
            width: 280px;
        }
        .main-content {
            margin-left: 280px;
        }
        main {
            padding: 1.5rem !important;
        }
    }
    
    /* 手机 */
    @media (max-width: 768px) {
        /* 侧边栏默认隐藏，通过 JS 切换 */
        .sidebar-fixed {
            position: fixed !important;
            left: 0 !important;
            width: 280px;
            transform: translateX(-100%);
            transition: transform 0.3s ease;
        }
        .sidebar-fixed.mobile-open {
            transform: translateX(0);
        }
        
        /* 主内容区全屏 */
        .main-content {
            margin-left: 0;
        }
        
        /* 顶部导航栏加汉堡菜单按钮 */
        .mobile-menu-btn {
            display: flex !important;
        }
        
        /* 导航链接隐藏（移动端用侧边栏分类代替） */
        header .flex.items-center.gap-6 {
            display: none;
        }
        
        /* 搜索框宽度调整 */
        header form input[name="query"] {
            width: 120px !important;
        }
        
        /* 主内容区 padding 缩小 */
        main {
            padding: 1rem !important;
        }
        
        /* 统计横幅改为纵向排列 */
        .stat-banner {
            flex-direction: column !important;
            gap: 1rem !important;
        }
        .stat-banner > div {
            text-align: center;
        }
        
        /* 站长推荐卡片手机单列 */
        .recommend-grid {
            grid-template-columns: 1fr !important;
        }
        
        /* 最新收录和侧边栏纵向排列 */
        .content-grid {
            grid-template-columns: 1fr !important;
        }
        
        /* 文字截断优化 */
        .truncate-mobile {
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }
    }
    
    /* 小手机 */
    @media (max-width: 480px) {
        header {
            padding: 0 1rem !important;
        }
        header form {
            flex: 1;
        }
        header form input[name="query"] {
            width: 80px !important;
            padding: 0.375rem 0.5rem !important;
        }
        header form button {
            padding: 0.375rem 0.75rem !important;
        }
        .stat-banner div div:first-child {
            font-size: 1.5rem !important;
        }
    }
    
    /* 汉堡菜单按钮（默认隐藏，手机端显示） */
    .mobile-menu-btn {
        display: none;
        background: none;
        border: none;
        cursor: pointer;
        padding: 0.5rem;
        margin-right: 0.75rem;
    }
    .mobile-menu-btn span {
        display: block;
        width: 20px;
        height: 2px;
        background: #cbd5e1;
        margin: 5px 0;
        transition: 0.3s;
    }
    
    /* 侧边栏遮罩层（手机端点击关闭） */
    .sidebar-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0,0,0,0.7);
        z-index: 40;
    }
    .sidebar-overlay.active {
        display: block;
    }

    /* ===== 手机端搜索框自适应修复 ===== */
    @media (max-width: 768px) {
        header form {
            flex: 1 !important;
            max-width: 100% !important;
        }
        header form input[name="query"] {
            width: auto !important;
            flex: 1 !important;
            min-width: 0 !important;
            padding: 0.375rem 0.5rem !important;
            font-size: 13px !important;
        }
        header form button {
            padding: 0.375rem 0.75rem !important;
            font-size: 13px !important;
            white-space: nowrap !important;
        }
    }
    
    @media (max-width: 480px) {
        header form {
            flex-direction: row !important;
            gap: 4px !important;
        }
        header form input[name="query"] {
            width: auto !important;
            flex: 1 !important;
            min-width: 0 !important;
            padding: 0.3rem 0.5rem !important;
            font-size: 12px !important;
        }
        header form button {
            padding: 0.3rem 0.6rem !important;
            font-size: 12px !important;
        }
    }
    
    /* ===== 手机端分类浏览按钮隐藏修复 ===== */
    @media (max-width: 768px) {
        /* 隐藏35dir原生的分类浏览按钮 */
        .category-btn,
        a.category-btn,
        [class*="category-btn"],
        #category_btn,
        #categoryBtn,
        .cat_btn,
        .category_switch {
            display: none !important;
        }
    }
    
    /* ===== 汉堡菜单按钮动画效果 ===== */
    .mobile-menu-btn.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }
    .mobile-menu-btn.active span:nth-child(2) {
        opacity: 0;
    }
    .mobile-menu-btn.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -6px);
    }

/* ============================================
   传统 CSS 替代 Tailwind CDN
   提供与 Tailwind 相同的样式效果
   ============================================ */

/* --- 颜色 - 背景 --- */
.bg-white { background-color: #111827; }
.bg-gray-50 { background-color: #1e293b; }
.bg-gray-100 { background-color: #334155; }
.bg-indigo-600 { background-color: #4f46e5; }
    .bg-\[#111827\] { background-color: #111827; }
.bg-gradient-to-r { background-image: linear-gradient(to right, var(--tw-gradient-stops)); }
.from-indigo-500 { --tw-gradient-from: #6366f1; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to); }
.to-purple-600 { --tw-gradient-to: #7c3aed; }

/* --- 颜色 - 文字 --- */
.text-white { color: #fff; }
.text-indigo-500 { color: #818cf8; }
.text-indigo-400 { color: #a5b4fc; }
.text-gray-100 { color: #f1f5f9; }
.text-gray-200 { color: #e2e8f0; }
.text-gray-300 { color: #cbd5e1; }
.text-gray-400 { color: #94a3b8; }
.text-gray-500 { color: #64748b; }

/* --- 颜色 - 边框 --- */
.border-gray-600 { border-color: #475569; }
.border-gray-700 { border-color: #334155; }
.border-gray-800 { border-color: #1e2937; }
.border-indigo-500 { border-color: #818cf8; }

/* --- 基础显示 --- */
.flex { display: flex; }
.grid { display: grid; }
.block { display: block; }
.sticky { position: sticky; }
.overflow-hidden { overflow: hidden; }
    .overflow-x-auto { overflow-x: auto; }
.transform { transform: translateZ(0); }
.whitespace-nowrap { white-space: nowrap; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.line-clamp-2 { -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.transition-colors { transition: background-color 0.2s, color 0.2s, border-color 0.2s; }
.transition-transform { transition: transform 0.2s; }
.duration-300 { transition-duration: 300ms; }

/* --- 布局 --- */
.flex-1 { flex: 1 1 0%; }
.w-full { width: 100%; }
.w-64 { width: 16rem; }
.w-6 { width: 1.5rem; }
.w-5 { width: 1.25rem; }
.h-16 { height: 4rem; }
.h-10 { height: 2.5rem; }
.h-6 { height: 1.5rem; }
.h-5 { height: 1.25rem; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.justify-around { justify-content: space-around; }
.justify-center { justify-content: center; }

.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }
.gap-x-6 { column-gap: 1.5rem; }
.gap-y-2 { row-gap: 0.5rem; }

/* --- 间距 - 内边距 --- */
.p-2 { padding: 0.5rem; }
.p-4 { padding: 1rem; }
.p-6 { padding: 1.5rem; }
.p-8 { padding: 2rem; }
.px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-8 { padding-left: 2rem; padding-right: 2rem; }
.py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; }
.py-1.5 { padding-top: 0.375rem; padding-bottom: 0.375rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.pl-3 { padding-left: 0.75rem; }
.pt-3 { padding-top: 0.75rem; }
.ml-2 { margin-left: 0.5rem; }

/* --- 间距 - 外边距 --- */
.mt-1 { margin-top: 0.25rem; }
.mt-0.5 { margin-top: 0.125rem; }
.mt-3 { margin-top: 0.75rem; }
.mt-10 { margin-top: 2.5rem; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-10 { margin-bottom: 2.5rem; }

/* --- 间距 - 子元素间距 --- */
.space-y-8 > * + * { margin-top: 2rem; }
.space-y-3 > * + * { margin-top: 0.75rem; }

/* --- 边框 --- */
.border { border: 1px solid #334155; }
.border-b { border-bottom: 1px solid #1e2937; }
.border-t { border-top: 1px solid #1e2937; }
.border-l-4 { border-left-width: 4px; }
.rounded { border-radius: 0.25rem; }
.rounded-lg { border-radius: 0.5rem; }
.rounded-l-md { border-top-left-radius: 0.375rem; border-bottom-left-radius: 0.375rem; }
.rounded-r-md { border-top-right-radius: 0.375rem; border-bottom-right-radius: 0.375rem; }

/* --- 阴影 --- */
.shadow-sm { box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.3); }
.shadow-lg { box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.5), 0 4px 6px -4px rgba(0, 0, 0, 0.3); }

/* --- 字体 --- */
.font-bold { font-weight: 700; }
.font-medium { font-weight: 500; }
.font-normal { font-weight: 400; }
.text-xs { font-size: 0.75rem; }
.text-sm { font-size: 0.875rem; }
.text-base { font-size: 1rem; }
.text-lg { font-size: 1.125rem; }
.text-2xl { font-size: 1.5rem; }
.text-[10px] { font-size: 10px; }

/* --- 定位 --- */
.top-0 { top: 0; }
.z-40 { z-index: 40; }

/* --- 文本 --- */
.text-center { text-align: center; }
.opacity-80 { opacity: 0.8; }

/* --- 状态 --- */
.hover\:bg-gray-50:hover { background-color: #1e293b; }
.hover\:bg-indigo-700:hover { background-color: #4338ca; }
.hover\:text-indigo-500:hover { color: #818cf8; }
.focus\:outline-none:focus { outline: 2px solid transparent; outline-offset: 2px; }
.focus\:border-indigo-500:focus { border-color: #6366f1; }

/* --- Group Open --- */
details[open] > summary span:last-child { transform: rotate(180deg); }

/* --- 响应式 --- */
@media (min-width: 640px) {
    .sm\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
    .lg\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .lg\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .lg\:col-span-2 { grid-column: span 2 / span 2; }
    .lg\:col-span-3 { grid-column: span 3 / span 3; }
}


    /* ============================================
       【侧边栏固定】侧边栏position:fixed 钉死在左侧，不随页面滚动
       ============================================ */
    @media (min-width: 769px) {
        /* 侧边栏fixed定位：彻底钉死在屏幕左侧，不随页面滚动 */
        .sidebar-fixed {
            position: fixed !important;
            top: 0 !important;
            height: 100vh !important;
            left: 0 !important;
        }
        /* 主内容区留出侧边栏宽度空间 */
        .main-content {
            margin-left: 280px !important;
        }
    }

    /* ============================================
       侧边栏居中修复：大屏时侧边栏跟随页面容器居中
       ============================================ */
    @media (min-width: 1601px) {
        .sidebar-fixed {
            left: calc((100vw - 1680px) / 2) !important;
        }
    }

    /* ============================================
       欧美风 Hero 区域样式
       ============================================ */
    .hero-section {
        max-width: 100%;
        margin: 30px auto 0;
        padding: 0 20px;
    }
    .hero-content {
        text-align: left;
    }
    .hero-title {
        font-size: 3rem;
        font-weight: 800;
        color: #ffffff;
        margin: 0 0 12px 0;
        letter-spacing: -0.02em;
        line-height: 1.1;
    }
    .gradient-text {
        background: linear-gradient(135deg, #6366f1 0%, #a855f7 50%, #ec4899 100%);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
        display: inline-block;
    }
    .hero-subtitle {
        font-size: 1.1rem;
        color: #94a3b8;
        max-width: 680px;
        margin: 0 0 25px;
        line-height: 1.6;
    }
    .hero-search {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        gap: 12px;
        margin-bottom: 20px;
        flex-wrap: wrap;
    }
    .hero-search-form {
        display: flex;
        align-items: center;
    }
    .hero-search-input {
        background: rgba(255, 255, 255, 0.06);
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-right: none;
        padding: 12px 20px;
        border-radius: 30px 0 0 30px;
        color: #ffffff;
        font-size: 0.95rem;
        outline: none;
        width: 340px;
        transition: all 0.3s ease;
    }
    .hero-search-input::placeholder {
        color: #64748b;
    }
    .hero-search-input:focus {
        border-color: #6366f1;
        background: rgba(255, 255, 255, 0.1);
        box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
    }
    .hero-search-btn {
        background: #4f46e5;
        color: #fff;
        border: 1px solid #4f46e5;
        padding: 12px 24px;
        border-radius: 0 30px 30px 0;
        font-weight: 600;
        cursor: pointer;
        font-size: 0.95rem;
        transition: all 0.3s ease;
    }
    .hero-search-btn:hover {
        background: #4338ca;
        border-color: #4338ca;
    }
    .hero-submit-btn {
        background: linear-gradient(135deg, #6366f1, #8b5cf6);
        color: #fff;
        border: none;
        padding: 12px 28px;
        border-radius: 30px;
        font-weight: 600;
        cursor: pointer;
        font-size: 0.95rem;
        text-decoration: none;
        transition: all 0.3s ease;
        box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
    }
    .hero-submit-btn:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4);
    }
    .hero-tags {
        display: flex;
        justify-content: flex-start;
        gap: 10px;
        flex-wrap: wrap;
    }
    .tag-pill {
        padding: 8px 20px;
        border-radius: 30px;
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid rgba(255, 255, 255, 0.1);
        color: #94a3b8;
        text-decoration: none;
        font-size: 0.85rem;
        font-weight: 500;
        transition: all 0.2s ease;
    }
    .tag-pill:hover, .tag-pill.active {
        background: rgba(255, 255, 255, 0.12);
        border-color: rgba(255, 255, 255, 0.25);
        color: #ffffff;
    }
    .tag-pill.active {
        background: rgba(99, 102, 241, 0.2);
        border-color: #6366f1;
        color: #a5b4fc;
    }
    
    /* 统计横幅 - 全宽横向平铺 */
    .stats-mini {
        max-width: 100%;
        margin-left: 0;
        margin-right: 0;
    }
    
    /* ============================================
       侧边栏分类名称完整显示 - 不截断不省略
       ============================================ */
    .sidebar-fixed .nav-main span:first-child,
    .sidebar-fixed .nav-sub {
        white-space: normal !important;
        overflow: visible !important;
        text-overflow: clip !important;
        word-wrap: break-word !important;
        hyphens: auto !important;
    }
    
    /* ============================================
       侧边栏底部链接一行显示
       ============================================ */
    .sidebar-fixed .side-footer {
        display: flex !important;
        flex-wrap: nowrap !important;
        gap: 12px !important;
        justify-content: center !important;
        align-items: center !important;
    }
    .sidebar-fixed .side-footer a {
        white-space: nowrap !important;
    }
    
    /* ============================================
       卡片区域标题优化
       ============================================ */
    .tool-card {
        transition: all 0.3s ease;
        border: 1px solid #1e2937;
        background: #111827;
    }
    .tool-card:hover {
        transform: translateY(-3px) scale(1.02);
        box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.5), 0 0 15px rgba(129, 140, 248, 0.1);
        border-color: #312e81;
    }

    /* ============================================
       【修复】Hero 区域搜索框在小屏下撑破页面的问题
       ============================================ */
    @media (max-width: 768px) {
        /* Hero 区域缩小 padding */
        .hero-section {
            padding: 0 12px !important;
        }
        
        /* 搜索表单容器强制换行，宽度不超过屏幕 */
        .hero-search {
            flex-wrap: wrap !important;
            gap: 8px !important;
        }
        
        .hero-search-form {
            display: flex !important;
            flex-wrap: wrap !important;
            width: 100% !important;
            max-width: 100% !important;
            box-sizing: border-box !important;
        }
        
        /* 输入框容器/输入框本身：撑满宽度，解除固定宽度锁定 */
        .hero-search-input {
            width: 100% !important;
            min-width: 0 !important;
            box-sizing: border-box !important;
            flex: 1 1 100% !important;
            font-size: 0.875rem !important;
            padding: 10px 16px !important;
        }
        
        /* Search 按钮跟随输入框换行，撑满宽度 */
        .hero-search-btn {
            flex: 0 0 100% !important;
            width: 100% !important;
            box-sizing: border-box !important;
            border-radius: 30px !important;
            padding: 10px 20px !important;
            font-size: 0.875rem !important;
        }
        
        /* Submit Your Tool 按钮：防止过宽溢出 */
        .hero-submit-btn {
            width: 100% !important;
            max-width: 100% !important;
            box-sizing: border-box !important;
            text-align: center !important;
            padding: 10px 20px !important;
            font-size: 0.875rem !important;
        }
        
        /* 大标题缩小 */
        .hero-title {
            font-size: 2rem !important;
        }
        
        /* 副标题缩小 */
        .hero-subtitle {
            font-size: 0.95rem !important;
            margin-bottom: 18px !important;
        }
        
        /* 胶囊标签间距缩小 */
        .hero-tags {
            gap: 6px !important;
        }
        
        .tag-pill {
            padding: 6px 14px !important;
            font-size: 0.75rem !important;
        }
    }
    
    @media (max-width: 480px) {
        /* 小手机进一步缩小 */
        .hero-section {
            padding: 0 8px !important;
            margin-top: 20px !important;
        }
        
        .hero-title {
            font-size: 1.5rem !important;
            margin-bottom: 8px !important;
        }
        
        .hero-subtitle {
            font-size: 0.85rem !important;
            margin-bottom: 15px !important;
        }
        
        .hero-search {
            margin-bottom: 15px !important;
        }
        
        .stats-mini {
            padding: 12px 8px !important;
        }
        
        .stats-mini .text-xl {
            font-size: 1.1rem !important;
        }
    }


        
    /* ============================================
       高端广告卡片样式 (Sponsored Card) - 暗黑主题
       ============================================ */
    
    /* 广告外层容器 */
    .ad-slot-wrapper, .ad-wrapper {
        width: 100%;
        max-width: 1600px;
        margin: 24px auto;
        box-sizing: border-box;
        padding: 0;
    }
    
    /* 广告顶部赞助商小标签 */
    .ad-label {
        font-size: 10px;
        color: #6b7280;
        font-weight: 700;
        letter-spacing: 1.5px;
        margin-bottom: 10px;
        padding-left: 2px;
        text-transform: uppercase;
    }
    
    /* 广告卡片主体 */
    .ad-card {
        position: relative;
        background: #121420;
        border: 1px solid #2a2e42;
        border-radius: 12px;
        padding: 24px;
        display: flex;
        align-items: center;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
        overflow: hidden;
        transition: border-color 0.3s ease;
    }
    
    /* 背景微光渐变效果 */
    .ad-card::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: radial-gradient(100% 100% at 100% 0%, rgba(99, 102, 241, 0.1) 0%, transparent 50%),
                    radial-gradient(100% 100% at 0% 100%, rgba(139, 92, 246, 0.05) 0%, transparent 50%);
        pointer-events: none;
        z-index: 1;
    }
    
    .ad-card:hover {
        border-color: #3f4663;
    }
    
    /* 卡片内部布局 */
    .ad-card-inner {
        position: relative;
        z-index: 2;
        display: flex;
        align-items: center;
        width: 100%;
    }
    
    /* 左侧图标 */
    .ad-icon {
        width: 56px;
        height: 56px;
        background: linear-gradient(135deg, #5b21b6, #3730a3);
        border-radius: 12px;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #ffffff;
        font-size: 24px;
        font-weight: bold;
        font-family: Arial, sans-serif;
        margin-right: 24px;
        flex-shrink: 0;
        box-shadow: 0 4px 12px rgba(91, 33, 182, 0.4);
    }
    
    /* 中间文本内容 */
    .ad-content {
        flex: 1;
    }
    
    .ad-title {
        color: #ffffff;
        font-size: 18px;
        font-weight: 700;
        margin-bottom: 6px;
    }
    
    .ad-desc {
        color: #9ca3af;
        font-size: 13px;
        line-height: 1.5;
        max-width: 85%;
    }
    
    /* 右侧 SPONSORED 按钮 */
    .ad-badge, .ad-btn {
        margin-left: 20px;
        border: 1px solid #d97706;
        color: #d97706;
        font-size: 11px;
        font-weight: 700;
        padding: 6px 14px;
        border-radius: 20px;
        letter-spacing: 0.5px;
        white-space: nowrap;
        flex-shrink: 0;
        text-transform: uppercase;
    }
    
    /* 防止第三方广告图片/iframe 撑破容器 */
    .ad-slot-wrapper img,
    .ad-slot-wrapper iframe,
    .ad-slot-wrapper embed,
    .ad-slot-wrapper object,
    .ad-slot-wrapper ins {
        max-width: 100%;
        height: auto;
        display: block;
    }
    
    /* 限制第三方广告内部标题/段落字号 */
    .ad-slot-wrapper h2,
    .ad-slot-wrapper h3,
    .ad-slot-wrapper h4 {
        font-size: 16px !important;
        margin: 0 0 10px 0 !important;
        color: #e5e7eb !important;
        line-height: 1.3 !important;
    }
    
    .ad-slot-wrapper p {
        font-size: 13px !important;
        margin: 0 !important;
        line-height: 1.6 !important;
        color: #9ca3af !important;
    }
    
    .ad-slot-wrapper a {
        color: #818cf8 !important;
        text-decoration: none !important;
    }
    
    /* 手机端适配 */
    @media screen and (max-width: 768px) {
        .ad-slot-wrapper {
            padding: 0 12px;
            margin: 16px auto;
        }
        
        .ad-card-inner {
            flex-direction: column;
            align-items: flex-start;
        }
        
        .ad-icon {
            margin-right: 0;
            margin-bottom: 16px;
        }
        
        .ad-desc {
            max-width: 100%;
            margin-bottom: 16px;
        }
        
        .ad-badge {
            margin-left: 0;
        }
    }


    /* ============================================
       高端赞助卡片样式 (Premium Sponsored Card)
       匹配用户 HTML: .sponsored-section / .premium-card / .premium-icon 等
       ============================================ */
    
    /* 外层 section 容器 */
    .sponsored-section {
        max-width: 1600px;
        margin: 30px auto;
        padding: 0;
        box-sizing: border-box;
    }
    
    /* 修复广告位4（在main外部的ad-slot-wrapper）恢复内边距 */
    .main-content > .ad-slot-wrapper {
        padding: 0 32px;
    }
    
    /* 标题文字 */
    .sponsored-section .section-title {
        font-size: 14px;
        font-weight: 700;
        color: #6b7280;
        letter-spacing: 1.5px;
        text-transform: uppercase;
        margin-bottom: 16px;
        padding-left: 2px;
        display: flex;
        align-items: center;
        gap: 8px;
    }
    
    /* 卡片主体 */
    .sponsored-section .premium-card {
        position: relative;
        background: linear-gradient(145deg, #121420 0%, #0f1119 100%);
        border: 1px solid #2a2e42;
        border-radius: 16px;
        padding: 28px 32px;
        display: flex;
        align-items: center;
        justify-content: space-between;
        box-shadow: 
            0 10px 40px rgba(0, 0, 0, 0.6),
            0 0 0 1px rgba(99, 102, 241, 0.05);
        overflow: hidden;
        transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }
    
    /* 卡片背景微光渐变效果（大气的关键） */
    .sponsored-section .premium-card::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: 
            radial-gradient(120% 120% at 100% 0%, rgba(99, 102, 241, 0.15) 0%, transparent 50%),
            radial-gradient(120% 120% at 0% 100%, rgba(139, 92, 246, 0.08) 0%, transparent 50%),
            radial-gradient(100% 100% at 50% 50%, rgba(99, 102, 241, 0.03) 0%, transparent 70%);
        pointer-events: none;
        z-index: 1;
    }
    
    /* 卡片悬停效果 */
    .sponsored-section .premium-card:hover {
        border-color: rgba(99, 102, 241, 0.5);
        transform: translateY(-2px);
        box-shadow: 
            0 20px 50px rgba(0, 0, 0, 0.7),
            0 0 30px rgba(99, 102, 241, 0.15),
            0 0 0 1px rgba(99, 102, 241, 0.1);
    }
    
    /* 左侧内容区 */
    .sponsored-section .premium-left {
        display: flex;
        align-items: center;
        gap: 24px;
        position: relative;
        z-index: 2;
        flex: 1;
    }
    
    /* 左侧图标方块 */
    .sponsored-section .premium-icon {
        width: 64px;
        height: 64px;
        background: linear-gradient(135deg, #5b21b6 0%, #3730a3 100%);
        border-radius: 14px;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #ffffff;
        font-size: 28px;
        font-weight: bold;
        font-family: 'Arial', sans-serif;
        flex-shrink: 0;
        box-shadow: 
            0 6px 20px rgba(91, 33, 182, 0.45),
            inset 0 1px 0 rgba(255, 255, 255, 0.1);
        transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        position: relative;
        overflow: hidden;
    }
    
    /* 图标悬停光泽扫过效果 */
    .sponsored-section .premium-icon::after {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 50%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
        transition: left 0.6s ease;
    }
    
    .sponsored-section .premium-card:hover .premium-icon::after {
        left: 100%;
    }
    
    .sponsored-section .premium-card:hover .premium-icon {
        transform: scale(1.05);
        box-shadow: 
            0 8px 25px rgba(91, 33, 182, 0.6),
            inset 0 1px 0 rgba(255, 255, 255, 0.15);
    }
    
    /* 元信息区域（标题+描述） */
    .sponsored-section .premium-meta {
        flex: 1;
        min-width: 0;
    }
    
    .sponsored-section .premium-meta h2 {
        color: #ffffff;
        font-size: 20px;
        font-weight: 700;
        margin: 0 0 8px 0;
        letter-spacing: -0.01em;
        text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    }
    
    .sponsored-section .premium-meta p {
        color: #9ca3af;
        font-size: 13px;
        line-height: 1.6;
        margin: 0;
        max-width: 600px;
    }
    
    /* 右侧 Sponsored 标签 */
    .sponsored-section .premium-tag {
        border: 1.5px solid #d97706;
        color: #d97706;
        font-size: 11px;
        font-weight: 800;
        padding: 8px 18px;
        border-radius: 30px;
        letter-spacing: 1px;
        white-space: nowrap;
        flex-shrink: 0;
        text-transform: uppercase;
        margin-left: 32px;
        background: rgba(217, 119, 6, 0.08);
        box-shadow: 0 0 15px rgba(217, 119, 6, 0.1);
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        position: relative;
        z-index: 2;
    }
    
    .sponsored-section .premium-card:hover .premium-tag {
        background: rgba(217, 119, 6, 0.15);
        box-shadow: 0 0 25px rgba(217, 119, 6, 0.2);
        transform: scale(1.05);
    }
    
    /* 手机端适配 */
    @media screen and (max-width: 768px) {
        .sponsored-section {
            padding: 0 16px;
            margin: 20px auto;
        }
        
        .sponsored-section .premium-card {
            flex-direction: column;
            align-items: flex-start;
            padding: 24px 20px;
        }
        
        .sponsored-section .premium-left {
            flex-direction: column;
            align-items: flex-start;
            width: 100%;
        }
        
        .sponsored-section .premium-icon {
            margin-bottom: 16px;
        }
        
        .sponsored-section .premium-meta p {
            max-width: 100%;
        }
        
        .sponsored-section .premium-tag {
            margin-left: 0;
            margin-top: 16px;
            align-self: flex-start;
        }
    }
    
    /* 小手机适配 */
    @media screen and (max-width: 480px) {
        .sponsored-section .premium-card {
            padding: 20px 16px;
        }
        
        .sponsored-section .premium-icon {
            width: 52px;
            height: 52px;
            font-size: 24px;
        }
        
        .sponsored-section .premium-meta h2 {
            font-size: 17px;
        }
        
        .sponsored-section .premium-meta p {
            font-size: 12px;
        }
        
        .sponsored-section .premium-tag {
            font-size: 10px;
            padding: 6px 14px;
        }
    }

    /* ============================================
       【补充】广告卡片独立样式（不依赖 .sponsored-section 包裹）
       确保后台广告位直接粘贴的 HTML 也能正确显示样式
       ============================================ */
    
    /* 卡片主体（独立选择器） */
    .premium-card {
        position: relative;
        background: linear-gradient(145deg, #121420 0%, #0f1119 100%);
        border: 1px solid #2a2e42;
        border-radius: 16px;
        padding: 28px 32px;
        display: flex;
        align-items: center;
        justify-content: space-between;
        box-shadow: 
            0 10px 40px rgba(0, 0, 0, 0.6),
            0 0 0 1px rgba(99, 102, 241, 0.05);
        overflow: hidden;
        transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        max-width: 1600px;
        margin: 0 auto;
    }
    
    /* 卡片背景微光渐变效果 */
    .premium-card::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: 
            radial-gradient(120% 120% at 100% 0%, rgba(99, 102, 241, 0.15) 0%, transparent 50%),
            radial-gradient(120% 120% at 0% 100%, rgba(139, 92, 246, 0.08) 0%, transparent 50%),
            radial-gradient(100% 100% at 50% 50%, rgba(99, 102, 241, 0.03) 0%, transparent 70%);
        pointer-events: none;
        z-index: 1;
    }
    
    /* 卡片悬停效果 */
    .premium-card:hover {
        border-color: rgba(99, 102, 241, 0.5);
        transform: translateY(-2px);
        box-shadow: 
            0 20px 50px rgba(0, 0, 0, 0.7),
            0 0 30px rgba(99, 102, 241, 0.15),
            0 0 0 1px rgba(99, 102, 241, 0.1);
    }
    
    /* 左侧内容区 */
    .premium-left {
        display: flex;
        align-items: center;
        gap: 24px;
        position: relative;
        z-index: 2;
        flex: 1;
    }
    
    /* 左侧图标方块 */
    .premium-icon {
        width: 64px;
        height: 64px;
        background: linear-gradient(135deg, #5b21b6 0%, #3730a3 100%);
        border-radius: 14px;
        display: flex;
        align-items: center;
        justify-content: center;
        color: #ffffff;
        font-size: 28px;
        font-weight: bold;
        font-family: 'Arial', sans-serif;
        flex-shrink: 0;
        box-shadow: 
            0 6px 20px rgba(91, 33, 182, 0.45),
            inset 0 1px 0 rgba(255, 255, 255, 0.1);
        transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        position: relative;
        overflow: hidden;
    }
    
    /* 图标悬停光泽扫过效果 */
    .premium-icon::after {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 50%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
        transition: left 0.6s ease;
    }
    
    .premium-card:hover .premium-icon::after {
        left: 100%;
    }
    
    .premium-card:hover .premium-icon {
        transform: scale(1.05);
        box-shadow: 
            0 8px 25px rgba(91, 33, 182, 0.6),
            inset 0 1px 0 rgba(255, 255, 255, 0.15);
    }
    
    /* 元信息区域（标题+描述） */
    .premium-meta {
        flex: 1;
        min-width: 0;
    }
    
    .premium-meta h2 {
        color: #ffffff;
        font-size: 20px;
        font-weight: 700;
        margin: 0 0 8px 0;
        letter-spacing: -0.01em;
        text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    }
    
    .premium-meta p {
        color: #9ca3af;
        font-size: 13px;
        line-height: 1.6;
        margin: 0;
        max-width: 600px;
    }
    
    /* 右侧 Sponsored 标签 */
    .premium-tag {
        border: 1.5px solid #d97706;
        color: #d97706;
        font-size: 11px;
        font-weight: 800;
        padding: 8px 18px;
        border-radius: 30px;
        letter-spacing: 1px;
        white-space: nowrap;
        flex-shrink: 0;
        text-transform: uppercase;
        margin-left: 32px;
        background: rgba(217, 119, 6, 0.08);
        box-shadow: 0 0 15px rgba(217, 119, 6, 0.1);
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        position: relative;
        z-index: 2;
    }
    
    .premium-card:hover .premium-tag {
        background: rgba(217, 119, 6, 0.15);
        box-shadow: 0 0 25px rgba(217, 119, 6, 0.2);
        transform: scale(1.05);
    }
    
    /* ============================================
       广告卡片链接包裹层悬停效果
       用户后台代码: <a class="premium-card-link" href="...">
       ============================================ */
    .premium-card-link {
        text-decoration: none !important;
        display: block;
    }
    
    .premium-card-link:hover .premium-card {
        border-color: rgba(99, 102, 241, 0.5);
        transform: translateY(-2px);
        box-shadow: 
            0 20px 50px rgba(0, 0, 0, 0.7),
            0 0 30px rgba(99, 102, 241, 0.15),
            0 0 0 1px rgba(99, 102, 241, 0.1);
    }
    
    /* 手机端适配（独立选择器） */
    @media screen and (max-width: 768px) {
        .premium-card {
            flex-direction: column;
            align-items: flex-start;
            padding: 24px 20px;
        }
        
        .premium-left {
            flex-direction: column;
            align-items: flex-start;
            width: 100%;
        }
        
        .premium-icon {
            margin-bottom: 16px;
        }
        
        .premium-meta p {
            max-width: 100%;
        }
        
        .premium-tag {
            margin-left: 0;
            margin-top: 16px;
            align-self: flex-start;
        }
    }
    
    /* 小手机适配（独立选择器） */
    @media screen and (max-width: 480px) {
        .premium-card {
            padding: 20px 16px;
        }
        
        .premium-icon {
            width: 52px;
            height: 52px;
            font-size: 24px;
        }
        
        .premium-meta h2 {
            font-size: 17px;
        }
        
        .premium-meta p {
            font-size: 12px;
        }
        
        .premium-tag {
            font-size: 10px;
            padding: 6px 14px;
        }
    }

    
    /* ============================================
       右侧侧边栏吸顶 - 大屏时跟随滚动，小屏正常流
       ============================================ */
    @media (min-width: 1024px) {
        .sticky-sidebar {
            position: sticky;
            top: 80px;
            max-height: calc(100vh - 80px);
            overflow-y: auto;
        }
        /* 美化滚动条 */
        .sticky-sidebar::-webkit-scrollbar {
            width: 4px;
        }
        .sticky-sidebar::-webkit-scrollbar-thumb {
            background-color: #334155;
            border-radius: 4px;
        }
        .sticky-sidebar::-webkit-scrollbar-track {
            background: transparent;
        }
    }
    
    * { box-sizing: border-box; }
body { 
    background-color: #0a0a12 !important; 
    color: #e5e7eb !important; 
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; 
    margin: 0; padding: 0; line-height: 1.6;
}
a { color: #a8a3b8; text-decoration: none; transition: color 0.2s; }
a:hover { color: #8b5cf6; }
h1, h2, h3 { color: #ffffff; margin: 0; }
ul, ol { list-style: none; margin: 0; padding: 0; }

/* ================== Wide Layout ================== */
.main-container { max-width: 1600px; margin: 0 auto; padding: 0 40px 60px; }
.content-container { display: flex; gap: 30px; align-items: flex-start; margin-top: 30px; }

/* Left Column (Rankings Grid) */
.mainbox-left-column { 
    flex: 1; 
    min-width: 0; 
    display: grid; 
    /* 2 columns on wide screens */
    grid-template-columns: repeat(2, minmax(0, 1fr)); 
    gap: 24px; 
}
@media (max-width: 900px) { .mainbox-left-column { grid-template-columns: 1fr; } }

/* Right Ad Column */
.mainbox-right-column { width: 320px; flex-shrink: 0; position: sticky; top: 80px; }

/* ================== Ranking Card Styles ================== */
.topsite { 
    background: #12121e; 
    border: 1px solid #1e1e30; 
    border-radius: 16px; 
    padding: 24px; 
    margin: 0 !important; 
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.2);
}
.topsite h3 { 
    font-size: 18px; 
    margin-bottom: 20px; 
    padding-left: 12px; 
    border-left: 4px solid #8b5cf6; 
    display: flex; 
    align-items: center;
}

/* Ranking List */
.toplist { display: flex; flex-direction: column; gap: 14px; }
.toplist li { 
    display: flex; 
    align-items: center; 
    font-size: 14px; 
    padding: 10px 12px;
    background: #0a0a12;
    border-radius: 8px;
    border: 1px solid transparent;
    transition: all 0.2s;
    overflow: hidden; 
}
.toplist li:hover { 
    border-color: #2a3343; 
    background: #161b26; 
}

/* Rank Numbers */
.toplist li span { 
    display: inline-flex; 
    align-items: center; 
    justify-content: center; 
    width: 22px; 
    height: 22px; 
    flex-shrink: 0; 
    background: #1f2937; 
    color: #9ca3af; 
    border-radius: 6px; 
    font-size: 12px; 
    font-weight: 700; 
    margin-right: 12px; 
}
/* Top 3 highlight (Gold, Silver, Bronze) */
.toplist li:nth-child(1) span { background: rgba(234,179,8,0.2); color: #facc15; }
.toplist li:nth-child(2) span { background: rgba(156,163,175,0.2); color: #e5e7eb; }
.toplist li:nth-child(3) span { background: rgba(180,83,9,0.2); color: #f97316; }

/* Website Name */
.toplist li > a { 
    font-weight: 600; 
    color: #f8fafc; 
    white-space: nowrap; 
    overflow: hidden; 
    text-overflow: ellipsis; 
    max-width: 45%; 
}
.toplist li > a:hover { color: #8b5cf6; }

/* Domain and Separators */
.toplist li em { 
    font-style: normal; 
    color: #6b7280; 
    margin: 0 8px; 
    flex-shrink: 0; 
}
.toplist li em a { 
    color: #6b7280; 
    font-size: 13px; 
    white-space: nowrap; 
    overflow: hidden; 
    text-overflow: ellipsis; 
    display: block; 
    max-width: 150px; 
}
.toplist li em a:hover { color: #a8a3b8; text-decoration: underline; }

/* ================== Right Ad Boxes ================== */
.ad-box-1 { background: #12121e; border: 1px solid #1e1e30; border-radius: 16px; overflow: hidden; margin-bottom: 24px; min-height: 250px; display: flex; align-items: center; justify-content: center; }
.ad-box-2 { background: #12121e; border: 1px solid #1e1e30; border-radius: 16px; overflow: hidden; min-height: 250px; display: flex; align-items: center; justify-content: center; }

/* ================== Footer ================== */
.main-container > .footer, .main-container > footer {
    margin-top: 60px !important; padding: 30px 0 !important; border-top: 1px solid #1e1e30 !important; text-align: center !important; color: #6b6880 !important;
}

/* ================== Responsive ================== */
@media (max-width: 1024px) {
    .content-container { flex-direction: column; }
    .mainbox-right-column { width: 100%; position: static; margin-top: 30px; }
    .main-container { padding: 0 20px 40px; }
}













    .tool-card {
        background: #111827; border: 1px solid #1f2937; transition: all 0.25s ease;
        display: flex; flex-direction: column; padding: 20px; border-radius: 14px;
        height: 100%; position: relative;
    }
    .tool-card:hover { border-color: #4f46e5; background: #1e293b; box-shadow: 0 8px 30px -5px rgba(79, 70, 229, 0.25); transform: translateY(-2px); }
    
    .card-top { display: flex; align-items: flex-start; margin-bottom: 16px; }
    
    /* Logo 底座 */
    .card-logo-box {
        width: 52px; height: 52px; border-radius: 12px; background: #0f172a; 
        border: 1px solid #1e293b; display: flex; align-items: center; justify-content: center; overflow: hidden;
    }
    .card-logo { width: 100%; height: 100%; padding: 8px; object-fit: contain; }
    
    .card-title { font-size: 17px; font-weight: 700; color: #f8fafc; margin-bottom: 8px; text-overflow: ellipsis; white-space: nowrap; overflow: hidden; }
    .card-desc { font-size: 13px; color: #94a3b8; line-height: 1.6; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; height: 42px; margin-bottom: 16px; }
    .card-footer { margin-top: auto; padding-top: 12px; border-top: 1px solid #1f2937; display: flex; justify-content: space-between; align-items: center; font-size: 12px; color: #64748b; }
    .card-badge { position: absolute; top: 20px; right: 20px; padding: 4px 10px; border-radius: 20px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; }
    .badge-free { background: rgba(16, 185, 129, 0.1); color: #34d399; border: 1px solid rgba(16, 185, 129, 0.2); }
    .badge-paid { background: rgba(245, 158, 11, 0.1); color: #fbbf24; border: 1px solid rgba(245, 158, 11, 0.2); }