:root {
  --ink: #1d1d1f;
  --muted: #5a5a5f;
  --rule: #dcdcdc;
  --paper: #ffffff;
  --tint: #f5f5f3;
  --mark: #c62828;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Segoe UI", "Noto Sans KR", Roboto, sans-serif;
  font-size: 1rem;
  line-height: 1.75;
}
:lang(ko) { word-break: keep-all; overflow-wrap: break-word; }
header.site, nav.guides, main, footer {
  width: min(720px, calc(100% - 40px));
  margin-inline: auto;
}
header.site {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-top: 28px;
  font-size: 0.9375rem;
}
header.site a.home { font-weight: 700; text-decoration: none; }
a { color: var(--ink); text-decoration-color: #9a9a9f; text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--ink); }
a:focus-visible, summary:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 2px; }
nav.guides { margin-top: 14px; padding-bottom: 14px; border-bottom: 1px solid var(--rule); }
nav.guides ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 20px; font-size: 0.9375rem; }
nav.guides a { color: var(--muted); text-decoration: none; }
nav.guides a:hover { color: var(--ink); text-decoration: underline; }
nav.guides a[aria-current="page"] { color: var(--ink); font-weight: 700; }
main { padding: 48px 0 32px; }
h1 { font-size: 2rem; line-height: 1.3; font-weight: 700; letter-spacing: -0.02em; margin: 0 0 16px; text-wrap: balance; }
h2 { font-size: 1.25rem; line-height: 1.4; font-weight: 700; letter-spacing: -0.01em; margin: 52px 0 12px; text-wrap: balance; }
h3 { font-size: 1.0625rem; line-height: 1.5; font-weight: 700; margin: 32px 0 6px; }
p { margin: 0 0 14px; }
.lead { font-size: 1.125rem; color: var(--muted); margin-bottom: 8px; }
ul, ol { margin: 0 0 16px; padding-left: 1.4em; }
li { margin-bottom: 6px; }
code, kbd {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
  background: var(--tint);
  padding: 1px 6px;
  border-radius: 4px;
  overflow-wrap: anywhere;
}
pre {
  background: var(--tint);
  border: 1px solid var(--rule);
  border-radius: 6px;
  padding: 12px 16px;
  overflow-x: auto;
  margin: 0 0 16px;
  line-height: 1.6;
}
pre code { background: none; padding: 0; }
table { width: 100%; border-collapse: collapse; margin: 0 0 20px; font-size: 0.9375rem; }
th, td { text-align: left; vertical-align: top; padding: 10px 12px 10px 0; border-bottom: 1px solid var(--rule); line-height: 1.55; }
th { font-weight: 700; border-bottom-color: var(--ink); }
.table-wrap { overflow-x: auto; }
.note { background: var(--tint); border-radius: 6px; padding: 12px 16px; margin: 0 0 16px; color: var(--ink); }
.note p:last-child { margin-bottom: 0; }

/* Illustrative mocks */
figure.mock { margin: 20px 0 28px; }
figure.mock > .frame {
  background: var(--tint);
  border: 1px solid var(--rule);
  border-radius: 8px;
  padding: 16px;
  font-size: 0.9375rem;
  line-height: 1.55;
}
figure.mock figcaption { margin-top: 8px; font-size: 0.875rem; color: var(--muted); line-height: 1.55; }
.lg {
  color: inherit;
  text-decoration: underline wavy var(--mark);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 4px;
}
.mail-row { background: var(--paper); border: 1px solid var(--rule); border-radius: 6px; padding: 10px 14px; }
.mail-row + .mail-row { margin-top: 8px; }
.mail-row .from { font-weight: 700; margin-right: 8px; }
.mail-row .time { color: var(--muted); float: right; font-size: 0.8125rem; }
.mail-row .subject { font-weight: 600; }
.mail-row .snippet { color: var(--muted); }
.msg { background: var(--paper); border: 1px solid var(--rule); border-radius: 6px; padding: 10px 14px; }
.msg .who { font-weight: 700; margin-right: 8px; }
.msg .time { color: var(--muted); font-size: 0.8125rem; }
.card {
  background: var(--paper);
  border: 1px solid #c9c9c9;
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
  padding: 12px 16px;
  margin-top: 12px;
  max-width: 460px;
}
.card .row { display: flex; gap: 14px; padding: 6px 0; border-bottom: 1px solid #ececec; }
.card .row:last-child { border-bottom: 0; }
.card dt { flex: 0 0 6.5em; color: var(--muted); font-size: 0.8125rem; padding-top: 2px; }
.card dd { margin: 0; flex: 1; min-width: 0; overflow-wrap: anywhere; }
.card dl { margin: 0; }
.dialog {
  background: var(--paper);
  border: 1px solid #c9c9c9;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  padding: 18px 20px;
  max-width: 460px;
}
.dialog p { margin-bottom: 10px; }
.dialog .check { display: flex; align-items: center; gap: 8px; margin: 12px 0; font-size: 0.9375rem; }
.box { width: 16px; height: 16px; border: 1.5px solid var(--ink); border-radius: 3px; display: inline-block; flex: none; }
.box.on { background: var(--ink); position: relative; }
.box.on::after { content: ""; position: absolute; left: 4px; top: 0; width: 4px; height: 9px; border: solid var(--paper); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.btns { display: flex; flex-wrap: wrap; gap: 8px; }
.btn { display: inline-block; padding: 6px 14px; border: 1px solid var(--ink); border-radius: 6px; font-size: 0.9375rem; background: var(--paper); }
.btn.solid { background: var(--ink); color: var(--paper); }
.btn.off { border-color: #b5b5b5; color: #6b6b6b; }
.popup {
  background: var(--paper);
  border: 1px solid #c9c9c9;
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
  max-width: 320px;
  padding: 14px 16px;
}
.popup .title { font-weight: 700; margin-bottom: 4px; }
.popup .counts { color: var(--muted); padding-bottom: 10px; border-bottom: 1px solid #ececec; }
.popup .line { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 9px 0; border-bottom: 1px solid #ececec; }
.popup .line:last-child { border-bottom: 0; }
.toggle { width: 34px; height: 20px; border-radius: 10px; background: #b5b5b5; position: relative; flex: none; }
.toggle::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--paper); }
.toggle.on { background: var(--ink); }
.toggle.on::after { left: 16px; }
.perm { max-width: 400px; }
.faq-q { margin-top: 40px; }
footer { padding: 24px 0 56px; border-top: 1px solid var(--rule); color: var(--muted); font-size: 0.875rem; }
.pager { display: flex; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
@media (max-width: 520px) {
  h1 { font-size: 1.625rem; }
  .card .row { flex-direction: column; gap: 0; }
  .card dt { flex-basis: auto; }
}
