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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: #f0f2f5;
    color: #333;
    line-height: 1.6;
}

/* 主容器 */
.app-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* 顶部导航栏 */
.header {
    background: linear-gradient(135deg, #1890ff 0%, #36cfc9 100%);
    color: white;
    padding: 0 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.header-content {
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1440px;
    margin: 0 auto;
}

.logo-area {
    display: flex;
    align-items: center;
}

.logo {
    height: 40px;
    margin-right: 12px;
}

.system-name {
    font-size: 20px;
    font-weight: 600;
    margin: 0;
    margin-right: 32px;
}

/* 模块导航菜单 */
.module-nav {
    display: flex;
    gap: 16px;
    margin-left: 24px;
}

.module-btn {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.85);
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.module-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.module-btn.active {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border-color: rgba(255, 255, 255, 0.3);
    font-weight: 500;
}

.header-info {
    display: flex;
    align-items: center;
    gap: 24px;
}

.time-info, .weather-info {
    font-size: 14px;
}

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

.user-avatar img {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.user-details {
    text-align: right;
}

.user-name {
    font-size: 14px;
    font-weight: 500;
}

.login-time {
    font-size: 12px;
    opacity: 0.8;
}

/* 主要内容区域 */
.main-content {
    flex: 1;
    display: flex;
    max-width: 1440px;
    margin: 20px auto;
    width: 100%;
    gap: 20px;
    padding: 0 20px;
}

/* 左侧菜单栏 */
.sidebar {
    width: 240px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.menu {
    padding: 16px 0;
}

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

.menu-item {
    cursor: pointer;
    transition: all 0.3s ease;
    color: #666;
}

.menu-item:hover {
    background-color: #f5f5f5;
}

.menu-item.active {
    color: #1890ff;
}

/* 一级菜单主内容 */
.menu-main {
    display: flex;
    align-items: center;
    padding: 12px 24px;
}

.menu-icon {
    font-size: 18px;
    margin-right: 12px;
    width: 24px;
    text-align: center;
}

.menu-text {
    font-size: 14px;
    font-weight: 500;
    flex: 1;
}

/* 箭头图标 */
.menu-arrow {
    font-size: 12px;
    transition: transform 0.3s ease;
}

.menu-item.expanded .menu-arrow {
    transform: rotate(90deg);
}

/* 二级菜单样式 */
.submenu-list {
    list-style: none;
    background-color: #f9fafb;
    display: none;
}

.menu-item.expanded .submenu-list {
    display: block;
}

.submenu-item {
    display: flex;
    align-items: center;
    padding: 10px 24px 10px 60px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: #666;
}

.submenu-item:hover {
    background-color: #f5f5f5;
    color: #1890ff;
}

.submenu-item.active {
    background-color: #e6f7ff;
    color: #1890ff;
    font-weight: 500;
}

/* 右侧内容区 */
.content-area {
    flex: 1;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    min-height: 600px;
    display: flex;
    flex-direction: column;
}

.content-header {
    padding: 24px;
    border-bottom: 1px solid #f0f0f0;
}

.content-title {
    font-size: 24px;
    color: #333;
    margin-bottom: 8px;
}

.breadcrumb {
    font-size: 14px;
    color: #666;
}

/* 内嵌页面容器 */
.content-body {
    flex: 1;
    overflow: hidden;
}

.page-frame {
    width: 100%;
    height: 100%;
    border: none;
    transition: opacity 0.3s ease;
}

.page-frame.loading {
    opacity: 0.5;
}

/* 页面样式 */
.page-header {
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid #f0f0f0;
}

.page-header h2 {
    font-size: 24px;
    color: #333;
    margin-bottom: 8px;
}

.page-header p {
    font-size: 14px;
    color: #666;
}

.page-content {
    min-height: 400px;
}

/* 快捷入口 */
.quick-access {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 16px;
    margin-bottom: 32px;
}

.quick-item {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 24px;
    border-radius: 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.quick-item:nth-child(2) {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.quick-item:nth-child(3) {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.quick-item:nth-child(4) {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

.quick-item:nth-child(5) {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
}

.quick-item:nth-child(6) {
    background: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%);
}

.quick-item:nth-child(7) {
    background: linear-gradient(135deg, #d299c2 0%, #fef9d7 100%);
}

.quick-item:nth-child(8) {
    background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
}

.quick-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.4);
}

.quick-icon {
    font-size: 32px;
    margin-bottom: 8px;
}

.quick-text {
    font-size: 14px;
    font-weight: 500;
}

.quick-item.add-more {
    background: #f0f2f5;
    color: #666;
    border: 2px dashed #d9d9d9;
}

.quick-item.add-more:hover {
    background: #e6f7ff;
    border-color: #1890ff;
    color: #1890ff;
}

/* 数据概览 */
.data-overview {
    margin-bottom: 32px;
}

.data-overview h3 {
    font-size: 18px;
    color: #333;
    margin-bottom: 16px;
}

.overview-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.overview-card {
    background: linear-gradient(135deg, #ffffff 0%, #f0f2f5 100%);
    padding: 24px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid #e8e8e8;
}

.overview-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.card-icon {
    font-size: 36px;
    margin-bottom: 12px;
    color: #1890ff;
}

.card-title {
    font-size: 14px;
    color: #666;
    margin-bottom: 8px;
}

.card-value {
    font-size: 32px;
    font-weight: 600;
    color: #333;
}

/* 公告信息 */
.announcement-section {
    margin-bottom: 24px;
}

.announcement-section h3 {
    font-size: 18px;
    color: #333;
    margin-bottom: 16px;
}

.announcement-content {
    background: #fafafa;
    border-radius: 8px;
    padding: 16px;
    border-left: 4px solid #1890ff;
}

.announcement-item {
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}

.announcement-item:last-child {
    border-bottom: none;
}

.announcement-title {
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin-bottom: 4px;
}

.announcement-date {
    font-size: 12px;
    color: #999;
    margin-bottom: 4px;
}

.announcement-text {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 64px 24px;
    color: #999;
}

.empty-icon {
    font-size: 72px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.empty-state h3 {
    font-size: 18px;
    color: #666;
    margin-bottom: 8px;
}

.empty-state p {
    font-size: 14px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .main-content {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
    }
    
    .header-content {
        flex-wrap: wrap;
        height: auto;
        padding: 12px 0;
    }
    
    .header-info {
        order: 3;
        width: 100%;
        justify-content: center;
        margin-top: 8px;
    }
    
    .quick-access {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .overview-cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .quick-access {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .overview-cards {
        grid-template-columns: 1fr;
    }
    
    .content-area {
        padding: 16px;
    }
}