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

/* 根变量 */
:root {
    --primary-color: #3b82f6;
    --secondary-color: #7446ca;
    --accent-color: #f59e0b;
    --text-color: #345f92;
    --text-light: #6b7280;
    --bg-color: #ffffff;
    --bg-light: #f8fafc;
    --border-color: #e5e7eb;
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --border-radius: 8px;
    --transition: all 0.3s ease;
}

/* 基础样式 */
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
    overflow-x: hidden;
}

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

/* 导航栏样式 */
.header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    box-shadow: var(--shadow);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

.nav {
    padding: 1rem 0;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.nav-logo h1 {
    color: white;
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-menu {
    display: flex;
    gap: 2rem;
}

.nav-link {
    color: white;
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.nav-link:hover,
.nav-link.active {
    background-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background-color: white;
    border-radius: 2px;
    transition: var(--transition);
}

/* 主要内容区域 */
.main {
    margin-top: 80px;
    min-height: calc(100vh - 80px);
}

/* 英雄区域 */
.hero {
    background: linear-gradient(135deg, var(--bg-light) 0%, #e0f2fe 100%);
    padding: 4rem 0;
    text-align: center;
}

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

.hero-title {
    font-size: 3rem;
    font-weight: 800;
    color: var(--text-color);
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-light);
    margin-bottom: 2rem;
    line-height: 1.8;
}

.hero-search {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
    background: white;
    border-radius: 50px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    transition: var(--transition);
}

.hero-search:focus-within {
    transform: translateY(-2px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.search-input {
    flex: 1;
    padding: 1rem 1.5rem;
    border: none;
    outline: none;
    font-size: 1rem;
    background: transparent;
}

.search-btn {
    padding: 1rem 1.5rem;
    background: var(--primary-color);
    border: none;
    color: white;
    cursor: pointer;
    font-size: 1.2rem;
    transition: var(--transition);
}

.search-btn:hover {
    background: var(--secondary-color);
}

/* 工具分类区域 */
.tools-section {
    padding: 4rem 0;
    background: var(--bg-color);
}

/* 工具布局 */
.tools-layout {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 2rem;
    margin-top: 2rem;
}

/* 工具侧边栏 */
.tools-sidebar {
    background: var(--bg-light);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    height: fit-content;
    max-height: 80vh;
    position: sticky;
    top: 2rem;
    overflow-y: auto;
    overflow-x: hidden;
}

.sidebar-header h3 {
    margin: 0 0 1rem 0;
    color: var(--text-color);
    font-size: 1.1rem;
    font-weight: 600;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 0.5rem;
}

.sidebar-menu {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.sidebar-category {
    display: block;
    padding: 0.75rem 1rem;
    color: var(--text-light);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    border-left: 3px solid transparent;
    position: relative;
}

.sidebar-category:hover {
    background: var(--hover-bg);
    color: var(--text-color);
    border-left-color: var(--primary-color);
    transform: translateX(3px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.sidebar-category.active {
    background: var(--primary-color);
    color: white;
    border-left-color: var(--secondary-color);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

.sidebar-category.active:hover {
    background: var(--secondary-color);
    transform: translateX(3px);
}

/* 工具内容区域 */
.tools-content {
    min-height: 400px;
}

/* 工具分类切换按钮（移动端） */
.tools-toggle-btn {
    display: none;
    width: 100%;
    padding: 1rem;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    margin-bottom: 1rem;
    justify-content: space-between;
    align-items: center;
}

.tools-toggle-btn:hover {
    background: var(--secondary-color);
}

.tools-toggle-btn.active .toggle-icon {
    transform: rotate(180deg);
}

/* 工具分类动画 */
.tool-category {
    transition: opacity 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
    opacity: 1;
    transform: translateY(0);
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 3rem;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    border-radius: 2px;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.tool-category {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: var(--transition);
}

.tool-category:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.category-header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 1.5rem;
    text-align: center;
}

.category-header h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.category-header p {
    opacity: 0.9;
    font-size: 0.9rem;
}

.tools-list {
    padding: 1.5rem;
    display: grid;
    gap: 1rem;
}

.tool-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: var(--bg-light);
    border-radius: var(--border-radius);
    text-decoration: none;
    color: var(--text-color);
    transition: var(--transition);
    border: 2px solid transparent;
}

.tool-item:hover {
    background: white;
    border-color: var(--primary-color);
    transform: translateX(5px);
    box-shadow: var(--shadow);
}

/* 在线工具收藏：两列布局（与影视娱乐视觉一致） */
.tools-collection .tools-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 768px) {
    .tools-collection .tools-list {
        grid-template-columns: 1fr;
    }
}

.tool-icon {
    font-size: 1.5rem;
    min-width: 2rem;
    text-align: center;
}

.tool-name {
    font-weight: 600;
    font-size: 1rem;
    color: var(--text-color);
}

.tool-desc {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-left: auto;
    text-align: right;
}

/* 关于区域 */
.about-section {
    padding: 4rem 0;
    background: var(--bg-light);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

.about-text p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-light);
}

.about-features {
    display: grid;
    gap: 1.5rem;
}

.feature-item {
    background: white;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    text-align: center;
    transition: var(--transition);
}

.feature-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    font-size: 2rem;
    display: block;
    margin-bottom: 1rem;
}

.feature-item h4 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 0.5rem;
}

.feature-item p {
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.6;
}

/* 页脚 */
.footer {
    background: var(--text-color);
    color: white;
    padding: 3rem 0 1rem;
}

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

.footer-section h4 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.footer-section p {
    color: #d1d5db;
    line-height: 1.6;
}

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

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: #d1d5db;
    text-decoration: none;
    transition: var(--transition);
}

.footer-section ul li a:hover {
    color: var(--primary-color);
}

/* 联系方式 */
.contact-list {
    list-style: none;
    padding: 0;
    margin: 0 0 0.5rem 0;
    display: grid;
    gap: 0.5rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.contact-icon {
    width: 18px;
    height: 18px;
    filter: invert(85%) sepia(6%) saturate(318%) hue-rotate(180deg) brightness(92%) contrast(88%);
}

.contact-item a {
    color: #d1d5db;
    text-decoration: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    width: fit-content;
}

.contact-item a:hover {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.footer-bottom {
    border-top: 1px solid #2e589b;
    padding-top: 1rem;
    text-align: center;
    color: #9ca3af;
}

.footer-bottom p {
    font-size: 0.65rem;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-search {
        flex-direction: column;
        border-radius: var(--border-radius);
    }
    
    .search-input {
        border-radius: var(--border-radius) var(--border-radius) 0 0;
    }
    
    .search-btn {
        border-radius: 0 0 var(--border-radius) var(--border-radius);
    }
    
    .tools-content .tools-grid {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }
    
    /* 所有分类占满整行 */
    .tools-content .tools-grid .tool-category {
        grid-column: 1 / -1 !important;
        width: 100% !important;
        max-width: 100% !important;
    }
    
    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .tool-item {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }
    
    .tool-desc {
        margin-left: 0;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .hero {
        padding: 2rem 0;
    }
    
    .hero-title {
        font-size: 1.8rem;
    }
    
    .tools-section,
    .about-section {
        padding: 2rem 0;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
}

/* 滚动行为 */
html {
    scroll-behavior: smooth;
}

/* 加载动画 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.tool-category {
    animation: fadeInUp 0.6s ease forwards;
}

.tool-category:nth-child(1) { animation-delay: 0.1s; }
.tool-category:nth-child(2) { animation-delay: 0.2s; }
.tool-category:nth-child(3) { animation-delay: 0.3s; }
.tool-category:nth-child(4) { animation-delay: 0.4s; }
.tool-category:nth-child(5) { animation-delay: 0.5s; }
.tool-category:nth-child(6) { animation-delay: 0.6s; }

/* 焦点样式 */
.tool-item:focus,
.search-input:focus,
.search-btn:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* 选择文本样式 */
::selection {
    background-color: var(--primary-color);
    color: white;
}

/* 影视模块样式 */
.movie-category {
    grid-column: 1 / -1; /* 占据整行 */
    margin-top: 1rem;
}

/* 在线工具收藏：单独起一行，与影视娱乐同级对齐 */
.tools-collection {
    grid-column: 1 / -1;
    margin-top: 1rem;
}

.movie-subnav {
    padding: 1rem 1.5rem 0;
    border-bottom: 1px solid var(--border-color);
}

.subnav-tabs {
    display: flex;
    gap: 0;
    background: var(--bg-light);
    border-radius: var(--border-radius);
    padding: 0.25rem;
}

.subnav-tab {
    flex: 1;
    padding: 0.75rem 1rem;
    border: none;
    background: transparent;
    color: var(--text-light);
    font-weight: 500;
    border-radius: calc(var(--border-radius) - 2px);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
}

.subnav-tab:hover {
    background: rgba(59, 130, 246, 0.1);
    color: var(--primary-color);
}

.subnav-tab.active {
    background: var(--primary-color);
    color: white;
    box-shadow: var(--shadow);
}

.movie-content {
    display: none;
    padding: 1.5rem;
}

.movie-content.active {
    display: block;
}

.movie-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
}

.movie-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    text-decoration: none;
    color: var(--text-color);
    transition: var(--transition);
    position: relative;
}

.movie-item:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.movie-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: bold;
    flex-shrink: 0;
    box-shadow: var(--shadow);
}

.movie-info {
    flex: 1;
    min-width: 0;
}

.movie-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-color);
    margin: 0 0 0.25rem 0;
    line-height: 1.3;
}

.movie-desc {
    font-size: 0.85rem;
    color: var(--text-light);
    margin: 0;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.movie-dropdown {
    color: var(--text-light);
    font-size: 0.8rem;
    opacity: 0.6;
    transition: var(--transition);
    flex-shrink: 0;
}

.movie-item:hover .movie-dropdown {
    opacity: 1;
    color: var(--primary-color);
}

/* 影视模块响应式设计 */
@media (max-width: 768px) {
    .movie-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0.5rem !important;
    }
    
    .movie-item {
        padding: 0.75rem;
        gap: 0.75rem;
    }
    
    .movie-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .movie-title {
        font-size: 0.9rem;
    }
    
    .movie-desc {
        font-size: 0.8rem;
    }
    
    .subnav-tabs {
        flex-direction: row;
        gap: 0.25rem;
    }
    
    .subnav-tab {
        text-align: center;
        padding: 0.5rem;
        flex: 1;
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .movie-content {
        padding: 1rem;
    }
    
    .movie-subnav {
        padding: 0.75rem 1rem 0;
        flex-direction: row;
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .subnav-tab {
        flex: 1;
        min-width: 80px;
        text-align: center;
        font-size: 0.8rem;
        padding: 0.5rem 0.75rem;
    }
    
    .movie-item {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }
    
    .movie-icon {
        width: 36px;
        height: 36px;
    }
    
    .movie-info {
        order: 2;
    }
    
    .movie-dropdown {
        position: absolute;
        top: 0.5rem;
        right: 0.5rem;
        order: 1;
    }
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-light);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* 侧边栏滚动条样式 */
.mobile-sidebar::-webkit-scrollbar,
.tools-sidebar::-webkit-scrollbar {
    width: 6px;
}

.mobile-sidebar::-webkit-scrollbar-track,
.tools-sidebar::-webkit-scrollbar-track {
    background: transparent;
}

.mobile-sidebar::-webkit-scrollbar-thumb,
.tools-sidebar::-webkit-scrollbar-thumb {
    background: rgba(59, 130, 246, 0.3);
    border-radius: 3px;
}

.mobile-sidebar::-webkit-scrollbar-thumb:hover,
.tools-sidebar::-webkit-scrollbar-thumb:hover {
    background: rgba(59, 130, 246, 0.6);
}

/* 移动端菜单按钮 */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background-color: white;
    margin: 3px 0;
    transition: var(--transition);
    border-radius: 2px;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(45deg) translate(-5px, -6px);
}

/* 移动端侧边栏 */
.mobile-sidebar {
    position: fixed;
    top: 0;
    left: -300px;
    width: 300px;
    height: 100vh;
    background: var(--bg-color);
    border-right: 1px solid var(--border-color);
    z-index: 1000;
    transition: left 0.3s ease;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    overflow-y: auto;
    overflow-x: hidden;
}

.mobile-sidebar.active {
    left: 0;
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-header h2 {
    margin: 0;
    color: var(--text-color);
    font-size: 1.2rem;
}

.sidebar-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-color);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: var(--transition);
}

.sidebar-close:hover {
    background: var(--hover-bg);
}

.sidebar-menu {
    padding: 1rem 0;
}

.sidebar-link {
    display: block;
    padding: 1rem 1.5rem;
    color: var(--text-color);
    text-decoration: none;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
    position: relative;
}

.sidebar-link:hover {
    background: var(--hover-bg);
    border-left-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateX(5px);
}

.sidebar-link.active {
    background: var(--primary-color);
    color: white;
    border-left-color: var(--secondary-color);
}

.sidebar-link.active:hover {
    background: var(--secondary-color);
    transform: translateX(5px);
}

/* 侧边栏遮罩 */
.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.sidebar-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* 移动端响应式调整 */
@media (max-width: 768px) {
    .nav-container {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
    
    .nav-menu {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }
    
    .tools-collection .tools-list {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0.5rem !important;
    }
    
    /* 影视娱乐工具列表多列布局 */
    .movie-category .tools-list {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0.5rem !important;
    }
    
    /* 工具分类移动端样式调整 */
    
    .tool-category {
        margin-bottom: 1rem;
    }
    
    .category-header {
        padding: 1rem;
    }
    
    .category-header h3 {
        font-size: 1rem;
    }
    
    .category-header p {
        font-size: 0.8rem;
    }
    
    .tools-list {
        padding: 1rem;
    }
    
    .tool-item {
        padding: 0.4rem;
        font-size: 0.75rem;
    }
    
    .tool-icon {
        font-size: 0.8rem;
    }
    
    .tool-name {
        font-size: 0.75rem;
    }
    
    .tool-desc {
        font-size: 0.65rem;
    }
    
    /* 工具列表多列布局 */
    .tools-list {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 0.5rem;
    }
    
    /* 工具布局移动端调整 - 隐藏侧边栏 */
    .tools-layout {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .tools-toggle-btn {
        display: flex;
    }
    
    .tools-sidebar {
        display: none;
        position: static;
        padding: 1rem;
        margin-bottom: 1rem;
        background: var(--bg-light);
        border-radius: 8px;
    }
    
    .tools-sidebar.active {
        display: block;
    }
    
    .sidebar-header h3 {
        font-size: 1rem;
    }
    
    .sidebar-category {
        font-size: 0.8rem;
        padding: 0.6rem 0.8rem;
    }
}

/* 超小屏幕调整 */
@media (max-width: 480px) {
    .tools-layout {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
    
    .tools-toggle-btn {
        padding: 0.8rem;
        font-size: 0.9rem;
    }
    
    .tools-sidebar {
        padding: 0.8rem;
    }
    
    .sidebar-header h3 {
        font-size: 0.9rem;
        margin-bottom: 0.8rem;
    }
    
    .sidebar-category {
        font-size: 0.75rem;
        padding: 0.5rem 0.6rem;
    }
    
    .tools-content {
        min-height: 300px;
    }
    
    /* 工具分类超小屏幕样式调整 */
    .tools-content .tools-grid {
        grid-template-columns: 1fr !important;
        gap: 0.5rem !important;
    }
    
    /* 所有分类占满整行 */
    .tools-content .tools-grid .tool-category {
        grid-column: 1 / -1 !important;
        width: 100% !important;
        max-width: 100% !important;
    }
    
    .tool-category {
        margin-bottom: 0.8rem;
    }
    
    .category-header {
        padding: 0.8rem;
    }
    
    .category-header h3 {
        font-size: 0.9rem;
    }
    
    .category-header p {
        font-size: 0.7rem;
    }
    
    .tools-list {
        padding: 0.8rem;
    }
    
    .tool-item {
        padding: 0.3rem;
        font-size: 0.7rem;
    }
    
    .tool-icon {
        font-size: 0.75rem;
    }
    
    .tool-name {
        font-size: 0.7rem;
    }
    
    .tool-desc {
        font-size: 0.6rem;
    }
    
    /* 工具列表三列布局 */
    .tools-list {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 0.4rem;
    }
    
    /* 在线工具收藏和影视娱乐三列布局 */
    .tools-collection .tools-list,
    .movie-category .tools-list {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 0.4rem !important;
    }
    
    /* 影视娱乐三列布局 */
    .movie-grid {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 0.4rem !important;
    }
    
    /* 影视娱乐移动端水平布局优化 */
    .movie-subnav {
        flex-direction: row;
        gap: 0.3rem;
    }
    
    .subnav-tab {
        flex: 1;
        min-width: 70px;
        font-size: 0.75rem;
        padding: 0.4rem 0.5rem;
    }
}

