/* 업종 페이지 「왜」 칸 — 버카다 개요 꼴 시안 (11/06 · ?demo=e 일 때만 · 움직임 = works-industry-unfold.js · 판 = works-clip-engine.css)
 * 넓은 장면 → 첫 이유(lead) → 지그재그 줄. 광산 2번 칸(.wm-unfold · works-wf-mining.css)과 같은 값. 색은 토큰만.
 * ?demo=e 이면 그 칸의 원래 본문을 숨긴다(내용은 장면 판과 줄 글이 대신 말한다). */
.wc-why[data-show='e'] .wc-why__body,
.wi-fac-scene[data-show='e'] .wi-fac-scene__list { display: none; }

.wi-unfold { margin-top: var(--wl1002-space-56); }
.wi-unfold[hidden] { display: none; }
.wi-unfold__wide .clip { aspect-ratio: 2 / 1; --u: 0.46cqw; }
.wi-unfold__lead { margin-top: var(--wl1002-space-32); }
.wi-unfold__lead .wi-unfold__text { max-width: calc(50% - var(--wl1002-space-16)); }
.wi-unfold__title { margin: 0; font: var(--wl1002-subtitle); letter-spacing: var(--wl1002-tracking); color: var(--wl1002-text-main); word-break: keep-all; }
.wi-unfold__text { margin: var(--wl1002-space-16) 0 0; font: var(--wl1002-text); letter-spacing: var(--wl1002-tracking); color: var(--wf-700); word-break: keep-all; }
.wi-unfold__row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: var(--wl1002-space-32); align-items: center; margin-top: var(--wl1002-space-56); }
.wi-unfold__lead + .wi-unfold__row { margin-top: var(--wl1002-space-96); }
.wi-unfold__row--flip .wi-unfold__body { order: -1; }
.wi-unfold__row .clip { aspect-ratio: 3 / 2; --u: 0.74cqw; --caption-height: calc(23 * var(--u)); } /* 판 글 = 1440 에서 제목 약 16px · 판 폭 36%(JS) */

@media screen and (max-width: 767px) {
  .wi-unfold { margin-top: var(--wl1002-space-32); }
  /* 휴대폰 — 넓은 장면은 판이 너무 작아 읽히지 않으므로 그림만(판 · 고리 층 숨김) */
  .wi-unfold__wide .clip__layer { display: none; }
  .wi-unfold__lead .wi-unfold__text { max-width: none; }
  .wi-unfold__row { grid-template-columns: minmax(0, 1fr); row-gap: var(--wl1002-space-16); }
  .wi-unfold__lead + .wi-unfold__row { margin-top: var(--wl1002-space-56); }
  .wi-unfold__row--flip .wi-unfold__body { order: 0; }
  .wi-unfold__row .clip { aspect-ratio: 4 / 3; --u: 0.95cqw; }
  .wi-unfold__row .clip__panel { width: 52% !important; }
  .wi-unfold__row .clip__pill { left: 4% !important; translate: 0 calc(-5 * var(--u)); } /* 11/06 꾸밈 배지(pill) — 휴대폰은 칸이 4:3 이라 배지가 아래 끝에 닿으므로 왼쪽에 붙이고 조금 올린다 */
}

/* 시설관리 3번 칸 「건물 어디서」 열 — ?demo=e 에서 층 그림 대신 3D 건물 단면 그림 + 오르내리는 승강기 (11/06 · 움직임 = works-industry-unfold.js buildTower)
 * 그림 원본 1024 × 1536. 행 높이 = 그림의 층 높이(바닥판 가운데끼리 · px) × 그림 폭 / 1024 → 표 글이 그림 층과 나란히 선다.
 * 글이 층 높이에 안 들어가는 폭이면 JS 가 is-tower-stack 으로 바꿔 그림을 표 위에 둔다. */
.wi-tower { display: none; }
.wi-fac-build[data-show='e'] .wi-fac-build__table { position: relative; container-type: inline-size; --tower-width: 40cqw; }
.wi-fac-build[data-show='e'] .wi-tower {
  display: block;
  position: relative;
  z-index: 1;
  aspect-ratio: 1024 / 1536;
  overflow: hidden;
  border-radius: var(--wl1002-radius-card);
  background: var(--wf-100);
}
.wi-tower__base { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }
.wi-tower__shaft { position: absolute; left: calc(832 / 1024 * 100%); top: calc(138 / 1536 * 100%); width: calc(132 / 1024 * 100%); height: calc(1182 / 1536 * 100%); overflow: hidden; }
/* 11/11 지현 님 그림 13 「엘리베이터 감싸고있는 네모 검정 보더는 뭘까?」 → 칸 그림(facility-tower-car.jpg 118 × 204)에 함께 잘린 어두운 통로(왼쪽 2 · 오른쪽 4 · 위 17 · 아래 5px)가 바탕 통로와 맞지 않아 네모 테두리로 보였음
 * → 칸 몸체만 다시 자름 = facility-tower-car-body.png(원본 칸 그림의 x 2 ~ 113 · y 17 ~ 198 · 112 × 182) · 왼쪽 6 → 8 · 폭 118 → 112 · 높이 204 → 182 · 칸 안 바닥 위치는 그대로(JS CAR_FLOOR 177 → 160) · 옛 그림 파일은 남김 */
.wi-tower__car { position: absolute; top: 0; left: calc(8 / 132 * 100%); display: block; width: calc(112 / 132 * 100%); height: calc(182 / 1182 * 100%); will-change: transform; }
.wi-fac-build[data-show='e'] .wi-fac-floor { background: none; box-shadow: none; }
.wi-fac-build[data-show='e'] .wi-fac-floor::after,
.wi-fac-build[data-show='e'] .wi-fac-floor__mark,
.wi-fac-build[data-show='e'] .wi-fac-floor__level { display: none; }

/* 넓은 화면 — 그림이 표 첫 열 */
.wi-fac-build[data-show='e'] .is-tower-side .wi-tower { position: absolute; left: 0; width: var(--tower-width); }
.is-tower-side .wi-fac-build__row,
.is-tower-side .wi-fac-build__row.is-head { grid-template-columns: var(--tower-width) minmax(0, 2fr) minmax(0, 3fr) minmax(0, 4fr); }
.is-tower-side .wi-fac-build__rows > li { min-height: 0; }
.is-tower-side .wi-fac-build__rows > li:nth-child(1) { height: calc(var(--tower-width) * 141 / 1024); }
.is-tower-side .wi-fac-build__rows > li:nth-child(2) { height: calc(var(--tower-width) * 167 / 1024); }
.is-tower-side .wi-fac-build__rows > li:nth-child(3) { height: calc(var(--tower-width) * 162 / 1024); }
.is-tower-side .wi-fac-build__rows > li:nth-child(4) { height: calc(var(--tower-width) * 174 / 1024); }
.is-tower-side .wi-fac-build__rows > li:nth-child(5) { height: calc(var(--tower-width) * 178 / 1024); }
.is-tower-side .wi-fac-build__rows > li:nth-child(6) { height: calc(var(--tower-width) * 169 / 1024); }
.is-tower-side .wi-fac-build__rows > li:nth-child(7) { height: calc(var(--tower-width) * 167 / 1024); }
.is-tower-side .wi-fac-build__rows > li:nth-child(8) { height: calc(var(--tower-width) * 171 / 1024); }
.is-tower-side .wi-fac-build__rows > li:nth-child(9) { height: calc(var(--tower-width) * 207 / 1024); }

/* 좁은 화면 — 그림을 표 위에(층 그림 열은 숨김) */
.is-tower-stack .wi-tower { width: min(100%, 420px); margin: 0 auto var(--wl1002-space-32); }
.is-tower-stack .wi-fac-floor { display: none; }
@media screen and (min-width: 768px) {
  .is-tower-stack .wi-fac-build__row,
  .is-tower-stack .wi-fac-build__row.is-head { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr) minmax(0, 5fr); }
  .is-tower-stack .wi-fac-build__col:first-child { grid-column: auto; }
}
