/*
  GK 홈페이지 2차메뉴 중복 제거 + 기존 탭 안정화 v2.8

  목적:
  - v2.7처럼 상단에 2차 메뉴를 새로 만들지 않음
  - 기존 본문 안의 01/02/03 탭 메뉴만 깔끔하게 정리
  - 1차 메뉴 안정화 상태는 건드리지 않음
*/

.gk-section-subnav-v27 {
  display: none !important;
}

/* JS가 찾은 기존 본문 탭바 */
.gk-local-tabbar-v28 {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 5px !important;
  flex-wrap: wrap !important;
  max-width: 100% !important;
  margin-top: 0 !important;
  margin-bottom: 34px !important;
  padding: 0 !important;
  box-sizing: border-box !important;
}

.gk-local-tabbar-v28 > *,
.gk-local-tabbar-item-v28 {
  flex: 0 0 auto !important;
  margin: 0 !important;
}

.gk-local-tabbar-link-v28 {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 36px !important;
  padding: 0 13px !important;
  border: 1px solid #dbe3ef !important;
  background: #f8fafc !important;
  color: #0f2f5f !important;
  font-size: 13px !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  word-break: keep-all !important;
  box-sizing: border-box !important;
  transition: none !important;
}

.gk-local-tabbar-link-v28:hover {
  background: #eff6ff !important;
  border-color: #bfdbfe !important;
  color: #0056b8 !important;
}

.gk-local-tabbar-link-v28.is-active,
.gk-local-tabbar-link-v28.active,
.gk-local-tabbar-v28 .active > .gk-local-tabbar-link-v28,
.gk-local-tabbar-v28 .on > .gk-local-tabbar-link-v28 {
  background: #005fc5 !important;
  border-color: #005fc5 !important;
  color: #fff !important;
}

/* 기존 스킨 active가 a에 직접 들어있는 경우 */
.gk-local-tabbar-v28 a.active,
.gk-local-tabbar-v28 a.on {
  background: #005fc5 !important;
  border-color: #005fc5 !important;
  color: #fff !important;
}

/* 모바일: 기존 탭은 한 줄 가로 스크롤 */
@media (max-width: 768px) {
  .gk-local-tabbar-v28 {
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important;
    gap: 4px !important;
    margin-left: -4px !important;
    margin-right: -4px !important;
    margin-bottom: 24px !important;
    padding: 0 4px 2px !important;
  }

  .gk-local-tabbar-v28::-webkit-scrollbar {
    display: none !important;
  }

  .gk-local-tabbar-link-v28 {
    min-height: 34px !important;
    padding: 0 11px !important;
    font-size: 12px !important;
  }
}

body::after {
  content: "GK_LOCAL_TABBAR_V28";
  position: fixed;
  right: 6px;
  bottom: 54px;
  z-index: 99999;
  color: #94a3b8;
  font-size: 10px;
  pointer-events: none;
}
