/* X-admin 2.x 布局样式（适配 AI精准获客系统） */
* { margin: 0; padding: 0; }
body { font-family: "Microsoft YaHei", Arial, sans-serif; font-size: 14px; color: #333; background: #f2f2f2; overflow: hidden; }

.container { width: 100%; height: 45px; background: #23262e; position: fixed; top: 0; left: 0; z-index: 1000; }
.aijzh-header {
    display: flex;
    align-items: center;
    overflow: visible;
}
.container .logo {
    float: none;
    flex-shrink: 0;
    width: 220px;
    line-height: 45px;
    text-align: center;
    background: #20222a;
}
.container .logo a { color: #fff; font-size: 16px; font-weight: 600; text-decoration: none; }
.container .logo a:hover { color: #fff; }
.container .left_open {
    float: none;
    flex-shrink: 0;
    height: 45px;
    line-height: 45px;
}
.container .left_open a { display: block; width: 45px; text-align: center; color: #fff; cursor: pointer; }
.container .left_open a:hover { background: rgba(255,255,255,0.05); }

/* 顶栏右侧导航 */
.container .layui-nav.aijzh-top-nav {
    flex: 1;
    display: flex !important;
    flex-direction: row;
    justify-content: flex-end;
    align-items: center;
    float: none !important;
    position: static !important;
    right: auto !important;
    left: auto !important;
    top: auto !important;
    width: auto !important;
    height: 45px;
    margin: 0;
    padding: 0 16px 0 0;
    background: none !important;
    white-space: nowrap;
}
.container .aijzh-top-nav .layui-nav-item {
    float: none !important;
    line-height: 45px;
    position: relative;
    flex-shrink: 0;
}
.container .aijzh-top-nav .layui-nav-item a {
    color: rgba(255,255,255,0.88);
}
.container .aijzh-top-nav .layui-nav-item a:hover {
    color: #fff;
}
.container .aijzh-top-nav .layui-this:after,
.container .aijzh-top-nav .layui-nav-bar {
    display: none !important;
}

/* 顶栏右侧操作区 */
.aijzh-top-nav .aijzh-nav-icon-btn {
    display: block;
    padding: 0 14px !important;
    height: 45px;
    line-height: 45px;
}
.aijzh-top-nav .aijzh-nav-icon-btn .layui-icon {
    font-size: 18px;
    transition: transform 0.35s ease;
}
.aijzh-top-nav .aijzh-nav-icon-btn:hover .layui-icon {
    transform: rotate(180deg);
}
.aijzh-top-nav .aijzh-nav-user > a {
    display: block;
    padding: 6px 12px 6px 8px !important;
    height: 45px;
    line-height: normal;
    box-sizing: border-box;
    overflow: hidden;
}
.aijzh-top-nav .aijzh-nav-user-inner {
    display: flex;
    align-items: center;
    height: 45px;
}
.aijzh-top-nav .aijzh-nav-user-home {
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 0;
    height: 45px;
    padding: 6px 4px 6px 8px !important;
    box-sizing: border-box;
    text-decoration: none;
    color: rgba(255,255,255,0.88);
}
.aijzh-top-nav .aijzh-nav-user-home:hover {
    background: rgba(255,255,255,0.06);
    color: #fff;
}
.aijzh-top-nav .aijzh-nav-user-toggle {
    flex-shrink: 0;
    width: 28px;
    height: 45px;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    color: rgba(255,255,255,0.7);
    cursor: pointer;
}
.aijzh-top-nav .aijzh-nav-user-toggle:hover,
.aijzh-top-nav .aijzh-nav-user.is-open .aijzh-nav-user-toggle {
    color: #fff;
    background: rgba(255,255,255,0.06);
}
.aijzh-top-nav .aijzh-nav-user-toggle .layui-icon {
    font-size: 12px;
}
.aijzh-top-nav .aijzh-nav-user > a:hover {
    background: rgba(255,255,255,0.06);
}
.aijzh-top-nav .aijzh-nav-avatar {
    float: left;
    width: 32px;
    height: 32px;
    margin-top: 1px;
    border-radius: 50%;
    background: rgba(255,255,255,0.12);
    display: flex;
    align-items: center;
    justify-content: center;
}
.aijzh-top-nav .aijzh-nav-avatar .layui-icon {
    font-size: 16px;
    color: #fff;
}
.aijzh-top-nav .aijzh-nav-info {
    float: left;
    margin-left: 10px;
    max-width: 140px;
    padding-top: 2px;
}
.aijzh-top-nav .aijzh-nav-name {
    display: block;
    line-height: 18px;
    font-size: 13px;
    color: #fff;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.aijzh-top-nav .aijzh-nav-role {
    display: block;
    line-height: 16px;
    font-size: 11px;
    color: rgba(255,255,255,0.55);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.aijzh-top-nav .aijzh-nav-user > a:after {
    display: none;
}
.aijzh-top-nav .aijzh-nav-user .layui-nav-child {
    display: none;
}
.aijzh-top-nav .aijzh-nav-user.is-open .layui-nav-child {
    display: block;
}
.aijzh-top-nav .layui-nav-child {
    top: 46px;
    right: 0;
    left: auto;
    min-width: 190px;
    border: none;
    border-radius: 4px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
    padding: 4px 0;
    z-index: 1001;
}
.aijzh-top-nav .layui-nav-child dd a {
    color: #333 !important;
    padding: 0 16px;
    line-height: 40px;
    height: 40px;
}
.aijzh-top-nav .layui-nav-child dd a:hover {
    background: #f6f6f6;
    color: #009688 !important;
}
.aijzh-top-nav .layui-nav-child dd a .layui-icon {
    margin-right: 8px;
    font-size: 15px;
}
.aijzh-top-nav .layui-nav-child .aijzh-nav-child-head {
    padding: 12px 16px 10px;
    line-height: 1.5;
    cursor: default;
    border-bottom: 1px solid #f0f0f0;
    margin-bottom: 4px;
}
.aijzh-top-nav .layui-nav-child .aijzh-nav-child-head:hover {
    background: #fff !important;
}
.aijzh-top-nav .aijzh-nav-child-name {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.aijzh-top-nav .aijzh-nav-child-role {
    font-size: 12px;
    color: #999;
    margin-top: 2px;
}
.aijzh-top-nav .layui-nav-line {
    height: 1px;
    margin: 4px 0;
    padding: 0 !important;
    background: #f0f0f0;
    pointer-events: none;
}

.left-nav { position: fixed; top: 45px; left: 0; width: 220px; height: calc(100% - 45px); background: #393d49; z-index: 999; overflow: auto; transition: width 0.1s; }
.left-nav #side-nav { padding: 0; }
.left-nav #nav { background: none; width: 100%; }
.left-nav #nav .layui-nav-item { line-height: 45px; }
.left-nav #nav .layui-nav-item a { height: 45px; line-height: 45px; color: rgba(255,255,255,0.7); padding: 0 20px; }
.left-nav #nav .layui-nav-item a:hover { color: #fff; }
.left-nav #nav .layui-nav-item a.active,
.left-nav #nav .layui-this > a { background: #009688 !important; color: #fff !important; }
.left-nav #nav .layui-nav-item a i { margin-right: 8px; font-size: 16px; }
.left-nav #nav .layui-nav-item a cite { font-style: normal; font-size: 14px; }
.left-nav #nav .layui-nav-bar { display: none; }

.page-content { position: fixed; top: 45px; left: 220px; right: 0; bottom: 0; overflow: auto; background: #f2f2f2; transition: left 0.1s; padding: 15px; box-sizing: border-box; }
.page-content-bg { display: none; position: fixed; top: 45px; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.3); z-index: 998; }

/* 登录页 */
.aijzh-login-wrap-xadmin { min-height: 100vh; background: #393d49; display: flex; align-items: center; justify-content: center; }
.aijzh-login-box-xadmin { width: 420px; background: #fff; border-radius: 4px; box-shadow: 0 2px 12px rgba(0,0,0,0.15); overflow: hidden; }
.aijzh-login-title-xadmin { background: #009688; color: #fff; text-align: center; padding: 25px 0; font-size: 20px; font-weight: 600; }
.aijzh-login-form-xadmin { padding: 30px 35px 20px; }
.aijzh-login-footer-xadmin { text-align: center; padding: 0 0 25px; color: #999; font-size: 12px; }

@media screen and (max-width: 768px) {
    .left-nav { width: 0; overflow: hidden; }
    .page-content { left: 0; }
    .aijzh-top-nav .aijzh-nav-info { display: none; }
    .aijzh-top-nav .aijzh-nav-user-home { padding: 6px 4px 6px 8px !important; }
    .aijzh-top-nav .aijzh-nav-user-toggle { width: 24px; }
}

/* 获客系统内嵌层：全宽覆盖，隐藏管理后台左侧导航；关闭后回到当前管理页 */
.aijzh-crm-frame-wrap {
    position: fixed;
    top: 45px;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1100;
    background: #fff;
    display: none;
}
body.aijzh-crm-frame-open {
    overflow: hidden;
}
body.aijzh-crm-frame-open .left-nav {
    display: none !important;
}
.aijzh-crm-frame-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
    height: 48px;
    padding: 0 16px;
    background: #23262e;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    box-sizing: border-box;
}
.aijzh-crm-frame-toolbar .layui-btn-primary {
    background: rgba(255,255,255,0.1);
    border-color: rgba(255,255,255,0.2);
    color: #fff;
}
.aijzh-crm-frame-toolbar .layui-btn-primary:hover {
    background: rgba(255,255,255,0.18);
    color: #fff;
}
.aijzh-crm-frame-title {
    color: rgba(255,255,255,0.75);
    font-size: 14px;
}
.aijzh-crm-frame {
    display: block;
    width: 100%;
    height: calc(100% - 48px);
    border: 0;
    background: #fff;
}
