:root {
    --primary-color: #ff6600;
    --text-color: #222222;
    --gray-text: #666;
    --border-color: #e5e5e5;
    --header-height:70px;
}

/* --- Header Layout (Common) --- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background: #fffefa;
    z-index: 1000;
    transition: all 0.3s ease;
}

.header-inner {
    max-width:1680px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    position: relative;
    z-index: 1002;
}

/* --- Logo --- */
.logo a {
    display: flex;
    flex-direction: column;
    line-height: 1;
}
.logo a span { font-size: 12px; font-weight: 400; font-family: serif; font-style: italic; margin-bottom: 2px;}

/* ================================================================
   [Desktop Styles] - Requested Fixes Applied Here
   ================================================================
*/

/* GNB PC Style */
.gnb-pc { display: flex; height: 100%; }
.gnb-pc > li {
    height: 100%;
    display: flex;
    align-items: center;
}
.gnb-pc > li > a {
    display: block;
    padding: 0 0px; /* 텍스트 위치 기준점 */
    font-size: 19px;
    font-weight:500;
    color: var(--text-color);
    height: 100%;
    line-height:70px;
    position: relative;
    transition: color 0.3s;
	min-width:150px;
	text-align:center;
}

/* [Fix #2] Hover Animation Line */
.gnb-pc > li > a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--primary-color);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

/* [Fix #3] Active & Current States */
/* hover: 마우스 올렸을 때, active: 서브메뉴 호버 중일 때, current: 서브메뉴 클릭 후 페이지 표시 */
.gnb-pc > li:hover > a,
.gnb-pc > li.active > a,
.gnb-pc > li.current > a {
    color: var(--primary-color);
}

.gnb-pc > li:hover > a::after,
.gnb-pc > li.active > a::after,
.gnb-pc > li.current > a::after {
    transform: scaleX(1);
}

/* Mega Menu Background */
.header-bg {
    position: absolute;
    top: var(--header-height);
    left: 0;
    width: 100%;
    height: 0;
    background:rgba(255,255,255,0.8);
    border-top: 1px solid #eee;
    overflow: hidden;
    /* [Fix #2] Recommended Motion: Cubic-bezier for smooth slide */
    transition: height 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    z-index: 999;
    box-shadow: 0 10px 20px rgba(0,0,0,0.03);
	backdrop-filter:blur(10px);
}

/* Submenu Wrapper */
.submenu-wrap {
    position: absolute;
    top: var(--header-height);
    left: 0;
    width: 100%;
    height: 200px; /* Menu Height */
    overflow: hidden;
    pointer-events: none; /* Prevent clicks when hidden */
    z-index: 1003;
}

.submenu-inner {
    max-width: 1680px;
    margin: 0 auto;
    padding: 30px 20px; /* Padding affects alignment calculation */
    position: relative;
    height: 100%;
    
    /* [Fix #2] Motion: Fade in + Slide Down */
    opacity:0%;
    transform: translateY(-15px);
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

/* Header Hover Actions */
	.header:hover .header-bg { height: 200px; }
	.header:hover .submenu-wrap { pointer-events: auto; }
	.header:hover .submenu-inner { opacity: 1; transform: translateY(0); }

/* [Fix #1] Submenu Columns - Absolute Positioning for Exact Alignment */
.submenu-col {
    position: absolute;
    top:30px;
    width: auto;
    min-width:150px;
    text-align:center;
	transform:translateX(20px)
}

.submenu-col ul li { margin-bottom: 12px; }
.submenu-col ul li a {
    font-size: 16px;
    color: #434343;
    display: inline-block;
    transition: all 0.2s;
}

.submenu-col ul li a:hover {
    color: var(--primary-color);
    font-weight: 600;
    transform: translateX(3px);
}

/* Banner inside Menu */
.gnb-banner {
    position: absolute;
    right: 20px;
    top: 30px;
    width: 250px;
    height: 120px;
    background: linear-gradient(rgba(0,0,0,0.3), rgba(0,0,0,0.3)), url('https://images.unsplash.com/photo-1513694203232-719a280e022f?ixlib=rb-1.2.1&auto=format&fit=crop&w=500&q=60') center/cover;
    border-radius: 4px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 25px;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    opacity: 0;
    transition: opacity 0.5s 0.2s;
}
.header:hover .gnb-banner { opacity: 1; }

@media (max-width: 1200px) {
    .gnb-banner { display: none; }
}

/* --- Utils --- */
.utils {
    display: none;
    align-items: center;
    gap: 20px;
}
.utils a { font-size: 22px; color: #333; }
.btn-brand {
    border: 1px solid #ddd;
    padding: 8px 15px;
    font-size: 13px;
    color: #555;
    border-radius: 2px;
    transition: all 0.2s;
}
.btn-brand:hover { border-color: var(--primary-color); color: var(--primary-color); }
.hamburger { display: none; font-size: 24px; color: #333; }


/* ================================================================
   [Mobile Styles] - RESTORED FROM ORIGINAL (n.html)
   ================================================================
*/
.mobile-nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    max-width: 400px; /* 태블릿 대응 */
    height: 100vh;
    background: #fff;
    z-index: 2000;
    transition: right 0.3s ease-in-out;
    display: flex;
    flex-direction: column;
    box-shadow: -5px 0 15px rgba(0,0,0,0.1);
}
.mobile-nav.active { right: 0; }

/* Mobile Overlay */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 1999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}
.overlay.active { opacity: 1; visibility: visible; }

/* Mobile Header */
.m-header {
    padding:10px 20px;
    background: var(--primary-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.m-auth-btns { display: flex; gap: 10px; }
.m-auth-btns a {
    display: block;
    border: 1px solid rgba(255,255,255,0.3);
    color: #fff;
    padding: 8px 16px;
    font-size: 13px;
    border-radius: 2px;
}
.m-close { color: #fff; font-size: 24px; }

/* Mobile Menu List (Accordion) */
.m-menu-list {
    flex: 1;
    overflow-y: auto;
    padding: 20px 0;
}
.m-item { border-bottom: 1px solid #f0f0f0; }

.m-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 20px;
    font-size:17px;
    font-weight:500;
    color: #222;
    cursor: pointer;
}
.m-link i { transition: transform 0.3s; color: #999; }

/* Accordion Active State */
.m-item.active .m-link { color: var(--primary-color); }
.m-item.active .m-link i { transform: rotate(180deg); }

.m-submenu {
    max-height: 0;
    overflow: hidden;
    background: #f9f9f9;
    transition: max-height 0.3s ease-out;
}
.m-submenu ul { padding: 15px 20px; }
.m-submenu li { padding: 8px 0; }
.m-submenu li a { font-size:16px; color: #434343; }

/* Mobile Banner (Footer area) */
.m-banner {
    padding: 20px;
    background: #f4f4f4;
}
.banner-box {
    flex-shrink:0;
    background:#ff6600;
    height: 150px;
    border-radius: 8px;
    position: relative;
    overflow: hidden;
   /* display: flex;
    align-items: center;
    padding-left: 20px;*/
    margin-bottom: 15px;
}
.banner-text { position: relative; z-index: 1; color: #fff; }
.banner-text h4 { font-size: 14px; margin-bottom: 5px; color: #ffcc00; }
.banner-text p { font-size: 16px; font-weight: bold; }

.company-link {
    display: block;
    background: #eee;
    text-align: center;
    padding: 12px;
    color: #333;
    font-weight: 600;
    font-size: 14px;
    border-radius: 4px;
}

/* --- Responsive Queries --- */
@media (max-width: 1024px) {
   
    .gnb-pc, .submenu-wrap, .header-bg { display: none; }
    .hamburger { display: block; }
	.utils{display:block;}
    .utils > a:not(.hamburger) { display: none; }
    .header-inner { justify-content: space-between; padding:10px }

	.header-inner .logo img{max-width:100%; width:190px;}
}
@media (max-width:430px) {
    .header {height:70px;}
	.header-inner .logo img{width:150px;}
}