@charset "UTF-8";

/* Pretendard 폰트 정의 */
@font-face {
    font-family: 'Pretendard';
    font-weight: 700;
    src: url('../fonts/Pretendard-Bold.woff2') format('woff2');
}
@font-face {
    font-family: 'Pretendard';
    font-weight: 500;
    src: url('../fonts/Pretendard-Medium.woff2') format('woff2');
}

/* Ria Sans 폰트 정의 */
@font-face {
    font-family: 'Ria Sans';
    font-weight: 800;
    src: local('Ria Sans ExtraBold'),
         url('../fonts/RiaSans-ExtraBold.otf') format('opentype'),
         url('../fonts/RiaSans-ExtraBold.ttf') format('truetype');
    font-display: swap;
}
@font-face {
    font-family: 'Ria Sans';
    font-weight: 700;
    src: local('Ria Sans Bold'),
         url('../fonts/RiaSans-Bold.otf') format('opentype'),
         url('../fonts/RiaSans-Bold.ttf') format('truetype');
    font-display: swap;
}
@font-face {
    font-family: 'Ria Sans';
    font-weight: 400;
    src: local('Ria Sans Regular'),
         url('../fonts/RiaSans-Regular.otf') format('opentype'),
         url('../fonts/RiaSans-Regular.ttf') format('truetype');
    font-display: swap;
}

body {
    word-break: keep-all;
}

/* --- Body Scroll Lock --- */
body.no-scroll {
    overflow: hidden;
}

/* =================================================================== */
/* --- PC Header Styles --- */
/* =================================================================== */

#header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: rgba(252, 252, 252, 0.9);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border-bottom: 1px solid #eee;
    font-family: 'Pretendard', sans-serif;
    transition: background-color 0.3s ease, border-bottom 0.3s ease;
}

/* Main Page Header Style (Initially Semi-Transparent) */
#biko-main-page #header {
    background-color: rgba(252, 252, 252, 0.8);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border-bottom: none;
}

/* Header state when scrolled down */
#header.header-scrolled {
    background-color: rgba(252, 252, 252, 0.9) !important;
    backdrop-filter: blur(5px) !important;
    -webkit-backdrop-filter: blur(5px) !important;
    border-bottom: 1px solid #eee !important;
}

/* Sub Page Header Override */
.sub-page #header {
    background-color: #ffffff;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}


#header .header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1920px;
    margin: 0 auto;
    padding: 0 36px;
    height: 82px;
    position: relative;
}

#header .logo img {
    display: block;
}

#header .gnb-pc {
    position: absolute;
    left: 322px; 
}
#header .gnb-pc-list {
    display: flex;
    gap: 48px;
    list-style: none;
}

#header .gnb-pc-item > a {
    display: block;
    padding: 14px 20px;
    font-weight: 700;
    font-size: 20px;
    color: #222;
    transition: color 0.3s;
    text-decoration: none;
}

#header .gnb-pc-item.active > a {
    color: #00754A;
}

#header .header-actions-pc {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 8px;
}

#header .btn-apply {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 12px 16px;
    background-color: #00754A;
    border-radius: 999px;
    color: white;
    font-size: 18px;
    font-weight: 500;
    white-space: nowrap;
    text-decoration: none;
}

#header .btn-apply img {
    filter: brightness(0) invert(1);
}

#header .portal-link {
    padding: 10px 16px;
    font-size: 16px;
    font-weight: 500;
    white-space: nowrap;
}

#header a.portal-link {
    color: #00754A;
    text-decoration: none;
}

#header a.portal-link + a.portal-link {
    color: #2793C2;
}

#header .btn-lang {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

#header .mega-menu-container {
    position: absolute;
    top: 82px;
    left: 0;
    width: 100%;
    background-color: #fcfcfc;
    border-top: 1px solid #eee;
    padding: 32px 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0.3s;
    text-align: center;
}

#header.mega-menu-active .mega-menu-container {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s 0s;
}

#header .mega-menu-inner {
    max-width: 1920px;
    margin: 0 auto;
    padding: 0 36px;
    position: relative;
    min-height: 200px; 
}

#header .mega-menu-content {
    position: absolute; 
    top: 0;
    display: none;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    width: max-content;
}

#header .mega-menu-content.active {
    display: flex;
}

#header .mega-menu-content a {
    font-size: 18px;
    font-weight: 500;
    color: #222;
    transition: color 0.3s;
    text-decoration: none;
}

#header .mega-menu-content a:hover,
#header .mega-menu-content a.active {
    color: #00754A;
    font-weight: 700;
}

#header .btn-hamburger { display: none; }


/* =================================================================== */
/* --- Mobile Header & Menu Styles --- */
/* =================================================================== */

.gnb-mobile-container {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #fcfcfc;
    z-index: 1100;
    padding: 0 16px;
    overflow-y: auto;
    box-sizing: border-box;
}

/* ------------------- 반응형: 모바일 (1024px 이하) ------------------- */
@media (max-width: 1440px) {
    #header .gnb-pc, #header .header-actions-pc, #header .mega-menu-container {
        display: none !important;
    }
    
    #header .header-inner {
        height: 56px;
        padding: 0 16px;
    }

    #header .logo img {
        height: 24px;
        width: auto;
    }

    #header .btn-hamburger {
        display: flex;
        flex-direction: column;
        justify-content: space-around;
        width: 24px;
        height: 24px;
        background: transparent;
        border: none;
        cursor: pointer;
        padding: 0;
        z-index: 1101;
    }

    #header .btn-hamburger .line {
        display: block;
        width: 100%;
        height: 2px;
        background-color: #222;
        transition: all 0.3s ease-in-out;
    }
    
    .gnb-mobile-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        height: 56px; /* 헤더와 동일한 높이 */
        padding: 10px 0;
    }
    
    .btn-lang-mobile {
	    background: none;
	    border: none;
	    cursor: pointer;
	    padding: 0;
    }

    .btn-lang-mobile .lang-toggle-switch {
        width: 84px;
        height: 36px;
    }
    
    .btn-lang-mobile .lang-toggle-switch .lang-toggle-thumb {
    	top: 4px;
    	left: 4px;
    	width: 28px;
    	height: 28px;
    }
    .btn-lang-mobile .lang-toggle-switch[data-lang="en"] .lang-toggle-thumb {
    	top: 4px;
    	left: -20px;
    }
    
    .btn-lang-mobile .lang-toggle-switch .lang-toggle-text {
    	font-size: 12px;
    	line-height: 20px;
    }
    .btn-lang-mobile .lang-toggle-switch .lang-toggle-text.lang-text-ko {
    	left: 8px;
    }
    .btn-lang-mobile .lang-toggle-switch .lang-toggle-text.lang-text-en {
    	right: 8px;
    }

    .btn-close {
        width: 24px;
        height: 24px;
        background: none;
        border: none;
        cursor: pointer;
    }

    .gnb-mobile-content {
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        gap: 40px;
        box-sizing: border-box;
    }
    
    .gnb-mobile-list {
        padding: 0px;
        margin: 0px;
        list-style: none;
    }

    .gnb-mobile-item {
        padding: 10px 16px;
    }

    .gnb-mobile-item > a {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px 16px;
        font-size: 16px;
        font-weight: 500;
        color: #222;
        border-radius: 999px;
        text-decoration: none;
    }
    
    .gnb-mobile-item.active > a {
        color: #00754A;
    }

    .gnb-mobile-item .icon-arrow {
        display: inline-block;
        width: 8px;
        height: 8px;
        border-left: 2px solid #888;
        border-bottom: 2px solid #888;
        transform: rotate(-45deg);
        transition: transform 0.3s;
    }

    .gnb-mobile-item.active > a > .icon-arrow {
        transform: rotate(135deg);
        border-color: #00754A;
    }

    .sub-menu {
        padding: 8px 16px 16px 32px;
        display: none;
        list-style: none;
    }

    .sub-menu li a {
        display: block;
        padding: 8px 0;
        font-size: 14px;
        color: #555;
        text-decoration: none;
    }

    .mobile-actions {
        margin-top: 40px;
        padding: 0 8px;
        position: relative;
    }
    
    .btn-apply-mobile {
        /* width: 100%; */
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 4px;
        padding: 10px 16px;
        background-color: #00754A;
        border-radius: 6px;
        color: white;
        font-size: 16px;
        font-weight: 500;
        text-decoration: none;
    }
    
    .btn-apply-mobile img {
        filter: brightness(0) invert(1);
    }
    
    .portal-links-mobile {
        display: flex;
        justify-content: center;
        margin: 0px;
        padding: 0px;
    }
    .portal-links-mobile a {
        font-size: 14px;
        font-weight: 500;
        text-decoration: none;
    }
    .portal-link {
        padding: 8px 16px;
    }
    .portal-link.participant {
        color: #00754a;
    }
    .portal-link.researcher {
        color: #2793c2;
    }
}
 
 /* =================================================================== */
 /* --- Language Toggle Switch Styles --- */
 /* =================================================================== */
 .lang-toggle-wrapper {
     display: flex;
     align-items: center;
     margin-left: 15px;
     z-index: 10;
 }
 
 .lang-toggle-switch {
     position: relative;
     width: 106px;
     height: 48px;
     background-color: #00C795;
     border-radius: 50px;
     cursor: pointer;
     display: flex;
     align-items: center;
     justify-content: space-between;
     padding: 2px;
     box-sizing: border-box;
     transition: background-color 0.3s ease;
     box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
 }
 
 .lang-toggle-text {
     position: absolute;
     top: 50%;
     transform: translateY(-50%);
     font-family: 'Pretendard', sans-serif;
     font-size: 14px;
     font-weight: 500;
     line-height: 1;
     pointer-events: none;
     transition: opacity 0.3s ease;
 }
 
 .lang-text-en {
     color: #fcfcfc;
     right: 10px;
     opacity: 1;
 }
 
 .lang-text-ko {
     color: #fcfcfc;
     left: 16px;
     opacity: 0;
 }
 
 .lang-toggle-switch[data-lang="en"] {
     background-color: #00C795;
 }
 
 .lang-toggle-switch[data-lang="en"] .lang-text-en {
     opacity: 0;
 }
 
 .lang-toggle-switch[data-lang="en"] .lang-text-ko {
     opacity: 1;
 }
 
 .lang-toggle-thumb {
     position: absolute;
     top: 6px;
     left: 6px;
     width: 36px;
     height: 36px;
     background-color: #fff;
     border-radius: 50%;
     box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
     transition: transform 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
     z-index: 2;
     display: flex;
     align-items: center;
     justify-content: center;
     pointer-events: none;
 }
 
 .lang-toggle-switch[data-lang="en"] .lang-toggle-thumb {
     transform: translateX(56px);
 }
 
 .lang-toggle-thumb svg {
     width: 14px;
     height: 14px;
     transition: transform 0.3s ease, fill 0.3s ease;
     fill: #00C795;
 }
 
 .lang-toggle-switch[data-lang="en"] .lang-toggle-thumb svg {
     transform: rotate(180deg);
     fill: #333;
 }
 
 .lang-toggle-switch[data-lang="ko"] .arrow-path {
     stroke: #27C289;
 }
 
 .lang-toggle-switch[data-lang="en"] .arrow-path {
     stroke: #27C289;
 }

/* =================================================================== */
/* --- Header Related Organizations (Dynamic) --- */
/* =================================================================== */
.header-related-sites {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 10px;
}

.header-portal-link {
    padding: 10px 12px;
    font-size: 16px;
    font-weight: 500;
    color: #00754A;
    text-decoration: none;
    white-space: nowrap;
}

.header-portal-link:nth-child(even) {
    color: #2793C2;
}

.header-portal-link:hover {
    text-decoration: underline;
}

/* Mobile Specific */
@media (max-width: 1440px) {
    .mobile-related-sites {
        display: flex;
        justify-content: center;
        gap: 16px;
        width: 100%;
    }

    .mobile-portal-link {
        font-size: 14px;
        font-weight: 500;
        color: #00754A;
        text-decoration: none;
    }

    .mobile-portal-link:nth-child(even) {
        color: #2793C2;
    }
}

/* 서브페이지 페이지 타이틀 섹션 */
.page-title-section {
    width: 100%;
    box-sizing: border-box;
    background-color: rgba(237, 237, 237, 0.6);
    padding: 100px 0 80px;
    text-align: center;
}

.page-title-section .page-title-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.page-title-section .location {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 18px;
    color: #222;
}

.page-title-section .location span {
    font-weight: 400;
}

.page-title-section .location .divider {
    width: 24px;
    height: 24px;
}

.page-title-section h2 {
    font-family: 'Ria Sans', sans-serif;
    font-weight: 800;
    font-size: 60px;
    color: #222;
    margin: 0;
    line-height: 1.2;
    letter-spacing: -2.4px;
}

.hero-subtitle {
    font-family: 'Ria Sans', sans-serif;
    font-weight: 700;
    font-size: 20px;
    color: #A1A1A1;
    margin: 0 auto;
    max-width: 800px;
    line-height: 1.5;
    letter-spacing: -0.8px;
    word-break: keep-all;
}

@media (max-width: 1440px) {
    .page-title-section h2 {
        font-size: 48px;
    }
}

@media (max-width: 1280px) {
    .page-title-section {
        padding: 40px 16px 42px;
    }

    .page-title-section .location {
        font-size: 12pt;
        gap: 4px;
    }

    .page-title-section .location .divider {
        width: 18px;
        height: 18px;
    }

    .page-title-section h2 {
        font-size: 18pt;
        letter-spacing: -0.96px;
    }

    .hero-subtitle {
        font-size: 12pt;
        letter-spacing: -0.56px;
    }
}
