/**
 * 布局组件样式
 */

@import url("./app-header-xp.css");

/* 主布局容器 */
.app-layout {
    display: flex;
    min-height: 100vh;
}

/* ========== 主题切换按钮 ========== */
.app-theme-switcher {
    position: fixed;
    right: 20px;
    top: 54px;
    width: 40px;
    height: 40px;
    background-color: var(--el-fill-color-extra-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 12px var(--el-box-shadow-lighter);
    z-index: 2000;
    transition: all 0.3s ease;
}

.app-theme-switcher:hover {
    box-shadow: 0 4px 16px var(--el-box-shadow-dark);
    transform: scale(1.05);
}

/* ========== 侧边栏样式 ========== */
.app-sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    background-color: var(--el-bg-color-sidebar);
    box-shadow: 4px 0 12px rgba(0, 0, 0, 0.08);
    transition: width 0.3s ease;
    z-index: 1000;
    overflow: hidden;
}

/* 夜间模式下侧边栏阴影更深 */
.dark-mode .app-sidebar {
    box-shadow: 4px 0 12px rgba(0, 0, 0, 0.3);
}

/* 侧边栏头部 */
.app-sidebar-header {
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 20px;
}

/* 收起/展开按钮 */
.app-collapse-btn {
    font-size: 20px;
    color: var(--el-text-color-regular);
    cursor: pointer;
    transition: transform 0.3s ease;
}

.app-collapse-btn:hover {
    transform: scale(1.1);
}

/* 侧边栏内容区域 */
.app-sidebar-content {
    padding: 20px 0;
    overflow-y: auto;
    height: calc(100vh - 60px);
}

/* ========== 菜单标题样式 ========== */
.app-menu-title {
    padding: 0 20px 15px;
    font-size: 18px;
    font-weight: 600;
    color: var(--el-text-color-primary);
    border-bottom: 1px solid var(--el-border-color-lighter);
    margin-bottom: 10px;
}

/* ========== 导航菜单列表样式 ========== */
.app-menu-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

/* 导航菜单项 */
.app-menu-item {
    cursor: pointer;
    display: flex;
    align-items: center;
    padding: 12px 20px;
    cursor: pointer;
    color: var(--el-text-color-regular);
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* 导航菜单项悬停高亮 */
.app-menu-item:hover {
    background-color: var(--el-bg-color-hover);
    color: var(--el-text-color-primary);
}

/* 菜单图标 */
.app-menu-icon {
    font-size: 18px;
    margin-right: 12px;
    width: 18px;
    text-align: center;
}

/* 菜单文本 */
.app-menu-text {
    font-size: 16px;
    color: var(--el-text-color-primary);
}

/* ========== 注册或登录部分样式 ========== */
.app-auth-section {
    padding: 20px;
    border-top: 1px solid var(--el-border-color-lighter);
    margin-top: 60px;
}

/* 图标和标题头部 - 水平排列垂直居中 */
.app-auth-header {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
}

.app-auth-icon {
    width: 28px;
    height: 28px;
    margin-right: 8px;
}

.app-auth-title {
    font-size: 16px;
    font-weight: 500;
    color: var(--el-text-color-primary);
}

/* 描述说明文字 */
.app-auth-desc {
    font-size: 13px;
    color: var(--el-text-color-secondary);
    line-height: 1.5;
    text-align: center;
    margin-bottom: 16px;
    padding: 0 10px;
}

/* 按钮容器 */
.app-auth-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* 注册按钮 - 白字蓝底 */
.app-auth-register-btn {
    width: 100%;
    padding: 10px 20px;
    background-color: #409eff;
    color: var(--el-fill-color-blank);
    border: none;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.app-auth-register-btn:hover {
    background-color: #66b1ff;
}

/* 登录按钮 - 蓝色边框，白底，蓝字 */
.app-auth-login-btn {
    width: 100%;
    padding: 10px 20px;
    background-color: var(--el-fill-color-blank);
    color: #409eff;
    border: 1px solid #409eff;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.app-auth-login-btn:hover {
    background-color: var(--el-fill-color-extra-light);
}

/* ========== 内容区域样式 ========== */
.app-main-content {
    margin-left: 260px;
    flex: 1;
    transition: margin-left 0.3s ease;
    min-height: 100vh;
    background-color: var(--el-bg-color-page);
}

/* 侧边栏收起时的内容区域 */
.app-main-content.app-content-expanded {
    margin-left: 64px;
}

/* 侧边栏完全隐藏时的内容区域 */
.app-main-content.app-content-full {
    margin-left: 0;
}

/* ========== 公共头部样式 ========== */
.app-header {
    position: sticky;
    top: 0;
    box-shadow: 0 1px 4px var(--el-border-color-lighter);
    z-index: 999;
}
.app-header-notice{
    background: linear-gradient(135deg, #409eff, #67c23a);
    border-bottom: 2px solid #e6f7ff;
    box-sizing: border-box;
}

/* 夜间模式下的通知栏背景 */
.dark-mode .app-header-notice {
    background: linear-gradient(135deg, #2c3e50, #34495e);
    border-bottom: 2px solid #4a5568;
}
.app-header-notice-content{
    width: 80%;
    margin: 0 auto;
    box-sizing: border-box;
}
.app-header-notice-item{
    padding: 0;
    display: flex;
    align-items: center;
    height: 50px;
}
.app-header-notice-item-title{
    
    flex: auto;
    color: #fff;
    color: #fff;
    flex: 1;
    font-size: 14px;
    font-weight: 500;
    margin-right: 20px;
}
.app-header-notice-item-btn{
    flex: none;
    background: #fff3;
    border: 1px solid hsla(0, 0%, 100%, .3);
    border-radius: 20px;
    color: #fff;
    font-size: 16px;
    padding: 6px 16px;
    cursor: pointer;
}
.app-header-nav{
    height: 60px;
    background-color: var(--el-fill-color-blank);
}

/* 头部内容容器 - 居中显示 */
.app-header .app-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    /* max-width: 1400px; */
    margin: 0 auto;
    overflow: hidden;
}

/* ========== 头部左侧样式 ========== */
.app-header-left {
    display: flex;
    align-items: center;
    flex: none;
}

/* Logo */
.app-logo {
    margin-right: 15px;
    width: 62px;
    height: 55px;
    background-image: url(../../images/common/logo_black.png);
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

/* 导航栏 */
.app-header-nav {
    display: flex;
    margin: 0;
    padding: 0;
}

.app-header-nav .app-nav-item {
    height: 60px;
    line-height: 60px;
    font-size: 18px;
    font-weight: 700;
    color: var(--el-text-color-primary);
    cursor: pointer;
    padding: 0 20px;
    position: relative;
    transition: color 0.3s ease;
    text-decoration: none;
}

.app-header-nav .app-nav-item:hover {
    color: #409eff;
}

/* 选中状态：蓝色文字 + 底部蓝色边框 */
.app-nav-item.app-nav-active {
    color: #409eff;
}

.app-nav-item.app-nav-active::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background-color: #409eff;
}

/* ========== 头部右侧样式 ========== */
.app-header-right {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: none;
}

/* 网站信息 */
.app-site-info {
    height: 60px;
    line-height: 60px;
    font-size: 18px;
    font-weight: 700;
    color: var(--el-text-color-primary);
    padding: 0 20px;
    cursor: pointer;
    text-decoration: none;
}

/* 顶栏「今日任务」入口（与网站信息同列显隐） */
.app-header-right .app-daily-task-entry.app-site-info-slot {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 60px;
    line-height: 60px;
    font-size: 18px;
    font-weight: 700;
    color: var(--el-text-color-primary);
    padding: 0 20px;
    text-decoration: none;
}

.app-header-right .app-daily-task-entry.app-site-info-slot:hover {
    color: #409eff;
}

.app-header-nav .app-daily-task-entry {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 700;
    color: var(--el-text-color-primary);
    text-decoration: none;
}

.app-nav-hot {
    display: inline-block;
    font-size: 10px;
    line-height: 1;
    padding: 2px 5px;
    border-radius: 2px;
    background: #f56c6c;
    color: #fff;
    font-weight: 700;
    letter-spacing: 0.02em;
}

/* 语言选择器 */
.app-language-selector {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 14px;
    color: var(--el-text-color-regular);
}

.app-language-icon {
    font-size: 18px;
    margin-right: 5px;
}

.app-language-text {
    margin-right: 4px;
    font-weight: 700;
}

/* 用户选择器 */
.app-user-selector {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 14px;
    color: var(--el-text-color-regular);
}

.app-user-profile-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

.app-user-dropdown-trigger {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
}

.app-user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 8px;
}

.app-user-nickname {
    margin-right: 4px;
    font-weight: 700;
    font-size: 16px;
}

/* 下拉菜单项文本 */
.app-dropdown-item-text {
    margin-right: 8px;
}

/* 消息角标 */
.app-message-badge {
    margin-left: auto;
}


/* ========== 页面内容区域样式 ========== */
.app-page-content {
    margin: 0;
    padding: 0;
}

/* ========== 登录后的用户内容样式 ========== */
.app-user-section {
    padding: 0 20px;
    margin-top: 20px;
}

/* 用户菜单项 */
.app-user-menu {
    margin-bottom: 10px;
}

/* 用户菜单头部 */
.app-user-menu-header {
    display: flex;
    align-items: center;
    padding: 12px 10px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    border-radius: 6px;
}

.app-user-menu-header:hover {
    background-color: var(--el-bg-color-hover);
}

.app-user-menu-header > i:first-child {
    font-size: 18px;
    margin-right: 12px;
    color: var(--el-text-color-regular);
}

.app-user-menu-header > span {
    flex: 1;
    font-size: 16px;
    color: var(--el-text-color-primary);
}

/* 箭头图标 */
.arrow-icon {
    font-size: 14px;
    color: var(--el-text-color-secondary);
    transition: transform 0.3s ease;
}

.arrow-icon-small {
    font-size: 12px;
    color: var(--el-text-color-secondary);
    margin-left: auto;
}

/* 漫画列表 */
.app-manga-list {
    padding-left: 30px;
    margin-top: 8px;
}

/* 漫画列表项 */
.app-manga-item {
    padding: 8px 10px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    border-radius: 6px;
    margin-bottom: 5px;
}

.app-manga-item:hover {
    background-color: var(--el-bg-color-hover);
}

/* 漫画名称 */
.app-manga-name {
    font-size: 14px;
    color: var(--el-text-color-regular);
    line-height: 1.4;
}

/* 历史时间段容器 */
.app-history-periods {
    padding-left: 10px;
}

/* 历史时间段项 */
.app-history-period {
    display: flex;
    align-items: center;
    padding: 10px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    border-radius: 6px;
    margin-bottom: 5px;
}

.app-history-period:hover {
    background-color: var(--el-bg-color-hover);
}

.app-history-period > span {
    font-size: 14px;
    color: var(--el-text-color-regular);
}

.app-history-period.active > span {
    color: #409eff;
    font-weight: 500;
}

/* ========== 头部面包屑样式 ========== */
.app-header-breadcrumb {
    display: flex;
    align-items: center;
    margin-left: 20px;
}

.app-breadcrumb-item {
    display: flex;
    align-items: center;
    font-size: 16px;
    color: var(--el-text-color-regular);
    text-decoration: none;
    transition: color 0.3s ease;
}

.app-breadcrumb-item:hover {
    color: #409eff;
}

.app-breadcrumb-item i {
    margin-right: 4px;
}

.breadcrumb-separator {
    margin: 0 8px;
    color: var(--el-text-color-secondary);
}

.app-theme-switcher .el-switch__core{
    border-color: var(--el-border-color)!important;
}

.app-theme-switcher .el-switch.is-checked .el-switch__core{
    border-color: var(--el-fill-color-blank)!important;
}

.app-theme-switcher .el-switch__core:after{
    background-image: url(../../images/common/icon_light.png);
    background-size: 100% 100%;
    background-repeat: no-repeat;
}

.app-theme-switcher .el-switch.is-checked .el-switch__core::after{
     background-image: url(../../images/common/icon_night.png);
    background-size: 100% 100%;
    background-repeat: no-repeat;
}

/* ========== 响应式媒体查询 ========== */

/* 屏幕宽度小于 1850px */
@media screen and (max-width: 1849px) {
    .app-content {
        width: 92%;
    }

    .app-header-notice-content {
        width: 92%;
    }

    .app-header-nav .app-nav-item {
        font-size: 14px;
    }

    .app-header-right .app-daily-task-entry.app-site-info-slot {
        font-size: 14px;
    }

    .app-header-right .app-site-info {
        font-size: 14px;
    }
}

/* 侧边栏展开时，在 lg 断点范围（1200px-1600px）强制 manga-list 每行显示 6 个元素 */
@media screen and (min-width: 1200px) and (max-width: 1600px) {
    .app-main-content:not(.app-content-expanded) .manga-list .el-row {
        display: flex;
        flex-wrap: wrap;
        margin-right: 0 !important;
        margin-left: 0 !important;
    }

    .app-main-content:not(.app-content-expanded) .manga-list .el-col {
        flex: 0 0 16.6666%;
        max-width: 16.6666%;
        padding: 0 4px;
        box-sizing: border-box;
    }
}

/* 屏幕宽度小于 897px */
@media screen and (max-width: 896px) {
    .app-sidebar {
        display: none;
    }

    .app-main-content {
        margin-left: 0 !important;
    }
}

/* 屏幕宽度小于 880px */
@media screen and (max-width: 879px) {

    .app-content {
        width: 90%;
    }

    .app-header-nav .app-nav-item {
        font-size: 14px;
        padding: 0 15px;
    }

    .app-header-nav .app-site-info {
        font-size: 14px;
        padding: 0 15px;
    }

    .app-header-nav .app-language-selector {
        font-size: 12px;
    }

    .app-header-nav .app-user-selector {
        font-size: 12px;
    }

    .app-header-nav .app-user-nickname {
        font-size: 13px;
    }
}

/* 屏幕宽度小于 375px */
@media screen and (max-width: 374px) {
    .app-header-nav .app-content {
        font-size: 12px;
    }

    .app-header-nav .app-nav-item {
        font-size: 12px;
        padding: 0 10px;
    }

    .app-header-nav .app-site-info {
        font-size: 12px;
        padding: 0 10px;
    }

    .app-header-nav .app-language-selector {
        font-size: 11px;
    }

    .app-header-nav .app-user-selector {
        font-size: 11px;
    }

    .app-header-nav .app-user-nickname {
        font-size: 12px;
    }
}

.user-avatar-box{
    position: relative;
    cursor: pointer;
     width: 100px;
    height: 100px;
}

.app-gender-icon{
    position: absolute;
    bottom: 1px;
    right: 8px;

    align-items: center;
    background-color: var(--el-bg-color);
    border-radius: 50%;
    display: flex;
    height: 22px;
    justify-content: center;
    width: 22px;
    color: var(--el-text-color-primary);
    font-size: 14px;
    box-shadow: var(--el-box-shadow-light);
}

/* ========== 越南语/英语模式下的样式调整 ========== */

/* 导航项字体大小调整为14px */
.app-header-nav-small-font .app-nav-item {
    padding: 0 10px !important;
}

/* 右侧区域gap调整为10px */
.app-header-right-small-font {
    gap: 10px !important;
}

/* 右侧"今日任务"入口字体和内边距调整 */
.app-header-right-small-font .app-daily-task-entry.app-site-info-slot {
    padding: 0 10px !important;
}

.app-header-right-small-font .app-site-info{
    padding: 0 10px !important;
}