/* AMONG 안내 페이지 공통 (서비스 소개 · 개인정보처리방침 · 이용약관) — 홈과 같은 색·글꼴 */
:root {
  --bg: #ffffff; --surface: #ffffff; --surface-2: #f6f6f9; --line: #ececf2; --line-strong: #dcdce6;
  --text: #17161c; --text-2: #4a4957; --muted: #72717f;
  --good: #12805a; --good-soft: #e5f6ee; --warn: #a35400; --warn-soft: #fff3df;
  --radius: 16px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #111015; --surface: #1a1920; --surface-2: #22212a; --line: #2c2b35; --line-strong: #3a3944;
    --text: #f2f1f6; --text-2: #c9c8d3; --muted: #9c9baa;
    --good: #4cc98b; --good-soft: #15291f; --warn: #ffb547; --warn-soft: #3a2a12;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #111015; --surface: #1a1920; --surface-2: #22212a; --line: #2c2b35; --line-strong: #3a3944;
  --text: #f2f1f6; --text-2: #c9c8d3; --muted: #9c9baa;
  --good: #4cc98b; --good-soft: #15291f; --warn: #ffb547; --warn-soft: #3a2a12;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg); color: var(--text);
  font-family: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Noto Sans KR", sans-serif;
  font-size: 15.5px; line-height: 1.7; -webkit-font-smoothing: antialiased; word-break: keep-all; overflow-wrap: anywhere;
}
a { color: var(--primary-label); text-underline-offset: 3px; }
button { font: inherit; color: inherit; cursor: pointer; }

.top { position: sticky; top: 0; z-index: 5; background: var(--bg); border-bottom: 1px solid var(--line); padding-top: env(safe-area-inset-top); }
.top-in { max-width: 720px; margin: 0 auto; padding: 10px 16px; display: flex; align-items: center; gap: 10px; }
.brand { display: inline-flex; align-items: center; gap: 8px; color: var(--text); text-decoration: none; font-weight: 800; letter-spacing: -.01em; }
.top nav { margin-left: auto; display: flex; gap: 2px; font-size: 13.5px; }
.top nav a { color: var(--text-2); text-decoration: none; padding: 6px 8px; border-radius: 999px; }
.top nav a[aria-current="page"] { color: var(--primary-label); background: var(--primary-soft); font-weight: 700; }

main { max-width: 720px; margin: 0 auto; padding: 28px 16px 56px; }
.eyebrow { color: var(--primary-label); font-size: 13px; font-weight: 800; letter-spacing: .02em; margin: 0 0 6px; }
h1 { font-size: 28px; line-height: 1.3; letter-spacing: -.02em; margin: 0 0 10px; }
.lead { color: var(--text-2); font-size: 16.5px; margin: 0 0 8px; }
.meta { color: var(--muted); font-size: 13px; margin: 0 0 24px; }
h2 { font-size: 19px; letter-spacing: -.01em; margin: 40px 0 10px; padding-top: 8px; scroll-margin-top: 72px; }
h3 { font-size: 16px; margin: 22px 0 6px; }
p, ul, ol { margin: 0 0 12px; }
ul, ol { padding-left: 22px; }
li { margin: 4px 0; }
li::marker { color: var(--muted); }
strong { font-weight: 700; }
.muted { color: var(--muted); }
small, .small { font-size: 13.5px; color: var(--text-2); }

.toc { background: var(--surface-2); border-radius: var(--radius); padding: 14px 18px; margin: 0 0 8px; font-size: 14px; }
.toc ol { margin: 0; padding-left: 20px; columns: 2; column-gap: 24px; }
.toc a { color: var(--text-2); text-decoration: none; }
.toc a:hover { color: var(--primary-label); text-decoration: underline; }
@media (max-width: 520px) { .toc ol { columns: 1; } }

.box { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; margin: 14px 0; background: var(--surface); }
.box.soft { background: var(--primary-soft); border-color: transparent; }
.box.warn { background: var(--warn-soft); border-color: transparent; }
.box > :last-child { margin-bottom: 0; }

.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 14px 0; }
@media (max-width: 520px) { .grid { grid-template-columns: 1fr; } }
.card { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; background: var(--surface); }
.card h3 { margin: 0 0 4px; font-size: 15.5px; }
.card p { margin: 0; color: var(--text-2); font-size: 14.5px; line-height: 1.6; }
.card .n { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 8px; background: var(--primary-soft); color: var(--primary-label); font-weight: 800; font-size: 13px; margin-bottom: 8px; }

.tbl { width: 100%; overflow-x: auto; margin: 12px 0 16px; border: 1px solid var(--line); border-radius: 12px; }
table { width: 100%; border-collapse: collapse; font-size: 14px; line-height: 1.55; min-width: 520px; }
th, td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--line); }
th { background: var(--surface-2); font-weight: 700; color: var(--text-2); font-size: 13px; white-space: nowrap; }
tr:last-child td { border-bottom: 0; }

.ctl { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 0; border-top: 1px solid var(--line); }
.ctl:first-of-type { border-top: 0; }
.ctl .t { font-weight: 700; }
.ctl .d { font-size: 13.5px; color: var(--text-2); }
.switch { position: relative; flex: none; width: 50px; height: 30px; }
.switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.switch span { position: absolute; inset: 0; border-radius: 999px; background: var(--line-strong); transition: background .15s; pointer-events: none; }
.switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .15s; }
.switch input:checked + span { background: var(--primary); }
.switch input:checked + span::after { background: var(--primary-ink); transform: translateX(20px); }
.switch input:focus-visible + span { outline: 2px solid var(--primary-label); outline-offset: 2px; }
.switch input:disabled + span { opacity: .5; }
.btn { flex: none; border: 1px solid var(--line-strong); background: var(--surface); border-radius: 999px; padding: 8px 14px; font-size: 14px; font-weight: 700; }
.btn.danger { border-color: transparent; background: var(--warn-soft); color: var(--warn); }
.status { font-size: 13.5px; color: var(--good); min-height: 1.2em; margin: 4px 0 0; }

.foot { border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; text-align: center; padding: 20px 16px calc(28px + env(safe-area-inset-bottom)); }
.foot nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 14px; margin-bottom: 6px; }
.foot a { color: var(--text-2); text-decoration: none; padding: 4px 2px; }
.foot a:hover { text-decoration: underline; }

.reading-nav { display: flex; flex-wrap: wrap; gap: 8px 18px; padding: 16px 0; border-block: 1px solid var(--line); }
.example { border-left: 3px solid var(--primary); padding: 4px 16px; margin: 18px 0; background: var(--surface-2); }
:focus-visible { outline: 2px solid var(--primary-label); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; } }
@media (max-width: 420px) {
  .top-in { flex-wrap: wrap; }
  .top nav { width: 100%; margin-left: 0; justify-content: space-between; }
}

.calculator { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 18px 0; }
.calculator label { font-size: 13px; font-weight: 700; }
.calculator input { display: block; width: 100%; min-width: 0; margin-top: 6px; padding: 12px; font: inherit; font-size: 16px; color: var(--text); background: var(--surface); border: 1px solid var(--line-strong); border-radius: 10px; }
.calculator button { justify-self: start; min-height: 44px; }
.calculation-result { font-weight: 700; line-height: 1.8; }
@media (max-width: 420px) { .calculator { grid-template-columns: 1fr; } }

.top { box-shadow: 0 2px 12px rgb(34 22 58 / .04); }

.order-comparison { min-width: 0; table-layout: fixed; margin: 16px 0; font-variant-numeric: tabular-nums; }
.order-comparison caption { text-align: left; color: var(--text-2); margin-bottom: 6px; font-size: 13px; }
.order-comparison th, .order-comparison td { padding: 9px 8px; }
.order-comparison th:not(:first-child), .order-comparison td { text-align: right; }
.order-comparison tbody th { background: var(--bg); font-weight: 500; }
.order-comparison tfoot th, .order-comparison tfoot td { background: var(--primary-soft); color: var(--text); font-weight: 750; }
@media (max-width: 420px) {
  main h2[id] { scroll-margin-top: calc(108px + env(safe-area-inset-top)); }
}
