:root {
  --bg: #ffffff;
  --bg-elev: #ffffff;
  --bg-sunk: #f4f4f4;
  --ink: #090302;
  --ink-2: #3a3330;
  --ink-3: #6f645a;
  --line: #e6e6e6;
  --accent: #4c6b48;
  --accent-soft: #eef3ed;
  --warn: #b4552d;
  --term-bg: #090302;
  --term-ink: #d7dae0;
  --shadow: 0 1px 2px rgb(0 0 0 / 0.04), 0 8px 24px -12px rgb(0 0 0 / 0.12);
  --radius: 14px;
  --sans: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
  --mono: "JetBrains Mono", "Pretendard Variable", Pretendard, ui-monospace, SFMono-Regular, Menlo, monospace;
  color-scheme: light;
}

/* 기본은 밝은 테마. 어두운 테마는 토글로 고른 경우에만 쓴다 */
:root[data-theme="dark"] {
  --bg: #0e0e0e;
  --bg-elev: #171717;
  --bg-sunk: #1f1f1f;
  --ink: #ececec;
  --ink-2: #b8b8b8;
  --ink-3: #8a8a8a;
  --line: #2a2a2a;
  --accent: #9dbb99;
  --accent-soft: #1c261b;
  --warn: #f08a5d;
  --term-bg: #0a0c0f;
  --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 12px 32px -16px rgb(0 0 0 / 0.6);
  color-scheme: dark;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 72px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.7;
  word-break: keep-all;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
img { max-width: 100%; display: block; }
code { font-family: var(--mono); font-size: 0.88em; background: var(--bg-sunk); padding: 0.1em 0.35em; border-radius: 4px; }
.mono { font-family: var(--mono); }

.wrap { width: min(1080px, 100% - 32px); margin-inline: auto; }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 100; background: var(--ink); color: var(--bg); padding: 8px 12px; border-radius: 8px; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* NAV */
.nav {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav-inner { display: flex; align-items: center; gap: 24px; height: 60px; }
.brand { font-family: var(--mono); font-weight: 700; text-decoration: none; font-size: 15px; }
.prompt { color: var(--accent); }
.nav nav { display: flex; gap: 22px; margin-left: auto; }
.nav nav a { text-decoration: none; color: var(--ink-2); font-size: 14px; }
.nav nav a:hover { color: var(--ink); }
.theme-toggle {
  width: 36px; height: 36px; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: 10px; background: var(--bg-elev); color: var(--ink-2); cursor: pointer;
}
.theme-toggle svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.theme-toggle .i-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .i-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .i-moon { display: block; }

/* HERO */
.hero { padding: 88px 0 40px; }
.hero-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: 48px; align-items: center; }
.eyebrow { color: var(--accent); font-size: 13px; letter-spacing: 0.04em; margin: 0 0 18px; }
h1 { font-size: clamp(34px, 5vw, 52px); line-height: 1.22; letter-spacing: -0.03em; margin: 0 0 22px; font-weight: 800; }
h1 em { font-style: normal; color: var(--accent); }
.lede { font-size: 17px; color: var(--ink-2); margin: 0 0 30px; max-width: 34em; }
.lede strong { color: var(--ink); }
.cta { display: flex; flex-wrap: wrap; gap: 10px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 16px; border-radius: 10px; font-size: 14px; font-weight: 600; text-decoration: none;
  border: 1px solid var(--line); background: var(--bg-elev); color: var(--ink);
  transition: transform .15s ease, border-color .15s ease;
}
.btn:hover { transform: translateY(-1px); border-color: var(--ink-3); }
.btn svg { width: 17px; height: 17px; fill: currentColor; }
.btn.primary { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.btn.ghost { background: transparent; }

.terminal {
  background: var(--term-bg); color: var(--term-ink);
  border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--term-ink) 12%, transparent);
}
.term-bar { display: flex; align-items: center; gap: 7px; padding: 12px 14px; border-bottom: 1px solid rgb(255 255 255 / 0.07); }
.term-bar span { width: 11px; height: 11px; border-radius: 50%; background: #3a3f48; }
.term-bar b { margin-left: auto; font-size: 12px; font-weight: 400; color: #7c8390; }
.terminal pre { margin: 0; padding: 18px 20px 22px; font-size: 13.5px; line-height: 1.75; overflow-x: auto; }
.terminal code { background: none; padding: 0; font-size: inherit; }
.c-p { color: #9dbb99; }
.c-k { color: #9dbb99; }
.c-s { color: #f2c37a; }
.c-dim { color: #9aa1ad; }
.cursor { color: #9dbb99; animation: blink 1.1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

.metrics {
  list-style: none; padding: 0; margin: 56px 0 0;
  display: grid; grid-template-columns: repeat(3, 1fr); /* Search Platform 지표를 다시 보이면 4로 */
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); overflow: hidden;
}
.metrics li { padding: 20px 22px; display: flex; flex-direction: column; gap: 4px; }
.metrics li + li { border-left: 1px solid var(--line); }
.m-label { font-size: 13px; color: var(--ink-3); }
.m-val { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.25; }
.m-from { font-size: 13px; color: var(--ink-3); }
.m-val b { color: var(--accent); }
.m-ctx { font-size: 13.5px; color: var(--ink-2); }

/* SECTIONS */
.section { padding: 88px 0 24px; }
.sec-head { display: grid; grid-template-columns: auto 1fr; column-gap: 16px; align-items: baseline; margin-bottom: 36px; }
.sec-no { margin: 0; color: var(--accent); font-size: 14px; }
.sec-head h2 { margin: 0; font-size: clamp(26px, 3.4vw, 34px); letter-spacing: -0.02em; }
.sec-sub { grid-column: 2; margin: 8px 0 0; color: var(--ink-2); }

.principles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.pr {
  background: var(--bg-elev); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 26px 20px;
  display: flex; flex-direction: column; gap: 16px; transition: border-color .2s, box-shadow .2s;
}
.pr:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); box-shadow: 0 8px 28px -18px color-mix(in srgb, var(--accent) 60%, transparent); }
.pr-kick { margin: 0; font-size: 12px; letter-spacing: .06em; color: var(--accent); font-weight: 600; }
.pr h3 { margin: -8px 0 0; font-size: 21px; line-height: 1.4; letter-spacing: -0.02em; }
.pr h3 em { font-style: normal; color: var(--accent); }
.pr-flow { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; counter-reset: f; }
.pr-flow li {
  font-size: 12.5px; padding: 4px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--ink);
  font-weight: 600; position: relative;
}
.pr-flow li + li::before { content: "→"; color: var(--ink-3); margin: 0 6px 0 -2px; font-weight: 400; position: absolute; left: -14px; }
.pr-flow li + li { margin-left: 14px; }
/* 프로젝트 한눈에 */
.hl { list-style: none; margin: 22px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; }


/* CASES */
.case {
  background: var(--bg-elev); border: 1px solid var(--line); border-radius: calc(var(--radius) + 4px);
  padding: 32px; margin-bottom: 24px; box-shadow: var(--shadow);
}
.case-head { display: flex; gap: 24px; justify-content: space-between; align-items: flex-start; }
.case-kind { margin: 0 0 8px; font-size: 13px; color: var(--ink-3); }
.case-kind.mono { font-family: var(--sans); font-weight: 500; }
.case h3 { margin: 0 0 12px; font-size: 24px; line-height: 1.35; letter-spacing: -0.02em; }
.case-desc { margin: 0; color: var(--ink-2); line-height: 1.8; }
.case-links { display: flex; flex-direction: column; gap: 6px; flex-shrink: 0; }
.case-links a, .more, .links a {
  font-family: var(--mono); font-size: 13px; color: var(--accent); text-decoration: none;
}
.case-links a:hover, .more:hover, .links a:hover { text-decoration: underline; }

.tags { list-style: none; padding: 0; margin: 18px 0 0; display: flex; flex-wrap: wrap; gap: 6px; }
.tags li {
  font-family: var(--mono); font-size: 12px; padding: 3px 9px; border-radius: 999px;
  background: var(--bg-sunk); color: var(--ink-2); border: 1px solid var(--line);
}

.diagram {
  margin: 24px 0 0; padding: 16px; background: #ffffff; border-radius: 12px; border: 1px solid var(--line);
}
.diagram img { width: 100%; height: auto; cursor: zoom-in; }
.diagram figcaption { margin-top: 10px; font-size: 13px; color: var(--ink-3); }

.stories { margin-top: 24px; border-top: 1px solid var(--line); }
.stories details { border-bottom: 1px solid var(--line); scroll-margin-top: 76px; transition: background .2s; }
.stories summary {
  list-style: none; cursor: pointer; padding: 14px 6px;
  display: grid; grid-template-columns: 14px minmax(0, 1fr) minmax(190px, auto); align-items: center; gap: 16px;
}
.stories summary::-webkit-details-marker { display: none; }
.stories summary::before {
  content: "+"; font-family: var(--mono); color: var(--accent); width: 14px; font-weight: 700;
}
.stories details[open] summary::before { content: "−"; }
.s-title { font-weight: 600; font-size: 15px; line-height: 1.5; color: var(--ink-2); }
.s-res { display: flex; flex-direction: column; align-items: flex-end; text-align: right; gap: 1px; }
.s-res b { font-size: 17.5px; font-weight: 800; color: var(--accent); letter-spacing: -0.02em; line-height: 1.3; }
.s-res small { font-size: 12.5px; color: var(--ink-3); line-height: 1.4; }
.stories summary:hover .s-title { color: var(--ink); }
.stories summary:hover { background: color-mix(in srgb, var(--accent-soft) 45%, transparent); }
/* 펼친 항목은 테두리로 영역을 나누고 읽는 동안 제목 줄을 위에 고정 */
.stories details[open] {
  border: 1px solid color-mix(in srgb, var(--accent) 45%, var(--line)); border-radius: 12px;
  margin: 12px -10px; background: var(--bg); box-shadow: 0 10px 30px -22px rgba(0,0,0,.35);
}
.stories details[open] > summary {
  position: sticky; top: 61px; z-index: 6; background: var(--bg-elev);
  border-bottom: 1px solid var(--line); border-radius: 12px 12px 0 0; padding: 14px 16px;
}
.stories details[open] > summary .s-title { color: var(--ink); }
.stories details[open] > .story { padding: 4px 22px 22px 46px; }
.story-end { display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; margin-top: 26px; padding-top: 14px; border-top: 1px dashed var(--line); }
.story-end button {
  font: inherit; font-size: 13.5px; border: 1px solid var(--line); background: var(--bg-elev); color: var(--ink-2);
  border-radius: 999px; padding: 6px 14px; cursor: pointer;
}
.story-end button:hover { border-color: var(--accent); color: var(--accent); }
.story-end .next { font-weight: 700; color: var(--accent); }
.stories .group {
  margin: 30px 0 0; padding: 0 4px 8px; font-size: 13.5px; font-weight: 800;
  color: var(--ink); border-bottom: 2px solid var(--ink);
}
.stories .group:first-child { margin-top: 18px; }
.story { padding: 4px 4px 30px 34px; color: var(--ink-2); font-size: 15.5px; line-height: 1.75; }
.story p { margin: 0 0 10px; }
.story p.step { margin: 12px 0 4px; }
.story h4 {
  margin: 30px 0 10px; font-size: 15.5px; font-weight: 800; color: var(--ink);
  display: flex; align-items: center; gap: 9px;
}
.story h4::before { content: ""; width: 4px; height: 16px; border-radius: 2px; background: var(--accent); }
.story h4:first-of-type { margin-top: 14px; }
.story ul { margin: 0; padding-left: 18px; }
.story ul li { margin-bottom: 8px; padding-left: 2px; }
.story ul li::marker { color: var(--ink-3); }
.story strong { color: var(--ink); font-weight: 700; background: linear-gradient(transparent 62%, color-mix(in srgb, var(--accent) 22%, transparent) 62%); }
.story ul.res strong { background: none; color: var(--accent); }
.story ul.res {
  list-style: none; padding: 14px 18px; border-radius: 10px;
  background: var(--accent-soft); color: var(--ink);
}
.story ul.res li { position: relative; padding-left: 18px; }
.story ul.res li:last-child { margin-bottom: 0; }
.story ul.res li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-weight: 700; }
.story .diagram { margin: 4px 0 14px; padding: 10px; }
.story .links { margin-top: 12px; font-size: 14px; }

.cmp { width: 100%; border-collapse: collapse; margin: 12px 0; font-size: 14px; }
.cmp th, .cmp td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); }
.cmp th { color: var(--ink); font-weight: 700; font-size: 13.5px; background: var(--bg); }
.cmp td:nth-child(2) { color: var(--ink-3); font-family: var(--mono); }
.cmp td:nth-child(3) { color: var(--accent); font-family: var(--mono); font-weight: 600; }
/* 안 비교 표: 숫자 강조 대신 고른 안의 행만 강조한다 */
.cmp.opt td { color: var(--ink-2); font-family: var(--sans); font-weight: 400; }
.cmp.opt td:first-child { color: var(--ink); font-weight: 500; }
.cmp.opt tr.pick td { background: var(--accent-soft); color: var(--ink); }
.cmp.opt tr.pick td:first-child { color: var(--accent); font-weight: 700; }
.cmp.opt.pick-col3 td:nth-child(3) { background: var(--accent-soft); color: var(--ink); }
.cmp.opt.pick-col3 th:nth-child(3) { background: var(--accent-soft); color: var(--accent); }
.table-scroll { overflow-x: auto; }

.case-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.case.compact { padding: 24px; margin: 0; display: flex; flex-direction: column; }
.case.compact h3 { font-size: 20px; margin-bottom: 8px; }
.case.compact .case-desc { font-size: 14.5px; }
.bullets { padding: 0; margin: 16px 0 0; list-style: none; display: grid; gap: 10px; font-size: 14px; color: var(--ink-2); }
.bullets li { padding-left: 14px; position: relative; }
.bullets li::before { content: ""; position: absolute; left: 0; top: 0.72em; width: 6px; height: 1px; background: var(--accent); }
.bullets b { color: var(--ink); display: block; }
.case.compact .tags { margin-top: auto; padding-top: 18px; }
.more { margin-top: 14px; word-break: break-all; }

/* DEEP DIVES */
.deep-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.deep {
  background: var(--bg-elev); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; display: flex; flex-direction: column;
  border-top: 3px solid var(--accent);
}
.deep-area { margin: 0 0 10px; font-size: 13px; font-weight: 700; color: var(--accent); }
.deep h3 { margin: 0 0 8px; font-size: 19px; line-height: 1.4; letter-spacing: -0.01em; }
.deep-src { margin: 0 0 12px; font-size: 13px; color: var(--ink-3); }
.deep-desc { margin: 0; font-size: 14.5px; color: var(--ink-2); }
.deep .tags { margin-top: auto; padding-top: 18px; }

/* TIMELINE */
.timeline { list-style: none; padding: 0; margin: 0; }
.timeline > li { display: grid; grid-template-columns: 180px 1fr; gap: 24px; padding: 22px 0; border-top: 1px solid var(--line); }
.timeline > li:last-child { border-bottom: 1px solid var(--line); }
.t-date { margin: 2px 0 0; font-size: 13px; color: var(--ink-3); }
.timeline h3 { margin: 0; font-size: 18px; }
.timeline h3 span { font-weight: 400; color: var(--ink-3); font-size: 14px; margin-left: 8px; }
.timeline ul { margin: 10px 0 0; padding-left: 18px; color: var(--ink-2); font-size: 15px; }
.timeline ul li { margin-bottom: 4px; }
.timeline ul li::marker { color: var(--accent); }
.timeline .edu { padding: 16px 0; }

.certs { list-style: none; padding: 0; margin: 28px 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.certs li {
  background: var(--bg-elev); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; font-weight: 600; font-size: 15px;
}
.certs li span { display: block; font-size: 12px; color: var(--ink-3); font-weight: 400; margin-bottom: 4px; }
.certs small { display: block; font-weight: 400; color: var(--ink-3); font-size: 12.5px; }

/* STACK */
.stack { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 40px; }
.stack > div { padding: 18px 0; border-top: 1px solid var(--line); }
.stack h3 { margin: 0 0 6px; font-size: 13.5px; color: var(--accent); font-weight: 700; }
.stack p { margin: 0; color: var(--ink-2); font-size: 15px; }

/* FOOTER */
.footer { margin-top: 96px; border-top: 1px solid var(--line); padding: 40px 0 56px; }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 32px; }
.footer-inner p { margin: 0; }
.footer-links { display: flex; gap: 18px; }
.footer-links a { color: var(--ink-2); text-decoration: none; font-size: 14px; }
.footer-links a:hover { color: var(--accent); }
.copy { margin-left: auto !important; color: var(--ink-3); font-size: 13px; }

/* LIGHTBOX */
.lightbox {
  position: fixed; inset: 0; z-index: 50; background: rgb(0 0 0 / 0.8);
  display: grid; place-items: center; padding: 16px; cursor: zoom-out;
}
.lightbox img { max-height: 92vh; width: auto; max-width: 100%; background: #fff; border-radius: 8px; padding: 12px; }

/* REVEAL */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .cursor { animation: none; }
}

/* RESPONSIVE */
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; }
  .metrics { grid-template-columns: repeat(2, 1fr); }
  .metrics li:nth-child(3) { border-left: 0; }
  .metrics li:nth-child(n+3) { border-top: 1px solid var(--line); }
  .metrics li:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .principles, .case-grid, .deep-grid { grid-template-columns: 1fr; }
  .certs { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .hero { padding-top: 56px; }
  .nav nav { display: none; }
  .theme-toggle { margin-left: auto; }
  .metrics { grid-template-columns: 1fr; }
  .metrics li + li { border-left: 0; border-top: 1px solid var(--line); }
  .case { padding: 22px 18px; }
  .case-head { flex-direction: column; gap: 14px; }
  .case-links { flex-direction: row; flex-wrap: wrap; gap: 14px; }
  .cmp { font-size: 12.5px; }
  .cmp th, .cmp td { padding: 6px 5px; }
  .deep { padding: 22px 18px; }
  .timeline > li { grid-template-columns: 1fr; gap: 4px; }
  .timeline h3 span { display: block; margin: 2px 0 0; }
  .stack { grid-template-columns: 1fr; }
  .certs { grid-template-columns: 1fr; }
  .copy { margin-left: 0 !important; }
  .pr { padding: 22px 18px 18px; }
  .pr h3 { font-size: 19px; }
}

/* 일하는 방식 사례 */
.pr-ex { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.pr-ex a, .pr-ex li > div {
  display: grid; gap: 2px;
  padding: 12px 14px; border-radius: 10px; background: var(--bg); border: 1px solid var(--line);
  color: var(--ink-2); text-decoration: none; font-size: 14.5px; line-height: 1.65; transition: border-color .2s;
}
.pr-ex a:hover { border-color: var(--accent); color: var(--ink); }
.pr-proj { font-size: 12.5px; font-weight: 700; color: var(--accent); }

/* 결과 타일 */
.hl a {
  display: flex; flex-direction: column; gap: 2px; height: 100%; padding: 14px 16px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--bg); color: inherit; text-decoration: none; transition: border-color .2s, transform .2s;
}
.hl a:hover { border-color: var(--accent); transform: translateY(-2px); }
.hl-label { font-size: 12.5px; color: var(--ink-3); font-weight: 600; }
.hl-big { font-size: 24px; font-weight: 800; color: var(--accent); letter-spacing: -0.02em; line-height: 1.3; margin-top: 4px; }
.hl-from { font-size: 13px; color: var(--ink-3); }

/* 홈랩 기술 층 */
.layers { margin: 16px 0 0; display: grid; gap: 0; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.layers div { display: grid; grid-template-columns: 5.2em 1fr; gap: 12px; padding: 8px 12px; font-size: 13.5px; }
.layers div + div { border-top: 1px solid var(--line); }
.layers dt { color: var(--accent); font-weight: 700; }
.layers dd { margin: 0; color: var(--ink-2); }

/* NOVA 요청 흐름 */
.flow { margin: 24px 0 8px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); padding: 18px 20px 16px; }
.flow-head { display: flex; align-items: center; gap: 12px; justify-content: space-between; margin-bottom: 10px; }
.flow-title { margin: 0; font-weight: 700; font-size: 16px; }
.flow-play {
  font: inherit; font-size: 13.5px; font-weight: 700; border: 0; border-radius: 999px; padding: 7px 16px; cursor: pointer;
  background: var(--accent); color: #fff; display: inline-flex; gap: 6px; align-items: center; flex-shrink: 0;
}
.flow-play .i-pause, .flow.playing .flow-play .i-play { display: none; }
.flow.playing .flow-play .i-pause { display: inline; }
.flow-scroll { overflow-x: auto; }
.flow-svg { display: block; width: 100%; min-width: 760px; height: auto; font-family: var(--sans); }
.flow-svg .node rect { fill: var(--bg); stroke: var(--line); stroke-width: 1.5; transition: fill .3s, stroke .3s; }
.flow-svg .node.store rect { stroke-dasharray: 0; }
.flow-svg .node .nl { font-size: 14px; font-weight: 700; fill: var(--ink); text-anchor: middle; }
.flow-svg .node .ns { font-size: 11.5px; fill: var(--ink-3); text-anchor: middle; }
.flow-svg .node.done rect { stroke: color-mix(in srgb, var(--accent) 45%, var(--line)); }
.flow-svg .node.on rect { fill: var(--accent-soft); stroke: var(--accent); stroke-width: 2.5; }
.flow-svg .node.warn.on rect { fill: color-mix(in srgb, #d9534f 14%, var(--bg)); stroke: #d9534f; }
.flow-svg .edge { fill: none; stroke: color-mix(in srgb, var(--ink-3) 55%, transparent); stroke-width: 1.6; }
.flow-svg .edge.dash { stroke-dasharray: 5 4; }
.flow-svg .edge.done { stroke: color-mix(in srgb, var(--accent) 55%, transparent); }
.flow-svg .edge.on { stroke: var(--accent); stroke-width: 2.4; }
.flow-svg .edge.warn.on { stroke: #d9534f; }
.flow-svg .fa { fill: color-mix(in srgb, var(--ink-3) 70%, transparent); }
.flow-svg .zone path { stroke: var(--accent); stroke-width: 2; }
.flow-svg .zone.z2 path { stroke: #b7791f; }
.flow-svg .zone text { font-size: 12.5px; font-weight: 700; fill: var(--accent); }
.flow-svg .zone.z2 text { fill: #b7791f; }
.flow-svg .divider path { stroke: var(--ink-3); stroke-dasharray: 3 4; }
.flow-svg .divider text { font-size: 11.5px; fill: var(--ink-3); }
.flow-dot { fill: var(--accent); stroke: var(--bg-elev); stroke-width: 3; filter: drop-shadow(0 0 6px color-mix(in srgb, var(--accent) 70%, transparent)); }
.flow-dot.warn { fill: #d9534f; }
.flow-steps { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.flow-steps button {
  font: inherit; font-size: 13px; border: 1px solid var(--line); background: var(--bg); color: var(--ink-2);
  border-radius: 999px; padding: 4px 12px 4px 6px; cursor: pointer; display: inline-flex; gap: 6px; align-items: center;
}
.flow-steps button .mono { font-size: 11px; width: 18px; height: 18px; border-radius: 50%; display: inline-grid; place-items: center; background: var(--line); color: var(--ink-2); }
.flow-steps button.done { color: var(--ink); }
.flow-steps button.done .mono { background: color-mix(in srgb, var(--accent) 30%, var(--line)); }
.flow-steps button.on { border-color: var(--accent); color: var(--accent); font-weight: 700; }
.flow-steps button.on .mono { background: var(--accent); color: #fff; }
.flow-cap { margin-top: 12px; min-height: 3.4em; }
.flow-cap p { margin: 0; padding: 12px 14px; border-radius: 10px; background: var(--accent-soft); color: var(--ink); font-size: 15px; line-height: 1.7; }
.flow-cap p > b.mono { color: var(--accent); margin-right: 6px; font-size: 13px; }
.flow-cap a { color: var(--accent); font-weight: 600; text-decoration: none; white-space: nowrap; }
.flow-cap a:hover { text-decoration: underline; }
@media (max-width: 640px) {
  .flow { padding: 14px 12px; }
  .flow-head { flex-wrap: wrap; }
}

/* 그림: 항목 안에서는 높이를 제한하고, 누르면 크게 */
.diagram { position: relative; }
.diagram:has(img)::after {
  content: "🔍 크게 보기"; position: absolute; top: 10px; right: 12px; font-size: 12px; font-weight: 600;
  color: var(--ink-2); background: color-mix(in srgb, var(--bg-elev) 92%, transparent); border: 1px solid var(--line);
  padding: 3px 9px; border-radius: 999px; pointer-events: none; opacity: 0; transition: opacity .2s;
}
.diagram:hover::after { opacity: 1; }
@media (hover: none) { .diagram:has(img)::after { opacity: 1; } }
.story .diagram { padding: 12px; max-width: 860px; margin-left: auto; margin-right: auto; }
.story .diagram img { width: auto; max-width: 100%; max-height: 380px; margin: 0 auto; }

/* AI 개발 */
.ai-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.ai { background: var(--bg-elev); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px 26px; }
.ai-kind { margin: 0 0 8px; font-size: 12.5px; font-weight: 700; color: var(--accent); }
.ai h3 { margin: 0 0 18px; font-size: 19px; line-height: 1.45; letter-spacing: -0.01em; }
.ai-steps { list-style: none; margin: 0; padding: 0; counter-reset: s; display: grid; gap: 0; }
.ai-steps li { counter-increment: s; position: relative; padding: 0 0 16px 44px; display: grid; gap: 2px; }
.ai-steps li::before {
  content: counter(s); position: absolute; left: 0; top: 0; width: 28px; height: 28px; border-radius: 50%;
  display: grid; place-items: center; font-family: var(--mono); font-size: 13px; font-weight: 700;
  background: var(--accent-soft); color: var(--accent);
}
.ai-steps li:not(:last-child)::after { content: ""; position: absolute; left: 13.5px; top: 32px; bottom: 4px; width: 1px; background: var(--line); }
.ai-steps li:last-child { padding-bottom: 0; }
.ai-steps b { font-size: 15.5px; line-height: 28px; }
.ai-steps span { font-size: 14.5px; color: var(--ink-2); line-height: 1.7; }
.ai-tags { margin-top: 18px; }

/* Svalinn 결과 */
.deep-stat { margin: 16px 0 0; padding: 12px 14px; border-radius: 10px; background: var(--accent-soft); display: grid; gap: 2px; }
.deep-stat span { font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.deep-stat b { font-size: 24px; font-weight: 800; color: var(--accent); letter-spacing: -0.02em; }
.deep-stat small { font-size: 13px; color: var(--ink-2); }
@media (max-width: 960px) { .ai-grid { grid-template-columns: 1fr; } }

@media (max-width: 640px) {
  .hl { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .hl a { padding: 12px; }
  .hl-big { font-size: 19px; }
  .hl-label, .hl-from { font-size: 12px; }
  .diagram:has(img)::after { top: 6px; right: 6px; font-size: 10.5px; padding: 1px 7px; }
}

/* 개인 프로젝트 카드 */
.dstats { list-style: none; margin: 18px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.dstats li { display: flex; flex-direction: column; gap: 2px; padding: 12px; border-radius: 10px; background: var(--accent-soft); }
.dstats .hl-big { font-size: 19px; margin-top: 2px; }
.dstats .hl-label, .dstats .hl-from { font-size: 12px; color: var(--ink-2); }
.deep-h { margin: 22px 0 10px; font-size: 14px; font-weight: 800; color: var(--ink); display: flex; align-items: center; gap: 8px; }
.deep-h::before { content: ""; width: 4px; height: 14px; border-radius: 2px; background: var(--accent); }
.deep .bullets { margin: 0; }
.deep .layers { margin-top: 0; }
.deep .more { margin-top: 16px; display: inline-block; }
@media (max-width: 640px) { .dstats { grid-template-columns: repeat(2, 1fr); } .dstats li:last-child:nth-child(odd) { grid-column: 1 / -1; } .dstats .hl-big { font-size: 17px; } }

/* 프로젝트 목차: 본문 왼쪽 여백을 채우고 본문 바로 옆에 붙는다 */
.toc {
  --gut: calc((100vw - 1080px) / 2);
  position: fixed; top: 84px; z-index: 30;
  right: calc(100vw - var(--gut) + 20px); width: clamp(190px, calc(var(--gut) - 44px), 250px);
  max-height: calc(100vh - 110px); overflow-y: auto; font-size: 13.5px; line-height: 1.4;
  opacity: 0; visibility: hidden; transform: translateX(-8px); transition: opacity .25s, transform .25s, visibility .25s;
  scrollbar-width: none;
}
.toc::-webkit-scrollbar { display: none; }
.toc.show { opacity: 1; visibility: visible; transform: none; }
.toc-h { margin: 0 0 10px; font-size: 11.5px; font-weight: 800; letter-spacing: .06em; color: var(--ink-3); }
.toc ol { list-style: none; margin: 0; padding: 0; }
.toc-case > a {
  display: block; font-size: 14.5px; font-weight: 800; color: var(--ink); text-decoration: none;
  padding: 0 0 6px; border-bottom: 1px solid var(--line);
}
.toc-case + .toc-case { margin-top: 18px; }
.toc-grp { margin-top: 10px; }
.toc-g {
  display: inline-block; margin: 0 0 4px; padding: 1px 8px; border-radius: 6px;
  font-size: 11.5px; font-weight: 800; color: var(--accent); background: var(--accent-soft);
}
.toc-grp > ol { border-left: 2px solid var(--line); margin-left: 4px; }
.toc-item a {
  display: block; padding: 3px 0 3px 12px; margin-left: -2px; border-left: 2px solid transparent;
  color: var(--ink-3); text-decoration: none; transition: color .15s, border-color .15s, background .15s;
}
.toc-item a:hover { color: var(--ink); }
.toc-item a.open { color: var(--ink-2); }
.toc-item a.cur { color: var(--accent); border-left-color: var(--accent); font-weight: 700; background: color-mix(in srgb, var(--accent-soft) 60%, transparent); border-radius: 0 6px 6px 0; }
.toc-case.cur > a { color: var(--accent); border-bottom-color: color-mix(in srgb, var(--accent) 40%, var(--line)); }
.toc-btn { display: none; }
@media (max-width: 1539px) {
  .toc { left: 12px; right: auto; top: auto; bottom: 74px; width: 260px; max-height: 64vh; padding: 14px 16px;
    background: var(--bg-elev); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 18px 40px -18px rgba(0,0,0,.35); }
  .toc.show { opacity: 0; visibility: hidden; }
  .toc.show.panel { opacity: 1; visibility: visible; }
  .toc-btn {
    position: fixed; left: 12px; bottom: 18px; z-index: 31; font: inherit; font-size: 13px; font-weight: 700;
    border: 1px solid var(--line); background: var(--bg-elev); color: var(--ink); border-radius: 999px; padding: 9px 14px;
    box-shadow: 0 10px 24px -14px rgba(0,0,0,.4); cursor: pointer; max-width: calc(100vw - 24px);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
    opacity: 0; visibility: hidden; transition: opacity .25s, visibility .25s;
  }
  .toc-btn.show { opacity: 1; visibility: visible; display: block; }
  .toc-btn { display: block; }
  .toc-btn b { color: var(--accent); }
}
@media (max-width: 640px) {
  .stories summary { grid-template-columns: 14px minmax(0, 1fr); row-gap: 4px; }
  .s-res { grid-column: 2; align-items: flex-start; text-align: left; }
  .stories details[open] { margin: 10px -6px; }
  .stories details[open] > summary { top: 57px; padding: 12px; }
  .stories details[open] > summary .s-title { font-size: 14px; }
  .stories details[open] > summary .s-res b { font-size: 15px; }
  .stories details[open] > summary .s-res small { display: none; }
  .stories details[open] > .story { padding: 4px 12px 18px 14px; }
}
.toc-case > ol:not(:has(.toc-grp)) { border-left: 2px solid var(--line); margin: 8px 0 0 4px; }
.toc-item a { padding-block: 2.5px; }

/* 검토 반영 */
.pr-kick.mono, .pr-proj.mono { font-family: var(--sans); letter-spacing: 0; }
.case-desc { max-width: 46em; }
.ai { display: flex; flex-direction: column; }
.ai-res {
  margin: auto 0 0; padding: 12px 14px; border-radius: 10px; background: var(--accent-soft);
  color: var(--accent); font-size: 14px; font-weight: 700; line-height: 1.6;
}
.ai-steps { margin-bottom: 18px; }
.t-kind { display: block; font-family: var(--sans); font-size: 12px; font-weight: 800; color: var(--accent); margin-bottom: 2px; }
@media (max-width: 640px) {
  .metrics { grid-template-columns: repeat(2, 1fr); }
  .metrics li { padding: 14px; }
  .metrics li + li { border-left: 0; }
  .metrics li:nth-child(even) { border-left: 1px solid var(--line); }
  .metrics li:nth-child(n+3) { border-top: 1px solid var(--line); }
  .metrics li:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .m-val { font-size: 22px; }
  .m-label, .m-from, .m-ctx { font-size: 12px; }
  .metrics li:nth-child(2) { border-top: 0; }
}

/* 개인 프로젝트: 카드 한 장을 머리, 지표, (한 일 | 기술) 두 단으로 */
.deep-grid { grid-template-columns: 1fr; gap: 20px; }
.deep { padding: 30px 32px; }
.deep-head { max-width: 46em; }
.deep h3 { font-size: 21px; }
.deep .dstats { margin-top: 20px; }
.deep .dstats li { padding: 14px 16px; }
.deep .dstats .hl-big { font-size: 22px; }
.deep .dstats .hl-label, .deep .dstats .hl-from { font-size: 12.5px; }
.deep-body { display: grid; grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr); gap: 36px; margin-top: 8px; }
.deep .bullets { gap: 0; font-size: 14.5px; }
.deep .bullets li { display: grid; grid-template-columns: 7.2em minmax(0, 1fr); gap: 14px; padding: 11px 0; border-top: 1px solid var(--line); }
.deep .bullets li:last-child { border-bottom: 1px solid var(--line); }
.deep .bullets li::before { display: none; }
.deep .bullets b { color: var(--accent); font-weight: 800; }
.deep .bullets strong { color: var(--ink); font-weight: 700; }
.deep-tech .layers div { grid-template-columns: 4.6em minmax(0, 1fr); padding: 10px 12px; }
.deep-tech .more { word-break: break-all; }
@media (max-width: 900px) {
  .deep-body { grid-template-columns: 1fr; gap: 0; }
}
@media (max-width: 640px) {
  .deep { padding: 22px 18px; }
  .deep h3 { font-size: 19px; }
  .deep .dstats .hl-big { font-size: 17px; }
  .deep .bullets li { grid-template-columns: 1fr; gap: 2px; }
}

/* 기술: 대표 아이콘과 이름 */
.stack .tech { margin: 4px 0 0; display: flex; flex-wrap: wrap; gap: 7px; }
.tech > span { display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px 5px 8px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg-elev); font-size: 14px; color: var(--ink); line-height: 1.3; }
.tech img { width: 18px; height: 18px; object-fit: contain; flex: none; }
:root[data-theme="dark"] .tech img.dk { filter: brightness(0) invert(0.92); }

/* 기술: 한 줄에 한 그룹. 왼쪽 그룹 이름, 오른쪽 기술 */
.stack { grid-template-columns: 1fr; }
.stack > div { display: grid; grid-template-columns: 9.5em minmax(0, 1fr); gap: 20px; align-items: start; padding: 16px 0; }
.stack > div:last-child { border-bottom: 1px solid var(--line); }
.stack h3 { margin: 0; padding-top: 7px; }
.stack .tech { margin: 0; }
.tech > span.no-ic { padding-left: 11px; }
@media (max-width: 640px) {
  .stack > div { grid-template-columns: 1fr; gap: 8px; }
  .stack h3 { padding-top: 0; }
}

/* 프로젝트 개요: 레포 링크를 아래 한 줄로 내려 설명이 전체 너비를 쓰게 */
.case-head { display: block; }
.case-desc { max-width: none; word-break: keep-all; text-wrap: pretty; }
.case-links { flex-direction: row; flex-wrap: wrap; gap: 6px 18px; margin-top: 12px; }

/* 인프라 그룹 머리의 아키텍처 그림 */
.stories .group-fig { margin: 4px 0 18px; }

/* 전체 아키텍처 그림은 조금 작게, 가운데 정렬 (눌러서 크게 보기는 그대로) */
.diagram.arch img { display: block; width: 74%; margin: 0 auto; }
@media (max-width: 900px) { .diagram.arch img { width: 100%; } }

/* 프로젝트 개요의 맡은 업무 */
.role { margin-top: 16px; padding: 14px 18px; border: 1px solid var(--line); border-left: 3px solid var(--accent); border-radius: 10px; background: var(--bg-elev); }
.role-h { margin: 0 0 8px; font-size: 13px; font-weight: 800; color: var(--ink); }
.role dl { margin: 0; display: grid; gap: 8px; }
.role dl > div { display: grid; grid-template-columns: 4.2em minmax(0, 1fr); gap: 12px; align-items: baseline; }
.role dt { font-size: 13px; font-weight: 700; color: var(--accent); }
.role dd { margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.role dd span { padding: 3px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--ink); font-size: 13.5px; line-height: 1.5; }
.role-note { margin: 10px 0 0; font-size: 12.5px; color: var(--ink-3); }
@media (max-width: 640px) { .role dl > div { grid-template-columns: 1fr; gap: 4px; } }

/* 경력과 교육: 경력, 교육, 학력, 자격증을 묶음으로 구분 */
.cv-group + .cv-group { margin-top: 36px; }
.cv-h { margin: 0 0 12px; font-size: 16px; font-weight: 800; color: var(--ink); display: flex; align-items: baseline; gap: 10px; }
.cv-h::before { content: ""; align-self: center; width: 4px; height: 16px; border-radius: 2px; background: var(--accent); }
.cv-h small { font-size: 13.5px; font-weight: 500; color: var(--ink-3); }
.timeline h4 { margin: 0; font-size: 18px; }
.timeline h4 span { font-weight: 400; color: var(--ink-3); font-size: 14px; margin-left: 8px; }
.t-len { display: block; margin-top: 4px; font-family: var(--sans); font-size: 12.5px; font-weight: 700; color: var(--accent); }
.cv-group .certs { margin-top: 0; }
@media (max-width: 640px) { .timeline h4 span { display: block; margin: 2px 0 0; } .cv-h { flex-wrap: wrap; } }

/* 담당 상자: 담당은 글, 기술은 칩, 저장소는 링크 */
.role dd { display: block; font-size: 14.5px; line-height: 1.7; color: var(--ink-2); }
.role .role-tech, .role .role-repo { padding-top: 8px; border-top: 1px dashed var(--line); }
.role .role-tech .tags { margin: 0; }
.role .role-repo dd { display: flex; flex-wrap: wrap; gap: 4px 18px; font-family: var(--mono); font-size: 13.5px; }
.role .role-repo a { color: var(--accent); text-decoration: none; }
.role .role-repo a:hover { text-decoration: underline; }
/* 펼친 항목의 소제목과 설계만 한 부분 메모 */
.story ul li.sub-h { list-style: none; margin: 12px 0 4px -18px; font-size: 13.5px; font-weight: 700; color: var(--accent); }
.story ul li.sub-h:first-child { margin-top: 0; }
.story .memo { margin: 10px 0 0; padding: 10px 14px; border-radius: 8px; background: var(--bg); border: 1px dashed var(--line); font-size: 14px; color: var(--ink-3); }

/* 담당 상자: 왼쪽 띠 대신 위쪽 제목 줄로 구분 */
.role { border-left: 1px solid var(--line); padding: 0; overflow: hidden; }
.role-h { margin: 0; padding: 9px 18px; font-size: 12.5px; font-weight: 800; letter-spacing: .02em; color: var(--ink-2); background: var(--bg); border-bottom: 1px solid var(--line); }
.role dl { gap: 0; }
.role dl > div { padding: 10px 18px; }
.role dl > div + div { border-top: 1px solid var(--line); }
.role .role-tech, .role .role-repo { padding-top: 10px; border-top: 1px solid var(--line); }
.role-note { margin: 0; padding: 8px 18px 10px; border-top: 1px solid var(--line); }


/* 버건디 + 세이지 조합: 결과 칸은 흰 바탕 위 세이지 선, 숫자는 버건디 */
:root { --sage: #7a9b76; }
:root[data-theme="dark"] { --sage: #9dbb99; }
.metrics .m-val b { color: var(--accent); }
.btn.ghost { background: var(--sage); border-color: var(--sage); color: #ffffff; font-weight: 700; }
:root[data-theme="dark"] .btn.ghost { color: #0e0a09; }
.btn.ghost:hover { border-color: var(--accent); }

/* 첫 화면 한눈에 보기: 테두리 없이 옅은 면 위에 항목별로 */
.glance { border-radius: 18px; background: var(--bg-sunk); padding: 28px 30px; display: grid; gap: 22px; }
.g-k { margin: 0 0 8px; font-size: 12.5px; font-weight: 700; color: var(--ink-3); letter-spacing: .02em; }
.g-big { margin: 0; font-size: 34px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.15; color: var(--accent); }
.g-sub { margin: 4px 0 0; font-size: 14px; color: var(--ink-2); }
.g-career { padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.g-stack, .g-certs { margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.g-stack span { display: inline-flex; align-items: center; gap: 7px; padding: 6px 12px 6px 9px; border-radius: 999px; background: var(--bg-elev); font-size: 14px; font-weight: 600; color: var(--ink); }
.g-stack img { width: 20px; height: 20px; object-fit: contain; }
.g-certs span { padding: 5px 12px; border-radius: 8px; background: var(--bg-elev); font-size: 14px; font-weight: 700; color: var(--ink); }
.g-text { margin: 0; font-size: 15.5px; color: var(--ink); }

/* 경력 카드 */
.jobs { display: grid; gap: 16px; }
.job { border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); padding: 24px 28px; }
.job-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.job-head h4 { margin: 0; font-size: 20px; }
.job-role { margin: 4px 0 0; font-size: 14px; color: var(--ink-3); }
.job-date { margin: 0; text-align: right; flex-shrink: 0; }
.job-date span { display: block; font-size: 13px; color: var(--ink-3); }
.job-date b { display: block; margin-top: 2px; font-size: 14px; color: var(--accent); }
.job-body { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; padding-top: 16px; }
.job-k { margin: 0 0 8px; font-size: 13px; font-weight: 800; color: var(--accent); }
.job ul, .cv-mini ul { margin: 0; padding-left: 18px; color: var(--ink-2); font-size: 15px; line-height: 1.65; }
.job li + li, .cv-mini li + li { margin-top: 6px; }
.job li::marker, .cv-mini li::marker { color: var(--ink-3); }

/* 교육, 학력, 자격증 */
.cv-row { display: grid; grid-template-columns: 1.3fr 1fr 1.2fr; gap: 16px; margin-top: 36px; }
.cv-mini { border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); padding: 20px 22px; }
.cv-k { margin: 0 0 10px; font-size: 13px; font-weight: 800; color: var(--accent); }
.cv-mini h4 { margin: 0; font-size: 17px; }
.cv-sub { margin: 4px 0 12px; font-size: 13.5px; color: var(--ink-3); }
.cv-sub .mono { font-size: 12.5px; }
.cert-list { list-style: none; padding: 0 !important; }
.cert-list li { display: flex; justify-content: space-between; gap: 10px; padding: 6px 0; border-top: 1px solid var(--line); margin: 0 !important; }
.cert-list li:first-child { border-top: 0; padding-top: 0; }
.cert-list b { font-weight: 600; color: var(--ink); font-size: 14.5px; }
.cert-list span { font-size: 12.5px; color: var(--ink-3); flex-shrink: 0; }
@media (max-width: 900px) { .cv-row { grid-template-columns: 1fr; } .job-body { grid-template-columns: 1fr; gap: 16px; } }
@media (max-width: 640px) { .job { padding: 20px; } .job-head { flex-direction: column; gap: 6px; } .job-date { text-align: left; } .job-date span, .job-date b { display: inline; margin: 0 8px 0 0; } .glance { padding: 18px 20px; } }

/* 첫 화면 수치: 테두리 없이 큰 숫자로 나열 */
.metrics { border: 0; border-radius: 0; background: none; overflow: visible; gap: 40px; margin-top: 64px; }
.metrics li { padding: 0; }
.metrics li + li { border-left: 0; }
.m-label { font-size: 14px; }
.m-val { font-size: 48px; line-height: 1.1; margin: 6px 0 4px; }
.m-from { font-size: 14px; }
.m-ctx { font-size: 14.5px; margin-top: 6px; }
@media (max-width: 640px) { .metrics { gap: 28px; } .m-val { font-size: 38px; } }
.metrics > li { border: 0 !important; padding: 0 !important; }
@media (max-width: 640px) { .metrics { grid-template-columns: 1fr; } .metrics li:last-child:nth-child(odd) { grid-column: auto; } }

/* 한눈에 보기: 배경 면 없이 흰 바탕 그대로, 칩만 중립 회색 */
.glance { background: none; padding: 4px 0 4px 32px; border-radius: 0; }
.g-stack span, .g-certs span { background: var(--bg-sunk); }
@media (max-width: 900px) { .glance { padding: 0; } }

/* 강조 역할 나누기: 버건디는 제목 강조에만, 숫자는 검정, 나머지 표시는 짙은 세이지(--accent) */
:root { --brand: #5a2328; }
:root[data-theme="dark"] { --brand: #d9969c; }
h1 em, .pr h3 em { color: var(--brand); }
.m-val b, .metrics .m-val b, .hl-big, .g-big { color: var(--ink); }

/* 경력과 교육: 상자 테두리 없이 여백과 글자 크기로 구분 */
.job, .cv-mini { border: 0; border-radius: 0; background: none; padding: 0; }
.jobs { gap: 48px; }
.job-head { border-bottom: 0; padding-bottom: 0; }
.job-head h4 { font-size: 22px; }
.job-body { padding-top: 18px; }
.cv-row { margin-top: 56px; gap: 40px; }
.cert-list li { border-top: 0; padding: 3px 0; }
@media (max-width: 640px) { .jobs { gap: 36px; } .job { padding: 0; } .cv-row { gap: 32px; } }
#career .cv-h { margin-bottom: 26px; }

/* 경력과 교육: 왼쪽 기간 열과 오른쪽 내용 열을 한 줄로 맞춘 이력서형 배치 */
.cv-list { display: grid; gap: 0; }
.cv-item { display: grid; grid-template-columns: 180px minmax(0, 1fr); gap: 32px; padding: 28px 0; }
.cv-item + .cv-item { border-top: 1px solid var(--line); }
.cv-meta p { margin: 0; }
.cv-date { font-size: 13.5px; color: var(--ink-2); padding-top: 5px; }
.cv-len { margin-top: 4px !important; font-size: 13.5px; font-weight: 700; color: var(--accent); }
.cv-main h4 { margin: 0; font-size: 21px; line-height: 1.35; }
.cv-role { margin: 4px 0 0; font-size: 14.5px; color: var(--ink-3); }
.cv-main .job-body { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; padding-top: 18px; }
.cv-main .job-k { margin: 0 0 8px; font-size: 13px; font-weight: 800; color: var(--accent); }
.cv-main ul { margin: 0; padding-left: 18px; color: var(--ink-2); font-size: 15px; line-height: 1.7; }
.cv-main li + li { margin-top: 6px; }
.cv-main li::marker { color: var(--ink-3); }
.cv-ul { margin-top: 12px !important; }
.cert-grid { list-style: none; padding: 0 !important; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 32px; }
.cert-grid li { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 12px; margin: 0 !important; }
.cert-grid b { font-size: 17px; color: var(--ink); }
.cert-grid span { grid-column: 1; font-size: 13.5px; color: var(--ink-3); }
.cert-grid em { grid-column: 2; grid-row: 1 / span 2; align-self: start; padding-top: 3px; font-style: normal; font-size: 13px; color: var(--ink-3); }
#career .cv-group + .cv-group { margin-top: 48px; }
#career .cv-h { margin-bottom: 4px; }
@media (max-width: 900px) { .cv-main .job-body { grid-template-columns: 1fr; gap: 18px; } }
@media (max-width: 640px) {
  .cv-item { grid-template-columns: 1fr; gap: 8px; padding: 22px 0; }
  .cv-meta { display: flex; gap: 10px; align-items: baseline; }
  .cv-date { padding-top: 0; }
  .cv-len { margin-top: 0 !important; }
  .cert-grid { grid-template-columns: 1fr; }
}
/* 불릿은 한 단으로 길게 읽히게, 묶음 이름은 왼쪽 작은 열 */
.cv-main .job-body { grid-template-columns: 1fr; gap: 14px; }
.cv-main .job-col { display: grid; grid-template-columns: 4.5em minmax(0, 1fr); gap: 12px; align-items: baseline; }
.cv-main .job-k { margin: 0; }
@media (max-width: 640px) { .cv-main .job-col { grid-template-columns: 1fr; gap: 6px; } }
.cv-only { margin-top: 5px !important; }
/* 경력 불릿이 줄바꿈되지 않게: 넓은 화면은 기간 열을 줄이고, 1100px 아래는 기간을 이름 위로 */
.cv-item { grid-template-columns: 150px minmax(0, 1fr); gap: 28px; }
.cv-main .job-col { grid-template-columns: 4em minmax(0, 1fr); }
@media (max-width: 1100px) {
  .cv-item { grid-template-columns: 1fr; gap: 8px; }
  .cv-meta { display: flex; gap: 10px; align-items: baseline; }
  .cv-date { padding-top: 0; }
  .cv-len, .cv-only { margin-top: 0 !important; }
}
.cv-link { margin: 12px 0 0; font-family: var(--mono); font-size: 13.5px; }
.cv-link a { color: var(--accent); text-decoration: none; }
.cv-link a:hover { text-decoration: underline; }
/* 다시 두 단: 묶음 이름은 위, 불릿은 한 줄 */
.cv-main .job-body { grid-template-columns: minmax(0, max-content) minmax(0, 1fr); gap: 32px; }
.cv-main .job-col { display: block; }
.cv-main .job-k { margin: 0 0 8px; }
@media (max-width: 760px) { .cv-main .job-body { grid-template-columns: 1fr; gap: 18px; } }

/* 일하는 방식: 카드 대신 한 줄에 원칙 하나. 왼쪽은 원칙과 흐름, 오른쪽은 사례 */
.principles { grid-template-columns: 1fr; gap: 0; }
.pr {
  display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); column-gap: 48px; row-gap: 10px;
  grid-template-areas: "kick ex" "title ex" "flow ex";
  align-content: start;
  background: none; border: 0; border-radius: 0; box-shadow: none; padding: 32px 0;
}
.pr + .pr { border-top: 1px solid var(--line); }
.pr:hover { border-color: var(--line); box-shadow: none; }
.pr-kick { grid-area: kick; font-size: 13px; }
.pr h3 { grid-area: title; margin: 0; font-size: 24px; line-height: 1.4; }
.pr-flow { grid-area: flow; align-self: start; margin-top: 6px; gap: 0; }
.pr-flow li { background: none; padding: 0; font-size: 14px; font-weight: 600; color: var(--ink-3); }
.pr-flow li + li { margin-left: 22px; }
.pr-flow li + li::before { left: -16px; margin: 0; }
.pr-ex { grid-area: ex; gap: 4px; align-self: start; }
.pr-ex a, .pr-ex li > div {
  position: relative; display: grid; grid-template-columns: 7.5em minmax(0, 1fr); gap: 14px; align-items: baseline;
  background: none; border: 0; border-radius: 10px; padding: 12px 36px 12px 14px; margin: 0 -14px;
  font-size: 15px; line-height: 1.7; color: var(--ink-2);
}
.pr-ex a::after { content: "→"; position: absolute; right: 14px; top: 12px; color: var(--ink-3); transition: transform .2s, color .2s; }
.pr-ex a:hover { background: var(--bg-sunk); color: var(--ink); }
.pr-ex a:hover::after { color: var(--accent); transform: translateX(3px); }
.pr-proj { font-size: 13px; }
@media (max-width: 960px) {
  .pr { grid-template-columns: 1fr; grid-template-areas: "kick" "title" "flow" "ex"; }
  .pr-ex { margin-top: 10px; }
}
@media (max-width: 640px) {
  .pr { padding: 26px 0; }
  .pr h3 { font-size: 20px; }
  .pr-ex a, .pr-ex li > div { grid-template-columns: 1fr; gap: 2px; }
}
.pr { grid-template-rows: auto auto 1fr; }
.pr-ex a, .pr-ex li > div { grid-template-columns: 1fr; gap: 2px; padding: 10px 40px 10px 14px; }
.pr-ex a::after { top: 50%; transform: translateY(-50%); }
.pr-ex a:hover::after { transform: translate(3px, -50%); }
.pr-flow li + li { margin-left: 26px; }
.pr-flow li + li::before { left: -19px; }
/* 일하는 방식: 왼쪽 원칙 묶음을 사례 높이의 가운데에 */
.pr { grid-template-rows: 1fr auto auto auto 1fr; grid-template-areas: "s1 ex" "kick ex" "title ex" "flow ex" "s2 ex"; }
@media (max-width: 960px) { .pr { grid-template-rows: none; grid-template-areas: "kick" "title" "flow" "ex"; } }
:root[data-theme="dark"] .g-stack img.dk { filter: brightness(0) invert(0.92); }

/* 프로젝트: 바깥 카드 테두리 없이 여백과 구분선으로 */
.case { border: 0; border-radius: 0; box-shadow: none; background: none; padding: 0; margin-bottom: 0; }
.case + .case { margin-top: 88px; padding-top: 64px; border-top: 1px solid var(--line); }
.case h3 { font-size: 28px; margin-bottom: 14px; }
.case-desc { font-size: 16.5px; }

/* 담당: 상자 없이 줄 구분만 */
.role { border: 0; border-radius: 0; background: none; margin-top: 24px; }
.role-h { display: none; }
.role dl > div { padding: 12px 0; grid-template-columns: 5em minmax(0, 1fr); gap: 16px; }
.role dl > div:first-child { border-top: 1px solid var(--line); }
.role dl > div:last-child { border-bottom: 1px solid var(--line); }
.role .role-tech, .role .role-repo { border-top: 1px solid var(--line); padding-top: 12px; }
.role-note { border-top: 0; padding: 8px 0 0; }
.role dt { padding-top: 1px; }

/* 결과: 카드 대신 큰 숫자 나열 */
.hl { margin-top: 36px; gap: 32px; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.hl a { border: 0; border-radius: 0; background: none; padding: 0; transform: none !important; }
.hl a:hover .hl-big { color: var(--accent); }
.hl-big { font-size: 28px; margin-top: 6px; }
.hl-label { font-size: 13.5px; }
.hl-from { font-size: 13.5px; }
@media (max-width: 960px) { .hl { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; } }

/* 그림과 목록 사이 여백, 묶음 제목은 가는 선 */
.case > .diagram { margin-top: 40px; }
.stories { margin-top: 40px; border-top: 0; }
.stories .group { border-bottom: 1px solid var(--line); color: var(--accent); font-size: 14px; padding: 0 0 10px; margin-top: 40px; }
.stories .group:first-child { margin-top: 0; }
.role dd { text-wrap: pretty; }
.case > .diagram, .stories > .diagram { border: 0; padding: 0; background: none; }
@media (max-width: 640px) {
  .role dl > div { grid-template-columns: 1fr; gap: 6px; }
  .hl { gap: 20px 16px; }
  .hl-big { font-size: 21px; }
  .case h3 { font-size: 23px; }
}

/* 섹션 소개 문장은 제목 번호 아래부터, 본문과 같은 왼쪽 선에 */
.sec-sub { grid-column: 1 / -1; margin-top: 12px; }

/* 담당: 가운뎃점 나열 대신 항목 목록, 항목 중간에서 줄이 끊기지 않게 */
.role dl > div { grid-template-columns: 4.5em minmax(0, 1fr); padding: 14px 0; }
.role-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 6px 28px; }
.role-list li { position: relative; padding-left: 14px; font-size: 14.5px; line-height: 1.6; color: var(--ink); }
.role-list li::before { content: ""; position: absolute; left: 0; top: .78em; width: 5px; height: 5px; border-radius: 50%; background: var(--ink-3); }

/* 기술 칩: 첫 화면 칩과 같은 결 */
.tags li { font-family: var(--sans); font-size: 13px; font-weight: 500; border: 0; background: var(--bg-sunk); color: var(--ink-2); padding: 4px 11px; }

/* 프로젝트 머리 정보 */
.case-kind.mono { color: var(--ink-2); font-weight: 600; }

/* 목차: 색 바탕 배지 없이 글자로만 */
.toc-g { background: none; padding: 0; color: var(--ink-3); font-size: 11.5px; letter-spacing: .04em; }
.toc-item a.cur { background: none; }
.toc-grp { margin-top: 12px; }
@media (max-width: 640px) {
  .role-list { grid-template-columns: 1fr; }
}
.role-list { display: flex; flex-wrap: wrap; gap: 6px 26px; max-width: 900px; }
.role-list li { white-space: nowrap; }
@media (max-width: 640px) { .role-list { display: grid; } .role-list li { white-space: normal; } }

/* 프로젝트 카드 (메인) */
.pcards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.pcard {
  display: flex; flex-direction: column; gap: 14px; padding: 32px; border-radius: 18px;
  background: var(--bg-sunk); color: var(--ink); text-decoration: none;
  transition: transform .2s, box-shadow .2s;
}
.pcard:hover { transform: translateY(-3px); box-shadow: 0 18px 40px -24px rgba(0,0,0,.35); }
.pcard:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.pcard-kind { margin: 0; font-size: 13px; font-weight: 600; color: var(--ink-3); }
.pcard h3 { margin: -6px 0 0; font-size: 24px; line-height: 1.35; letter-spacing: -0.02em; }
.pcard-desc { margin: 0; font-size: 15px; line-height: 1.7; color: var(--ink-2); }
.pcard-role { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 0; font-size: 14px; font-weight: 700; color: var(--accent); }
.pcard-role li + li::before { content: "·"; margin: 0 8px; color: var(--ink-3); font-weight: 400; }
.pcard-res { list-style: none; margin: 8px 0 0; padding: 18px 0 0; border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.pcard-res li { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.pcard-res b { font-size: 22px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.3; color: var(--ink); }
.pcard-res span { font-size: 13px; color: var(--ink-2); line-height: 1.45; }
.pcard-res small { font-size: 12.5px; color: var(--ink-3); line-height: 1.45; }
.pcard-tags { list-style: none; margin: auto 0 0; padding: 8px 0 0; display: flex; flex-wrap: wrap; gap: 6px; }
.pcard-tags li { font-size: 12.5px; font-weight: 500; padding: 3px 10px; border-radius: 999px; background: var(--bg); color: var(--ink-2); }
.pcard-more { font-size: 14px; font-weight: 700; color: var(--accent); }
.pcard:hover .pcard-more { text-decoration: underline; }
@media (max-width: 960px) { .pcards { grid-template-columns: 1fr; } }
@media (max-width: 640px) {
  .pcard { padding: 24px 20px; }
  .pcard h3 { font-size: 21px; }
  .pcard-res { grid-template-columns: 1fr; gap: 12px; }
  .pcard-res li { flex-direction: row; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; }
  .pcard-res small { flex-basis: 100%; }
}

/* 프로젝트 상세 페이지 */
.project-page { padding-top: 40px; }
.crumb { display: flex; justify-content: space-between; gap: 16px; margin-bottom: 36px; font-size: 14px; font-weight: 600; }
.crumb a { color: var(--ink-3); text-decoration: none; }
.crumb a:hover { color: var(--accent); }
.page-sub { margin: 0 0 20px; color: var(--ink-3); font-size: 14px; }
.case .case-title { margin: 0 0 14px; font-size: clamp(28px, 3.6vw, 38px); line-height: 1.3; letter-spacing: -0.025em; }
.next-proj { display: block; margin-top: 72px; padding: 28px 0; border-top: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.next-proj small { display: block; font-size: 13px; color: var(--ink-3); margin-bottom: 4px; }
.next-proj b { font-size: 22px; letter-spacing: -0.02em; }
.next-proj:hover b { color: var(--accent); }
.case > .page-sub { margin: 48px 0 0; }
.case > .page-sub + .stories { margin-top: 20px; }
.pcard-role li { white-space: nowrap; }
.pcard-role li + li::before { content: none; }
.pcard-role li:not(:last-child)::after { content: "·"; margin: 0 8px; color: var(--ink-3); font-weight: 400; }

/* 프로젝트 카드: 팔레트 #C8BFC7 바탕, 결과는 흰 면, 버튼은 #5A2328 */
:root { --card: #c8bfc7; --card-panel: #ffffff; --card-ink-2: #3a3330; }
:root[data-theme="dark"] { --card: #2b2629; --card-panel: #1a1719; --card-ink-2: #c9c0c6; }
.pcards { gap: 28px; }
.pcard {
  background: var(--card); padding: 34px 34px 30px; border-radius: 22px; gap: 16px;
  transition: transform .25s ease, box-shadow .25s ease;
}
.pcard:hover { transform: translateY(-4px); box-shadow: 0 26px 48px -28px rgb(9 3 2 / .45); }
.pcard-kind {
  align-self: flex-start; padding: 4px 12px; border-radius: 999px;
  background: var(--card-panel); color: var(--card-ink-2); font-size: 12.5px; font-weight: 600;
}
.pcard h3 { margin: 2px 0 0; font-size: 26px; }
.pcard-desc { color: var(--card-ink-2); }
.pcard-role { color: var(--brand); font-size: 14.5px; }
.pcard-role li:not(:last-child)::after { color: var(--card-ink-2); opacity: .6; }
.pcard-res {
  margin: 4px 0 0; padding: 20px 22px; border-top: 0; border-radius: 16px; background: var(--card-panel);
  gap: 18px;
}
.pcard-res b { font-size: 23px; }
.pcard-res span { color: var(--ink-2); font-weight: 600; }
.pcard-tags { padding-top: 4px; }
.pcard-tags li { background: rgb(255 255 255 / .55); color: var(--card-ink-2); }
:root[data-theme="dark"] .pcard-tags li { background: rgb(255 255 255 / .08); }
.pcard-more {
  align-self: flex-start; margin-top: 4px; padding: 10px 18px; border-radius: 999px;
  background: var(--brand); color: #ffffff; font-size: 14px; transition: padding .2s;
}
:root[data-theme="dark"] .pcard-more { color: #1a0d0e; }
.pcard:hover .pcard-more { text-decoration: none; padding-right: 22px; }
@media (max-width: 640px) {
  .pcard { padding: 24px 20px 22px; border-radius: 18px; }
  .pcard h3 { font-size: 22px; }
  .pcard-res { padding: 16px 18px; }
}
/* 결과는 줄 단위: 왼쪽 큰 값, 오른쪽 설명 */
.pcard-res { grid-template-columns: 1fr; gap: 0; padding: 6px 22px; }
.pcard-res li { display: grid; grid-template-columns: 8.2em minmax(0, 1fr); column-gap: 16px; align-items: baseline; padding: 12px 0; }
.pcard-res li + li { border-top: 1px solid var(--line); }
.pcard-res b { grid-row: span 2; font-size: 21px; white-space: nowrap; }
.pcard-res span { font-size: 13.5px; }
.pcard-res small { font-size: 12.5px; }
@media (max-width: 640px) {
  .pcard-res li { grid-template-columns: 1fr; flex-direction: column; }
  .pcard-res b { grid-row: auto; }
}
.pcard-res li { align-items: center; row-gap: 1px; }
/* 카드 색: 말씀하신 흰 계열 #f0f0f0 바탕, 버건디는 쓰지 않음 */
:root { --card: #f0f0f0; --card-panel: #ffffff; --card-ink-2: #3a3330; }
:root[data-theme="dark"] { --card: #1b1b1b; --card-panel: #111111; --card-ink-2: #b8b8b8; }
.pcard-role { color: var(--accent); }
.pcard-tags li { background: var(--card-panel); }
:root[data-theme="dark"] .pcard-tags li { background: var(--card-panel); }
.pcard-more { background: var(--ink); color: var(--bg); }
:root[data-theme="dark"] .pcard-more { color: var(--bg); }

/* 프로젝트 카드 v3: 흰 카드 + 아키텍처 그림, 마우스를 올리면 맡은 일과 성과 */
.pcards { gap: 28px; }
.pcard {
  padding: 0; gap: 0; overflow: hidden; border-radius: 20px;
  background: var(--bg-elev); border: 1px solid var(--line);
  box-shadow: 0 1px 2px rgb(9 3 2 / .04), 0 12px 32px -20px rgb(9 3 2 / .25);
}
.pcard:hover { transform: translateY(-4px); box-shadow: 0 2px 4px rgb(9 3 2 / .05), 0 28px 50px -26px rgb(9 3 2 / .4); }
.pcard-media { position: relative; aspect-ratio: 16 / 9; background: #f0f0f0; border-bottom: 1px solid var(--line); overflow: hidden; }
.pcard-media > img { width: 100%; height: 100%; object-fit: contain; padding: 18px; background: #ffffff; transition: transform .4s ease, filter .3s; }
.pcard-hover {
  position: absolute; inset: 0; padding: 22px 26px; display: flex; flex-direction: column; justify-content: center; gap: 8px;
  background: rgb(255 255 255 / .96); opacity: 0; transform: translateY(8px); transition: opacity .25s ease, transform .25s ease;
}
:root[data-theme="dark"] .pcard-hover { background: rgb(17 17 17 / .95); }
.pcard:hover .pcard-hover, .pcard:focus-visible .pcard-hover { opacity: 1; transform: none; }
.pcard:hover .pcard-media > img { transform: scale(1.03); filter: blur(2px); }
.pcard-hk { margin: 0; font-size: 12px; font-weight: 800; letter-spacing: .04em; color: var(--ink-3); }
.pcard-hk + .pcard-role { margin-bottom: 8px; }
.pcard-hover .pcard-res { margin: 0; padding: 0; background: none; border-radius: 0; }
.pcard-hover .pcard-res li { padding: 9px 0; grid-template-columns: 7.6em minmax(0, 1fr); }
.pcard-hover .pcard-res b { font-size: 19px; }
.pcard-body { display: flex; flex-direction: column; gap: 12px; padding: 24px 28px 28px; flex: 1; }
.pcard-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.pcard-kind { padding: 0; background: none; font-size: 13px; color: var(--ink-3); }
.pcard h3 { margin: 0; font-size: 23px; }
.pcard-desc { font-size: 14.5px; }
.pcard-tags { margin-top: auto; padding-top: 6px; }
.pcard-tags li { background: var(--bg-sunk); color: var(--ink-2); }
:root[data-theme="dark"] .pcard-tags li { background: var(--bg-sunk); }
/* 자세히 보기: 오른쪽 위, 배경 없이 밑줄. 색은 팔레트 #7A9B76 */
.pcard-more {
  flex-shrink: 0; align-self: auto; margin: 0; padding: 0 0 1px; border-radius: 0; background: none;
  color: var(--accent); font-size: 13.5px; font-weight: 700; white-space: nowrap;
  text-decoration: underline; text-decoration-color: #7a9b76; text-decoration-thickness: 2px; text-underline-offset: 5px;
}
:root[data-theme="dark"] .pcard-more { color: var(--accent); background: none; }
.pcard-more::after { content: " →"; display: inline-block; transition: transform .2s; text-decoration: none; }
.pcard:hover .pcard-more { padding-right: 0; text-decoration: underline; text-decoration-color: #7a9b76; }
.pcard:hover .pcard-more::after { transform: translateX(3px); }
/* 마우스가 없는 기기: 그림 아래에 맡은 일과 성과를 그대로 보여 준다 */
@media (hover: none) {
  .pcard-media { aspect-ratio: auto; background: none; border-bottom: 0; }
  .pcard-media > img { aspect-ratio: 16 / 9; border-bottom: 1px solid var(--line); }
  .pcard-hover { position: static; opacity: 1; transform: none; background: none; padding: 20px 22px 0; }
  :root[data-theme="dark"] .pcard-hover { background: none; }
  .pcard:hover .pcard-media > img { transform: none; filter: none; }
}
@media (max-width: 640px) {
  .pcard-body { padding: 20px 22px 24px; }
  .pcard-top { flex-direction: column; align-items: flex-start; gap: 6px; }
  .pcard-hover .pcard-res li { grid-template-columns: 1fr; }
}
@media (max-width: 1300px) and (min-width: 961px) { .pcard-media { aspect-ratio: 16 / 10; } .pcard-hover { padding: 18px 22px; } }

/* 카드 색 나누기: 세이지 하나만 쓰지 않고 팔레트를 역할별로 */
:root { --mauve: #c8bfc7; --taupe: #8a7e72; }
:root[data-theme="dark"] { --mauve: #5e555d; --taupe: #a99d91; }
/* 그림 칸: 흰 그림이 옅은 회색 면 위에 떠 보이게 */
.pcard-media { background: #f6f5f6; }
.pcard-media > img { background: none; mix-blend-mode: multiply; padding: 22px 26px; }
:root[data-theme="dark"] .pcard-media { background: #ffffff; }
/* 구분 줄은 토프 */
.pcard-kind { color: var(--taupe); font-weight: 700; letter-spacing: .01em; }
/* 자세히 보기: 잉크 글자 + 모브 굵은 밑줄, 올리면 밑줄이 버건디로 */
.pcard-more {
  color: var(--ink); text-decoration-color: var(--mauve); text-decoration-thickness: 3px; text-underline-offset: 6px;
  transition: text-decoration-color .2s, color .2s;
}
:root[data-theme="dark"] .pcard-more { color: var(--ink); }
.pcard:hover .pcard-more { color: var(--brand); text-decoration-color: var(--brand); }
/* 마우스를 올렸을 때: 맡은 일은 모브 테두리 칩, 성과 값은 잉크, 설명은 토프 */
.pcard-hk { color: var(--taupe); }
.pcard-hover .pcard-role { gap: 6px; font-size: 13px; font-weight: 600; color: var(--ink); }
.pcard-hover .pcard-role li { padding: 3px 10px; border: 1px solid var(--mauve); border-radius: 999px; }
.pcard-hover .pcard-role li:not(:last-child)::after { content: none; }
.pcard-hover .pcard-res b { color: var(--ink); }
.pcard-hover .pcard-res span { color: var(--ink-2); }
.pcard-hover .pcard-res small { color: var(--taupe); }
.pcard-hover .pcard-res li + li { border-top-color: color-mix(in srgb, var(--mauve) 60%, transparent); }
/* 카드 테두리는 올렸을 때만 모브로 */
.pcard { transition: transform .25s ease, box-shadow .25s ease, border-color .25s; }
.pcard:hover { border-color: var(--mauve); }
/* 그림 칸 배경 없이 흰색 그대로 */
.pcard-media, :root[data-theme="dark"] .pcard-media { background: #ffffff; }
.pcard-media > img { mix-blend-mode: normal; background: none; }

/* 경력과 교육: 밝은 첫 화면 다음, 무게를 주는 어두운 띠. 팔레트 잉크에 세이지를 섞은 짙은 녹회색 */
#career {
  --ink: #f1efea; --ink-2: #c9c4bb; --ink-3: #9a948b; --line: rgb(255 255 255 / .12);
  --accent: #a9c4a4; --bg-sunk: rgb(255 255 255 / .07);
  background: #1e2620; color: var(--ink-2);
  margin-top: 72px; padding: 96px 0 88px;
}
#career .sec-no { color: #c8bfc7; }
#career .cv-date { color: #c8bfc7; }
#career .cv-link a { color: var(--accent); }
:root[data-theme="dark"] #career { background: #161c17; }
#career + .section { padding-top: 112px; }
@media (max-width: 640px) { #career { margin-top: 48px; padding: 64px 0 56px; } #career + .section { padding-top: 80px; } }
#career h2, #career h3, #career h4, #career b { color: var(--ink); }

/* ===== AI 개발: 두 번째 띠. 경력 띠(녹회색)와 다른 색, 팔레트 버건디 #5A2328을 잉크로 낮춘 짙은 와인 갈색 ===== */
#ai {
  --ink: #f4eeee; --ink-2: #d4c8c9; --ink-3: #a8999b; --line: rgb(255 255 255 / .13);
  --accent: #e3b8bc; --accent-soft: rgb(255 255 255 / .08); --bg-sunk: rgb(255 255 255 / .07);
  background: #2a1a1c; color: var(--ink-2);
  margin-top: 96px; padding: 96px 0 88px;
}
:root[data-theme="dark"] #ai { background: #1e1415; }
#ai h2, #ai h3, #ai b { color: var(--ink); }
#ai .sec-no { color: #c8bfc7; }
#ai + .section { padding-top: 112px; }
.ai-grid { gap: 28px; }
.ai { background: rgb(255 255 255 / .045); border: 0; border-radius: 18px; padding: 30px 32px; }
.ai-kind { color: #c8bfc7; letter-spacing: .02em; }
.ai-steps li::before { background: none; border: 1px solid var(--line); color: var(--ink); }
.ai-res { background: none; border-top: 1px solid var(--line); border-radius: 0; padding: 16px 0 0; color: var(--accent); font-size: 14.5px; }
@media (max-width: 640px) { #ai { margin-top: 56px; padding: 64px 0 56px; } .ai { padding: 22px 20px; } #ai + .section { padding-top: 80px; } }

/* ===== 개인 프로젝트: 테두리, 위쪽 띠, 녹색 바탕 상자 없애고 구분선과 여백으로 ===== */
.deep { border: 0; border-top: 0; border-radius: 0; background: none; padding: 0; }
.deep-grid { gap: 0; }
.deep + .deep { margin-top: 72px; padding-top: 64px; border-top: 1px solid var(--line); }
.deep-area { color: var(--taupe); letter-spacing: .02em; }
.deep h3 { font-size: 24px; }
.deep .dstats { gap: 32px; margin-top: 28px; }
.deep .dstats li { background: none; padding: 0; border-radius: 0; }
.deep .dstats .hl-big { font-size: 28px; color: var(--ink); }
.deep .dstats .hl-label { color: var(--ink-3); font-size: 13px; }
.deep .dstats .hl-from { color: var(--ink-3); font-size: 13px; }
.deep-body { margin-top: 24px; }
.deep-h::before { display: none; }
.deep-h { font-size: 13px; color: var(--ink-3); letter-spacing: .04em; }
.deep .bullets b { color: var(--ink); }
.deep-tech .layers { border: 0; border-radius: 0; }
.deep-tech .layers div { padding: 10px 0; border-top: 1px solid var(--line); }
.deep-tech .layers div:last-child { border-bottom: 1px solid var(--line); }
.deep-tech .layers dt { color: var(--taupe); }
@media (max-width: 640px) { .deep .dstats { gap: 16px; } .deep .dstats .hl-big { font-size: 22px; } }

/* ===== 기술: 칩 테두리 없이 첫 화면 칩과 같은 결 ===== */
.stack h3 { color: var(--taupe); }
.stack .tech > span { border: 0; background: var(--bg-sunk); border-radius: 999px; padding: 6px 13px 6px 10px; }
/* AI 띠 색 변경: 와인 갈색 대신 처음 제안하신 #4F7CAC를 낮춘 짙은 남색 */
#ai {
  --ink: #eef2f7; --ink-2: #c3ccd8; --ink-3: #8f9aab; --line: rgb(255 255 255 / .12);
  --accent: #a9c4e4; --bg-sunk: rgb(255 255 255 / .07);
  background: #1b2433;
}
:root[data-theme="dark"] #ai { background: #141b27; }
#ai .sec-no, .ai-kind { color: #a9c4e4; }

/* ===== 개인 프로젝트 v2: 읽는 순서대로 위에서 아래로. 머리 → 수치 → 한 일(두 단) → 기술 ===== */
.deep-head { max-width: none; }
.deep-top { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-bottom: 10px; }
.deep-top .deep-area { margin: 0; font-size: 13px; font-weight: 700; color: var(--taupe); letter-spacing: .02em; }
.deep-repo {
  flex-shrink: 0; font-size: 13.5px; font-weight: 700; color: var(--ink); text-decoration: underline;
  text-decoration-color: var(--mauve); text-decoration-thickness: 3px; text-underline-offset: 6px; transition: color .2s, text-decoration-color .2s;
}
.deep-repo::after { content: " ↗"; }
.deep-repo:hover { color: var(--brand); text-decoration-color: var(--brand); }
.deep h3 { margin: 0 0 8px; font-size: 26px; line-height: 1.35; letter-spacing: -0.02em; max-width: 30em; }
.deep-src { margin: 0 0 16px; font-size: 14px; color: var(--ink-3); }
.deep-desc { max-width: 44em; font-size: 16px; line-height: 1.8; color: var(--ink-2); }

/* 수치: 위아래 가는 선 사이에 큰 글자 */
.deep .dstats { margin-top: 32px; padding: 24px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); gap: 32px; }
.deep .dstats li { gap: 4px; }
.deep .dstats .hl-big { font-size: 26px; line-height: 1.25; }

/* 한 일: 두 단 격자, 항목 이름 위 · 설명 아래 */
.deep-body { display: block; margin-top: 36px; }
.deep-h { margin: 0 0 4px; font-size: 13px; font-weight: 700; color: var(--taupe); letter-spacing: .02em; }
.deep .bullets { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 48px; }
.deep .bullets li { display: block; padding: 18px 0; border-top: 0; border-bottom: 1px solid var(--line); }
.deep .bullets li:last-child { border-bottom: 1px solid var(--line); }
.deep .bullets b { display: block; margin-bottom: 6px; font-size: 16px; font-weight: 700; color: var(--ink); }
.deep .bullets span { display: block; font-size: 15px; line-height: 1.75; color: var(--ink-2); }
.deep .bullets strong { font-weight: 700; color: var(--ink); background: none; }

/* 기술: 맨 아래 한 덩어리, 분류 이름과 기술을 가로로 */
.deep-tech { margin-top: 32px; }
.deep-tech .layers { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px 48px; margin-top: 10px; }
.deep-tech .layers div { grid-template-columns: 5em minmax(0, 1fr); gap: 12px; padding: 0; border: 0 !important; font-size: 14.5px; }
.deep-tech .layers dt { color: var(--ink); font-weight: 700; }
.deep-tech .layers dd { color: var(--ink-2); }

@media (max-width: 900px) {
  .deep .bullets { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .deep h3 { font-size: 21px; }
  .deep-desc { font-size: 15px; }
  .deep .dstats { grid-template-columns: 1fr; gap: 16px; }
  .deep-tech .layers { grid-template-columns: 1fr; }
  .deep-tech .layers div { grid-template-columns: 1fr; gap: 2px; }
}
.deep-repo::after { display: inline-block; margin-left: 4px; text-decoration: none; }
.deep-tech .layers { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 48px; }
.deep-tech .layers div { grid-template-columns: 4.6em minmax(0, 1fr); }
@media (max-width: 900px) { .deep-tech .layers { grid-template-columns: 1fr; } }

/* 개인 프로젝트 카드 (메인) */
.dcards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }
.dcard {
  display: flex; flex-direction: column; gap: 12px; padding: 28px 30px 30px; border-radius: 20px;
  background: var(--bg-elev); border: 1px solid var(--line); color: var(--ink); text-decoration: none;
  box-shadow: 0 1px 2px rgb(9 3 2 / .04), 0 12px 32px -20px rgb(9 3 2 / .25);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s;
}
.dcard:hover { transform: translateY(-4px); border-color: var(--mauve); box-shadow: 0 2px 4px rgb(9 3 2 / .05), 0 28px 50px -26px rgb(9 3 2 / .4); }
.dcard:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.dcard-area { margin: 0; font-size: 13px; font-weight: 700; color: var(--taupe); letter-spacing: .02em; }
.dcard h3 { margin: 4px 0 0; font-size: 22px; line-height: 1.4; letter-spacing: -0.02em; }
.dcard-src { margin: -4px 0 0; font-size: 13.5px; color: var(--ink-3); }
.dcard-desc { margin: 0; font-size: 15px; line-height: 1.75; color: var(--ink-2); }
.dcard .dstats { margin: 6px 0 0; padding: 18px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); grid-template-columns: 1fr; gap: 12px; }
.dcard .dstats li { display: grid; grid-template-columns: 9em minmax(0, 1fr); column-gap: 16px; align-items: center; padding: 0; background: none; border-radius: 0; }
.dcard .dstats .hl-big { grid-row: span 2; font-size: 19px; margin: 0; color: var(--ink); white-space: nowrap; }
.dcard .dstats .hl-label { font-size: 13px; color: var(--ink-2); font-weight: 600; }
.dcard .dstats .hl-from { font-size: 12.5px; color: var(--ink-3); }
.dcard .pcard-tags { margin-top: auto; padding-top: 6px; }
.dcard .pcard-tags li { background: var(--bg-sunk); color: var(--ink-2); }
.dcard:hover .pcard-more { color: var(--brand); text-decoration-color: var(--brand); }
.dcard:hover .pcard-more::after { transform: translateX(3px); }
@media (max-width: 960px) { .dcards { grid-template-columns: 1fr; } }
@media (max-width: 640px) {
  .dcard { padding: 22px 20px 24px; }
  .dcard h3 { font-size: 19px; }
  .dcard .pcard-top { flex-direction: column; align-items: flex-start; gap: 6px; }
  .dcard .dstats li { grid-template-columns: 1fr; }
  .dcard .dstats .hl-big { grid-row: auto; }
}

/* 개인 프로젝트 상세 페이지 */
.project-page .deep .deep-title { margin: 0 0 10px; font-size: clamp(28px, 3.6vw, 38px); line-height: 1.3; letter-spacing: -0.025em; max-width: 24em; }
.dcard .dstats li { grid-template-columns: 8.5em minmax(0, 1fr); row-gap: 1px; }
.dcard .dstats .hl-big { grid-column: 1; grid-row: 1 / span 2; }
.dcard .dstats .hl-label, .dcard .dstats .hl-from { grid-column: 2; }
@media (max-width: 640px) { .dcard .dstats li { grid-template-columns: 1fr; } .dcard .dstats .hl-big, .dcard .dstats .hl-label, .dcard .dstats .hl-from { grid-column: 1; grid-row: auto; } .dcard .dstats .hl-label { order: -1; } }

/* 개인 프로젝트 카드 v2: 회사 프로젝트 카드와 다르게. 테두리 없는 옅은 면, 위에 큰 번호, 아래 오른쪽 + 버튼 */
.dcards { counter-reset: dc; }
.dcard {
  position: relative; counter-increment: dc; border: 0; background: #f6f5f4; box-shadow: none;
  padding: 30px 32px 30px; border-radius: 22px;
}
.dcard::before {
  content: "0" counter(dc); font-family: var(--mono); font-size: 13px; font-weight: 700; color: var(--taupe);
  letter-spacing: .04em;
}
.dcard:hover { transform: translateY(-4px); border-color: transparent; background: #f2f0ee; box-shadow: 0 24px 44px -28px rgb(9 3 2 / .35); }
:root[data-theme="dark"] .dcard { background: #1a1a1a; }
:root[data-theme="dark"] .dcard:hover { background: #1f1f1f; }
.dcard-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: -2px; }
.dcard-area { color: var(--ink-2); }
/* 펼쳐 보기: 테두리 알약, 테두리 색은 팔레트 세이지 #7A9B76 */
.dcard-open {
  display: inline-flex; align-items: center; gap: 6px; flex-shrink: 0;
  padding: 6px 12px 6px 14px; border: 1.5px solid #7a9b76; border-radius: 999px;
  font-size: 13px; font-weight: 700; color: var(--ink); transition: background .2s, color .2s, border-color .2s;
}
.dcard-open::after { content: "+"; font-size: 16px; line-height: 1; font-weight: 600; transition: transform .2s; }
.dcard:hover .dcard-open { background: #7a9b76; color: #ffffff; }
.dcard:hover .dcard-open::after { transform: rotate(90deg); }
.dcard .dstats { border-color: rgb(9 3 2 / .08); }
.dcard .pcard-tags li { background: #ffffff; }
:root[data-theme="dark"] .dcard .pcard-tags li { background: #262626; }
.dcards .dcard:first-child { position: relative; }
@media (max-width: 640px) { .dcard { padding: 22px 20px 24px; } }

/* 개인 프로젝트 모달 */
html.modal-open { overflow: hidden; }
.pmodal {
  width: min(1040px, calc(100vw - 48px)); max-width: none; max-height: calc(100vh - 64px);
  padding: 0; border: 0; border-radius: 22px; background: var(--bg-elev); color: var(--ink);
  box-shadow: 0 40px 100px -30px rgb(9 3 2 / .55); overflow: hidden;
}
.pmodal[open] { display: flex; flex-direction: column; animation: pm-in .28s ease; }
.pmodal::backdrop { background: rgb(9 3 2 / .55); backdrop-filter: blur(3px); }
@keyframes pm-in { from { opacity: 0; transform: translateY(16px) scale(.985); } to { opacity: 1; transform: none; } }
.pmodal-bar {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 14px 20px 14px 32px; border-bottom: 1px solid var(--line); background: var(--bg-elev);
}
.pmodal-name { font-size: 13.5px; font-weight: 700; color: var(--taupe); }
.pmodal-close {
  font: inherit; font-size: 13.5px; font-weight: 700; color: var(--ink); cursor: pointer;
  background: none; border: 1.5px solid var(--line); border-radius: 999px; padding: 6px 14px;
  transition: border-color .2s, color .2s;
}
.pmodal-close:hover { border-color: var(--brand); color: var(--brand); }
.pmodal-body { overflow-y: auto; padding: 32px 40px 44px; overscroll-behavior: contain; }
.pmodal .deep { transform: none; opacity: 1; }
.pmodal .deep .deep-title { margin: 0 0 10px; font-size: clamp(24px, 3vw, 32px); line-height: 1.3; letter-spacing: -0.025em; }
@media (prefers-reduced-motion: reduce) { .pmodal[open] { animation: none; } }
@media (max-width: 640px) {
  .pmodal { width: 100vw; max-height: 92vh; margin: auto 0 0; border-radius: 20px 20px 0 0; }
  .pmodal-bar { padding: 12px 14px 12px 20px; }
  .pmodal-body { padding: 22px 20px 32px; }
}
.dcard::before { content: none; }
.dcard-area::before { content: "0" counter(dc); margin-right: 10px; font-family: var(--mono); font-size: 13px; font-weight: 700; color: var(--taupe); }
.pmodal:focus, .pmodal:focus-visible { outline: none; }

/* 프로젝트 세 번째 카드: 두 칸을 다 쓰는 가로형 (그림 왼쪽, 내용 오른쪽) */
.pcard-wide { grid-column: 1 / -1; flex-direction: row; }
.pcard-wide .pcard-media { flex: 0 0 52%; aspect-ratio: auto; min-height: 340px; border-bottom: 0; border-right: 1px solid var(--line); }
.pcard-wide .pcard-body { justify-content: center; padding: 32px 36px; }
@media (max-width: 960px) {
  .pcard-wide { flex-direction: column; }
  .pcard-wide .pcard-media { flex: none; aspect-ratio: 16 / 9; min-height: 0; border-right: 0; border-bottom: 1px solid var(--line); }
}

/* ===== 개인 프로젝트 카드 v3: 한 줄에 하나, 왼쪽은 큰 번호와 소개, 오른쪽은 수치 패널 ===== */
.dcards { grid-template-columns: 1fr; gap: 24px; }
.dcard {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); column-gap: 48px; row-gap: 0;
  grid-template-rows: auto auto auto auto 1fr auto;
  grid-template-areas: "num stats" "area stats" "title stats" "src stats" "desc stats" "open tags";
  padding: 40px 44px; background: var(--bg-elev); border: 1px solid var(--line); border-radius: 24px; box-shadow: none;
}
.dcard:hover { background: var(--bg-elev); border-color: var(--mauve); box-shadow: 0 26px 50px -30px rgb(9 3 2 / .35); }
:root[data-theme="dark"] .dcard, :root[data-theme="dark"] .dcard:hover { background: var(--bg-elev); }
.dcard::before {
  content: "0" counter(dc); grid-area: num; font-family: var(--mono); font-size: 56px; font-weight: 700; line-height: 1;
  letter-spacing: -0.04em; color: var(--mauve); margin-bottom: 18px;
}
.dcard-area::before { content: none; }
.dcard-top { display: contents; }
.dcard-area { grid-area: area; margin: 0 0 8px; font-size: 13px; font-weight: 700; color: var(--taupe); }
.dcard h3 { grid-area: title; margin: 0 0 8px; font-size: 24px; line-height: 1.35; }
.dcard-src { grid-area: src; margin: 0 0 16px; }
.dcard-desc { grid-area: desc; font-size: 15.5px; }
.dcard-open { grid-area: open; justify-self: start; align-self: end; margin-top: 24px; padding: 9px 16px 9px 18px; font-size: 14px; }
.dcard .dstats {
  grid-area: stats; align-self: stretch; margin: 0; padding: 8px 26px; border: 0; border-radius: 18px;
  background: #f6f5f4; display: flex; flex-direction: column; justify-content: center; gap: 0;
}
:root[data-theme="dark"] .dcard .dstats { background: #1d1d1d; }
.dcard .dstats li { padding: 18px 0; grid-template-columns: 9.5em minmax(0, 1fr); }
.dcard .dstats li + li { border-top: 1px solid rgb(9 3 2 / .08); }
:root[data-theme="dark"] .dcard .dstats li + li { border-top-color: rgb(255 255 255 / .08); }
.dcard .dstats .hl-big { font-size: 24px; letter-spacing: -0.02em; }
.dcard .pcard-tags { grid-area: tags; align-self: end; margin-top: 20px; padding: 0; }
.dcard .pcard-tags li { background: var(--bg-sunk); }
@media (max-width: 960px) {
  .dcard {
    grid-template-columns: 1fr; grid-template-rows: none;
    grid-template-areas: "num" "area" "title" "src" "desc" "stats" "tags" "open";
    padding: 28px 24px;
  }
  .dcard::before { font-size: 40px; margin-bottom: 12px; }
  .dcard .dstats { margin-top: 20px; padding: 4px 18px; }
}
@media (max-width: 640px) {
  .dcard h3 { font-size: 20px; }
  .dcard .dstats li { grid-template-columns: 1fr; }
}

/* ===== 프로젝트 카드: 가로로 끌어서 넘기는 띠. 오른쪽은 화면 끝까지 이어지고 스크롤바는 숨김 ===== */
#work { overflow-x: clip; }
.pcards {
  display: flex; gap: 24px; overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory; scroll-behavior: smooth; scrollbar-width: none; -ms-overflow-style: none;
  margin-right: calc((100% - 100vw) / 2); padding: 10px calc((100vw - 100%) / 2) 30px 0;
  cursor: grab;
}
.pcards::-webkit-scrollbar { display: none; }
.pcards:focus-visible { outline: 2px solid var(--accent); outline-offset: 6px; border-radius: 12px; }
.pcards.dragging { cursor: grabbing; scroll-snap-type: none; scroll-behavior: auto; user-select: none; }
.pcards.dragging .pcard { pointer-events: none; }
.pcards > .pcard { flex: 0 0 min(540px, 84vw); scroll-snap-align: start; }
.pcards img { -webkit-user-drag: none; user-select: none; }
/* 세 번째 카드도 같은 모양으로 */
.pcard-wide { grid-column: auto; flex-direction: column; }
.pcard-wide .pcard-media { flex: none; aspect-ratio: 16 / 9; min-height: 0; border-right: 0; border-bottom: 1px solid var(--line); }
.pcard-wide .pcard-body { justify-content: flex-start; padding: 24px 28px 28px; }
@media (max-width: 1300px) and (min-width: 961px) { .pcard-wide .pcard-media { aspect-ratio: 16 / 10; } }
.pc-ctrl { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-top: 4px; }
.pc-hint { margin: 0; font-size: 13px; color: var(--ink-3); }
.pc-btns { display: flex; gap: 8px; }
.pc-btns button {
  width: 44px; height: 44px; border-radius: 50%; border: 1.5px solid var(--line); background: var(--bg-elev);
  color: var(--ink); font: inherit; font-size: 17px; cursor: pointer; transition: border-color .2s, color .2s, opacity .2s;
}
.pc-btns button:hover:not(:disabled) { border-color: #7a9b76; color: var(--accent); }
.pc-btns button:disabled { opacity: .35; cursor: default; }
@media (max-width: 640px) {
  .pcards { gap: 14px; }
  .pc-hint { font-size: 12.5px; }
}
@media (hover: none) { .pc-hint::after { content: ""; } }
@media (hover: none) {
  .pcards > .pcard .pcard-media { flex: none; aspect-ratio: auto; }
  .pcards > .pcard .pcard-media > img { height: auto; aspect-ratio: 16 / 9; }
}

/* 왼쪽도 화면 끝까지 이어지게: 넘긴 카드가 본문 왼쪽 선에서 잘리지 않고 화면 밖으로 빠져나감 */
.pcards {
  --gut: calc((100vw - 100%) / 2);
  margin-left: calc(var(--gut) * -1); margin-right: calc(var(--gut) * -1);
  padding-left: var(--gut); padding-right: var(--gut);
  scroll-padding-left: var(--gut);
}
.pcards {
  margin-left: calc(var(--gl, 16px) * -1); margin-right: calc(var(--gr, 16px) * -1);
  padding-left: var(--gl, 16px); padding-right: var(--gr, 16px);
  scroll-padding-left: var(--gl, 16px);
}

/* ===== 개인 프로젝트 모달 v2: 개요 → 어디까지 만들었나 → 풀어 본 문제 → 배운 점 ===== */
.pm { display: flex; flex-direction: column; gap: 44px; }
.pm-head { padding-bottom: 32px; border-bottom: 1px solid var(--line); }
.pm-top { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; }
.pm-links { display: flex; flex-wrap: wrap; gap: 6px 16px; justify-content: flex-end; min-width: 0; }
.pm-area { margin: 0; font-size: 13px; font-weight: 700; color: var(--taupe); }
.pm-title { margin: 10px 0 8px; font-size: clamp(22px, 2.4vw, 30px); line-height: 1.35; letter-spacing: -0.02em; text-wrap: balance; }
.pm-meta { margin: 0 0 18px; font-size: 14px; color: var(--ink-3); }
.pm-desc { margin: 0; max-width: none; font-size: 16px; line-height: 1.8; color: var(--ink-2); text-wrap: pretty; }
.pm-h { margin: 0 0 18px; font-size: 13px; font-weight: 700; letter-spacing: .02em; color: var(--accent); }
.pm-scope { margin: 0; display: grid; gap: 0; }
.pm-scope > div { display: grid; grid-template-columns: 7.5em minmax(0, 1fr); gap: 16px; padding: 12px 0; border-top: 1px solid var(--line); }
.pm-scope > div:last-child { border-bottom: 1px solid var(--line); }
.pm-scope dt { font-size: 14px; font-weight: 700; color: var(--ink); padding-top: 4px; }
.pm-scope dd { margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.pm-scope dd span { padding: 4px 11px; border-radius: 999px; background: var(--bg-sunk); font-size: 13.5px; color: var(--ink-2); }
.pm-note { margin: 16px 0 0; padding: 14px 18px; border-left: 3px solid var(--taupe); background: var(--bg-sunk); border-radius: 0 10px 10px 0; font-size: 14.5px; line-height: 1.7; color: var(--ink-2); }
.pm-note b { display: block; margin-bottom: 2px; color: var(--ink); font-size: 13px; }
.pm-sub { margin: 0 0 14px; font-size: 14.5px; line-height: 1.7; color: var(--ink-2); text-wrap: pretty; }
.pm-threat { margin: 0; }
.pm-threat td:first-child { width: 48%; }
.pm-case { padding: 26px 0; border-top: 1px solid var(--line); }
.pm-case:first-of-type { border-top: 0; padding-top: 4px; }
.pm-case h4 { display: flex; align-items: baseline; gap: 12px; margin: 0 0 16px; font-size: 18px; line-height: 1.45; }
.pm-no { font-family: var(--mono); font-size: 14px; color: var(--mauve); font-weight: 700; }
:root[data-theme="dark"] .pm-no { color: #a99aa6; }
.pm-flow { display: grid; grid-template-columns: 1fr 1fr 0.85fr; gap: 14px; }
.pm-flow > div { padding: 16px 18px; border-radius: 14px; background: var(--bg-sunk); }
.pm-flow p { margin: 0; font-size: 14.5px; line-height: 1.7; color: var(--ink-2); }
.pm-k { margin-bottom: 6px !important; font-size: 12.5px !important; font-weight: 700; color: var(--ink-3) !important; }
.pm-res { background: transparent !important; border: 1.5px solid #7a9b76; }
.pm-res .pm-k { color: var(--accent) !important; }
.pm-big { margin-bottom: 6px !important; font-size: 21px !important; font-weight: 800; line-height: 1.3 !important; color: var(--ink) !important; letter-spacing: -0.02em; }
.pm-learn ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.pm-learn li { padding: 20px 20px 22px; border-radius: 16px; background: #f6f5f4; border-top: 3px solid var(--mauve); }
:root[data-theme="dark"] .pm-learn li { background: #1d1d1d; }
.pm-learn b { display: block; margin-bottom: 8px; font-size: 15.5px; line-height: 1.5; color: var(--ink); }
.pm-learn p { margin: 0; font-size: 14px; line-height: 1.7; color: var(--ink-2); }
@media (max-width: 900px) {
  .pm-flow, .pm-learn ul { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .pm { gap: 36px; }
  .pm-scope > div { grid-template-columns: 1fr; gap: 8px; }
  .pm-case h4 { font-size: 16.5px; }
}

/* 모달 그림 */
.pm-fig { margin: 0; }
.pm-head + .pm-fig { margin-top: -12px; }
.pm-fig img { display: block; width: 100%; height: auto; padding: 16px; background: #fff; border: 1px solid var(--line); border-radius: 14px; cursor: zoom-in; }
.pm-fig figcaption { margin-top: 10px; font-size: 13.5px; line-height: 1.6; color: var(--ink-3); }
.pm-case > .pm-fig { margin-bottom: 16px; }
/* 세로로 긴 그림은 너무 커지지 않게, 두 장이면 나란히 */
.pm-fig-side { max-width: 560px; }
.pm-fig-side img { max-height: 520px; object-fit: contain; }
.pm-case:has(.pm-fig-side + .pm-fig-side) { display: grid; grid-template-columns: 1fr 1fr; column-gap: 16px; }
.pm-case:has(.pm-fig-side + .pm-fig-side) > h4, .pm-case:has(.pm-fig-side + .pm-fig-side) > .pm-flow { grid-column: 1 / -1; }
.pm-case:has(.pm-fig-side + .pm-fig-side) .pm-fig-side { max-width: none; }
@media (max-width: 640px) {
  .pm-fig img { padding: 8px; }
  .pm-case:has(.pm-fig-side + .pm-fig-side) { grid-template-columns: 1fr; }
}
/* 모달 그림 v2: .diagram 기본 테두리 제거, 세로 그림 하나면 그림 왼쪽 + 흐름 오른쪽 */
.pmodal figure.pm-fig { padding: 0; border: 0; background: none; box-shadow: none; }
.pm-case:has(> .pm-fig-side:only-of-type) { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: 20px; align-items: start; }
.pm-case:has(> .pm-fig-side:only-of-type) > h4 { grid-column: 1 / -1; }
.pm-case:has(> .pm-fig-side:only-of-type) > .pm-fig-side { max-width: none; margin: 0; }
.pm-case:has(> .pm-fig-side:only-of-type) > .pm-fig-side img { max-height: 560px; }
.pm-case:has(> .pm-fig-side:only-of-type) > .pm-flow { grid-template-columns: 1fr; gap: 10px; }
@media (max-width: 900px) {
  .pm-case:has(> .pm-fig-side:only-of-type) { grid-template-columns: 1fr; }
  .pm-case:has(> .pm-fig-side:only-of-type) > .pm-fig-side { margin-bottom: 16px; }
}
/* 배운 점: 배경과 상단 띠 없이 왼쪽 선만 */
.pm-learn li, :root[data-theme="dark"] .pm-learn li { padding: 2px 0 2px 18px; border-radius: 0; background: none; border-top: 0; border-left: 2px solid var(--mauve); }
.pm-learn ul { gap: 28px; }
@media (max-width: 900px) { .pm-learn ul { gap: 20px; } }
/* 모달 안 스레드 덤프 발췌 */
.pm-dump { margin: 0 0 16px; }
.pm-dump pre { margin: 0; padding: 18px 20px; overflow-x: auto; border-radius: 14px; background: #16181d; color: #d7dbe2; font-family: var(--mono); font-size: 12.5px; line-height: 1.75; }
.pm-dump code { font: inherit; white-space: pre; }
.pm-dump .c { color: #8b93a1; }
.pm-dump mark { background: rgb(219 120 120 / .22); color: #ffb4b4; padding: 0 2px; border-radius: 3px; }
.pm-dump figcaption { margin-top: 10px; font-size: 13.5px; line-height: 1.6; color: var(--ink-3); }
.pmodal .pm-dump pre code { background: none; padding: 0; border: 0; border-radius: 0; color: inherit; font-size: inherit; }

/* ===== 프로젝트 상세 머리 v2: 메타 칩 → 제목 → 소개 → 맡은 일 카드(영역별 열) → 기술, 저장소 → 주요 결과 ===== */
.project-page .case-head { display: block; margin-bottom: 0; }
.case-meta { list-style: none; margin: 0 0 16px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.case-meta li { padding: 5px 12px; border-radius: 999px; font-size: 13px; font-weight: 600; color: var(--ink-2); background: var(--bg-sunk); }
.case-meta li:first-child { background: none; border: 1.5px solid #7a9b76; color: var(--accent); }
.project-page .case-title { margin: 0 0 18px; font-size: clamp(30px, 4vw, 44px); line-height: 1.25; letter-spacing: -0.03em; text-wrap: balance; }
.project-page .case-desc { margin: 0; max-width: 46em; font-size: 17.5px; line-height: 1.85; color: var(--ink-2); text-wrap: pretty; }

.project-page .role { margin-top: 40px; padding: 28px 30px 26px; border: 1px solid var(--line); border-radius: 20px; background: var(--bg-elev); }
.project-page .role-h { margin: 0 0 18px; font-size: 13px; font-weight: 700; letter-spacing: .02em; color: var(--accent); }
.project-page .role dl { margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 0 28px; }
.project-page .role dl > div { display: block; padding: 0; border: 0; }
.project-page .role dl > div:not(.role-tech):not(.role-repo) { padding-bottom: 22px; }
.project-page .role dl > div:not(.role-tech):not(.role-repo) + div:not(.role-tech):not(.role-repo) { padding-left: 28px; margin-left: -28px; border-left: 1px solid var(--line); }
.project-page .role dt { margin: 0 0 10px; font-size: 15px; font-weight: 800; color: var(--ink); }
.project-page .role-list { display: block; margin: 0; padding: 0; list-style: none; }
.project-page .role-list li { position: relative; display: block; margin: 0; padding: 0 0 0 14px; font-size: 15px; line-height: 1.6; color: var(--ink-2); }
.project-page .role-list li + li { margin-top: 6px; }
.project-page .role-list li::before { content: ""; position: absolute; left: 0; top: .72em; width: 5px; height: 5px; border-radius: 50%; background: var(--sage); }
.project-page .role-list li::after { content: none; }
.project-page .role .role-tech, .project-page .role .role-repo { grid-column: 1 / -1; display: grid; grid-template-columns: 5.5em minmax(0, 1fr); align-items: start; gap: 12px; padding: 16px 0 0; border-top: 1px solid var(--line); }
.project-page .role .role-repo { margin-top: 14px; }
.project-page .role .role-tech dt, .project-page .role .role-repo dt { margin: 0; padding-top: 5px; font-size: 13px; font-weight: 700; color: var(--ink-3); }
.project-page .role .role-tech dd, .project-page .role .role-repo dd { margin: 0; }
.project-page .role-repo dd { display: flex; flex-wrap: wrap; gap: 6px 18px; padding-top: 4px; }
.project-page .role-note { margin: 14px 0 0; font-size: 13.5px; color: var(--ink-3); }

.project-page .hl { margin: 28px 0 48px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; padding: 0; border: 0; }
.project-page .hl li { margin: 0; padding: 0; border: 0; }
.project-page .hl a { display: flex; flex-direction: column; height: 100%; padding: 20px 20px 18px; border-radius: 16px; background: var(--bg-sunk); color: inherit; text-decoration: none; transition: background .2s, box-shadow .2s; }
.project-page .hl a:hover { background: var(--bg-elev); box-shadow: inset 0 0 0 1.5px #7a9b76; }
.project-page .hl .hl-label { order: 0; font-size: 13px; color: var(--ink-3); }
.project-page .hl .hl-big { order: 1; margin: 8px 0 6px; font-size: clamp(20px, 2vw, 26px); line-height: 1.25; font-weight: 800; letter-spacing: -0.02em; }
.project-page .hl .hl-from { order: 2; margin-top: auto; font-size: 13px; color: var(--ink-3); }
@media (max-width: 960px) { .project-page .hl { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) {
  .project-page .case-desc { font-size: 16px; }
  .project-page .role { padding: 22px 20px; }
  .project-page .role dl > div:not(.role-tech):not(.role-repo) + div:not(.role-tech):not(.role-repo) { padding-left: 0; margin-left: 0; border-left: 0; padding-top: 18px; border-top: 1px solid var(--line); }
  .project-page .role .role-tech, .project-page .role .role-repo { grid-template-columns: 1fr; gap: 8px; }
  .project-page .hl { gap: 8px; }
  .project-page .hl a { padding: 16px; }
}
.project-page .role .role-h { display: block; }
.project-page .role dl { display: flex; flex-wrap: wrap; gap: 0; }
.project-page .role dl > div:not(.role-tech):not(.role-repo) { flex: 1 1 220px; min-width: 0; padding-right: 24px; }
.project-page .role dl > div:not(.role-tech):not(.role-repo) + div:not(.role-tech):not(.role-repo) { margin-left: 0; padding-left: 24px; }
.project-page .role .role-tech, .project-page .role .role-repo { flex: 1 1 100%; }
@media (max-width: 640px) {
  .project-page .role dl > div:not(.role-tech):not(.role-repo) { flex-basis: 100%; padding-right: 0; }
  .project-page .role dl > div:not(.role-tech):not(.role-repo) + div:not(.role-tech):not(.role-repo) { padding-left: 0; }
}
.project-page .role .role-h { padding: 0; border: 0; margin: 0 0 18px; }
.project-page .role .role-h::before, .project-page .role .role-h::after { content: none; }
.project-page .role dl > div:not(.role-tech):not(.role-repo) { container-type: inline-size; }
@container (min-width: 440px) {
  .project-page .role-list:has(li:nth-child(6)) { columns: 2; column-gap: 24px; }
  .project-page .role-list:has(li:nth-child(6)) li { break-inside: avoid; margin: 0 0 6px; }
}

/* ===== 프로젝트 상세 GNB: 포트폴리오로 돌아가기 + 프로젝트 전환 + 읽기 진행 막대 ===== */
.nav-proj { position: sticky; }
.nav-proj .proj-nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.proj-nav a { padding: 7px 13px; border-radius: 999px; font-size: 14px; color: var(--ink-2); text-decoration: none; white-space: nowrap; transition: background .2s, color .2s; }
.proj-nav a:hover { color: var(--ink); background: var(--bg-sunk); }
.proj-nav a[aria-current="page"] { color: var(--ink); font-weight: 700; background: var(--bg-sunk); box-shadow: inset 0 0 0 1.5px #7a9b76; }
.proj-nav .pn-home { color: var(--ink-3); }
.pn-sep { width: 1px; height: 16px; margin: 0 8px; background: var(--line); }
.nav-progress { position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: #7a9b76; transform: scaleX(0); transform-origin: 0 50%; pointer-events: none; }
.project-page { padding-top: 56px; }
@media (max-width: 860px) {
  .nav-proj .nav-inner { flex-wrap: wrap; row-gap: 0; }
  .nav-proj .proj-nav { display: flex; order: 3; flex: 1 1 100%; margin: 0 -16px; padding: 4px 16px 10px; overflow-x: auto; scrollbar-width: none; }
  .nav-proj .proj-nav::-webkit-scrollbar { display: none; }
  .proj-nav a { font-size: 13.5px; padding: 6px 12px; }
}
@media (max-width: 860px) {
  .nav-proj .nav-inner { height: auto; min-height: 56px; padding-top: 10px; }
  .nav-proj .theme-toggle { margin-left: auto; }
  .nav-proj .proj-nav { margin-top: 6px; }
  html:has(.nav-proj) { scroll-padding-top: 116px; }
}
/* 지금 보는 프로젝트: 테두리, 배경, 굵기 없이 글자색과 아래 선만 */
.proj-nav a { position: relative; border-radius: 0; padding: 7px 4px; margin: 0 9px; }
.proj-nav a:hover { background: none; }
.proj-nav a[aria-current="page"] { font-weight: inherit; background: none; box-shadow: none; color: var(--accent); }
.proj-nav a[aria-current="page"]::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; border-radius: 2px; background: #7a9b76; }
/* 상세 페이지 소개: 폭 제한으로 생기던 어색한 줄바꿈 제거 */
.project-page .case-desc { max-width: none; text-wrap: wrap; }

/* 경력과 교육 띠: 어두운 배경 위 글자 대비와 크기 올림 */
#career { --ink-2: #e2ded6; --ink-3: #bdb7ad; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
#career li { font-size: 15.5px; line-height: 1.75; color: #e2ded6; }
#career li::marker, #career li::before { color: #a9c4a4; }
#career .cv-role { font-size: 15px; color: #c4beb4; }
#career small, #career .cv-h small { font-size: 14px; color: #bdb7ad; }
#career .cv-date { font-size: 14px; color: #ddd5dc; }
#career .job-k, #career .cv-len { font-size: 13.5px; color: #b9d4b4; }
#career span, #career em { color: #c4beb4; }
#career a { color: #bcd8b7; }

/* ===== 프로젝트 상세 정리 v3: 박스 줄이고 색 역할 나누기
   초록 = 결과와 현재 위치, 검정 = 제목과 수치, 회색 = 보조, 토프 = 그룹 라벨과 메타, 모브 = 번호와 장식 ===== */
/* 머리: 종류 칩 테두리 제거, 맡은 일은 선으로만 구분, 주요 결과는 세로선 4칸 */
.case-meta li:first-child { border: 0; background: var(--bg-sunk); color: var(--accent); }
.project-page .role { padding: 26px 0 24px; border: 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); border-radius: 0; background: none; }
.project-page .role .role-h { color: var(--taupe); }
.project-page .hl { gap: 0; margin: 8px 0 40px; }
.project-page .hl li + li { border-left: 1px solid var(--line); }
.project-page .hl a { padding: 22px 22px 20px; border-radius: 0; background: none; }
.project-page .hl li:first-child a { padding-left: 0; }
.project-page .hl a:hover { background: none; box-shadow: none; }
.project-page .hl a:hover .hl-big { color: var(--accent); }
@media (max-width: 960px) {
  .project-page .hl li:nth-child(3) { border-left: 0; }
  .project-page .hl li:nth-child(3) a { padding-left: 0; }
  .project-page .hl li:nth-child(n+3) { border-top: 1px solid var(--line); }
}
/* 구조도: 바깥 상자 제거, 설명과 안내 사이 간격 줄임 */
.project-page .case > .diagram, .project-page .case > figure.diagram { border: 0; padding: 0; background: none; }
.case > .page-sub { margin-top: 28px; }
/* 항목 목록: 제목이 먼저 읽히게, 결과 요약은 검정, 펼침 표시는 꺾쇠 */
.stories .group { color: var(--taupe); border-bottom-color: var(--line); }
.s-title { font-size: 17px; font-weight: 700; color: var(--ink); }
.s-res b { font-size: 15px; font-weight: 700; color: var(--ink-2); }
.stories summary { grid-template-columns: minmax(0, 1fr) minmax(170px, auto) 16px; }
.stories summary::before { content: none; }
.stories summary::after {
  content: ""; width: 9px; height: 9px; justify-self: center; margin-top: -4px;
  border-right: 2px solid var(--ink-3); border-bottom: 2px solid var(--ink-3); transform: rotate(45deg); transition: transform .2s;
}
.stories details[open] > summary::after { transform: rotate(-135deg); margin-top: 4px; }
.stories summary:hover { background: var(--bg-sunk); }
.stories details[open] { border-color: var(--line); box-shadow: 0 10px 30px -24px rgba(0,0,0,.3); }
/* 펼친 내용: 그림 바깥 상자 제거, 소제목 막대와 형광펜 제거, 초록은 결과 칸에만, 글 폭 760px */
.stories details[open] > .story { padding: 8px 28px 24px; }
.story .diagram { border: 0; padding: 0; background: none; max-width: none; margin: 8px 0 18px; }
.story h4 { font-size: 15px; color: var(--ink); }
.story h4::before { content: none; }
.story strong { background: none; font-weight: 700; color: var(--ink); }
.story > ul, .story > p, .story > h4, .story > .links { max-width: 760px; }
.story ul.res { max-width: none; }
/* 맨 아래 이전, 접기, 다음은 글자 링크로 */
.story-end { border-top: 1px solid var(--line); }
.story-end button { border: 0; background: none; padding: 6px 2px; color: var(--ink-3); }
.story-end button:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.story-end .next { color: var(--ink); }
@media (max-width: 640px) {
  .stories summary { grid-template-columns: minmax(0, 1fr) 16px; }
  .s-res { grid-column: 1; grid-row: 2; }
  .stories summary::after { grid-column: 2; grid-row: 1 / 3; }
  .s-title { font-size: 15.5px; }
  .stories details[open] > .story { padding: 6px 16px 20px; }
}

/* ===== 개인 프로젝트 모달 정리: 같은 색 역할 적용, 회색 상자 대신 세로선 ===== */
.pm-h { color: var(--taupe); }
.pm-flow { gap: 0; }
.pm-flow > div { padding: 2px 20px; border-radius: 0; background: none; border-left: 1px solid var(--line); }
.pm-flow > div:first-child { border-left: 0; padding-left: 0; }
.pm-res { border: 0 !important; border-left: 1px solid var(--line) !important; }
.pm-res .pm-k { color: var(--accent) !important; }
.pm-big { color: var(--accent) !important; }
.pm-note { background: none; border-left: 2px solid var(--taupe); border-radius: 0; padding: 4px 0 4px 18px; }
.pm-case:has(> .pm-fig-side:only-of-type) > .pm-flow > div { border-left: 0; padding: 0 0 14px; border-bottom: 1px solid var(--line); }
.pm-case:has(> .pm-fig-side:only-of-type) > .pm-flow > div:last-child { border-bottom: 0; }
.pm-case:has(> .pm-fig-side:only-of-type) > .pm-flow .pm-res { border-left: 0 !important; }
@media (max-width: 900px) {
  .pm-flow > div, .pm-res { border-left: 0 !important; padding: 0 0 14px !important; border-bottom: 1px solid var(--line); }
  .pm-flow > div:last-child { border-bottom: 0; }
}
.stories details[open] summary::before, .stories details summary::before { content: none; display: none; }
.story .diagram { max-width: 860px; margin-left: auto; margin-right: auto; }
.pmodal .pm-fig, .pmodal figure.diagram { border: 0 !important; padding: 0 !important; background: none !important; box-shadow: none !important; }
@media (max-width: 640px) { .s-res b, .stories details[open] > summary .s-res b { font-size: 13.5px; font-weight: 600; color: var(--ink-3); } }

/* 배운 점: 맨 아래 따로 모으지 않고 각 사례 끝에 붙임 */
.pm-lesson { margin-top: 20px; padding: 2px 0 2px 18px; border-left: 2px solid var(--mauve); }
.pm-lesson .pm-k { margin: 0 0 6px; color: var(--taupe); }
.pm-lesson ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.pm-lesson b { display: block; font-size: 15.5px; font-weight: 700; color: var(--ink); line-height: 1.5; }
.pm-lesson p:not(.pm-k) { margin: 4px 0 0; color: var(--ink-2); font-size: 14.5px; line-height: 1.7; max-width: 760px; }
.pmodal .pm-fig img { border: 0; border-radius: 0; }

/* 배운 점은 그림 옆 배치에서도 사례 폭 전체를 씀 */
.pm-case > .pm-lesson { grid-column: 1 / -1; }

/* 푸터: 페이지를 닫는 옅은 따뜻한 회색 띠 */
.footer { margin-top: 112px; border-top: 0; padding: 48px 0 60px; background: #f2efea; }
.footer-inner p { color: #6f675e; }
.footer-links a { color: #4a443d; }
.footer-links a:hover { color: var(--accent); }
:root[data-theme="dark"] .footer { background: #161513; }
:root[data-theme="dark"] .footer-inner p { color: #9a948b; }
:root[data-theme="dark"] .footer-links a { color: #c9c4bb; }

/* 푸터 v2: 경력 띠와 같은 계열의 짙은 녹회색으로 페이지를 닫음 */
.footer { margin-top: 112px; background: #1e2620; }
.footer-inner p { color: #b8b2a8; }
.footer-inner .prompt { color: #a9c4a4; }
.footer-links a { color: #e2ded6; }
.footer-links a:hover { color: #bcd8b7; }
.footer .copy { color: #9a948b; }
:root[data-theme="dark"] .footer { background: #151a16; border-top: 1px solid #232a24; }
:root[data-theme="dark"] .footer-inner p { color: #b8b2a8; }
:root[data-theme="dark"] .footer-links a { color: #e2ded6; }
/* 배운 점 글이 짧은 폭에서 끝 단어 하나만 넘어가지 않게 */
.pm-lesson p:not(.pm-k) { max-width: none; text-wrap: pretty; }
.pmodal .pm-flow p, .pmodal .pm-note { text-wrap: pretty; }

/* 푸터 v3: 강조색 세이지를 아주 옅게 깐 띠. 본문 흰색과 구분되면서 튀지 않게 */
.footer { margin-top: 112px; background: #eef2ec; border-top: 1px solid #dfe6dc; }
.footer-inner p { color: #5d6a5a; }
.footer-inner .prompt { color: var(--accent); }
.footer-links a { color: #2f3a2d; font-weight: 500; }
.footer-links a:hover { color: var(--accent); }
.footer .copy { color: #7d8a7a; }
:root[data-theme="dark"] .footer { background: #141a15; border-top: 1px solid #222b23; }
:root[data-theme="dark"] .footer-inner p { color: #9fae9b; }
:root[data-theme="dark"] .footer-inner .prompt { color: #a9c4a4; }
:root[data-theme="dark"] .footer-links a { color: #dfe6dc; }
:root[data-theme="dark"] .footer .copy { color: #7f8c7c; }

/* 푸터 v4: 대표색(버건디) 띠 */
.footer { background: #5a2328; border-top: 0; }
.footer-inner p { color: #e9d3d5; }
.footer-inner .prompt { color: #f3c9cd; }
.footer-links a { color: #ffffff; }
.footer-links a:hover { color: #f3c9cd; }
.footer .copy { color: #d2b0b3; }
:root[data-theme="dark"] .footer { background: #3d171b; border-top: 0; }
:root[data-theme="dark"] .footer-inner p { color: #e2c7ca; }
:root[data-theme="dark"] .footer-inner .prompt { color: #f3c9cd; }
:root[data-theme="dark"] .footer-links a { color: #ffffff; }
:root[data-theme="dark"] .footer .copy { color: #c9a5a9; }

/* 푸터 v5: 대표색(세이지 그린) 띠 */
.footer { background: #4c6b48; border-top: 0; }
.footer-inner p { color: #dde7da; }
.footer-inner .prompt { color: #c7dcc3; }
.footer-links a { color: #ffffff; }
.footer-links a:hover { color: #dbead7; }
.footer .copy { color: #c3d1c0; }
:root[data-theme="dark"] .footer { background: #2c3d2a; border-top: 0; }
:root[data-theme="dark"] .footer-inner p { color: #d3dfd0; }
:root[data-theme="dark"] .footer-inner .prompt { color: #c7dcc3; }
:root[data-theme="dark"] .footer-links a { color: #ffffff; }
:root[data-theme="dark"] .footer .copy { color: #a9baa6; }

/* ===== 프로젝트 정리 v4: 초록은 바뀐 결과 숫자와 현재 위치에만 ===== */
/* 메인 카드: 대표 결과 한 줄, 썸네일 낮춤, 기술은 글자 나열 */
.pcard-key { margin: 14px 0 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.pcard-key b { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; color: var(--ink-3); }
.pcard-key b s, .s-res b s { text-decoration: none; color: var(--ink-3); font-weight: 600; }
.pcard-key b em, .s-res b em { font-style: normal; color: var(--accent); }
.pcard-key span { font-size: 14px; color: var(--ink-3); }
.pcards > .pcard .pcard-media { max-height: 250px; }
.pcards > .pcard .pcard-media img { object-fit: contain; }
.pcard .pcard-tags { display: block; gap: 0; }
.pcard .pcard-tags li { display: inline; background: none; padding: 0; border: 0; font-size: 13.5px; color: var(--ink-3); }
.pcard .pcard-tags li + li::before { content: " · "; color: var(--line); }

/* 상세 머리: 개요 폭 760px, 주요 결과 숫자는 초록, 기술은 글자 나열 */
.project-page .case-desc { max-width: 760px; }
.project-page .hl { margin: 28px 0 8px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.project-page .hl .hl-big { color: var(--accent); }
.project-page .hl .hl-from { color: var(--ink-3); }
.project-page .role { border-top: 0; margin-top: 8px; }
.project-page .role .tags { display: block; }
.project-page .role .tags li { display: inline; background: none; border: 0; padding: 0; font-size: 14.5px; color: var(--ink-2); }
.project-page .role .tags li + li::before { content: " · "; color: var(--ink-3); }

/* 처리 흐름: 상자 세 겹을 걷어 내고 단계는 밑줄 탭, 설명은 글자만 */
.flow { border: 0; background: none; padding: 8px 0 0; border-radius: 0; }
.flow-steps { gap: 2px 14px; border-bottom: 1px solid var(--line); }
.flow-steps button { border: 0 !important; background: none !important; border-radius: 0 !important; padding: 8px 2px 10px !important; border-bottom: 2px solid transparent !important; margin-bottom: -1px; }
.flow-steps button.on { border-bottom-color: var(--accent) !important; }
.flow-cap p { background: none; padding: 4px 0 0; border-radius: 0; }

/* 항목 목록: 그룹 라벨을 뚜렷하게 */
.stories .group { font-size: 16px; font-weight: 800; color: var(--ink); border-bottom: 2px solid var(--ink); padding-bottom: 10px; margin-top: 48px; }
.s-res b { color: var(--ink); }

/* 펼친 내용: 소제목 키우고 결과 상자 안 강조는 굵은 검정 */
.story h4 { font-size: 16.5px; margin-top: 34px; }
.story ul.res strong { color: var(--ink); }

/* 떠 있는 목차 버튼: 작게, 오른쪽 아래로 */
@media (max-width: 1539px) {
  .toc-btn { left: auto; right: 16px; bottom: 16px; font-size: 12.5px; padding: 7px 12px; max-width: min(280px, calc(100vw - 32px)); }
  .toc { left: auto; right: 16px; }
}

/* ===== 프로젝트 본문 v5: 왼쪽 제목은 가볍게, 오른쪽 성과를 크게. 본문 강조는 초록 밑줄 ===== */
.s-title { font-size: 15.5px; font-weight: 600; color: var(--ink-2); }
.stories summary:hover .s-title, .stories details[open] > summary .s-title { color: var(--ink); }
.s-res b { font-size: 18px; font-weight: 800; color: var(--ink); letter-spacing: -0.02em; }
.s-res b s, .s-res b em { color: inherit; font-weight: inherit; font-style: normal; }
.s-res small { font-size: 12.5px; color: var(--ink-3); }
.stories .group { font-size: 15px; font-weight: 700; border-bottom-width: 1px; }
.story h4 { font-size: 16px; font-weight: 700; }
.story strong { font-weight: 600; color: var(--ink); background: linear-gradient(transparent 64%, color-mix(in srgb, var(--accent) 24%, transparent) 64%); }
.story ul.res strong { background: linear-gradient(transparent 64%, color-mix(in srgb, var(--accent) 28%, transparent) 64%); }
@media (max-width: 640px) {
  .s-title { font-size: 15px; }
  .s-res b, .stories details[open] > summary .s-res b { font-size: 15px; font-weight: 800; color: var(--ink); }
}
.story ul.res strong { background: linear-gradient(transparent 62%, color-mix(in srgb, var(--accent) 42%, transparent) 62%); }
.story > ul, .story > p { max-width: 860px; text-wrap: pretty; }
/* 개요는 폭 제한 없이 이어서 씀 (짧은 개요가 한 단어만 넘어가지 않게) */
.project-page .case-desc { max-width: none; text-wrap: wrap; }

/* 본문 줄바꿈: 폭 제한과 pretty 줄맞춤을 풀어 글이 칸 끝까지 이어지게 */
.story > ul, .story > p, .story > h4, .story > .links, .story li, .story p { max-width: none; text-wrap: wrap; }
.role dd, .pm-desc, .pmodal .pm-flow p, .pmodal .pm-note, .pm-lesson p:not(.pm-k) { max-width: none; text-wrap: wrap; }
/* 폭 제한은 풀고, 마지막 줄에 한 단어만 남는 것은 pretty로 막음 */
.story li, .story p, .role dd, .pm-desc, .pmodal .pm-flow p, .pmodal .pm-note, .pm-lesson p:not(.pm-k), .project-page .case-desc { text-wrap: pretty; }

/* ===== 상세 개요 v3: 선과 상자를 걷어 내고 "주요 성과 → 맡은 일" 두 덩어리로 ===== */
.project-page .ov .case-meta { display: block; margin: 0 0 14px; padding: 0; }
.project-page .ov .case-meta li { display: inline; padding: 0; border: 0; background: none; border-radius: 0; font-size: 14px; font-weight: 500; color: var(--ink-3); }
.project-page .ov .case-meta li:first-child { color: var(--accent); font-weight: 700; }
.project-page .ov .case-meta li + li::before { content: "·"; margin: 0 8px; color: var(--ink-3); }
.project-page .ov .case-desc { margin: 0 0 48px; font-size: 17px; line-height: 1.85; color: var(--ink-2); }
.project-page .ov .ov-h, .project-page .ov .role .role-h {
  margin: 0 0 16px; padding: 0; border: 0; font-size: 13.5px; font-weight: 700; letter-spacing: .02em; color: var(--ink-3);
}
/* 주요 성과: 선 없이 넓은 간격의 4칸 */
.project-page .ov .hl { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px 36px; margin: 0 0 52px; padding: 0; border: 0; }
.project-page .ov .hl li, .project-page .ov .hl li + li { border: 0; padding: 0; margin: 0; }
.project-page .ov .hl a, .project-page .ov .hl li:first-child a { padding: 0; background: none; border-radius: 0; box-shadow: none; }
.project-page .ov .hl .hl-label { font-size: 14px; color: var(--ink-2); font-weight: 500; }
.project-page .ov .hl .hl-big { margin: 6px 0 4px; font-size: clamp(22px, 2.1vw, 27px); font-weight: 800; color: var(--accent); }
.project-page .ov .hl .hl-from { margin-top: 0; font-size: 13.5px; color: var(--ink-3); }
.project-page .ov .hl a:hover .hl-label { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
/* 맡은 일: 왼쪽 분류, 오른쪽 한 줄 나열. 선, 점, 다단 없음 */
.project-page .ov .role { margin: 0; padding: 0; border: 0; background: none; }
.project-page .ov .role dl { display: block; margin: 0; }
.project-page .ov .role dl > div, .project-page .ov .role dl > div + div,
.project-page .ov .role dl > div:not(.role-tech):not(.role-repo) + div:not(.role-tech):not(.role-repo) {
  display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: 20px; margin: 0; padding: 7px 0; border: 0; container-type: normal;
}
.project-page .ov .role dt { margin: 0; padding: 0; font-size: 15px; font-weight: 700; color: var(--ink); line-height: 1.75; }
.project-page .ov .role dd { margin: 0; }
.project-page .ov .role-list, .project-page .ov .role-list:has(li:nth-child(6)) { display: block; columns: auto; margin: 0; padding: 0; }
.project-page .ov .role-list li, .project-page .ov .role-list:has(li:nth-child(6)) li { display: inline; margin: 0; padding: 0; font-size: 15.5px; line-height: 1.75; color: var(--ink-2); }
.project-page .ov .role-list li::before { content: none; }
.project-page .ov .role-list li + li::before { content: "·"; position: static; display: inline; width: auto; height: auto; background: none; margin: 0 9px; color: var(--ink-3); }
.project-page .ov .role .role-tech { margin-top: 18px; }
.project-page .ov .role .role-tech dt, .project-page .ov .role .role-repo dt { padding: 0; font-size: 14px; font-weight: 600; color: var(--ink-3); }
.project-page .ov .role .tags li { font-size: 14.5px; color: var(--ink-3); line-height: 1.75; }
.project-page .ov .role-repo dd { padding: 0; gap: 4px 18px; }
.project-page .ov .role-note { margin: 10px 0 0 108px; font-size: 13.5px; color: var(--ink-3); }
@media (max-width: 960px) { .project-page .ov .hl { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) {
  .project-page .ov .role dl > div, .project-page .ov .role dl > div + div,
  .project-page .ov .role dl > div:not(.role-tech):not(.role-repo) + div:not(.role-tech):not(.role-repo) { grid-template-columns: 1fr; gap: 2px; padding: 8px 0; }
  .project-page .ov .role-note { margin-left: 0; }
}
/* 개요 아래 구조도와는 간격으로만 나눔 */
.project-page .case > .diagram.arch { margin-top: 64px; }
.diagram.arch.arch-sm img { width: 56%; }
@media (max-width: 900px) { .diagram.arch.arch-sm img { width: 100%; } }

/* NOVA 흐름 애니메이션: 접어 두고 원할 때 펼쳐 봄 */
.flow-toggle { margin: 20px 0 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.flow-toggle > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 14px; padding: 16px 2px; }
.flow-toggle > summary::-webkit-details-marker { display: none; }
.flow-toggle .ft-t { font-size: 15.5px; font-weight: 600; color: var(--ink); }
.flow-toggle .ft-a { margin-left: auto; font-size: 14px; font-weight: 600; color: var(--accent); }
.flow-toggle .ft-a::before { content: "▶ "; font-size: 11px; }
.flow-toggle[open] .ft-a::before { content: ""; }
.flow-toggle[open] .ft-a { color: var(--ink-3); }
.flow-toggle[open] .ft-a { font-size: 0; }
.flow-toggle[open] .ft-a::after { content: "접기"; font-size: 14px; }
.flow-toggle > summary:hover .ft-t { text-decoration: underline; text-underline-offset: 4px; }
.flow-toggle .flow { margin: 0 0 18px; }
.flow-toggle .flow-title { display: none; }
.flow-toggle .flow-head { justify-content: flex-end; margin-bottom: 4px; }
/* 나열 항목은 한 덩어리로 줄바꿈하고 가운뎃점은 앞 항목 끝에 붙임 */
.project-page .ov .role-list li, .project-page .ov .role .tags li { white-space: nowrap; }
.project-page .ov .role-list li + li::before, .project-page .ov .role .tags li + li::before { content: none; }
.project-page .ov .role-list li:not(:last-child)::after { content: "·"; margin: 0 9px; color: var(--ink-3); }
.project-page .ov .role .tags li:not(:last-child)::after { content: "·"; margin: 0 7px; color: var(--ink-3); }
.project-page .ov .role-list li:not(:last-child), .project-page .ov .role .tags li:not(:last-child) { white-space: nowrap; }
.project-page .ov .role-list, .project-page .ov .role .tags { white-space: normal; }
@media (max-width: 640px) {
  .project-page .ov .role-list li, .project-page .ov .role-list li:not(:last-child),
  .project-page .ov .role .tags li, .project-page .ov .role .tags li:not(:last-child) { white-space: normal; }
}

/* 푸터 v6: 경력과 교육 띠와 같은 짙은 녹회색 */
.footer { background: #1e2620; border-top: 0; }
.footer-inner p { color: #c9c4bb; }
.footer-inner .prompt { color: #a9c4a4; }
.footer-links a { color: #f1efea; }
.footer-links a:hover { color: #a9c4a4; }
.footer .copy { color: #9a948b; }
:root[data-theme="dark"] .footer { background: #161c17; border-top: 0; }
:root[data-theme="dark"] .footer-inner p { color: #c9c4bb; }
:root[data-theme="dark"] .footer-inner .prompt { color: #a9c4a4; }
:root[data-theme="dark"] .footer-links a { color: #f1efea; }
:root[data-theme="dark"] .footer .copy { color: #9a948b; }

/* 메인 카드 링크 밑줄과 모달 배운 점 선은 포인트 컬러(버건디) */
.pcard-more, .deep-repo { text-decoration-color: color-mix(in srgb, var(--brand) 45%, transparent); }
.pcard:hover .pcard-more, .dcard:hover .pcard-more, .deep-repo:hover { text-decoration-color: var(--brand); }
.pm-learn li, .pm-lesson { border-left-color: color-mix(in srgb, var(--brand) 55%, transparent); }


/* 상세: 초록 = 성과와 구획 이름 */
.s-res b, .stories details[open] > summary .s-res b { color: var(--accent); }
.project-page .ov .ov-h, .project-page .ov .role .role-h { color: var(--accent); }
.story h4:has(+ ul.res) { color: var(--accent); }
@media (max-width: 640px) { .s-res b, .stories details[open] > summary .s-res b { color: var(--accent); } }

/* 어두운 테마의 프로젝트 상세에서만 초록 대신 버건디 계열 */
:root[data-theme="dark"]:has(.nav-proj) {
  --accent: #d9969c; --accent-soft: #2a1a1c; --sage: #d9969c;
}
:root[data-theme="dark"]:has(.nav-proj) .proj-nav a[aria-current="page"]::after,
:root[data-theme="dark"]:has(.nav-proj) .nav-progress { background: #d9969c; }

/* 잠시 숨긴 항목: display를 정한 규칙보다 우선 */
[hidden] { display: none !important; }
@media (min-width: 961px) { .project-page .ov .hl:has(> li[hidden]) { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* 사례 본문이 여러 문단일 때와 문제, 한 일, 결과 사이에 숨 쉴 여백 */
.pm-flow p:not(.pm-k):not(.pm-big) + p { margin-top: 1.7em; }
.pm-flow .pm-k { margin-bottom: 6px; }
.pm-case:has(> .pm-fig-side:only-of-type) > .pm-flow > div { padding-bottom: 20px; }
.pm-case:has(> .pm-fig-side:only-of-type) > .pm-flow > div + div { padding-top: 18px; }
@media (max-width: 900px) {
  .pm-flow > div, .pm-res { padding-bottom: 16px !important; }
  .pm-flow > div + div { padding-top: 14px !important; }
}

/* 프로젝트 발표 자료와 시연 영상 미리보기 */
.decks { list-style: none; margin: 4px 0 26px; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.decks a { display: flex; flex-direction: column; gap: 4px; color: inherit; text-decoration: none; }
.deck-thumb { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: var(--bg-sunk); margin-bottom: 8px; transition: border-color .15s ease, transform .15s ease; }
.deck-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.deck-video::after { content: ""; position: absolute; left: 50%; top: 50%; width: 52px; height: 52px; margin: -26px 0 0 -26px; border-radius: 50%; background: rgb(0 0 0 / 0.62) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='white' d='M9 7l9 5-9 5z'/%3E%3C/svg%3E") center / 26px no-repeat; }
.decks a:hover .deck-thumb { border-color: var(--accent); transform: translateY(-2px); }
.deck-k { font-size: 12.5px; color: var(--ink-3); }
.deck-t { font-size: 15px; font-weight: 600; color: var(--ink); line-height: 1.4; }
.decks a:hover .deck-t { color: var(--accent); }
@media (max-width: 640px) {
  .decks { grid-template-columns: 1fr; gap: 18px; }
}
