/* 농기계 자산 수첩 공통 스타일: 시스템 글꼴, 외부 라이브러리 없음 */
:root {
  --ink: #17302a;
  --muted: #475a51;
  --line: #d3e2d8;
  --bg: #f3f7f4;
  --card: #ffffff;
  --brand: #17644d;
  --brand-dark: #0f4a39;
  --soft: #e7f2eb;
  --warn-bg: #fff4e6;
  --warn-line: #b4581c;
  --bad: #a3271f;
  --good: #1f6b3f;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", system-ui, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--ink);
  background: var(--bg);
  word-break: keep-all;
  overflow-wrap: anywhere;
}
a { color: var(--brand); text-underline-offset: 3px; }
a:hover { color: var(--brand-dark); }
img, svg { max-width: 100%; }
h1, h2, h3 { line-height: 1.35; color: #11291f; }
h1 { font-size: clamp(1.75rem, 6vw, 2.5rem); margin: .2em 0 .5em; }
h2 { font-size: clamp(1.3rem, 4.5vw, 1.6rem); margin: 0 0 .6em; }
h3 { font-size: 1.12rem; margin: 1.1em 0 .4em; }
p { margin: 0 0 .9em; }
ul, ol { padding-left: 1.3em; margin: 0 0 1em; }
li { margin: .35em 0; }
:focus-visible { outline: 3px solid #e2a400; outline-offset: 2px; }
.skip { position: absolute; left: -9999px; top: 0; background: #fff; padding: 10px 14px; z-index: 10; }
.skip:focus { left: 8px; top: 8px; }

/* 머리말 */
.site-header { background: #fff; border-bottom: 1px solid var(--line); }
.site-header .bar { max-width: 980px; margin: 0 auto; padding: 10px 16px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; }
.brand { font-weight: 800; font-size: 1.15rem; color: #12422f; text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; }
.site-nav { display: flex; flex-wrap: wrap; gap: 6px; margin-left: auto; }
.site-nav a { display: inline-flex; align-items: center; min-height: 44px; padding: 6px 12px; border-radius: 8px; text-decoration: none; font-weight: 700; color: #1c4a37; font-size: 1rem; }
.site-nav a:hover, .site-nav a[aria-current="page"] { background: var(--soft); }
.site-nav a[aria-current="page"] { color: var(--brand-dark); box-shadow: inset 0 -3px 0 var(--brand); }
@media (max-width: 720px) {
  .site-nav { margin-left: 0; width: 100%; gap: 4px; }
  .site-nav a { padding: 6px 10px; font-size: .97rem; background: #f4f8f5; }
}

/* 본문 */
.wrap { max-width: 980px; margin: 0 auto; padding: 12px 16px 56px; }
.narrow { max-width: 820px; }
.crumbs { font-size: .97rem; color: var(--muted); margin: 8px 0 4px; }
.crumbs a { color: var(--muted); }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 22px; margin: 16px 0; }
.card > :last-child { margin-bottom: 0; }
.hero { padding: 26px 22px; }
.lead { font-size: 1.12rem; color: #25443a; }
.eyebrow { font-weight: 800; color: #2d6a4f; margin: 0; font-size: 1rem; }
.muted, .small { color: var(--muted); }
.small { font-size: .97rem; }
.notice { background: var(--soft); border-left: 5px solid #3a8460; padding: 12px 15px; border-radius: 6px; }
.warn { background: var(--warn-bg); border-left: 5px solid var(--warn-line); padding: 12px 15px; border-radius: 6px; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.tile { display: block; background: #f8fbf9; border: 1px solid var(--line); border-radius: 12px; padding: 16px; text-decoration: none; color: var(--ink); }
a.tile:hover { border-color: var(--brand); background: #fff; }
.tile strong { display: block; color: #12422f; font-size: 1.08rem; margin-bottom: 4px; }
.tile span { color: var(--muted); }
@media (max-width: 760px) { .grid2, .grid3 { grid-template-columns: 1fr; } .card { padding: 18px 16px; } .hero { padding: 20px 16px; } }

/* 버튼 */
.btn, button.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px; padding: 10px 18px; border-radius: 10px; border: 2px solid var(--brand); background: var(--brand); color: #fff; font: inherit; font-weight: 800; text-decoration: none; cursor: pointer; text-align: center; }
.btn:hover { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; }
.btn.secondary { background: #fff; color: var(--brand-dark); }
.btn.secondary:hover { background: var(--soft); color: var(--brand-dark); }
.btn.danger { background: #fff; color: var(--bad); border-color: #d9a29d; }
.btn.danger:hover { background: #fdf0ef; }
.btn.big { font-size: 1.15rem; min-height: 56px; padding: 12px 24px; }
.btn.small-btn { min-height: 44px; padding: 6px 14px; font-size: 1rem; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 14px 0 4px; }
@media (max-width: 480px) { .actions .btn { flex: 1 1 100%; } }

/* 입력 */
.field { display: block; margin: 0 0 12px; }
.field > span { display: block; font-weight: 700; margin-bottom: 4px; }
.field small { display: block; color: var(--muted); font-size: .95rem; }
input[type="text"], input[type="date"], input[type="tel"], input[type="number"], input:not([type]), select, textarea {
  width: 100%; font: inherit; font-size: 1.0625rem; color: var(--ink); background: #fff;
  border: 1px solid #9fb5a7; border-radius: 9px; padding: 10px 12px; min-height: 48px;
}
textarea { min-height: 96px; resize: vertical; line-height: 1.6; }
input:focus, select:focus, textarea:focus { border-color: var(--brand); outline: 3px solid rgba(23,100,77,.25); outline-offset: 0; }
input[type="checkbox"], input[type="radio"] { width: 24px; height: 24px; accent-color: var(--brand); flex: none; }
.fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 16px; }
.fields .wide { grid-column: 1 / -1; }
@media (max-width: 680px) { .fields { grid-template-columns: 1fr; } }

/* 체크 목록 */
.checklist { list-style: none; padding: 0; margin: 0 0 1em; }
.checklist li { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; margin: 10px 0; background: #fbfdfb; }
.checklist label.row { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; min-height: 44px; }
.checklist label.row input { margin-top: 3px; }
.checklist small { display: block; color: var(--muted); font-size: .97rem; }
.steps { counter-reset: step; list-style: none; padding: 0; }
.steps > li { position: relative; padding: 4px 0 12px 52px; margin: 0 0 6px; border-bottom: 1px solid #e3ece6; }
.steps > li::before { counter-increment: step; content: counter(step); position: absolute; left: 0; top: 2px; width: 38px; height: 38px; border-radius: 50%; background: var(--brand); color: #fff; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.steps > li:last-child { border-bottom: 0; }
.steps strong { display: block; font-size: 1.08rem; }

table.data { width: 100%; border-collapse: collapse; font-size: 1rem; }
table.data th, table.data td { border: 1px solid #cddcd2; padding: 9px 10px; text-align: left; vertical-align: top; overflow-wrap: break-word; }
table.data th { background: #f0f6f2; }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
@media (max-width: 600px) {
  table.stack thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  table.stack, table.stack tbody, table.stack tr, table.stack td { display: block; width: auto; }
  table.stack tr { border: 1px solid #cddcd2; border-radius: 10px; margin: 0 0 10px; padding: 10px 12px; background: #fbfdfb; }
  table.stack td { border: 0; padding: 3px 0; }
  table.stack td[data-label]::before { content: attr(data-label) " · "; font-weight: 800; color: #2f4a3e; }
}

summary { cursor: pointer; padding: 10px 0; font-weight: 700; color: var(--brand-dark); }
.status { min-height: 1.6em; font-weight: 700; color: var(--good); margin: 8px 0 0; }
.status.err { color: var(--bad); }
.sources li { margin: .6em 0; }
.next a { font-weight: 700; }

/* 작성 정보·범위 */
.meta-line { font-size: .97rem; color: var(--muted); border-top: 1px solid var(--line); padding-top: 10px; margin: 14px 0 0; }
.meta-line a { color: #2f4a3e; font-weight: 700; }
.scope { background: #f6f9f7; }
.scope h2 { font-size: 1.2rem; }
dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: 8px 18px; margin: 0 0 1em; }
dl.facts dt { font-weight: 800; color: #1f3a2f; }
dl.facts dd { margin: 0; }
@media (max-width: 560px) { dl.facts { grid-template-columns: 1fr; gap: 2px; } dl.facts dd { margin-bottom: 10px; } }
.example-tag { display: inline-block; font-size: .9rem; font-weight: 800; color: #6a3d07; background: #fdf0d8; border: 1px solid #e8c48a; border-radius: 999px; padding: 1px 10px; }

/* 꼬리말 */
.site-footer { border-top: 1px solid var(--line); background: #fff; margin-top: 24px; }
.site-footer .inner { max-width: 980px; margin: 0 auto; padding: 24px 16px 36px; color: var(--muted); font-size: .97rem; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-bottom: 10px; }
.site-footer nav a { display: inline-flex; align-items: center; min-height: 44px; font-weight: 700; }
.site-footer nav.info-links { border-top: 1px solid var(--line); padding-top: 8px; }
.site-footer .ops { color: #33463d; font-weight: 700; }
.site-footer .ops a { color: inherit; }

@media print {
  body { background: #fff; font-size: 11pt; }
  .site-header, .site-footer, .crumbs, .actions, .no-print, .skip { display: none !important; }
  .wrap { max-width: none; padding: 0; }
  .card { border: 0; padding: 4px 0; margin: 8px 0; break-inside: auto; }
  a { color: inherit; text-decoration: none; }
  input[type="text"], input[type="date"], input:not([type]), select, textarea { border: 0; border-bottom: 1px solid #666; border-radius: 0; min-height: 0; padding: 4px 2px; }
}
