:root {
  --bg: #ffffff;
  --surface: #f5f6f8;
  --text: #1c1e21;
  --muted: #5f6670;
  --border: #dde1e6;
  --accent: #2457d6;
  --accent-text: #ffffff;
  --warn: #c0392b;
  --radius: 10px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #15171a;
    --surface: #1f2226;
    --text: #e8eaed;
    --muted: #a0a7b0;
    --border: #33373d;
    --accent: #7aa2ff;
    --accent-text: #0d1220;
    --warn: #ff7b6b;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.7 -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", sans-serif;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
a { color: var(--accent); }
.wrap { max-width: 760px; margin: 0 auto; padding: 0 16px; }
header.site { border-bottom: 1px solid var(--border); }
header.site .wrap { display: flex; align-items: center; justify-content: space-between; height: 56px; }
header.site .logo { font-weight: 700; font-size: 18px; color: var(--text); text-decoration: none; }
header.site nav a { color: var(--muted); text-decoration: none; margin-left: 14px; font-size: 15px; }
main { padding: 24px 0 48px; }
h1 { font-size: 26px; line-height: 1.35; margin: 0 0 8px; }
h2 { font-size: 20px; margin: 36px 0 10px; }
h3 { font-size: 17px; margin: 22px 0 6px; }
.lead { color: var(--muted); margin: 0 0 20px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; }
textarea, input[type="number"], input[type="text"], input[type="date"], select {
  width: 100%;
  font: inherit;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
}
textarea { min-height: 240px; resize: vertical; }
textarea:focus, input:focus, select:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
button {
  font: inherit;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  border-radius: 8px;
  padding: 8px 14px;
  cursor: pointer;
}
button.primary { background: var(--accent); color: var(--accent-text); border-color: var(--accent); }
.row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 10px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 8px; margin-top: 14px; }
.stat { background: var(--bg); border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; }
.stat .label { color: var(--muted); font-size: 13px; }
.stat .value { font-size: 22px; font-weight: 700; font-variant-numeric: tabular-nums; }
.stat.main .value { color: var(--accent); }
.limit { margin-top: 14px; }
.limit label { font-size: 14px; color: var(--muted); }
.bar { height: 8px; background: var(--border); border-radius: 4px; overflow: hidden; margin-top: 6px; }
.bar > span { display: block; height: 100%; width: 0; background: var(--accent); }
.over .bar > span { background: var(--warn); }
.over .limit-msg { color: var(--warn); font-weight: 600; }
.note { font-size: 14px; color: var(--muted); }
table { border-collapse: collapse; width: 100%; font-size: 15px; }
th, td { border: 1px solid var(--border); padding: 8px 10px; text-align: left; vertical-align: top; }
th { background: var(--surface); }
.tool-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.tool-list a { display: block; padding: 14px 16px; border: 1px solid var(--border); border-radius: var(--radius); text-decoration: none; color: var(--text); background: var(--surface); }
.tool-list strong { display: block; font-size: 17px; }
.tool-list span { color: var(--muted); font-size: 14px; }
footer.site { border-top: 1px solid var(--border); padding: 20px 0 32px; font-size: 14px; color: var(--muted); }
footer.site a { color: var(--muted); margin-right: 12px; }
@media (max-width: 480px) {
  h1 { font-size: 22px; }
  header.site nav a { margin-left: 10px; font-size: 14px; }
}
