/* サクッと計算 — デザインシステム v2「退職届」
 * 和紙×墨×朱。見出し・数字=しっぽり明朝、本文=Zen Kaku Gothic New。
 * 罫線とドットリーダーの書類モチーフ。角丸は原則ゼロ。
 */
:root {
  --paper: #f9f7f2;
  --card: #fdfcf9;
  --ink: #221d16;
  --ink-2: #5c5546;
  --ink-3: #8a8172;
  --faint: #9d947f;
  --line: #d5cdbc;
  --line-strong: #c9c1af;
  --accent: #c73e2e;
  --accent-dark: #a32f21;
  --accent-bg: #fbf1ef;
  --track: #ece6d8;
  --serif: "Shippori Mincho", "Hiragino Mincho ProN", "Yu Mincho", serif;
  --gothic: "Zen Kaku Gothic New", "Hiragino Sans", "Noto Sans JP", sans-serif;
  --maxw: 880px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--gothic);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.85;
  font-size: 15.5px;
  font-feature-settings: "palt";
}
a { color: var(--accent-dark); text-decoration: none; }
a:hover { text-decoration: underline; }
.num, .tnum { font-variant-numeric: tabular-nums; }

/* ===== ヘッダー ===== */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: rgba(249, 247, 242, 0.94);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header .inner {
  max-width: var(--maxw); margin: 0 auto; padding: 0 16px;
  height: 54px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.brand {
  font-family: var(--serif); font-weight: 700; font-size: 15.5px; color: var(--ink);
  letter-spacing: 0.12em; white-space: nowrap;
  display: flex; align-items: center; gap: 8px;
}
.brand:hover { text-decoration: none; }
.brand .yen {
  width: 23px; height: 23px;
  background: var(--accent); color: var(--paper);
  display: grid; place-items: center;
  font-family: var(--serif); font-size: 13px; font-weight: 700;
}
.brand .mark { color: var(--ink); }
.gnav { display: flex; gap: 2px; font-size: 12.5px; white-space: nowrap; overflow-x: auto; }
.gnav a { color: var(--ink-2); padding: 5px 8px; font-weight: 600; border-bottom: 2px solid transparent; }
.gnav a:hover { color: var(--accent-dark); text-decoration: none; }
.gnav a.active { color: var(--ink); border-bottom-color: var(--accent); }

main { max-width: var(--maxw); margin: 0 auto; padding: 26px 16px 64px; }

/* ===== 見出し・パンくず ===== */
.crumbs { font-size: 11.5px; color: var(--faint); margin: 0 0 16px; letter-spacing: 0.04em; }
.crumbs a { color: var(--faint); }
h1 {
  font-family: var(--serif); font-size: 27px; line-height: 1.55; margin: 0 0 12px;
  letter-spacing: 0.03em; font-weight: 800;
}
h2 {
  font-family: var(--serif); font-size: 16.5px; margin: 46px 0 16px; line-height: 1.6;
  font-weight: 700; letter-spacing: 0.3em;
  border-bottom: 1.5px solid var(--ink); padding-bottom: 8px;
}
h3 { font-family: var(--serif); font-size: 15.5px; margin: 26px 0 8px; font-weight: 700; letter-spacing: 0.06em; }
.lead { color: var(--ink-2); font-size: 14px; margin: 0 0 24px; line-height: 2; }
.lead strong, p strong { color: var(--ink); }
.aka { color: var(--accent); }

/* ===== カード（書類）・フォーム ===== */
.card {
  background: var(--card); border: 1px solid var(--line);
  padding: 26px 18px 22px 18px; margin: 0 0 18px;
  position: relative;
}
.card[data-tab]::before {
  content: attr(data-tab);
  position: absolute; top: -10px; left: 14px;
  background: var(--ink); color: var(--paper);
  font-family: var(--serif); font-size: 11px; font-weight: 600;
  letter-spacing: 0.28em; padding: 2px 12px 2px 14px; line-height: 1.6;
}
.calc-form { display: grid; gap: 20px; }
.field label {
  display: block; font-size: 11px; font-weight: 700;
  letter-spacing: 0.14em; color: var(--ink-3); margin-bottom: 2px;
}
.field .unit { font-size: 11px; color: var(--faint); margin-left: 6px; font-weight: 500; letter-spacing: 0; }
input[type="number"], input[type="text"] {
  width: 100%; padding: 6px 2px; font-size: 24px;
  border: none; border-bottom: 1.5px solid var(--ink);
  background: transparent; color: var(--ink);
  font-family: var(--serif); font-weight: 700;
  font-variant-numeric: tabular-nums; border-radius: 0;
}
select {
  width: 100%; padding: 10px 8px; font-size: 15px;
  border: 1px solid var(--line-strong); background: var(--card); color: var(--ink);
  font-family: var(--gothic); border-radius: 0;
}
input::placeholder { color: #c9c1af; font-weight: 600; }
input:focus, select:focus { outline: none; border-color: var(--accent); }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.checks { display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 13.5px; align-items: center; }
.checks label { display: flex; align-items: center; gap: 7px; cursor: pointer; color: var(--ink-2); }
.checks select { width: auto; padding: 5px 8px; font-size: 13.5px; }
.btn {
  display: block; width: 100%; padding: 16px; font-size: 16px;
  font-family: var(--serif); font-weight: 700; letter-spacing: 0.3em;
  color: var(--paper); background: var(--ink);
  border: none; border-radius: 0; cursor: pointer;
  position: relative; transition: background 0.15s ease, transform 0.05s ease;
}
.btn::after { content: ""; position: absolute; top: 0; right: 0; width: 6px; height: 100%; background: var(--accent); }
.btn:hover { background: #35301f; }
.btn:active { transform: translateY(1px); }
a.btn { text-align: center; text-decoration: none; }

/* ===== プリセットチップ・セグメント ===== */
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.chips button {
  padding: 5px 12px; font-size: 12px; font-weight: 500; font-family: var(--gothic);
  color: var(--ink-2); background: transparent; border: 1px solid var(--line-strong);
  border-radius: 0; cursor: pointer; font-variant-numeric: tabular-nums;
}
.chips button:active { transform: translateY(1px); }
.chips button.on { background: var(--accent); border-color: var(--accent); color: var(--card); font-weight: 700; }

.seg { display: flex; gap: 28px; padding: 4px 8px; }
.seg button {
  position: relative; padding: 6px 4px;
  font-family: var(--serif); font-weight: 600; font-size: 17px;
  background: transparent; border: none; color: var(--faint); cursor: pointer;
}
.seg button.on { color: var(--ink); font-weight: 700; }
.seg button.on::after {
  content: ""; position: absolute; inset: -4px -12px;
  border: 2.2px solid var(--accent);
  border-radius: 46% 54% 50% 50% / 58% 46% 54% 42%;
  transform: rotate(-2deg);
}

/* ===== 結果（診断書） ===== */
.result { display: none; }
.result.show { display: block; animation: rise 0.35s cubic-bezier(0.16, 1, 0.3, 1); }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .result.show { animation: none; }
  html { scroll-behavior: auto; }
}
.result-hero {
  position: relative;
  border-top: 1.5px solid var(--ink);
  padding: 22px 4px 8px 4px; margin: 26px 0 12px;
  text-align: left;
}
.result-hero .label { font-size: 12.5px; color: var(--ink-2); font-weight: 500; letter-spacing: 0.08em; }
.result-hero .value {
  font-family: var(--serif); font-size: 52px; font-weight: 800; color: var(--ink);
  line-height: 1.25; font-variant-numeric: tabular-nums; letter-spacing: 0.01em;
}
.result-hero .sub { font-size: 12.5px; color: var(--ink-2); }
.stamp { position: absolute; top: 8px; right: 2px; transform: rotate(-11deg); opacity: 0.92; pointer-events: none; }

/* 明細行 */
.meisai { margin: 4px 0; }
.meisai .m-row { display: flex; align-items: baseline; gap: 10px; padding: 9px 2px; font-size: 13.5px; }
.meisai .m-row .m-label { color: var(--ink-2); font-weight: 500; white-space: nowrap; }
.meisai .m-row .m-dots { flex: 1; border-bottom: 1px dotted var(--line-strong); transform: translateY(-4px); }
.meisai .m-row .m-value { font-family: var(--serif); font-weight: 700; font-size: 15px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.meisai .m-row.m-total { border-top: 1.5px solid var(--ink); margin-top: 6px; padding-top: 13px; }
.meisai .m-row.m-total .m-label { font-weight: 700; color: var(--ink); }
.meisai .m-row.m-total .m-value { font-weight: 800; font-size: 16.5px; }

/* 結果アクション */
.result-actions { display: flex; gap: 10px; margin: 18px 0 2px; }
.btn-sub {
  flex: 1; padding: 12px; font-size: 13px;
  font-family: var(--serif); font-weight: 700; letter-spacing: 0.18em;
  color: var(--ink); background: var(--card); border: 1.5px solid var(--ink);
  border-radius: 0; cursor: pointer; text-align: center;
  transition: background 0.15s ease;
}
.btn-sub:hover { background: var(--paper); text-decoration: none; }
.btn-sub:active { transform: translateY(1px); }

.note { font-size: 12px; color: var(--ink-3); margin-top: 12px; line-height: 1.8; }

/* ===== テーブル ===== */
table.breakdown { width: 100%; border-collapse: collapse; font-size: 13.5px; background: var(--card); border: 1px solid var(--line); }
table.breakdown th, table.breakdown td { padding: 10px 12px; text-align: left; }
table.breakdown thead th, table.breakdown tr:first-child th { background: #f4efe6; font-size: 12px; color: var(--ink-2); letter-spacing: 0.06em; }
table.breakdown tbody tr, table.breakdown tr { border-top: 1px solid var(--line); }
table.breakdown tr:first-child { border-top: none; }
table.breakdown td.num, table.breakdown th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; font-family: var(--serif); font-weight: 700; }
table.breakdown th.num { font-family: var(--gothic); font-weight: 700; }
table.breakdown tr.total { font-weight: 700; background: #f4efe6; }

/* ===== ファーストビュー ===== */
.fv { margin: 10px 0 18px; position: relative; }
.fv-title { font-size: 36px; line-height: 1.45; letter-spacing: 0.04em; }
.fv-eyebrow {
  font-family: var(--serif); font-weight: 700; font-size: 12px;
  letter-spacing: 0.3em; color: var(--accent); margin-bottom: 12px;
}
.fv-ghost {
  position: absolute; top: -14px; right: -4px;
  writing-mode: vertical-rl;
  font-family: var(--serif); font-weight: 800; font-size: 64px;
  letter-spacing: 0.18em; color: rgba(34, 29, 22, 0.06);
  line-height: 1; pointer-events: none; user-select: none;
}
@media (max-width: 560px) { .fv-title { font-size: 29px; } .fv-ghost { font-size: 52px; } }

/* フラッグシップ（記入欄） */
.card.flagship { border: 1px solid var(--line); }
.flag-head { display: flex; align-items: center; gap: 9px; margin-bottom: 16px; }
.flag-head .badge {
  background: var(--accent); color: var(--paper); font-family: var(--serif);
  font-size: 10.5px; font-weight: 700; letter-spacing: 0.2em;
  padding: 2px 10px 2px 12px; white-space: nowrap;
}
.flag-head .t { font-weight: 700; font-size: 13px; color: var(--ink-2); }

/* ===== ツールカード（漢字チップ） ===== */
.tool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 10px; margin: 16px 0; }
.tool-card {
  display: flex; gap: 13px; align-items: flex-start;
  background: var(--card); border: 1px solid var(--line);
  padding: 15px 16px; color: var(--ink);
  transition: border-color 0.15s ease;
}
.tool-card:hover { border-color: var(--accent); text-decoration: none; }
.chip-kanji {
  flex: none; width: 40px; height: 40px;
  background: transparent; color: var(--accent-dark);
  border: 1px solid var(--accent);
  display: grid; place-items: center;
  font-family: var(--serif); font-size: 13px; font-weight: 700;
  letter-spacing: 0.05em; line-height: 1.15; text-align: center;
}
.tool-card .t { font-family: var(--serif); font-weight: 700; font-size: 14.5px; color: var(--ink); line-height: 1.5; }
.tool-card .d { font-size: 12px; color: var(--ink-2); margin-top: 3px; line-height: 1.7; }

/* 他の計算機ストリップ */
.tools-strip { display: flex; flex-wrap: wrap; gap: 7px; margin: 14px 0; }
.tools-strip a {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 12px; font-weight: 600; color: var(--ink-2);
  padding: 6px 12px 6px 7px; background: var(--card);
  border: 1px solid var(--line); white-space: nowrap;
}
.tools-strip a .k {
  width: 21px; height: 21px; border: 1px solid var(--accent);
  color: var(--accent-dark); display: grid; place-items: center;
  font-family: var(--serif); font-size: 9.5px; font-weight: 700;
}
.tools-strip a:hover { border-color: var(--accent); color: var(--accent-dark); text-decoration: none; }
.tools-strip a.current { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.tools-strip a.current .k { border-color: var(--accent); color: var(--paper); background: var(--accent); }

/* ===== リンク群 ===== */
.link-cloud { display: flex; flex-wrap: wrap; gap: 7px; margin: 14px 0; }
.link-cloud a {
  font-size: 12.5px; font-weight: 500; padding: 5px 12px; background: var(--card);
  border: 1px solid var(--line); color: var(--ink-2);
  white-space: nowrap; font-variant-numeric: tabular-nums;
}
.link-cloud a:hover { border-color: var(--accent); color: var(--accent-dark); text-decoration: none; }
.link-cloud a.current { background: var(--ink); color: var(--paper); border-color: var(--ink); }

/* ===== 記事 ===== */
.article-body { font-size: 15px; }
.article-body p { margin: 0 0 1.3em; }
.article-body table { width: 100%; border-collapse: collapse; font-size: 13.5px; margin: 16px 0; background: var(--card); }
.article-body th, .article-body td { padding: 9px 11px; border: 1px solid var(--line); }
.article-body th { background: #f4efe6; font-size: 12.5px; }
.article-meta { font-size: 12px; color: var(--faint); margin-bottom: 22px; letter-spacing: 0.04em; }
.article-list { list-style: none; padding: 0; margin: 14px 0; display: grid; gap: 9px; }
.article-list li { background: var(--card); border: 1px solid var(--line); transition: border-color 0.15s ease; }
.article-list li:hover { border-color: var(--accent); }
.article-list a { display: block; padding: 14px 17px; color: var(--ink); }
.article-list a:hover { text-decoration: none; }
.article-list .t { font-family: var(--serif); font-weight: 700; font-size: 14px; line-height: 1.7; }
.article-list .d { font-size: 12px; color: var(--ink-2); margin-top: 3px; line-height: 1.7; }

/* 続けて読む記事（static/chain.js） */
.chain-sep { display: flex; align-items: center; gap: 14px; margin: 64px 0 34px; }
.chain-sep::before, .chain-sep::after { content: ""; flex: 1; border-top: 1.5px solid var(--ink); }
.chain-sep span {
  background: var(--accent); color: var(--paper);
  font-family: var(--serif); font-size: 11px; font-weight: 700; letter-spacing: 0.3em; padding: 2px 10px 2px 13px;
}
.chain-status { margin: 34px 0 0; text-align: center; font-size: 12.5px; color: var(--faint); letter-spacing: 0.04em; }
.chain-status:empty { margin: 0; }
.chain-more { display: block; max-width: 320px; margin: 0 auto; }

/* ===== CTA・FAQ・広告枠・参考資料 ===== */
.cta {
  border: 1px solid var(--accent); background: var(--card);
  padding: 15px 18px; margin: 26px 0; font-size: 13.5px; position: relative;
}
.cta::before {
  content: "次の一手"; position: absolute; top: -9px; left: 12px;
  background: var(--accent); color: var(--paper);
  font-family: var(--serif); font-size: 10px; letter-spacing: 0.3em; padding: 1px 8px 1px 10px;
}
.cta a { font-weight: 700; }
.ad-slot:empty, .affi-slot:empty { display: none; }
.ad-slot, .affi-slot { margin: 26px 0; text-align: center; }
.faq dt { font-family: var(--serif); font-weight: 700; margin: 20px 0 4px; font-size: 14.5px; }
.faq dd { margin: 0 0 12px; color: var(--ink-2); font-size: 14px; }
.refs { font-size: 12.5px; color: var(--ink-2); background: var(--card); border: 1px solid var(--line); padding: 14px 18px; margin: 18px 0; }
.refs .t { font-family: var(--serif); font-weight: 700; font-size: 12.5px; margin-bottom: 4px; color: var(--ink); letter-spacing: 0.1em; }
.refs a { display: inline-block; margin-right: 14px; }

/* ===== サマリータイル・タイムライン ===== */
.sum3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 16px 0; }
.sum3 .s { background: var(--card); border: 1px solid var(--line); padding: 12px 10px; text-align: center; }
.sum3 .s .k { font-size: 10.5px; color: var(--ink-3); font-weight: 700; line-height: 1.5; letter-spacing: 0.04em; }
.sum3 .s .v { font-family: var(--serif); font-size: 18px; font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums; line-height: 1.5; margin-top: 2px; }
.sum3 .s .v small { font-size: 10.5px; font-weight: 600; color: var(--ink-3); }
@media (max-width: 560px) { .sum3 { gap: 6px; } .sum3 .s { padding: 10px 6px; } }

.timeline { margin: 16px 0 6px; }
.tl-row { display: grid; grid-template-columns: 62px 1fr; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px dotted var(--line-strong); }
.tl-row:last-child { border-bottom: none; }
.tl-m { font-size: 11px; font-weight: 700; color: var(--ink-2); white-space: nowrap; }
.tl-flow { font-size: 12px; color: var(--ink-2); display: flex; flex-wrap: wrap; gap: 4px 10px; font-variant-numeric: tabular-nums; }
.tl-flow .in { color: var(--accent-dark); font-weight: 700; }
.tl-bal-line { display: flex; align-items: center; gap: 8px; margin-top: 3px; }
.tl-bar { flex: 1; height: 8px; background: var(--track); overflow: hidden; }
.tl-bar span { display: block; height: 100%; background: var(--ink); }
.tl-bal { font-family: var(--serif); font-size: 12.5px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; color: var(--ink); }
.tl-row.neg .tl-bal { color: var(--accent); }
.tl-row.neg .tl-bar { background: #f4ded9; }
.tl-row.neg .tl-bar span { background: var(--accent); }

/* 注意（朱枠） */
.danger-note {
  background: var(--card); border: 1px solid var(--accent);
  padding: 14px 15px 12px 15px; font-size: 12.5px; color: var(--ink-2);
  margin: 14px 0; font-weight: 500; line-height: 1.9; position: relative;
}
.danger-note::before {
  content: "注意"; position: absolute; top: -9px; left: 12px;
  background: var(--accent); color: var(--paper);
  font-family: var(--serif); font-size: 10px; letter-spacing: 0.3em; padding: 1px 8px 1px 10px;
}

/* ===== フッター ===== */
.site-footer { border-top: 1px solid var(--line); background: var(--card); margin-top: 52px; }
.site-footer .inner { max-width: var(--maxw); margin: 0 auto; padding: 28px 16px 34px; font-size: 12.5px; color: var(--faint); }
.site-footer .cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 18px 24px; margin-bottom: 18px; }
.site-footer .cols .h { font-family: var(--serif); font-weight: 700; font-size: 11.5px; color: var(--ink-2); margin-bottom: 8px; letter-spacing: 0.2em; }
.site-footer .cols a { display: block; color: var(--ink-2); padding: 3px 0; font-size: 12.5px; }
.site-footer .legal { border-top: 1px solid var(--line); padding-top: 14px; line-height: 1.9; }

@media (max-width: 560px) {
  h1 { font-size: 22px; }
  h2 { font-size: 15px; letter-spacing: 0.2em; }
  main { padding: 20px 14px 56px; }
  .card { padding: 24px 15px 20px 15px; }
  .btn { padding: 16px; }
  .gnav a { padding: 5px 6px; font-size: 12px; }
  .result-hero .value { font-size: 42px; }
  .meisai .m-row .m-label { white-space: normal; line-height: 1.5; }
  .meisai .m-row { align-items: flex-end; }
}

/* ===== ダイヤル入力（目盛りテープ） ===== */
.dial-box { position: relative; margin-top: 8px; }
.dial {
  overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scrollbar-width: none; -ms-overflow-style: none;
  cursor: ew-resize;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 14%, #000 86%, transparent);
  mask-image: linear-gradient(to right, transparent, #000 14%, #000 86%, transparent);
}
.dial::-webkit-scrollbar { display: none; }
.dial-strip {
  display: flex;
  height: 50px;
  align-items: flex-end;
}
.dial-pad {
  flex: 0 0 50%;
  height: 1px;
}
.dt { flex: none; width: 14px; height: 36px; scroll-snap-align: center; position: relative; }
.dt::before {
  content: ""; position: absolute; left: 50%; bottom: 15px;
  width: 1px; height: 11px; background: rgba(34, 29, 22, 0.26);
}
.dt.major::before { height: 21px; width: 1.5px; background: rgba(34, 29, 22, 0.55); }
.dt.major::after {
  content: attr(data-l); position: absolute; bottom: -1px; left: 50%; transform: translateX(-50%);
  font-size: 9.5px; color: var(--faint); font-weight: 600; font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.dial-needle {
  position: absolute; left: 50%; top: 1px; height: 38px; width: 2px;
  background: var(--accent); transform: translateX(-50%); pointer-events: none;
}
.dial-needle::before {
  content: ""; position: absolute; top: -2px; left: 50%;
  transform: translateX(-50%) rotate(45deg);
  width: 6px; height: 6px; background: var(--accent);
}
input.dialing { color: var(--accent); transition: color 0.12s ease; }

/* ダイヤルがグリッド列を押し広げないように（min-width:autoの罠） */
.calc-form > *, .row2 > *, .field { min-width: 0; }
.dial { width: 100%; }

/* ===== 全体ブラッシュアップ ===== */
/* number入力のスピナーを消す（ダイヤルがあるため不要） */
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
input[type="number"] { -moz-appearance: textfield; appearance: textfield; }

/* 記事内の長文h2は字間を締めて読みやすく */
.article-body h2 { letter-spacing: 0.06em; }

/* FVを詰めて1画面目にダイヤルを入れる */
.fv { margin: 6px 0 14px; }
.lead-fv { margin-bottom: 4px; }
.flag-head { margin-bottom: 12px; }

/* 結果の前提条件行（スクショに条件が写るように） */
.r-cond { font-size: 11px; color: var(--faint); margin-top: 8px; letter-spacing: 0.02em; line-height: 1.7; }

/* 結果のブランド行（スクショが広告になる） */
.result-brand {
  display: flex; justify-content: flex-end; align-items: center; gap: 6px;
  font-size: 10.5px; color: var(--faint); letter-spacing: 0.08em; margin-top: 10px;
}
.result-brand .k {
  width: 15px; height: 15px; background: var(--accent); color: var(--paper);
  font-family: var(--serif); font-weight: 700; font-size: 9px;
  display: grid; place-items: center;
}

/* 結果アクション3つ並び（スマホで窮屈にならないように） */
.result-actions { flex-wrap: wrap; }
.result-actions .btn-sub { min-width: 100px; padding: 12px 8px; letter-spacing: 0.1em; }

/* ===== 退職届ジェネレーター（縦書きA4シート） ===== */
.sheet-wrap { overflow: hidden; margin: 0 0 18px; }
.sheet {
  width: 794px; height: 1123px;
  background: #ffffff;
  border: 1px solid var(--line);
  box-sizing: border-box;
  padding: 90px 70px;
  writing-mode: vertical-rl;
  font-family: var(--serif);
  color: #1a1712;
  transform-origin: top left;
  display: flex;
  flex-direction: column; /* 縦書きでは column = 右→左の列並び */
  justify-content: space-between;
}
.s-title {
  font-size: 34px; font-weight: 700; letter-spacing: 0.5em;
  margin-left: 46px; text-align: center; align-self: center;
}
.s-col { line-height: 2.4; }
.s-body { margin-left: 34px; }
.s-giki { text-align: end; font-size: 18px; margin-left: 26px; }
.s-text { font-size: 18px; letter-spacing: 0.12em; max-height: 820px; }
.s-date { font-size: 17px; margin-left: 30px; }
.s-sign { font-size: 18px; text-align: end; margin-left: 30px; letter-spacing: 0.1em; }
.s-in {
  display: inline-grid; place-items: center;
  width: 26px; height: 26px; border: 1.5px solid #c73e2e; border-radius: 999px;
  color: #c73e2e; font-size: 12px; margin-block-start: 6px;
}
.s-to { font-size: 18px; letter-spacing: 0.08em; }

@media print {
  .site-header, .site-footer, .no-print { display: none !important; }
  body { background: #ffffff; }
  main { max-width: none; padding: 0; margin: 0; }
  .sheet-wrap { height: auto !important; overflow: visible; margin: 0; }
  .sheet { transform: none !important; border: none; width: auto; height: auto; padding: 60px 50px; }
  @page { size: A4 portrait; margin: 0; }
}

/* 列の多い表（前年比較・計算方法ページ）: スマホでは表だけ横スクロール */
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 0 4px; }
table.breakdown.compact { font-size: 12.5px; }
table.breakdown.compact th, table.breakdown.compact td { padding: 8px 9px; }
.source-list { font-size: 13px; line-height: 1.8; padding-left: 1.2em; }
.source-list li { margin: 4px 0; }
.source-list .covers { display: block; color: var(--ink-3); font-size: 12px; }
table.breakdown.compact th, table.breakdown.compact td:first-child { white-space: nowrap; }

/* ページの挿絵（木版画風イラスト） */
.illust { margin: 28px 0 8px; }
.illust img { display: block; width: 100%; height: auto; border: 1px solid var(--line); background: var(--card); }

.illust-top { margin: 0 0 22px; }
.article-list a.has-thumb { display: grid; grid-template-columns: 132px 1fr; gap: 14px; align-items: center; }
.article-list .thumb { width: 132px; height: auto; aspect-ratio: 16 / 9; object-fit: cover; border: 1px solid var(--line); }
@media (max-width: 480px) { .article-list a.has-thumb { grid-template-columns: 96px 1fr; gap: 11px; } .article-list .thumb { width: 96px; } }

/* 追加入力の折りたたみ */
details.more-inputs { margin: 6px 0 14px; border-top: 1px dashed var(--line); padding-top: 10px; }
details.more-inputs summary { cursor: pointer; font-size: 13px; color: var(--accent); font-weight: 700; margin-bottom: 10px; }
