:root {
  --bg: #f7f7f5; --card: #fff; --text: #1b1b1b; --muted: #666; --line: #e3e3df;
  --accent: #1a6b4f; --accent-soft: #e6f2ed; --warn: #9a5b00;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #141414; --card: #1e1e1e; --text: #eee; --muted: #aaa; --line: #333; --accent: #5fc79f; --accent-soft: #1f3129; --warn: #e3a64a; }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); font: 16px/1.65 -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Pretendard", "Noto Sans KR", sans-serif; }
a { color: var(--accent); }
header, main, footer { max-width: 760px; margin: 0 auto; padding: 0 16px; }
header { display: flex; justify-content: space-between; align-items: center; padding-top: 18px; padding-bottom: 18px; }
header .logo { font-weight: 700; font-size: 18px; text-decoration: none; color: var(--text); }
header nav a { margin-left: 14px; font-size: 14px; color: var(--muted); text-decoration: none; }
h1 { font-size: 26px; line-height: 1.3; margin: 8px 0 6px; }
h2 { font-size: 20px; margin-top: 36px; }
.lead { color: var(--muted); margin-top: 0; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 20px; margin: 18px 0; }
.grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 4px; }
input, select { width: 100%; padding: 11px 12px; font-size: 17px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg); color: var(--text); }
.hint { font-size: 12px; color: var(--muted); margin-top: 3px; }
button { margin-top: 16px; width: 100%; padding: 13px; font-size: 17px; font-weight: 700; border: 0; border-radius: 8px; background: var(--accent); color: #fff; cursor: pointer; }
.result { background: var(--accent-soft); border-radius: 12px; padding: 18px 20px; margin-top: 18px; }
.result .big { font-size: 30px; font-weight: 800; color: var(--accent); }
table { width: 100%; border-collapse: collapse; font-size: 15px; }
td, th { padding: 8px 4px; border-bottom: 1px solid var(--line); text-align: left; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.note { font-size: 13px; color: var(--warn); }
.tools { list-style: none; padding: 0; }
.tools li { margin: 0 0 12px; }
.tools a { display: block; padding: 16px 18px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; text-decoration: none; color: var(--text); }
.tools a strong { display: block; color: var(--accent); }
.tools a span { font-size: 14px; color: var(--muted); }
.ad { margin: 24px 0; min-height: 100px; }
details { border-bottom: 1px solid var(--line); padding: 10px 0; }
summary { font-weight: 600; cursor: pointer; }
footer { color: var(--muted); font-size: 13px; padding-top: 40px; padding-bottom: 40px; }
footer a { color: var(--muted); margin-right: 12px; }
