html, body, div, span, iframe,
h1, p,a, img, header, nav, section {
  margin-bottom: 5px;
  margin-top:0px;
  padding: 0;
  border: 0;
  font-size: 115%;
  font-family: 'Space Grotesk', sans-serif;
  vertical-align: baseline;
  color : black;
  text-decoration: none;
  
}
.bg-slideshow {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -2; /* 3D 캔버스가 -1이므로, 그보다 더 뒤로 배치 */
  
}

.bg-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  opacity: 0; /* 처음에는 안 보이게 시작 */
  animation: fadeSlide 55s infinite; /* 15초 주기로 무한 반복 */
}

/* 애니메이션: 투명도가 0에서 0.15(희미하게)로 변했다가 다시 0으로 */
@keyframes fadeSlide {
  0% { opacity: 0; }
  4% { opacity: 1; } /* 숫자를 키우면 더 진해지고, 줄이면 더 희미해집니다 */
  13% { opacity: 1; }
  18% { opacity: 0; }
  100% { opacity: 0; }
}

/* 각 이미지마다 시작 시간을 다르게 설정하여 순서대로 나오게 함 */
.bg-image:nth-child(1)  { animation-delay: 0s; }
.bg-image:nth-child(2)  { animation-delay: 5s; }
.bg-image:nth-child(3)  { animation-delay: 10s; }
.bg-image:nth-child(4)  { animation-delay: 15s; }
.bg-image:nth-child(5)  { animation-delay: 20s; }
.bg-image:nth-child(6)  { animation-delay: 25s; }
.bg-image:nth-child(7)  { animation-delay: 30s; }
.bg-image:nth-child(8)  { animation-delay: 35s; }
.bg-image:nth-child(9)  { animation-delay: 40s; }
.bg-image:nth-child(10) { animation-delay: 45s; }
.bg-image:nth-child(11) { animation-delay: 50s; }

canvas {
  display: block;
  position: fixed;
  top: 0;
  left: 0;
  z-index: -1; /* 메뉴보다 뒤로 가도록 z-index를 음수로 설정 */
}

body {
  margin: 0 !important;
  padding: 0;
}

.site-logo {
  width: 15%;
  height: auto; /* 비율 맞춰서 자동 조정 */
}

.menu a {
  text-decoration: none;
  color: black;
  padding: 8px 16px;
  transition: background-color 0.3s, color 0.3s;
  border-radius: 4px;
}

.menu a:hover {
  background-color: black;
  color: white;
}

.menu a:hover span {
  color: white;
}


img {
  margin-left: 30px;
  margin-top: 15px;
}

ol, ul {
  list-style: none;
  font-size: 50%;
  display: flex;
  justify-content: flex-end;
  margin-right : 50px;
  margin-bottom: 10px;
  margin-top: -50px;
}
  

  nav {
    display: block;
  }

  * {
    -webkit-box-sizing: border-box;
    -moz-box-sizing: border-box;
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
  }


.menu-toggle {
  display: none;
}
#mobile-menu-overlay {
  display: none;
}

/* 모바일에서 햄버거 아이콘 보이게 + 메뉴 숨기기 */
@media (max-width: 768px) {
  .menu-toggle {
    display: block;
    font-size: 28px;
    cursor: pointer;
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    z-index: 1001;
  }

  #logo img,
  .site-logo {
    display: block;
    width: 40vw;         /* or a fixed px like 150px */
    height: auto;
    margin-left: auto;
    margin-right: auto;
    margin-top: 10px;     /* 적절히 조정 */
    margin-bottom: 10px;
  }

  #header {
    position: fixed; /* 화면의 절대 위치에 고정 (스크롤 시 따라오게 하려면 fixed 사용) */
    top: 0;
    left: 0;
    width: 100%;
    background-color: transparent; /* 배경을 투명하게 설정 */
    z-index: 1000; /* 3D 캔버스(본문)보다 메뉴가 항상 위로 올라오게 설정 */
  }

  #head-center {
    display: none;
    position: absolute;
    top: 80px;
    right: 20px;
    background: white;
    border: 1px solid #ccc;
    padding: 10px 20px;
    z-index: 999;
  }

  #head-center.active {
    display: block;
  }

  #head-center ul {
    flex-direction: column;
    align-items: flex-start;
    margin: 0;
    padding: 0;
    gap: 10px;
  }

  .menu {
    width: 100%;
  }

  .menu a {
    font-size: 16px;
    display: block;
    width: 100%;
  }
  .site-logo {
    width: 40vw; /* 모바일에서 더 크고 안정적으로 보이게 */
    height: auto;
    margin-left: 10px;
}

#mobile-menu-overlay {
  position: fixed;
  top: 0; left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(255, 255, 255, 0.95);
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  transition: opacity 0.4s ease;
}

#mobile-menu-overlay.active {
  display: flex;
}

#mobile-menu-overlay ul {
  list-style: none;
  padding: 0;
  margin: 0;
  text-align: center;
  align-items: center;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

#mobile-menu-overlay li {
  margin: 0;
  text-align: center;
}

#mobile-menu-overlay a {
  text-decoration: none;
  font-size: 24px;
  color: black;
  font-family: 'Space Grotesk', sans-serif;
  text-align: center;
}

#mobile-menu-close {
  position: absolute;
  top: 30px;
  right: 30px;
  font-size: 30px;
  cursor: pointer;
}

}
/* --- 메뉴 틀어짐 없는 로고 호버 반전 효과 --- */
#logo a {
  transition: background-color 0.3s;
  border-radius: 4px;
  /* padding이나 display 같은 레이아웃 속성을 없애서 메뉴가 밀려나지 않게 합니다 */
}



.site-logo {
  transition: filter 0.3s;
}

#logo a:hover .site-logo {
  filter: invert(100%); /* 배경이 까매질 때, 로고 이미지는 하얗게 반전 */
}