
:root {
    /*--primary-color: #4f46e5;*/
    /*--secondary-color: #6366f1;*/
    --dark-color: #1e293b;
    --light-color: #f8fafc;
    --gray-color: #94a3b8;
    /*--hover-color: #4338ca;*/
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
}

body {
    background-color: #f1f5f9;
    color: var(--dark-color);
}

/* 顶部导航 */
.top-nav {
    background-color: white;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 50;
    padding: 0 2rem;
}

.nav-container {
    max-width: 100%;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 60px;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    display: flex;
    align-items: center;
}

.logo i {
    margin-right: 10px;
    font-size: 1.8rem;
}

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

.nav-links a {
    color: var(--dark-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
    position: relative;
    padding: 0.5rem 0;
}

.nav-links a:hover {
    color: var(--primary-color);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s;
}

.nav-links a:hover::after {
    width: 100%;
}

/* 主体布局 */
.main-container {
    display: flex;
    min-height: calc(100vh - 60px);
}

/* 左侧导航 */
.sidebar2 {
    width: 220px;
    background-color: white;
    border-right: 1px solid #e2e8f0;
    padding: 1.5rem 0;
    position: sticky;
    top: 60px;
    height: calc(100vh - 60px);
    overflow-y: auto;
}

.sidebar-title {
    padding: 0 1.5rem 1rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--gray-color);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

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

.nav-item1 {
    margin-bottom: 0.25rem;
}

.nav-link {
    display: flex;
    align-items: center;
    padding: 0.75rem 1.5rem;
    color: var(--dark-color);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
    position: relative;
}

.nav-link:hover {
    background-color: #f1f5f9;
    color: var(--primary-color);
}

.nav-link.active  {
    background-color: #eef2ff;
    color: var(--primary-color);
    border-left: 3px solid var(--primary-color);
}

.nav-link i {
    margin-right: 0.75rem;
    font-size: 1.1rem;
    width: 20px;
    text-align: center;
}

/* 右侧内容 */
.content {
    flex: 1;
    padding: 2rem;
    background-color: #f8fafc;
}

.section {
    margin-bottom: 3rem;
    scroll-margin-top: 100px;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--dark-color);
    display: flex;
    align-items: center;
}

.section-title i {
    margin-right: 0.75rem;
    color: var(--primary-color);
}

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

.tool-card {
    background-color: white;
    border-radius: 0.5rem;
    /*padding: 1.5rem;*/
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: all 0.3s;
    cursor: pointer;
}

.tool-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.tool-header {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
}

.tool-icon {
    width: 40px;
    height: 40px;
    background-color: #eef2ff;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    color: var(--primary-color);
    font-size: 1.25rem;
}

.tool-name {
    font-weight: 600;
    font-size: 1.1rem;
}

.tool-desc {
    color: var(--gray-color);
    font-size: 0.9rem;
    line-height: 1.5;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .main-container {
        /*flex-direction: column;*/
    }

    .sidebar {
        width: 100%;
        height: auto;
        position: static;
        border-right: none;
        border-bottom: 1px solid #e2e8f0;
    }

    .nav-links {
        display: none;
    }

    .tools-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    }
}
