/* =============================================================================
 * woosungjung.com — pages/teaching.css
 * 교육 페이지 전용.
 * 공통 조각은 여기 다시 만들지 않는다 —
 *   .row .badge .tl .box .link .todo → components.css
 *   .head .lead · section · .eyebrow → layout.css
 *   .grid-three .grid-cards          → base.css
 * ========================================================================== */

/* ---------- 본문 컬럼 타이포 (3단·2단 공용) ---------- */
.tprose h2 {
  font-family: var(--serif);
  font-weight: 300;
  font-size: 27px;
  line-height: 1.2;
  margin-bottom: 14px;
}
.tprose h2.lg { font-size: 31px; }

.tprose p { font-size: 14px; color: var(--sub); margin-bottom: 13px; }
.tprose p:last-child { margin-bottom: 0; }
/* 눈이 먼저 가야 하는 단락 — 본문색으로 올린다 */
.tprose p.hi { color: var(--hanji); }
.tprose p.hi.lg { font-size: 15px; }
.tprose b { font-weight: 400; color: var(--hanji); }

.tprose .link { margin-top: 14px; }

/* ---------- 온라인 수강 국가 칩 ---------- */
.geo { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 15px; }
.geo span {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 400;
  color: var(--dim);
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 4px 10px;
}

/* ---------- 지금 나가는 곳 (.box 를 얇게 쓴 카드) ---------- */
.now { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.nc { padding: 24px 26px; }
.nc .v { font-size: 16px; line-height: 1.5; }
.nc .n { font-size: 12.5px; color: var(--sub); margin-top: 9px; line-height: 1.8; }

/* ---------- 2단 — 본문 + 사진 ---------- */
.split      { display: grid; grid-template-columns: 1.4fr 1fr; gap: 52px; align-items: start; }
.split.rev  { grid-template-columns: 1fr 1.15fr; }

/* ---------- 사진 슬라이더 ----------
   조각은 components.css 로 올렸다 (works 상세에서도 쓴다).
   여기 남는 것은 이 페이지의 비율뿐이다 — teaching 사진은 4:3 이다. */
.slider { --sl-ratio: 4 / 3; }

/* ---------- 목록 아래 사진 자리 (원본 확보 전) ---------- */
.slots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 28px;
}
.slots div {
  aspect-ratio: 3 / 2;
  border: 1px dashed #3A3A3E;
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 14px;
  font-size: 12px;
  color: var(--faint);
  line-height: 1.6;
}

/* ---------- 강의 목차 10강 ---------- */
.syl { display: grid; grid-template-columns: 1fr 1fr; gap: 0 26px; }
.syl li {
  display: flex;
  gap: 13px;
  align-items: baseline;
  font-size: 13px;
  padding: 9px 0;
  border-bottom: 1px solid var(--line);
}
.syl span {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 400;
  color: var(--dimmer);
  flex: 0 0 20px;
}

/* ---------- 교육 이력 연표 ----------
   연도가 `1998–2003` 같은 구간이라 공통 `.tl` 의 52px 로는 줄이 바뀐다 */
.tl-origin .e span { flex: 0 0 84px; }

/* ---------- 반응형 ---------- */
/* 2단일 때는 마지막 줄(두 칸)의 밑줄만 지운다 */
@media (min-width: 781px) {
  .syl li:last-child,
  .syl li:nth-last-child(2) { border-bottom: none; }
}
@media (max-width: 860px) {
  .split,
  .split.rev { grid-template-columns: 1fr; gap: 34px; }
}
@media (max-width: 780px) {
  /* 세로로 쌓이면 연도 칸의 고정폭을 다시 풀어준다 (components.css 와 같은 처리) */
  .tl-origin .e span { flex: none; }
  .syl { grid-template-columns: 1fr; }
  .syl li:last-child { border-bottom: none; }
  .slots { grid-template-columns: 1fr 1fr; }
  .tprose h2 { font-size: 24px; }
  .tprose h2.lg { font-size: 27px; }
}

/* ---------- 첫 강의 · 연습 사다리 (2026-07-31 시안 개정) ---------- */

/* 영상 자리 — 섬네일을 먼저 깔고 누를 때만 유튜브를 심는다 (pages/teaching.js).
   iframe 을 처음부터 넣으면 페이지 하나에 유튜브가 통째로 딸려 온다 */
.vid { position: relative; border-radius: 9px; overflow: hidden; background: #101012; aspect-ratio: 16 / 9; }
.vid iframe { width: 100%; height: 100%; border: 0; display: block; }
.facade { position: relative; display: block; width: 100%; height: 100%; }
.facade img { width: 100%; height: 100%; object-fit: cover; filter: brightness(.86); transition: filter .25s; }
.facade:hover img { filter: brightness(1); }
.facade .pb {
  position: absolute;
  left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  width: 62px; height: 62px;
  border-radius: 50%;
  background: rgba(14, 14, 16, .62);
  border: 1px solid rgba(237, 231, 218, .55);
  transition: background .2s;
}
.facade:hover .pb { background: rgba(217, 96, 74, .85); border-color: transparent; }
.facade .pb::after {
  content: '';
  position: absolute;
  left: 54%; top: 50%;
  transform: translate(-50%, -50%);
  border-left: 17px solid var(--hanji);
  border-top: 11px solid transparent;
  border-bottom: 11px solid transparent;
}

/* 사다리 앞 안내문 — 본문보다 한 단계 크게 */
.lead-sm { font-size: 14.5px; color: var(--hanji); line-height: 1.85; margin-bottom: 30px; max-width: 820px; }

/* 난이도 칸 넷. 한 칸을 다 내려간 뒤 다음 칸으로 간다 */
.ladder { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.lvcol { background: var(--surface); border-radius: 10px; padding: 22px 22px 14px; }
.lvh { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.lvh b { font-family: var(--serif); font-weight: 400; font-size: 21px; }
.lvh i { font-style: normal; font-family: var(--mono); font-size: 11px; color: var(--cheong-lt); }
/* 설명 높이를 맞춰 둔다 — 칸마다 목록 시작 줄이 어긋나면 훑기 어렵다 */
.lvd { font-size: 11.5px; font-weight: 400; color: #65656B; line-height: 1.65; margin: 7px 0 14px; min-height: 38px; }
.lvlist { border-top: 1px solid var(--line); }
.lvi {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 9px 0;
  border-bottom: 1px solid #232326;
  font-size: 13px;
  color: var(--sub);
  transition: color .15s, padding-left .15s;
}
.lvi:last-child { border-bottom: none; }
.lvi:hover { color: var(--hanji); padding-left: 4px; }
/* 곡명은 **한 줄로 자른다** — 긴 이름 하나 때문에 줄이 두세 줄이 되면 목록이 어긋나 보인다.
   전체 이름은 마우스를 올리면 뜬다(뷰가 title 로 달아 둔다) */
.lvi .ln {
  flex: 1;
  min-width: 0;          /* 이게 없으면 flex 칸이 안 줄어들어 자르기가 먹지 않는다 */
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lvi { min-width: 0; }

/* 사다리에 없는 나머지 — 그 앞에 붙는 안내 한 덩이.
   **`.more` 라고 부르지 않는다** — components.css 의 `.more`(더보기 링크)와 이름이 겹치면
   대문자·주홍색·밑줄이 함께 먹는다 (한 번 겪었다) */
.restnote {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 32px;
  flex-wrap: wrap;
  margin-top: 20px;
  border-top: 1px solid var(--line);
  padding-top: 22px;
}
.restnote div { font-size: 13px; color: var(--sub); line-height: 1.8; flex: 1; min-width: 0; }
.restnote b { display: block; font-family: var(--serif); font-weight: 400; font-size: 15px; color: var(--hanji); margin-bottom: 6px; }
/* 칸이 없는 나머지 — 여러 단으로 흘린다. 한 단으로 세우면 화면이 끝없이 길어진다 */
.restlist {
  columns: 4;
  column-gap: 28px;
  margin-top: 4px;
  border-top: 1px solid var(--line);
  padding-top: 6px;
}
.restlist .rvi {
  /* 단 경계에서 줄이 잘리지 않게 */
  break-inside: avoid;
  page-break-inside: avoid;
  display: flex;
  align-items: baseline;
  gap: 8px;
}
.restlist .rvi i {
  font-style: normal;
  font-family: var(--mono);
  font-size: 10.5px;
  color: #55555A;
  flex: 0 0 auto;
}

@media (max-width: 980px) { .restlist { columns: 2; } }
@media (max-width: 560px) { .restlist { columns: 1; } }

/* 사다리 모달 — 곡 하나를 그 자리에서 듣는다 */
.ov[hidden] { display: none; }
.ov {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(6, 6, 8, .82);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px;
}
.mo {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  width: min(820px, 100%);
  max-height: calc(100vh - 56px);
  overflow: auto;
  padding: 26px 30px 30px;
}
.mo h2 { font-family: var(--serif); font-weight: 400; font-size: 29px; line-height: 1.2; padding-right: 44px; }
.molv { font-family: var(--mono); font-size: 11px; font-weight: 400; color: var(--cheong-lt); letter-spacing: .12em; margin-top: 9px; }
.mo .vid { margin-top: 20px; }
.mx {
  position: absolute;
  right: 18px; top: 18px;
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: none;
  color: var(--sub);
  cursor: pointer;
  font-size: 17px;
  line-height: 1;
}
.mx:hover { color: var(--hanji); border-color: #4A4A50; }
.molinks { display: flex; gap: 22px; flex-wrap: wrap; margin-top: 20px; font-size: 13px; }
.molinks a { color: var(--dan-lt); border-bottom: 1px solid rgba(217, 96, 74, .45); padding-bottom: 2px; }

/* 모달이 떠 있는 동안 뒤 페이지는 스크롤하지 않는다 */
body.ov-on { overflow: hidden; }

@media (max-width: 980px) { .ladder { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) {
  .ov { padding: 0; }
  .mo { border-radius: 0; max-height: 100vh; min-height: 100vh; padding: 22px 20px 28px; }
}
@media (max-width: 560px) {
  .ladder { grid-template-columns: 1fr; }
  .lvd { min-height: 0; }
}
