/* 首页全站搜索：仅保留 index.html 中实际用到的规则（结构类名与 #search-main） */

.search-main {
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  overflow-x: hidden;
  overflow-y: scroll;
  -webkit-text-size-adjust: 100%;
  -ms-text-size-adjust: 100%;
}

.search-main *,
.search-main :after,
.search-main :before {
  -webkit-box-sizing: inherit;
  -moz-box-sizing: inherit;
  box-sizing: inherit;
  -webkit-tap-highlight-color: transparent;
}

:root {
  --be-grey-7: #777;
  --be-blue: #4d8cb8;
  --be-bg-blue-d: #ddd;
  --be-grey-9: #999;
  --be-bg-glass-s: rgba(239, 240, 242, 0.8);
  --be-bg-white: #fff;
  --be-main-width: 1200px;
  --be-bg-grey-f1: #eff0f2;
  --be-grey-6: #666;
  --be-shadow-h: #cc3333;
  --be-white: #fff;
}

button,
input {
  font: 14px "Microsoft YaHei", Helvetica, Arial, Lucida Grande, Tahoma, sans-serif;
}

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

.nav-search {
  position: relative;
  font-size: 1.6rem;
  float: right;
  color: var(--be-grey-7);
  line-height: 26px;
  margin: 0 5px 0 10px;
  padding: 0 8px 3px;
  cursor: pointer;
  z-index: 5;
}

.nav-search:hover {
  color: var(--be-blue);
}

.off-search {
  position: absolute;
  top: 30px;
  left: 50%;
  width: 35px;
  height: 35px;
  cursor: pointer;
  margin: 0 0 0 -17px;
  border-radius: 50%;
  background: var(--be-bg-blue-d);
}

.off-search:after {
  position: absolute;
  top: 56%;
  left: 49%;
  content: "\e6f5";
  font-family: be;
  font-size: 14px !important;
  color: var(--be-white);
  margin: -12px 0 0 -7px;
}

.nav-search:after {
  content: "\e614";
  font-family: be;
  font-size: 16px !important;
  color: var(--be-grey-7);
}

.nav-search:hover:after {
  color: var(--be-blue);
}

@media only screen and (max-width: 1025px) {
  .nav-search:after {
    color: var(--be-grey-9);
  }
}

#search-main {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  margin: 0 auto;
  height: 100%;
  text-align: center;
  overflow-x: hidden;
  display: none;
  cursor: pointer;
  z-index: 99999;
  background: var(--be-bg-glass-s);
  -webkit-backdrop-filter: saturate(5) blur(20px);
  backdrop-filter: saturate(5) blur(20px);
}

.off-search-a {
  background: var(--be-bg-white);
  min-height: 15vh;
}

.search-area {
  background: var(--be-bg-white);
  width: 100%;
}

.search-wrap {
  width: var(--be-main-width);
  cursor: auto;
  margin: 0 auto;
  padding: 20px;
}

.searchbar {
  margin: 10px 0;
  position: relative;
}

.search-input {
  position: relative;
}

.search-input input {
  float: left;
  width: 90%;
  height: 37px;
  line-height: 37px;
  font: 14px "Microsoft YaHei", Helvetica;
  padding: 4px 15px;
  background: var(--be-bg-grey-f1);
  border: 1px solid transparent;
  border-radius: 5px 0 0 5px;
  -webkit-appearance: none;
}

.search-input input:focus {
  background: var(--be-bg-white);
  border: 1px solid #999;
  border-right: none;
}

.search-wrap .search-input input:focus {
  background: var(--be-bg-white);
  border: 1px solid #999;
  border-right: none !important;
}

.search-wrap input.baidu-input:focus {
  border: 1px solid #52819c;
}

.search-wrap input.bing-input:focus {
  border: 1px solid #008272;
}

.search-wrap input.input-360:focus {
  border: 1px solid #00a496;
}

.search-wrap input.sogou-input:focus {
  border: 1px solid #fd5607;
}

.searchbar button {
  overflow: visible;
  position: relative;
  cursor: pointer;
  height: 37px;
  width: 10%;
  color: var(--be-grey-6);
  background: var(--be-bg-blue-d);
  margin: 0;
  border: none;
  border-radius: 0 5px 5px 0;
}

.searchbar button:hover {
  opacity: 0.8;
}

.searchbar button .cx {
  font-size: 18px !important;
}

.searchbar button .be {
  font-size: 15px !important;
}

@media screen and (max-width: 768px) {
  .searchbar button {
    width: 20%;
  }

  .search-input input {
    width: 80%;
  }
}

.search-nav {
  margin: 20px auto 0;
}

.search-menu a {
  float: left;
  color: var(--be-grey-9);
  line-height: 30px;
  margin: 0 2px 2px 0;
  padding: 2px 10px;
  border-radius: 5px;
}

.search-menu a:hover {
  background: var(--be-shadow-h);
  color: var(--be-white);
}

.choose {
  display: none;
}

@media screen and (max-width: 1025px) {
  .search-wrap {
    width: 98%;
  }
}

.search-tabs {
  float: left;
  width: 100%;
}

/* 全屏搜索内：父级含 float 子元素时高度为 0，仅上半区能点到；用 flex 铺满可点区域 */
#search-main .search-tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 6px;
  float: none;
}

#search-main .search-tabs .search-item {
  display: flex;
  align-items: stretch;
  cursor: pointer;
}

.search-tabs .search-item span {
  float: left;
  cursor: pointer;
  margin: 0 2px 0 0;
  padding: 4px 10px;
  border-radius: 5px;
}

#search-main .search-tabs .search-item span {
  float: none;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  margin: 0;
  padding: 6px 14px;
}

.search-baidu button,
.search-item.searchbaidu.active span {
  background: #c8102e;
}

.search-bing button,
.search-item.searchbing.active span {
  background: #c8102e;
}

.search-sogou button,
.search-item.searchsogou.active span {
  background: #c8102e;
}

.search-360 button,
.search-item.search360.active span {
  background: #c8102e;
}

.active {
  color: #fff;
}

.search-baidu button {
  background: #c8102e;
}

.search-bing button {
  background: #c8102e;
}

.search-360 button {
  background: #c8102e;
}

.search-sogou button {
  background: #c8102e;
}

.tab-search button {
  color: var(--be-white);
}
