/* CHROMETI Journal — 공통 스타일
   레이아웃: 좁은 본문 칼럼 + 넓은 인포그래픽, 차분한 징크 톤에 브랜드 색 하나만 포인트로 */
:root {
  --font: "Geist", "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
  --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  /* AIOudit 스킨 (밝음) */
  --bg: #FAFAFA;
  --surface: #FFFFFF;
  --raised: #F4F4F5;
  --line: #E4E4E7;
  --ink: #111113;
  --body: #3F3F46;
  --muted: #71717A;
  --accent: #2F5BEA;
  --accent-text: #2F5BEA;
  --accent-wash: #EEF2FD;
  --button-bg: #111113;
  --button-ink: #FFFFFF;
  --invert-bg: #111113;
  --invert-ink: #F4F4F5;
  --invert-body: #D4D4D8;
  --shadow: 0 1px 2px rgba(17,17,19,.04), 0 12px 32px rgba(17,17,19,.06);
  --radius: 14px;
  color-scheme: light;
}
:root[data-skin="dark"] {
  /* VIDEOudit 스킨 (어두움) */
  --bg: #0F0F0F;
  --surface: #161616;
  --raised: #1D1D1D;
  --line: #2A2A2A;
  --ink: #F1F1F1;
  --body: #D2D2D2;
  --muted: #A0A0A0;
  --accent: #FF3030;
  --accent-text: #FF5A5A;
  --accent-wash: rgba(255, 48, 48, .10);
  --button-bg: #E5252A;
  --button-ink: #FFFFFF;
  --invert-bg: #F1F1F1;
  --invert-ink: #111113;
  --invert-body: #3F3F46;
  --shadow: 0 1px 0 rgba(255,255,255,.03);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--body);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.75;
  word-break: keep-all;
  overflow-wrap: anywhere;
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; height: auto; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.skip { position: absolute; left: -999px; top: 8px; background: var(--surface); padding: 8px 12px; z-index: 20; }
.skip:focus { left: 16px; }

.wrap {
  width: 100%;
  max-width: 1120px;
  margin-inline: auto;
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
}
.wrap.narrow { max-width: 760px; }

.eyebrow {
  margin: 0;
  font-family: var(--mono);
  font-size: 12.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent-text);
}

/* 헤더 */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 60px; }
.wordmark { display: inline-flex; align-items: baseline; text-decoration: none; font-weight: 700; font-size: 20px; letter-spacing: -.02em; color: var(--ink); }
.wm-a { color: var(--accent); }
.wm-c { margin-left: 10px; font-family: var(--mono); font-weight: 500; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.nav { display: flex; align-items: center; gap: 4px; font-size: 14.5px; }
.nav a { text-decoration: none; color: var(--body); padding: 8px 12px; border-radius: 8px; }
.nav a:hover { color: var(--ink); background: var(--raised); }
.nav .nav-cta { color: var(--button-ink); background: var(--button-bg); font-weight: 500; }
.nav .nav-cta:hover { color: var(--button-ink); background: var(--button-bg); opacity: .9; }

/* 홈 */
.hero { padding-block: 88px 56px; display: flex; flex-direction: column; gap: 20px; }
.hero-title {
  margin: 0; color: var(--ink);
  font-size: clamp(34px, 5.4vw, 60px); line-height: 1.16; font-weight: 600; letter-spacing: -.035em;
  text-wrap: balance; max-width: 18ch;
}
.hero-sub { margin: 0; max-width: 46ch; font-size: 18px; color: var(--muted); }

.list-section { padding-bottom: 24px; }
.list-head { display: flex; align-items: baseline; justify-content: space-between; border-bottom: 1px solid var(--ink); padding-bottom: 12px; }
.section-title { margin: 0; font-size: 15px; font-weight: 600; color: var(--ink); letter-spacing: -.01em; }
.list-count { margin: 0; font-family: var(--mono); font-size: 13px; color: var(--muted); }
.post-list { list-style: none; margin: 0; padding: 0; }
.post-row a {
  display: grid; grid-template-columns: 156px minmax(0, 1fr) 24px; gap: 24px; align-items: start;
  padding-block: 28px; border-bottom: 1px solid var(--line); text-decoration: none;
}
.row-date { white-space: nowrap; font-family: var(--mono); font-size: 13px; color: var(--muted); padding-top: 4px; font-variant-numeric: tabular-nums; }
.row-main { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.row-cat { font-family: var(--mono); font-size: 12px; letter-spacing: .08em; color: var(--accent-text); text-transform: uppercase; }
.row-title { font-size: 23px; font-weight: 600; letter-spacing: -.02em; line-height: 1.35; color: var(--ink); text-wrap: balance; }
.row-desc { font-size: 16px; color: var(--muted); line-height: 1.6; max-width: 62ch; }
.row-arrow { color: var(--muted); padding-top: 4px; transition: transform .2s; }
.post-row a:hover .row-title { color: var(--accent-text); }
.post-row a:hover .row-arrow { transform: translateX(4px); color: var(--accent-text); }

/* 글 */
.post { padding-bottom: 32px; }
.post-head { padding-block: 64px 32px; display: flex; flex-direction: column; gap: 16px; }
.crumb { font-size: 14px; color: var(--muted); text-decoration: none; }
.crumb:hover { color: var(--ink); }
.post-title { margin: 0; color: var(--ink); font-size: clamp(30px, 4.4vw, 46px); line-height: 1.22; font-weight: 600; letter-spacing: -.03em; text-wrap: balance; }
.post-lead { margin: 0; font-size: 19px; line-height: 1.7; color: var(--body); }
.post-meta { margin: 8px 0 0; display: flex; flex-wrap: wrap; gap: 6px 18px; font-family: var(--mono); font-size: 12.5px; color: var(--muted); padding-top: 18px; border-top: 1px solid var(--line); }

.prose { display: flex; flex-direction: column; gap: 22px; }
.prose > * { margin: 0; }
.prose h2 { margin-top: 28px; color: var(--ink); font-size: 26px; line-height: 1.35; font-weight: 600; letter-spacing: -.02em; text-wrap: balance; }
.prose h3 { margin-top: 8px; color: var(--ink); font-size: 19px; font-weight: 600; }
.prose a { color: var(--accent-text); text-underline-offset: 3px; }
.prose strong { color: var(--ink); font-weight: 600; }
.prose ul, .prose ol { padding-left: 1.3em; display: flex; flex-direction: column; gap: 8px; }
.prose blockquote { border-left: 2px solid var(--accent); padding: 4px 0 4px 20px; color: var(--ink); font-size: 18px; }

.note {
  background: var(--raised); border-radius: var(--radius); padding: 20px 24px; font-size: 15.5px; color: var(--body);
}
.note b { color: var(--ink); }

/* 인포그래픽 */
.figure { margin: 12px 0; display: flex; flex-direction: column; gap: 12px; }
.figure-frame {
  background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 28px; box-shadow: var(--shadow);
  overflow-x: auto;
}
.figure figcaption { font-size: 13.5px; color: var(--muted); }
.figure figcaption b { color: var(--body); font-weight: 600; }

.compare { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.compare-col { display: flex; flex-direction: column; gap: 14px; border-radius: 14px; padding: 20px; background: var(--raised); min-width: 0; }
.compare-col.is-clean { background: var(--accent-wash); }
.compare-label { font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.compare-col.is-clean .compare-label { color: var(--accent-text); }
.compare-title { font-size: 18px; font-weight: 600; color: var(--ink); line-height: 1.4; }
.bubble { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; font-size: 15px; line-height: 1.6; display: flex; flex-direction: column; gap: 8px; }
.bar { height: 8px; border-radius: 4px; background: var(--line); }
.bar.w80 { width: 80%; } .bar.w60 { width: 60%; } .bar.w70 { width: 70%; }
.hl { display: inline-block; width: fit-content; padding: 2px 10px; border-radius: 6px; font-weight: 600; font-size: 14px; }
.hl-warn { background: #FDECEC; color: #B42318; }
.hl-ok { background: var(--accent-wash); color: var(--accent-text); border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); }
:root[data-skin="dark"] .hl-warn { background: rgba(240,104,60,.15); color: #F7A27F; }
.compare-foot { font-size: 14px; color: var(--muted); line-height: 1.55; }

.steps { list-style: none; padding: 0 !important; display: grid !important; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px !important; }
.steps li { background: var(--raised); border-radius: 14px; padding: 18px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.step-no { font-family: var(--mono); font-size: 12px; color: var(--accent-text); letter-spacing: .08em; }
.step-title { font-weight: 600; color: var(--ink); font-size: 16px; line-height: 1.45; }
.step-body { font-size: 14.5px; color: var(--muted); line-height: 1.6; }

.flow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; align-items: stretch; }
.flow-item { position: relative; background: var(--raised); border-radius: 14px; padding: 18px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.flow-item.is-out { background: var(--invert-bg); }
.flow-item.is-out .step-title { color: var(--invert-ink); }
.flow-item.is-out .step-body { color: var(--invert-body); }
.flow-item.is-out .step-no { color: var(--accent-text); }

/* 출처 */
.sources { border-top: 1px solid var(--line); padding-top: 20px; font-size: 14.5px; }
.sources h2 { margin-top: 0 !important; font-size: 15px !important; }
.sources ol { gap: 6px !important; color: var(--muted); }
.sources a { color: var(--body); }

/* CTA */
.cta {
  margin-block: 48px 16px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
  background: var(--invert-bg); color: var(--invert-body); border-radius: 20px; padding: 32px 36px;
}
.cta > div { display: flex; flex-direction: column; gap: 8px; min-width: 0; flex: 1 1 320px; }
.cta-title { margin: 0; color: var(--invert-ink); font-size: 22px; line-height: 1.4; font-weight: 600; letter-spacing: -.02em; }
.cta-body { margin: 0; font-size: 15.5px; color: var(--invert-body); }
.cta .eyebrow { color: var(--accent-text); }
:root:not([data-skin="dark"]) .cta .eyebrow { color: #8FA8F7; }
.button {
  display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 0 22px; border-radius: 10px;
  background: var(--accent); color: #FFFFFF; font-weight: 600; font-size: 15px; text-decoration: none; white-space: nowrap;
}
:root[data-skin="dark"] .button { background: var(--button-bg); }
.button:hover { filter: brightness(1.08); }
.hero .button { background: var(--button-bg); color: var(--button-ink); }

/* 푸터 */
.site-footer { margin-top: 72px; border-top: 1px solid var(--line); background: var(--surface); }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.4fr) minmax(0, .7fr); gap: 32px; padding-block: 44px 28px; }
.footer-brand { display: flex; flex-direction: column; gap: 10px; }
.footer-note { margin: 0; font-size: 14.5px; color: var(--muted); max-width: 32ch; }
.family { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.family-card { display: flex; flex-direction: column; gap: 4px; padding: 16px 18px; border-radius: 12px; text-decoration: none; border: 1px solid var(--line); background: var(--bg); }
.family-card:hover { border-color: var(--muted); }
.fam-name { font-weight: 700; font-size: 17px; color: var(--ink); letter-spacing: -.02em; }
.fam-aio b { color: #2F5BEA; }
.fam-vid b { color: #E5252A; }
:root[data-skin="dark"] .fam-aio b { color: #7C9BF5; }
:root[data-skin="dark"] .fam-vid b { color: #FF5A5A; }
.fam-desc { font-size: 13.5px; color: var(--muted); }
.footer-links { display: flex; flex-direction: column; gap: 8px; font-size: 14.5px; }
.footer-links a { color: var(--body); text-decoration: none; }
.footer-links a:hover { color: var(--ink); }
.footer-base { padding-block: 16px 32px; border-top: 1px solid var(--line); }
.footer-base p { margin: 0; font-size: 12.5px; color: var(--muted); }

@media (max-width: 760px) {
  .hero { padding-block: 56px 36px; }
  .nav a { display: none; }
  .wm-c { display: none; }
  .post-row a { grid-template-columns: minmax(0, 1fr); gap: 8px; padding-block: 22px; }
  .row-arrow { display: none; }
  .row-title { font-size: 20px; }
  .compare, .steps, .flow { grid-template-columns: minmax(0, 1fr); }
  .figure-frame { padding: 18px; }
  .footer-grid { grid-template-columns: minmax(0, 1fr); }
  .cta { padding: 26px 22px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* 언어 선택 (서비스와 같은 형태) */
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.lang select {
  appearance: none; -webkit-appearance: none;
  font: inherit; font-size: 13px; color: var(--body);
  background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%23888' stroke-width='1.4'/%3E%3C/svg%3E") no-repeat right 10px center;
  border: 1px solid var(--line); border-radius: 8px; padding: 6px 28px 6px 10px; cursor: pointer;
}
.lang select:hover { border-color: var(--muted); color: var(--ink); }
.lang option { color: #111113; background: #FFFFFF; }

/* 언어별 서체와 줄바꿈 */
html[lang="ja"] { --font: "Geist", "Noto Sans JP", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif; }
html[lang="ja"] body { word-break: normal; line-break: strict; }
html[lang="en"] body, html[lang="id"] body { word-break: normal; overflow-wrap: break-word; }
@media (max-width: 760px) { .lang select { font-size: 12px; padding: 5px 24px 5px 8px; } }
