
:root {
    --background-color: #f0f0f0;
    --white: #ffffff;
    --black: #000000;
}
              
body {
    padding: 0;
    margin: 0;
    height: 100%;
    background-color: var(--background-color);
}

#HXT {
        
    width: 100%;
    height: auto;
    position: relative;
    top: 0px;
    left: 0;
    padding-bottom: 50px;
    overflow: hidden;
    background-color: var(--background-color);

}



/* 导航hidden */
    
#custom-navbar-container.hidden {
top: -70px; 
transition: 0.3s;
}

/* 导航栏 */

#custom-navbar-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 70px;
    background-color: var(--black);
    /* display: none; */
    justify-content: space-between;
    align-items: center;
    /* opacity: 0; */
    animation: slideIn 1s ease-in-out forwards;
    z-index: 10;
  }
  
  
  .custom-navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 0 20px 0 0;
  }
  
  .logo, .logo img {
    height: 70px;
    width: auto;
    overflow: hidden;
    background-color: var(--white);
  }
  
  
  .custom-nav-links {
    display: flex;
    justify-content: center;
    align-items: center;
    list-style: none;
    padding: 0;
    margin: 0;
    height: 100%;
  }
  
  .custom-nav-link {
    /* width: 100px; */
    margin: 0 0px;
    padding: 0;
    font-size: 20px;
  }
  
  .custom-link {
    padding: 20px 20px;
  
    position: relative;
    
    display: flex;
    justify-content: center;
    text-decoration: none;
    background-color: black;
    white-space: nowrap;
  }
  .up,.down{
    line-height: 70px;
    position: absolute;
    color: white;
    top: 0;
    transition: 0.3s;
  }
  .down{
  
    clip-path: inset(49% 0 0 0);
  }
  .up{
    clip-path: inset(1% 0 50% 0);
  }
  .custom-link:hover {
    text-decoration: none;
  }
  .custom-link:hover .up,.custom-link:hover .down{
    top: calc(var(--i)*1px);
  }  
  .custom-link:hover .split{
    opacity: 1;
  }
  .split {
    text-decoration: none;
    color: transparent;
    opacity: 0;
    transition: 0.1s;
  }
  
  .custom-link::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('https://static.igem.wiki/teams/4980/wiki/image/small-sword.png'); 
    background-size: 100% 50%;
    background-repeat: no-repeat;
    background-position: right;
    opacity: 0;
    transition: opacity 0.3s;
    /* z-index: 0; */
    overflow: visible;
  }
  .custom-link:hover::before {
    opacity: 1;
  }
  
  @keyframes slideIn {
    0% {
        opacity: 0;
        transform: translateY(-100%);
    }
  
    100% {
        opacity: 1;
        transform: translateY(0);
    }
  }
  
  /* 导航下拉菜单 */
  
  .custom-dropdown {
    position: relative;
    display: inline-block;
  }
  
  .custom-dropdown-content {
    display: none;
    position: absolute;
    background-color: var(--black);
    min-width: 200px;
    box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.2);
    z-index: 4;
    left: 50%;
    top: 100%;  /* 使下拉菜单的上边缘与其父元素的下边缘对齐 */
    transform: translateX(-50%);
  }
  
  .custom-dropdown-content a {
    color: var(--white);
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    text-align: center;
    white-space: nowrap;
  }
  
  .custom-dropdown-content.left {
    left: -10%;
  }
  
  
  .custom-nav-link:hover .custom-dropdown-content {
    display: block;
  }
  
  .custom-dropdown-content a:hover {
    color: black;
    text-decoration: none;
    background-color: var(--white);
  }
  
  
  /* 移动端按钮 */
  .menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    margin-right: 40px;
  }
  
  .menu-toggle span {
    background-color: var(--white);
    height: 3px;
    width: 25px;
    margin-bottom: 4px;
    border-radius: 2px;
  }
  
  /* 媒体查询：小于768px的屏幕尺寸 */
  @media screen and (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }
  
    .custom-nav-links {
        position: absolute;
        top: 243px;
        right: 0;
        background-color: var(--black);
        flex-direction: column;
        width: 50%;  /* 主导航的宽度 */
        display: none;
        align-items: center;
    }
  
    .custom-nav-link {
        width: 100%;
        text-align: center;
        position: relative;
    }
  
    .custom-link {
        width: 100%;
        display: block;
        text-align: center;
    }
  
    .up, .down{
        display: none;
    }
    .split {
        font-size: 13px;
        
        color: white;
        opacity: 1;
    }
    .custom-link::before{
        display: none;
    }
  
    .custom-dropdown-content {
        position: fixed; 
        top: 66px; 
        left: 25%; 
        width: 50%;     
        height: 600%;
        background-color: var(--black);
        display: none;    /* 默认隐藏 */
        flex-direction: column;
    }
  
    .custom-dropdown-content.left {
        left: 25%;
    }
  
    .custom-dropdown-content a{
        font-size: 13px;
        padding: 20px 0;
    }
    
    /* 当主导航项被悬停时，显示子菜单 */
    .custom-nav-link:hover .custom-dropdown-content {
        display: flex;
    }
  }

/* 页面容器 */

.page-container {
position: relative;
width: 100%;
background-color: var(--background-color);

/* overflow-x: hidden;  */
/* overflow-y: scroll; */
/* display: none; */

}


/* 顶栏 */

#up-container {
display: flex;
flex-direction: column;

width: 100%;
height: 85vh;
margin-top: 70px;
z-index: 8;
background-image: url(https://static.igem.wiki/teams/4980/wiki/image/background1.png);
background-position: center bottom;
background-size: cover;
background-repeat: no-repeat;
}


/* 大标题 */

.up-content {
display: flex;
align-items: center;
justify-content: center;
height: 60vh;
/* text-align: center; */
background-color: transparent;
}


.up-parts {
position: relative;
display: flex;
justify-content: center;
margin: 0 15px;
/* padding: 21px 10px; */
/* font-size: 300px; */
/* top: 7%; */
text-decoration: none;
/* background-color: black; */
overflow: hidden; 
}

@media (max-width: 768px) {
.up-parts {
    display: none;
}
}

.up1, .down1 {
font-size: 120px;
line-height: 300px;
position: absolute;
color: transparent;
/* background-image: url(https://static.igem.wiki/teams/4980/wiki/image/collaborations.png); */
background-position: center center;
background-repeat: no-repeat;
background-size: contain;
top: 0;
transition: 0.4s;
/* overflow: hidden; */
}
.down1 {
clip-path: inset(49% 0 0 0);
}
.up1 {
clip-path: inset(1% 0 50% 0);
}
.up-parts:hover .up1, .up-parts:hover .down1 {
top: calc(var(--i) * 1px);
}
.up-parts:hover .split1 {
opacity: 0;
}
.split1 {
text-decoration: none;
color: white;
font-size: 300px;
line-height: 250px;
opacity: 0;
transition: 0.3s;
}

/* 剑 */

.up-parts::before {
content: "";
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background-image: url('https://static.igem.wiki/teams/4980/wiki/image/big-sword.png'); 
/* background-image: url('./image/heart.png');  */
background-size: contain;
background-repeat: no-repeat;
background-position: center;
opacity: 0;
transition: opacity 0.3s;
z-index: 0;
overflow: visible;
}
.up-parts:hover::before {
opacity: 1;
}

.up-header1 {
text-align: center;
transform: scale(-1, -1);
background-color: transparent;
margin-top: -20px;
}
.up-header2 {
text-align: center;
background-color: transparent;
margin-top: auto;
}
#up-container2 {
top: 20px;
width: 100%;
z-index: 8;
transition: top 0.3s;
background-color: transparent;
}
.up-content2 {
height: 5vh;
margin: 0;
text-align: center;
background-color: black;
}
.waves2 {
width: 100%;
height: 15vh;
margin-bottom: 0px;
min-height: 60px;
max-height: 80px;
}
.sticky2 {
position: sticky;
}





.block-content1 {
height: 70px;
background-color: black;
margin-top: -70px;
}

.block-content2 {
height: 70px;
margin-top: -70px;
}



.waves {
width: 100%;
height: 15vh;
min-height: 60px;
max-height: 80px;
}


.parallax>use {
/* 使use元素执行move-forever动画 */
animation: move-forever 25s cubic-bezier(.55, .5, .45, .5) infinite;
}

.parallax>use:nth-child(1) {
/* 延迟2秒启动动画  */
animation-delay: -2s;
/* 设置动画持续时间为7秒 */
animation-duration: 7s;
}

.parallax>use:nth-child(2) {
animation-delay: -3s;
animation-duration: 10s;
}

.parallax>use:nth-child(3) {
animation-delay: -4s;
animation-duration: 13s;
}

.parallax>use:nth-child(4) {
animation-delay: -5s;
animation-duration: 20s;
}

@keyframes move-forever {
0% {
    transform: translate3d(-90px, 0, 0);
}

100% {
    transform: translate3d(85px, 0, 0);
}
}

@media (max-width: 768px) {
.waves {
    height: 40px;
    min-height: 40px;
}

.waves2 {
    height: 40px;
    min-height: 40px;
}

.up-header1 {
  margin-top: 0;
}

h1 {
    font-size: 24px;
}
}

/* 底栏 */

#bottom-container {

  width: 100%;
  min-height: 65vh;
  position: relative;
  /* display: none; */
  background-color: black;
  /* overflow: hidden; */
}

.bottom-header1 {
  text-align: center;
  background-color: var(--background-color);
}
.bottom-header2 {
  text-align: center;
  transform: scale(-1, -1);
  background-color: var(--background-color);
}

/* 底栏 */

.bottom-content1 {
  display: flex;
  padding: 10px;
  min-height: 45vh;
  align-items: center;
  justify-content: center;
  background-color: black;
}

.bottom-content2 {
  min-height: 10vh;
  text-align: center;
  background-color: var(--background-color);
}

.item1 img {
  height: 85px;
  width: auto;
  margin: 12px;
}
.item2 img {
  height: 60px;
  width: auto;
  margin: 5px;
}

.item1, .item2, .item3{
  text-align: center;
}

.item3 img {
  height: 40px;
  width: auto;
  padding: 0 20px;
}


.bottom-content1 h2{
  font-size: 27px;
  line-height: 30px;
  text-align: center;
  color: white;
  margin-top: 20px;
}
.bottom-content1 p{
  font-size: small;
  line-height: 22px;
  white-space: nowrap;
  color: white;
  text-align: center;
  margin: 0;
}

.bottom-content2 p{
  line-height: 20px;
  color: black;
  margin: 0;
}

.bottom-link{
  text-decoration: none;
  font-weight: bold;
  color: black;
}
.bottom-link:hover{
  text-decoration: underline;
  font-weight: bold;
  color: black;
}
