/* sungd.uk/cv — 업계 관례 형식(The Pragmatic Engineer's Resume Template 결)
   한 단, 섹션 제목 아래 선, 날짜 오른쪽. 글꼴은 마루 부리 하나.
   데스크톱은 A4 종이 보기(cv.js 가 쪽을 나눈다), 폰은 웹 보기가 기본이다. */

@font-face { font-family: "MaruBuri Web"; src: url("https://hangeul.pstatic.net/hangeul_static/webfont/MaruBuri/MaruBuri-Regular.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "MaruBuri Web"; src: url("https://hangeul.pstatic.net/hangeul_static/webfont/MaruBuri/MaruBuri-SemiBold.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "MaruBuri Web"; src: url("https://hangeul.pstatic.net/hangeul_static/webfont/MaruBuri/MaruBuri-Bold.woff2") format("woff2"); font-weight: 700; font-display: swap; }

/* 이력서는 종이처럼 늘 밝게 둔다 */
:root { color-scheme: light; }
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #ffffff;
    --text-primary: #1a1a1a;
    --text-secondary: #4f4f4f;
    --text-tertiary: #9a9a9a;
    --line: rgba(0, 0, 0, 0.08);
    --hover-bg: rgba(0, 0, 0, 0.035);
    --accent: #1a1a1a;
  }
}

body.cvp { background: #fff; word-break: keep-all; }

/* ── 사이트 머리와 바닥 ── */
.cvp-bar { max-width: 794px; margin: 0 auto; padding: 28px 24px 0; }
.cvp-bar .nav-top { margin-bottom: 20px; }
.cvp-bar footer { margin: 0; padding: 28px 0 48px; }

/* ── 보기: A4 종이(회색 바탕 위 쪽마다 한 장) ── */
.cvp-viewer { padding: 0 24px 8px; }
.cvp-flow { max-width: 746px; margin: 0 auto; }
.cvp-stage { display: none; margin: 0 auto; }
html.cvp-a4 .cvp-viewer { background: #D5D8DD; padding: 28px 24px 40px; }
html.cvp-a4 .cvp-flow { display: none; }
html.cvp-a4 .cvp-stage { display: block; }
.cvp-pages { width: 794px; transform-origin: 0 0; }
.cvp-page { width: 794px; height: 1123px; background: #fff; position: relative; overflow: hidden;
  box-shadow: 0 1px 3px rgba(0,0,0,.18), 0 6px 18px rgba(0,0,0,.10); }
.cvp-page + .cvp-page { margin-top: 24px; }
.cvp-page > .cv { position: absolute; inset: 57px 68px; }   /* 위아래 15mm, 좌우 18mm */
.cvp-pno { position: absolute; bottom: 22px; right: 68px; font: 12px var(--font-sans); color: #9AA0A8; }
.cvp-measure { position: absolute; left: -10000px; top: 0; width: 658px; visibility: hidden; }

/* ── 이력서 본문 ── */
.cv {
  --cv-accent: #1F5BAD;
  font-family: "MaruBuri Web", "Noto Serif KR", serif;
  font-size: 13.5px; line-height: 1.5; color: #1a1a1a;
  container-type: inline-size;
}
.cv a { color: inherit; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; text-decoration-color: rgba(0,0,0,.35); }
.cv .b { margin-top: 4px; }
.cv .b:first-child { margin-top: 0; }
.cv .row { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; }
.cv .row > .r { white-space: nowrap; flex: none; text-align: right; font-size: 12.5px; color: #555; font-variant-numeric: tabular-nums; }

/* 머리: 왼쪽에 이름과 직함 한 줄, 오른쪽에 연락처 두 줄. 이름은 연락처 끝 줄과 기준선을 맞춘다 */
.cv .hd { display: flex; justify-content: space-between; align-items: last baseline; gap: 16px 24px; }
.cv .hd .who { display: flex; align-items: baseline; gap: 14px; }
.cv .hd .nm { font-size: 28px; font-weight: 700; line-height: 1.1; }
.cv .hd .ti { font-size: 14px; color: #444; }
.cv .hd .sd { font-size: 12.5px; color: #333; display: flex; flex-direction: column; gap: 2px; }
.cv .hd .sd.r { align-items: flex-end; text-align: right; }
.cv .hd .ln { display: flex; flex-wrap: wrap; gap: 3px 12px; }
.cv .hd .sd.r .ln { justify-content: flex-end; }
.cv .lk { display: inline-flex; align-items: center; gap: 5px; }
.cv .lk svg { display: block; width: 12px; height: 12px; flex: none; color: #444; }
.cv .em { cursor: copy; }

.cv .st { font-size: 15px; font-weight: 700; color: var(--cv-accent); border-bottom: 1px solid var(--cv-accent); padding-bottom: 3px; margin-top: 18px; }
.cv .st + .b { margin-top: 8px; }
.cv .org { margin-top: 10px; }
.cv .org .l b { font-weight: 700; }
.cv .grp { margin-top: 6px; padding-left: 12px; } /* 팀 줄은 회사 줄보다 한 단 들여 쓴다 */
.cv .gt { font-weight: 600; }
.cv .gp { color: #555; }
.cv .dl { margin: 2px 0 0; color: #555; } /* bullet 대신 쓰는 한 줄 설명 (입사 직후 회사처럼) */
.cv .grp .row > .r { font-size: 11.5px; color: #888; } /* 팀 날짜는 회사 날짜보다 작고 옅게 */
.cv .now { font-weight: 700; color: #1a1a1a; } /* 지금 회사의 「현재」 */
.cv .dur { font-size: .92em; color: #888; margin-right: .5em; } /* 회사 기간, 날짜 앞 */
.cv ul { list-style: none; margin: 3px 0 0 15px; padding: 0; }
.cv li { position: relative; margin-top: 2px; }
.cv li::before { content: "•"; position: absolute; left: -11px; color: #555; }
.cv .sk div + div { margin-top: 2px; }
.cv .sk .k { font-weight: 600; }
.cv .edu .l b, .cv .aw .l b, .cv .lang .l b { font-weight: 600; }
.cv .pg { margin-top: 8px; font-size: 12px; font-weight: 600; color: #555; }
.cv .pub .ttl { display: flex; }
.cv .pub .code { flex: none; width: 34px; color: #555; font-variant-numeric: tabular-nums; }
.cv .pub .au { color: #444; font-size: 12.5px; padding-left: 34px; }
.cv .vn { color: #666; }
.cv .me { font-weight: 700; }
.cv .fn { margin-top: 6px; font-size: 12px; color: #555; }
.cv sup.cite { font-size: .68em; line-height: 0; margin-left: 2px; }
.cv sup.cite a { text-decoration: none; }
.cv .sym { font-size: .8em; }

@container (max-width: 460px) {
  .cv .hd { flex-direction: column; align-items: center; gap: 4px; text-align: center; }
  .cv .hd .who { flex-direction: column; align-items: center; gap: 4px; }
  .cv .hd .sd, .cv .hd .sd.r { align-items: center; text-align: center; }
  .cv .hd .ln, .cv .hd .sd.r .ln { justify-content: center; }
  .cv .row { flex-wrap: wrap; row-gap: 0; }
  .cv .row > .r { width: 100%; text-align: left; }
  .cv .pub .row > .r { padding-left: 34px; }
}

@media screen and (max-width: 819px) {
  .cvp-bar { padding: 20px 16px 0; }
  .cvp-viewer { padding: 0 16px 8px; }
  /* 폰: 종이 없이 화면을 채우고, 글자는 A4 보다 작게 */
  .cvp-flow.cv { font-size: 11.5px; }
  .cvp-flow .row > .r, .cvp-flow .hd .sd, .cvp-flow .hd .ti, .cvp-flow .pub .au { font-size: 10.5px; }
  .cvp-flow .grp .row > .r { font-size: 10px; }
  .cvp-flow .hd .nm { font-size: 21px; }
  .cvp-flow .st { font-size: 13px; }
  /* 머리 링크: 아이콘만 한 줄, 이메일은 글자로 맨 끝 */
  .cvp-flow .hd { display: flex; flex-direction: row; flex-wrap: wrap; justify-content: center; align-items: center; gap: 4px 20px; }
  .cvp-flow .hd .nm { width: 100%; order: -2; text-align: center; }
  .cvp-flow .hd .who, .cvp-flow .hd .sd, .cvp-flow .hd .sd.r, .cvp-flow .hd .ln { display: contents; }
  .cvp-flow .hd .ti { width: 100%; text-align: center; color: #333; order: -1; margin-bottom: 6px; }
  .cvp-flow .hd .lk:not(.em) span { display: none; }
  .cvp-flow .hd .lk:not(.em) svg { width: 19px; height: 19px; }
  .cvp-flow .hd .em { order: 1; }
  .cvp-flow .hd .lk[href="https://sungd.uk"] { display: none; }   /* 이미 sungd.uk 안이라 폰에선 뺀다. 맨 위 ← sungd.uk 가 대신한다 */
  html.cvp-a4 .cvp-viewer { padding: 16px 16px 28px; }
  .cvp-bar footer { padding: 24px 0 40px; }
}

/* ── 인쇄와 PDF: 종이 보기와 같은 여백으로, 블록이 쪽 끝에서 잘리지 않게 ── */
@media print {
  @page { size: A4 portrait; margin: 15mm 18mm; }
  body.cvp { background: #fff !important; font-size: 13.5px !important; line-height: 1.5 !important; }
  .cvp-bar, .cvp-stage, .cvp-measure { display: none !important; }
  .cvp-viewer, html.cvp-a4 .cvp-viewer { background: #fff; padding: 0; }
  .cvp-flow, html.cvp-a4 .cvp-flow { display: block !important; max-width: none; margin: 0; }
  .cv .b { break-inside: avoid; }
  .cv .st, .cv .pg, .cv .org { break-after: avoid; }
  .cv .aw:has(+ .aw) { break-after: avoid; } /* 수상은 몇 줄뿐이라 한 쪽에 모은다 */
}
