/* ==========================================================
   Dalgubeol - Common Styles
   Design System: Trust Blue #004182, Pretendard, borderRadius 0
   ========================================================== */

:root {
    --color-primary: #004182;
    --color-primary-dark: #00305f;
    --color-primary-light: #e8f0f9;
    --color-secondary: #767676;
    --color-text: #1a1a1a;
    --color-text-sub: #555;
    --color-border: #e5e8ec;
    --color-bg: #ffffff;
    --color-bg-paper: #f5f7f9;
    --color-error: #e02020;

    --font-sans: 'SCDream', 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, Roboto, 'Helvetica Neue', 'Segoe UI', sans-serif;

    --radius: 0px;
    --header-h: 80px;
    --container-max: 1400px;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    font-family: var(--font-sans);
    color: var(--color-text);
    background: var(--color-bg);
    -webkit-font-smoothing: antialiased;
}

body {
    font-size: 16px;
    line-height: 1.6;
    font-weight: 400;
}

/* 한글(Hangul)에만 자간 미세 조정 */
:lang(ko) { letter-spacing: -0.045rem; }

a { color: inherit; text-decoration: none; }
a:hover { color: var(--color-primary); }

img { max-width: 100%; display: block; }

button {
    font-family: inherit;
    border: 0;
    background: transparent;
    cursor: pointer;
    padding: 0;
    color: inherit;
}

ul, ol { list-style: none; padding: 0; margin: 0; }

h1, h2, h3, h4, h5, h6 { margin: 0; font-weight: 700; letter-spacing: -0.02em; }

/* Bootstrap container-xxl override to 1400px */
.container-xxl { max-width: var(--container-max) !important; }

/* ------------------------------------------ Utility */
.text-primary { color: var(--color-primary) !important; }
.bg-primary   { background: var(--color-primary) !important; }
.fw-700 { font-weight: 700; }
.fw-600 { font-weight: 600; }

/* ------------------------------------------ Site Header (Innogrid 스타일) */
.site-header {
    /* 헤더 전용 포인트 컬러 override */
    --color-primary: #0042ff;
    --color-primary-light: #eaf0ff;

    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
    background: transparent;
    border-bottom: 1px solid transparent;
    height: var(--header-h);
    color: #fff;
    transition: background 0.45s cubic-bezier(.4,0,.2,1),
                border-color 0.4s,
                box-shadow 0.4s,
                color 0.4s,
                height 0.3s;
}
.site-header.is-scrolled {
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom-color: rgba(0, 0, 0, 0.06);
    box-shadow: 0 2px 18px rgba(0, 0, 0, 0.06);
    color: var(--color-text);
    height: 70px;
}

/* ---------- Dark Text variant (page-view : 흰 배경 페이지에서 텍스트만 블랙) ---------- */
body.page-view .site-header,
body.page-view .site-header.is-scrolled {
    background: rgba(255, 255, 255, 0.96) !important;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom-color: rgba(0, 0, 0, 0.06);
    box-shadow: 0 2px 18px rgba(0, 0, 0, 0.06);
    color: var(--color-text) !important;
}
body.page-view .site-header .site-header__logo img {
    filter: none !important;
}
body.page-view .site-header .gnb__link,
body.page-view .site-header .gnb__link .gnb__name,
body.page-view .site-header:not(.is-scrolled) .gnb__link,
body.page-view .site-header:not(.is-scrolled) .gnb__link .gnb__name {
    color: var(--color-text) !important;
    text-shadow: none !important;
    font-weight: 600;
}
body.page-view .site-header .gnb__item:hover .gnb__link,
body.page-view .site-header .gnb__item:hover .gnb__link .gnb__name {
    color: var(--color-primary) !important;
}
body.page-view .site-header .gnb__link::after {
    background: var(--color-primary) !important;
}
.site-header__inner {
    height: 100%;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 32px;
    margin: 0 auto;
    padding: 0 48px;
    max-width: var(--container-max);
}
.site-header__inner > .gnb { justify-self: center; }
.site-header__inner > .site-header__cta { justify-self: end; }

/* 우측 외부 링크 (모두의 창업) */
.site-header__cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: inherit;
    font-size: 20px;
    font-weight: 600;
    letter-spacing: -0.01em;
    text-decoration: none;
    padding: 28px 0;
    line-height: 1.2;
    transition: color 0.3s, opacity 0.3s, text-shadow 0.3s;
}
.site-header__cta-arrow {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    transition: transform 0.35s cubic-bezier(.4,0,.2,1);
}
.site-header__cta:hover .site-header__cta-arrow {
    transform: translate(3px, -3px);
}
.site-header:not(.is-scrolled) .site-header__cta {
    color: rgba(255, 255, 255, 0.92);
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.35);
    font-weight: 700;
}
.site-header:not(.is-scrolled) .site-header__cta:hover { color: #fff; }
body.page-view .site-header .site-header__cta,
body.page-view .site-header:not(.is-scrolled) .site-header__cta {
    color: var(--color-text) !important;
    text-shadow: none !important;
}
.site-header.is-scrolled .site-header__cta:hover { color: var(--color-primary); }
.site-header__logo {
    display: inline-flex;
    align-items: center;
    padding-top: 0;
    transition: padding-top 0.3s;
}
.site-header.is-scrolled .site-header__logo { padding-top: 0; }
.site-header__logo img {
    height: 52px;
    filter: brightness(0) invert(1);
    transition: filter 0.45s, height 0.3s;
}
.site-header.is-scrolled .site-header__logo img {
    filter: none;
    height: 44px;
}
/* sub02(모두의 창업) 풀 로고는 가로가 길어 높이를 줄여 균형 맞춤 */
body.page-modoo .site-header__logo { padding-top: 0px; }
body.page-modoo .site-header.is-scrolled .site-header__logo { padding-top: 0px; }
body.page-modoo .site-header__logo img {
    height: 38px;
}
body.page-modoo .site-header.is-scrolled .site-header__logo img {
    height: 32px;
}

/* ------------------------------------------ GNB */
.gnb__list {
    display: flex;
    gap: 56px;
}
.gnb__item {
    position: relative;
}
.gnb__link {
    display: inline-block;
    padding: 30px 2px;
    font-weight: 500;
    font-size: 20px;
    color: inherit;
    line-height: 1.2;
    letter-spacing: -0.01em;
    position: relative;
    transition: color 0.3s, text-shadow 0.3s, opacity 0.3s;
}
/* 투명 헤더(영상/다크 BG 위) - 가독성 보강 */
.site-header:not(.is-scrolled) .gnb__link {
    color: rgba(255, 255, 255, 0.92);
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.35);
    font-weight: 600;
}
.site-header:not(.is-scrolled) .gnb__item:hover .gnb__link,
.site-header:not(.is-scrolled) .gnb__item--active .gnb__link {
    color: #fff;
}
.site-header:not(.is-scrolled) .site-header__logo img {
    filter: brightness(0) invert(1) drop-shadow(0 1px 8px rgba(0,0,0,0.3));
}
.gnb__name {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}
.gnb__name-en { display: none; } /* 심플 톤 */

/* Innogrid eduBtn 스타일 45° 화살표 */
.gnb__name::after { display: none; }
.gnb__link:hover .gnb__name::after,
.gnb__item--active .gnb__link .gnb__name::after {
    opacity: 1;
    transform: translate(3px, -3px);
}

.gnb__link::after {
    content: "";
    position: absolute;
    left: 0; right: 0;
    bottom: 22px;
    height: 2px;
    background: #fff;
    opacity: 0;
    transform: scaleX(0);
    transform-origin: center;
    transition: opacity 0.3s,
                transform 0.4s cubic-bezier(.4,0,.2,1),
                background 0.3s;
}
.site-header.is-scrolled .gnb__link::after {
    background: var(--color-primary);
}
.gnb__item:hover .gnb__link::after {
    opacity: 1;
    transform: scaleX(1);
}
.site-header.is-scrolled .gnb__link:hover {
    color: var(--color-primary);
}
.gnb__item--active .gnb__link { color: inherit; }

/* ---------- Dropdown ---------- */
.gnb__sub {
    display: none;
    position: absolute;
    top: calc(100% - 4px);
    left: 50%;
    transform: translateX(-50%) translateY(8px);
    min-width: 240px;
    padding: 12px 0;
    background: #fff;
    border: 0;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
    border-radius: 14px;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.3s, visibility 0.3s, transform 0.35s cubic-bezier(.4,0,.2,1);
}
.gnb__item:hover .gnb__sub {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateX(-50%) translateY(0);
}
.gnb__sub-item { list-style: none; }
.gnb__sub-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 13px 26px;
    font-size: 15px;
    font-weight: 500;
    color: var(--color-text);
    text-align: left;
    white-space: nowrap;
    text-shadow: none;
    transition: background 0.25s, color 0.25s, padding-left 0.3s;
}
.gnb__sub-link::after {
    content: "";
    width: 14px;
    height: 1px;
    background: currentColor;
    opacity: 0;
    margin-left: 18px;
    transform: translateX(-8px);
    transition: opacity 0.3s, transform 0.3s;
}
.gnb__sub-link:hover {
    background: var(--color-primary-light);
    color: var(--color-primary);
    padding-left: 34px;
}
.gnb__sub-link:hover::after {
    opacity: 1;
    transform: translateX(0);
}

/* ------------------------------------------ Mobile GNB (햄버거 / 드로어) */
.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 42px;
    height: 42px;
    padding: 0;
    margin-left: 4px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: inherit;
    cursor: pointer;
    justify-self: end;
}
.nav-toggle__bar {
    display: block;
    width: 22px;
    height: 2px;
    margin: 0 auto;
    border-radius: 2px;
    background: currentColor;
    transition: transform 0.3s cubic-bezier(.4,0,.2,1), opacity 0.2s;
}
.site-header:not(.is-scrolled) .nav-toggle { color: #fff; }
body.page-view .site-header .nav-toggle,
body.page-view .site-header:not(.is-scrolled) .nav-toggle { color: var(--color-text); }
.nav-toggle.is-active .nav-toggle__bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-active .nav-toggle__bar:nth-child(2) { opacity: 0; }
.nav-toggle.is-active .nav-toggle__bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.gnb__mobile-head,
.gnb__mobile-cta { display: none; }

.gnb-backdrop {
    position: fixed;
    inset: 0;
    z-index: 120;
    background: rgba(10, 16, 32, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}
body.is-nav-open .gnb-backdrop { opacity: 1; visibility: visible; }
body.is-nav-open .site-header { z-index: 130; }
body.is-nav-open { overflow: hidden; }

/* ------------------------------------------ Breadcrumb */
.breadcrumb-wrap {
    margin: 24px auto 0;
    padding: 0 24px;
}
.breadcrumb {
    display: flex;
    gap: 8px;
    font-size: 14px;
    color: var(--color-secondary);
}
.breadcrumb-item + .breadcrumb-item::before {
    content: "›";
    margin-right: 8px;
    color: var(--color-secondary);
}
.breadcrumb-item--active {
    color: var(--color-primary);
    font-weight: 600;
}

/* ------------------------------------------ Site Footer */
.site-footer {
    background: #0d1b2a;
    color: #c7ccd3;
    padding: 48px 0;
    margin-top: 0px;
}
.site-footer--main {
    background: transparent;
    color: rgba(255,255,255,0.65);
    margin-top: 0;
    padding: 24px 0;
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    text-align: center;
    z-index: 6;
    font-size: 12px;
    letter-spacing: 0.02em;
    pointer-events: none;
}
.site-footer--main a { pointer-events: auto; }
.site-footer--main .site-footer__copy {
    font-size: 11px;
    opacity: 0.55;
    margin-top: 4px;
}
.site-footer__inner {
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    flex-wrap: wrap;
}
.site-footer--main .site-footer__inner {
    display: block;
    text-align: center;
}
.site-footer__logo { height: 48px; opacity: 0.95; }
body.page-modoo .site-footer__logo { height: 32px; }
.site-footer__info { margin: 0; font-size: 14px; }
.site-footer__dot { margin: 0 10px; opacity: 0.5; }
.site-footer__copy { margin: 8px 0 0; font-size: 13px; opacity: 0.7; }

/* ------------------------------------------ Sub Visual (HD CTA 스타일) */
.sub-visual {
    position: relative;
    min-height: 520px;
    padding: 140px 0 108px;
    text-align: center;
    color: #fff;
    overflow: hidden;
    background: #001a40;
    display: flex;
    align-items: center;
}
.sub-visual__bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
}
.sub-visual__bg img {
    width: 100%; height: 100%;
    object-fit: cover;
    filter: brightness(0.65) saturate(0.9);
}
.sub-visual__overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(135deg, rgba(0,51,115,0.75) 0%, rgba(0,20,60,0.92) 100%);
}
.sub-visual__inner {
    position: relative;
    z-index: 2;
    margin: 0 auto;
    padding: 0 48px;
    width: 100%;
    text-align: center;
}

/* 라벨 (좌측 라인 + 영문 대문자) */
.sub-visual__label {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-size: 12px;
    letter-spacing: 0.35em;
    color: rgba(255,255,255,0.85);
    font-weight: 600;
    margin: 0 0 24px;
    text-transform: uppercase;
}
.sub-visual__label::before {
    content: "";
    width: 28px;
    height: 1px;
    background: #fff;
}

/* 기존 en 배지도 라벨처럼 치환 렌더되도록 fallback 스타일 */
.sub-visual__en {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-size: 12px;
    letter-spacing: 0.35em;
    color: rgba(255,255,255,0.85);
    font-weight: 600;
    margin: 0 0 24px;
    text-transform: uppercase;
    padding: 0;
    border: 0;
    background: transparent;
}
.sub-visual__en::before {
    content: "";
    width: 28px;
    height: 1px;
    background: #fff;
}

.sub-visual__title {
    font-size: clamp(36px, 4.5vw, 64px);
    color: #fff;
    margin: 0 0 24px;
    line-height: 1.1;
    font-weight: 800;
    letter-spacing: -0.03em;
}
.sub-visual__title em {
    font-style: normal;
    background: linear-gradient(90deg, #ffffff 0%, rgba(255,255,255,0.6) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.sub-visual__desc {
    font-size: 17px;
    color: rgba(255,255,255,0.85);
    margin: 0 auto;
    max-width: 640px;
    line-height: 1.7;
    font-weight: 300;
}

/* CTA 버튼 그룹 */
.sub-visual__ctas {
    display: inline-flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 40px;
}
.sub-visual__cta {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    padding: 16px 36px 16px 30px;
    background: #fff;
    color: var(--color-text);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    border-radius: 999px;
    transition: background 0.3s, color 0.3s, transform 0.3s, border-color 0.3s;
    border: 1px solid transparent;
}
.sub-visual__cta:hover {
    background: var(--color-primary);
    color: #fff;
    transform: translateY(-2px);
}
.sub-visual__cta svg { transition: transform 0.3s; }
.sub-visual__cta:hover svg { transform: translateX(4px); }

.sub-visual__cta--outline {
    background: transparent;
    color: #fff;
    border-color: rgba(255,255,255,0.6);
}
.sub-visual__cta--outline:hover {
    background: #fff;
    color: var(--color-text);
    border-color: #fff;
}

/* 대형 배경 넘버 */
.sub-visual__num {
    position: absolute;
    right: 6vw;
    bottom: -1.2vw;
    z-index: 2;
    font-size: clamp(120px, 18vw, 280px);
    font-weight: 900;
    color: transparent;
    -webkit-text-stroke: 1px rgba(255,255,255,0.15);
    pointer-events: none;
    line-height: 0.85;
    letter-spacing: -0.04em;
    font-variant-numeric: tabular-nums;
}

/* ------------------------------------------ Responsive */
@media (max-width: 1280px) {
    .site-header__inner { padding: 0 32px; }
    .gnb__list { gap: 36px; }
}
@media (max-width: 1024px) {
    .site-header__inner { padding: 0 24px; }
    .gnb__list { gap: 24px; }
    .gnb__link { font-size: 15px; padding: 26px 2px; }
    .gnb__link::after { bottom: 18px; }
    .sub-visual { min-height: 440px; padding: 100px 0 80px; }
    .sub-visual__desc { font-size: 16px; }
    .sub-visual__inner { padding: 0 32px; }
}
@media (max-width: 768px) {
    .site-header { height: 64px; }
    .site-header.is-scrolled { height: 56px; }
    .site-header__inner { grid-template-columns: 1fr auto; gap: 12px; }
    /* 모바일 드로어가 있는 헤더에서만 상단 CTA 숨김 (모두의 창업 헤더는 유지) */
    .site-header__actions--has-mnav { display: none !important; }
    .nav-toggle { display: flex; }
    .site-header__cta { font-size: 14px; padding: 20px 0; gap: 6px; }
    .site-header__cta-arrow { width: 14px; height: 14px; }

    /* --- 드로어 --- */
    .gnb {
        /* .site-header 가 backdrop-filter 를 쓰므로 fixed 의 컨테이닝 블록이 헤더(64px)가 된다.
           bottom:0 대신 뷰포트 높이를 직접 지정해 상단부터 전체 높이를 차지하게 한다. */
        position: fixed;
        top: 0;
        right: 0;
        z-index: 110;
        display: flex;
        flex-direction: column;
        width: min(320px, 86vw);
        height: 100vh;
        height: 100dvh;
        max-height: 100vh;
        max-height: 100dvh;
        padding: 0 0 calc(24px + env(safe-area-inset-bottom));
        background: #fff;
        box-shadow: -8px 0 32px rgba(0, 0, 0, 0.16);
        transform: translateX(100%);
        visibility: hidden;
        overflow-y: auto;
        overscroll-behavior: contain;
        transition: transform 0.35s cubic-bezier(.4,0,.2,1), visibility 0.35s;
    }
    body.is-nav-open .gnb { transform: translateX(0); visibility: visible; }

    .gnb__mobile-head {
        display: flex;
        flex: 0 0 auto;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        height: 64px;
        padding: 0 16px 0 20px;
        border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    }
    .gnb__mobile-logo { height: 32px; width: auto; }
    .gnb__close {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        padding: 0;
        border: 0;
        border-radius: 10px;
        background: transparent;
        color: var(--color-text);
        cursor: pointer;
    }
    .gnb__close svg { width: 22px; height: 22px; }

    .gnb__list {
        display: block;
        flex: 1 1 auto;
        gap: 0;
        margin: 0;
        padding: 8px 0;
        list-style: none;
    }
    .gnb__item { border-bottom: 1px solid rgba(0, 0, 0, 0.05); }
    .gnb__link {
        display: block;
        padding: 16px 20px;
        font-size: 16px;
        font-weight: 600;
        color: var(--color-text) !important;
        text-shadow: none !important;
    }
    .gnb__link::after { display: none; }
    .gnb__name { font-size: inherit; }
    .gnb__item--active .gnb__link,
    .gnb__link:active { color: var(--color-primary) !important; }

    .gnb__mobile-cta {
        display: inline-flex;
        flex: 0 0 auto;
        align-items: center;
        justify-content: center;
        gap: 8px;
        margin: 16px 20px 0;
        padding: 14px 18px;
        border-radius: 999px;
        background: #004182;
        color: #fff;
        font-size: 15px;
        font-weight: 700;
        text-decoration: none;
    }
    .gnb__mobile-cta svg { width: 16px; height: 16px; }

    /* 드로어 안에서는 페이지별 헤더 색상 override 무효화 */
    body.page-view .site-header .gnb__link,
    body.page-view .site-header .gnb__link .gnb__name,
    body.page-view .site-header:not(.is-scrolled) .gnb__link,
    body.page-view .site-header:not(.is-scrolled) .gnb__link .gnb__name,
    .site-header:not(.is-scrolled) .gnb__link { color: var(--color-text) !important; }
    .sub-visual { min-height: 380px; padding: 80px 0 64px; }
    .sub-visual__cta { padding: 12px 24px 12px 22px; font-size: 12px; }
    .site-footer__inner { flex-direction: column; text-align: center; }
}
