.header {
  position: fixed;
  width: 100%;
  top: 0;
  left: 0;
  z-index: 999;
}

.header .inner {
  max-width: 1920px;
  margin: 0 auto;
  padding: 20px 95px 0;
  transition: background-color 0.3s;
}

.header .inner.scrolled {
  background-color: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(0px);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.header .header_top {
  display: flex;
  justify-content: flex-end;
  gap: 30px;
}

.header .header_top .main_logo_small,
.header .header_top .btn_menu.small {
  display: none;
}

.header .header_top_right {
  display: flex;
  align-items: center;
  gap: 30px;
}

.header .header_top .login_join {
  display: flex;
}

.header .header_top .login_join li {
  display: flex;
  align-items: center;
}

.header .header_top .login_join li:first-child ::after {
  content: '';
  width: 1px;
  height: 18px;
  background-color: #999;
  display: inline-block;
  margin: 0 15px;
  vertical-align: sub;
}

.header .header_top .login_join > li a {
  display: flex;
  align-items: center;
  height: 100%;
  text-shadow: 2px 2px 3px rgba(255, 255, 255, 0.4);
}

.header .header_top .login_join > li a:hover {
  color: var(--point-color-hover);
}

.header .header_top .login_join > li a.mo {
  display: none;
}

.header .header_top .language_icon {
  display: flex;
  align-items: center;
}

.header .header_top #langToggleBtn {
  display: none;
  align-items: center;
}

.header .header_top #langToggleBtn span {
  font-size: 24px;
  font-weight: 200;
}

.header .header_top .language_icon .lang-list {
  display: flex;
  align-items: center;
  gap: 5px;
  overflow: hidden;
  height: 31px;
}

.header .header_top .language_icon .lang-list li a:hover img {
  filter: brightness(0.9);
}

.header .header_bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 30px;
  padding: 15px 0;
}

/* 로고 */
.header .header_bottom .main_logo {
  min-width: 205px;
  height: 50px;
}

.header .header_bottom .main_logo a {
  display: block;
  width: 100%;
  height: 100%;
}

.header .header_bottom .main_logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.header .header_bottom nav {
  height: 50px;
}

/* 모바일 네비게이션 버튼 */
.header .btn_menu {
  min-width: 17px;
  height: 15px;
  position: relative;
}

.header .btn_menu a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: 100%;
}
.header .btn_menu a.active {
  position: absolute;
  right: 15px;
}

.header .btn_menu i {
  display: block;
  width: 100%;
  height: 2px;
  background-color: #222;
  transition: all 0.3s;
}

.header .btn_menu a.active i:nth-child(1) {
  transform: rotate(45deg) translate(5.5px, 5.5px);
}
.header .btn_menu a.active i:nth-child(2) {
  opacity: 0;
}
.header .btn_menu a.active i:nth-child(3) {
  transform: rotate(-45deg) translate(3.5px, -4px);
}


/* 네비게이션 */
.header .header_bottom .nav_list {
  display: flex;
  align-items: center;
  justify-content: end;
  height: 100%;
}

.header .header_bottom .nav_list li {
  white-space: nowrap;
  padding: 0 27px;
  color: #333;
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
}
.header .header_bottom .nav_list li:first-child {
  padding-left: 0;
}
.header .header_bottom .nav_list li:last-child {
  padding-right: 0;
}

.header .header_bottom .nav_list > li a {
  position: relative;
  display: inline-flex;
  align-items: center;
  height: 100%;
}
.header .header_bottom .nav_list > li a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 50%;
  width: 0;
  height: 2px;
  background-color: var(--point-color-hover);
  transition: all 0.3s ease;
  transform: translateX(-50%);
}
.header .header_bottom .nav_list > li a:hover::after {
  width: 100%;
}

.header .header_bottom .nav_list li:hover a {
  color: var(--point-color-hover);
}

/* navbar sub menu */
.nav_sub_menu {
  max-width: 1920px;
  margin: 0 auto;
  width: 100%;
  height: 100vh;
  background-color: #fff;
  padding: 100px 80px 200px;
  flex-wrap: wrap;
  gap: 80px;
  display: none;
  position: absolute;
  inset: 0;
  overflow-y: auto;
}

/* 개별 서브메뉴 스타일 */
.header .header_bottom .nav_list .nav-item .submenu {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(-10px);
  background-color: #fff;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.15);
  border-radius: 16px;
  min-width: 240px;
  z-index: 1000;
  padding: 20px 0;
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(0, 0, 0, 0.08);
}

.header .header_bottom .nav_list .nav-item:hover .submenu {
  display: block;
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.header .header_bottom .nav_list .nav-item .submenu ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.header .header_bottom .nav_list .nav-item .submenu ul li {
  margin: 0;
  padding: 0;
}

.header .header_bottom .nav_list .nav-item .submenu ul li a {
  display: block;
  width: 100%;
  padding: 14px 28px;
  color: #333;
  text-decoration: none;
  font-size: 14px;
  font-weight: 400;
  transition: all 0.3s ease;
  position: relative;
  border-radius: 0;
  background: transparent;
}

.header .header_bottom .nav_list .nav-item .submenu ul li a:hover {
  background: rgba(248, 249, 250, 0.8);
  color: var(--point-color-hover);
  box-shadow: inset 4px 0 0 var(--point-color-hover);
}

.header .header_bottom .nav_list .nav-item .submenu ul li a::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 0;
  height: 100%;
  background-color: var(--point-color-hover);
  transition: width 0.3s ease;
  opacity: 0.1;
}

.header .header_bottom .nav_list .nav-item .submenu ul li a:hover::before {
  width: 4px;
}

.header .header_bottom .nav_list .nav-item .submenu ul li a::after {
  display: none;
}

/* 네비게이션 아이템에 position relative 추가 */
.header .header_bottom .nav_list .nav-item {
  position: relative;
}

/* aside 형태의 nav_sub_menu 스타일 */
.nav_sub_menu {
  max-width: 1920px;
  margin: 0 auto;
  width: 100%;
  height: 100vh;
  background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
  padding: 0;
  display: none;
  position: absolute;
  inset: 0;
  overflow-y: auto;
  z-index: 1000;
}

.nav_sub_menu.active {
  display: block;
  animation: slideInFromTop 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideInFromTop {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 서브메뉴 헤더 */
.nav_sub_menu .submenu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 30px 80px 20px;
  background-color: rgba(255, 255, 255, 0.75);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 10;
}

.nav_sub_menu .submenu-header h2 {
  font-size: 24px;
  font-weight: 700;
  color: #333;
  margin: 0;
}

.nav_sub_menu .submenu-close {
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 8px;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
}

.nav_sub_menu .submenu-close:hover {
  background: rgba(0, 0, 0, 0.05);
  transform: scale(1.1);
}

.nav_sub_menu .submenu-close span {
  font-size: 24px;
  color: #666;
  transition: color 0.3s ease;
}

.nav_sub_menu .submenu-close:hover span {
  color: var(--point-color-hover);
}

.nav_sub_menu .submenu-container {
  display: flex;
  flex-wrap: wrap;
  gap: 80px;
  max-width: 1600px;
  margin: 0 auto;
  padding: 60px 80px 200px;
}

.nav_sub_menu .submenu-section {
  flex: 1;
  min-width: 250px;
  max-width: 300px;
  background: rgba(255, 255, 255, 0.8);
  border-radius: 16px;
  padding: 30px 25px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  overflow: hidden;
}

.nav_sub_menu .submenu-section:hover {
  /* transform: translateY(-4px); */
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.12);
  background: rgba(255, 255, 255, 0.95);
}

.nav_sub_menu .submenu-section h3 {
  font-weight: 700;
  font-size: 18px;
  color: #333;
  margin-bottom: 35px;
  position: relative;
  padding-bottom: 15px;
}

.nav_sub_menu .submenu-section h3::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 3px;
  background: linear-gradient(90deg, var(--point-color-hover) 0%, rgba(255, 255, 255, 0) 100%);
  border-radius: 2px;
  transition: width 0.3s ease;
}

.nav_sub_menu .submenu-section:hover h3::after {
  width: 60px;
}

.nav_sub_menu .submenu-section ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav_sub_menu .submenu-section ul li {
  margin: 0;
  padding: 0;
  margin-bottom: 15px;
  position: relative;
}

.nav_sub_menu .submenu-section ul li a {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #666;
  text-decoration: none;
  font-size: 14px;
  transition: all 0.3s ease;
  position: relative;
  padding: 12px 16px;
  border-radius: 8px;
  background: transparent;
  border-left: 3px solid transparent;
}

.nav_sub_menu .submenu-section ul li a::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--point-color-hover) 0%, rgba(255, 255, 255, 0) 100%);
  transition: width 0.3s ease;
  opacity: 0.1;
  border-radius: 8px 0 0 8px;
}

.nav_sub_menu .submenu-section ul li a:hover {
  color: var(--point-color-hover);
  background: rgba(248, 249, 250, 0.8);
  border-left: 3px solid var(--point-color-hover);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.nav_sub_menu .submenu-section ul li a:hover::before {
  width: 100%;
}

.nav_sub_menu .submenu-section ul li a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 1px;
  background: linear-gradient(90deg, var(--point-color-hover) 0%, rgba(255, 255, 255, 0) 100%);
  transition: width 0.3s ease;
}

.nav_sub_menu .submenu-section ul li a:hover::after {
  width: 100%;
}

body:has(.nav_sub_menu.active) {
  overflow: hidden;
}

.nav_sub_menu ul {
  margin: 0 20px;
}

.nav_sub_menu ul li {
  color: #999999;
  margin-top: 15px;
}

.nav_sub_menu ul li a {
  position: relative;
  display: inline-block;
}

.nav_sub_menu ul li a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 50%;
  width: 0;
  height: 2px;
  background-color: var(--point-color-hover);
  transition: all 0.3s ease;
  transform: translateX(-50%);
}

.nav_sub_menu ul li a:hover {
  color: var(--point-color-hover);
}

.nav_sub_menu ul li a:hover::after {
  width: 100%;
}

@media (max-width: 1600px) {
  .header .header_bottom .nav_list {
    display: none;
  }
}


@media (max-width: 1240px) {
  .header .inner {
    padding: 20px 40px 0;
  }
  .nav_sub_menu .submenu-header {
    padding: 25px 40px 15px;
  }
  .nav_sub_menu .submenu-container {
    padding: 50px 40px 150px;
    gap: 60px;
  }
  .nav_sub_menu .submenu-section {
    min-width: 200px;
    padding: 25px 20px;
  }
  .nav_sub_menu .submenu-section h3 {
    font-size: 17px;
    margin-bottom: 30px;
  }
  .nav_sub_menu .submenu-section ul li a {
    font-size: 13px;
    padding: 10px 14px;
  }
}

@media (max-width: 768px) {
  .header .inner {
    padding: 20px 16px 0;
  }
  .header .header_top {
    justify-content: space-between;
  }
  .header .header_top_right {
    gap: 15px;
  }
  .header .header_top .language_icon .lang-list {
    height: auto;
  }
  .header .header_bottom {
    display: none;
  }
  .header .header_top .main_logo_small,
  .header .header_top .btn_menu.small {
    display: block;
  }
  .header .header_top .login_join > li a.pc {
    display: none;
  }
  .header .header_top .login_join > li a.mo {
    display: flex;
    color: #333;
  }
  .header .header_top .language_icon {
    position: relative;
    gap: 0;
  }
  .header .header_top .language_icon > li:not(.lang-toggle) {
    display: none;
  }
  .header .header_top #langToggleBtn {
    display: flex;
  }
  .header .header_top .language_icon .lang-list {
    display: block;
    position: absolute;
    top: 25px;
    right: -10px;
    width: 48px;
    background: rgba(255, 255, 255, 0.75);
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    transition: max-height 0.3s cubic-bezier(.4,0,.2,1), opacity 0.2s;
    z-index: 100;
    pointer-events: none;
  }
  .header .header_top .language_icon .lang-toggle:hover .lang-list,
  .header .header_top .language_icon .lang-toggle:focus-within .lang-list {
    max-height: 300px;
    opacity: 1;
    transition: max-height 0.4s cubic-bezier(.4,0,.2,1), opacity 0.2s;
    pointer-events: auto;
  }
  .header .header_top .language_icon .lang-list li {
    margin: 0;
    padding: 8px 0;
    text-align: center;
  }
  .header .header_top .language_icon .lang-list li:hover {
    background-color: rgba(0, 0, 0, 0.05);
  }
  .header .header_top .language_icon .lang-list li a img {
    width: 32px;
  }

  /* 네비게이션 서브메뉴 모바일 스타일 */
  .nav_sub_menu {
    padding: 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
  }
  .nav_sub_menu .submenu-header {
    padding: 10px 16px 15px;
  }
  .nav_sub_menu .submenu-header h2 {
    font-size: 20px;
  }
  .nav_sub_menu .submenu-close {
    width: 36px;
    height: 36px;
  }
  .nav_sub_menu .submenu-close span {
    font-size: 20px;
  }
  .nav_sub_menu .submenu-container {
    flex-direction: column;
    gap: 30px;
    padding: 40px 16px 100px;
  }
  .nav_sub_menu .submenu-section {
    min-width: auto;
    max-width: none;
    padding: 20px 16px;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
  }
  .nav_sub_menu .submenu-section:hover {
    /* transform: translateY(-2px); */
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
  }
  .nav_sub_menu .submenu-section h3 {
    font-size: 16px;
    margin-bottom: 20px;
    padding-bottom: 12px;
  }
  .nav_sub_menu .submenu-section h3::after {
    width: 30px;
    height: 2px;
  }
  .nav_sub_menu .submenu-section:hover h3::after {
    width: 40px;
  }
  .nav_sub_menu .submenu-section ul li {
    margin-bottom: 8px;
  }
  .nav_sub_menu .submenu-section ul li a {
    font-size: 13px;
    padding: 10px 12px;
    border-radius: 6px;
  }
  .nav_sub_menu .submenu-section ul li a:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  }
  .header .btn_menu a.active {
    top: 50px;
  }
}