@import url('font.css');

:root{
  --primary-color: #1a1a1a;
  --secondary-color: #444;
  --accent-color: #0843c1;
  --text-color: #F5F7FA;
  --background-color: #F5F7FA;
}

*{
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

a,a:focus{
  color: #1A1A1A;
  text-decoration: none;
}

img{
  width: 100%;
  height: 100%;
  object-fit: cover;
}

header img {
    width: 280px;
    height: 60px;
}

.main-logo img{
  width: 80%;
  height: 100%;
  display: block;
  object-fit: cover;
}

body{
  background-color: white;
  color: #1A1A1A;
  font-family: "Noto Sans KR", sans-serif;
}

button{
  cursor: pointer;
  border-style: none;
}

address{
  font-style: normal;
}

ul, li{
  list-style: none;
}

/* 기본적으로 리스트*/
.visible-list ul {
    list-style: disc !important;
    padding-left: 20px;
}

.visible-list li {
    list-style: disc !important;
}

select, input, option{
  font-family: "NotoSansKR", sans-serif;
  color: #1a1a1a;
}

/* 1차 메뉴 전체 컨테이너 */
.gnb-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 999;
    width: inherit;
}

/* 1차 메뉴 각 항목 */
.gnb-parent-item {
    position: relative;
    flex: 1 1 auto;  /* 각 li가 동일한 비율로 너비를 차지하도록 */
}

/* 1차 메뉴 텍스트 */
.gnb-item-ti {
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    color: #F5F7FA;
    height: 80px;
    line-height: 60px;
    text-align: center;
    font-size: 18px;
}

/* 2차 메뉴 wrapper: 기본은 숨김 */
.gnb-slave-wrapper {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    height: 300px; /* 여기서 원하는 높이 (예: 70px 또는 200px로 확장 가능) */
    background-color: white; /* 파란 배경 */
    visibility: hidden;
    opacity: 0;
    border-top: 1px solid #ccc;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    z-index: 998;
}


/* 1차 메뉴 중 아무 곳에 마우스를 올리면 전체 슬레이브 영역 보이기 */
.gnb-container:hover .gnb-slave-wrapper {
    visibility: visible;
    opacity: 1;
}

/* 2차 메뉴 리스트: 가로로 나열 (1차 메뉴 수만큼 칸 나눔) */
.gnb-slave {
    display: block;  /* 기존 flex 지우기 */
}

/* 각 1차 메뉴에 대응하는 2차 메뉴 박스 */
.gnb-slave-col {
    width: calc(100% / 5);  /* 1차 메뉴 수에 따라 조정 */
    padding-left: 15px;
    box-sizing: border-box;
    border-left: 1px solid #444;
}

/* 2차 메뉴 항목 */
.gnb-slave-col a {
    display: block;
    padding: 10px 0;
    font-size: 0.9rem;
    color: #333;
    white-space: nowrap;
    font-weight: 500;
}

/* hover 시 강조 */
.gnb-slave-col a:hover {
    color: #0843c1;
    background-color: #f0f0f0;
}

/* 각 1차 메뉴 아래 세로로 나열되는 영역 (지금 gnb-slave-wrapper는 부모 li 기준 위치 고정됨, 그대로 둠) */
.gnb-slave-item a {
    display: block;
    padding: 10px 15px;
    color: #333;
    font-size: 0.9rem;
    font-weight: 500;
    text-align: center;
}

/* hover 효과는 그대로 유지 */
.gnb-slave-item a:hover {
    color: #0843c1;
}

.gnb-submenu-wrap {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    height: 300px; /* 원하는 높이 */
    background-color: white;
    visibility: hidden;
    opacity: 0;
    border-top: 1px solid #ccc;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    z-index: 997;  /* gnb-container보다 낮고 메뉴보단 높게 */
}

/* Hover 트리거 대상은 .main-menu 전체로 */
.main-menu:hover .gnb-submenu-wrap {
    visibility: visible;
    opacity: 1;
}

/* gnb-container hover도 같이 */
.main-menu:hover .gnb-container .gnb-slave-wrapper {
    visibility: visible;
    opacity: 1;
}

/* index.html research / news 구분 선 */
.section-divider {
    width: 100%;
    height: 2px;
    background-color: #000000;
    margin: 10px 0;
}

.title-divider {
    width: 100%;
    height: 1px;
    background-color: rgb(203, 214, 230);
}

.side-menu-divider {
  border-top: 1px solid #ccc;
  margin: 0 20px;
}

/* 좌측 사이드 메뉴 해당 페이지 접근 시 강조 색상 부여 */
.l-menu.active .l-menu-text,
.l-submenu.active .l-menu-text-child {
    color: blue;
}

#gnbCurtain {
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 900;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.5);
}