/* 顶部导航 */
.header {
    background: #2c3e50;
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.header h1 {
    font-size: 20px;
    font-weight: normal;
}

.header .nav-links {
    display: flex;
    gap: 20px;
}

.header .nav-links a {
    color: white;
    text-decoration: none;
    font-size: 14px;
}

.header .nav-links a:hover {
    color: #1abc9c;
}

/* 页脚 */
.footer {
    background: #2c3e50;
    color: white;
    padding: 40px 20px 30px;
    text-align: center;
    position: relative;
    z-index: 1;
    clear: both;
}

.footer p {
    font-size: 14px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
}

.footer-logo {
    width: 48px;
    height: 48px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.footer-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.footer-brand h3 {
    color: white;
    font-size: 18px;
    margin: 0;
}

.footer-copyright {
    margin: 0;
    color: rgba(255,255,255,0.8);
}

.footer-desc {
    margin: 10px 0 0;
    color: rgba(255,255,255,0.6);
    font-size: 12px;
}

/* 管理后台布局 */
.container {
    display: flex;
    flex: 1;
    width: 100%;
    max-width: none;
    margin: 0;
    overflow: hidden;
}

/* 侧边栏 */
.sidebar {
    width: 220px;
    background: #34495e;
    padding: 20px 0;
    flex-shrink: 0;
    border-right: 1px solid #e0e0e0;
    overflow-y: auto;
}

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

.sidebar-menu li {
    margin-bottom: 5px;
}

.sidebar-menu a {
    display: block;
    padding: 12px 20px;
    color: white;
    text-decoration: none;
    transition: background 0.3s;
}

.sidebar-menu a:hover, .sidebar-menu a.active {
    background: #1abc9c;
    color: white;
}

/* 主内容区 */
.main-content {
    flex: 1;
    padding: 30px;
    overflow-y: auto;
    width: 100%;
    background: #f5f7fa;
}

/* 管理中心风格样式 */
.admin-container {
    display: flex;
    min-height: 100vh;
    background: #f5f7fa;
}

/* 侧边导航 */
.admin-sidebar {
    width: 240px;
    background: #2c3e50;
    color: white;
    padding: 20px 0;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.admin-sidebar .logo {
    padding: 0 20px 30px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 20px;
}

.admin-sidebar .logo h2 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.admin-sidebar .logo .logo-icon {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.admin-sidebar .logo .logo-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.admin-sidebar .nav-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.admin-sidebar .nav-menu li {
    margin-bottom: 5px;
}

.admin-sidebar .nav-menu a {
    display: block;
    padding: 12px 20px;
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.admin-sidebar .nav-menu a:hover {
    background: rgba(255,255,255,0.1);
    color: white;
}

.admin-sidebar .nav-menu a.active {
    background: rgba(26, 188, 156, 0.2);
    color: #1abc9c;
    border-left-color: #1abc9c;
}

.admin-sidebar .nav-menu a i {
    margin-right: 10px;
    font-size: 16px;
}

/* 主内容区 */
.admin-main {
    flex: 1;
    margin-left: 240px;
    padding: 20px;
}

/* 防止页面被撑开的全局样式 */
.admin-main {
    overflow-x: hidden;
    box-sizing: border-box;
}

/* 顶部导航栏 */
.admin-header {
    background: white;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-header h1 {
    margin: 0;
    font-size: 20px;
    color: #2c3e50;
}

.admin-header .user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.admin-header .user-info span {
    color: #555;
    font-size: 14px;
}

.admin-header .user-info a {
    color: #1abc9c;
    text-decoration: none;
    font-size: 14px;
}

/* 移动端菜单按钮 */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 28px;
    height: 22px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
}

.mobile-menu-btn span {
    display: block;
    width: 100%;
    height: 3px;
    background: #2c3e50;
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* 登录页头部样式 */
.header-login {
    padding: 10px 20px;
    flex-wrap: nowrap !important;
}

.header-login .nav-links {
    display: flex !important;
    align-items: center;
    gap: 15px;
    flex-wrap: nowrap !important;
    white-space: nowrap !important;
    flex-shrink: 0;
    min-width: max-content;
    margin-left: auto;
}

.header-login .header-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 2;
    white-space: nowrap;
    flex-basis: 0;
}

.header-login .header-brand h1 {
    margin: 0;
    font-size: 16px;
}

.header-login .nav-links {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: nowrap;
}

.header-login .nav-links a {
    display: inline-flex;
    align-items: center;
    padding: 5px 10px;
}

.header-login .nav-links span {
    display: flex;
    align-items: center;
}

.header-login .nav-links #user-info.hidden {
    display: none;
}

.header-login .nav-links #user-info.visible {
    display: inline-flex !important;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
}

.header-login .nav-links #user-info.visible.hidden {
    display: none;
}

.header-login .nav-links #user-info.visible #username-display {
    display: inline !important;
    white-space: nowrap;
    margin-right: 10px;
}

.header-login .nav-links #user-info.visible a {
    display: inline !important;
    white-space: nowrap;
}

.header-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-logo {
    width: 48px;
    height: 48px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.header-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.header-brand h1 {
    margin: 0;
    font-size: 20px;
}

.member-link {
    display: none;
}

.user-info-text {
    margin-right: 15px;
}
