/* ============================================================================
   EM 系统 · 界面改版视觉层（干净版：除了老板点名要的几项，别的都不动）
   老板点名的：①注册企业名放系统名下方、缩小加粗 ②搜索框左移 ③取消左侧菜单栏
              ④鼠标触碰搜索框不弹菜单，输入关键字才出候选 ⑤「全部模块」图标放搜索框左侧、加深
              ⑥标签栏只剩 1 个时不显示（由 em-theme.js 处理）
   之前我把整站底色、卡片阴影、圆角都改了一遍 —— 老板说难看，已全部撤掉，恢复原样。
   ========================================================================== */

/* 顶栏：品牌两行（系统名在上，注册企业名在下）；渐变流动是原系统自带的，没动 */
.em-brand-wrap{display:flex;flex-direction:column;justify-content:center;gap:1px;flex:0 0 auto;min-width:0}
.em-brand-wrap .brand{font-size:15.5px;line-height:1.25}
.em-co-line{font-size:11px;font-weight:700;color:#5b6b86;letter-spacing:.2px;padding-left:18px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

/* 搜索框（只输入才出候选） */
.em-sbox{position:relative;flex:0 1 460px;min-width:220px;display:flex;align-items:center;gap:8px}
.em-search{flex:1;height:38px;display:flex;align-items:center;gap:9px;padding:0 12px;border-radius:10px;background:#fff;
  box-shadow:inset 0 0 0 1px #dbe1ea;color:var(--dim);font-size:13.5px;cursor:text;transition:box-shadow .15s}
.em-sbox.open .em-search{box-shadow:0 0 0 3px rgba(6,182,212,.16),inset 0 0 0 1px var(--accent)}
.em-search .ic{width:16px;height:16px;flex:0 0 auto;color:var(--dim)}
.em-search input{flex:1;border:0;background:transparent;outline:none;font:inherit;font-size:13.5px;color:var(--ink);height:100%}
.em-search input::placeholder{color:#9aa5b1}
.em-search kbd{margin-left:auto;font:11px/1 ui-monospace,monospace;background:#f1f4f9;border-radius:6px;padding:4px 7px;color:var(--dim);white-space:nowrap}

/* 「全部模块」图标：放搜索框左侧、颜色加深；强制居中（原系统给 button 加过内边距，会把图标挤偏） */
.em-allbtn{width:38px;height:38px;flex:0 0 auto;border:0;border-radius:10px;background:#fff;
  box-shadow:inset 0 0 0 1px #dbe1ea;color:#1e293b;cursor:pointer;
  display:flex !important;align-items:center;justify-content:center;
  padding:0 !important;line-height:0;box-sizing:border-box;transition:box-shadow .15s,color .15s}
.em-allbtn:hover{color:var(--accent);box-shadow:inset 0 0 0 1px var(--accent)}
.em-allbtn .ic{width:17px !important;height:17px !important;display:block;margin:0 !important}

/* 候选面板：主菜单并排成多列、子菜单在列内竖排；**不用卡片/渐变色块/阴影，保持干净**
   关闭时 display:none（用 visibility 隐藏的话，这个上千像素宽的绝对定位块会把文档撑出横向滚动条） */
@keyframes emPop{from{opacity:0;transform:translateY(-4px)}to{opacity:1;transform:none}}
.em-panel{position:absolute;top:44px;left:0;width:min(1220px, calc(100vw - 88px));
  max-height:calc(100vh - 64px);overflow:auto;background:#fff;border-radius:12px;padding:10px 12px;
  border:1px solid var(--line);box-shadow:0 10px 24px -12px rgba(16,24,40,.22);
  display:none;grid-template-columns:repeat(auto-fill,minmax(156px,1fr));gap:8px 10px;align-content:start;grid-auto-flow:dense;
  z-index:200}
.em-sbox.open .em-panel{display:grid;animation:emPop .16s ease}
.em-grp{min-width:0}
.em-grp.wide{grid-column:span 2}          /* 条目多的分组横跨两列，整体更矮、不出下滑条 */
.em-grp.wide .em-mgrid{grid-template-columns:1fr 1fr}
.em-grp h4{display:flex;align-items:center;gap:6px;font-size:12.5px;font-weight:700;color:#334155;margin:0 0 4px;
  padding:0 0 4px;border-bottom:1px solid var(--line);white-space:nowrap;overflow:hidden}
.em-grp h4::before{content:'';width:3px;height:10px;border-radius:2px;flex:0 0 auto;background:linear-gradient(180deg,#06b6d4,#6366f1)}
.em-mgrid{display:grid;grid-template-columns:1fr;gap:1px}
.em-mgrid a{display:flex;align-items:center;gap:7px;padding:3px 6px;border-radius:6px;color:var(--ink);font-size:12.5px;
  text-decoration:none;cursor:pointer;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;transition:background .12s,color .12s}
.em-mgrid a:hover{background:#f1f5fb;color:var(--accent2);font-weight:600}
.em-mgrid a i{width:5px;height:5px;border-radius:50%;background:#cbd5e1;flex:0 0 auto;font-style:normal}
.em-mgrid a:hover i{background:var(--accent2)}
.em-none{grid-column:1/-1;font-size:12.5px;color:var(--dim);padding:14px 2px}

/* 取消左侧菜单栏（JS 注入成功后才加 html.em-nosidebar；JS 挂了侧栏还在） */
html.em-nosidebar .sidebar{display:none !important}
html.em-nosidebar .main-col{width:100%}
