html,
body {
  width: 100%;
  display: flex;
  flex-direction: column;
  padding: 0px;
  height: 100%;
  margin: 0px;
  color: white;
  background-color: rgb(75, 75, 79);
  font-family: "微软雅黑";
}

.页眉1 {
  background-color: #000034;
  font-family: "微软雅黑";
  font-size: 18px;
  color: white;
  position: sticky;
  top: 0;
}

a {
  text-decoration: none;
}

a:link {
  color: #ffffff;
  font-style: normal;
}

a:visited {
  color: #ffffff;
}

a:hover {
  color: #FF00FF;
}

/* index页面为上下结构，这个是底部-目录树+内容区的盒子 */
.body-container {
  display: flex;
  flex-direction: row;
  overflow: hidden;
  width: 100%;
  position: relative;
  height: calc(100vh - 60px);
  /* 减去header高度 */
}

/* 顶部盒子-包括logo、子目录、前进后退按钮以及搜索栏 */
.header-container {
  display: flex;
  align-items: center;
  padding: 12px 20px;
  border-bottom: 1px solid #ddd;
}

/* 顶部盒子的中间盒子-存放子目录 */
.header-center {
  flex: 1;
  font-size: 1.5em;
}

/* 顶部盒子的右边-存放logo */
.header-right {
  display: flex;
  justify-content: space-around;
}

/* logo盒子 */
.logo {
  width: 250px;
  margin-right: 20px;
}

.submenu-item {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 前进后退导航 */
.navigation {
  cursor: pointer;
  display: flex;
  align-items: center;
}

/* 箭头图标 */
.navigation a img {
  height: 30px;
}

/* 搜索框盒子-包括input框和搜索按钮 */
.search-box {
  padding: 8px;
  border-radius: 4px;
  display: flex;
  align-items: center;
}

form {
  margin: 0;
  padding: 0;
  display: flex;
}
/* app端专用搜索盒子  web端隐藏 */
.app-search{
  display: block;
  height: 0px;
  overflow: hidden;
  padding: 0;
  background-color: #000034;
  transition: height 0.3s ease-in-out;
}
.app-search-btn{
  display: none;
}
/* 目录树盒子 */
.menu-tree-container {
  position: relative;
  width: 280px;
  height: 100%;
  overflow: hidden;
  background-color: rgb(55, 55, 81);
  transition: width 0.3s ease-in-out;
}

/* 目录树隐藏时的样式 */
.menu-close {
  width: 0px;
}

/* 控制目录树显示和隐藏的按钮 */
.toggle-btn {
  position: absolute;
  left: 240px;
  top: 15px;
  z-index: 1000;
  transition: all 0.3s ease-in-out;
  cursor: pointer;
}

/* 按钮图标 */
.toggle-btn img {
  width: 20px;
}

/* 目录树内层盒子 */
.dtree-container {
  height: 97%;
  /* width:  92%; */
  margin: 10px;
  box-sizing: border-box;
  background-color: rgb(55, 55, 81);
  color: white;
  overflow: auto;
  scroll-behavior: smooth;
  scrollbar-color: transparent;
  padding-bottom: 6px;
  scrollbar-width: 4px;
}

.dtree-container::-webkit-scrollbar {
  width: 5px;
  height: 5px;
}

.dtree-container::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 5px;
}

/* iframe容器盒子 */
.iframe-container {
  flex: 1;
}

/* iframe内容 */
.content-iframe {
  width: 100%;
  height: 100%;
  border: none;
  /* min-width: 900px; */
}
/* 新增拖拽相关样式 */
.drag-handle {
  position: absolute;
  right: -2px;
  top: 0;
  bottom: 0;
  width: 4px;
  cursor: col-resize;
  z-index: 100;
  background-color: rgba(0,0,0,0.1);
  transition: background-color 0.2s;
}

.drag-handle:hover,
.dragging .drag-handle {
  background-color: #2c7dfa;
}

/* 禁用文本选择 */
body.dragging {
  user-select: none;
}
.mask {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 999;
  display: none;
}

.mask + .iframe-container {
  pointer-events: none;
}
/* 平板适配 */
@media (min-width: 769px) and (max-width: 1024px) {
  .header-container{
    padding: 6px 10px;
  }
  .menu-tree-container {
  width: 160px;
  transition: width 0.3s ease-in-out;
  }

  .submenu-item {
      font-size: 16px;
  }
  .header-center{
    font-size: 1em;
    max-width: 36%;
  }
  /* logo盒子 */
  .logo {
    width: 160px;
    margin-right: 10px;
  }
  .toggle-btn {
    left: 120px;
  }
  .submenu-box{
    word-break: break-all;
  }
  .drag-handle {
    display: none; /* 移动端隐藏拖拽功能 */
  }
}
/* 目录树隐藏时的样式 */
.menu-close {
  width: 0px !important;
}

/* 目录树隐藏时按钮的定位 */
.btn-close {
  left: 10px !important;
}
/* 移动端适配 */
/* 移动端适配 隐藏搜索框以及子路径、前进后退按钮*/
@media (max-width: 768px) {
  .header-container {
      padding: 10px;
  }

  .logo {
      width: 140px;
      /* margin-bottom: 10px; */
  }
  .submenu-box{
    display: none;
  }
  .search-box {
    height: 0;
  }
  .header-right{
    display: none;
  }
  .body-container {
      flex-direction: column;
      height: calc(100vh - 110px); /* 调整header高度 */
  }
  .menu-tree-container{
      position: fixed;
      top: 56px;
      height:calc(100% - 55px);
      width: 0;
  }
  .menu-tree-container.active {
      transform: translateX(0);
  }
  .menu-close {
      position: fixed;
      top: 56px;
      left: 0;
      bottom: 0;
      width: 70% !important;
      height:calc(100% - 55px);
      transform: translateX(-100%);
      z-index: 999;
      box-shadow: 2px 0 8px rgba(0,0,0,0.15);
  }

  .iframe-container {
      width: 100% !important;
      height: calc(100vh - 110px);
  }
  .toggle-btn {
    position: absolute;
    left:10px;
    top: 5px;
  }
  /* 此处语义不适配  因为移动端和web段初始状态不一样 */
  .btn-close{
    left:63% !important;
    background-color: rgb(75, 75, 79);
  }
  .app-search-btn{
    display: block;
    width: 20px;
    height: 20px;
  }
  .app-search-btn img{
    width: 100%;
  }
  .app-search-open{
    height: 36px;
    overflow: hidden;
    border-bottom-right-radius: 4px;
    border-bottom-left-radius: 4px;
  }
  .app-form{
    padding:5px;
    padding-bottom: 10px;
  }
  .header-container{
    border-bottom: none;
  }
  .drag-handle {
    display: none; /* 移动端隐藏拖拽功能 */
  }
}

