/* PayChain Medium series — article reader (print → PDF) */
:root {
  --article-max: 42rem;
  --article-muted: #5c6370;
  --article-border: #e2e6ed;
  --article-accent: #1a5f4a;
  --article-risk: #8b3a3a;
  --article-limit: #6b5a1a;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: "Segoe UI", system-ui, -apple-system, sans-serif;
  line-height: 1.65;
  color: #1a1d21;
  background: #f7f8fa;
}
.article-topbar {
  background: #fff;
  border-bottom: 1px solid var(--article-border);
  padding: 0.75rem 1rem;
  position: sticky;
  top: 0;
  z-index: 10;
}
.article-topbar__inner {
  max-width: 52rem;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  align-items: center;
  justify-content: space-between;
}
.article-topbar a { color: var(--article-accent); text-decoration: none; font-weight: 600; }
.article-topbar a:hover { text-decoration: underline; }
.article-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.article-actions button, .article-actions a.btn-print {
  font: inherit;
  padding: 0.35rem 0.75rem;
  border: 1px solid var(--article-border);
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}
.article-actions button:hover, .article-actions a.btn-print:hover { background: #eef2f6; }
.article-wrap {
  max-width: var(--article-max);
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
  background: #fff;
  box-shadow: 0 1px 0 var(--article-border);
}
.article-series { font-size: 0.85rem; color: var(--article-muted); text-transform: uppercase; letter-spacing: 0.04em; }
.article-part { font-size: 0.9rem; color: var(--article-accent); font-weight: 700; margin: 0.25rem 0 0; }
h1 { font-size: 1.85rem; line-height: 1.25; margin: 0.5rem 0 0.25rem; }
.article-subtitle { font-size: 1.15rem; color: var(--article-muted); margin: 0 0 1.5rem; font-weight: 500; }
.article-meta { font-size: 0.85rem; color: var(--article-muted); margin-bottom: 2rem; padding-bottom: 1rem; border-bottom: 1px solid var(--article-border); }
h2 { font-size: 1.25rem; margin: 2rem 0 0.75rem; color: #0f1419; }
h3 { font-size: 1.05rem; margin: 1.5rem 0 0.5rem; }
p { margin: 0 0 1rem; }
ul, ol { margin: 0 0 1rem; padding-left: 1.35rem; }
li { margin-bottom: 0.35rem; }
code { font-size: 0.88em; background: #eef2f6; padding: 0.1em 0.35em; border-radius: 4px; }
.article-callout {
  border-left: 4px solid var(--article-accent);
  background: #f0f7f4;
  padding: 1rem 1.15rem;
  margin: 1.25rem 0;
  border-radius: 0 8px 8px 0;
}
.article-callout--limit { border-color: #c9a227; background: #fdf9ed; }
.article-callout--risk { border-color: #c44; background: #fdf3f3; }
.article-callout--pilot { border-color: #5a6a8a; background: #f4f6fa; }
.article-callout--v2 { border-color: #2d6a9f; background: #f0f6fc; }
.article-callout--v2 h3 { color: #1a4d7a; margin-top: 0; font-size: 0.95rem; }
.article-callout--pilot h3 { color: #3d4a5c; }
.article-code {
  font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 0.88rem;
  background: #f0f2f5;
  padding: 0.75rem 1rem;
  border-radius: 6px;
  overflow-x: auto;
  margin: 1rem 0;
}
.article-medium-meta { font-size: 0.8rem; color: var(--article-muted); margin-top: 0.5rem; }
.article-medium-meta code { font-size: 0.95em; }
.article-callout h3 { margin-top: 0; font-size: 0.95rem; text-transform: uppercase; letter-spacing: 0.03em; }
.article-callout--limit h3 { color: var(--article-limit); }
.article-callout--risk h3 { color: var(--article-risk); }
.article-nav { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--article-border); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1rem; }
.article-nav a { color: var(--article-accent); font-weight: 600; }
body.lang-is-ko .lang-en { display: none !important; }
body.lang-is-en .lang-ko { display: none !important; }
.article-lang-toggle { display: flex; gap: 0.25rem; }
.article-lang-toggle button {
  font: inherit;
  font-size: 0.8rem;
  padding: 0.25rem 0.5rem;
  border: 1px solid var(--article-border);
  border-radius: 4px;
  background: #fff;
  cursor: pointer;
}
.article-lang-toggle button.is-active {
  background: var(--article-accent);
  color: #fff;
  border-color: var(--article-accent);
}
.article-reading-time { font-size: 0.85rem; color: var(--article-muted); }
.article-toc { background: #f7f8fa; border-radius: 8px; padding: 1rem 1.25rem; margin: 1.5rem 0; }
.article-toc ol { margin: 0.5rem 0 0; }
table.article-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; margin: 1rem 0; }
table.article-table th, table.article-table td { border: 1px solid var(--article-border); padding: 0.5rem 0.65rem; text-align: left; }
table.article-table th { background: #f0f2f5; }
.article-figure { margin: 1.5rem 0; padding: 1rem; background: #f7f8fa; border-radius: 8px; border: 1px solid var(--article-border); }
.article-figure figcaption { font-size: 0.85rem; color: var(--article-muted); margin-top: 0.75rem; text-align: center; }
.article-flow { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 0.35rem 0.5rem; font-size: 0.82rem; }
.article-flow__node { padding: 0.4rem 0.65rem; background: #fff; border: 1px solid var(--article-border); border-radius: 6px; font-weight: 600; }
.article-flow__node--core { background: #e8f5f0; border-color: var(--article-accent); color: var(--article-accent); }
.article-flow__node--v2 { background: #e8f2fa; border-color: #2d6a9f; }
.article-flow__arrow { color: var(--article-muted); font-weight: 700; }
.article-flow--stack { flex-direction: column; align-items: stretch; max-width: 22rem; margin: 0 auto; }
.article-flow--stack .article-flow__row { display: flex; align-items: center; justify-content: center; gap: 0.5rem; }
@media print {
  .article-topbar, .article-actions, .no-print { display: none !important; }
  body { background: #fff; }
  .article-wrap { box-shadow: none; max-width: 100%; padding: 0; }
}
