input[type="radio"],
input[type="checkbox"] {
    display: none;
}

.is-hidden {
    display: none !important;
}

#mapContainer,
#three-container {
    position: fixed;
    z-index: 0;
    width: 100vw;
    height: 100dvh;
    background: #eee;
}

#three-container canvas {
    display: block;
    touch-action: none;
}

.viewer-stack {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.viewer-stack>#three-container {
    position: relative;
    flex: 1 1 auto;
    width: 100%;
    height: auto;
    min-height: 0;
    overflow: hidden;
    z-index: 0;
}

#three-container>.split-slider__ {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 1.5rem;
    transform: translateX(-50%);
    z-index: 250;
    cursor: ew-resize;
    touch-action: none;
}

#three-container>.split-slider__::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0.125rem;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 0 0.25rem rgba(0, 0, 0, 0.5);
}

#three-container>.split-slider__>.handle {
    position: absolute;
    top: 4rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: stretch;
    gap: 0.25rem;
    height: 1.75rem;
    padding: 0.1875rem;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 1.5rem;
    user-select: none;
    font-size: 0.75rem;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    z-index: 2;
    border: 0.0625rem solid #aaa;
}

#three-container>.split-slider__>.handle>.lbl {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
    padding: 0 0.6rem;
    max-width: 11rem;
    overflow: hidden;
    text-overflow: ellipsis;
    border-radius: 1.25rem;
}

#three-container>.split-slider__>.handle>.lbl.--a {
    background: var(--color-blue);
    justify-content: flex-end;
}

#three-container>.split-slider__>.handle>.lbl.--b {
    background: var(--color-purple);
    justify-content: flex-start;
}

#three-container>.split-slider__>.handle>.arr {
    flex: 0 0 auto;
    width: 1.5rem;
    background: url('/img/split-arrow_111.svg') no-repeat center / 1.125rem;
}

.--mono {
    font-family: "JetBrains Mono", monospace;
}

.--scroll-bar::-webkit-scrollbar {
    width: 0.5rem;
    height: 0.5rem;
}

.--scroll-bar::-webkit-scrollbar-track {
    background: transparent;
}

.--scroll-bar::-webkit-scrollbar-thumb {
    border: 0.125rem solid transparent;
    border-radius: 0.25rem;
    background-color: #aaa;
    background-clip: padding-box;
}

.--scroll-bar::-webkit-scrollbar-thumb:hover {
    background-color: #555;
    cursor: pointer;
}

iframe {
    border: none;
}

.schedule-plan__>iframe,
.progress-plan__>iframe {
    outline: 0.0625rem solid var(--primary-lv-7);
}

.model__,
.schedule-plan__,
.progress-plan__,
.design-review__,
.detail-design__,
.construction-schedule__,
.safety__,
.quality__,
.environment__ {
    display: none;
}

.document-section__>.preview__>iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

body:has(.nav>.model input:checked) .model__,
body:has(.nav>.drawing input:checked) .model__,
body:has(.nav>.instruction input:checked) .model__,
body:has(.nav>.in-progress input:checked) .model__,
body:has(.nav>.design-section input:checked) .model__,
body:has(.nav>.schedule-plan input:checked) .schedule-plan__,
body:has(.nav>.progress-plan input:checked) .progress-plan__,
body:has(.construction>.design-review input:checked) .design-review__,
body:has(.construction>.detail-design input:checked) .detail-design__,
body:has(.construction>.construction-schedule input:checked) .construction-schedule__,
body:has(.construction>.safety input:checked) .safety__,
body:has(.construction>.quality input:checked) .quality__,
body:has(.construction>.environment input:checked) .environment__,
body:has(.nav>.construction-report input:checked) .construction-report__,
body:has(.nav>.geotechnical-investigation-report input:checked) .geotechnical-investigation-report__ {
    display: flex;
}

.header__ {
    position: fixed;
    top: 0;
    width: 100dvw;
    background: var(--primary-lv-5);
    display: flex;
    align-items: center;
    border-bottom: 0.0625rem solid var(--primary-lv-7);

    >.project {
        display: flex;
        align-items: center;
        padding: 0 1rem;
        min-width: 25.5rem;
        max-width: 25.5rem;
        border-right: 0.0625rem solid var(--primary-lv-7);
        height: 2.75rem;
    }

    >.project>.logo {
        background: url('../img/logo.svg') no-repeat center / contain;
        min-height: 2.25rem;
        min-width: 13.125rem;
    }

    >.project>.logo:hover {
        cursor: pointer;
    }

    >.project>.subtitle {
        color: var(--primary-lv-3);
        /* padding-left: 0.5rem; */
    }

    >.project>.arrow {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -6.25rem -12.5rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.project>.title>.label {
        color: #fff;
    }

    >.project>.title {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        justify-content: space-between;
        flex: 1;
    }

    >.project>.title>.info {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
        border: none;
        outline: 0.0625rem solid var(--primary-lv-7);
        background: var(--primary-lv-5);
        cursor: pointer;
        margin-left: auto;
    }

    >.project>.title>.info:hover {
        background: var(--primary-lv-6);
    }

    >.project>.title>.info:active {
        background: var(--primary-lv-7);
    }

    >.project>.title>.info>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -6.25rem 0;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.project>.title>.info>.label {
        color: #fff;
    }

    /* 버전 드롭다운(착공전/시공중) — 타이틀 구역(.project, 고정 폭) 오른쪽, .info 와 같은 알약 모양.
       자리가 모자라면(sub 의 긴 부재명) 이름이 말줄임으로 줄어든다 — 전체 이름은 마우스를 올리면(title) */
    >.project>.title {
        min-width: 0;
    }

    >.project>.title>.label {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    >.project>.version {
        flex: none;
        margin-left: 0.25rem;
        padding: 0.125rem 0.5rem;
        border-radius: 0.75rem;
        border: none;
        outline: 0.0625rem solid var(--primary-lv-7);
        background: var(--primary-lv-5);
        color: #fff;
        font: inherit;
        font-size: 0.875rem;
        cursor: pointer;
    }

    >.project>.version:hover {
        background: var(--primary-lv-6);
    }

    >.project>a {
        display: flex;
        align-items: center;
        gap: 0.25rem;
    }

    >.project>a>.info {
        background-color: transparent;
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -6.25rem 0;
        background-repeat: no-repeat;
        min-height: 1.25rem;
        min-width: 1.25rem;
        cursor: pointer;
    }

    >.nav {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        padding: 0.5rem 1rem;
        flex-grow: 1;
        border-right: 0.0625rem solid var(--primary-lv-7);
    }

    >.nav>.divider {
        flex: 0 0 auto;
        align-self: stretch;
        width: 0.0625rem;
        margin: -0.5rem 0.25rem;
        background: var(--primary-lv-7);
    }

    >.nav>button {
        display: flex;
        align-items: center;
        padding: 0.25rem 0.75rem;
        border: none;
        border-radius: 0.75rem;
        outline: 0.0625rem solid var(--primary-lv-7);
        background-color: transparent;
        cursor: pointer;
    }

    >.nav>button>.label {
        color: #fff;
    }

    >.nav>button:hover {
        background-color: var(--primary-lv-6);
    }

    >.nav>button:active {
        background-color: var(--primary-lv-7);
    }

    >.nav>button.--active {
        background-color: #fff;
        cursor: default;
    }

    >.nav>button.--active>.label {
        color: var(--primary-lv-5);
    }

    /* 공종 탭(_drawWorkTypeButtons 동적 생성) — allnew-aside__ 세그먼트로 이동해 nav 에선 숨김.
       버튼 자체는 남아 있어 기존 자동 클릭·배선(테마 폴더 로드)은 그대로 동작한다. */
    >.nav>.work-type {
        display: none;
    }

    >.nav>.layers {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        margin-left: auto;
    }

    >.nav>.layers::before {
        content: '';
        align-self: stretch;
        width: 0.0625rem;
        margin: -0.5rem 0.5rem;
        background: var(--primary-lv-7);
    }

    >.nav>.layers>.title {
        color: #fff;
        font-size: 0.75rem;
        line-height: 0.75rem;
        opacity: 0.4;
        flex-shrink: 0;
        margin-right: 0.5rem;   /* gap 0.5rem 과 합쳐 모델 버튼과 1rem 간격 */
    }

    /* 패널(article)의 display:flex 가 UA 의 닫힘 숨김을 이겨버려서 명시적으로 닫힘 상태를 숨긴다 */
    >.nav>.layers>details:not([open])>article {
        display: none;
    }

    >.nav>.layers>details>.button {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
        outline: 0.0625rem solid var(--primary-lv-7);
        background-color: transparent;
        cursor: pointer;
        list-style: none;
    }

    >.nav>.layers>details>.button::-webkit-details-marker {
        display: none;
    }

    >.nav>.layers>details>.button:hover {
        background-color: var(--primary-lv-6);
    }

    >.nav>.layers>details>.button:active {
        background-color: var(--primary-lv-7);
    }

    >.nav>.layers>details>.button>.label {
        color: #fff;
        white-space: nowrap;
    }

    >.nav>.layers>details[open]>.button {
        background-color: #fff;
    }

    >.nav>.layers>details[open]>.button:hover {
        background-color: var(--primary-lv-0);
    }

    >.nav>.layers>details[open]>.button:active {
        background-color: var(--primary-lv-1);
    }

    >.nav>.layers>details[open]>.button>.label {
        color: var(--primary-lv-5);
    }

    >.nav>.layers>details>.button>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.nav>.layers>.model>.button>.icon {
        background-position: -1.25rem 0;
    }

    >.nav>.layers>.drawing>.button>.icon {
        background-position: -22.5rem 0;
    }

    >.nav>.layers>.map>.button>.icon {
        background-position: -23.75rem 0;
    }

    >.nav>.layers>.model[open]>.button>.icon {
        background-position: -1.25rem -35rem;
    }

    >.nav>.layers>.drawing[open]>.button>.icon {
        background-position: -11.25rem -35rem;
    }

    >.nav>.layers>.map[open]>.button>.icon {
        background-position: -10rem -35rem;
    }

    /* theme — 레이어즈를 design 과 profile 사이 별도 nav(.--layers)로 배치(index 는 좌측 nav 안).
       좌측 nav 만 남은 폭을 차지하고, 구분선은 design 의 border-right 를 그대로 쓴다 */
    >.nav.--layers {
        flex-grow: 0;
    }

    >.nav.--layers>.layers::before {
        display: none;
    }

    /* 하위 items 미준비 공종(토공/배수공/포장공/부대공) — 클릭 차단 */
    >.nav>.work-type.--disabled {
        opacity: 0.4;
        pointer-events: none;
    }

    >.nav>label {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
        outline: 0.0625rem solid var(--primary-lv-7);
        background: var(--primary-lv-5);
    }

    >.nav>label:hover {
        background: var(--primary-lv-6);
        cursor: pointer;
    }

    >.nav>label:active {
        background: var(--primary-lv-7);
    }

    >.nav>label>.label {
        color: #fff;
    }

    >.nav>label:has(input:checked) {
        background: #fff;
    }

    >.nav>label:has(input:checked)>.label {
        color: var(--primary-lv-5);
    }

    >.nav>.model>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -1.25rem 0;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.nav>.model:has(input:checked)>.icon {
        background-position: -17.5rem -15rem;
    }

    >.nav>.schedule-plan>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -11.25rem 0;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.nav>.schedule-plan:has(input:checked)>.icon {
        background-position: -2.5rem -15rem;
    }

    >.nav>.progress-plan>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -7.5rem 0;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.nav>.progress-plan:has(input:checked)>.icon {
        background-position: -27.5rem -15rem;
    }

    >.construction {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        padding: 0.5rem 1rem;
        background: #1B7198;
        border-right: 0.0625rem solid var(--primary-lv-7);
        flex-shrink: 1;
        min-width: 0;
    }

    >.construction>.title {
        color: #fff;
        padding-right: 0.5rem;
        font-size: 0.75rem;
        line-height: 0.75rem;
        opacity: 0.4;
        flex-shrink: 0;
    }

    >.construction>.construction-track {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        min-width: 0;
        flex-shrink: 1;
        overflow-x: hidden;
        scroll-behavior: smooth;
    }

    >.construction>.construction-track>label {
        display: flex;
        align-items: center;
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
        outline: 0.0625rem solid #17546A;
        background: #1B5F74;
        flex-shrink: 0;
    }

    >.construction>.construction-track>label:hover {
        background: #17546A;
        cursor: pointer;
    }

    >.construction>.construction-track>label:active {
        background: #1B343C;
    }

    >.construction>.construction-track>label>.label {
        color: #fff;
        white-space: nowrap;
    }

    >.construction>.construction-track>label:has(input:checked) {
        background: #fff;
    }

    >.construction>.construction-track>label:has(input:checked)>.label {
        color: var(--primary-lv-5);
    }

    >.construction>.header-nav {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        flex-shrink: 0;
    }

    >.design {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        padding: 0.5rem 1rem;
        background: #407342;
        border-right: 0.0625rem solid var(--primary-lv-7);
    }

    >.design>.title {
        color: #fff;
        padding-right: 0.5rem;
        font-size: 0.75rem;
        line-height: 0.75rem;
        opacity: 0.4;
    }

    >.design>a {
        display: flex;
        align-items: center;
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
        outline: 0.0625rem solid #2D5536;
        background: #316040;
        cursor: pointer;
    }

    >.design>a:hover {
        background: #2D5536;
    }

    >.design>a:active {
        background: #243428;
    }

    >.design>a>.label {
        color: #fff;
    }

    >.lang {
        display: flex;
        align-items: center;
        padding: 0.5rem 1rem;
        border-right: 0.0625rem solid var(--primary-lv-7);
    }

    >.lang>.segment {
        display: flex;
        border-radius: 0.75rem;
        outline: 0.0625rem solid var(--primary-lv-7);
    }

    >.lang>.segment>.kr {
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
    }

    >.lang>.segment>.kr:hover {
        background: var(--primary-lv-6);
        cursor: pointer;
    }

    >.lang>.segment>.kr:active {
        background: var(--primary-lv-7);
    }

    >.lang>.segment>.kr>.label {
        color: #fff;
    }

    >.lang>.segment>.kr:has(input:checked) {
        background: #fff;
    }

    >.lang>.segment>.kr:has(input:checked)>.label {
        color: var(--primary-lv-5);
    }

    >.lang>.segment>.en {
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
    }

    >.lang>.segment>.en:hover {
        background: var(--primary-lv-6);
        cursor: pointer;
    }

    >.lang>.segment>.en:active {
        background: var(--primary-lv-7);
    }

    >.lang>.segment>.en>.label {
        color: #fff;
    }

    >.lang>.segment>.en:has(input:checked) {
        background: #fff;
    }

    >.lang>.segment>.en:has(input:checked)>.label {
        color: var(--primary-lv-5);
    }

    >.profile {
        display: flex;
        align-items: center;
        padding: 0.5rem 1rem;
        gap: 0.5rem;
        flex-shrink: 0;
    }

    >.construction>.header-nav>button {
        color: #fff;
        background: #1B5F74;
        border: none;
        cursor: pointer;
        padding: 0.25rem 0.5rem;
        border-radius: 0.5rem;
        font-size: 1.1rem;
        line-height: 1;
    }

    >.construction>.header-nav>button:hover {
        background: #17546A;
    }

    >.construction>.header-nav>button:disabled {
        opacity: 0.35;
        cursor: default;
    }

    >.profile>.name {
        color: #fff;
    }

    >.profile>.logout {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
        outline: 0.0625rem solid var(--primary-lv-7);
        background: var(--primary-lv-5);
    }

    >.profile>.logout>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -2.5rem 0;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.profile>.logout>.label {
        color: #fff;
    }

    >.profile>.logout:hover {
        background: var(--primary-lv-6);
        cursor: pointer;
    }

    >.profile>.logout:active {
        background: var(--primary-lv-7);
    }

    >.profile>.layer {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
        outline: 0.0625rem solid var(--primary-lv-7);
        background: var(--primary-lv-5);
        border: none;
        cursor: pointer;
    }

    >.profile>.layer>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -3.75rem 0;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.profile>.layer>.label {
        color: #fff;
    }

    >.profile>.layer:hover {
        background: var(--primary-lv-6);
    }

    >.profile>.layer:active {
        background: var(--primary-lv-7);
    }

    >.profile>.layer.--active {
        background: #fff;
    }

    >.profile>.layer.--active>.icon {
        background-position: -20rem -15rem;
    }

    >.profile>.layer.--active>.label {
        color: var(--primary-lv-5);
    }

    >.profile>.divider {
        flex: 0 0 auto;
        align-self: stretch;
        width: 0.0625rem;
        margin: -0.5rem 0.25rem;
        background: var(--primary-lv-7);
    }

    >.profile>.sitemap,
    >.profile>.help,
    >.profile>.setting {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem;
        border-radius: 0.75rem;
        outline: 0.0625rem solid var(--primary-lv-7);
        background: var(--primary-lv-5);
        border: none;
        cursor: pointer;
    }

    >.profile>.sitemap>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -21.25rem 0;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.profile>.help>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -5rem 0;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.profile>.setting>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -13.75rem 0;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.profile>.help>.label,
    >.profile>.setting>.label {
        color: #fff;
    }

    >.profile>.sitemap:hover,
    >.profile>.help:hover,
    >.profile>.setting:hover {
        background: var(--primary-lv-6);
    }

    >.profile>.sitemap:active,
    >.profile>.help:active,
    >.profile>.setting:active {
        background: var(--primary-lv-7);
    }

    /* 🟥 index — 객체 버튼(구 사이트맵 자리): 아이콘+라벨 필. 아이콘 = 객체_fff(400,0) */
    >.profile>.object {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
        outline: 0.0625rem solid var(--primary-lv-7);
        background: #1B443D;   /* 🟥 객체 버튼 전용 배경 — CBIM primary 그린 램프의 lv-5 값을 리터럴로(리맵 안 타게) */
        border: none;
        cursor: pointer;
    }

    /* 🟥 배경이 페이지 리맵이 아닌 고정색(#023f3a)이라 hover/active 도 같은 계열 명도 변형으로
       (다른 헤더 버튼과 같은 결 — hover 어둡게, active 더 어둡게) */
    >.profile>.object:hover {
        background: #163631;   /* primary-lv-6 값 */
    }

    >.profile>.object:active {
        background: #102925;   /* primary-lv-7 값 */
    }

    >.profile>.object>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -25rem 0;
        background-repeat: no-repeat;
        /* 🟥 흰색(400,0) 셀을 #dfd5bc 로 틴트 — 검정으로 눌렀다가(brightness 0) 밝기·세피아로 근사(오차 ±2) */
        filter: brightness(0) invert(85%) sepia(40%) brightness(90%);
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.profile>.object>.label {
        color: #dfd5bc;   /* 🟥 객체 버튼 전용 텍스트 컬러(3페이지 공통) */
        font-weight: 800;   /* 🟥 이 버튼만 강조(사용자 지정) */
        white-space: nowrap;
    }

    /* 🟥 index — 설정이 details 로(배경지도 패널 종속): details 자체가 기존 원형 버튼 결(.profile>.setting 공유 규칙),
       서머리는 마커 없는 래퍼. 열림 = 흰 배경 + --main 기어(200,560).
       gap 0 — 크롬이 article 을 ::details-content 로 감싸며 0폭 자식이 생겨, 공유 gap(0.25rem)이 유령 여백을 만든다 */
    >.profile>details.setting {
        gap: 0;
    }

    >.profile>details.setting>summary {
        display: flex;
        cursor: pointer;
        list-style: none;
    }

    >.profile>details.setting>summary::-webkit-details-marker {
        display: none;
    }

    >.profile>details.setting>summary>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -13.75rem 0;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.profile>details.setting[open] {
        background: #fff;
    }

    >.profile>details.setting[open]:hover {
        background: var(--primary-lv-0);
    }

    >.profile>details.setting[open]:active {
        background: var(--primary-lv-1);
    }

    >.profile>details.setting[open]>summary>.icon {
        background-position: -12.5rem -35rem;
    }

    >.profile>details.setting:not([open])>article {
        display: none;
    }
}

/* sub 는 타이틀 구역에 '구조물명 >' 경로까지 있어 고정 폭(25.5rem)에 부재명·버전이 다 안 들어간다 —
   내용만큼 넓힌다(오른쪽 nav 가 flex 로 양보). 화면이 좁으면 다시 줄면서 부재명이 말줄임. */
body.--sub .header__>.project {
    max-width: none;
}

.linear-tools__ {
    position: fixed;
    z-index: 2;
    top: calc(2.75rem + 0.0625rem + 0.75rem);
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.5rem;
}

.linear-tools__>.btn-linear {
    padding: 0.4375rem 0.875rem;
    border-radius: 0.5rem;
    background: #fff;
    outline: 0.0625rem solid #aaa;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #333;
    cursor: pointer;
}

.linear-tools__>.btn-linear:hover {
    background: var(--primary-lv-0);
}

.linear-tools__>.btn-linear.--active {
    background: var(--primary-lv-2);
    color: var(--primary-lv-7);
    outline-color: var(--primary-lv-6);
}

.linear-tools__>.btn-linear:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.model__ {
    >.view-cube__ {
        position: fixed;
        top: calc(2.75rem + 0.0625rem + 0.5rem);
        right: 0.5rem;
        width: 8rem;
        height: 8rem;
        padding: 0;
        border: none;
        background: transparent;
        z-index: 1;
        pointer-events: all;
        cursor: default;

        >.vc-home {
            position: absolute;
            top: 0;
            left: 0;
            display: flex;
            align-items: center;
            justify-content: center;
            width: 1.875rem;
            height: 1.875rem;
            padding: 0;
            border: none;
            border-radius: 50%;
            background: #eeeeee;
            color: #555555;
            opacity: 0;
            pointer-events: none;
            cursor: pointer;
            box-shadow: 0 0.0625rem 0.25rem rgba(0, 0, 0, 0.25);
            transition: opacity 0.15s, color 0.15s, background 0.15s;

            >svg {
                width: 1.125rem;
                height: 1.125rem;
            }

            &:hover {
                color: #111111;
                background: #dddddd;
            }
        }

        &:hover>.vc-home {
            opacity: 1;
            pointer-events: auto;
        }
    }

    >.compass__ {
        display: flex;
        position: fixed;
        z-index: 1;
        top: calc(2.75rem + 0.0625rem + 0.75rem);
        right: 0.75rem;
        width: 6rem;
        height: 6rem;
        padding: 0;
        border: none;
        border-radius: 0;
        background: transparent;
        pointer-events: all;
        cursor: pointer;

        &:hover {
            background: transparent;
        }

        >.graphic {
            width: 100%;
            height: 100%;
            background: url('../img/compass.svg') no-repeat center / contain;
        }

        >.icon {
            display: none;
        }
    }

    >.scale__ {
        position: fixed;
        z-index: 1;
        right: 0.75rem;
        top: calc(2.75rem + 0.0625rem + 50%);
        transform: translate(0, -50%);
        background: #fff;
        border-radius: 1rem;
        outline: 0.0625rem solid #aaa;

        >.zoom-in {
            padding: 0.5rem;
            border-radius: 1rem 1rem 0 0;
            border-bottom: 0.0625rem solid #ddd;
            display: flex;
            background: #fff;
        }

        >.zoom-in:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.zoom-in:active {
            background: var(--primary-lv-1);
        }

        >.zoom-in>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -8.75rem -6.25rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.zoom-out {
            padding: 0.5rem;
            border-radius: 0 0 1rem 1rem;
            border-bottom: 0.0625rem solid #ddd;
            display: flex;
            background: #fff;
        }

        >.zoom-out:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.zoom-out:active {
            background: var(--primary-lv-1);
        }

        >.zoom-out>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -10rem -6.25rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }
    }

    >.aside__ {
        position: fixed;
        z-index: 1;
        left: 0.5rem;
        top: 3.25rem;
        display: flex;
        align-items: center;

        >.contents {
            display: flex;
            flex-direction: column;
            width: var(--panel-w);
            max-height: calc(100dvh - 4.25rem);
            background: #fff;
            border: 0.0625rem solid #aaa;
            border-radius: 1rem;
            box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
            margin-left: calc(-1 * var(--panel-w) - 0.75rem);
            transition: margin-left 0.3s ease, max-height 0.3s ease;
        }

        >.contents:has(>.head>.expand) {
            --panel-w: 12rem;
            transition: margin-left 0.3s ease, width 0.3s ease, max-height 0.3s ease;
        }

        >.contents:has(>.head>.expand input:checked) {
            --panel-w: 19.25rem;
        }

        >.contents>.head {
            display: flex;
            align-items: center;
            padding: 0.5rem 0.5rem 0.5rem 1rem;
            gap: 0.25rem;
            border-bottom: 0.0625rem solid #ddd;
        }

        >.contents>.head.--sub {
            padding: 0.75rem 1rem;
        }

        >.contents>.head>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -22.5rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
            height: 1.25rem;
            width: 1.25rem;
        }

        >.contents>.head>.label {
            margin-right: auto;
            white-space: nowrap;
            font-size: 0.875rem;
        }

        >.contents>.head>.data-icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -3.75rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.contents>.head>.data-label {
            color: var(--primary-lv-5);
            white-space: nowrap;
        }

        >.contents>.head>.bulb {
            display: flex;
            cursor: pointer;
            margin-right: 0.5rem;
        }

        >.contents>.head>.bulb>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -2.5rem -6.25rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.contents>.head>.bulb:has(input:checked)>.icon {
            background-position: -1.25rem -70rem;
        }

        >.contents>.head>.expand {
            display: flex;
            cursor: pointer;
        }

        >.contents>.head>.expand:hover {
            filter: brightness(0.3);
        }

        >.contents>.head>.expand>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -3.75rem -6.25rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.contents>.list {
            display: flex;
            flex-direction: column;
            overflow-y: scroll;
            padding: 1rem 0.5rem 1rem 1rem;
            gap: 0.25rem;
        }

        >.contents>.list>.division-bar {
            margin: 0.5rem 0;
            width: 100%;
            min-height: 0.0625rem;
            background: #ddd;
        }

        >.contents>.list>.division-bar:first-child {
            display: none;
        }

        >.contents>.list:not(.bg-list) {
            flex: 1;
        }

        >.contents>.bg-divider,
        >.contents>.con-divider,
        >.contents>.drn-divider {
            flex: 0 0 auto;
            height: 0.0625rem;
            background: #ddd;
        }

        >.contents>.bg-list {
            min-height: max-content;
        }

        >.contents>.list>.item {
            display: flex;
            align-items: center;
            gap: 0.25rem;
            padding: 0.25rem 0.75rem;
            border-radius: 0.75rem;
        }

        >.contents>.list>.item:not([checked]):hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.contents>.list>.item:not([checked]):active {
            background: var(--primary-lv-1);
        }

        >.contents>.list>.item[checked] {
            background: var(--primary-lv-0);
            outline: 0.0625rem solid var(--primary-lv-5);
        }

        >.contents>.list>.item.--disabled,
        >.contents>.list>.item>.group>.group-item.--disabled {
            opacity: 0.4;
            pointer-events: none;
        }

        >.contents>.list>.item.--select {
            background: var(--primary-lv-0);
            outline: 0.0625rem solid var(--primary-lv-5);
        }

        >.contents>.list>.item>.group>.group-item.--select {
            background: var(--primary-lv-1);
            border-color: var(--primary-lv-5);
        }

        >.contents>.list>.item.--item-group:has(>.group>.group-item:active) {
            background: var(--primary-lv-0);
        }

        >.contents>.list>.item.--item-group {
            flex-direction: column;
            gap: 0.75rem;
        }

        >.contents>.list>.item.--bg:hover {
            cursor: default;
        }

        >.contents>.list>.item.--bg:active {
            background: var(--primary-lv-0);
        }

        >.contents>.list>.item.--model {
            cursor: pointer;
            gap: 0.25rem;
            font-size: 0.875rem;
        }

        >.contents>.list>.item.--model>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -1.25rem -61.25rem;
            background-repeat: no-repeat;
            min-height: 1.25rem;
            min-width: 1.25rem;
            height: 1.25rem;
            width: 1.25rem;
        }

        >.contents>.list>.item.--model[data-type="terrain"]>.icon {
            background-position: -1.25rem -67.5rem;
        }

        >.contents>.list>.item.--model[data-type="drn-cl"]>.icon {
            background-position: -13.75rem -15rem;
        }

        >.contents>.list>.item.--model[data-type="drn-hm"]>.icon {
            background-position: -1.25rem -76.25rem;
        }

        >.contents>.list>.item.--model>.date {
            color: #555;
            font-variant-numeric: tabular-nums;
            white-space: nowrap;
            padding-right: 0.5rem;
        }

        >.contents>.list>.item.--model>.label {
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        >.contents>.list>.item.--model.--selected {
            background: var(--primary-lv-0);
            outline: 0.0625rem solid var(--primary-lv-5);
        }

        &.--split>.contents>.list>.item.--model:hover,
        &.--split>.contents>.list>.item.--model:active,
        &.--split>.contents>.list>.item.--model.--selected {
            border-color: var(--color-blue);
            background: var(--color-blue-light);
            outline-color: var(--color-blue);
        }

        >.contents>.list>.item>.wrap {
            display: flex;
            align-items: center;
            gap: 0.25rem;
            width: 100%;
        }

        >.contents>.list>.item>.group {
            display: grid;
            grid-template-columns: repeat(2, 1fr);
            gap: 0.5rem;
            width: 100%;
        }

        >.contents:has(>.head>.expand input:checked)>.list>.item>.group {
            grid-template-columns: repeat(4, 1fr);
        }

        >.contents>.list>.item>.group>.group-item {
            display: flex;
            background: #fff;
            border: 0.0625rem solid #aaa;
            border-radius: 0.75rem;
            font-size: 0.875rem;
            font-weight: 500;
            padding: 0.25rem 0;
        }

        >.contents>.list>.item>.group>.group-item:hover {
            cursor: pointer;
            background: var(--primary-lv-0);
        }

        >.contents>.list>.item>.group>.group-item:active {
            background: var(--primary-lv-1);
        }

        >.contents>.list>.item>.group>.group-item>.label {
            color: #555;
        }

        >.contents>.list>.item .bulb {
            display: flex;
        }

        >.contents>.list>.item .bulb>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -2.5rem -6.25rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
            cursor: pointer;
        }

        >.contents>.list>.item .bulb:has(input:checked)>.icon {
            background-position: -1.25rem -70rem;
        }

        >.contents>.list>.item.--item-group .bulb>.icon {
            background: url('../img/bulb-off.svg') no-repeat center / contain;
        }

        >.contents>.list>.item.--item-group .bulb:has(input:indeterminate)>.icon {
            background: url('../img/bulb-half.svg') no-repeat center / contain;
        }

        >.contents>.list>.item.--item-group .bulb:has(input:checked)>.icon {
            background: url('../img/bulb-on.svg') no-repeat center / contain;
        }

        >.contents>.list>.item .label {
            flex-grow: 1;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            width: max-content;
        }

        >.contents input[type="range"] {
            -webkit-appearance: none;
            appearance: none;
            width: 5.5rem;
            height: 1rem;
            background: transparent;
            cursor: pointer;
        }

        >.contents input[type="range"]::-webkit-slider-runnable-track {
            height: 0.375rem;
            background: #fff;
            border: 0.0625rem solid #aaa;
            border-radius: 0.25rem;
            overflow: hidden;
        }

        >.contents input[type="range"]::-webkit-slider-thumb {
            -webkit-appearance: none;
            appearance: none;
            height: 0.875rem;
            width: 0.875rem;
            border-radius: 50%;
            background: #fff;
            border: 0.0625rem solid #555;
            margin-top: -0.3125rem;
            box-shadow: -100vmax 0 0 calc(100vmax - 0.5rem) var(--primary-lv-5);
        }

        >.contents>.base-map {
            display: flex;
            align-items: center;
            gap: 0.25rem;
            padding: 0.625rem 0.5rem;
            margin: 0 1rem;
            border-bottom: 0.0625rem solid #ddd;
        }

        >.contents>.base-map .bulb {
            display: flex;
        }

        >.contents>.base-map .bulb>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -2.5rem -6.25rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
            cursor: pointer;
        }

        >.contents>.base-map .bulb:has(input:checked)>.icon {
            background-position: -1.25rem -70rem;
        }

        >.contents>.base-map .label {
            flex-grow: 1;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            width: max-content;
        }

        >.contents>.base-map .act {
            min-height: 1.25rem;
            min-width: 1.25rem;
            background: none;
            pointer-events: none;
        }

        >.contents>.list>.item .act {
            min-height: 1.25rem;
            min-width: 1.25rem;
            cursor: pointer;
            background-color: transparent;
        }

        >.contents>.list>.item .act.--location {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -18.75rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
        }

        >.contents>.list>.item .act.--spacer {
            background: none;
            cursor: default;
            pointer-events: none;
        }

        >.contents>.list>.item input[type="range"],
        >.contents>.base-map input[type="range"],
        >.contents>.list>.item .act,
        >.contents>.base-map .act {
            display: none;
        }

        >.contents:has(>.head>.expand input:checked)>.list>.item input[type="range"] {
            display: block;
        }

        >.contents:has(>.head>.expand input:checked)>.base-map input[type="range"],
        >.contents:has(>.head>.expand input:checked)>.base-map .act {
            display: block;
        }

        >.contents:has(>.head>.expand input:checked)>.list>.item .act {
            display: block;
        }

        >.contents:not(:has(>.head>.expand input:checked))>.head>.data-icon,
        >.contents:not(:has(>.head>.expand input:checked))>.head>.data-label,
        >.contents:not(:has(>.head>.expand input:checked))>.head>.bulb,
        >.contents:not(:has(>.head>.expand input:checked))>.body>.top>.segment,
        >.contents:not(:has(>.head>.expand input:checked))>.body>.top>.list>.item input[type="range"] {
            display: none;
        }

        >.contents>.body {
            display: flex;
            flex-direction: column;
            flex: 1;
            min-height: 0;
            overflow-y: scroll;
            border-radius: 0 0 1rem 1rem;
        }

        >.contents>.body>.top {
            display: flex;
            flex-direction: column;
            gap: 1rem;
            padding: 0.75rem 0.5rem 0.75rem 1rem;
            border-bottom: 0.0625rem solid #ddd;
        }

        >.contents>.body>.top>.segment {
            display: flex;
            align-items: center;
            width: 100%;
            outline: 0.0625rem solid #aaa;
            border-radius: 0.75rem;
        }

        >.contents>.body>.top>.segment>.realism {
            display: flex;
            flex-grow: 1;
            align-items: center;
            justify-content: center;
            padding: 0.25rem;
            border-radius: 0.75rem;
        }

        >.contents>.body>.top>.segment>.realism:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.contents>.body>.top>.segment>.realism:active {
            background: var(--primary-lv-1);
        }

        >.contents>.body>.top>.segment>.realism>.label {
            color: #555;
        }

        >.contents>.body>.top>.segment>.solid {
            display: flex;
            flex-grow: 1;
            align-items: center;
            justify-content: center;
            padding: 0.25rem;
            border-radius: 0.75rem;
        }

        >.contents>.body>.top>.segment>.solid:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.contents>.body>.top>.segment>.solid:active {
            background: var(--primary-lv-1);
        }

        >.contents>.body>.top>.segment>.solid>.label {
            color: #555;
        }

        >.contents>.body>.top>.segment>.wireframe {
            display: flex;
            flex-grow: 1;
            align-items: center;
            justify-content: center;
            padding: 0.25rem;
            border-radius: 0.75rem;
        }

        >.contents>.body>.top>.segment>.wireframe:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.contents>.body>.top>.segment>.wireframe:active {
            background: var(--primary-lv-1);
        }

        >.contents>.body>.top>.segment>.wireframe>.label {
            color: #555;
        }

        >.contents>.body>.top>.segment>.x-ray {
            display: flex;
            flex-grow: 1;
            align-items: center;
            justify-content: center;
            padding: 0.25rem;
            border-radius: 0.75rem;
        }

        >.contents>.body>.top>.segment>.x-ray:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.contents>.body>.top>.segment>.x-ray:active {
            background: var(--primary-lv-1);
        }

        >.contents>.body>.top>.segment>.x-ray>.label {
            color: #555;
        }

        >.contents>.body>.top>.segment>.realism:has(input:checked) {
            background: var(--primary-lv-5);
        }

        >.contents>.body>.top>.segment>.realism:has(input:checked)>.label {
            color: #fff;
        }

        >.contents>.body>.top>.segment>.solid:has(input:checked) {
            background: var(--primary-lv-5);
        }

        >.contents>.body>.top>.segment>.solid:has(input:checked)>.label {
            color: #fff;
        }

        >.contents>.body>.top>.segment>.wireframe:has(input:checked) {
            background: var(--primary-lv-5);
        }

        >.contents>.body>.top>.segment>.wireframe:has(input:checked)>.label {
            color: #fff;
        }

        >.contents>.body>.top>.segment>.x-ray:has(input:checked) {
            background: var(--primary-lv-5);
        }

        >.contents>.body>.top>.segment>.x-ray:has(input:checked)>.label {
            color: #fff;
        }

        >.contents>.body>.top>.list {
            display: flex;
            flex-direction: column;
            gap: 0.25rem;
        }

        >.contents>.body>.top>.list>.division-bar {
            margin: 0.5rem 0;
            width: 100%;
            min-height: 0.0625rem;
            background: #ddd;
        }

        >.contents>.body>.top>.list>.division-bar:first-child {
            display: none;
        }

        >.contents>.body>.top>.list>.item {
            display: flex;
            align-items: center;
            padding: 0.25rem 0.5rem;
            border-radius: 0.75rem;
            gap: 0.25rem;
        }

        >.contents>.body>.top>.list>.item[checked] {
            background: var(--primary-lv-0);
            outline: 0.0625rem solid var(--primary-lv-5);
        }

        >.contents>.body>.top>.list>.item:not([checked]):hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.contents>.body>.top>.list>.item:not([checked]):active {
            background: var(--primary-lv-1);
        }

        >.contents>.body>.top>.list>.item .bulb {
            display: flex;
        }

        >.contents>.body>.top>.list>.item .bulb>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -2.5rem -6.25rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
            cursor: pointer;
        }

        >.contents>.body>.top>.list>.item .bulb:has(input:checked)>.icon {
            background-position: -1.25rem -70rem;
        }

        >.contents>.body>.top>.list>.item .label {
            flex-grow: 1;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            width: max-content;
        }

        >.contents>.body>.top>.list>.item input[type="range"] {
            -webkit-appearance: none;
            appearance: none;
            width: 5.5rem;
            height: 1rem;
            background: transparent;
            cursor: pointer;
        }

        >.contents>.body>.top>.list>.item input[type="range"]::-webkit-slider-runnable-track {
            height: 0.375rem;
            background: #fff;
            border: 0.0625rem solid #aaa;
            border-radius: 0.25rem;
            overflow: hidden;
        }

        >.contents>.body>.top>.list>.item input[type="range"]::-webkit-slider-thumb {
            -webkit-appearance: none;
            appearance: none;
            height: 0.875rem;
            width: 0.875rem;
            border-radius: 50%;
            background: #fff;
            border: 0.0625rem solid #555;
            margin-top: -0.3125rem;
            box-shadow: -100vmax 0 0 calc(100vmax - 0.5rem) var(--primary-lv-5);
        }

        >.contents>.body>.bg-divider {
            flex: 0 0 auto;
            height: 0.0625rem;
            background: #ddd;
        }

        >.contents>.body>.bg-head {
            display: flex;
            align-items: center;
            gap: 0.25rem;
            padding: 0.75rem 0.5rem 0.75rem 1rem;
            border-bottom: 0.0625rem solid #ddd;
        }

        >.contents>.body>.bg-head>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -17.5rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.contents>.body>.bg-head>.label {
            flex-grow: 1;
        }

        >.contents>.body>.bg-list {
            display: flex;
            flex-direction: column;
            gap: 0.25rem;
            padding: 1rem 0.5rem 1rem 1rem;
            border-bottom: 0.0625rem solid #ddd;
        }

        >.contents>.body>.bg-list>.item {
            display: flex;
            align-items: center;
            gap: 0.25rem;
            padding: 0.25rem 0.5rem;
            border-radius: 0.75rem;
        }

        >.contents>.body>.bg-list>.item.--bg {
            cursor: default;
        }

        >.contents>.body>.bg-list>.item.--bg:active {
            background: var(--primary-lv-0);
        }

        >.contents>.body>.bg-list>.item:not([checked]):hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.contents>.body>.bg-list>.item:not([checked]):active {
            background: var(--primary-lv-1);
        }

        >.contents>.body>.bg-list>.item[checked] {
            background: var(--primary-lv-0);
            outline: 0.0625rem solid var(--primary-lv-5);
        }

        >.contents>.body>.bg-list>.item .bulb {
            display: flex;
        }

        >.contents>.body>.bg-list>.item .bulb>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -2.5rem -6.25rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
            cursor: pointer;
        }

        >.contents>.body>.bg-list>.item .bulb:has(input:checked)>.icon {
            background-position: -1.25rem -70rem;
        }

        >.contents>.body>.bg-list>.item .label {
            flex-grow: 1;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            width: max-content;
        }

        >.contents>.body>.bg-list>.item .act {
            min-height: 1.25rem;
            min-width: 1.25rem;
            background: none;
            border: none;
            padding: 0;
            pointer-events: none;
        }

        >.contents:not(:has(>.head>.expand input:checked))>.body>.bg-list>.item input[type="range"] {
            display: none;
        }

        >.contents>.body>#subsObjectInfo>.info>.head {
            display: flex;
            align-items: center;
            gap: 0.25rem;
            padding: 0.75rem 1rem;
            border-bottom: 0.0625rem solid #ddd;
        }

        >.contents>.body>#subsObjectInfo>.info>.wrap {
            display: flex;
            border-bottom: 0.0625rem solid #ddd;
        }

        >.contents>.body>#subsObjectInfo>.info>.wrap>.label {
            color: #555;
            padding: 0.5rem 0 0.5rem 0.75rem;
            min-width: 4.875rem;
            max-width: 4.875rem;
            background: linear-gradient(90deg, #E9EDEC 0%, #FFF 100%);
            height: auto;
        }

        >.contents>.body>#subsObjectInfo>.info>.wrap>.value {
            width: 100%;
            padding: 0.5rem;
        }

        >.contents>.body>#subsObjectInfo>.info>.wrap>.value>p {
            margin: 0;
        }

        >.contents>.body>#subsObjectInfo>.info>.head>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -1.25rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.contents>.simulation {
            margin: auto 1rem 1rem 1rem;
            padding: 0.5rem 0;
            outline: 0.0625rem solid var(--primary-lv-5);
            border-radius: 1rem;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 0.25rem;
        }

        >.contents>.simulation:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.contents>.simulation:active {
            background: var(--primary-lv-1);
        }

        >.contents>.simulation>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -8.75rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.contents>.simulation>.label {
            color: var(--primary-lv-5);
        }

        >.contents>.simulation:has(input:checked) {
            background: var(--primary-lv-5);
        }

        >.contents>.simulation:has(input:checked)>.icon {
            background-position: -15rem 0;
        }

        >.contents>.simulation:has(input:checked)>.label {
            color: #fff;
        }

        >.toggle {
            display: none;
            background: #fff;
            outline: 0.0625rem solid #aaa;
            border-radius: 0 0.75rem 0.75rem 0;
            padding: 1rem 0.25rem;
        }

        >.toggle:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.toggle:active {
            background: var(--primary-lv-1);
        }

        >.toggle>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -11.25rem -6.25rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
            transform: scaleX(-1);
        }

        >.toggle:has(input:checked)>.icon {
            transform: scaleX(1);
        }

        &:has(>.toggle input:checked)>.contents {
            margin-left: 0;
        }
    }

    >.model-info__ {
        display: none;
        flex-direction: column;
        position: fixed;
        z-index: 3;
        right: 0.5rem;
        top: calc(2.75rem + 0.0625rem + 0.5rem);
        background: #fff;
        border: 0.0625rem solid #aaa;
        border-radius: 1rem;
        box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
        width: 17.5rem;

        &.--visible {
            display: flex;
        }

        >.head {
            display: flex;
            align-items: center;
            padding: 0.75rem 1rem;
            gap: 0.25rem;
            border-bottom: 0.0625rem solid #ddd;
        }

        >.head>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -17.5rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.head>.close {
            background-color: transparent;
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -1.25rem -6.25rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
            margin-left: auto;
        }

        >.head>.close:hover {
            cursor: pointer;
        }

        >.body {
            padding: 1rem 0.5rem 1rem 1rem;
            overflow-y: scroll;
            display: flex;
            flex-direction: column;
            gap: 0.5rem;
            max-height: calc(100dvh - 7.5rem);
        }

        >.body>.substantial-object-view {
            padding: 0.5rem 0;
            background: #fff;
            outline: 0.0625rem solid var(--primary-lv-5);
            border-radius: 1rem;
            display: flex;
            justify-content: center;
        }

        >.body>.substantial-object-view:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.body>.substantial-object-view:active {
            background: var(--primary-lv-1);
        }

        >.body>.substantial-object-view>.label {
            color: var(--primary-lv-5);
        }

        >.body>.title {
            color: var(--primary-lv-5);
            padding-top: 0.5rem;
            padding-left: 0.625rem;
            position: relative;
        }

        >.body>.title::after {
            content: '';
            position: absolute;
            top: 0.625rem;
            bottom: 0.125rem;
            left: 0;
            width: 0.1875rem;
            background: var(--primary-lv-5);
        }

        >.body>.wrap {
            display: flex;
            align-items: center;
        }

        >.body>.wrap>.label {
            min-width: 5rem;
            color: #555;
        }

        >.body>.wrap>.value {
            flex-grow: 1;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            width: max-content;
        }
    }

    >.simulation__ {
        position: fixed;
        bottom: 0.75rem;
        display: none;
        background: #fff;
        right: 0.75rem;
        left: 20.75rem;
        transition: left 0.3s ease;
        padding: 0.5rem 1rem;
        align-items: center;
        gap: 0.25rem;
        border-radius: 1rem;
        border: 0.0625rem solid #aaa;
        box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);

        >.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -8.75rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.play {
            display: flex;
            align-items: center;
            gap: 0.25rem;
            background: #fff;
            border: 0.0625rem solid #aaa;
            border-radius: 0.75rem;
            padding: 0.25rem 0.75rem;
            margin-left: 0.5rem;
        }

        >.play>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -5rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.play>.label {
            color: #555;
        }

        >.play:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.play:active {
            background: var(--primary-lv-1);
        }

        >.play:has(input:checked) {
            background: var(--primary-lv-5);
        }

        >.play:has(input:checked)>.icon {
            background-position: -12.5rem 0;
        }

        >.play:has(input:checked)>.label {
            color: #fff;
        }

        >.reset {
            background: #fff;
            border: 0.0625rem solid #aaa;
            border-radius: 0.75rem;
            padding: 0.25rem 0.75rem;
            margin-left: 0.25rem;
        }

        >.reset:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.reset:active {
            background: var(--primary-lv-1);
        }

        >.reset>.label {
            color: #555;
        }

        >input[type="range"] {
            -webkit-appearance: none;
            appearance: none;
            flex-grow: 1;
            height: 1rem;
            background: transparent;
            cursor: pointer;
            margin-left: 0.5rem;
        }

        >input[type="range"]::-webkit-slider-runnable-track {
            height: 0.375rem;
            background: #fff;
            border: 0.0625rem solid #aaa;
            border-radius: 0.25rem;
            overflow: hidden;
        }

        >input[type="range"]::-webkit-slider-thumb {
            -webkit-appearance: none;
            appearance: none;
            height: 0.875rem;
            width: 0.875rem;
            border-radius: 50%;
            background: #fff;
            border: 0.0625rem solid #555;
            margin-top: -0.3125rem;
            box-shadow: -100vmax 0 0 calc(100vmax - 0.5rem) var(--primary-lv-5);
        }

        >.phase {
            margin-left: 0.5rem;
            color: #555;
        }

        >.close {
            background-color: transparent;
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -1.25rem -6.25rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
            cursor: pointer;
        }
    }

    .simulation-chart__ {
        display: none;
        flex-direction: column;
        position: absolute;
        left: 0;
        right: 0;
        bottom: 0;
        /* 기본 높이 = 헤더(2.8125rem) 제외한 뷰포트의 50% — theme/index 공통 */
        height: calc((100dvh - 2.8125rem) * 0.5);
        /* 시트 상단 보더가 헤더(2.75rem+보더) 아랫선에 정확히 붙는 높이가 상한 —
           리사이즈 바 돌출분(1rem)은 헤더를 침범해 그 뒤로 들어간다(헤더 z 100 > 시트 z 2) */
        max-height: calc(100dvh - 2.8125rem);
        transition: height 0.25s ease;
        background: #fff;
        border-top: 0.125rem solid #aaa;
        box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
        overflow: visible;
        z-index: 2;

        &.--visible {
            display: flex;
        }

        &.--dragging {
            transition: none;
        }

        >.resize-bar {
            position: absolute;
            left: 0;
            right: 0;
            top: -1rem;
            height: 1.25rem;
            cursor: ns-resize;
            touch-action: none;
            user-select: none;
            z-index: 4;
        }

        >.resize-bar::after {
            content: '';
            position: absolute;
            left: 50%;
            top: 50%;
            transform: translate(-50%, -50%);
            width: 5rem;
            height: 0.25rem;
            border-radius: 0.125rem;
            background: #fff;
        }

        >.resize-bar:hover::after {
            background: #eee;
        }

        >.resize-bar:active::after {
            background: #aaa;
        }

        &.--collapsed>.tabs,
        &.--collapsed>.body,
        &.--collapsed>.panel {
            visibility: hidden;
            transition: visibility 0s linear 0.25s;
        }

        &.--collapsed {
            border-top-color: transparent;
            box-shadow: none;
            transition: height 0.25s ease, border-top-color 0s linear 0.25s, box-shadow 0s linear 0.25s;
        }

        >.tabs {
            display: flex;
            align-items: center;
            gap: 0.5rem;
            padding: 0.0625rem 1rem 0.5rem 1rem;
            flex: 0 0 auto;
            border-bottom: 0.0625rem solid #aaa;
        }

        >.tabs input {
            display: none;
        }

        >.tabs>label {
            display: flex;
            align-items: center;
            padding: 0.25rem 0.75rem;
            border-radius: 0.75rem;
            outline: 0.0625rem solid #aaa;
            background: #fff;
            cursor: pointer;
        }

        >.tabs>label:hover {
            background: var(--primary-lv-0);
        }

        >.tabs>label:active {
            background: var(--primary-lv-1);
        }

        >.tabs>label>.label {
            color: #555;
        }

        >.tabs>label:has(input:checked) {
            background: var(--primary-lv-5);
        }

        >.tabs>label:has(input:checked)>.label {
            color: #fff;
        }

        >.panel {
            display: none;
            flex: 1 1 auto;
            min-height: 0;
            align-items: center;
            justify-content: center;
            color: #999;
        }

        &:not(:has(.tabs>.simulation input:checked))>.body {
            display: none;
        }

        &:has(.tabs>.profile input:checked)>.panel.--profile {
            display: flex;
        }

        &:has(.tabs>.photo input:checked)>.panel.--photo {
            display: flex;
        }

        &:has(.tabs>.inspect input:checked)>.panel.--inspect {
            display: flex;
        }

        >.panel.--profile {
            position: relative;
            flex-direction: column;
            align-items: stretch;
            justify-content: flex-start;
            padding: 0;
            overflow: hidden;
        }

        >.panel.--profile>.head {
            position: absolute;
            top: 0.75rem;
            left: 0.75rem;
            display: flex;
            align-items: center;
            gap: 0.5rem;
            z-index: 2;
        }

        >.panel.--profile>.head>.title {
            color: #fff;
        }

        >.panel.--profile>.head>.segment {
            display: flex;
            border-radius: 0.8125rem;
            background: #fff;
            border: 0.0625rem solid #aaa;
        }

        >.panel.--profile>.head>.segment input {
            display: none;
        }

        >.panel.--profile>.head>.segment>label {
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 0.25rem 0.5rem;
            border-radius: 0.75rem;
            cursor: pointer;
        }

        >.panel.--profile>.head>.segment>label>.label {
            color: #555;
            font-size: 0.75rem;
            line-height: 1rem;
            letter-spacing: -0.0175rem;
        }

        >.panel.--profile>.head>.segment>label:has(input:checked) {
            background: var(--primary-lv-5);
        }

        >.panel.--profile>.head>.segment>label:has(input:checked)>.label {
            color: #fff;
        }

        /* 데이터 없는 종단 종류(pvertical/tvertical) — themeView 가 input 을 disable */
        >.panel.--profile>.head>.segment>label:has(input:disabled) {
            opacity: 0.4;
            cursor: default;
        }

        >.panel>.plan-canvas {
            flex: 1 1 auto;
            min-height: 0;
            position: relative;
            background: #000;
            overflow: hidden;
        }

        >.panel>.plan-canvas>canvas {
            position: absolute;
            top: 0;
            left: 0;
            display: block;
        }

        >.head {
            display: flex;
            align-items: center;
            gap: 0.25rem;
            padding: 0.5rem 1rem;
            border-bottom: 0.0625rem solid #ddd;
        }

        >.head>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -8.75rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.head>.label {
            color: var(--primary-lv-5);
            font-weight: 700;
        }

        >.head>.play {
            display: flex;
            align-items: center;
            gap: 0.25rem;
            background: #fff;
            border: 0.0625rem solid #aaa;
            border-radius: 0.75rem;
            padding: 0.25rem 0.75rem;
            margin-left: 0.5rem;
        }

        >.head>.play>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -5rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.head>.play>.label {
            color: #555;
        }

        >.head>.play:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.head>.play:active {
            background: var(--primary-lv-1);
        }

        >.head>.play:has(input:checked) {
            background: var(--primary-lv-5);
        }

        >.head>.play:has(input:checked)>.icon {
            background-position: -12.5rem 0;
        }

        >.head>.play:has(input:checked)>.label {
            color: #fff;
        }

        >.head>.reset {
            background: #fff;
            border: 0.0625rem solid #aaa;
            border-radius: 0.75rem;
            padding: 0.25rem 0.75rem;
            margin-left: 0.25rem;
        }

        >.head>.reset:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.head>.reset:active {
            background: var(--primary-lv-1);
        }

        >.head>.reset>.label {
            color: #555;
        }

        >.head>.time {
            margin-left: 0.75rem;
            color: #555;
        }

        >.head>.view-mode {
            margin-left: auto;
            background: #fff;
            border: 0.0625rem solid #aaa;
            border-radius: 0.75rem;
            padding: 0.25rem 0.75rem;
        }

        >.head>.view-mode:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.head>.view-mode:active {
            background: var(--primary-lv-1);
        }

        >.head>.view-mode>.label {
            color: #555;
        }

        >.head>.close {
            background-color: transparent;
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -1.25rem -6.25rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
            margin-left: 0.5rem;
            border: none;
            padding: 0;
            cursor: pointer;
        }

        >.body {
            flex: 1 1 auto;
            min-height: 0;
            display: flex;
            flex-direction: column;
            overflow: hidden;
        }

        >.body>.canvas {
            position: relative;
            width: 100%;
            display: flex;
            flex-direction: column;
            flex: 1 1 auto;
            min-height: 0;
        }

        >.body>.canvas>.table {
            display: flex;
            flex-direction: column;
            flex: 1 1 auto;
            min-height: 0;
            width: 100%;
        }

        >.body>.canvas>.table>colgroup {
            display: none;
        }

        >.body>.canvas>.table>thead {
            display: table;
            width: 100%;
            table-layout: fixed;
            border-spacing: 0;
            flex: 0 0 auto;
        }

        >.body>.canvas>.table>tbody {
            display: block;
            flex: 1 1 auto;
            min-height: 0;
            overflow-y: auto;
            overflow-x: hidden;
            scrollbar-width: none;
        }

        >.body>.canvas>.table>tbody::-webkit-scrollbar {
            width: 0;
            height: 0;
        }

        >.body>.canvas>.table>tbody>tr {
            display: table;
            width: 100%;
            table-layout: fixed;
            border-spacing: 0;
        }

        >.body>.canvas>.sim-vsb {
            position: absolute;
            right: 0;
            width: 0.5rem;
            z-index: 6;
            display: none;
            pointer-events: none;
        }

        >.body>.canvas>.sim-vsb>.sim-vsb__thumb {
            position: absolute;
            top: 0;
            right: 0;
            width: 0.5rem;
            border: 0.125rem solid #aaa;
            border-radius: 0.25rem;
            background-color: rgba(170, 170, 170, 0.6);
            background-clip: padding-box;
            pointer-events: auto;
            cursor: pointer;
        }

        >.body>.canvas>.sim-vsb>.sim-vsb__thumb:hover {
            background-color: rgba(85, 85, 85, 0.6);
        }

        >.body>.canvas>.table>thead>tr>th {
            position: sticky;
            z-index: 3;
            background: #eee;
            padding: 0.25rem;
            text-align: center;
            font-weight: 500;
            font-size: 0.75rem;
            border-right: 0.0625rem solid #ddd;
            border-bottom: 0.0625rem solid #aaa;
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
        }

        >.body>.canvas>.table>thead>tr:first-child>th {
            top: 0;
            height: 1.625rem;
        }

        >.body>.canvas>.table>thead>tr:nth-child(2)>th {
            top: 1.625rem;
            height: 1.375rem;
        }

        >.body>.canvas>.table>thead>tr>th.name {
            top: 0;
            left: 0;
            z-index: 5;
            width: 10rem;
            min-width: 10rem;
            max-width: 10rem;
            text-align: left;
            padding-left: 1rem;
            font-size: 0.875rem;
            border-right: 0.0625rem solid #aaa;
        }

        >.body>.canvas>.table>thead>tr>th.name>.today {
            margin-left: 0.375rem;
            padding: 0.125rem 0.375rem;
            border-radius: 0.75rem;
            outline: 0.0625rem solid #aaa;
            background-color: #fff;
            color: #555;
            font-size: 0.75rem;
            line-height: 1rem;
            cursor: pointer;
        }

        >.body>.canvas>.table>thead>tr>th.name>.today:hover {
            background-color: var(--primary-lv-0);
        }

        >.body>.canvas>.table>thead>tr>th.name>.today:active {
            background-color: var(--primary-lv-1);
        }

        >.body>.canvas>.table>thead>tr>th.year {
            font-weight: 700;
            color: #333;
            border-right: 0.0625rem solid #aaa;
        }

        >.body>.canvas>.table>thead>tr>th.quarter {
            color: #888;
        }

        >.body>.canvas>.table>thead>tr>th.quarter:nth-child(4n) {
            border-right: 0.0625rem solid #aaa;
        }

        >.body>.canvas>.table>tbody>tr>td {
            padding: 0.375rem 0.5rem;
            font-size: 0.875rem;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            border-right: 0.0625rem solid #ddd;
            border-bottom: 0.0625rem solid #ddd;
        }

        >.body>.canvas>.table>tbody>tr>td.name {
            position: sticky;
            left: 0;
            z-index: 4;
            width: 10rem;
            min-width: 10rem;
            max-width: 10rem;
            padding-left: 1rem;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            background: #fff;
            color: #111;
            border-right: 0.0625rem solid #aaa;
        }

        >.body>.canvas>.table>tbody>tr>td.timeline {
            position: relative;
            padding: 0;
            overflow: visible;
            border-right: none;
            background-image: repeating-linear-gradient(to right, transparent 0, transparent calc(100% / var(--quarter-count, 4) - 0.0625rem), #eee calc(100% / var(--quarter-count, 4) - 0.0625rem), #eee calc(100% / var(--quarter-count, 4))), repeating-linear-gradient(to right, transparent 0, transparent calc(100% / var(--year-count, 1) - 0.0625rem), #ccc calc(100% / var(--year-count, 1) - 0.0625rem), #ccc calc(100% / var(--year-count, 1)));
        }

        >.body>.canvas>.table>tbody>tr>td.timeline>.bar {
            position: absolute;
            top: 50%;
            transform: translateY(-50%);
            height: 1.25rem;
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 0 0.25rem;
            border-radius: 0.25rem;
            background: var(--color-green);
            color: #fff;
            font-size: 0.75rem;
            font-weight: 300;
            white-space: nowrap;
            overflow: visible;
            text-shadow: -0.0625rem -0.0625rem 0 rgba(0, 0, 0, 0.85), 0.0625rem -0.0625rem 0 rgba(0, 0, 0, 0.85), -0.0625rem 0.0625rem 0 rgba(0, 0, 0, 0.85), 0.0625rem 0.0625rem 0 rgba(0, 0, 0, 0.85);
        }

        >.body>.canvas>.table>tbody>tr>td.timeline>.bar.--disabled {
            background: #aaa;
        }

        >.body>.canvas>.table>tbody>tr>td.timeline>.bar.--demo {
            background: #f28c28;
        }

        >.body>.canvas>.table>tbody>tr>td.timeline>.bar>.bar-name {
            cursor: pointer;
            border-radius: 0.25rem;
            padding: 0.125rem 0.25rem;
            font-weight: 500;
            color: #111;
            text-shadow: none;
        }

        >.body>.canvas>.table>tbody>tr>td.timeline>.bar>.bar-name:hover {
            background: rgba(255, 255, 255, 0.4);
        }

        >.body>.canvas>.table>tbody>tr>td.timeline>.bar>.bar-name.--disabled {
            cursor: default;
        }

        >.body>.canvas>.table>tbody>tr>td.timeline>.bar>.bar-sep {
            opacity: 0.7;
            pointer-events: none;
            color: #333;
            text-shadow: none;
        }

        /* 공정 막대 — 공정 하나 = 막대 하나. 이웃 공정과 붙어 있어 라벨은 막대 안에서 가운데, 넘치면 말줄임
           (라벨 최대폭 = 막대 폭이라 가운데 정렬이 양쪽으로 잘리지 않는다. 전체는 툴팁). 오른쪽 1px 흰 줄로 이웃과 구분 */
        >.body>.canvas>.table>tbody>tr>td.timeline>.bar.--proc {
            padding: 0;
            overflow: hidden;
            border-radius: 0.125rem;
            box-shadow: inset -0.0625rem 0 0 rgba(255, 255, 255, 0.9);
        }

        >.body>.canvas>.table>tbody>tr>td.timeline>.bar.--proc>.bar-name {
            min-width: 0;
            max-width: 100%;
            overflow: hidden;
            text-overflow: ellipsis;
            padding: 0 0.1875rem;
            font-weight: 400;
        }

        /* 여러 부재 그룹 행(교각·교대) — 이름 칸 클릭 = 접기/펼치기, 펼친 부재 행은 들여쓰기 */
        >.body>.canvas>.table>tbody>tr[data-group]>td.name {
            cursor: pointer;
        }

        >.body>.canvas>.table>tbody>tr[data-group]>td.name::before {
            content: '▶';
            display: inline-block;
            width: 1rem;
            margin-left: -0.75rem;
            font-size: 0.625rem;
            color: #666;
        }

        >.body>.canvas>.table>tbody>tr[data-group].is-open>td.name::before {
            content: '▼';
        }

        >.body>.canvas>.table>tbody>tr.--child>td.name {
            padding-left: 1.75rem;
            color: #555;
        }

        >.body>.canvas>.playhead {
            display: none;
            position: absolute;
            top: 0;
            bottom: 0;
            left: 10rem;
            width: 1.5rem;
            transform: translateX(-50%);
            z-index: 3;
            cursor: ew-resize;
            touch-action: none;
        }

        >.body>.canvas>.playhead::after {
            content: '';
            position: absolute;
            top: 0;
            bottom: 0;
            left: 50%;
            transform: translateX(-50%);
            width: 0.125rem;
            background: var(--color-dahong);
        }

        >.body>.canvas>.playhead::before {
            content: '';
            position: sticky;
            top: 0;
            display: block;
            margin-left: -0.125rem;
            width: 1.75rem;
            height: 1.25rem;
            border-radius: 0.25rem;
            z-index: 1;
            background: url('../img/split-arrow_fff.svg') no-repeat center / 1.0625rem, var(--color-dahong);
        }

        >.body>.canvas>.cmp-marker {
            position: absolute;
            top: 0;
            bottom: 0;
            width: 0.125rem;
            z-index: 3;
            pointer-events: none;
        }

        >.body>.canvas>.cmp-marker>.cap {
            position: sticky;
            top: 0;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            padding: 0 0.375rem;
            height: 1.25rem;
            font-size: 0.6875rem;
            font-weight: 700;
            color: #fff;
            white-space: nowrap;
        }

        >.body>.canvas>.cmp-marker.--now {
            background: #2aa37a;
        }

        >.body>.canvas>.cmp-marker.--now>.cap {
            transform: translateX(-50%);
            border-radius: 0.25rem;
            background: #2aa37a;
        }
    }
}

.document-section__ {
    background: #fff;
    position: fixed;
    top: calc(2.75rem + 0.0625rem);
    bottom: 0;
    width: 100vw;
    display: flex;

    >.article__ {
        display: flex;
        position: fixed;
        top: calc(2.75rem + 0.0625rem);
        bottom: 0;
        left: 15rem;
        right: 0;
        background: #fff;
        flex-direction: column;
        align-items: center;
        justify-content: center;

        >.edit {
            background: #fff;
            position: absolute;
            top: 0.75rem;
            right: 0.75rem;
            border-radius: 0.75rem;
            border: 0.0625rem solid var(--primary-lv-5);
            cursor: pointer;
            padding: 0.5rem;
            display: flex;
        }

        >.edit:hover {
            background: var(--primary-lv-0);
        }

        >.edit:active {
            background: var(--primary-lv-1);
        }

        >.edit>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -16.25rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.notice {
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 1rem;
        }

        >.notice>.example {
            display: flex;
            position: relative;
        }

        >.notice>.example>.label {
            background: #fff;
            color: #555;
            padding: 0.25rem 0.75rem;
            border-radius: 0.75rem;
            border: 0.0625rem solid #aaa;
            position: absolute;
            top: 0.75rem;
            left: 0.75rem;
        }

        >.notice>.example>.image {
            max-width: 50rem;
            max-height: 30rem;
            border: 0.0625rem solid #aaa;
            border-radius: 1rem;
            background: #eee;
        }

        &.--notice-image>.notice {
            width: 100%;
            height: 100%;
        }

        &.--notice-image>.notice>.image {
            width: 100%;
            height: 100%;
            object-fit: contain;
        }

        >.notice-context-menu__ {
            display: none;
            position: absolute;
            top: 3.25rem;
            right: 0.75rem;
            z-index: 10;
            flex-direction: column;
            gap: 0.25rem;
            min-width: 9rem;
            padding: 0.5rem;
            background: #fff;
            border: 0.0625rem solid #aaa;
            border-radius: 1rem;
            box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
        }

        >.notice-context-menu__>button {
            display: flex;
            align-items: center;
            padding: 0.25rem 0.75rem;
            background: #fff;
            border-radius: 0.75rem;
            cursor: pointer;
        }

        >.notice-context-menu__>button:hover {
            background: var(--primary-lv-0);
        }

        >.notice-context-menu__>button>.label {
            color: #555;
        }

        >.notice-context-menu__>button:disabled {
            opacity: 0.5;
            cursor: not-allowed;
        }

        >.notice-context-menu__>button:disabled:hover {
            background: #fff;
        }

        >.notice>.text {
            text-align: center;
            color: #555;
        }

        >.notice>.foot {
            display: flex;
            gap: 0.5rem;
        }

        >.notice>.foot>.download {
            width: 10rem;
            padding: 0.5rem 1rem;
            outline: 0.0625rem solid var(--primary-lv-5);
            border-radius: 1rem;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 0.25rem;
            background: #fff;
            cursor: pointer;
        }

        >.notice>.foot>.download:disabled {
            opacity: 0.5;
            cursor: not-allowed;
        }

        >.notice>.foot>.download:disabled:hover {
            background: #fff;
        }

        >.notice>.foot>.download:hover {
            background: var(--primary-lv-0);
        }

        >.notice>.foot>.download:active {
            background: var(--primary-lv-1);
        }

        >.notice>.foot>.download>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -10rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.notice>.foot>.download>.label {
            color: var(--primary-lv-5);
        }

        >.notice>.foot>.upload {
            width: 10rem;
            padding: 0.5rem 1rem;
            outline: 0.0625rem solid var(--primary-lv-5);
            border-radius: 1rem;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 0.25rem;
            background: var(--primary-lv-5);
            cursor: pointer;
        }

        >.notice>.foot>.upload:hover {
            background: var(--primary-lv-6);
        }

        >.notice>.foot>.upload:active {
            background: var(--primary-lv-7);
        }

        >.notice>.foot>.upload>.label {
            color: #fff;
        }
    }

    >.aside__ {
        min-width: 15rem;
        max-width: 15rem;
        border-right: 0.0625rem solid #aaa;
        padding: 1rem 0.5rem 1rem 1rem;
        display: flex;
        flex-direction: column;
        overflow-y: scroll;

        >.group {
            display: flex;
            flex-direction: column;
            gap: 0.25rem;
        }

        >.group+.group {
            margin-top: 0.5rem;
        }

        >.group>.title {
            cursor: pointer;
            color: var(--primary-lv-5);
        }

        >.group .list {
            display: flex;
            flex-direction: column;
            gap: 0.25rem;
        }

        >.group .list>.item {
            display: flex;
            align-items: center;
            padding: 0.25rem 0.75rem;
            border-radius: 0.75rem;
        }

        >.group .list>.item:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.group .list>.item:active {
            background: var(--primary-lv-1);
        }

        >.group .list>.item[checked] {
            background: var(--primary-lv-0);
            outline: 0.0625rem solid var(--primary-lv-5);
        }

        >.group .list>.item>.label {
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            width: max-content;
            flex-grow: 1;
        }

        >.group .list>.item>.count {
            color: #555;
        }

        /* 묶음(depth2) — 제목 + 그 밑 폴더 목록. 파일이 없어 클릭 대상이 아니다 */
        >.group>.sub-group {
            display: flex;
            flex-direction: column;
            gap: 0.25rem;
            padding-left: 0.5rem;
        }

        >.group>.sub-group+.sub-group {
            margin-top: 0.25rem;
        }

        >.group>.sub-group>.sub-title {
            color: #555;
            font-size: 0.875rem;
            font-weight: 500;
        }

        >.group>.sub-group>.list {
            padding-left: 0.5rem;
        }

        >.division-bar {
            margin: 0.5rem 0;
            width: 100%;
            min-height: 0.0625rem;
            background: #ddd;
        }
    }

    >.file__ {
        flex-grow: 1;
        display: flex;
        flex-direction: column;
        min-width: 0;
        position: relative;

        >.head {
            display: flex;
            align-items: center;
            padding: 0.75rem 3.25rem 0.75rem 1.75rem;
            border-bottom: 0.0625rem solid #ddd;
            gap: 0.25rem;
        }

        /* 헤더 각 열은 클릭 정렬 대상 — 커서와 화살표로 표시.
           드래그로 글자가 잡히지 않게 선택도 막는다 */
        >.head>div {
            cursor: pointer;
            user-select: none;
        }

        >.head>div.--sort-asc::after {
            content: '▲';
            color: var(--primary-lv-6, #555);
            font-size: 0.625rem;
        }

        >.head>div.--sort-desc::after {
            content: '▼';
            color: var(--primary-lv-6, #555);
            font-size: 0.625rem;
        }

        >.head>.name {
            display: flex;
            align-items: center;
            gap: 0.125rem;
            flex-grow: 1;
        }

        >.head>.name>.label {
            color: #555;
            font-size: 0.875rem;
            font-weight: 500;
            line-height: 1.25rem;
            letter-spacing: -0.0175rem;
        }

        >.head>.author {
            min-width: 5rem;
            display: flex;
            align-items: center;
            gap: 0.125rem;
        }

        >.head>.author>.label {
            color: #555;
        }

        >.head>.uploader {
            min-width: 5rem;
            display: flex;
            align-items: center;
            gap: 0.125rem;
        }

        >.head>.uploader>.label {
            color: #555;
        }

        >.head>.date {
            min-width: 7rem;
            display: flex;
            align-items: center;
            gap: 0.125rem;
        }

        >.head>.date>.label {
            color: #555;
        }

        >.head>.volume {
            min-width: 5rem;
            display: flex;
            align-items: center;
            gap: 0.125rem;
        }

        >.head>.volume>.label {
            color: #555;
        }

        >.head>.status {
            min-width: 4rem;
            display: flex;
            align-items: center;
            gap: 0.125rem;
        }

        >.head>.status>.label {
            color: #555;
        }

        >.head .sort-toggle {
            background-color: transparent;
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -12.5rem -6.25rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
            cursor: pointer;
        }

        >.body {
            display: flex;
            flex-direction: column;
            gap: 0.25rem;
            overflow-y: scroll;
            padding: 0.5rem 0.5rem 0.5rem 1rem;
        }

        >.body>.item {
            display: flex;
            align-items: center;
            padding: 0.25rem 0.75rem;
            border: 0.125rem solid transparent;
            border-radius: 0.75rem;
            gap: 0.25rem;
            cursor: pointer;
        }

        >.body>.item:hover {
            background: var(--primary-lv-0);
        }

        >.body>.item:active {
            background: var(--primary-lv-1);
        }

        >.body>.item[checked] {
            background: var(--primary-lv-0);
        }

        >.body>.item>.sub-sign {
            display: flex;
            align-items: center;
            gap: 0.5rem;
        }

        >.body>.item>.sub-sign>.line {
            color: #555;
        }

        >.body>.item>.sub-sign>.attach {
            color: var(--color-purple);
            padding: 0 0.25rem;
            border-radius: 0.375rem;
            background: var(--color-purple-light);
            border: 0.0625rem solid var(--color-purple);
        }

        >.body>.item>.sub-sign>.version {
            color: var(--color-blue);
            padding: 0 0.25rem;
            border-radius: 0.375rem;
            background: var(--color-blue-light);
            border: 0.0625rem solid var(--color-blue);
        }

        >.body>.item>.name {
            flex-grow: 1;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        >.body>.item>.author {
            min-width: 5rem;
            color: #555;
        }

        >.body>.item>.uploader {
            min-width: 5rem;
            color: #555;
        }

        >.body>.item>.date {
            min-width: 7rem;
            color: #555;
        }

        >.body>.item>.volume {
            min-width: 5rem;
            color: #555;
        }

        >.body>.item>.status {
            min-width: 4rem;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        >.body>.item>.status>.convert {
            display: none;
            background: #fff;
            padding: 0.125rem 0.5rem;
            outline: 0.0625rem solid #aaa;
            border-radius: 0.5rem;
        }

        >.body>.item>.status>.convert:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.body>.item>.status>.convert:active {
            background: var(--primary-lv-1);
        }

        >.body>.item:has(>.status>.convert:active) {
            background: var(--primary-lv-0);
        }

        >.body>.item>.status>.convert>.label {
            color: #555;
        }

        >.body>.item>.status>.supported {
            display: none;
            font-size: 0.75rem;
        }

        >.body>.item>.status>.unsupported {
            display: none;
            font-size: 0.75rem;
            color: var(--color-dahong);
        }

        >.body>.item>.status>.converting {
            display: none;
            font-size: 0.75rem;
            color: #888;
        }

        >.body>.item>.status[data-status="convert"]>.convert {
            display: flex;
        }

        >.body>.item>.status[data-status="converting"]>.converting {
            display: flex;
        }

        >.body>.item>.status[data-status="supported"]>.supported {
            display: flex;
        }

        >.body>.item>.status[data-status="unsupported"]>.unsupported {
            display: flex;
        }

        >.body>.item>.more {
            background: url('../img/more.svg') no-repeat center / contain;
            min-height: 1.25rem;
            min-width: 1.25rem;
            cursor: pointer;
        }
    }

    .preview__ {
        flex: 0 0 40rem;
        width: 40rem;
        min-width: 40rem;
        display: flex;
        position: relative;   /* 3D 로딩 오버레이(.preview-loading)의 기준 */
        flex-direction: column;
        height: 100%;
        background: #fff;
        border-left: 0.0625rem solid #aaa;
    }

    .preview__>.preview-header {
        height: 2.8125rem;
        min-height: 2.8125rem;
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 0.5rem;
        padding: 0 0.75rem;
        box-sizing: border-box;
        border-bottom: 0.0625rem solid #ddd;
        background: #fff;
    }

    .preview__>.preview-header>.label {
        color: var(--primary-lv-5);
        font-weight: 700;
        margin-right: auto;
        flex: 1;
    }

    .preview__>.preview-header>.pdf-full-view {
        padding: 0.25rem 0.75rem;
        font-size: 0.875rem;
        font-weight: 500;
        line-height: 1.25rem;
        letter-spacing: -0.0175rem;
        border: 0.0625rem solid #aaa;
        border-radius: 0.75rem;
        background: #fff;
        cursor: pointer;
        white-space: nowrap;
        margin-left: auto;
        color: #555;
    }

    .preview__>.preview-header>.pdf-full-view:hover {
        background: var(--primary-lv-0);
    }

    .preview__>.preview-header>.pdf-full-view:active {
        background: var(--primary-lv-1);
    }

    .preview__>.pdf-viewer {
        flex: 1;
        width: 100%;
        height: calc(100% - 2.75rem) !important;
        border: 0;
        background: #fff;
    }

    .preview__.--active {
        background: #111;
    }

    .preview__.--active>.pdf-viewer {
        background: #111;
    }

    .preview__>.image-viewer {
        flex: 1;
        display: block;
        width: 100%;
        height: calc(100% - 2.75rem);
        object-fit: contain;
        background: #fff;
    }

    .preview__.--active>.image-viewer {
        background: #111;
    }

    .preview__>.video-viewer {
        flex: 1;
        display: block;
        width: 100%;
        height: calc(100% - 2.75rem);
        object-fit: contain;
        background: #111;
    }

    .preview__.--active>.video-viewer {
        background: #111;
    }

    /* 동영상 재생 불가 안내 — 브라우저가 코덱/컨테이너를 못 다룰 때 <video> 자리에 대신 뜬다.
       미리보기 패널이 활성화되면 배경이 #111이라, 스스로 어두운 바탕과 밝은 글자를 갖는다 */
    .preview__>.video-unsupported {
        display: none;
        flex: 1;
        width: 100%;
        height: calc(100% - 2.75rem);
        align-items: center;
        justify-content: center;
        padding: 2rem;
        box-sizing: border-box;
        text-align: center;
        text-wrap: balance;
        background: #111;
        color: #f1f1f1;
        font-size: 1.0625rem;
        font-weight: 500;
        line-height: 1.7;
        letter-spacing: -0.0175rem;
    }

    /* 3D 모델 캔버스 — preview3d.js가 만들고 교체할 때 지운다.
       three.js가 캔버스 픽셀 크기를 직접 잡으므로 CSS는 자리만 잡아준다 */
    .preview__>.preview-model {
        flex: 1;
        min-height: 0;
        width: 100%;
        display: block;
        /* three.js가 첫 프레임을 그리기 전 잠깐 보이는 색 — 씬 배경과 같은 그라데이션 */
        background: linear-gradient(#8fa1b9, #b7b2aa);
        cursor: grab;          /* 드래그로 회전 */
    }

    .preview__>.preview-model:active {
        cursor: grabbing;
    }

    /* 3D 모델 로딩 진행률 — 큰 모델은 내려받는 데만 몇십 초 걸린다 */
    .preview__>.preview-loading {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        height: 100%;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        pointer-events: none;   /* 뒤 캔버스의 마우스 조작을 막지 않는다 */
    }

    .preview__>.preview-loading>.preview-loading__text {
        display: flex;
        flex-direction: column;
        align-items: center;
        font-size: 1.25rem;
        color: #111;
        text-align: center;
    }

    /* 파싱 단계 표시 — 네모 두 개가 시차를 두고 돈다 */
    .preview__>.preview-loading .loader {
        display: inline-block;
        position: relative;
        width: 3rem;
        height: 3rem;
        margin-top: 0.5rem;
    }

    .preview__>.preview-loading .loader::after,
    .preview__>.preview-loading .loader::before {
        content: '';
        position: absolute;
        left: 0;
        top: 0;
        width: 3rem;
        height: 3rem;
        border: 0.25rem solid #fff;
        box-sizing: border-box;
        animation: preview-loader-rotation 2s ease-in-out infinite;
    }

    .preview__>.preview-loading .loader::after {
        border-color: var(--primary-lv-5, #6944F0);
        animation-delay: 1s;
    }

    /* IFC 뷰어 준비 안내 — 뷰어가 자기 배경을 그리기 전이라 흰 바탕 위에 뜬다.
       기본 로딩 표시는 흰 테두리라 안 보이므로 회색으로 바꾸고, 문구도 한 단계 작게 */
    .preview__>.preview-loading.--ifc>.preview-loading__text {
        font-size: 1rem;
        font-weight: 500;
    }

    .preview__>.preview-loading.--ifc .loader::before {
        border-color: #ddd;
    }

    /* 안내 카드 — 3D 용량 초과 / 로딩 실패 공용 */
    .preview__>.preview-notice {
        flex: 1;
        min-height: 0;
        width: 100%;
        background: #808080;
        display: none;         /* JS가 표시 */
        align-items: center;
        justify-content: center;
        padding: 1.5rem;
    }

    .preview__>.preview-notice>.preview-notice__card {
        background: #fff;
        border-radius: 0.75rem;
        box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.2);
        padding: 1.75rem 2rem;
        max-width: 32rem;
    }

    .preview__>.preview-notice p {
        color: #222;
        font-size: 0.9375rem;
        line-height: 1.7;
    }

    .preview__>.preview-notice strong {
        color: #c00;
        font-weight: 700;
    }

    /* 로딩 실패 때만 붙는 원인 문구 — 안내보다 한 단계 낮게 */
    .preview__>.preview-notice .preview-notice__reason {
        margin-top: 0.75rem;
        padding-top: 0.75rem;
        border-top: 0.0625rem solid #eee;
        color: #777;
        font-size: 0.8125rem;
        line-height: 1.6;
        word-break: break-all;
    }

    /* IFC 전용 뷰어 iframe — 뷰어가 자기 배경·툴바를 직접 그린다 */
    .preview__>.preview-ifc {
        flex: 1;
        min-height: 0;
        width: 100%;
        display: block;
        border: 0;
        background: #fff;
    }

    .preview__>.text-viewer {
        flex: 1;
        width: 100%;
        height: calc(100% - 2.75rem);
        margin: 0;
        padding: 1rem;
        box-sizing: border-box;
        overflow: auto;
        white-space: pre-wrap;
        word-break: break-word;
        font-family: monospace;
        font-size: 0.8125rem;
        line-height: 1.5;
        color: #222;
        background: #fff;
    }

    .preview__>.html-viewer {
        flex: 1;
        width: 100%;
        height: calc(100% - 2.75rem);
        border: 0;
        background: #fff;
    }

    .preview__>.url-viewer {
        flex: 1;
        width: 100%;
        height: calc(100% - 2.75rem);
        border: 0;
        background: #fff;
    }

    .preview__>.preview-empty {
        flex: 1;
        min-height: 0;
        width: 100%;
        overflow: auto;
        text-align: center;
        padding: 1rem;
        box-sizing: border-box;
        background: #fff;
    }

    .preview__>.preview-empty>.image {
        max-width: 100%;
        height: auto;
    }

    >.file-context-menu__ {
        display: none;
        position: absolute;
        top: 20rem;
        left: 20rem;
        background: #fff;
        border: 0.0625rem solid #aaa;
        border-radius: 1rem;
        box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
        flex-direction: column;
        padding: 0.5rem;
        gap: 0.25rem;
        min-width: 8rem;

        >.name-change {
            display: flex;
            align-items: center;
            padding: 0.25rem 0.75rem;
            gap: 0.25rem;
            background: #fff;
            border-radius: 0.75rem;
        }

        >.name-change:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.name-change:active {
            background: var(--primary-lv-1);
        }

        >.name-change>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -16.25rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.name-change>.label {
            color: #555;
        }

        >.attach-upload {
            display: flex;
            align-items: center;
            padding: 0.25rem 0.75rem;
            gap: 0.25rem;
            background: #fff;
            border-radius: 0.75rem;
        }

        >.attach-upload>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -21.25rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.attach-upload>.label {
            color: #555;
        }

        >.version-upload {
            display: flex;
            align-items: center;
            padding: 0.25rem 0.75rem;
            gap: 0.25rem;
            background: #fff;
            border-radius: 0.75rem;
        }

        >.version-upload>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -6.25rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.version-upload>.label {
            color: #555;
        }

        >button {
            display: flex;
            align-items: center;
            gap: 0.5rem;
            width: 100%;
            padding: 0.375rem 0.75rem;
            border-radius: 0.5rem;
            background: #fff;
            cursor: pointer;
            text-align: left;
        }

        >button:hover {
            background: var(--primary-lv-0);
        }

        >button>.icon {
            width: 1rem;
            height: 1rem;
            flex: 0 0 1rem;
        }

        button>.label {
            white-space: nowrap;
        }

        >.download {
            display: flex;
            align-items: center;
            padding: 0.25rem 0.75rem;
            gap: 0.25rem;
            background: #fff;
            border-radius: 0.75rem;
        }

        >.download:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.download:active {
            background: var(--primary-lv-1);
        }

        >.download>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -10rem -15rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.download>.label {
            color: #555;
        }

        >.delete {
            display: flex;
            align-items: center;
            padding: 0.25rem 0.75rem;
            gap: 0.25rem;
            background: #fff;
            border-radius: 0.75rem;
        }

        >.delete:hover {
            background: #FFECE6;
            cursor: pointer;
        }

        >.delete>.icon {
            background-image: url('../img/CBIM_icon.svg');
            background-size: 31.25rem 77.5rem;
            background-position: -1.25rem -58.75rem;
            background-repeat: no-repeat;
            width: 1.25rem;
            height: 1.25rem;
            min-height: 1.25rem;
            min-width: 1.25rem;
        }

        >.delete>.label {
            color: #555;
        }
    }

    >.file-upload-context-menu__ {
        display: none;
        position: fixed;
        background: #fff;
        border: 0.0625rem solid #aaa;
        border-radius: 1rem;
        box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
        flex-direction: column;
        padding: 0.5rem;
        gap: 0.25rem;
        min-width: 8rem;
        z-index: 9999;
    }

    >.file-upload-context-menu__>.file-upload {
        display: flex;
        align-items: center;
        padding: 0.25rem 0.75rem;
        gap: 0.25rem;
        background: #fff;
        border-radius: 0.75rem;
    }

    .file-upload-context-menu__>.file-upload:hover {
        background: var(--primary-lv-0);
        cursor: pointer;
    }

    .file-upload-context-menu__>.file-upload:active {
        background: var(--primary-lv-1);
    }

    .file-upload-context-menu__>.file-upload>.label {
        color: #555;
    }
}

.bill-of-quantities__ {
    position: fixed;
    height: calc(100dvh - 2.75rem - 0.0625rem);
    width: 100vw;
    bottom: 0;
    overflow-y: scroll;
    overflow-x: scroll;

    >.table {
        width: 100%;
        border-collapse: collapse;
    }

    >.table>thead {
        position: sticky;
        top: 0;
        background: #eee;
        z-index: 1;
        border-bottom: 0.0625rem solid #aaa;
    }

    >.table>thead>tr>th {
        padding: 0.5rem 0.75rem;
        text-align: left;
        font-weight: 500;
        font-size: 0.875rem;
        border-right: 0.0625rem solid #aaa;
    }

    >.table>thead>tr>th:last-child {
        border-right: none;
    }

    >.table>thead>tr>th.no {
        width: 3rem;
        text-align: center;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>thead>tr>th.unit {
        width: 4rem;
        text-align: center;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>thead>tr>th.unit-price {
        width: 8rem;
        text-align: right;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>thead>tr>th.quantity {
        width: 8rem;
        text-align: right;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>thead>tr>th.cost {
        width: 10rem;
        text-align: right;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>tbody>tr {
        border-bottom: 0.0625rem solid #ddd;
    }

    >.table>tbody>tr>td {
        padding: 0.5rem 0.75rem;
        font-size: 0.875rem;
        color: #111;
        border-right: 0.0625rem solid #ddd;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>tbody>tr>td:last-child {
        border-right: none;
    }

    >.table>tbody>tr>td.no {
        text-align: center;
        color: #555;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>tbody>tr>td.unit {
        text-align: center;
        color: #555;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>tbody>tr>td.unit-price {
        text-align: right;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>tbody>tr>td.quantity {
        text-align: right;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>tbody>tr>td.cost {
        text-align: right;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
}

.cost-summary__ {
    position: fixed;
    height: calc(100dvh - 2.75rem - 0.0625rem);
    width: 100vw;
    bottom: 0;
    overflow-y: scroll;
    overflow-x: scroll;

    >.table {
        width: 100%;
        border-collapse: collapse;
    }

    >.table>thead {
        position: sticky;
        top: 0;
        background: #eee;
        z-index: 1;
        border-bottom: 0.0625rem solid #aaa;
    }

    >.table>thead>tr>th {
        padding: 0.5rem 0.75rem;
        text-align: left;
        font-weight: 500;
        font-size: 0.875rem;
        border-right: 0.0625rem solid #aaa;
    }

    >.table>thead>tr>th:last-child {
        border-right: none;
    }

    >.table>thead>tr>th.no {
        width: 3rem;
        text-align: center;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>thead>tr>th.unit {
        width: 4rem;
        text-align: center;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>thead>tr>th.unit-price {
        width: 8rem;
        text-align: right;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>thead>tr>th.quantity {
        width: 8rem;
        text-align: right;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>thead>tr>th.cost {
        width: 10rem;
        text-align: right;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>tbody>tr {
        border-bottom: 0.0625rem solid #ddd;
    }

    >.table>tbody>tr:hover {
        background: var(--primary-lv-0);
    }

    >.table>tbody>tr>td {
        padding: 0.5rem 0.75rem;
        font-size: 0.875rem;
        color: #111;
        border-right: 0.0625rem solid #ddd;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>tbody>tr>td:last-child {
        border-right: none;
    }

    >.table>tbody>tr>td.no {
        text-align: center;
        color: #555;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>tbody>tr>td.unit {
        text-align: center;
        color: #555;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>tbody>tr>td.unit-price {
        text-align: right;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>tbody>tr>td.quantity {
        text-align: right;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.table>tbody>tr>td.cost {
        text-align: right;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
}

.design-drawing__ {
    display: flex;
    position: fixed;
    height: calc(100dvh - 2.75rem - 0.0625rem);
    width: 100vw;
    bottom: 0;

    >.aside__ {
        min-width: 15rem;
        max-width: 15rem;
        border-right: 0.0625rem solid #aaa;
        padding: 1rem 0.5rem 1rem 1rem;
        display: flex;
        flex-direction: column;
        overflow-y: scroll;

        >.group {
            display: flex;
            flex-direction: column;
            gap: 0.5rem;
        }

        >.group>.title {
            color: var(--primary-lv-5);
        }

        >.group>.list {
            display: flex;
            flex-direction: column;
            gap: 0.25rem;
        }

        >.group>.list>.item {
            display: flex;
            align-items: center;
            padding: 0.25rem 0.75rem;
            border-radius: 0.75rem;
        }

        >.group>.list>.item:hover {
            background: var(--primary-lv-0);
            cursor: pointer;
        }

        >.group>.list>.item:active {
            background: var(--primary-lv-1);
        }

        >.group>.list>.item[checked] {
            background: var(--primary-lv-0);
            outline: 0.0625rem solid var(--primary-lv-5);
        }

        >.group>.list>.item>.label {
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            width: max-content;
            flex-grow: 1;
        }
    }

    >.pdf__ {
        display: flex;
        height: calc(100dvh - 2.75rem - 0.0625rem);
        flex-grow: 1;
        bottom: 0;
    }
}

.quantity-takeoff__ {
    display: flex;
    position: fixed;
    height: calc(100dvh - 2.75rem - 0.0625rem);
    width: 100vw;
    bottom: 0;
}

.construction-report__ {
    display: none;
    position: fixed;
    height: calc(100dvh - 2.75rem - 0.0625rem);
    width: 100vw;
    bottom: 0;
}

.geotechnical-investigation-report__ {
    display: none;
    position: fixed;
    height: calc(100dvh - 2.75rem - 0.0625rem);
    width: 100vw;
    bottom: 0;
}

.schedule-report__ {
    display: flex;
    position: fixed;
    height: calc(100dvh - 2.75rem - 0.0625rem);
    width: 100vw;
    bottom: 0;
}

.shared-drawing__ {
    display: none;
    position: fixed;
    height: calc(100dvh - 2.75rem - 0.0625rem);
    width: 100vw;
    bottom: 0;
}

.structural-report__ {
    display: flex;
    position: fixed;
    height: calc(100dvh - 2.75rem - 0.0625rem);
    width: 100vw;
    bottom: 0;
}

.model-layer__ {
    --panel-w: 19.25rem;
    position: fixed;
    top: 3.25rem;
    left: 0.5rem;
    z-index: 1;
    display: flex;
    flex-direction: column;
    width: var(--panel-w);
    max-height: calc(100dvh - 2.75rem - 1.5rem);
    background: #fff;
    border: 0.0625rem solid #aaa;
    border-radius: 1rem;
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
    overflow: hidden;
    transition: width 0.3s ease;

    &:has(>.head>.expand input:checked) {
        --panel-w: 12rem;
    }

    &:has(>.head>.expand input:checked)>.list .item>input,
    &:has(>.head>.expand input:checked)>.list .item>button {
        display: none;
    }

    >.head {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.75rem 1rem;
        border-bottom: 0.0625rem solid #ddd;
    }

    >.head>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -17.5rem -15rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    .head>.expand {
        display: flex;
        cursor: pointer;
        margin-left: auto;
    }

    .head>.expand:hover {
        filter: brightness(0.3);
    }

    .head>.expand>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -3.75rem -6.25rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.list {
        display: flex;
        flex-direction: column;
        gap: 0.25rem;
        padding: 1rem 0.5rem 1rem 1rem;
        overflow-y: scroll;
    }

    >.list .item {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem 0.5rem;
        border-radius: 0.75rem;
        cursor: pointer;
    }

    >.list .item:hover {
        background: var(--primary-lv-0);
    }

    >.list .item:active {
        background: var(--primary-lv-1);
    }

    >.list .item>.bulb {
        display: flex;
        cursor: pointer;
    }

    >.list .item>.bulb>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -2.5rem -6.25rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.list .item>.bulb:has(input:checked)>.icon {
        background-position: -1.25rem -70rem;
    }

    >.list .item>.label {
        flex-grow: 1;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.list .item>input[type="range"] {
        -webkit-appearance: none;
        appearance: none;
        width: 5rem;
        height: 1rem;
        background: transparent;
        cursor: pointer;
    }

    >.list .item>input[type="range"]::-webkit-slider-runnable-track {
        height: 0.375rem;
        background: #fff;
        border: 0.0625rem solid #aaa;
        border-radius: 0.25rem;
        overflow: hidden;
    }

    >.list .item>input[type="range"]::-webkit-slider-thumb {
        -webkit-appearance: none;
        appearance: none;
        height: 0.875rem;
        width: 0.875rem;
        border-radius: 50%;
        background: #fff;
        border: 0.0625rem solid #555;
        margin-top: -0.3125rem;
        box-shadow: -100vmax 0 0 calc(100vmax - 0.5rem) var(--primary-lv-5);
    }

    >.list .item>.act {
        min-height: 1.25rem;
        min-width: 1.25rem;
        border: none;
        padding: 0;
        cursor: pointer;
        background-color: transparent;
    }

    >.list .item>.act.--location {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -18.75rem -15rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
    }

    >.list>.folder {
        display: flex;
        flex-direction: column;
        gap: 0.25rem;
        list-style: none;
    }

    >.list>.folder>.head {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
        cursor: pointer;
        list-style: none;
    }

    >.list>.folder>.head::-webkit-details-marker {
        display: none;
    }

    >.list>.folder>.head:hover {
        background: var(--primary-lv-0);
    }

    >.list>.folder>.head:active {
        background: var(--primary-lv-1);
    }

    >.list>.folder>.head::before {
        content: "";
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -2.5rem -35rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-width: 1.25rem;
        min-height: 1.25rem;
    }

    >.list>.folder[open]>.head::before {
        background-position: -5rem -35rem;
    }

    >.list>.folder>.head>.label {
        font-size: 0.875rem;
        font-weight: 500;
        line-height: 1.25rem;
        letter-spacing: -0.0175rem;
    }

    >.list>.folder>.head>.count {
        margin-left: auto;
        padding-right: 0.25rem;
        color: #888;
        font-size: 0.875rem;
        font-weight: 300;
        line-height: 1rem;
        letter-spacing: -0.0175rem;
        font-family: "JetBrains Mono", monospace;
    }

    >.list>.folder>.body {
        display: flex;
        flex-direction: column;
        gap: 0.25rem;
    }

    >.list>.folder>.body>.item {
        position: relative;
        margin-left: 1.5rem;
    }

    >.list>.folder>.body>.item::after {
        content: "";
        position: absolute;
        left: -0.375rem;
        top: -0.25rem;
        bottom: -0.25rem;
        width: 0.25rem;
        border-left: 0.0625rem solid #ddd;
        background: linear-gradient(#ddd, #ddd) no-repeat left center / 100% 0.0625rem;
        pointer-events: none;
    }

    >.list>.folder>.body>.item:last-child::after {
        bottom: 50%;
        background-position: left bottom;
    }

    >.list .item.--disabled {
        pointer-events: none;
    }

    >.list .item.--disabled>* {
        opacity: 0.4;
    }
}

.new-model-layer__ {
    display: none;
    --panel-w: 20rem;
    position: fixed;
    top: 3.25rem;
    left: 0.5rem;
    z-index: 1;
    flex-direction: column;
    width: var(--panel-w);
    max-height: calc(100dvh - 2.75rem - 1.5rem);
    background: #fff;
    border: 0.0625rem solid #aaa;
    border-radius: 1rem;
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
    overflow: hidden;
    transition: width 0.3s ease;

    &:has(>.head>.expand input:checked) {
        --panel-w: 12rem;
    }

    &:has(>.head>.expand input:checked)>.list>.folder>.head>input,
    &:has(>.head>.expand input:checked)>.list>.folder>.head>.act,
    &:has(>.head>.expand input:checked)>.list>.folder>.head>.bulb {
        display: none;
    }

    &:has(>.head>.expand input:checked)>.list>.folder>.sub-list>.chips {
        grid-template-columns: repeat(2, 1fr);
    }

    >.head {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.75rem 1rem;
        border-bottom: 0.0625rem solid #ddd;
    }

    >.head>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -1.25rem -35rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.head>.title {
        flex-grow: 1;
        color: #111;
    }

    >.head>.expand {
        display: flex;
        cursor: pointer;
    }

    >.head>.expand:hover {
        filter: brightness(0.3);
    }

    >.head>.expand>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -3.75rem -6.25rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.list {
        flex: 1 1 auto;
        min-height: 0;
        display: flex;
        flex-direction: column;
        gap: 0.25rem;
        padding: 1rem 0.5rem 1rem 1rem;
        overflow-y: scroll;
    }

    >.list>.folder {
        display: flex;
        flex-direction: column;
        list-style: none;
    }

    /* sub 미준비 theme 폴더 — 조작 차단 */
    >.list>.folder.--disabled {
        pointer-events: none;
    }

    >.list>.folder.--disabled>.head {
        opacity: 0.4;
    }

    >.list>.folder>.head {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem 0.5rem;
        border-radius: 0.75rem;
        cursor: pointer;
        list-style: none;
    }

    >.list>.folder>.head::-webkit-details-marker {
        display: none;
    }

    >.list>.folder>.head:hover {
        background: var(--primary-lv-0);
    }

    >.list>.folder>.head:active {
        background: var(--primary-lv-1);
    }

    >.list>.folder>.head::before {
        content: "";
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -2.5rem -35rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-width: 1.25rem;
        min-height: 1.25rem;
    }

    >.list>.folder[open]>.head::before {
        background-position: -5rem -35rem;
    }

    >.list>.folder>.head>.label {
        flex-grow: 1;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.list>.folder>.head>input[type="range"] {
        -webkit-appearance: none;
        appearance: none;
        width: 4rem;
        height: 1rem;
        flex: 0 0 auto;
        background: transparent;
        cursor: pointer;
    }

    >.list>.folder>.head>input[type="range"]::-webkit-slider-runnable-track {
        height: 0.375rem;
        background: #fff;
        border: 0.0625rem solid #aaa;
        border-radius: 0.25rem;
        overflow: hidden;
    }

    >.list>.folder>.head>input[type="range"]::-webkit-slider-thumb {
        -webkit-appearance: none;
        appearance: none;
        height: 0.875rem;
        width: 0.875rem;
        border-radius: 50%;
        background: #fff;
        border: 0.0625rem solid #555;
        margin-top: -0.3125rem;
        box-shadow: -100vmax 0 0 calc(100vmax - 0.5rem) var(--primary-lv-5);
    }

    >.list>.folder>.head>.act {
        border: none;
        padding: 0;
        cursor: pointer;
        background-color: transparent;
    }

    >.list>.folder>.head>.act.--location {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -6.25rem -35rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.list>.folder>.head>.bulb {
        display: flex;
        cursor: pointer;
    }

    >.list>.folder>.head>.bulb>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -2.5rem -6.25rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.list>.folder>.head>.bulb:has(input:checked)>.icon {
        background-position: -1.25rem -70rem;
    }

    >.list>.folder>.sub-list {
        display: flex;
        flex-direction: column;
        gap: 0.25rem;
        margin-left: 1.125rem;
        padding-left: 0.375rem;
        border-left: 0.0625rem solid #ddd;
    }

    >.list>.folder>.sub-list>.item {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
        cursor: pointer;
    }

    >.list>.folder>.sub-list>.item:hover {
        background: var(--primary-lv-0);
    }

    >.list>.folder>.sub-list>.item:active {
        background: var(--primary-lv-1);
    }

    >.list>.folder>.sub-list>.item>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -1.25rem -35rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.list>.folder>.sub-list>.item>.label {
        flex-grow: 1;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.list>.folder>.sub-list>.chips {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 0.5rem;
        padding: 0.25rem 0.5rem;
    }

    >.list>.folder>.sub-list>.chips>.chip {
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 0.125rem 0.25rem;
        background-color: #fff;
        border: 0.0625rem solid #aaa;
        border-radius: 0.75rem;
        cursor: pointer;
    }

    >.list>.folder>.sub-list>.chips>.chip:hover {
        background-color: var(--primary-lv-0);
    }

    >.list>.folder>.sub-list>.chips>.chip:active {
        background-color: var(--primary-lv-1);
    }

    >.list>.folder>.sub-list>.chips>.chip>.label {
        color: #555;
        white-space: nowrap;
    }
}

.allnew-aside__ {
    --panel-w: 20rem;
    position: fixed;
    top: 3.25rem;
    left: 0.5rem;
    z-index: 1;
    display: flex;
    flex-direction: column;
    width: var(--panel-w);
    max-height: calc(100dvh - 2.75rem - 1.5rem);
    background: #fff;
    border: 0.0625rem solid #aaa;
    border-radius: 1rem;
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
    overflow: hidden;
    transition: width 0.3s ease;

    &:has(>.head>.expand input:checked) {
        --panel-w: 12rem;
    }

    &:has(>.head>.expand input:checked)>.list>.item>.slider,
    &:has(>.head>.expand input:checked)>.list>.item>.act,
    &:has(>.head>.expand input:checked)>.list>.item>.bulb {
        display: none;
    }

    /* 접힘 — 세그먼트가 셀렉트박스가 된다(별도 select 없이 같은 라디오 그룹 그대로라
       펼침↔접힘 어느 쪽에서 바꿔도 선택이 항상 일치).
       닫힘 얼굴은 목록 밖의 포커스 요소(i.drop-open[tabindex]) — 클릭(포커스)으로 열리고,
       옵션(label)을 고르면 포커스가 밖으로 빠지며 셀렉트박스처럼 즉시 닫힌다.
       클릭이 끝나기 전에 목록이 사라지지 않도록 :active 가 mousedown~mouseup 사이를 이어준다 */
    &:has(>.head>.expand input:checked)>.work-type {
        position: relative;
        min-height: 2.75rem;   /* 목록이 absolute 로 떠도 아래 리스트가 안 움직이게 얼굴 자리 유지 */
    }

    >.work-type>.drop-open {
        display: none;
    }

    &:has(>.head>.expand input:checked)>.work-type>.drop-open {
        position: relative;
        display: flex;
        align-items: center;
        height: 1.75rem;
        padding: 0 2rem 0 0.75rem;
        outline: 0.0625rem solid #aaa;
        border-radius: 1rem;
        background: #fff;
        color: #111;
        font-size: 0.875rem;
        line-height: 1.25rem;
        letter-spacing: -0.0175rem;
        font-style: normal;
        cursor: pointer;
    }

    &:has(>.head>.expand input:checked)>.work-type>.drop-open::after {
        content: '';
        position: absolute;
        right: 0.5rem;
        top: 0.25rem;
        pointer-events: none;
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -5rem -6.25rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
    }

    &:has(>.head>.expand input:checked)>.work-type:has(>.drop-open:focus)>.drop-open::after {
        transform: rotate(180deg);
    }

    /* 얼굴 텍스트 = 현재 선택값 */
    &:has(>.head>.expand input:checked)>.work-type:has(input[value="토공"]:checked)>.drop-open::before { content: '토공'; }
    &:has(>.head>.expand input:checked)>.work-type:has(input[value="배수공"]:checked)>.drop-open::before { content: '배수공'; }
    &:has(>.head>.expand input:checked)>.work-type:has(input[value="구조물공"]:checked)>.drop-open::before { content: '구조물공'; }
    &:has(>.head>.expand input:checked)>.work-type:has(input[value="포장공"]:checked)>.drop-open::before { content: '포장공'; }
    &:has(>.head>.expand input:checked)>.work-type:has(input[value="부대공"]:checked)>.drop-open::before { content: '부대공'; }

    /* 열림 — 얼굴이 포커스를 쥔 동안(+옵션 클릭이 끝날 때까지 :active) 목록이 얼굴 아래로 뜬다.
       absolute 라 아래 리스트를 밀지 않고, 옵션은 DOM 순서 그대로 */
    &:has(>.head>.expand input:checked)>.work-type>.segment {
        display: none;
    }

    &:has(>.head>.expand input:checked)>.work-type:has(>.drop-open:focus)>.segment,
    &:has(>.head>.expand input:checked)>.work-type>.segment:active {
        position: absolute;
        top: calc(0.75rem + 1.75rem + 0.25rem);
        left: 1rem;
        right: 1rem;
        z-index: 3;
        display: flex;
        flex-direction: column;
        align-items: stretch;   /* base 의 center 는 column 에선 가로 중앙정렬이 돼 행이 쪼그라든다 */
        padding: 0.0625rem 0.0625rem;
        box-shadow: 0 0.25rem 0.75rem 0 rgba(17, 17, 17, 0.16);
    }

    &:has(>.head>.expand input:checked)>.work-type>.segment>label {
        justify-content: flex-start;
        padding: 0.25rem 0.75rem;
    }

    &:has(>.head>.expand input:checked)>.work-type>.segment>label::before {
        display: none;
    }

    &:has(>.head>.expand input:checked)>.work-type>.segment>label:has(input:checked) {
        background: var(--primary-lv-0);
        cursor: default;
    }

    &:has(>.head>.expand input:checked)>.work-type>.segment>label:has(input:checked)>.label {
        color: var(--primary-lv-5);
    }

    /* 얼굴 재클릭 닫기 캐처 — 얼굴이 포커스를 쥔 동안 얼굴 위를 덮는 비포커스 요소(i.drop-close).
       포커스된 요소를 다시 눌러선 blur 가 안 일어나므로, 대신 이걸 눌러 포커스를 빼서 닫는다 */
    >.work-type>.drop-close {
        display: none;
    }

    &:has(>.head>.expand input:checked)>.work-type:has(>.drop-open:focus)>.drop-close {
        display: block;
        position: absolute;
        top: 0.75rem;
        left: 1rem;
        right: 1rem;
        height: 1.75rem;
        z-index: 4;
        cursor: pointer;
    }

    >.head {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.75rem 1rem;
        border-bottom: 0.0625rem solid #ddd;
        cursor: grab;              /* 헤드 잡고 창 이동(.layer__ 패널과 동일) */
        touch-action: none;
    }

    >.head:active {
        cursor: grabbing;
    }

    >.head>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -1.25rem -35rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.head>.title {
        flex-grow: 1;
        color: #111;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.head>.title>.point {
        color: var(--primary-lv-5);
    }

    >.head>.expand {
        display: flex;
        cursor: pointer;
    }

    >.head>.expand:hover {
        filter: brightness(0.3);
    }

    >.head>.expand>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -3.75rem -6.25rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.head>.close {
        border: none;
        padding: 0;
        cursor: pointer;
        background-color: transparent;
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -1.25rem -6.25rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.head>.close:hover {
        filter: brightness(0.3);
    }

    >.work-type {
        flex: 0 0 auto;
        padding: 0.75rem 1rem 0.25rem;
    }

    >.work-type input {
        display: none;
    }

    >.work-type>.segment {
        display: flex;
        align-items: center;
        outline: 0.0625rem solid #aaa;
        border-radius: 1rem;
        background: #fff;
    }

    >.work-type>.segment>label {
        position: relative;
        flex: 1 1 0;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 0.25rem 0.125rem;
        border-radius: 1rem;
        cursor: pointer;
    }

    >.work-type>.segment>label+label::before {
        content: '';
        position: absolute;
        left: 0;
        top: 50%;
        transform: translate(-50%, -50%);
        width: 0.0625rem;
        height: 0.875rem;
        background: #ddd;
    }

    >.work-type>.segment>label:has(input:checked)+label::before,
    >.work-type>.segment>label:has(input:checked)::before {
        display: none;
    }

    >.work-type>.segment>label:hover {
        background: var(--primary-lv-0);
    }

    >.work-type>.segment>label>.label {
        color: #555;
        white-space: nowrap;
    }

    >.work-type>.segment>label:has(input:checked) {
        background: var(--primary-lv-5);
        cursor: default;
    }

    >.work-type>.segment>label:has(input:checked)>.label {
        color: #fff;
    }

    /* 하위 theme 목록이 아직 없는 공종(토공/배수공/포장공/부대공) — projectManager 가 input 을 disable */
    >.work-type>.segment>label:has(input:disabled) {
        opacity: 0.4;
        pointer-events: none;
    }

    /* DB 에 theme 이 없는 항목 — 모양만 남기고 조작 차단 */
    >.list>.item.--disabled {
        pointer-events: none;
    }

    >.list>.item.--disabled>* {
        opacity: 0.4;
    }

    >.list {
        flex: 1 1 auto;
        min-height: 0;
        display: flex;
        flex-direction: column;
        gap: 0.25rem;
        margin: 0;
        padding: 0.5rem 0 0.5rem 0.5rem;
        list-style: none;
        overflow-y: scroll;
        overflow-x: hidden;
    }

    /* 지형모델 고정 리스트(메인 리스트 아래 한 줄) — head 의 구분선(border-bottom)과 같은 선을
       border-top 으로 올려 공종 리스트와 구분. 늘어나거나 스크롤하지 않는다 */
    >.list.--fixed {
        flex: 0 0 auto;
        overflow-y: hidden;
        border-top: 0.0625rem solid #ddd;
    }

    >.list>.item {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem 0.5rem;
        border-radius: 0.75rem;
        cursor: pointer;
    }

    >.list>.item:hover {
        background: var(--primary-lv-0);
    }

    >.list>.item:active {
        background: var(--primary-lv-1);
    }

    >.list>.item>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -1.25rem -35rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.list>.item>.label {
        flex-grow: 1;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    >.list>.item>.slider {
        -webkit-appearance: none;
        appearance: none;
        width: 4rem;
        height: 1rem;
        flex: 0 0 auto;
        background: transparent;
        cursor: pointer;
    }

    >.list>.item>.slider::-webkit-slider-runnable-track {
        height: 0.375rem;
        background: #fff;
        border: 0.0625rem solid #aaa;
        border-radius: 0.25rem;
        overflow: hidden;
    }

    >.list>.item>.slider::-webkit-slider-thumb {
        -webkit-appearance: none;
        appearance: none;
        height: 0.875rem;
        width: 0.875rem;
        border-radius: 50%;
        background: #fff;
        border: 0.0625rem solid #555;
        margin-top: -0.3125rem;
        box-shadow: -100vmax 0 0 calc(100vmax - 0.5rem) var(--primary-lv-5);
    }

    >.list>.item>.act {
        border: none;
        padding: 0;
        cursor: pointer;
        background-color: transparent;
    }

    >.list>.item>.act.--location {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -6.25rem -35rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.list>.item>.bulb {
        display: flex;
        cursor: pointer;
    }

    >.list>.item>.bulb input {
        display: none;
    }

    >.list>.item>.bulb>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -2.5rem -6.25rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    >.list>.item>.bulb:has(input:checked)>.icon {
        background-position: -1.25rem -70rem;
    }

    /* theme — 하위 부재 칩(접속슬래브1·교각1…): 4열 기준 균등분할(2개면 반반), 접힘(축소) 상태에선 숨김.
       좌측 세로선(#ddd) = 상위 부재와의 하이어라키 표시(아이콘 중심선에 맞춤) */
    >.list>.sub-list {
        display: flex;
        flex-wrap: wrap;
        gap: 0.5rem;
        margin-left: 1.125rem;
        padding: 0 0.5rem 0.25rem 0.875rem;
        border-left: 0.0625rem solid #ddd;
    }

    >.list>.sub-list>.chip {
        flex: 1 1 20%;
        padding: 0.25rem 0.5rem;
        border: none;
        outline: 0.0625rem solid #aaa;
        border-radius: 1rem;
        background-color: #fff;
        cursor: pointer;
    }

    >.list>.sub-list>.chip:hover {
        background-color: var(--primary-lv-0);
    }

    >.list>.sub-list>.chip:active {
        background-color: var(--primary-lv-1);
    }

    >.list>.sub-list>.chip>.label {
        color: #555;
        font-size: 0.875rem;
        line-height: 1.25rem;
        white-space: nowrap;
    }

    /* sub — 하위 부재 행(.--child): 아이콘 없이 들여쓰기 + 세로선(#ddd) 하이어라키.
       선은 ::before — 행 사이 gap(0.25rem) 위까지 덮어 위 행과 끊김 없이 이어진다 */
    >.list>.item.--child {
        position: relative;
        margin-left: 1.125rem;
        padding-left: 0.875rem;
    }

    >.list>.item.--child::before {
        content: '';
        position: absolute;
        left: 0;
        top: -0.25rem;
        bottom: 0;
        width: 0.0625rem;
        background: #ddd;
        pointer-events: none;
    }

    /* 그룹의 첫 하위 행 — 선이 부모 행 쪽으로 튀어나오지 않게 자기 상단에서 시작 */
    >.list>.item:not(.--child)+.item.--child::before {
        top: 0;
    }

    /* 접힘 — 칩은 그대로 두고 좁은 폭(12rem)에 맞춰 재배열: 2개짜리(접속슬래브·교대)=1열 풀폭,
       3개 이상(교각)=2열. 개수 판별은 :has(>.chip:nth-child(3)) */
    &:has(>.head>.expand input:checked)>.list>.sub-list>.chip {
        flex-basis: 100%;
    }

    &:has(>.head>.expand input:checked)>.list>.sub-list:has(>.chip:nth-child(3))>.chip {
        flex-basis: 35%;
    }
}

/* ㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡㅡ 🟥 index 통합 레이어(theallnew-layer__) —
   헤더 레이어즈(모델/도면) 대체. summary = 좌상단 원형 버튼(열리면 숨김), article = 아코디언 aside.
   모델/평면도/종단면도/미지정 섹션은 details 아코디언. X 닫기·헤드 드래그는 initHeaderLayersPanels 공용 배선 */
.theallnew-layer__>.button {
    position: fixed;
    top: 3.25rem;
    left: 0.5rem;
    z-index: 100;   /* 하단 시트(z:99) 위 — 헤더(100)와는 화면이 안 겹친다 */
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 50%;
    background: #fff;
    border: 0.0625rem solid #aaa;
    box-shadow: 0 0.25rem 0.75rem 0 rgba(17, 17, 17, 0.16);
    cursor: pointer;
    list-style: none;
}

.theallnew-layer__>.button::-webkit-details-marker {
    display: none;
}

.theallnew-layer__>.button:hover {
    background: var(--primary-lv-0);
}

.theallnew-layer__>.button:active {
    background: var(--primary-lv-1);
}

.theallnew-layer__>.button>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -3.75rem -35rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-height: 1.25rem;
    min-width: 1.25rem;
}

/* 열리면 버튼 자리는 aside 가 차지 · 닫힘 상태의 aside 는 명시적으로 숨김(author display 가 UA 숨김을 이기는 함정) */
.theallnew-layer__[open]>.button {
    display: none;
}

.theallnew-layer__:not([open])>article {
    display: none;
}

.theallnew-aside__ {
    --panel-w: 20rem;
    position: fixed;
    top: 3.25rem;
    left: 0.5rem;
    z-index: 100;   /* 하단 시트(z:99) 위 — 헤더(100)와는 화면이 안 겹친다 */
    display: flex;
    flex-direction: column;
    width: var(--panel-w);
    max-height: calc(100dvh - 3.25rem - 1rem);
    background: #fff;
    border: 0.0625rem solid #aaa;
    border-radius: 1rem;
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
    overflow: hidden;
    transition: width 0.3s ease;
}

/* ㅡㅡㅡㅡㅡ 헤드 */
.theallnew-aside__>.head {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.75rem 0.75rem 0.75rem 1rem;
    border-bottom: 0.0625rem solid #ddd;
}

.theallnew-aside__>.head>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -3.75rem -35rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-height: 1.25rem;
    min-width: 1.25rem;
}

.theallnew-aside__>.head>.title {
    flex-grow: 1;
    color: #111;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.theallnew-aside__>.head>.expand {
    display: flex;
    cursor: pointer;
}

.theallnew-aside__>.head>.expand:hover {
    filter: brightness(0.3);
}

.theallnew-aside__>.head>.expand input {
    display: none;
}

.theallnew-aside__>.head>.expand>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -3.75rem -6.25rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-height: 1.25rem;
    min-width: 1.25rem;
}

.theallnew-aside__>.head>.close {
    border: none;
    padding: 0;
    cursor: pointer;
    background-color: transparent;
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -1.25rem -6.25rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-height: 1.25rem;
    min-width: 1.25rem;
}

.theallnew-aside__>.head>.close:hover {
    filter: brightness(0.3);
}

/* ㅡㅡㅡㅡㅡ 바디(아코디언 컨테이너) */
.theallnew-aside__>.body {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    padding: 0.5rem 0 0.5rem 0.5rem;
    overflow-y: scroll;
    overflow-x: hidden;
}

/* ㅡㅡㅡㅡㅡ 아코디언 섹션(details.group) — summary = 섹션 헤드(셰브론+아이콘+타이틀+전체끄기) */
.theallnew-aside__ .group>.head {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.5rem;
    border-radius: 0.75rem;
    cursor: pointer;
    list-style: none;
}

.theallnew-aside__ .group>.head::-webkit-details-marker {
    display: none;
}

.theallnew-aside__ .group>.head:hover {
    background: var(--primary-lv-0);
}

.theallnew-aside__ .group>.head>.toggle {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -5rem -6.25rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-height: 1.25rem;
    min-width: 1.25rem;
}

/* 접힘 = 셰브론 위로 */
.theallnew-aside__ .group:not([open])>.head>.toggle {
    transform: rotate(180deg);
}

/* 닫힌 아코디언 내용 명시 숨김 — 자식의 author display(flex 등)가 UA 닫힘 숨김을 이기는 함정 대응.
   details 타입+:is 로 리스트 display 규칙(0,4,0)보다 특이성을 높인다 */
.theallnew-aside__ details.group:not([open])>:is(.list, .work-type) {
    display: none;
}

.theallnew-aside__ .group>.head>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -1.25rem -35rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-height: 1.25rem;
    min-width: 1.25rem;
}

/* 모델 외 그룹(--plan/--vertical/--unassigned + 동적 렌더 도면 그룹) = 도면 아이콘 */
.theallnew-aside__ .group:not(.--model)>.head>.icon {
    background-position: -11.25rem -35rem;
}

.theallnew-aside__ .group>.head>.title {
    flex-grow: 1;
    color: #111;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 그룹 헤드 전구(구 '전체끄기/켜기' 텍스트 버튼) — 클릭 배선(전구 일괄 토글)은 그대로.
   상태는 CSS 로 계산: 전부 꺼짐 = off · 하나라도 켜짐 = on · 섞임 = indeterminate(개별 svg) */
.theallnew-aside__ .group>.head>.toggle-all {
    flex: 0 0 auto;
    border: none;
    padding: 0;
    cursor: pointer;
    background-color: transparent;
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -2.5rem -6.25rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-height: 1.25rem;
    min-width: 1.25rem;
}

/* 기본 탭 — 측량 행(.--survey)은 화면에 없으므로 상태 계산에서도 제외 */
.theallnew-aside__ .group:has(.list .item:not(.--survey) .bulb input:checked)>.head>.toggle-all {
    background-position: -1.25rem -70rem;
}

.theallnew-aside__ .group:has(.list .item:not(.--survey) .bulb input:checked):has(.list .item:not(.--survey) .bulb input:not(:checked))>.head>.toggle-all {
    background: url('../img/bulb-indeterminate.svg') no-repeat center / contain;
}

/* 모델비교 탭 — 측량 행이 보이므로 포함해서 다시 계산 */
body.--theme:has(.nav>.in-progress input:checked) .theallnew-aside__ .group:has(.list .bulb input:checked)>.head>.toggle-all {
    background: url('../img/CBIM_icon.svg') no-repeat -1.25rem -70rem / 31.25rem 77.5rem;
}

body.--theme:has(.nav>.in-progress input:checked) .theallnew-aside__ .group:has(.list .bulb input:checked):has(.list .bulb input:not(:checked))>.head>.toggle-all {
    background: url('../img/bulb-indeterminate.svg') no-repeat center / contain;
}

/* ㅡㅡㅡㅡㅡ 공종 세그먼트(모델 섹션) — allnew 와 동일 동작(접힘 시 셀렉트박스).
   리스트와 같은 트리 선 안쪽(margin+border-left 동일) — 아래 리스트 보더와 이어져 한 줄로 보인다 */
.theallnew-aside__ .work-type {
    flex: 0 0 auto;
    position: relative;
    margin-left: 1.125rem;
    border-left: 0.0625rem solid #ddd;
    padding: 0.25rem 0.5rem;
}

.theallnew-aside__ .work-type input {
    display: none;
}

.theallnew-aside__ .work-type>.segment {
    display: flex;
    align-items: center;
    outline: 0.0625rem solid #aaa;
    border-radius: 1rem;
    background: #fff;
}

.theallnew-aside__ .work-type>.segment>label {
    position: relative;
    flex: 1 1 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.25rem 0.125rem;
    border-radius: 1rem;
    cursor: pointer;
}

.theallnew-aside__ .work-type>.segment>label+label::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 0.0625rem;
    height: 0.875rem;
    background: #ddd;
}

.theallnew-aside__ .work-type>.segment>label:has(input:checked)+label::before,
.theallnew-aside__ .work-type>.segment>label:has(input:checked)::before {
    display: none;
}

.theallnew-aside__ .work-type>.segment>label:hover {
    background: var(--primary-lv-0);
}

.theallnew-aside__ .work-type>.segment>label>.label {
    color: #555;
    white-space: nowrap;
}

.theallnew-aside__ .work-type>.segment>label:has(input:checked) {
    background: var(--primary-lv-5);
    cursor: default;
}

.theallnew-aside__ .work-type>.segment>label:has(input:checked)>.label {
    color: #fff;
}

/* 하위 theme 목록이 아직 없는 공종(토공/배수공/포장공/부대공) — projectManager 가 input 을 disable.
   접힘 셀렉트박스 목록에도 같은 셀렉터가 적용된다 */
.theallnew-aside__ .work-type>.segment>label:has(input:disabled) {
    opacity: 0.4;
    pointer-events: none;
}

/* ㅡㅡㅡㅡㅡ 모델 리스트(공종 theme 행 + 지형 고정 행 — projectManager 가 렌더).
   좌측 세로선(#ddd) = 섹션 하위 트리 표시(시안) — UL 의 border 라 행 사이 gap 에도 끊기지 않는다 */
.theallnew-aside__ .group.--model>.list {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin: 0 0 0 1.125rem;
    padding-top: 0.25rem;
    padding-left: 0.5rem;
    border-left: 0.0625rem solid #ddd;
    list-style: none;
    margin-right: 0.0625rem;
}

.theallnew-aside__ .group.--model>.list>.item {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.5rem;
    border-radius: 0.75rem;
    cursor: pointer;
}

.theallnew-aside__ .group.--model>.list>.item:hover {
    background: var(--primary-lv-0);
}

.theallnew-aside__ .group.--model>.list>.item:active {
    background: var(--primary-lv-1);
}

/* 시안 — 행 아이콘 없음(렌더러가 넣어도 숨김, 지형 고정 행 포함) */
.theallnew-aside__ .group.--model>.list>.item>.icon {
    display: none;
}

.theallnew-aside__ .group.--model>.list>.item>.label {
    flex-grow: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.theallnew-aside__ .group.--model>.list>.item>.slider {
    -webkit-appearance: none;
    appearance: none;
    width: 4rem;
    height: 1rem;
    flex: 0 0 auto;
    background: transparent;
    cursor: pointer;
}

.theallnew-aside__ .group.--model>.list>.item>.slider::-webkit-slider-runnable-track {
    height: 0.375rem;
    background: #fff;
    border: 0.0625rem solid #aaa;
    border-radius: 0.25rem;
    overflow: hidden;
}

.theallnew-aside__ .group.--model>.list>.item>.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    height: 0.875rem;
    width: 0.875rem;
    border-radius: 50%;
    background: #fff;
    border: 0.0625rem solid #555;
    margin-top: -0.3125rem;
    box-shadow: -100vmax 0 0 calc(100vmax - 0.5rem) var(--primary-lv-5);
}

.theallnew-aside__ .group.--model>.list>.item>.act {
    border: none;
    padding: 0;
    cursor: pointer;
    background-color: transparent;
}

.theallnew-aside__ .group.--model>.list>.item>.act.--location {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -6.25rem -35rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-height: 1.25rem;
    min-width: 1.25rem;
}

/* ㅡㅡㅡㅡㅡ 전구(전 섹션 공통 — 도면 그룹 행에도 쓰인다) */
.theallnew-aside__ .list>.item .bulb {
    display: flex;
    cursor: pointer;
}

.theallnew-aside__ .list>.item .bulb input {
    display: none;
}

.theallnew-aside__ .list>.item .bulb>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -2.5rem -6.25rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-height: 1.25rem;
    min-width: 1.25rem;
}

.theallnew-aside__ .list>.item .bulb:has(input:checked)>.icon {
    background-position: -1.25rem -70rem;
}

/* 🟥 선택된 모델 행(subLayerPanel 피킹이 is-selected 토글) — 컬러는 리맵(sub=quaterary·index=secondary·theme=tertiary) */
.theallnew-aside__ .group.--model>.list>.item.is-selected {
    background: var(--primary-lv-0);
    outline: 0.0625rem solid var(--primary-lv-5);
    cursor: default;
}

/* 하위 행 선택 시 — 계층 세로선(::before, li 왼쪽 모서리)이 outline 과 정확히 겹치므로 그 행 구간만 끊는다 */
.theallnew-aside__ .group.--model>.list>.item.--child.is-selected::before {
    display: none;
}

/* theme·index — 선택된 행/칩도 pointer 유지(더블클릭 = sub/theme 진입이 살아 있다) */
body.--main .theallnew-aside__ .group.--model>.list>.item.is-selected,
body.--theme .theallnew-aside__ .group.--model>.list>.item.is-selected,
body.--theme .theallnew-aside__ .group.--model>.list>.sub-list>.chip.is-selected {
    cursor: pointer;
}

/* 소그룹 전구 3상태 — 자식이 섞이면 subLayerPanel 이 .--indeterminate 를 건다(체크 상태보다 우선) */
.theallnew-aside__ .list>.item .bulb.--indeterminate>.icon,
.theallnew-aside__ .list>.item .bulb:has(input:indeterminate)>.icon {
    background: url('../img/bulb-indeterminate.svg') no-repeat center / contain;
}

/* ㅡㅡㅡㅡㅡ 도면 섹션 리스트(평면도/종단면도/미지정 — 라벨 좌 + 전구 우, 트리 세로선) */
.theallnew-aside__ .group:not(.--model)>.list {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin: 0 0 0 1.125rem;
    padding: 0.25rem 0 0 0.5rem;
    border-left: 0.0625rem solid #ddd;
    list-style: none;
}

.theallnew-aside__ .group:not(.--model)>.list>.item {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.5rem;
    border-radius: 0.75rem;
}

/* 시안 — 전구는 행 우측 끝(마크업은 전구+라벨 순서라 order 로 뒤집는다) */
.theallnew-aside__ .group:not(.--model)>.list>.item .bulb {
    order: 2;
}

.theallnew-aside__ .group:not(.--model)>.list>.item:hover {
    background: var(--primary-lv-0);
}

.theallnew-aside__ .group:not(.--model)>.list>.item>.label {
    flex-grow: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 데이터 없는 행(선형중심선 등) — projectManager 가 --disabled 를 건다 */
.theallnew-aside__ .list>.item.--disabled {
    opacity: 0.4;
    pointer-events: none;
}

/* (해당없음) — 실시설계모델이 어느 분할면에도 없음. projectSplit/themeCompare 가 --na 를 건다.
   모델명(선택/더블클릭)은 살리고 조작 컨트롤(슬라이더/위치/전구)만 잠금.
   탭 조건은 .side 노출과 동일 — 비교 탭 밖에선 클래스가 남아 있어도 잠기지 않는다 */
body.--main:has(.nav>.progress-status input:checked) .theallnew-aside__ .group.--model.--na :is(.list .slider, .list .act.--location, .list .bulb, .head>.toggle-all),
body.--theme:has(.nav>.in-progress input:checked) .theallnew-aside__ .group.--model.--na :is(.list .slider, .list .act.--location, .list .bulb, .head>.toggle-all) {
    opacity: 0.4;
    pointer-events: none;
}

/* ㅡㅡㅡㅡㅡ 접힘(익스펜드) — 폭 축소 + 모델 행의 슬라이더/위치/전구 숨김 + 세그먼트 → 셀렉트박스 */
.theallnew-aside__:has(>.head>.expand input:checked) {
    --panel-w: 12rem;
}

/* 접힘 — 전구(행/그룹 헤드)는 그대로 두고 슬라이더/위치 버튼만 숨김 */
.theallnew-aside__:has(>.head>.expand input:checked) .group.--model>.list>.item>.slider,
.theallnew-aside__:has(>.head>.expand input:checked) .group.--model>.list>.item>.act {
    display: none;
}

/* .theallnew-aside__:has(>.head>.expand input:checked) .work-type {
    min-height: 2.75rem;
} */

.theallnew-aside__ .work-type>.drop-open {
    display: none;
}

.theallnew-aside__:has(>.head>.expand input:checked) .work-type>.drop-open {
    position: relative;
    display: flex;
    align-items: center;
    height: 1.75rem;
    padding: 0 2rem 0 0.75rem;
    outline: 0.0625rem solid #aaa;
    border-radius: 1rem;
    background: #fff;
    color: #111;
    font-size: 0.875rem;
    line-height: 1.25rem;
    letter-spacing: -0.0175rem;
    font-style: normal;
    cursor: pointer;
}

.theallnew-aside__:has(>.head>.expand input:checked) .work-type>.drop-open::after {
    content: '';
    position: absolute;
    right: 0.5rem;
    top: 0.25rem;
    pointer-events: none;
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -5rem -6.25rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
}

.theallnew-aside__:has(>.head>.expand input:checked) .work-type:has(>.drop-open:focus)>.drop-open::after {
    transform: rotate(180deg);
}

/* 얼굴 텍스트 = 현재 선택 공종명(projectManager 가 data-label 에 심는다 — 공종은 DB 라 이름을 CSS 에 박지 않는다) */
.theallnew-aside__:has(>.head>.expand input:checked) .work-type>.drop-open::before { content: attr(data-label); }

/* 열림 — 얼굴 포커스 동안(+옵션 클릭이 끝날 때까지 :active) 목록이 얼굴 아래로 뜬다 */
.theallnew-aside__:has(>.head>.expand input:checked) .work-type>.segment {
    display: none;
}

.theallnew-aside__:has(>.head>.expand input:checked) .work-type:has(>.drop-open:focus)>.segment,
.theallnew-aside__:has(>.head>.expand input:checked) .work-type>.segment:active {
    position: absolute;
    top: calc(0.25rem + 1.75rem + 0.25rem);
    left: 0.5rem;
    right: 0.5rem;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    padding: 0.25rem 0;
    box-shadow: 0 0.25rem 0.75rem 0 rgba(17, 17, 17, 0.16);
}

.theallnew-aside__:has(>.head>.expand input:checked) .work-type>.segment>label {
    justify-content: flex-start;
    padding: 0.25rem 0.75rem;
}

.theallnew-aside__:has(>.head>.expand input:checked) .work-type>.segment>label::before {
    display: none;
}

.theallnew-aside__:has(>.head>.expand input:checked) .work-type>.segment>label:has(input:checked) {
    background: var(--primary-lv-0);
    cursor: default;
}

.theallnew-aside__:has(>.head>.expand input:checked) .work-type>.segment>label:has(input:checked)>.label {
    color: var(--primary-lv-5);
}

/* 얼굴 재클릭 닫기 캐처 — 포커스된 얼굴 위를 덮는 비포커스 요소(누르면 blur 로 닫힘) */
.theallnew-aside__ .work-type>.drop-close {
    display: none;
}

.theallnew-aside__:has(>.head>.expand input:checked) .work-type:has(>.drop-open:focus)>.drop-close {
    display: block;
    position: absolute;
    top: 0.25rem;
    left: 0.5rem;
    right: 0.5rem;
    height: 1.75rem;
    z-index: 4;
    cursor: pointer;
}

/* ㅡㅡㅡㅡㅡ 🟥 하위 부재 칩(theme — themeSimulation 이 .sub-list>.chip 렌더: 접속슬래브1·교각1…).
   펼침 4열 균등(2개면 반반), 접힘은 2개=1열 풀폭 · 3개 이상=2열 */
.theallnew-aside__ .group.--model>.list>.sub-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0 0.5rem 0.25rem 1rem;
    list-style: none;
}

.theallnew-aside__ .group.--model>.list>.sub-list>.chip {
    flex: 1 1 20%;
    padding: 0.25rem 0.5rem;
    border: none;
    outline: 0.0625rem solid #aaa;
    border-radius: 1rem;
    background-color: #fff;
    cursor: pointer;
    color: #555;
    font-size: 0.875rem;
    line-height: 1.25rem;
    white-space: nowrap;
}

/* 칩 라벨(h4) — 기본 h4(0.75rem)를 14px 로 올린다(system.css 는 건드리지 않는다) */
.theallnew-aside__ .group.--model>.list>.sub-list>.chip>.label {
    font-size: 0.875rem;
    line-height: 1.25rem;
}

.theallnew-aside__ .group.--model>.list>.sub-list>.chip:hover {
    background-color: var(--primary-lv-0);
}

.theallnew-aside__ .group.--model>.list>.sub-list>.chip.is-selected {
    background-color: var(--primary-lv-0);
    outline-color: var(--primary-lv-5);
    cursor: default;
}

.theallnew-aside__:has(>.head>.expand input:checked) .group.--model>.list>.sub-list>.chip {
    flex-basis: 100%;
}

.theallnew-aside__:has(>.head>.expand input:checked) .group.--model>.list>.sub-list:has(>.chip:nth-child(3))>.chip {
    flex-basis: 35%;
}

/* ㅡㅡㅡㅡㅡ 🟥 (좌측)/(우측)/(양쪽) — 분할(모델비교) 탭에서만 의미. projectSplit/themeCompare 가 채운다 */
.theallnew-aside__ .group.--model>.head .side {
    display: none;
    color: var(--color-pink);
}

body.--main:has(.nav>.progress-status input:checked) .theallnew-aside__ .group.--model>.head .side,
body.--theme:has(.nav>.in-progress input:checked) .theallnew-aside__ .group.--model>.head .side {
    display: inline;
}

/* ㅡㅡㅡㅡㅡ 🟥 측량성과 2종(평면기준점·SAT.POINTER) — 3D 점이 모델비교 탭에서만 그려진다(themeSurveyPoints) */
.theallnew-aside__ .group.--unassigned>.list>.item.--survey {
    display: none;
}

body.--theme:has(.nav>.in-progress input:checked) .theallnew-aside__ .group.--unassigned>.list>.item.--survey {
    display: flex;
}

/* ㅡㅡㅡㅡㅡ 🟥 theme — 아이콘은 tertiary 셀(y=400 행: layer 320,400 · model 280,400 · 도면 460,400 · local 300,400),
   공정모델·모델비교 탭에선 종단면도 그룹 숨김(하단 종단 뷰어가 평면/종단 탭에만 있어서) */
body.--theme .theallnew-layer__>.button>.icon,
body.--theme .theallnew-aside__>.head>.icon {
    background-position: -20rem -25rem;
}

body.--theme .theallnew-aside__ .group>.head>.icon {
    background-position: -17.5rem -25rem;
}

body.--theme .theallnew-aside__ .group:not(.--model)>.head>.icon {
    background-position: -28.75rem -25rem;
}

body.--theme .theallnew-aside__ .group.--model>.list>.item>.act.--location {
    background-position: -18.75rem -25rem;
}

body.--theme:has(.nav>.instruction input:checked) .theallnew-aside__ .group.--vertical,
body.--theme:has(.nav>.in-progress input:checked) .theallnew-aside__ .group.--vertical {
    display: none;
}

/* index — 공정모델·모델비교 탭은 하단 종단면도 탭이 없으므로 종단면도 그룹 숨김 */
body:has(.nav>.process-model input:checked) .theallnew-aside__ .group.--vertical,
body:has(.nav>.progress-status input:checked) .theallnew-aside__ .group.--vertical {
    display: none;
}

/* ㅡㅡㅡㅡㅡ 🟥 sub — 버튼·창은 공정모델 창(left-aside: left 0.5rem + 폭 10rem) 우측 0.5rem 간격.
   아이콘은 sub 셀(y=720 행: layer 100,720 · model 40,720 · local 160,720) */
body.--sub .theallnew-layer__>.button>.icon,
body.--sub .theallnew-aside__>.head>.icon {
    background-position: -6.25rem -45rem;
}

body.--sub .theallnew-aside__ .group>.head>.icon {
    background-position: -2.5rem -45rem;
}

body.--sub .theallnew-aside__ .group:not(.--model)>.head>.icon {
    background-position: -12.5rem -45rem;
}

body.--sub .theallnew-aside__ .group.--model>.list>.item>.act.--location {
    background-position: -10rem -45rem;
}

/* sub 기성객체 그룹 — 모델 탭은 창 제목(기성객체)이 헤드를 대신한다: 헤드 숨김 + 트리 들여쓰기·세로선 없음.
   단면확인 탭은 다른 묶음(도면·연결객체)과 같은 아코디언 */
body.--sub:has(.header__>.nav>.instruction input:checked) .theallnew-aside__ .group.--own>.head {
    display: none;
}

body.--sub:has(.header__>.nav>.instruction input:checked) .theallnew-aside__ .group.--own>.list {
    margin-left: 0;
    padding-left: 0;
    border-left: none;
}

/* 단면확인 탭 — 연결객체 줄은 선택 안 됨(subLayerPanel 피킹 — 기성객체만). 전구·슬라이더는 그대로 */
body.--sub:has(.header__>.nav>.design-section input:checked) .theallnew-aside__ .group.--linked>.list>.item {
    cursor: default;
}

/* 도면 그룹 자리 — 래퍼 없이 바디 flex(간격)에 그대로 참여 */
.theallnew-aside__ .drawings {
    display: contents;
}

/* sub 연결객체(바깥 참조 '@') — 지금 단계 행에 보이는 줄이 없으면 섹션째 숨김 */
body.--sub .theallnew-aside__ .group.--linked:not(:has(>.list>.item:not(.--filtered))) {
    display: none;
}

/* ㅡㅡㅡㅡㅡ 🟥 sub — 하위 부재 행(.item.--child): 아이콘 없이 2단 들여쓰기 + 세로선(#ddd).
   ::before 가 행 사이 gap(0.25rem)까지 덮어 위 행과 이어진다(그룹 첫 하위 행은 제 상단부터) */
.theallnew-aside__ .group.--model>.list>.item.--child {
    position: relative;
    margin-left: 1.125rem;
    padding-left: 0.875rem;
}

.theallnew-aside__ .group.--model>.list>.item.--child::before {
    content: '';
    position: absolute;
    left: 0;
    top: -0.25rem;
    bottom: 0;
    width: 0.0625rem;
    background: #ddd;
    pointer-events: none;
}

.theallnew-aside__ .group.--model>.list>.item:not(.--child)+.item.--child::before {
    top: 0;
}

/* 렌더러가 전체끄기 텍스트 라벨(h4)을 넣어도 전구 버튼에선 숨긴다 */
.theallnew-aside__ .group>.head>.toggle-all>.label {
    display: none;
}

.header__ {
    z-index: 100;

    /* 기존 레이어 버튼(모달 포함) — 레이어즈 그룹(모델/도면/지도)으로 대체되어 숨김 */
    .nav>.layer {
        display: none;
        margin-left: auto;
    }

    .nav>.layer>.button {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
        outline: 0.0625rem solid var(--primary-lv-7);
        background: var(--primary-lv-5);
        list-style: none;
        cursor: pointer;
    }

    .nav>.layer>.button::-webkit-details-marker {
        display: none;
    }

    .nav>.layer>.button:hover {
        background: var(--primary-lv-6);
    }

    .nav>.layer>.button:active {
        background: var(--primary-lv-7);
    }

    .nav>.layer>.button>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -3.75rem 0;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    .nav>.layer>.button>.label {
        color: #fff;
    }

    .nav>.layer[open]>.button {
        background: #fff;
    }

    .nav>.layer[open]>.button>.label {
        color: var(--primary-lv-5);
    }

    .nav>.layer[open]>.button>.icon {
        background-position: -20rem -15rem;
    }

    .nav>.layer>.modal {
        position: fixed;
        top: calc(2.75rem + 0.0625rem + 0.5rem);
        right: 0.5rem;
        display: flex;
        flex-direction: column;
        width: 14rem;
        max-height: calc(100dvh - 4rem);
        background: #fff;
        border: 0.0625rem solid #aaa;
        border-radius: 1rem;
        box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
    }

    .nav>.layer>.modal>.head {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.75rem 1rem;
        border-bottom: 0.0625rem solid #ddd;
    }

    .nav>.layer>.modal>.head>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -20rem -15rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    .nav>.layer>.modal>.head>.label {
        flex-grow: 1;
    }

    .nav>.layer>.modal>.head>.close {
        background-color: transparent;
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -1.25rem -6.25rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
        border: none;
        padding: 0;
        cursor: pointer;
    }

    .nav>.layer>.modal>ul {
        display: flex;
        flex-direction: column;
        gap: 0.25rem;
        padding: 0.5rem;
    }

    .nav>.layer>.modal>.road-list {
        flex: 1 1 auto;
        min-height: 0;
        overflow-y: scroll;
        padding-right: 0;
    }

    .nav>.layer>.modal>ul>.item {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
    }

    .nav>.layer>.modal>ul>.item:hover {
        background: var(--primary-lv-0);
    }

    .nav>.layer>.modal>ul>.item>.bulb {
        display: flex;
        cursor: pointer;
    }

    .nav>.layer>.modal>ul>.item>.bulb>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -2.5rem -6.25rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    .nav>.layer>.modal>ul>.item>.bulb:has(input:checked)>.icon {
        background-position: -1.25rem -70rem;
    }

    .nav>.layer>.modal>ul>.item>.label {
        flex-grow: 1;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .nav>.layer>.modal>.base-map {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.75rem 1rem;
        border-top: 0.0625rem solid #ddd;
        border-bottom: 0.0625rem solid #ddd;
    }

    .nav>.layer>.modal>.base-map>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -10rem -35rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    .nav>.layer>.modal>ul>.item>.radio {
        display: flex;
        cursor: pointer;
    }

    .nav>.layer>.modal>ul>.item>.radio>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -16.25rem 0;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }

    .nav>.layer>.modal>ul>.item>.radio:has(input:checked)>.icon {
        background-position: -8.75rem -35rem;
    }

    .nav>.layer>.modal>.road {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.5rem 1rem;
        border-top: 0.0625rem solid #ddd;
        border-bottom: 0.0625rem solid #ddd;
    }

    .nav>.layer>.modal>.road>.icon {
        background-image: url('../img/CBIM_icon.svg');
        background-size: 31.25rem 77.5rem;
        background-position: -23.75rem -15rem;
        background-repeat: no-repeat;
        width: 1.25rem;
        height: 1.25rem;
        min-height: 1.25rem;
        min-width: 1.25rem;
    }
}

.header__ .label,
.header__ .title,
.header__ .name {
    white-space: nowrap;
}

.header__.--lang-en>.construction>label>.label,
.header__.--lang-en>.design>a>.label {
    letter-spacing: -0.0625rem;
}

.header__ {
    .nav>.layer>.modal>.road>.button {
        display: flex;
        align-items: center;
        gap: 0.25rem;
        padding: 0.25rem 0.75rem;
        border-radius: 0.75rem;
        background: #fff;
        outline: 0.0625rem solid #aaa;
        list-style: none;
        cursor: pointer;
        margin-left: auto;
    }

    .nav>.layer>.modal>.road>.button:hover {
        background: var(--primary-lv-0);
    }

    .nav>.layer>.modal>.road>.button:active {
        background: var(--primary-lv-1);
    }

    .nav>.layer>.modal>.road>.button>.label {
        color: #555;
    }
}

body.--sub {
    --primary-lv-0: var(--quaterary-lv-0);
    --primary-lv-1: var(--quaterary-lv-1);
    --primary-lv-2: var(--quaterary-lv-2);
    --primary-lv-3: var(--quaterary-lv-3);
    --primary-lv-4: var(--quaterary-lv-4);
    --primary-lv-5: var(--quaterary-lv-5);
    --primary-lv-6: var(--quaterary-lv-6);
    --primary-lv-7: var(--quaterary-lv-7);
}

body.--sub .header__>.project>.logo {
    background-image: url('../img/logo2-model.svg');
}

body.--sub .header__>.project>.arrow {
    background-position: -1.25rem -42.5rem;
}

body.--sub .header__>.nav>.model:has(input:checked)>.icon {
    background-position: -2.5rem -45rem;
}

body.--sub .header__>.profile>.layer.--active>.icon {
    background-position: -6.25rem -45rem;
}

body.--sub .header__>.nav>.schedule-plan:has(input:checked)>.icon {
    background-position: -5rem -45rem;
}

body.--sub .header__>.nav>.progress-plan:has(input:checked)>.icon {
    background-position: -8.75rem -45rem;
}

/* sub — 문서함 연필(edit 220,720 #943800) — 같은 연필을 쓰는 파일 이름변경 메뉴도 함께 */
body.--sub .document-section__>.article__>.edit>.icon,
body.--sub .document-section__>.file-context-menu__>.name-change>.icon {
    background-position: -13.75rem -45rem;
}

/* sub — 문서함 다운로드(240,720 #943800) — 템플릿 다운로드 + 파일 컨텍스트 메뉴 */
body.--sub .document-section__>.article__>.notice>.foot>.download>.icon,
body.--sub .document-section__>.file-context-menu__>.download>.icon {
    background-position: -15rem -45rem;
}

body.--sub .model__>.aside__>.contents>.head>.icon {
    background-position: -2.5rem -45rem;
}

body.--sub .model__>.aside__>.contents>.head>.data-icon {
    background-position: -3.75rem -45rem;
}

body.--sub .model__>.aside__>.contents>.body>.bg-head>.icon {
    background-position: -2.5rem -45rem;
}

body.--sub .model__>.aside__>.contents>.body>#subsObjectInfo>.info>.head>.icon {
    background-position: -11.25rem -45rem;
}

body.--sub .model__>.model-info__>.head>.icon {
    background-position: -2.5rem -45rem;
}

body.--sub .model__>.model-context-menu__>.substantial-object-view>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -2.5rem -45rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
}

body.--main {
    --primary-lv-0: var(--secondary-lv-0);
    --primary-lv-1: var(--secondary-lv-1);
    --primary-lv-2: var(--secondary-lv-2);
    --primary-lv-3: var(--secondary-lv-3);
    --primary-lv-4: var(--secondary-lv-4);
    --primary-lv-5: var(--secondary-lv-5);
    --primary-lv-6: var(--secondary-lv-6);
    --primary-lv-7: var(--secondary-lv-7);
}

body.--main .header__>.project>.logo {
    background-image: url('../img/logo2-model.svg');
}

body.--main .header__ .nav>.layer>.modal>.road>.icon {
    background-position: -7.5rem -35rem;
}

body.--main .header__ .nav>.layer[open]>.button>.icon {
    background-position: -3.75rem -35rem;
}

body.--main .header__ .nav>.layer>.modal>.head>.icon {
    background-position: -3.75rem -35rem;
}

body.--main .model-layer__>.head>.icon {
    background-position: -1.25rem -35rem;
}

body.--main .model-layer__>.list .item>.act.--location {
    background-position: -6.25rem -35rem;
}

body.--theme {
    --primary-lv-0: var(--tertiary-lv-0);
    --primary-lv-1: var(--tertiary-lv-1);
    --primary-lv-2: var(--tertiary-lv-2);
    --primary-lv-3: var(--tertiary-lv-3);
    --primary-lv-4: var(--tertiary-lv-4);
    --primary-lv-5: var(--tertiary-lv-5);
    --primary-lv-6: var(--tertiary-lv-6);
    --primary-lv-7: var(--tertiary-lv-7);
}

body.--theme .header__>.project>.logo {
    background-image: url('../img/logo2-model.svg');
}

body.--theme .header__>.project>.arrow {
    background-position: -6.25rem -22.5rem;
}

body.--theme .header__>.profile>.layer.--active>.icon {
    background-position: -20rem -25rem;
}

body.--theme .model__>.aside__>.contents>.head>.icon {
    background-position: -22.5rem -25rem;
}

body.--theme .model__>.aside__>.contents>.head>.data-icon {
    background-position: -3.75rem -25rem;
}

body.--theme .model__>.aside__>.contents>.list>.item.--model[data-type="drn-cl"]>.icon {
    background-position: -13.75rem -25rem;
}

body.--theme .model__>.aside__>.contents>.list>.item .act.--location {
    background-position: -18.75rem -25rem;
}

body.--theme .model__>.aside__>.contents>.body>.bg-head>.icon {
    background-position: -17.5rem -25rem;
}

body.--theme .model__>.aside__>.contents>.simulation>.icon {
    background-position: -8.75rem -25rem;
}

body.--theme .model__>.model-info__>.head>.icon {
    background-position: -17.5rem -25rem;
}

body.--theme .model__>.simulation__>.icon {
    background-position: -8.75rem -25rem;
}

body.--theme .model__>.simulation__>.play>.icon {
    background-position: -5rem -25rem;
}

body.--theme .model__ .simulation-chart__>.head>.icon {
    background-position: -8.75rem -25rem;
}

body.--theme .model__ .simulation-chart__>.head>.play>.icon {
    background-position: -5rem -25rem;
}

body.--theme .document-section__>.article__>.edit>.icon {
    background-position: -16.25rem -25rem;
}

body.--theme .document-section__>.article__>.notice>.foot>.download>.icon {
    background-position: -10rem -25rem;
}

body.--theme .document-section__>.file-context-menu__>.name-change>.icon {
    background-position: -16.25rem -25rem;
}

body.--theme .document-section__>.file-context-menu__>.attach-upload>.icon {
    background-position: -21.25rem -25rem;
}

body.--theme .document-section__>.file-context-menu__>.version-upload>.icon {
    background-position: -6.25rem -25rem;
}

body.--theme .document-section__>.file-context-menu__>.download>.icon {
    background-position: -10rem -25rem;
}

body.--theme .clipping__>.follow-camera>.icon {
    background-position: -12.5rem -25rem;
}

body.--theme .clipping__>.cliping-invert>.icon {
    background-position: -15rem -25rem;
}

body.--theme .clipping__>.play>.icon {
    background-position: -5rem -25rem;
}

body.--theme .layer-button__>.icon {
    background-position: -20rem -25rem;
}

body.--theme .clipping-button__>.icon {
    background-position: -11.25rem -25rem;
}

body.--theme .layer__>.head>.icon {
    background-position: -20rem -25rem;
}

/* theme — 헤더: 기존 레이어 버튼·구분선은 레이어즈 그룹(모델/도면)으로 대체.
   마크업·배선은 남기고 CSS 로만 숨긴다. (진행중 → '진행상태' 탭은 다시 노출) */
body.--theme .header__>.profile>.layer,
body.--theme .header__>.profile>.divider {
    display: none;
}

/* theme — 레이어즈 열림 버튼·패널 아이콘은 tertiary 셀(y=400 행: model 280,400 · local 300,400 · 도면 460,400) */
body.--theme .header__>.nav>.layers>.model[open]>.button>.icon {
    background-position: -17.5rem -25rem;
}

body.--theme .header__>.nav>.layers>.drawing[open]>.button>.icon {
    background-position: -28.75rem -25rem;
}

body.--theme .allnew-aside__>.head>.icon,
body.--theme .allnew-aside__>.list>.item>.icon {
    background-position: -17.5rem -25rem;
}

body.--theme .allnew-aside__>.list>.item>.act.--location {
    background-position: -18.75rem -25rem;
}

body.--theme .allnew-drawing__>.head>.icon {
    background-position: -28.75rem -25rem;
}

/* theme — 지도 패널이 없어 도면 창을 우측 끝(index 의 지도 자리)에 붙인다 */
body.--theme .allnew-drawing__ {
    right: 0.5rem;
}

/* theme — (좌측)/(우측)/(양쪽) 표기는 화면이 둘인 진행상태 탭에서만 의미가 있다.
   평면/종단·공정모델은 한 화면뿐이라 숨긴다.
   도면은 항상 좌측 화면에 그려져 (좌측) 고정 표기, 모델은 themeCompare 가
   실시설계모델이 떠 있는 쪽을 채운다(어느 쪽도 아니면 빈 문자열이라 안 보인다). */
body.--theme .allnew-drawing__>.head>.title>.side {
    display: none;
    color: var(--color-pink);
}

body.--theme:has(.nav>.in-progress input:checked) .allnew-drawing__>.head>.title>.side,
body.--theme:has(.nav>.in-progress input:checked) .allnew-aside__>.head>.title>.side {
    display: inline;
}

.subs-nav__[hidden],
.theme-nav__[hidden] {
    display: none;
}

.subs-nav__,
.theme-nav__ {
    position: fixed;
    inset: 0;
    z-index: 500;
    display: flex;
    align-items: center;
    justify-content: center;
}

.subs-nav__dim,
.theme-nav__dim {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
}

.subs-nav__panel,
.theme-nav__panel {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 18rem;
    background: #fff;
    border-radius: 1rem;
    box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.25);
    overflow: hidden;
    font-family: Pretendard, sans-serif;
    border: 0.0625rem solid #aaa;
}

.subs-nav__head,
.theme-nav__head {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    border-bottom: 0.0625rem solid #ddd;
}

.subs-nav__title,
.theme-nav__title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #111;
}

.subs-nav__close,
.theme-nav__close {
    margin-left: auto;
    cursor: pointer;
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -1.25rem -6.25rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
}

.subs-nav__list,
.theme-nav__list {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    padding: 0.75rem 0.5rem 0.75rem 1rem;
    max-height: 60vh;
    overflow-y: scroll;
}

.subs-nav__item,
.theme-nav__item {
    flex-shrink: 0;
    padding: 0.25rem 0.5rem;
    border-radius: 0.75rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: #555;
    cursor: pointer;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.25rem;
    letter-spacing: -0.0175rem;
}

.subs-nav__item:hover,
.theme-nav__item:hover {
    background: var(--primary-lv-0);
}

.subs-nav__item.--current,
.theme-nav__item.--current {
    background: var(--primary-lv-0);
    outline: 0.0625rem solid var(--primary-lv-5);
    font-weight: 500 !important;
    cursor: default;
}

.subs-nav__item.--disabled,
.theme-nav__item.--disabled {
    opacity: 0.4;
    pointer-events: none;
}

.cam-help__[hidden] {
    display: none;
}

.cam-help__ {
    position: fixed;
    inset: 0;
    z-index: 500;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cam-help__dim {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
}

.cam-help__panel {
    position: relative;
    display: flex;
    flex-direction: column;
    width: min(52rem, 92vw);
    max-height: 80dvh;
    background: #fff;
    border-radius: 1rem;
    box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.25);
    overflow: hidden;
    font-family: Pretendard, sans-serif;
    border: 0.0625rem solid #aaa;
}

.cam-help__head {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    border-bottom: 0.0625rem solid #ddd;
    flex-shrink: 0;
}

.cam-help__title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #111;
}

.cam-help__close {
    margin-left: auto;
    cursor: pointer;
    background-image: url('../img/CBIM_icon.svg');
    background-repeat: no-repeat;
    background-position: -1.25rem -6.25rem;
    background-size: 31.25rem 77.5rem;
    width: 1.25rem;
    height: 1.25rem;
}

.cam-help__body {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1rem;
    overflow-y: auto;
}

.cam-help__section {
    display: flex;
    align-items: center;
    gap: 0.4375rem;
    font-size: 0.9rem;
    font-weight: 700;
    color: #111;
    padding-top: 0.75rem;
    border-top: 0.0625rem solid #e5e5e5;
    letter-spacing: -0.0125rem;
}

.cam-help__section:first-child {
    padding-top: 0;
    border-top: none;
}

.cam-help__section::before {
    content: "";
    width: 0.25rem;
    height: 0.95rem;
    background: var(--primary-lv-5);
    border-radius: 0.125rem;
}

.cam-help__lead,
.cam-help__tip {
    font-size: 0.8125rem;
    line-height: 1.5;
    color: #333;
    letter-spacing: -0.0125rem;
}

.cam-help__lead b {
    color: #111;
    font-weight: 700;
}

.cam-help__tip {
    padding: 0.625rem 0.75rem;
    background: var(--primary-lv-0);
    border: 0.0625rem solid var(--primary-lv-2);
    border-radius: 0.75rem;
    color: #222;
}

.cam-help__table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.75rem;
    border: 0.0625rem solid #ddd;
    border-radius: 0.5rem;
    overflow: hidden;
}

.cam-help__table th,
.cam-help__table td {
    padding: 0.4375rem 0.625rem;
    border: 0.0625rem solid #eee;
    text-align: left;
    vertical-align: top;
    line-height: 1.4;
    letter-spacing: -0.0125rem;
}

.cam-help__table thead th {
    background: var(--primary-lv-5);
    color: #fff;
    font-weight: 600;
}

.cam-help__table tbody td:first-child {
    background: var(--primary-lv-0);
    font-weight: 600;
    color: #333;
    white-space: nowrap;
}

.cam-help__table tbody td {
    color: #444;
}

.cam-help__figure {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
    margin: 0;
}

.cam-help__figure img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 0.75rem;
}

.cam-help__figure figcaption {
    font-size: 0.75rem;
    line-height: 1.45;
    color: #666;
    letter-spacing: -0.0125rem;
}

.cam-help__figure figcaption b {
    color: #222;
    font-weight: 700;
}

.folder-context-menu__ {
    display: none;
    position: fixed;
    z-index: 100;
    flex-direction: column;
    gap: 0.25rem;
    min-width: 8rem;
    padding: 0.5rem;
    background: #fff;
    border: 0.0625rem solid #aaa;
    border-radius: 1rem;
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
}

.folder-context-menu__>button {
    display: flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    background: #fff;
    border-radius: 0.75rem;
    cursor: pointer;
}

.folder-context-menu__>button:hover {
    background: var(--primary-lv-0);
}

.folder-context-menu__>button>.label {
    color: #555;
}

.header-context-menu__ {
    display: none;
    position: fixed;
    z-index: 100;
    flex-direction: column;
    gap: 0.25rem;
    min-width: 8rem;
    padding: 0.5rem;
    background: #fff;
    border: 0.0625rem solid #aaa;
    border-radius: 1rem;
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
}

.header-context-menu__>button {
    display: flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    background: #fff;
    border-radius: 0.75rem;
    cursor: pointer;
}

.header-context-menu__>button:hover {
    background: var(--primary-lv-0);
}

.header-context-menu__>button>.label {
    color: #555;
}

.aside__ .item.--context,
.aside__ .group .title.--context,
.aside__ .group .sub-title.--context {
    background: var(--primary-lv-2);
    outline: 0.0625rem solid var(--primary-lv-5);
    border-radius: 0.5rem;
}

.aside__.--context {
    background: var(--primary-lv-0);
    outline: 0.0625rem dashed var(--primary-lv-5);
    outline-offset: -0.375rem;
    border-radius: 0.5rem;
}

.file__>.file-drop-overlay {
    display: none;
    position: absolute;
    inset: 0;
    z-index: 5;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-align: center;
    background: rgba(233, 237, 236, 0.92);
    outline: 0.125rem dashed var(--primary-lv-5);
    outline-offset: -0.5rem;
    pointer-events: none;
}

.file__.--drag-over>.file-drop-overlay {
    display: flex;
}

.file__>.file-drop-overlay>.icon {
    width: 2.5rem;
    height: 2.5rem;
    color: var(--primary-lv-5);
}

.file__>.file-drop-overlay>.line1 {
    color: var(--primary-lv-5);
    font-weight: 700;
}

.file__>.file-drop-overlay>.line2 {
    color: #e03131;
    font-weight: 700;
}

.file__ .body .item.--selected {
    background: var(--primary-lv-1);
}

.file__ .body .item.--linked {
    background: #fff;
}

.file__ .body {
    position: relative;
}

.file__ .body>.group-outline {
    position: absolute;
    border: 0.125rem solid var(--primary-lv-5);
    border-radius: 0.75rem;
    pointer-events: none;
}

.upload-progress__ {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.upload-progress__dim {
    position: absolute;
    inset: 0;
    background: rgba(17, 17, 17, 0.45);
}

.upload-progress__panel {
    position: relative;
    z-index: 1;
    min-width: 22rem;
    padding: 1.5rem;
    background: #fff;
    border-radius: 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
}

.upload-progress__title {
    font-weight: 700;
    color: var(--primary-lv-5);
}

.upload-progress__count {
    color: #555;
}

.upload-progress__bar {
    width: 100%;
    height: 0.5rem;
    background: var(--primary-lv-0);
    border-radius: 0.5rem;
    overflow: hidden;
}

.upload-progress__fill {
    display: block;
    height: 100%;
    width: 0;
    background: var(--primary-lv-5);
    transition: width 0.15s ease;
}

.upload-progress__percent {
    font-weight: 700;
    color: var(--primary-lv-5);
}

.upload-progress__status {
    color: #888;
    min-height: 1.2em;
}

.folder-modal__ {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 200;
    align-items: center;
    justify-content: center;
}

.folder-modal__dim {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
}

.folder-modal__panel {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-width: 20rem;
    padding: 1.5rem;
    background: #fff;
    border-radius: 1rem;
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.2);
}

.folder-modal__title {
    font-weight: 700;
    color: var(--primary-lv-5);
}

.folder-modal__input {
    padding: 0.5rem 0.75rem;
    border: 0.0625rem solid #aaa;
    border-radius: 0.5rem;
}

.folder-modal__foot {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
}

.folder-modal__foot>button {
    padding: 0.4rem 1rem;
    border-radius: 0.75rem;
    cursor: pointer;
}

.folder-modal__cancel {
    background: #fff;
    border: 0.0625rem solid #aaa;
}

.folder-modal__confirm {
    background: var(--primary-lv-5);
    color: #fff;
    border: 0;
}

.header__ .construction .header-add {
    margin-left: 0.25rem;
    padding: 0.25rem 0.5rem;
    border-radius: 0.75rem;
    border: 0.0625rem solid #17546A;
    background: #1B5F74;
    color: #fff;
    cursor: pointer;
    font-size: 1.125rem;
    font-weight: 700;
}

.header__ .construction .header-add:hover {
    background: #17546A;
}

.header-modal__ {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 200;
    align-items: center;
    justify-content: center;
}

.header-modal__dim {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
}

.header-modal__panel {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-width: 20rem;
    padding: 0.75rem 1rem;
    background: #fff;
    border-radius: 1rem;
    outline: 0.0625rem solid #aaa;
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.2);
}

.header-modal__input {
    padding: 0.25rem 0.75rem;
    border: 0.0625rem solid #aaa;
    color: var(--color-dahong);
    border-radius: 0.75rem;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.25rem;
    letter-spacing: -0.0175rem;
}

.header-modal__input::placeholder {
    color: #aaa;
}

.header-modal__foot {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
}

.header-modal__foot>button {
    padding: 0.25rem 0.75rem;
    border-radius: 0.75rem;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.25rem;
    letter-spacing: -0.0175rem;
}

.header-modal__cancel {
    background: #fff;
    color: #555;
    border: 0.0625rem solid #aaa;
}

.header-modal__confirm {
    background: var(--primary-lv-5);
    color: #fff;
}

body.--main .completed-quantity__,
body.--main .design-quantity__,
body.--main .unit-price__ {
    display: none;
    position: relative;
    z-index: 1;
    width: 100dvw;
    height: calc(100dvh - 2.8125rem);
    margin-top: 2.8125rem;
}

body.--main:has(.nav>.completed-quantity input:checked) .completed-quantity__,
body.--main:has(.nav>.design-quantity input:checked) .design-quantity__,
body.--main:has(.nav>.unit-price input:checked) .unit-price__ {
    display: flex;
}

body.--main .completed-quantity__>iframe,
body.--main .design-quantity__>iframe,
body.--main .unit-price__>iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

body.--sub .contract-unit-price__,
body.--sub .construction-cost__ {
    display: none;
    position: relative;
    z-index: 1;
    width: 100dvw;
    height: calc(100dvh - 2.8125rem);
    margin-top: 2.8125rem;
}

body.--sub:has(.nav>.contract-unit-price input:checked) .contract-unit-price__,
body.--sub:has(.nav>.construction-cost input:checked) .construction-cost__ {
    display: flex;
}

body.--sub .contract-unit-price__>iframe,
body.--sub .construction-cost__>iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

/* 🟥 기즈모(8rem, right 0.5rem) 하단 중앙 정렬 — 큐브 중심 = 우측 4.5rem 지점.
   right 4.5rem + translateX(50%) 로 세그먼트 폭과 무관하게 중앙이 맞는다 */
.view-type__ {
    background: #fff;
    outline: 0.0625rem solid #aaa;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
    position: fixed;
    top: 11.5rem;
    right: 4.5rem;
    transform: translateX(50%);
    z-index: 1;
}

.side-tools__>.view-type__{
    position: static;
    transform: none;
    /* 🟥 side-tools(right 0.75rem) 안에서 기즈모 중앙(우측 4.5rem)에 맞춤 — 세그먼트 폭 4.5rem 기준 */
    margin-right: 1.5rem;
}

/* 완성계·진행중 탭 직교/원근 토글 — 평면/종단(2D)에선 숨김 */
.view-type__.--progress {
    display: none;
}

body:has(.nav>.instruction input:checked) .view-type__.--progress,
body:has(.nav>.in-progress input:checked) .view-type__.--progress {
    display: flex;
}

.view-type__>label {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.75rem;
    padding: 0.25rem 0.5rem;
}

.view-type__>label:hover {
    background: var(--primary-lv-0);
    cursor: pointer;
}

.view-type__>.label:active {
    background: var(--primary-lv-0);
}

.view-type__>label>.label {
    color: #555;
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1rem;
    letter-spacing: -0.0175rem;
}

.view-type__>label:has(input:checked) {
    background-color: var(--primary-lv-5);
}

.view-type__>label:has(input:checked)>.label {
    color: #fff;
    font-weight: 500;
}

.clipping__ {
    position: fixed;
    z-index: 2;
    top: 3.5rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    height: 2.75rem;
    padding: 0 0.5rem;
    background: #fff;
    border-radius: 1.25rem;
    outline: 0.0625rem solid #aaa;
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
    white-space: nowrap;
}

.clipping__[hidden] {
    display: none;
}

.clipping__>.segment {
    display: flex;
    align-items: center;
    height: 1.75rem;
    background: #fff;
    border-radius: 0.75rem;
    outline: 0.0625rem solid #aaa;
}

.clipping__>.segment>label {
    display: flex;
    align-items: center;
    height: 100%;
    padding: 0 0.75rem;
    border-radius: 0.75rem;
    cursor: pointer;
}

.clipping__>.segment>label>.label {
    color: #555;
}

.clipping__>.segment>label:not(:has(input:checked)):hover {
    background: var(--primary-lv-0);
}

.clipping__>.segment>label:has(input:checked) {
    background: var(--primary-lv-5);
}

.clipping__>.segment>label:has(input:checked)>.label {
    color: #fff;
    font-weight: 700;
}

.clipping__>.select {
    position: relative;
    display: flex;
    align-items: center;
    height: 1.75rem;
    background: #fff;
    border-radius: 0.75rem;
    outline: 0.0625rem solid #aaa;
}

.clipping__>.select:hover {
    background: var(--primary-lv-0);
}

.clipping__>.select>select {
    -webkit-appearance: none;
    appearance: none;
    height: 100%;
    padding: 0 1.75rem 0 0.75rem;
    border: none;
    outline: none;
    background: transparent;
    color: #111;
    font-family: inherit;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.25rem;
    letter-spacing: -0.0175rem;
    cursor: pointer;
}

.clipping__>.select>.icon {
    position: absolute;
    right: 0.5rem;
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -11.25rem -6.25rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-width: 1.25rem;
    min-height: 1.25rem;
    transform: rotate(-90deg);
    pointer-events: none;
}

.clipping__>.title {
    color: #111;
    font-weight: 700;
}

.clipping__>.select+.title {
    margin-left: 0.5rem;
}

.clipping__>input[type="text"] {
    box-sizing: border-box;
    width: 5rem;
    height: 1.75rem;
    padding: 0 0.75rem;
    border: none;
    outline: 0.0625rem solid #aaa;
    border-radius: 0.75rem;
    background: #fff;
    color: var(--color-dahong);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.25rem;
    letter-spacing: -0.0175rem;
}

.clipping__>input[type="text"]:focus {
    outline-color: var(--primary-lv-5);
}

.clipping__>.input-range {
    width: 25.9375rem;
    height: 0.75rem;
    background: none;
    cursor: pointer;
    appearance: none;
}

.clipping__>.input-range::-webkit-slider-runnable-track {
    height: 0.25rem;
    border-radius: 0.125rem;
    background: linear-gradient(to right, var(--primary-lv-5) var(--range-fill, 0%), #ddd var(--range-fill, 0%));
}

.clipping__>.input-range::-moz-range-track {
    height: 0.25rem;
    border-radius: 0.125rem;
    background: #ddd;
}

.clipping__>.input-range::-moz-range-progress {
    height: 0.25rem;
    border-radius: 0.125rem;
    background: var(--primary-lv-5);
}

.clipping__>.input-range::-webkit-slider-thumb {
    width: 1rem;
    height: 0.75rem;
    margin-top: -0.25rem;
    border: 0.0625rem solid #aaa;
    border-radius: 0.5rem;
    background: #fff;
    appearance: none;
}

.clipping__>.input-range::-moz-range-thumb {
    width: 1rem;
    height: 0.75rem;
    border: 0.0625rem solid #aaa;
    border-radius: 0.5rem;
    background: #fff;
}

.clipping__>.input-range:hover::-webkit-slider-thumb {
    background: var(--primary-lv-0);
}

.clipping__>.input-range:active::-webkit-slider-thumb {
    background: var(--primary-lv-1);
}

.clipping__>.input-range:hover::-moz-range-thumb {
    background: var(--primary-lv-0);
}

.clipping__>.input-range:active::-moz-range-thumb {
    background: var(--primary-lv-1);
}

.clipping__>.divider {
    width: 0.0625rem;
    align-self: stretch;
    background: #ddd;
    margin: 0 0.5rem;
}

.clipping__>button,
.clipping__>.play {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    height: 1.75rem;
    padding: 0 0.75rem;
    border: none;
    outline: 0.0625rem solid #aaa;
    border-radius: 0.75rem;
    background: #fff;
    cursor: pointer;
}

.clipping__>button:hover,
.clipping__>.play:hover {
    background: var(--primary-lv-0);
}

.clipping__>button:active,
.clipping__>.play:active {
    background: var(--primary-lv-1);
}

.clipping__>button>.icon,
.clipping__>.play>.icon {
    min-width: 1.25rem;
    min-height: 1.25rem;
}

.clipping__>button>.label,
.clipping__>.play>.label {
    color: #555;
}

.clipping__>.follow-camera>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -12.5rem -15rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
}

.clipping__>.cliping-invert>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -15rem -15rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
}

.clipping__>.play>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -5rem -15rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
}

.clipping__>button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.clipping__>button:disabled:hover,
.clipping__>button:disabled:active {
    background: #fff;
}

.clipping__>button.--active {
    background: var(--primary-lv-5);
    outline-color: var(--primary-lv-7);
}

.clipping__>button.--active:hover {
    background: var(--primary-lv-6);
}

.clipping__>button.--active:active {
    background: var(--primary-lv-7);
}

.clipping__>button.--active>.icon {
    filter: brightness(0) invert(1);
}

.clipping__>button.--active>.label {
    color: #fff;
}

.clipping__>.play:has(input:checked) {
    background: var(--primary-lv-5);
    outline-color: var(--primary-lv-7);
}

.clipping__>.play:has(input:checked):hover {
    background: var(--primary-lv-6);
}

.clipping__>.play:has(input:checked):active {
    background: var(--primary-lv-7);
}

.clipping__>.play:has(input:checked)>.icon {
    background-position: -12.5rem 0;
}

.clipping__>.play:has(input:checked)>.label {
    color: #fff;
}

.model-head {
    padding: 0.75rem 1rem !important;
}

.side-tools__ {
    position: fixed;
    top: 11.5rem;
    right: 0.75rem;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.75rem;
}

.layer-button__,
.clipping-button__,
.section-button__ {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 0 0 auto;
    width: 3rem;
    height: 3rem;
    padding: 0.375rem 0 0;
    border: none;
    outline: 0.0625rem solid #aaa;
    border-radius: 0.75rem;
    background: #fff;
    cursor: pointer;
}

.layer-button__[hidden],
.clipping-button__[hidden],
.section-button__[hidden] {
    display: none;
}

.layer-button__:hover,
.clipping-button__:hover,
.section-button__:hover {
    background: var(--primary-lv-0);
}

/* 🟥 theme — 선형클리핑 버튼이 헤더 nav(모델비교 우측)로 이동: 원형(side-tools) 스타일을 nav 필 결로 재정의.
   토글 배선(themeAlignment)·.--active 는 그대로. 어느 탭에서든 진입 가능한 독립 모드 */
.header__>.nav>.clipping-button__ {
    flex-direction: row;
    width: auto;
    height: auto;
    padding: 0.25rem 0.75rem;
    background: transparent;
    outline: 0.0625rem solid var(--primary-lv-7);
}

.header__>.nav>.clipping-button__:hover {
    background: var(--primary-lv-6);
}

.header__>.nav>.clipping-button__:active {
    background: var(--primary-lv-7);
}

.header__>.nav>.clipping-button__>.label {
    color: #fff;
    font-size: 0.875rem;
    line-height: 1.25rem;
    white-space: nowrap;
}

.header__>.nav>.clipping-button__.--active {
    background: #fff;
    outline-color: var(--primary-lv-7);
}

.header__>.nav>.clipping-button__.--active>.label {
    color: var(--primary-lv-5);
}

/* 🟥 선형클리핑 모드 — 하단탭(공정시뮬레이션 간트) 숨김. 시점은 공정모델에서 잡아둔 날짜 그대로 유지 🟥 */
body.--theme:has(.header__>.nav>.clipping-button__.--active) .simulation-chart__ {
    display: none;
}

/* 🟥 선형클리핑 모드 — 내부적으로 체크해 둔 공정모델 탭이 선택된 것처럼 보이지 않게 nav 선택 스타일 무효화.
   클리핑 버튼(.--active 흰 배경)만 단독 모드로 강조된다 🟥 */
body.--theme:has(.header__>.nav>.clipping-button__.--active) .header__>.nav>label:has(input:checked) {
    background: var(--primary-lv-5);
}

body.--theme:has(.header__>.nav>.clipping-button__.--active) .header__>.nav>label:has(input:checked)>.label {
    color: #fff;
}

.layer-button__.--active,
.clipping-button__.--active,
.section-button__.--active {
    background: var(--primary-lv-5);
    outline-color: var(--primary-lv-5);
}

.layer-button__.--active>.icon,
.clipping-button__.--active>.icon,
.section-button__.--active>.icon {
    filter: brightness(0) invert(1);
}

.layer-button__.--active>.label,
.clipping-button__.--active>.label,
.section-button__.--active>.label {
    color: #fff;
}

.layer-button__:active,
.clipping-button__:active,
.section-button__:active {
    background: var(--primary-lv-1);
}

.layer-button__>.icon,
.clipping-button__>.icon,
.section-button__>.icon {
    min-width: 1.25rem;
    min-height: 1.25rem;
}

.layer-button__>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -20rem -15rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
}

.clipping-button__>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -11.25rem -15rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
}

.section-button__.--flip>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -1.25rem -45rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
}

.section-button__.--reset>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -7.5rem -45rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
}

.layer-button__>.label,
.clipping-button__>.label,
.section-button__>.label {
    color: var(--primary-lv-5);
    font-size: 0.75rem;
    line-height: 1.25rem;
    letter-spacing: -0.015rem;
}

.z-scale__ {
    position: relative;
    flex: 0 0 auto;
    width: 3rem;
    height: 14.3125rem;
    background: #fff;
    border-radius: 0.75rem;
    outline: 0.0625rem solid #aaa;
    margin-right: -0.25rem;   /* 🟥 side-tools(right 0.75rem) 안에서 z-scale 만 브라우저 우측 0.5rem 에 맞춤 */
}

.z-scale__::after {
    content: '';
    position: absolute;
    top: 0.6597rem;
    left: 0.4375rem;
    width: 1rem;
    height: 13.0556rem;
    background: url('../img/Indicator_z-scale.svg') no-repeat center / contain;
    pointer-events: none;
}

.z-scale__>.input-range-vertical {
    position: absolute;
    left: 58%;
    top: 7.1875rem;
    width: 12.75rem;
    height: 0.75rem;
    transform: translate(-50%, -50%) rotate(-90deg);
    background: none;
    cursor: pointer;
    appearance: none;
}

.z-scale__>.input-range-vertical::-webkit-slider-runnable-track {
    height: 0.25rem;
    border-radius: 0.125rem;
    background: linear-gradient(to right, var(--primary-lv-5) var(--range-fill, 0%), #ddd var(--range-fill, 0%));
}

.z-scale__>.input-range-vertical::-moz-range-track {
    height: 0.25rem;
    border-radius: 0.125rem;
    background: #ddd;
}

.z-scale__>.input-range-vertical::-moz-range-progress {
    height: 0.25rem;
    border-radius: 0.125rem;
    background: var(--primary-lv-5);
}

.z-scale__>.input-range-vertical::-webkit-slider-thumb {
    width: 1rem;
    height: 0.75rem;
    margin-top: -0.25rem;
    border: 0.0625rem solid #aaa;
    border-radius: 0.5rem;
    background: #fff;
    appearance: none;
}

.z-scale__>.input-range-vertical::-moz-range-thumb {
    width: 1rem;
    height: 0.75rem;
    border: 0.0625rem solid #aaa;
    border-radius: 0.5rem;
    background: #fff;
}

.z-scale__>.input-range-vertical:hover::-webkit-slider-thumb {
    background: var(--primary-lv-0);
}

.z-scale__>.input-range-vertical:active::-webkit-slider-thumb {
    background: var(--primary-lv-1);
}

.z-scale__>.input-range-vertical:hover::-moz-range-thumb {
    background: var(--primary-lv-0);
}

.z-scale__>.input-range-vertical:active::-moz-range-thumb {
    background: var(--primary-lv-1);
}

.header__>.nav>.drawing,
.header__>.nav>.instruction,
.header__>.nav>.in-progress {
    gap: 0 !important;
}

.divider__ {
    position: fixed;
    top: 2.8125rem;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 1.5rem;
    z-index: 2;
    cursor: ew-resize;
    touch-action: none;
}

.divider__::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0.125rem;
    background: #aaa;
}

.divider__::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100vw;
    background-image:
        linear-gradient(90deg, rgba(197, 45, 39, 0) 0%, #C52D27 12% 50%, #1D4289 50% 88%, rgba(29, 66, 137, 0) 100%),
        linear-gradient(90deg, rgba(197, 45, 39, 0) 0%, #C52D27 12% 50%, #1D4289 50% 88%, rgba(29, 66, 137, 0) 100%);
    background-size: 100% 0.25rem;
    background-position: top, bottom;
    background-repeat: no-repeat;
    pointer-events: none;
}

.divider__>.divider-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    padding: 0;
    border: none;
    outline: 0.0625rem solid #aaa;
    border-radius: 0.75rem;
    background: #fff;
    cursor: ew-resize;
}

.divider__>.divider-button:hover {
    background: var(--primary-lv-0);
}

.divider__>.divider-button:active {
    background: var(--primary-lv-1);
}

.divider__>.divider-button>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -7.5rem -6.25rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-width: 1.25rem;
    min-height: 1.25rem;
}

.divider__>.left-model,
.divider__>.right-model {
    position: absolute;
    /* top: 0.75rem; */
    width: 12.5rem;
    /* background: #fff; */
    /* border-radius: 0.75rem; */
    /* outline: 0.0625rem solid #aaa; */
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
    cursor: default;
}

.divider__>.left-model {
    right: 50%;
    border-radius: 0 0 0 0.75rem;
    background: #C52D27;
    /* margin-right: 0.8125rem; */
}

.divider__>.right-model {
    left: 50%;
    border-radius: 0 0 0.75rem 0;
    background: #1D4289;
    /* margin-left: 0.8125rem; */
}

.divider__ .selected-model {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    height: 4rem;
    padding: 0 0.5rem 0 0.75rem;
    border-bottom: 0.0625rem solid transparent;
    border-radius: 0.75rem;
    cursor: pointer;
    list-style: none;
}

.divider__ .selected-model::-webkit-details-marker {
    display: none;
}

.divider__ .selected-model:hover {
    background: rgba(0, 0, 0, 0.1);
}

.divider__ .selected-model:active {
    background: rgba(0, 0, 0, 0.2);
}

.divider__ details[open]>.selected-model {
    border-bottom-color: #ddd;
    border-radius: 0.75rem 0.75rem 0 0;
}

/* 접힘 = 위(∧) / 펼침 = 아래(∨) */
.divider__ .selected-model>.toggle {
    margin-left: auto;
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -11.25rem -6.25rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-width: 1.25rem;
    min-height: 1.25rem;
    transform: rotate(90deg);
    filter: brightness(0) invert(1);
}

.divider__ details[open]>.selected-model>.toggle {
    transform: rotate(-90deg);
}

.divider__ .list {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin: 0;
    padding: 0.5rem;
    list-style: none;
    background: #fff;
}

.divider__>.left-model .list {
    border-radius: 0 0 0 0.75rem;
}

.divider__>.right-model .list {
    border-radius: 0 0 0.75rem 0;
}

.divider__ .list>.item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    height: 1.75rem;
    padding: 0 0.75rem;
    border-radius: 0.75rem;
    cursor: pointer;
}

.divider__ .list>.item:not(.is-selected):hover {
    background: var(--primary-lv-0);
}

.divider__ .list>.item.is-selected {
    background: var(--primary-lv-0);
    outline: 0.0625rem solid var(--primary-lv-5);
    cursor: default;
}

.divider__ .selected-model>.icon,
.divider__ .list>.item>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -1.25rem -61.25rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-width: 1.25rem;
    min-height: 1.25rem;
}

.divider__ .selected-model[data-type="design"]>.icon {
    background-position: -1.25rem 0;
}

.divider__ .selected-model[data-type="terrain"]>.icon {
    background-position: -18.75rem 0;
}

.divider__ .selected-model[data-type="drn-cl"]>.icon {
    background-position: -17.5rem 0;
}

.divider__ .selected-model[data-type="drn-hm"]>.icon {
    background-position: -20rem 0;
}

.divider__ .list>.item[data-type="design"]>.icon {
    background-position: -7.5rem -15rem;
}

.divider__ .list>.item[data-type="terrain"]>.icon {
    background-position: -1.25rem -67.5rem;
}

.divider__ .list>.item[data-type="drn-cl"]>.icon {
    background-position: -13.75rem -15rem;
}

.divider__ .list>.item[data-type="drn-hm"]>.icon {
    background-position: -1.25rem -76.25rem;
}

.divider__ .date {
    color: #555;
    letter-spacing: -0.0175rem;
    white-space: nowrap;
}

.divider__ .selected-model>.date {
    color: #fff;
}

.layer__ {
    position: fixed;
    top: calc(2.75rem + 0.0625rem + 0.5rem);
    right: 0.5rem;
    z-index: 3;
    display: flex;
    flex-direction: column;
    width: 15rem;
    max-height: calc(100dvh - 9.5rem - 0.5rem);
    background: #fff;
    border-radius: 1.25rem;
    outline: 0.0625rem solid #aaa;
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
    overflow: hidden;
}

.layer__[hidden] {
    display: none;
}

.layer__>.head {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    flex: 0 0 auto;
    padding: 0.75rem 1rem;
    border-bottom: 0.0625rem solid #ddd;
    cursor: grab;
    touch-action: none;
}

.layer__>.head:active {
    cursor: grabbing;
}

body.is-grabbing,
body.is-grabbing * {
    cursor: grabbing !important;
}

.layer__>.head>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -20rem -15rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-width: 1.25rem;
    min-height: 1.25rem;
}

.layer__>.head>.title {
    color: #111;
}

.layer__>.head>.close {
    margin-left: auto;
    padding: 0;
    border: none;
    background-color: transparent;
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -1.25rem -6.25rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-width: 1.25rem;
    min-height: 1.25rem;
    cursor: pointer;
}

.layer__>.body {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: scroll;
    overflow-x: hidden;
    padding: 0.75rem 0.25rem 0.75rem 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.layer__ .group {
    flex: 0 0 auto;
}

.layer__ .group>.head {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0 0.25rem;
}

.layer__ .group>.head>.title {
    color: #555;
}

.layer__ .group>.head>.toggle-all {
    margin-left: auto;
    flex: 0 0 auto;
    padding: 0.1875rem 0.6875rem;
    border: 0.0625rem solid #aaa;
    border-radius: 0.75rem;
    background: #fff;
    cursor: pointer;
}

.layer__ .group>.head>.toggle-all>.label {
    color: #555;
    font-size: 0.875rem;
    line-height: 1.25rem;
    white-space: nowrap;
}

.layer__ .group>.head>.toggle-all:hover {
    background: var(--primary-lv-0);
}

.layer__ .group>.head>.toggle-all:active {
    background: var(--primary-lv-1);
}

.layer__ .list {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin: 0.5rem 0 0;
    padding: 0;
    list-style: none;
}

.layer__ .list>.loading {
    padding: 0.25rem 0.5rem;
    color: #aaa;
}

.layer__ .list>.item {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    height: 1.75rem;
    padding: 0 0.5rem;
    border-radius: 0.75rem;
    /* cursor: pointer; */
}

.layer__ .list>.item:hover {
    background: var(--primary-lv-0);
}

.layer__ .list>.item>.label {
    color: #111;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.layer__ .bulb {
    display: flex;
    flex: 0 0 auto;
    cursor: pointer;
}

.layer__ .bulb>input {
    display: none;
}

.layer__ .bulb>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -2.5rem -6.25rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-width: 1.25rem;
    min-height: 1.25rem;
}

.layer__ .bulb:has(input:checked)>.icon {
    background-position: -1.25rem -70rem;
}

.layer__ .bulb:has(input:indeterminate)>.icon,
.layer__ .bulb.--indeterminate>.icon {
    background: url('../img/bulb-indeterminate.svg') no-repeat center / contain;
}

.layer__ .list>.chips {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    column-gap: 0.25rem;
    row-gap: 0.5rem;
    margin: 0.25rem 0;
    padding: 0 0.5rem;
}

.layer__ .chips>.chip {
    height: 1.75rem;
    padding: 0;
    border: none;
    outline: 0.0625rem solid #aaa;
    border-radius: 0.75rem;
    background: #fff;
    color: #111;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.25rem;
    letter-spacing: -0.0175rem;
    cursor: pointer;
}

.layer__ .chips>.chip:hover {
    background: var(--primary-lv-0);
}

.layer__ .chips>.chip.is-selected {
    background: var(--primary-lv-0);
    outline-color: var(--primary-lv-5);
}

.allnew-drawing__ {
    top: 3.25rem;
    right: 16rem;
    max-height: calc(100dvh - 3.25rem - 1rem);
}


/* 데이터가 없는 도면 레이어 행(선형중심선 등) — projectManager 가 --disabled 를 건다 */
.allnew-drawing__ .list>.item.--disabled {
    opacity: 0.4;
    pointer-events: none;
}

.allnew-drawing__>.head>.icon {
    background-position: -11.25rem -35rem;
}

.allnew-map__ {
    top: 3.25rem;
    right: 0.5rem;
    max-height: calc(100dvh - 3.25rem - 1rem);
}

.allnew-map__>.head>.icon {
    background-position: -10rem -35rem;
}

.allnew-drawing__>.head>.title>.point,
.allnew-map__>.head>.title>.point {
    color: var(--primary-lv-5);
}

.allnew-map__ .list>.item>.radio {
    display: flex;
    cursor: pointer;
}

.allnew-map__ .list>.item>.radio input {
    display: none;
}

.allnew-map__ .list>.item>.radio>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -16.25rem 0;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-height: 1.25rem;
    min-width: 1.25rem;
}

.allnew-map__ .list>.item>.radio:has(input:checked)>.icon {
    background-position: -8.75rem -35rem;
}

.divider__ .label {
    color: #111;
    white-space: nowrap;
}

.divider__ .selected-model>.label {
    color: #fff;
}

.side-tools__ {
    display: none;
}

body:has(.nav>.drawing input:checked) .side-tools__,
body:has(.nav>.instruction input:checked) .side-tools__,
body:has(.nav>.in-progress input:checked) .side-tools__ {
    display: flex;
}

/* 완성계·진행중 탭 — 직교/원근 토글(.view-type__.--progress, 높이 1.5rem)이 side-tools 맨 위에 끼어들어
   레이어 버튼이 1.5rem + gap 0.75rem 내려간다. 레이어 패널도 같은 값만큼 내려 버튼 상단과 정렬 */
body.--theme:has(.nav>.instruction input:checked) .layer__:not(.allnew-drawing__),
body.--theme:has(.nav>.in-progress input:checked) .layer__:not(.allnew-drawing__) {
    max-height: calc(100dvh - 11.75rem - 0.5rem);
}

.divider__ {
    display: none;
}

body:has(.nav>.in-progress input:checked) .divider__ {
    display: block;
}

body:has(.nav>.in-progress input:checked) .split-slider__,
body:has(.nav>.in-progress input:checked) .model__>.aside__,
body:has(.nav>.in-progress input:checked) .simulation-chart__ {
    display: none;
}

/* 속성창 — 3D 뷰어 3탭(평면/종단·공정모델·진행상태)에서 표시(레이어 모델 행/칩 클릭 선택 효과 공통). 문서 탭에선 숨김 */
body.--theme:not(:has(.nav>.drawing input:checked, .nav>.instruction input:checked, .nav>.in-progress input:checked)) .model__>.model-info__ {
    display: none;
}

.side-tools__>.clipping-button__,
.side-tools__>.z-scale__ {
    display: none;
}

body:has(.nav>.instruction input:checked) .side-tools__>.clipping-button__ {
    display: flex;
}

body:has(.nav>.instruction input:checked) .side-tools__>.z-scale__,
body:has(.nav>.in-progress input:checked) .side-tools__>.z-scale__ {
    display: block;
}

body:has(.nav>.drawing input:checked) .model__>.aside__,
body:has(.nav>.instruction input:checked) .model__>.aside__ {
    display: none;
}

body:has(.nav>.drawing input:checked) .model__ .simulation-chart__>.tabs,
body:has(.nav>.instruction input:checked) .model__ .simulation-chart__>.tabs {
    display: none;
}

/* index(메인) — theme 과 동일하게 탭 바 숨김(theme 규칙은 라디오 input 기반 :has 라 index 버튼 탭엔 안 걸림) */
body.--main .model__ .simulation-chart__>.tabs {
    display: none;
}

/* index(메인) — 시트를 끝까지 내리면 리사이즈 바 하단 돌출분이 뷰포트를 넘어 페이지 스크롤이 생김.
   theme 은 viewer-stack overflow:hidden 이 잘라주지만 index 엔 클리핑 조상이 없어 페이지에서 차단 */
body.--main {
    overflow: hidden;
}

/* index(메인) — 시트는 헤더(z-index 100) 바로 아래: 레이어즈 패널(모델/도면/지도, 헤더 스택 소속)이
   시트 위에 떠야 한다. 드래그 배선이 없어 리사이즈 바가 헤더까지 올라올 일도 없다.
   초기 높이는 공용 규칙(헤더 제외 50%)을 그대로 쓴다 */
body.--main .model__ .simulation-chart__ {
    z-index: 99;
    background: #5C5C5C;   /* rgb(92,92,92) — index 시트 전용 배경 */
}

/* index(메인) — 종단 패널 캔버스 영역도 시트 배경색으로(공용 규칙의 검정 #000 을 덮음).
   common/drawingView 의 씬 배경(0x5c5c5c)과 같은 값이라 로드 전후로 색이 안 튄다 */
body.--main .model__ .simulation-chart__ .panel>.plan-canvas {
    background: #5C5C5C;
}

/* 🟥 index(메인) — 설정 창(구 레이어즈 지도 패널) 헤드 기어: setting--main(200,560 #003675).
   .allnew-map__ 기본 헤드 아이콘(접힌지도)보다 뒤에 선언되어 이긴다 */
.allnew-setting__>.head>.icon {
    background-position: -12.5rem -35rem;
}

/* 🟥 index(메인) — 설정 창은 다른 오버레이(통합 레이어 z:3)보다 위 */
body.--main .allnew-setting__ {
    z-index: 4;
}

/* 🟥 index(메인) — 우측 정보창(model-info__): 모델 원클릭 시 .--visible 로 표시(배선은 추후 JS).
   헤드 아이콘 model--main(20,560 #003675), 폭은 시안(경간구성이 안 잘리는 21rem) */
body.--main .model__>.model-info__ {
    width: 21rem;
}

body.--main .model__>.model-info__>.head>.icon {
    background-position: -1.25rem -35rem;
}

/* index(메인) 탭별 UI 전환(:has, JS 없음) — 평면/종단 = 바텀시트 · 공정모델 = 지도만 · 진행상태 = 좌우 분할 */
body.--main:not(:has(.nav>.drawing input:checked)) .model__ .simulation-chart__ {
    display: none;
}

/* 직교/원근 세그먼트 — 평면/종단 탭은 2D 고정(직교)이라 숨기고, 공정모델·모델비교(3D)에서만 노출 */
body.--main:has(.nav>.drawing input:checked) .model__>.view-type__ {
    display: none;
}

body:has(.nav>.progress-status input:checked) .divider__ {
    display: block;
}

/* 🟥 index/theme 모델비교 분할 UI 재디자인 — 상하단 그라데이션 라인 제거,
   칩은 아이콘 없이 텍스트만: 배경은 분할선 쪽이 진하고 화면 끝으로 갈수록 투명해지는 lv-5 그라데이션,
   라벨 1.75rem(28px), 날짜는 Pretendard(mono 해제)+오퍼시티 0.6. 드롭다운 목록은 흰 카드로 분리 */
body.--main .divider__::before, body.--theme .divider__::before {
    display: none;
}

body.--main .divider__>.left-model, body.--theme .divider__>.left-model,
body.--main .divider__>.right-model, body.--theme .divider__>.right-model {
    width: 25rem;
    box-shadow: none;
    border-radius: 0;
}

body.--main .divider__>.left-model, body.--theme .divider__>.left-model {
    background: linear-gradient(to left, var(--primary-lv-5), rgb(from var(--primary-lv-5) r g b / 0));
}

body.--main .divider__>.right-model, body.--theme .divider__>.right-model {
    background: linear-gradient(to right, var(--primary-lv-5), rgb(from var(--primary-lv-5) r g b / 0));
}

/* 칩 클러스터는 분할선 양옆에 붙는다(시안) — 좌 칩은 오른끝, 우 칩은 왼끝 정렬 */
body.--main .divider__>.left-model>.selected-model, body.--theme .divider__>.left-model>.selected-model {
    justify-content: flex-end;
    padding-right: 1rem;
}

body.--main .divider__>.right-model>.selected-model, body.--theme .divider__>.right-model>.selected-model {
    justify-content: flex-start;
    padding-left: 1rem;
}

body.--main .divider__ .selected-model:hover, body.--theme .divider__ .selected-model:hover,
body.--main .divider__ .selected-model:active, body.--theme .divider__ .selected-model:active {
    background: transparent;
}

body.--main .divider__ .selected-model>.toggle, body.--theme .divider__ .selected-model>.toggle {
    margin-left: 0;
}

body.--main .divider__ .selected-model>.label, body.--theme .divider__ .selected-model>.label {
    font-size: 1.75rem;
}

body.--main .divider__ .date, body.--theme .divider__ .date {
    font-family: 'Pretendard';
    min-width: 2.75rem;
    opacity: 0.6;
}

body.--main .divider__ details[open]>.selected-model, body.--theme .divider__ details[open]>.selected-model {
    border-bottom-color: transparent;
    border-radius: 0.75rem;
}

/* 드롭다운 목록 — 흰 카드로 분리해 칩 클러스터(분할선 쪽) 아래에 절대 배치 */
body.--main .divider__ .list, body.--theme .divider__ .list {
    position: absolute;
    top: 4.25rem;
    width: 11rem;
    background: #fff;
    border-radius: 0.75rem;
    box-shadow: 0 0.5rem 1.5rem 0 rgba(17, 17, 17, 0.16);
    border: 0.0625rem solid #aaa;
}

body.--main .divider__>.left-model>.list, body.--theme .divider__>.left-model>.list {
    left: auto;
    right: 0.5rem;
}

body.--main .divider__>.right-model>.list, body.--theme .divider__>.right-model>.list {
    left: 0.5rem;
    right: auto;
}

body.--main .divider__ .list>.item>.icon, body.--theme .divider__ .list>.item>.icon {
    display: none;
}

/* 진행상태 탭 — 레이어 도면 패널: 핑크 보더(0.125rem) */
/* 레이어 모델 패널의 (좌측)/(우측)/(양쪽) — 실시설계모델이 올라간 분할면. 문구는 projectSplit 이 채운다.
   세 경우 모두 같은 핑크(패널 보더와 한 세트) — 좌우를 색으로 구분하지 않는다. */
.allnew-aside__>.head>.title>.side {
    display: none;
    color: var(--color-pink);
}

body:has(.nav>.progress-status input:checked) .allnew-drawing__ {
    outline: 0.125rem solid var(--color-pink);
    /* 루트 폰트가 0.8333vw 클램프라 1920에서 15.9999px → 0.125rem 이 1.9999px 로 계산돼 1px 로 내림되는 것 보정 */
    outline-width: round(0.125rem, 1px);
}

body:has(.nav>.progress-status input:checked) .allnew-aside__>.head>.title>.side {
    display: inline;
}

/* 종단면도 그룹은 하단 종단 뷰어(.panel.--profile)의 레이어 목록이다 — 그 뷰어가 없는 탭에선 숨긴다.
   (공정모델 = 지도만 · 진행상태 = 좌우 분할, 둘 다 바텀시트 없음) */
body:has(.nav>.progress-status input:checked) .allnew-drawing__ .group.--vertical,
body:has(.nav>.process-model input:checked) .allnew-drawing__ .group.--vertical {
    display: none;
}

/* 측량성과 2종(평면기준점·SAT.POINTER) — 3D 점이 진행상태 탭에서만 그려지므로(themeSurveyPoints)
   레이어(미지정) 그룹의 그 행도 같은 탭에서만 보인다. 선형중심선은 탭 무관. */
.allnew-drawing__ .group.--unassigned>.list>.item.--survey {
    display: none;
}

body:has(.nav>.in-progress input:checked) .allnew-drawing__ .group.--unassigned>.list>.item.--survey {
    display: flex;
}

.layer__ .group {
    display: none;
}

body:has(.nav>.drawing input:checked) .layer__ .group.--plan,
body:has(.nav>.drawing input:checked) .layer__ .group.--vertical,
body:has(.nav>.instruction input:checked) .layer__ .group.--cpt,
body:has(.nav>.in-progress input:checked) .layer__ .group.--plan,
body:has(.nav>.in-progress input:checked) .layer__ .group.--cpt,
body:has(.nav>.in-progress input:checked) .layer__ .group.--survey {
    display: block;
}

.allnew-drawing__ .group,
.allnew-map__ .group {
    display: block;
}

body.--sub .header__>.project>.title>.info {
    display: none;
}

body.--sub .layer__ .group {
    display: block;
}

body.--sub .layer-button__ {
    position: fixed;
    top: 11.5rem;
    right: calc(0.75rem + var(--raside-open, 0rem));
    z-index: 3;
}

/* 🟥 설계단면 반전(전면/후면) — three-container(우측 어사이드가 밀고 나온 나머지 영역) 가로 정가운데,
   헤더 아래 0.5rem. 어사이드 개폐(--raside-open)에 따라 중앙이 따라간다 */
body.--sub .section-tools__ {
    position: fixed;
    top: calc(2.75rem + 0.0625rem + 0.5rem);
    left: calc((100vw - var(--raside-open, 0rem)) / 2);
    transform: translateX(-50%);
    z-index: 3;
    transition: left 0.25s ease;
}

/* 반전 버튼 — 정사각(아이콘 위+라벨 아래) → 가로 필(아이콘은 기존 clipping-invert 그대로) */
.section-button__.--flip {
    flex-direction: row;
    gap: 0.25rem;
    width: auto;
    height: auto;
    padding: 0.25rem 0.75rem;
    border-radius: 0.75rem;
}

.section-button__.--flip>.label {
    color: #555;
    font-size: 0.875rem;
    line-height: 1.25rem;
    white-space: nowrap;
}

/* 활성(반전 ON) — 어두운 배경 위 흰 라벨(공용 .--active 규칙이 위 #111 에 밀리지 않게 재선언) */
.section-button__.--flip.--active>.label {
    color: #fff;
}

/* :not(.allnew-drawing__) — 헤더 레이어즈의 도면 창은 index/theme 와 똑같은 순정 .layer__ 모양이어야 해서
   sub 전용 위치·트리 들여쓰기 규칙에서 전부 제외한다 */
body.--sub .layer__:not(.allnew-drawing__) {
    top: calc(2.75rem + 0.0625rem + 0.5rem);
    right: 0.5rem;
    max-height: calc(100dvh - (2.75rem + 0.0625rem + 0.5rem) - 0.5rem);
}

body.--sub .layer-button__>.icon,
body.--sub .layer__>.head>.icon {
    background-position: -6.25rem -45rem;
}

body.--sub .layer__ .group>.head>.title {
    color: #111;
}

body.--sub .layer__:not(.allnew-drawing__) .group:has(>.head)>.list>.item {
    position: relative;
    margin-left: 1.5rem;
}

body.--sub .layer__:not(.allnew-drawing__) .group:has(>.head)>.list>.item::after {
    content: "";
    position: absolute;
    left: -0.625rem;
    top: -0.125rem;
    bottom: -0.125rem;
    width: 0.625rem;
    border-left: 0.0625rem solid #ddd;
    background: linear-gradient(#ddd, #ddd) no-repeat left center / 100% 0.0625rem;
    pointer-events: none;
}

body.--sub .layer__:not(.allnew-drawing__) .group:has(>.head)>.list>.item:last-child::after {
    bottom: 50%;
    background-position: left bottom;
}

/* sub — 헤더: 기존 레이어 버튼·구분선은 레이어즈 그룹(모델/도면)으로 대체(마크업·배선 유지, CSS 숨김) */
body.--sub .header__>.profile>.layer,
body.--sub .header__>.profile>.divider {
    display: none;
}

/* sub — 레이어즈 버튼·패널 아이콘은 sub 셀(y=720 행: model 40,720 · local 160,720 · 도면 200,720).
   도면 창 위치·그룹 트리 선은 위 body.--sub .layer__ 규칙(사용자 지정 초기값)을 그대로 물려받는다 */
body.--sub .header__>.nav>.layers>.model[open]>.button>.icon {
    background-position: -2.5rem -45rem;
}

body.--sub .header__>.nav>.layers>.drawing[open]>.button>.icon {
    background-position: -12.5rem -45rem;
}

body.--sub .allnew-aside__>.head>.icon,
body.--sub .allnew-aside__>.list>.item>.icon {
    background-position: -2.5rem -45rem;
}

body.--sub .allnew-aside__>.list>.item>.act.--location {
    background-position: -10rem -45rem;
}

body.--sub .allnew-drawing__>.head>.icon {
    background-position: -12.5rem -45rem;
}

/* sub — 도면 창은 index/theme 와 동일한 순정 .layer__ 모양(위 :not 제외 참고).
   지도 패널이 없어 우측 끝에 붙인다(theme 과 동일) */
body.--sub .allnew-drawing__ {
    right: 0.5rem;
}

/* sub — 도면 레이어즈는 설계단면 탭 전용이다(도면 타일셋이 그때만 로드된다) → 그 외 탭에선 비활성.
   열려 있던 창도 숨긴다 — details[open] 은 유지되어 설계단면으로 돌아오면 다시 보인다 */
body.--sub:not(:has(.nav>.design-section input:checked)) .header__>.nav>.layers>.drawing {
    opacity: 0.4;
    pointer-events: none;
}

body.--sub:not(:has(.nav>.design-section input:checked)) .header__>.nav>.layers>.drawing>article {
    display: none;
}

/* 설계단면에서 열어둔 채([open]) 돌아와도 버튼은 그냥 닫힘 모양 — 흰 배경이 dim 되어 떠 보이는 것 방지 */
body.--sub:not(:has(.nav>.design-section input:checked)) .header__>.nav>.layers>.drawing[open]>.button {
    background-color: transparent;
}

body.--sub:not(:has(.nav>.design-section input:checked)) .header__>.nav>.layers>.drawing[open]>.button>.label {
    color: #fff;
}

body.--sub:not(:has(.nav>.design-section input:checked)) .header__>.nav>.layers>.drawing[open]>.button>.icon {
    background-position: -22.5rem 0;
}

/* theme/sub — 시공도서 문서 탭으로 나가면(같은 name="header" 라디오라 뷰어 nav 라디오가 전부 해제됨)
   레이어즈 전체 비활성 + 열린 창 숨김. 설계도서는 팝업(window.open)이라 페이지 상태가 안 바뀐다.
   뷰어 탭 라디오만 .header__>.nav 의 직계 label 이라 이 조건이 레이어즈 nav(.--layers)의 전구·익스펜드 체크박스에 안 걸린다 */
body.--theme:not(:has(.header__>.nav>label input:checked)) .header__>.nav>.layers,
body.--sub:not(:has(.header__>.nav>label input:checked)) .header__>.nav>.layers {
    opacity: 0.4;
    pointer-events: none;
}

body.--theme:not(:has(.header__>.nav>label input:checked)) .header__>.nav>.layers details>article,
body.--sub:not(:has(.header__>.nav>label input:checked)) .header__>.nav>.layers details>article {
    display: none;
}

/* details[open] 잔존 시 버튼은 닫힘 모양으로 강제(CSS 는 open 속성을 못 지움) — 뷰어 탭 복귀 시 원상복구 */
body.--theme:not(:has(.header__>.nav>label input:checked)) .header__>.nav>.layers details[open]>.button,
body.--sub:not(:has(.header__>.nav>label input:checked)) .header__>.nav>.layers details[open]>.button {
    background-color: transparent;
}

body.--theme:not(:has(.header__>.nav>label input:checked)) .header__>.nav>.layers details[open]>.button>.label,
body.--sub:not(:has(.header__>.nav>label input:checked)) .header__>.nav>.layers details[open]>.button>.label {
    color: #fff;
}

body.--theme:not(:has(.header__>.nav>label input:checked)) .header__>.nav>.layers>.model[open]>.button>.icon,
body.--sub:not(:has(.header__>.nav>label input:checked)) .header__>.nav>.layers>.model[open]>.button>.icon {
    background-position: -1.25rem 0;
}

body.--theme:not(:has(.header__>.nav>label input:checked)) .header__>.nav>.layers>.drawing[open]>.button>.icon,
body.--sub:not(:has(.header__>.nav>label input:checked)) .header__>.nav>.layers>.drawing[open]>.button>.icon {
    background-position: -22.5rem 0;
}

/* 🟥 theme/sub — 레이어 모델 창도 index 와 같이 우측 끝. 도면 창(.layer__ z:3)이 모델(z:1) 위에 겹친다.
   설정은 두 페이지 모두 창 없이 '기능 준비 중' 알림 버튼 그대로 */
body.--theme .allnew-aside__,
body.--sub .allnew-aside__ {
    left: auto;
    right: 0.5rem;
}

/* sub 좌측 메뉴 — 통합 창(theallnew-aside) 바디 맨 위(단면확인 탭의 단면확인 행). 창 바디가 스크롤하므로 자체 스크롤·테두리 없음.
   그룹 제목은 창 제목이 대신한다(숨김 — subSection 좌측 메뉴 매칭 키라 마크업엔 유지). 리스트 모양(들여쓰기·세로선)은 같은 창 도면 리스트 규칙 그대로 */
.left-aside__ {
    display: flex;
    flex-direction: column;
}

.left-aside__>.group {
    display: flex;
    flex-direction: column;
}

body:has(.header__>.nav>.instruction input:checked) .left-aside__>.group:not(.--instruction),
body:has(.header__>.nav>.design-section input:checked) .left-aside__>.group:not(.--design-section) {
    display: none;
}

/* 모델 탭 — 좌측 메뉴 없음(완성계 행은 상태로만 남는다, subSection) */
body:has(.header__>.nav>.instruction input:checked) .left-aside__ {
    display: none;
}

.left-aside__>.group>.head {
    display: none;
}

/* '선택됨' 외곽선(0.0625rem)이 창 바디 오른쪽 끝(스크롤 영역)에서 잘리지 않게 — 기성객체 리스트와 같은 여백 */
.theallnew-aside__ .left-aside__>.group>.list {
    margin-right: 0.0625rem;
}

.left-aside__>.group>.list>.item {
    display: flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: 0.75rem;
    cursor: pointer;
}

.left-aside__>.group>.list>.item>.label {
    flex-grow: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.left-aside__>.group>.list>.item:hover {
    background: var(--primary-lv-0);
}

.left-aside__>.group>.list>.item:active {
    background: var(--primary-lv-1);
}

.left-aside__>.group>.list>.empty {
    display: flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    color: #aaa;
    cursor: default;
}

.left-aside__>.group>.list>.item.is-selected {
    background: var(--quaterary-lv-0);
    outline: 0.0625rem solid var(--quaterary-lv-5);
    cursor: default;
}

.left-aside__>.group>.list>.sub-head {
    display: flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    cursor: default;
}

.left-aside__>.group>.list>.sub-head>.title {
    color: var(--quaterary-lv-5);
}

/* 레이어 창 — 모델 탭 단계 행이 고른 레이어 밖의 줄(subLayerPanel 프리셋) */
.theallnew-aside__ .item.--filtered {
    display: none !important;
}

body.--sub {
    --rw-object: 20rem;
    --rw-drawing: 40rem;
    --rw-quantity: 30rem;
    --raside-open: 0rem;
}

body.--sub:has(.right-aside__.--object.--visible) {
    --raside-open: var(--rw-object);
}

body.--sub:has(.right-aside__.--drawing.--visible) {
    --raside-open: var(--rw-drawing);
}

body.--sub:has(.right-aside__.--quantity.--visible) {
    --raside-open: var(--rw-quantity);
}

.right-aside__ {
    display: flex;
    position: fixed;
    z-index: 1;
    top: calc(2.75rem + 0.0625rem);
    right: 0;
    width: var(--rw-object, 20rem);
    height: calc(100dvh - 2.75rem - 0.0625rem);
    flex-direction: column;
    background: #fff;
    border-left: 0.0625rem solid #aaa;
    box-shadow: -0.5rem 0 1.5rem 0 rgba(17, 17, 17, 0.16);
    overflow-y: scroll;
    visibility: hidden;
    transform: translateX(100%);
    transition: transform 0.25s ease, visibility 0s linear 0.25s;
}

.right-aside__.--visible {
    visibility: visible;
    transform: translateX(0);
    transition: transform 0.25s ease, visibility 0s;
}

body.--sub .model__>#three-container {
    width: calc(100vw - var(--raside-open, 0rem));
}

body.--sub .model__>.view-cube__ {
    right: calc(0.5rem + var(--raside-open, 0rem));
}

body.--sub .model__>.scale__ {
    right: calc(0.75rem + var(--raside-open, 0rem));
}

body.--sub .view-type__.--sub {
    right: calc(4.5rem + var(--raside-open, 0rem));   /* 🟥 기즈모 중앙(우측 4.5rem) + 어사이드 오프셋 추종 */
}

body.--sub .model__>#three-container,
body.--sub .model__>.view-cube__,
body.--sub .model__>.scale__,
body.--sub .view-type__.--sub,
body.--sub .layer-button__,
body.--sub .layer__ {
    transition: width 0.25s ease, right 0.25s ease;
}

.right-aside__ .btn {
    flex: 0 0 auto;
    padding: 0.25rem 0.75rem;
    border: 0.0625rem solid #aaa;
    border-radius: 0.75rem;
    background: #fff;
    color: #555;
    white-space: nowrap;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    line-height: 1.25rem;
    letter-spacing: -0.0175rem;
}

.right-aside__ .btn:hover {
    background: var(--primary-lv-0);
}

.right-aside__ .btn:active {
    background: var(--primary-lv-1);
}

.right-aside__.--object>.info {
    display: flex;
    flex-direction: column;
}

.right-aside__.--object>.info>.head {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.75rem 1rem;
    border-bottom: 0.0625rem solid #ddd;
}

.right-aside__.--object>.info>.head>.icon {
    background-image: url('../img/CBIM_icon.svg');
    background-size: 31.25rem 77.5rem;
    background-position: -11.25rem -45rem;
    background-repeat: no-repeat;
    width: 1.25rem;
    height: 1.25rem;
    min-width: 1.25rem;
    min-height: 1.25rem;
}

.right-aside__.--object>.info>.wrap {
    display: flex;
    border-bottom: 0.0625rem solid #ddd;
}

.right-aside__.--object>.info>.wrap>.label {
    flex: 0 0 6rem;
    padding: 0.5rem 0 0.5rem 0.75rem;
    color: #555;
    word-break: keep-all;
    background: linear-gradient(90deg, #F5ECE6 0%, #FFF 100%);
}

.right-aside__.--object>.info>.wrap>.value {
    flex: 1 1 auto;
    padding: 0.5rem;
    color: #111;
    word-break: keep-all;
}

.right-aside__.--object>.info>.wrap>.value>p {
    margin: 0;
}

.right-aside__.--drawing {
    overflow: hidden;
    width: var(--rw-drawing, 40rem);
}

/* 🟥 도면명 헤드 행 — 검토 행(wrap)과 같은 그라데이션 라벨 컬럼 */
.right-aside__.--drawing>.head {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-bottom: 0.0625rem solid #ddd;
}

.right-aside__.--drawing>.head>.label {
    flex: 0 0 6rem;
    align-self: stretch;
    display: flex;
    align-items: center;
    padding: 0.75rem 0 0.75rem 1rem;
    color: #555;
    background: linear-gradient(90deg, #F5ECE6 0%, #FFF 100%);
}

.right-aside__.--drawing>.head>.value {
    color: #111;
    font-weight: 500;
}

.right-aside__.--drawing>.head>.btn {
    margin: 0.5rem 0.5rem 0.5rem auto;
}

.right-aside__.--drawing>.preview {
    min-height: 20rem;
    background: #eee;
    flex: 1;
}

.right-aside__.--drawing>.review {
    display: flex;
    flex-direction: column;
}

/* 🟥 검토 행 — 라벨 컬럼을 --object 정보표와 같은 그라데이션(행 왼쪽 끝부터 채움)으로 */
.right-aside__.--drawing>.review>.wrap {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-top: 0.0625rem solid #ddd;
}

.right-aside__.--drawing>.review>.wrap>.label {
    flex: 0 0 6rem;
    align-self: stretch;
    display: flex;
    align-items: center;
    padding: 0.75rem 0 0.75rem 1rem;
    color: #555;
    background: linear-gradient(90deg, #F5ECE6 0%, #FFF 100%);
}

.right-aside__.--drawing>.review>.wrap>.value {
    flex: 1 1 auto;
    padding: 0.75rem 0;
    color: #111;
    word-break: keep-all;
}

.right-aside__.--drawing>.review>.wrap>.value>p {
    margin: 0;
}

.right-aside__.--drawing>.review>.wrap>.value.--warn {
    color: var(--color-dahong);
    font-weight: 500;
}

.right-aside__.--drawing>.review>.wrap>.btn {
    margin: 0.5rem 0.5rem 0.5rem auto;
}

.right-aside__.--quantity {
    padding-left: 0.5rem;
    width: var(--rw-quantity, 30rem);
}

.right-aside__.--quantity>.head {
    padding: 0.75rem 1rem;
}

.right-aside__.--quantity>.table {
    width: 100%;
    table-layout: fixed;
    border-collapse: separate;
    border-spacing: 0;
    border-left: 0.0625rem solid #aaa;
    border-right: 0.0625rem solid #aaa;
    border-bottom: 0.0625rem solid #aaa;
}

.right-aside__.--quantity>.table>tbody>tr:last-child>td {
    border-bottom: none;
}

.right-aside__.--quantity>.table>thead {
    position: sticky;
    top: 0;
    z-index: 1;
}

.right-aside__.--quantity>.table>thead>tr>th {
    padding: 0.5rem;
    text-align: center;
    font-size: 0.875rem;
    font-weight: 500;
    background: #eee;
    border-top: 0.0625rem solid #aaa;
    border-bottom: 0.0625rem solid #aaa;
    border-right: 0.0625rem solid #aaa;
}

.right-aside__.--quantity>.table>thead>tr>th:last-child {
    border-right: none;
}

.right-aside__.--quantity>.table>tbody>tr>td {
    padding: 0.375rem 0.5rem;
    font-size: 0.875rem;
    color: #111;
    border-bottom: 0.0625rem solid #ddd;
    border-right: 0.0625rem solid #ddd;
    word-break: keep-all;
    vertical-align: top;
}

.right-aside__.--quantity>.table>tbody>tr>td:last-child {
    border-right: none;
}

.right-aside__.--quantity>.table>tbody>tr.major-row {
    background: #eee;
    font-weight: 500;
}

.right-aside__.--quantity>.table th.no,
.right-aside__.--quantity>.table td.no {
    width: 5rem;
    text-align: left;
    color: #555;
}

.right-aside__.--quantity>.table th.unit,
.right-aside__.--quantity>.table td.unit {
    width: 2.75rem;
    text-align: center;
    color: #555;
}

.right-aside__.--quantity>.table th.quantity,
.right-aside__.--quantity>.table td.quantity {
    width: 4rem;
    text-align: right;
}

.right-aside__.--quantity>.table>tbody>tr.major-row>td.no {
    color: #111;
}

/* 3D 모델 로딩 표시 회전 (preview3d.js의 .loader) — @keyframes는 중첩 규칙 안에 두면 안 먹어 최상위에 둔다 */
@keyframes preview-loader-rotation {
    0%   { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
