/* HUMAC AI活用セミナー資料ライブラリ — humac.info のトークンに準拠 */
:root {
  --ink: #0e1726;
  --ink-soft: #2b3850;
  --muted: #5b6678;
  --line: #e3e8f0;
  --bg: #ffffff;
  --bg-tint: #f5f7fb;
  --sky: #4ba3dc;
  --accent: #1e63d0;
  --accent-soft: #eaf1fc;
  --warn: #c2410c;
  --warn-soft: #fff1e8;
  --ok: #15803d;
  --ok-soft: #e9f7ee;
  --yellow: #a16207;
  --yellow-soft: #fdf6e3;
  --radius: 12px;
  --font: "Noto Sans JP", -apple-system, BlinkMacSystemFont, "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  --font-display: "Zen Old Mincho", "Hiragino Mincho ProN", "Yu Mincho", serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.8;
}
a { color: var(--accent); }
img { max-width: 100%; }

.wrap { max-width: 980px; margin: 0 auto; padding: 0 16px; }

/* header */
.lib-header { border-bottom: 1px solid var(--line); background: #fff; }
.lib-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-block: 12px; flex-wrap: wrap; }
.lib-brand { font-weight: 700; color: var(--ink); text-decoration: none; font-size: .95rem; }
.lib-brand span { color: var(--accent); }
.lib-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.btn { display: inline-block; padding: 6px 14px; border-radius: 999px; border: 1px solid var(--accent); color: var(--accent); text-decoration: none; font-size: .88rem; font-weight: 500; background: #fff; }
.btn--solid { background: var(--accent); color: #fff; }

/* page head */
.doc-head { padding: 36px 0 20px; }
.doc-id { display: inline-block; font-size: .8rem; font-weight: 700; color: #fff; background: var(--accent); border-radius: 6px; padding: 2px 10px; letter-spacing: .05em; }
.doc-head h1 { font-family: var(--font-display); font-size: clamp(1.6rem, 4vw, 2.2rem); line-height: 1.4; margin: 12px 0 8px; }
.doc-lead { color: var(--ink-soft); font-size: 1.05rem; margin: 0; }
.doc-meta { color: var(--muted); font-size: .85rem; margin-top: 10px; }

main { padding-bottom: 48px; }
h2 { font-size: 1.3rem; margin: 40px 0 12px; padding-left: 12px; border-left: 5px solid var(--accent); line-height: 1.5; }
h3 { font-size: 1.08rem; margin: 24px 0 8px; color: var(--ink-soft); }
p { margin: 0 0 12px; }
ul, ol { margin: 0 0 14px; padding-left: 1.4em; }
li { margin-bottom: 4px; }
strong { color: var(--ink); }

/* tables */
.table-wrap { overflow-x: auto; margin: 12px 0 20px; border: 1px solid var(--line); border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; font-size: .92rem; min-width: 560px; }
th, td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
th { background: var(--bg-tint); font-weight: 700; color: var(--ink-soft); white-space: nowrap; }
tr:last-child td { border-bottom: none; }
td.c, th.c { text-align: center; }
.yes { color: var(--ok); font-weight: 700; }
.no { color: var(--muted); }
.part { color: var(--yellow); font-weight: 700; }

/* callouts */
.box { border-radius: var(--radius); padding: 16px 18px; margin: 16px 0; background: var(--bg-tint); border: 1px solid var(--line); }
.box > :last-child { margin-bottom: 0; }
.box--key { background: var(--accent-soft); border-color: #c9dbf6; }
.box--warn { background: var(--warn-soft); border-color: #f6d3bd; }
.box--ok { background: var(--ok-soft); border-color: #c6e8d2; }
.box-title { font-weight: 700; margin-bottom: 6px; }

/* cards grid */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; margin: 14px 0 20px; }
.card { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; background: #fff; }
.card h3 { margin-top: 0; color: var(--ink); }
.card p:last-child, .card ul:last-child { margin-bottom: 0; }
.card .tag { display: inline-block; font-size: .75rem; padding: 1px 8px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); margin: 0 4px 4px 0; }

/* flow */
.flow { display: flex; flex-wrap: wrap; gap: 8px; align-items: stretch; margin: 14px 0 20px; counter-reset: step; }
.flow .step { flex: 1 1 150px; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; background: #fff; position: relative; }
.flow .step::before { counter-increment: step; content: counter(step); display: inline-flex; width: 26px; height: 26px; border-radius: 50%; background: var(--accent); color: #fff; font-weight: 700; font-size: .85rem; align-items: center; justify-content: center; margin-bottom: 6px; }
.flow .step b { display: block; }
.flow .step small { color: var(--muted); display: block; line-height: 1.6; }

/* signal */
.sig { display: inline-block; width: 14px; height: 14px; border-radius: 50%; vertical-align: -2px; margin-right: 6px; }
.sig--g { background: #22a354; } .sig--y { background: #e0a100; } .sig--r { background: #d64545; }

/* prompt blocks */
.prompt { background: #0e1726; color: #e6edf7; border-radius: var(--radius); padding: 14px 16px; font-size: .92rem; white-space: pre-wrap; margin: 10px 0 16px; line-height: 1.7; }
.prompt::before { content: "コピーして使う"; display: block; font-size: .72rem; color: #8fcdf0; margin-bottom: 6px; letter-spacing: .05em; }

/* library index */
.lib-section { margin-top: 28px; }
.doc-list { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }
.doc-list li { margin: 0; }
.doc-list a { display: block; height: 100%; text-decoration: none; color: inherit; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; background: #fff; }
.doc-list a:hover { border-color: var(--accent); box-shadow: 0 6px 20px rgba(14,23,38,.06); }
.doc-list .t { font-weight: 700; display: block; margin: 4px 0 2px; }
.doc-list .d { font-size: .86rem; color: var(--muted); display: block; line-height: 1.6; }

/* sources */
.sources { font-size: .85rem; color: var(--muted); border-top: 1px solid var(--line); margin-top: 40px; padding-top: 14px; }
.sources ul { padding-left: 1.2em; }
.sources a { word-break: break-all; }

/* footer */
.lib-footer { background: var(--ink); color: #c4ccda; font-size: .85rem; padding: 24px 0; }
.lib-footer a { color: #c4ccda; }

/* worksheet */
.write { border-bottom: 1px dashed #b7c1d1; min-height: 32px; margin-bottom: 8px; }
.ws-table td { height: 44px; }

@media print {
  @page { size: A4; margin: 14mm 12mm; }
  body { font-size: 11pt; line-height: 1.65; }
  .lib-header, .lib-footer, .no-print { display: none !important; }
  .doc-head { padding-top: 0; }
  h2 { break-after: avoid; margin-top: 22px; }
  .table-wrap { overflow: visible; border: none; }
  table { min-width: 0; font-size: 9.5pt; border: 1px solid var(--line); }
  tr, .card, .box, .step { break-inside: avoid; }
  a { color: inherit; text-decoration: none; }
  .sources a::after { content: " (" attr(href) ")"; font-size: 8pt; }
  .prompt { background: #f3f5f9; color: var(--ink); border: 1px solid var(--line); }
  .prompt::before { color: var(--muted); }
  -webkit-print-color-adjust: exact; print-color-adjust: exact;
}
