/* 류경서 웹 포트폴리오 — 화면 틀 (S001, 글자·여백 S016)
   디자인 기준: 계획 3절. 흰 바탕, 강조색 없음, Pretendard 300/400/600, 사진은 각지게.
   글꼴 @font-face는 css/fonts.css (Pretendard dynamic subset).
   글자·여백은 화면 폭 375px → 1920px 사이에서 고르게 커진다(clamp). 값 표는 :root 주석. */


:root {
  --bg: #fff;
  --ink: #111;
  --sub: #6b6b6b;
  --line: #e5e5e5;
  --ph: #ececea;          /* 그림 자리표시 */
  --max: 1680px;
  --ease: cubic-bezier(.2, .6, .2, 1);
  --font: "Pretendard", -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", system-ui, sans-serif;

  /* 여백                                                       375 / 768 / 1440 / 1920 */
  --gutter: clamp(16px, 2.41px + 3.625vw, 72px);           /* 16 / 30 / 55 / 72 좌우 여백 */
  --head-h: clamp(56px, 48.23px + 2.071vw, 88px);          /* 56 / 64 / 78 / 88 머리 높이 */
  --page-top: clamp(32px, 16.47px + 4.142vw, 96px);        /* 32 / 48 / 76 / 96 머리 아래 첫 여백 */
  --gap-sm: clamp(24px, 18.17px + 1.553vw, 48px);          /* 24 / 30 / 41 / 48 */
  --gap-md: clamp(32px, 22.29px + 2.589vw, 72px);          /* 32 / 42 / 60 / 72 */
  --sp: clamp(56px, 34.64px + 5.696vw, 144px);             /* 56 / 78 / 117 / 144 섹션 사이 */
  --grid-gap: clamp(4px, 1.09px + 0.777vw, 16px);          /* 4 / 7 / 12 / 16 바둑판 틈 */

  /* 글자 */
  --fs-nav: clamp(15px, 14.03px + 0.259vw, 19px);          /* 15 / 16 / 17.8 / 19 */
  --logo-h: clamp(26px, 23.18px + 0.751vw, 36px);          /* 머리 마크 높이 26 / 28.9 / 34 / 36 (S026) */
  --fs-lang: clamp(12px, 11.27px + 0.194vw, 15px);         /* 12 / 12.8 / 14.1 / 15 */
  --fs-btn: clamp(13px, 12.27px + 0.194vw, 16px);          /* 13 / 13.8 / 15.1 / 16 Contact·단추 */
  --btn-h: clamp(36px, 33.09px + 0.777vw, 48px);           /* 36 / 39 / 44 / 48 */
  --fs-body: clamp(15px, 14.27px + 0.194vw, 18px);         /* 15 / 15.8 / 17.1 / 18 본문·정보표 값 */
  --fs-lead: clamp(17px, 15.30px + 0.453vw, 24px);         /* 17 / 18.8 / 21.8 / 24 한 줄 설명 */
  --fs-small: clamp(12px, 11.03px + 0.259vw, 16px);        /* 12 / 13 / 14.8 / 16 캡션·라벨·칩 */
  --fs-ui: clamp(13px, 12.51px + 0.129vw, 15px);           /* 13 / 13.5 / 14.4 / 15 분류 단추·바닥 */
  --fs-h-work: clamp(18px, 15.57px + 0.647vw, 28px);       /* 18 / 20.5 / 24.9 / 28 첫 화면 작품 제목 */
  --fs-h-sec: clamp(28px, 20.23px + 2.071vw, 60px);        /* 28 / 36 / 50 / 60 섹션 제목 */
  --fs-h-project: clamp(30px, 18.83px + 2.977vw, 76px);    /* 30 / 42 / 62 / 76 상세 제목 */
  --fs-h-list: clamp(40px, 24.47px + 4.142vw, 104px);      /* 40 / 56 / 84 / 104 목록 제목 */
  /* 소개 머리 두 줄(S030): 375 42 / 768 54.8 / 1440 103.2 / 1920 122.
     작은 화면은 윗줄 「RYU KYUNG SEO」(7.6em)가 한 줄에 들도록 12.4vw-4px로 묶고, 넓은 화면은 아랫줄(12.3em)이 한 줄에 들도록 7.19vw.
     위 한계 122px = 본문 최대 폭 1536px에 아랫줄이 들어가는 크기 */
  --fs-h-about: clamp(30px, min(12.4vw - 4px, max(42px, 7.19vw - 0.37px)), 122px);
  --fs-contact-big: clamp(20px, 17.57px + 0.647vw, 30px);  /* 20 / 22.5 / 26.9 / 30 */
  --fs-pnav: clamp(16px, 12.12px + 1.036vw, 32px);         /* 16 / 20 / 27 / 32 이전·다음 */
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-weight: 400; font-size: var(--fs-body); line-height: 1.6;
  letter-spacing: -0.01em; word-break: keep-all; overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, p, dl, dd, figure, ol, ul { margin: 0; padding: 0; }
ol, ul { list-style: none; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 8px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 8px 14px; }
.skip:focus { top: 8px; }
.num { font-variant-numeric: tabular-nums; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
main { display: block; min-height: 60vh; }
.page-top { padding-top: calc(var(--head-h) + var(--page-top)); }

/* 「확인 필요」 등 비어 있는 사실 — 회색 기울임 */
.tbd { color: var(--sub); font-style: italic; font-weight: 300; }

/* ---------- 공통 머리 ---------- */
.site-head {
  position: fixed; inset: 0 0 auto 0; z-index: 50; height: var(--head-h);
  background: rgba(255, 255, 255, .94); border-bottom: 1px solid var(--line);
  -webkit-backdrop-filter: saturate(1.2) blur(8px); backdrop-filter: saturate(1.2) blur(8px);
  transition: background-color .3s var(--ease), border-color .3s var(--ease), color .3s var(--ease);
}
.site-head .wrap { height: 100%; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px; }
/* 「KS / RYU」 두 줄 마크(S026): 글자 윤곽 SVG, 글자색(currentColor)을 따라 투명·흰 바탕 모두 검정 */
.logo { justify-self: start; display: inline-flex; align-items: center; }
.logo .mark { display: block; height: var(--logo-h); width: auto; }
.nav { display: none; gap: clamp(24px, 2.4vw, 56px); font-weight: 300; font-size: var(--fs-nav); letter-spacing: .02em; }
.nav a { position: relative; padding: 4px 0; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: currentColor;
  transform: scaleX(0); transform-origin: left; transition: transform .25s var(--ease); }
.nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.head-right { grid-column: 3; justify-self: end; display: flex; align-items: center; gap: clamp(16px, 1.4vw, 28px); }
.lang { display: none; font-size: var(--fs-lang); letter-spacing: .06em; color: var(--sub); }
.lang b { color: var(--ink); font-weight: 600; }
.lang [aria-disabled="true"] { opacity: .45; cursor: not-allowed; }
.btn-contact {
  display: none; align-items: center; height: var(--btn-h); padding: 0 1.4em; border-radius: 999px;
  background: var(--ink); color: #fff; font-size: var(--fs-btn); letter-spacing: .03em; transition: opacity .2s;
}
.btn-contact:hover { opacity: .8; }
.menu-btn { display: inline-flex; width: 40px; height: 40px; margin-right: -8px; align-items: center; justify-content: center; }
.menu-btn i { position: relative; display: block; width: 20px; height: 1px; background: currentColor; }
.menu-btn i::before, .menu-btn i::after { content: ""; position: absolute; left: 0; width: 20px; height: 1px; background: currentColor; transition: transform .25s var(--ease); }
.menu-btn i::before { top: -6px; } .menu-btn i::after { top: 6px; }
.menu-open .menu-btn i { background: transparent; }
.menu-open .menu-btn i::before { transform: translateY(6px) rotate(45deg); }
.menu-open .menu-btn i::after { transform: translateY(-6px) rotate(-45deg); }
/* 메뉴 4개(S021): 1024px 미만은 메뉴 단추 안으로. KOR/ENG·Contact는 768px부터 머리에 둠 */
@media (min-width: 768px) {
  .lang { display: flex; }
  .btn-contact { display: inline-flex; }
}
@media (min-width: 1024px) {
  .nav { display: flex; }
  .menu-btn { display: none; }
}
/* 휴대폰 메뉴 */
.mobile-menu {
  position: fixed; inset: var(--head-h) 0 0 0; z-index: 49; background: #fff;
  padding: 40px var(--gutter); display: flex; flex-direction: column; gap: 8px;
  visibility: hidden; opacity: 0; transition: opacity .25s var(--ease), visibility 0s .25s;
}
.menu-open .mobile-menu { visibility: visible; opacity: 1; transition: opacity .25s var(--ease); }
.mobile-menu a.big { font-size: 40px; font-weight: 300; line-height: 1.3; letter-spacing: -0.02em; }
.mobile-menu .mm-foot { margin-top: auto; display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: var(--sub); }
.mobile-menu .btn-contact { display: inline-flex; }
@media (min-width: 1024px) { .mobile-menu { display: none; } }
@media (min-width: 768px) { .mobile-menu .mm-foot { display: none; } }
.menu-open { overflow: hidden; }

/* 첫 화면: 큐브 무대(밝은 바탕) 위 머리는 투명 바탕 + 검은 글씨 */
.head-clear { background: transparent; border-color: transparent; -webkit-backdrop-filter: none; backdrop-filter: none; }
.menu-open .site-head { background: #fff; color: var(--ink); border-color: var(--line); }

/* ---------- 공통 바닥 ---------- */
.site-foot { margin-top: var(--sp); border-top: 1px solid var(--line); padding: var(--gap-sm) 0 32px; font-size: var(--fs-ui); }
.foot-grid { display: grid; gap: 28px; }
/* 꼬리말 이름(S029): 머리 줄과 같은 「KS / RYU」 마크(A)를 조금 크게 + 아래 작은 회색 한글 이름 */
.foot-name { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.foot-name .mark { display: block; height: clamp(36px, 32.48px + 0.939vw, 50px); width: auto; } /* 36 / 39.7 / 46 / 50 */
.foot-name span { color: var(--sub); font-size: var(--fs-small); font-weight: 400; letter-spacing: .04em; }
.foot-contact { display: grid; gap: 6px; }
.foot-contact dt { font-size: 11px; letter-spacing: .1em; color: var(--sub); text-transform: uppercase; padding-top: .2em; }
.foot-contact dd { margin-bottom: 8px; }
.foot-contact a:hover { text-decoration: underline; text-underline-offset: 3px; }
.foot-copy { color: var(--sub); font-size: var(--fs-small); align-self: end; }
@media (min-width: 768px) {
  .site-foot { padding: var(--gap-md) 0 40px; }
  .foot-grid { grid-template-columns: 2fr 2fr 1fr; align-items: end; }
  .foot-contact { grid-template-columns: auto 1fr; column-gap: 24px; }
  .foot-contact dd { margin-bottom: 0; }
  .foot-copy { justify-self: end; }
}

/* ---------- 그림 ---------- */
.media { position: relative; overflow: hidden; background: var(--ph); }
.media img, .media picture { width: 100%; height: 100%; }
.media img { object-fit: cover; }
.ph { display: flex; align-items: center; justify-content: center; text-align: center; padding: 16px;
  color: var(--sub); font-size: 13px; font-weight: 300; background:
  linear-gradient(to top right, transparent calc(50% - .5px), #d6d6d3 50%, transparent calc(50% + .5px)),
  linear-gradient(to top left, transparent calc(50% - .5px), #d6d6d3 50%, transparent calc(50% + .5px)), var(--ph); }
.ph span { background: var(--ph); padding: 4px 10px; }
.media > .ph { position: absolute; inset: 0; }

/* 연도 칩 */
.chip { display: inline-flex; align-items: center; height: 2.3em; padding: 0 1em; border: 1px solid var(--ink);
  border-radius: 999px; font-size: var(--fs-small); letter-spacing: .02em; white-space: nowrap; font-variant-numeric: tabular-nums; }
.chip.tbd { border-color: var(--line); }

/* 작은 머리글: 번호 — 이름 */
.eyebrow { display: flex; gap: 12px; align-items: baseline; font-size: var(--fs-small); letter-spacing: .12em; text-transform: uppercase; color: var(--sub); }
.eyebrow .num { color: var(--ink); }
.sec-head { display: flex; justify-content: space-between; align-items: end; gap: 16px; padding-bottom: 16px;
  border-bottom: 1px solid var(--ink); margin-bottom: var(--gap-md); }
.sec-head h2 { font-size: var(--fs-h-sec); font-weight: 300; letter-spacing: -0.03em; line-height: 1.15; margin-top: 8px; }
.link-arrow { display: inline-flex; gap: 8px; align-items: center; font-size: var(--fs-ui); white-space: nowrap; }
.link-arrow::after { content: "→"; transition: transform .2s var(--ease); }
.link-arrow:hover::after { transform: translateX(4px); }

/* 스크롤하면 살짝 떠오름 (JS가 html.js를 붙였을 때만) */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .reveal.is-in { opacity: 1; transform: none; }

/* 사진 hover 확대 1.03 */
.zoom img { transition: transform .7s var(--ease); }
@media (hover: hover) { a:hover .zoom img, .zoom:hover img { transform: scale(1.03); } }

/* ---------- 첫 화면 ---------- */
/* 큐브 무대: 키가 큰 칸 안에서 무대가 화면에 붙어 있고, 그 사이 스크롤로 조립된다 */
.hero { position: relative; height: 230vh; height: 230svh; background: #efeeeb; color: var(--ink); }
.hero-stick { position: sticky; top: 0; height: 100vh; height: 100svh; min-height: 480px; overflow: hidden; }
.hero-stage { position: absolute; inset: 0; }
/* 모듈을 못 받았을 때 site.js가 내는 정지 그림도 무대를 꽉 채움(hero3d.js mountStill과 같게) */
.hero-stage > .hero3d-still, .hero-stage > .hero3d-still img { display: block; width: 100%; height: 100%; object-fit: cover; }
.hero-body { position: absolute; z-index: 3; left: 0; right: 0; bottom: 0; padding-bottom: clamp(16px, 1.4vw, 28px); pointer-events: none; }
.hero-body a { pointer-events: auto; }
.hero-cta { display: inline-flex; align-items: baseline; gap: 6px; font-size: var(--fs-btn); letter-spacing: .02em; color: var(--ink); }
.hero-cta span { transition: transform .2s var(--ease); }
.hero-cta:hover span { transform: translateX(4px); }

.intro { padding: 72px 0 8px; }
.intro p { font-size: 20px; font-weight: 300; line-height: 1.55; letter-spacing: -0.02em; max-width: 30em; }
@media (min-width: 768px) { .intro { padding: 120px 0 24px; } .intro .wrap { display: grid; grid-template-columns: 1fr 2fr; gap: 40px; } .intro p { font-size: 28px; } }

/* 큐브 아래 Projects 격자(S023): 좌우 끝까지, 정사각, 틈 아주 좁게 */
.home-grid { padding-top: var(--sp); }
.hg-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding-bottom: 14px; }
.hg-head h2 { margin: 0; }
.hg { display: grid; grid-template-columns: repeat(2, 1fr); gap: 4px; }
@media (min-width: 768px) { .hg { grid-template-columns: repeat(4, 1fr); gap: 5px; } }
@media (min-width: 1024px) { .hg { grid-template-columns: repeat(5, 1fr); } }
@media (min-width: 1440px) { .hg { grid-template-columns: repeat(6, 1fr); gap: 6px; } }
@media (min-width: 1920px) { .hg { grid-template-columns: repeat(7, 1fr); } }
.hg-item { position: relative; display: block; overflow: hidden; }
.hg-item .media { display: block; aspect-ratio: 1 / 1; }
.hg-item .media img { transition: transform .6s var(--ease); }
.hg-cap { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end; gap: 2px; padding: clamp(12px, 1.2vw, 22px);
  background: rgba(0, 0, 0, .45); color: #fff; opacity: 0; transition: opacity .3s var(--ease); pointer-events: none; }
.hg-cap b { font-weight: 600; font-size: var(--fs-ui); line-height: 1.35; }
.hg-cap span { font-size: var(--fs-small); color: rgba(255, 255, 255, .85); font-variant-numeric: tabular-nums; }
@media (hover: hover) {
  .hg-item:hover .hg-cap, .hg-item:focus-visible .hg-cap { opacity: 1; }
  .hg-item:hover .media img { transform: scale(1.03); }
}
.hg-item:focus-visible { outline-offset: -3px; }
.hg-more { display: flex; justify-content: center; margin-top: var(--gap-md); }
.hg-plus { width: 52px; height: 52px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--ink);
  font-size: 28px; font-weight: 300; line-height: 1; transition: background-color .2s, color .2s; }
.hg-plus:hover { background: var(--ink); color: #fff; }
.home-works { padding-top: var(--sp); }
.works { display: grid; gap: var(--gap-md); }
.work .media { aspect-ratio: 16 / 9; }
.work-cap { display: grid; grid-template-columns: 1fr auto; gap: 4px 16px; align-items: start; padding-top: 14px; }
.work-cap h3 { font-size: var(--fs-h-work); font-weight: 400; line-height: 1.35; letter-spacing: -0.02em; }
.work-cap .cat { grid-column: 1; font-size: var(--fs-ui); color: var(--sub); font-weight: 300; }
.work-cap .chip { grid-row: 1 / span 2; grid-column: 2; }
.work-cap .en { display: block; font-weight: 300; color: var(--sub); font-size: var(--fs-ui); letter-spacing: 0; }
@media (min-width: 768px) { .work-cap .en { display: inline; margin-left: .6em; } }
@media (min-width: 1024px) { .works { grid-template-columns: 1fr 1fr; column-gap: var(--gap-sm); row-gap: var(--gap-md); } }
.home-more { margin-top: var(--sp); display: flex; justify-content: center; }
.btn-line { display: inline-flex; align-items: center; gap: 10px; height: calc(var(--btn-h) + 8px); padding: 0 1.9em; border: 1px solid var(--ink); border-radius: 999px; font-size: var(--fs-btn); transition: background-color .2s, color .2s; }
.btn-line:hover { background: var(--ink); color: #fff; }

/* ---------- 프로젝트 목록 ---------- */
.list-head h1 { font-size: var(--fs-h-list); font-weight: 300; letter-spacing: -0.04em; line-height: 1.05; margin-top: 8px; }
.list-head h1 sup { font-size: var(--fs-ui); font-weight: 400; color: var(--sub); vertical-align: top; margin-left: 6px; letter-spacing: 0; }
.toolbar { margin-top: var(--gap-sm); display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: center; justify-content: space-between;
  padding: 12px 0; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--line); }
.filters { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 0 calc(var(--gutter) * -1); padding: 0 var(--gutter); flex: 1 1 100%; }
.filters::-webkit-scrollbar { display: none; }
.filters button { flex: none; height: 2.5em; padding: 0 1.1em; border: 1px solid var(--line); border-radius: 999px; font-size: var(--fs-ui); white-space: nowrap; transition: border-color .2s, background-color .2s, color .2s; }
.filters button sup { font-size: .72em; color: var(--sub); margin-left: 3px; vertical-align: super; }
.filters button:hover { border-color: var(--ink); }
.filters button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.filters button[aria-pressed="true"] sup { color: rgba(255,255,255,.7); }
.views { display: flex; gap: 4px; margin-left: auto; }
.views button { width: 40px; height: 36px; display: inline-flex; align-items: center; justify-content: center; color: var(--sub); }
.views button[aria-pressed="true"] { color: var(--ink); }
.views svg { width: 16px; height: 16px; }
@media (min-width: 768px) { .filters { flex: 1 1 auto; margin: 0; padding: 0; flex-wrap: wrap; overflow: visible; } }

.grid { margin-top: var(--gap-sm); display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--grid-gap); }
@media (min-width: 720px) { .grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1100px) { .grid { grid-template-columns: repeat(4, 1fr); } }
.tile { position: relative; display: block; }
.tile .media { aspect-ratio: 1 / 1; }
.tile-cap { padding: 8px 2px 14px; font-size: var(--fs-ui); line-height: 1.45; }
.tile-cap b { display: block; font-weight: 400; }
.tile-cap span { color: var(--sub); font-size: var(--fs-small); font-weight: 300; }
@media (min-width: 720px) { .tile-cap { padding: 12px 2px 20px; } .tile-cap b { font-size: var(--fs-body); } }
.rows { margin-top: 8px; }
.row { display: grid; grid-template-columns: 28px 1fr auto; gap: 4px 12px; align-items: center; padding: 16px 0; border-bottom: 1px solid var(--line); transition: background-color .2s; }
.row .idx { font-size: var(--fs-small); color: var(--sub); }
.row b { font-weight: 400; }
.row .en { display: block; font-size: var(--fs-small); color: var(--sub); font-weight: 300; }
.row .c-cat, .row .c-phase, .row .thumb { display: none; }
.row .c-year { font-size: var(--fs-ui); color: var(--sub); text-align: right; }
@media (min-width: 768px) {
  .row { grid-template-columns: 48px clamp(96px, 8vw, 144px) 3fr 1.2fr 1.2fr 120px; gap: 24px; padding: 14px 0; }
  .row .thumb { display: block; width: 100%; aspect-ratio: 4 / 3; }
  .row .c-cat, .row .c-phase { display: block; font-size: var(--fs-ui); color: var(--sub); font-weight: 300; }
}
@media (hover: hover) { .row:hover { background: #fafafa; } }
.more-wrap { margin-top: var(--gap-md); display: flex; justify-content: center; }
.empty { padding: 80px 0; text-align: center; color: var(--sub); }

/* ---------- 프로젝트 상세 (S016, 사용자 참고 화면 기준) ----------
   꽉 찬 대표 사진 → 큰 굵은 제목 + 작은 아이콘 → 정보표 | 설명(넓은 화면 두 단) → 남은 사진 가로로 → 이전·다음(작게) */
.p-cover { padding-top: var(--head-h); }
.p-cover .media { width: 100%; }
@media (min-width: 768px) {
  .p-cover .media { aspect-ratio: auto !important; height: 65vh; height: 65svh; min-height: 400px; max-height: 960px; }
}
.p-wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); } /* 머리·바닥과 같은 왼쪽 선 */

.p-head { margin-top: var(--gap-md); display: flex; justify-content: space-between; align-items: flex-start; gap: 16px 40px; }
.p-head h1 { font-size: clamp(28px, 17.32px + 2.848vw, 72px); font-weight: 600; line-height: 1.2; letter-spacing: -0.035em; }
.p-head .en { margin-top: .6em; font-size: var(--fs-small); letter-spacing: .1em; text-transform: uppercase; color: var(--sub); }
.p-tools { position: relative; flex: none; display: flex; gap: 4px; margin-top: .4em; }
.p-icon { width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; border-radius: 999px; color: var(--ink); transition: background-color .2s; }
.p-icon:hover { background: #f2f2f0; }
.p-icon svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.p-copied { position: absolute; right: 0; top: 100%; margin-top: 6px; white-space: nowrap; font-size: var(--fs-small); color: var(--sub); }
@media (max-width: 767px) { .p-head { flex-direction: column; } .p-tools { order: -1; margin: 0 0 0 -10px; } .p-copied { left: 10px; right: auto; } }

.p-detail { margin-top: var(--gap-md); display: grid; gap: var(--gap-md); }
@media (min-width: 900px) { .p-detail { grid-template-columns: 1fr 1fr; column-gap: clamp(48px, 9vw, 180px); align-items: start; } }
.p-info div { display: grid; grid-template-columns: 6.5em 1fr; gap: 16px; padding: 1em 0; border-bottom: 1px solid var(--line); font-size: var(--fs-body); line-height: 1.5; }
.p-info div:first-child { padding-top: 0; }
.p-info dt { font-weight: 600; }
.p-body .text { display: grid; gap: 1.1em; }
.p-body .text p { font-size: var(--fs-body); line-height: 1.9; }
.p-body .text .summary { font-weight: 600; }
.draft-note { display: inline-block; font-size: var(--fs-small); color: var(--sub); border-left: 2px solid var(--line); padding-left: 8px; justify-self: start; }

.gallery { margin-top: var(--gap-md); display: grid; grid-template-columns: 1fr; gap: var(--gap-sm) var(--grid-gap); }
.gallery .media { cursor: zoom-in; }
.gallery .media.ph { cursor: default; }
.gallery button.media { display: block; width: 100%; }
.gallery figcaption { margin-top: 10px; font-size: var(--fs-small); color: var(--sub); font-weight: 400; line-height: 1.5; display: flex; gap: 10px; }
.gallery figcaption .num { color: var(--ink); font-weight: 400; }
@media (min-width: 768px) {
  .gallery.g2, .gallery.g4 { grid-template-columns: 1fr 1fr; }
  .gallery.g3 { grid-template-columns: repeat(3, 1fr); }
  /* 여러 장이면 같은 높이로 맞춰 자름(3:2). 1장이면 그림 비율 그대로 본문 폭 한 줄 */
  .gallery.g2 .media, .gallery.g3 .media, .gallery.g4 .media { aspect-ratio: 3 / 2 !important; }
}

.p-nav { margin-top: calc(var(--gap-md) * 1.5); display: grid; grid-template-columns: 1fr auto 1fr; gap: 16px; align-items: start; border-top: 1px solid var(--line); padding-top: 20px; font-size: var(--fs-small); }
.p-nav a { display: grid; gap: 4px; min-width: 0; }
.p-nav a[rel="next"] { text-align: right; }
.p-nav .dir { color: var(--sub); letter-spacing: .06em; }
.p-nav b { font-weight: 400; font-size: var(--fs-ui); line-height: 1.4; }
.p-nav .p-list { align-self: center; color: var(--sub); white-space: nowrap; }
.p-nav a:hover b, .p-nav .p-list:hover { text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 767px) {
  .p-nav { grid-template-columns: 1fr; gap: 0; padding-top: 0; }
  .p-nav a[rel] { padding: 14px 0; border-bottom: 1px solid var(--line); }
  .p-nav a[rel="next"] { text-align: left; order: 2; }
  .p-nav .p-list { order: 3; justify-self: center; padding-top: 20px; }
}

/* 크게 보기 */
.lightbox { border: 0; padding: 0; margin: 0; width: 100vw; height: 100vh; height: 100dvh; max-width: none; max-height: none; background: #fff; color: var(--ink); }
.lightbox::backdrop { background: #fff; }
.lb-stage { position: absolute; inset: 56px 0 72px; display: flex; align-items: center; justify-content: center; padding: 0 var(--gutter); touch-action: pan-y; }
.lb-stage picture { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; } /* 세로 그림도 화면 안에 */
.lb-stage img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; }
.lb-top, .lb-bottom { position: absolute; left: 0; right: 0; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0 var(--gutter); }
.lb-top { top: 0; height: 56px; font-size: var(--fs-ui); }
.lb-bottom { bottom: 0; height: 72px; font-size: var(--fs-ui); color: var(--sub); }
.lb-close, .lb-prev, .lb-next { height: 40px; min-width: 40px; display: inline-flex; align-items: center; justify-content: center; font-size: 14px; }
.lb-close { font-size: var(--fs-ui); letter-spacing: .06em; }
.lb-arrows { display: flex; gap: 8px; }
.lb-prev, .lb-next { border: 1px solid var(--line); border-radius: 999px; padding: 0 14px; color: var(--ink); }
.lb-prev:hover, .lb-next:hover { border-color: var(--ink); }

/* 크게 보기 아래 한 줄 설명(Small Works) */
.lb-info { position: absolute; left: 0; right: 0; bottom: 72px; padding: 0 var(--gutter); text-align: center; display: grid; gap: 2px; }
.lb-info .lb-title { font-size: var(--fs-ui); font-weight: 600; }
.lb-info .lb-sum { font-size: var(--fs-small); color: var(--ink); max-width: 46em; margin: 0 auto; line-height: 1.5; }
.lb-info .lb-meta { font-size: var(--fs-small); color: var(--sub); }
.lightbox.has-info .lb-stage { bottom: calc(72px + 5.2em); }

/* ---------- Design Works (S021) — 분류 칩 없는 사진 카드 목록 ---------- */
.dw-list { margin-top: var(--gap-sm); padding-top: var(--gap-sm); border-top: 1px solid var(--ink); }
.pl-list { padding-top: var(--gap-sm); } /* Projects: 분류 칩 줄 아래 같은 간격 */

/* ---------- 소개 ---------- */
/* 머리(S030 B안): 같은 크기 두 줄 — 윗줄 SemiBold 이름, 아랫줄 Light. 낱말 사이에서만 줄이 바뀐다 */
.about-head { padding-bottom: var(--gap-md); border-bottom: 1px solid var(--ink); }
.about-title { font-size: var(--fs-h-about); line-height: 1.04; letter-spacing: -0.02em; color: var(--ink);
  overflow-wrap: normal; word-break: keep-all; hyphens: none; }
.about-title b, .about-title b + span { display: block; }
.about-title b { font-weight: 600; white-space: nowrap; }
.about-title b + span { font-weight: 300; }
.a-sec { display: grid; gap: 20px; padding: var(--gap-md) 0; border-bottom: 1px solid var(--line); }
.a-sec > h2 { font-size: var(--fs-small); font-weight: 400; letter-spacing: .12em; text-transform: uppercase; color: var(--sub); padding-top: .3em; }
@media (min-width: 768px) { .a-sec { grid-template-columns: 1fr 2fr; gap: var(--gap-md); } }
.timeline li { display: grid; grid-template-columns: 112px 1fr; gap: 16px; padding: .9em 0; border-top: 1px solid var(--line); }
.timeline li:first-child { border-top: 0; padding-top: 0; }
.timeline .when { font-size: var(--fs-ui); color: var(--sub); padding-top: .15em; }
.timeline b { font-weight: 400; display: block; }
.timeline span { font-size: var(--fs-ui); color: var(--sub); font-weight: 300; }
@media (min-width: 768px) { .timeline li { grid-template-columns: 11em 1fr; } }
.tools { display: flex; flex-wrap: wrap; gap: 8px; }
.tools li { border: 1px solid var(--line); border-radius: 999px; padding: .3em 1.1em; font-size: var(--fs-ui); }
.contact-list { display: grid; gap: 4px; }
.contact-list a { font-size: var(--fs-contact-big); font-weight: 300; letter-spacing: -0.02em; line-height: 1.4; display: inline-block; }
.contact-list a:hover { text-decoration: underline; text-underline-offset: 5px; text-decoration-thickness: 1px; }
.contact-list dt { font-size: var(--fs-small); color: var(--sub); margin-top: 12px; }

/* 불러오기 실패 */
.load-error { padding: 120px 0; text-align: center; color: var(--sub); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .js .reveal { opacity: 1; transform: none; }
  .zoom img { transform: none !important; }
}
