@charset "utf-8";

.header.UpMove{
  animation: UpAnime 0.5s forwards;
}

.ham-wrap{
  margin-top:5rem;
}

.header.DownMove{
  animation: DownAnime 0.5s forwards;
}
@keyframes UpAnime{
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(-100px);
  }
}
@keyframes DownAnime{
  from {
    opacity: 0;
    transform: translateY(-100px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}


.header{
  position: fixed;
  z-index:9999;
  top: 0;
  left: 0;
  width: 100%;
  padding:1rem 0 0 0;
  background-color: transparent;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-start;
  transition: 0.3s;
}

.header-logo{
  display: block;
  width: 370px;
}

.header_menu{
  display: flex;
  flex-direction: row;
  gap: 1.5rem;
  align-items: center
}

.header-right{
  display: flex;
  align-items: center;
}

.header-contact{
  background: #024DA4;
  color: #fff;
  padding: 12px;
  font-size: clamp(1.125rem, 0.989rem + 0.45vw, 1.5rem);
  width: 280px;
  letter-spacing: 2px;
  height: 64px;
  display: flex;
  justify-content: center;
  align-items: center;
      position: relative;
  overflow:hidden;
}

.header-contact::before{
    background: #fff;
    content: "";
    height: 250%;
    left: -200%;
    opacity: .2;
    position: absolute;
    top: -100px;
    transform: rotate(15deg);
    transition: all 600ms cubic-bezier(0.19, 1, 0.22, 1);
    width: 100%;
    z-index: 10;
}

.header-contact:hover::before{
    left: 100%;
    top: 18px;
    transition: all 550ms cubic-bezier(0.19, 1, 0.22, 1);
}

.hamBtn {
  cursor: pointer;
  z-index: 9999;
  transition: all .5s;
  display: flex;
  align-items: center;
  width: 100px;
  height: 64px;
  background-color: #002753;
  justify-content: center;
}

.hamBtn:has(.hamBar.active){
  background:transparent;
}

.hamBar {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 24px;
  width: 2.5rem;
}

.hamBar>div {
  position: absolute;
  right: 0;
  width: 100%;
  height: 4px;
  background: #fff;
  transition: .5s;
}

.hamBar>div:nth-child(1) {
  top: 0; 
}

.hamBar>div:nth-child(2) {
  top: 50%;
}

.hamBar>div:nth-child(3) {
  top: 100%;
}

.hamBar.active>div:nth-child(1) {
  top: 10px;
  transform: rotate(-30deg);
}

.hamBar.active>div:nth-child(2) {
  opacity: 0;
}

.hamBar.active>div:nth-child(3) {
  top: 10px;
  transform: rotate(30deg);
}


.sp__menu {
  background: url(https://sanei-construction.com/system_panel/uploads/images/20251106142649691300.png) no-repeat center/cover;
  position: fixed;
  top: 0;
  left: 0;
  opacity: 0;
  width: 100%;
  height: 100vh;
  display:flex;
  flex-direction: column;
  justify-content: center;
  align-items:center;
  color: #554844;
  transition: 1s;
  z-index: 8000;
  z-index:-100;
}

.sp__menu .hamBtn{
  position:fixed;
  right:0;
  top:1rem;
}

.sp__menu .header-logo{
  position:fixed;
  left:0;
  top:1rem;
}

.ham-wrap{
  max-width:1080px;
  margin:0 auto;
  width: 90%;
  display: flex;
  flex-wrap: wrap;
  gap: 3rem 5%;
}

.ham-wrap a{
  width:30%;
  font-size:clamp(0.875rem, 0.784rem + 0.3vw, 1.125rem);
}

.ham-wrap a:hover{
  color:#FFFDB4;
  opacity:1;
}

.ham-wrap a p:first-child{
  font-size:clamp(1.5rem, 0.227rem + 4.24vw, 5rem);
  font-family:"Oswald", sans-serif;
  font-weight:bold;
}

.sp__menu.active {
  opacity: 1;
  visibility: visible;
  z-index:100000;
}



@media (max-width: 1279px) {
  .sp__menu{
    overflow: scroll;
    min-height: 600px;
    height: 100%;
  }
}

@media (max-width: 1024px) {
  .header-contact{
    width: 240px;
  }
  .header-logo{
    width: 300px;
  }
}


@media (max-width: 767px) {
  .header-right > .header-contact{
    display:none;
  }
  .hamBtn{
    width: 64px;
    height: 40px;
  }
  .sp__menu {
    width:100%;
    padding: 5rem 0;
    background: url(https://sanei-construction.com/system_panel/uploads/images/20251106142649595804.png) no-repeat center / cover;
  }
  .header-logo{
    width: 160px;
  }
  .hamBar>div{
    height: 2px;
  }
  .hamBar{
    height: 18px;
    width: 26px;
  }
  .ham-wrap{
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
  }
  .ham-wrap a{
    width: fit-content;
  }
  .ham-wrap a p:first-child{
    display:none;
  }
}


#header.UpMove{
  animation: UpAnime 0.5s forwards;
}

@keyframes UpAnime{
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(-100px);
  }
}

/*　下に下がる動き　*/

#header.DownMove{
  animation: DownAnime 0.5s forwards;
}
@keyframes DownAnime{
  from {
    opacity: 0;
    transform: translateY(-100px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

