/* ==================== 全局重置与基础样式 ==================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: #f5f7fa;
    color: #303133;
}

/* ==================== 统一页眉设计 (参考 Tisilu) ==================== */
.global-header {
    background-color: #304156;
    color: white;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.logo {
    font-size: 1.25rem;
    font-weight: bold;
    letter-spacing: 1px;
    cursor: pointer;
    user-select: none;
    transition: opacity 0.3s;
}

.logo:hover {
    opacity: 0.8;
}

.nav-links {
    display: flex;
    gap: 0.5rem;
}

.nav-links a {
    color: #bfcbd9;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.3s;
    font-size: 0.9rem;
    font-weight: 500;
}

.nav-links a:hover {
    color: #409eff;
    background-color: rgba(64, 158, 255, 0.1);
}

.nav-links a.active {
    color: #409eff;
    background-color: rgba(64, 158, 255, 0.15);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* ==================== 主内容区 ==================== */
.main-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    min-height: calc(100vh - 60px);
}

/* ==================== 按钮样式 ==================== */
.btn {
    padding: 0.5rem 1.25rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background-color: #409eff;
    color: white;
}

.btn-primary:hover {
    background-color: #66b1ff;
}

.btn-secondary {
    background-color: #909399;
    color: white;
}

.btn-secondary:hover {
    background-color: #a6a9ad;
}

.btn-success {
    background-color: #67c23a;
    color: white;
}

.btn-success:hover {
    background-color: #85ce61;
}

/* ==================== 卡片样式 ==================== */
.card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    padding: 1.5rem;
    transition: all 0.3s;
}

.card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

/* ==================== 网格布局 ==================== */
.grid-layout {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

/* ==================== 响应式设计 ==================== */
@media (max-width: 768px) {
    .global-header {
        padding: 0 1rem;
    }
    
    .header-left {
        gap: 1rem;
    }
    
    .nav-links {
        display: none; /* 移动端可以改为汉堡菜单 */
    }
    
    .main-container {
        padding: 1rem;
    }
    
    .grid-layout {
        grid-template-columns: 1fr;
    }
}
