/* サンプル「契約書の台帳づくり」専用の見た目。請求書のサンプルの sample-invoice.css を写して接頭辞を ct- に替え、法律の助言ではない旨の帯・台帳の欄・条項の見出しの形を足した。色と書体は main.css の変数を使う */
.ct-page {
  --ct-head: 73px;
  --ct-sans: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic UI", "Yu Gothic", Meiryo, "Noto Sans JP", sans-serif;
  --ct-unsure-ink: #92400E; --ct-unsure-bg: #FEF3C7;
  --ct-sku-ink: #991B1B; --ct-sku-bg: #FEE2E2;
  --ct-over-ink: #9A3412; --ct-over-bg: #FFEDD5;
  --ct-ok-ink: #115E59; --ct-ok-bg: #CCFBF1;
  --ct-muted: #475569;
}
.ct-page *:focus-visible { outline: 3px solid var(--cp-accent); outline-offset: 2px; }
.ct-page p { margin: 0; }
:where(.ct-page) :where(button, input) { font: inherit; color: inherit; }
html:has(#ct-app :focus-visible) { scroll-padding-top: 9.75rem; }
html:has(.ct-finish.is-ready) { scroll-padding-bottom: 8rem; }
.skip-link { top: -5rem; }
.ct-wrap { max-width: var(--container); margin-inline: auto; padding-inline: var(--pad-x); width: 100%; }
.ct-vh { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }

/* トップの「たとえば」節の部品（index.html の #can から写す） */
.can-eyebrow { display: flex; align-items: center; justify-content: center; gap: clamp(.5rem, 2vw, .75rem); word-break: auto-phrase; margin: 0 0 1rem !important; font-size: .85rem; font-weight: 600; letter-spacing: .16em; color: var(--cp-primary); text-align: center; }
.can-eyebrow::before, .can-eyebrow::after { content: ""; display: inline-block; flex: none; width: clamp(1rem, 5vw, 2rem); height: 1.5px; background: var(--cp-accent); }
.can-title { font-size: clamp(1.7rem, 3.2vw, 2.8rem); color: var(--cp-primary); line-height: 1.45; text-wrap: balance; word-break: auto-phrase; text-align: center; }
.can-title::after { content: ""; display: block; width: 64px; height: 2px; margin: 1.1rem auto 0; background: var(--cp-accent); }
.can-card__no { display: grid; place-items: center; min-width: 2.6rem; height: 2.6rem; padding: 0 .5rem; background: var(--cp-navy-deep); color: #fff; font-family: var(--ff-display); font-size: 1rem; font-weight: 600; letter-spacing: .06em; border-bottom: 2px solid var(--cp-accent); flex: none; }

/* プライバシーポリシーと同じヘッダーの戻るリンクとフッター */
.policy-header__back { display: inline-flex; align-items: center; min-height: 44px; margin-block: -4px; font-size: 0.92rem; font-weight: 600; letter-spacing: 0.04em; color: var(--cp-primary); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .35em; white-space: nowrap; }
.policy-header__back:hover { color: var(--cp-navy-deep); }
.policy-footer .site-footer__inner { grid-template-columns: 1.2fr 1fr 1.1fr; }

/* 説明 */
.ct-intro { padding: clamp(1.75rem, 4vw, 3.25rem) 0 clamp(1.75rem, 3.5vw, 2.5rem); background: radial-gradient(60rem 30rem at 85% -5%, color-mix(in oklab, var(--cp-accent) 12%, transparent), transparent 70%), linear-gradient(180deg, var(--cp-white) 0%, var(--cp-bg) 100%); }
.ct-hero { display: grid; grid-template-columns: minmax(0, 11fr) minmax(0, 10fr); gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center; }
.ct-hero .can-eyebrow { justify-content: flex-start; }
.ct-hero .can-eyebrow::before { display: none; }
.ct-hero .can-title { text-align: left; font-size: clamp(1.7rem, 2.9vw, 2.45rem); }
.ct-hero .can-title::after { margin-left: 0; }
.ct-lead { margin: 1.1rem 0 0 !important; font-size: 1.02rem; line-height: 1.9; text-wrap: pretty; }
.ct-lead-act { margin-top: 1.25rem !important; }
.ct-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .75rem 1.25rem; margin: clamp(1.25rem, 3vw, 2rem) 0 0; padding-top: .9rem; border-top: 1px solid var(--cp-line); }
.ct-step { display: flex; align-items: baseline; gap: .55rem; }
.ct-step__no { flex: none; font-family: var(--ff-display); font-size: .95rem; font-weight: 600; letter-spacing: .06em; color: var(--cp-accent-ink); }
.ct-step__text { font-size: .95rem; font-weight: 600; line-height: 1.6; color: var(--cp-text); word-break: auto-phrase; }
.ct-note { margin-top: clamp(1rem, 2.5vw, 1.5rem); padding: .9rem 1.25rem 1rem; background: var(--cp-white); border: 1px solid var(--cp-line); border-radius: 2px; }
.ct-note__title { font-size: .98rem; color: var(--cp-primary); margin-bottom: .45rem; }
.ct-note__list { list-style: disc; padding-left: 1.3em; }
.ct-note__list li { font-size: .92rem; line-height: 1.75; margin-bottom: .2em; overflow-wrap: anywhere; }
.ct-note__list li::marker { color: var(--cp-primary); }
.ct-run { margin-top: .55rem !important; font-size: .82rem; line-height: 1.6; color: var(--ct-muted); font-family: var(--ct-sans); }

/* 触ってみる */
.ct-tool { padding: clamp(1.75rem, 4vw, 3rem) 0 clamp(2.5rem, 5vw, 4rem); background: var(--cp-cream); border-top: 1px solid var(--cp-line); border-bottom: 1px solid var(--cp-line); }
.ct-tool__title { font-size: clamp(1.35rem, 2.6vw, 1.8rem); color: var(--cp-primary); }
.ct-tool__lead { margin-top: .25rem !important; font-size: .98rem; color: var(--cp-text); }
.ct-tool__notice { margin-top: .5rem; padding: .6rem .85rem; background: #FEF2F2; border-left: 4px solid #B91C1C; font-size: .9rem; line-height: 1.7; color: var(--cp-text); overflow-wrap: anywhere; }
.ct-tool__notice p + p { margin-top: .25rem; }
.ct-noscript { margin-top: 1rem !important; padding: 1rem; background: var(--cp-white); border: 1px solid var(--cp-line); }
.ct-app { margin-top: 1rem; }

/* 依頼を選ぶ */
.ct-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .5rem; }
.ct-tab { display: flex; flex-direction: column; gap: .1rem; min-height: 44px; padding: .6rem .9rem; text-align: left; background: var(--cp-white); border: 1px solid var(--cp-line); border-bottom: 3px solid var(--cp-line); border-radius: 2px; cursor: pointer; line-height: 1.5; transition: border-color .2s ease, background-color .2s ease; }
.ct-tab:hover { border-bottom-color: var(--cp-accent); }
.ct-tab[aria-selected="true"] { background: var(--cp-navy-deep); border-color: var(--cp-navy-deep); border-bottom-color: var(--cp-accent); color: #fff; }
.ct-tab__label { font-weight: 600; font-size: .95rem; word-break: auto-phrase; }
.ct-tab__who { font-size: .82rem; color: var(--ct-muted); min-width: 0; overflow-wrap: anywhere; }
.ct-tab[aria-selected="true"] .ct-tab__who { color: #cbd5e1; }
.ct-tab__state { font-size: .86rem; font-weight: 600; color: var(--cp-accent-ink); font-family: var(--ct-sans); }
.ct-tab[aria-selected="true"] .ct-tab__state { color: #bfdbfe; }

.ct-panel { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(1rem, 2.5vw, 2rem); align-items: start; margin-top: 1rem; }

/* 左: 届いた依頼 */
.ct-srccol { position: sticky; top: calc(var(--ct-head) + .75rem); background: var(--cp-white); border: 1px solid var(--cp-line); border-radius: 2px; box-shadow: var(--cp-shadow); padding: .75rem; }
.ct-srccol__head { display: flex; align-items: center; justify-content: space-between; gap: .75rem; margin-bottom: .6rem; }
.ct-srccol__title { font-size: 1.02rem; color: var(--cp-primary); }
/* 見出しが長いときは、ボタンを縮めず見出しの字の側を折る（幅 901px 付近でボタンの左右の余白が潰れないように） */
.ct-srccol__head .ct-btn { flex-shrink: 0; }
.ct-sheet { position: relative; margin-inline: auto; width: min(100%, calc((100vh - var(--ct-head) - 6.5rem) * var(--ct-ratio, 0.7546))); box-shadow: 0 0 0 1px var(--cp-line); cursor: zoom-in; background: #fff; }
.ct-sheet img { display: block; width: 100%; height: 100%; max-width: none; }
.ct-hit { position: absolute; border: 3px solid var(--cp-accent); border-radius: 2px; pointer-events: none; box-sizing: content-box; transform: translate(-3px, -3px); }

/* 右: 見積の下書き */
.ct-count { position: sticky; top: var(--ct-head); z-index: 5; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0 1rem; padding: .55rem 1rem; background: var(--cp-navy-deep); color: #fff; border-bottom: 2px solid var(--cp-accent); border-radius: 2px; }
.ct-count__main { display: flex; align-items: baseline; gap: .4rem; min-width: 0; white-space: nowrap; font-weight: 600; font-size: 1rem; }
.ct-count__num { font-family: var(--ct-sans); font-size: 2.1rem; font-weight: 700; line-height: 1.1; color: #fff; }
/* 帯は 2 行まで。相手の名前は 1 行に収め、人が長い名前を打ったときは終わりを省く（全部の名前はすぐ下の行で読める） */
.ct-count__sub { min-width: 0; max-width: 100%; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: .92rem; color: #cbd5e1; }
.ct-count__sub b { font-family: var(--ct-sans); font-size: 1.15rem; color: #fff; font-weight: 700; }
.ct-prior { margin-top: .35rem !important; font-size: .9rem; color: var(--cp-text); line-height: 1.7; }

.ct-head { margin-top: .75rem; padding: .7rem .9rem; background: var(--cp-white); border: 1px solid var(--cp-line); border-radius: 2px; }
.ct-head__row { display: flex; justify-content: space-between; align-items: flex-start; gap: .75rem; }
.ct-head__dl { flex: 1 1 0; min-width: 0; display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: .1rem .9rem; margin: 0; font-size: .92rem; line-height: 1.7; }
.ct-head__dl dt { color: var(--ct-muted); }
.ct-head__dl dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }

.ct-list { display: grid; grid-template-columns: minmax(0, 1fr); gap: .6rem; margin-top: .75rem; }
.ct-rowitem { position: relative; background: var(--cp-white); border: 1px solid var(--cp-line); border-radius: 2px; padding: .6rem .9rem; }
.ct-rowitem.has-marks { border-left: 4px solid var(--cp-primary); box-shadow: var(--cp-shadow); padding: .8rem .95rem .95rem; }
.ct-rowitem.is-done { border-left: 4px solid var(--ct-ok-ink); }
/* 直した行を、少しの間だけ色で知らせる */
.is-just-fixed { animation: ct-fixed 2s ease-out; }
@keyframes ct-fixed { 0%, 35% { background-color: var(--ct-ok-bg); } 100% { background-color: var(--cp-white); } }
.ct-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: .5rem .75rem; }
.ct-row__data { display: flex; flex-wrap: wrap; align-items: baseline; gap: .1rem .75rem; min-width: 0; }
.ct-name { font-weight: 600; font-size: 1rem; overflow-wrap: anywhere; }
.ct-diff { margin-top: .25rem !important; font-size: .82rem; color: var(--ct-ok-ink); line-height: 1.6; font-family: var(--ct-sans); overflow-wrap: anywhere; }
.ct-tags { display: flex; flex-wrap: wrap; gap: .3rem .4rem; }
.ct-rowitem .ct-tags--row, .ct-head .ct-tags--row { margin-top: .3rem; align-items: center; }
.ct-tags--row .ct-link { min-height: 44px; margin-left: .3rem; }

.ct-tag { display: inline-flex; align-items: center; gap: .3rem; padding: .1rem .55rem; font-family: var(--ct-sans); font-size: 13px; font-weight: 700; line-height: 1.6; border: 1px solid currentColor; border-radius: 2px; }
.ct-tag svg { width: .85rem; height: .85rem; flex: none; }
.ct-tag--unsure { color: var(--ct-unsure-ink); background: var(--ct-unsure-bg); }
.ct-tag--ok { color: var(--ct-ok-ink); background: var(--ct-ok-bg); }
.ct-by { font-size: .84rem; color: var(--ct-muted); font-family: var(--ct-sans); align-self: center; }

/* 確かめる所 */
.ct-block { margin-top: .8rem; padding-top: .8rem; border-top: 1px dashed var(--cp-line); scroll-margin: 8rem; }
.ct-block__top { display: flex; align-items: center; justify-content: space-between; gap: .75rem; margin-top: .1rem; }
.ct-block__field { font-size: .92rem; font-weight: 600; color: var(--cp-primary); }
/* border を付けると内側の縦横比がずれて切り抜きが動くので、枠は box-shadow で描く */
.ct-crop { position: relative; overflow: hidden; margin: .5rem 1px 1px; background: #fff; box-shadow: 0 0 0 1px var(--cp-muted); max-width: calc(100% - 2px); }
.ct-crop img { position: absolute; max-width: none; height: auto; }
/* かすれの切り抜きは、FAX の点の集まりが字に見えるように少しなめらかにする。画像そのものは変えない */
.ct-crop--tight img { filter: blur(1.1px) contrast(1.5); }
/* スマホの幅で字が読める大きさにした切り抜き。入りきらない分は横に動かして見る */
.ct-cropscroll { overflow-x: auto; margin: .5rem 0 0; padding: 0 1px 1px; -webkit-overflow-scrolling: touch; }
.ct-cropscroll .ct-crop--wide { max-width: none; margin-top: 0; }
.ct-cropscroll:focus-visible { outline: 3px solid var(--cp-primary); outline-offset: 2px; }
.ct-say { margin-top: .5rem !important; font-size: .95rem; line-height: 1.75; overflow-wrap: anywhere; }
.ct-say b { font-family: var(--ct-sans); font-weight: 700; }
.ct-why { margin-top: .15rem !important; font-size: .9rem; color: var(--ct-muted); line-height: 1.7; overflow-wrap: anywhere; font-family: var(--ct-sans); }
.ct-group-label { margin-top: .6rem !important; font-size: .88rem; font-weight: 600; color: var(--cp-text); }
.ct-choices { display: grid; gap: .4rem; margin-top: .35rem; }
.ct-choices--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ct-btn { display: inline-flex; align-items: center; justify-content: center; gap: .5em; min-width: 0; overflow-wrap: anywhere; min-height: 44px; padding: .45rem .95rem; font-weight: 600; font-size: .95rem; line-height: 1.5; letter-spacing: .02em; border-radius: 2px; border: 1.5px solid var(--cp-primary); background: var(--cp-white); color: var(--cp-primary); cursor: pointer; transition: background-color .2s ease, color .2s ease; }
.ct-btn--primary { background: var(--cp-primary); color: #fff; }
.ct-btn--quiet { border-color: var(--cp-line); color: var(--cp-text); font-weight: 500; }
/* タッチの端末で押したあとに濃い色が残らないように */
@media (hover: hover) {
  .ct-btn:hover { background: var(--cp-primary); color: #fff; }
  .ct-btn--primary:hover { background: var(--cp-navy-deep); border-color: var(--cp-navy-deep); }
  .ct-btn--quiet:hover { background: var(--cp-cream); color: var(--cp-text); border-color: var(--cp-muted); }
}
.ct-btn--small { padding-inline: .7rem; font-size: .88rem; white-space: nowrap; }
.ct-btn:disabled, .ct-btn:disabled:hover { background: var(--cp-line); border-color: var(--cp-line); color: var(--ct-muted); cursor: not-allowed; }
.ct-type { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .4rem; margin-top: .35rem; }
.ct-input { width: 100%; min-height: 44px; padding: .4rem .65rem; font-family: var(--ct-sans); font-size: 16px; line-height: 1.4; background: #fff; border: 1.5px solid var(--cp-muted); border-radius: 2px; }
.ct-input[aria-invalid="true"] { border-color: var(--ct-sku-ink); }
.ct-err { margin-top: .3rem !important; font-size: .88rem; font-weight: 600; color: var(--ct-sku-ink); }
.ct-tools { display: flex; flex-wrap: wrap; gap: .3rem .9rem; margin-top: .4rem; }
.ct-link { display: inline-flex; align-items: center; min-height: 44px; padding: 0; background: none; border: 0; color: var(--cp-primary); font-size: .9rem; font-weight: 600; text-decoration: underline; text-underline-offset: .2em; cursor: pointer; }
.ct-link:hover { color: var(--cp-navy-deep); }
.ct-block__top .ct-link { flex: none; white-space: nowrap; }
.ct-nowrap { white-space: nowrap; }

/* 行を直す */
.ct-editor { margin-top: .7rem; padding-top: .7rem; border-top: 1px dashed var(--cp-line); }
.ct-editor__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .55rem .75rem; margin-top: .5rem; }
.ct-editor__field label { display: block; font-size: .86rem; font-weight: 600; margin-bottom: .15rem; }
.ct-editor__field--wide { grid-column: 1 / -1; }
.ct-editor__actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .7rem; }

/* 確定 */
.ct-finish { margin-top: .9rem; padding: .9rem 1rem 1rem; background: var(--cp-white); border: 1px solid var(--cp-line); border-top: 3px solid var(--cp-accent); border-radius: 2px; }
.ct-finish.is-ready { position: sticky; bottom: 0; z-index: 4; box-shadow: 0 -6px 18px rgba(15, 23, 42, .12); }
.ct-finish__msg { font-size: .95rem; line-height: 1.75; margin-bottom: .6rem !important; text-wrap: pretty; }
.ct-finish .ct-btn--primary { width: 100%; min-height: 50px; font-size: 1.02rem; }
.ct-done__title { font-size: 1.3rem; color: var(--cp-primary); }
.ct-done__title:focus { outline: none; }
.ct-done__lead { margin-top: .35rem !important; font-size: .95rem; line-height: 1.75; }
.ct-tablewrap { overflow-x: auto; margin-top: .75rem; background: var(--cp-white); border: 1px solid var(--cp-line); -webkit-overflow-scrolling: touch; }
.ct-table { width: 100%; border-collapse: collapse; font-size: .92rem; line-height: 1.6; font-family: var(--ct-sans); }
.ct-table th, .ct-table td { padding: .55rem .6rem; border-bottom: 1px solid var(--cp-line); text-align: left; vertical-align: top; overflow-wrap: anywhere; }
.ct-table thead th { background: var(--cp-cream); color: var(--cp-text); font-size: .82rem; font-weight: 700; white-space: nowrap; }
.ct-table tr:last-child td { border-bottom: 0; }
.ct-table .is-num { text-align: right; white-space: nowrap; }
.ct-tnote { display: block; font-size: .92em; color: var(--ct-muted); }
.ct-done__actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .85rem; }
.ct-done__actions .ct-btn--primary { flex: 1 1 100%; min-height: 50px; font-size: 1.02rem; }
.ct-done__saved { margin-top: .5rem !important; font-size: .9rem; color: var(--ct-ok-ink); font-weight: 600; font-family: var(--ct-sans); overflow-wrap: anywhere; }
.ct-reset { margin-top: 1rem; text-align: right; }

/* 照らし合わせの結果の形 */
.ct-paper { position: relative; margin-top: .75rem; padding: .9rem 1rem 1rem; background: #fff; border: 1px solid var(--cp-line); font-family: var(--ct-sans); }
.ct-paper__mark { position: absolute; right: .75rem; top: .75rem; padding: .05rem .5rem; border: 1px solid var(--cp-text); font-size: .8rem; font-weight: 700; }
.ct-paper__title { font-size: 1.15rem; font-weight: 700; letter-spacing: .08em; padding-right: 8.5rem; }
.ct-paper__meta { margin-top: .35rem !important; font-size: .86rem; color: var(--ct-muted); overflow-wrap: anywhere; }
.ct-paper .ct-tablewrap { margin-top: .55rem; }
.ct-table tfoot th { font-weight: 600; text-align: right; background: var(--cp-cream); }
.ct-table tfoot td { background: var(--cp-cream); }
.ct-table tbody tr:last-child td { border-bottom: 1px solid var(--cp-line); }

/* 全体を拡大して見る */
.ct-zoom { width: min(96vw, 1100px); height: min(94dvh, 100%); max-width: none; max-height: none; padding: 0; border: 1px solid var(--cp-line); border-radius: 2px; background: var(--cp-white); color: var(--cp-text); font-family: var(--ff-serif); overflow: hidden; }
.ct-zoom[open] { display: flex; flex-direction: column; }
.ct-zoom::backdrop { background: rgba(2, 6, 23, .72); }
.ct-zoom__bar { display: flex; align-items: center; justify-content: space-between; gap: .5rem; flex-wrap: wrap; padding: .4rem .6rem; border-bottom: 1px solid var(--cp-line); background: var(--cp-white); }
.ct-zoom__title { font-size: .98rem; font-weight: 600; color: var(--cp-primary); margin: 0; }
.ct-zoom__ctrl { display: flex; align-items: center; gap: .35rem; margin-left: auto; }
.ct-zoom__pct { min-width: 3.2em; text-align: center; font-family: var(--ct-sans); font-size: .88rem; }
.ct-zoom__scroll { flex: 1; min-height: 0; overflow: auto; background: var(--cp-cream); -webkit-overflow-scrolling: touch; }
.ct-zoom__scroll:focus-visible { outline: 3px solid var(--cp-accent); outline-offset: -3px; }
/* main.css の「動きを減らす」は全部に短い transition を付ける。大きさが遅れて変わると中心の計算がずれるので切る */
.ct-zoom__page { position: relative; margin-inline: auto; background: #fff; transition: none !important; }
.ct-zoom__page img { display: block; width: 100%; height: 100%; max-width: none; }
html.ct-noscroll { overflow: hidden; }


@media (max-width: 1024px) {
  .ct-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1025px) {
  .ct-note__list { columns: 2; column-gap: 2.5rem; }
  .ct-note__list li { break-inside: avoid; }
}
@media (max-width: 860px) {
  .ct-hero { grid-template-columns: minmax(0, 1fr); gap: 1.25rem; }
  .ct-fig { min-height: 0; }
}
@media (max-width: 900px) {
  .ct-panel { grid-template-columns: minmax(0, 1fr); }
  .ct-srccol { position: static; display: grid; grid-template-columns: 4.75rem minmax(0, 1fr); gap: .75rem; align-items: center; box-shadow: none; padding: .55rem .75rem; }
  .ct-srccol__head { display: block; margin: 0; grid-column: 2; grid-row: 1; }
  .ct-srccol__head .ct-btn { margin-top: .45rem; width: 100%; }
  .ct-sheet { grid-column: 1; grid-row: 1; width: 100%; margin: 0; }
  .ct-sheet .ct-hit { display: none; }
}
@media (max-width: 768px) {
  .policy-footer .site-footer__inner { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .ct-page { --ct-head: 63px; }
  .site-header .brand { min-height: 44px; margin-block: -3px; }
  .ct-table { font-size: .86rem; }
  .ct-table th, .ct-table td { padding: .5rem .4rem; }
  .ct-table td:first-child { min-width: 6.5em; }
  .policy-footer .site-footer__inner { grid-template-columns: 1fr; }
  .ct-lead { text-align: left; }
  .ct-steps { grid-template-columns: minmax(0, 1fr); gap: .15rem; }
  .ct-step__text { font-size: .92rem; }
  .ct-hero .can-eyebrow { margin-bottom: .6rem !important; }
  .ct-note { padding: .85rem .9rem .9rem; }
  .ct-tool { padding-top: 1.1rem; scroll-margin-top: -1.25rem; }
  .ct-app { margin-top: .75rem; }
  .ct-tabs { gap: .3rem; }
  .ct-tab { padding: .4rem .45rem; }
  .ct-tab__label { font-size: .84rem; line-height: 1.35; }
  .ct-tab__who { display: none; }
  .ct-tab__state { font-size: .8rem; margin-top: auto; }
  .ct-count { padding: .35rem .75rem; gap: 0 .5rem; }
  .ct-count__main { font-size: .92rem; gap: .25rem; }
  .ct-count__sub { font-size: .86rem; }
  .ct-finish.is-ready { padding: .5rem .75rem .6rem; }
  .ct-finish.is-ready .ct-finish__msg { font-size: .9rem; line-height: 1.5; margin-bottom: .25rem !important; }
  .ct-finish.is-ready .ct-btn--primary { min-height: 48px; }
  .ct-count__num { font-size: 1.7rem; }
  .ct-rowitem { padding: .55rem .7rem; }
  .ct-rowitem.has-marks { padding: .7rem .75rem .85rem; }
  .ct-choices--2 { grid-template-columns: minmax(0, 1fr); }
  .ct-editor__grid { grid-template-columns: minmax(0, 1fr); }
  .ct-reset { text-align: center; }
  .ct-zoom { width: 100vw; height: 100dvh; border: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .is-just-fixed { animation: none; }
  .ct-tab, .ct-btn { transition: none; }
}
@media (max-width: 340px) {
  .ct-tab { padding-inline: .35rem; }
  .ct-tab__label { font-size: .8rem; }
  .ct-srccol { grid-template-columns: 4rem minmax(0, 1fr); }
  .ct-tool__lead { display: none; }
}
/* 高さのない画面では、固定の帯で作業の場所が狭くならないようにする（固定の帯は画面の 30% まで）。下の帯から先に固定を外す */
@media (max-height: 700px) {
  .ct-finish.is-ready { position: static; box-shadow: none; }
  html:has(.ct-finish.is-ready) { scroll-padding-bottom: 1rem; }
}
@media (max-height: 500px) {
  .site-header, .ct-count { position: static; }
  html:has(#ct-app :focus-visible) { scroll-padding-top: 1rem; }
}
/* 見出しの近くの図（契約書から写した値と確認表） */
.ct-fig { margin: 0; padding: .85rem .95rem .95rem; background: var(--cp-white); border: 1px solid var(--cp-line); border-radius: 2px; box-shadow: var(--cp-shadow); }
.ct-fig__cap { font-size: .86rem; font-weight: 600; color: var(--cp-primary); margin-bottom: .4rem !important; line-height: 1.6; }
.ct-fig__rows { display: grid; font-family: var(--ct-sans); font-size: .84rem; border: 1px solid var(--cp-line); }
/* 項目名を 1 行目、値と確認表をその下に縦に並べる（横に並べると確認表の長い文に押されて項目名の列が潰れる。点検の P2） */
.ct-fig__row { display: grid; grid-template-columns: minmax(0, 1fr); gap: .1rem .6rem; align-items: baseline; padding: .35rem .55rem; border-top: 1px solid var(--cp-line); }
.ct-fig__row:first-child { border-top: 0; }
.ct-fig__row.is-marked { background: var(--ct-over-bg); }
.ct-fig__name { font-weight: 600; overflow-wrap: anywhere; }
.ct-fig__nums { font-size: .875rem; text-align: left; line-height: 1.5; color: var(--cp-text); overflow-wrap: anywhere; }
.ct-fig__mark { grid-column: 1 / -1; }
.ct-fig__ok { font-size: .82rem; color: var(--ct-ok-ink); font-weight: 600; }
.ct-fig__note { margin-top: .4rem !important; font-size: .82rem; line-height: 1.6; color: var(--ct-muted); font-family: var(--ct-sans); }

/* 行: 契約書から写した値と確認表を並べる */
.ct-row__data { display: grid; gap: .2rem; min-width: 0; }
.ct-row__name { display: flex; flex-wrap: wrap; align-items: baseline; gap: .1rem .7rem; }
.ct-slip { font-family: var(--ct-sans); font-weight: 600; font-size: .9rem; color: var(--ct-muted); }
.ct-name { font-weight: 600; font-size: 1rem; overflow-wrap: anywhere; }
.ct-date { font-family: var(--ct-sans); font-size: .84rem; color: var(--ct-muted); }
.ct-pair { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: .05rem .7rem; margin: 0; font-family: var(--ct-sans); font-size: .92rem; line-height: 1.65; }
.ct-pair dt { color: var(--ct-muted); font-weight: 600; }
.ct-pair dd { margin: 0; overflow-wrap: anywhere; word-break: auto-phrase; text-wrap: pretty; }
.ct-pair dd.is-empty { color: var(--ct-sku-ink); font-weight: 600; }
.ct-match { margin-top: .25rem !important; font-size: .9rem; line-height: 1.6; text-wrap: pretty; color: var(--ct-ok-ink); font-family: var(--ct-sans); }
.ct-rowitem.is-ask, .ct-head.is-ask { border-left: 4px solid var(--ct-over-ink); }
.ct-head .ct-why { margin-top: .35rem !important; }

/* 印の色。見比べの印は赤と橙、人が決めたものは緑と橙の枠 */
.ct-tag--find { color: var(--ct-sku-ink); background: var(--ct-sku-bg); }
.ct-tag--paid, .ct-tag--diff, .ct-tag--calc { color: var(--ct-over-ink); background: var(--ct-over-bg); }
.ct-tag--ask { color: var(--ct-over-ink); background: #fff; }

/* 聞く所の一覧 */
.ct-asks { margin-top: .75rem; padding: .7rem .9rem; background: var(--ct-over-bg); border-left: 4px solid var(--ct-over-ink); font-family: var(--ct-sans); font-size: .92rem; line-height: 1.7; }
.ct-asks__title { font-weight: 700; color: var(--ct-over-ink); margin-bottom: .25rem !important; }
.ct-asks ul { list-style: disc; padding-left: 1.2em; margin: 0; }
.ct-asks li { overflow-wrap: anywhere; word-break: auto-phrase; text-wrap: pretty; }
.ct-paper__meta { margin-top: .35rem !important; }
.ct-table td { white-space: normal; }
/* 表を 1 列に積む。スマホと、表の幅が 500px ほどより狭くなる幅（4 列では語が細かく折れる） */
@media (max-width: 640px), (min-width: 901px) and (max-width: 1100px) {
  .ct-table, .ct-table tbody, .ct-table tfoot { display: block; }
  .ct-table thead { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .ct-table tbody tr { display: grid; grid-template-columns: minmax(0, 1fr); gap: .1rem; padding: .55rem .6rem; border-bottom: 1px solid var(--cp-line); }
  .ct-table tbody td, .ct-table tbody tr:last-child td { padding: 0; border: 0; }
  .ct-table tbody td:first-child { min-width: 0; font-weight: 600; }
  .ct-table tbody td:nth-child(2)::before { content: "契約書 "; color: var(--ct-muted); }
  .ct-table tbody td:nth-child(3)::before { content: "確認表 "; color: var(--ct-muted); }
  .ct-table tbody td:last-child { font-weight: 700; }
  .ct-table tbody td.is-nomark:last-child { font-weight: 400; color: var(--ct-muted); }
  .ct-table tfoot tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .6rem; align-items: baseline; background: var(--cp-cream); border-bottom: 1px solid var(--cp-line); }
  .ct-table tfoot tr:last-child { border-bottom: 0; }
  .ct-table tfoot th, .ct-table tfoot td { border: 0; }
  .ct-table tfoot tr.ct-tfoot-mark { grid-template-columns: minmax(0, 1fr); gap: .2rem; }
  .ct-table tfoot tr.ct-tfoot-mark td { text-align: right; font-weight: 700; }
  .ct-pair { font-size: .88rem; }
}

/* ---------- 契約書のサンプルで足したもの ---------- */
/* 冒頭の「これは法律の助言ではありません」の帯。見出しより先に読ませる */
.ct-legal { background: #FEF2F2; border-bottom: 2px solid #B91C1C; }
.ct-legal__inner { display: flex; flex-wrap: wrap; align-items: baseline; gap: .2rem 1rem; padding-block: .7rem; }
.ct-legal__title { font-family: var(--ct-sans); font-size: 1.05rem; font-weight: 700; color: #991B1B; }
.ct-legal__text { font-size: .92rem; line-height: 1.7; color: var(--cp-text); overflow-wrap: anywhere; }
.ct-legal__list { flex: 1 1 100%; margin: 0; padding-left: 1.2em; list-style: disc; font-size: .92rem; line-height: 1.7; color: var(--cp-text); overflow-wrap: anywhere; }
/* 結果の所の断り書き（見比べの結果の上と、確定したあとの台帳の上） */
.ct-disc { margin-top: .6rem; padding: .5rem .8rem; background: #FEF2F2; border-left: 4px solid #B91C1C; font-family: var(--ct-sans); font-size: .9rem; line-height: 1.65; overflow-wrap: anywhere; }
.ct-disc__title { font-weight: 700; color: #991B1B; }
/* ページの最後の、このページについてのご指摘の 1 行 */
.ct-contact { padding: clamp(1.5rem, 4vw, 2.5rem) 0; }
.ct-contact__text { font-size: .92rem; line-height: 1.8; overflow-wrap: anywhere; }
.ct-contact__text a { color: var(--cp-primary); text-decoration: underline; text-underline-offset: 2px; }
.ct-tool__legal { font-weight: 700; color: #991B1B; }
.ct-tag--list { color: var(--ct-sku-ink); background: var(--ct-sku-bg); }
.ct-sec { margin-top: .9rem; }
.ct-sec__title { font-size: 1.02rem; color: var(--cp-primary); }
.ct-sec__note { margin-top: .15rem !important; font-size: .9rem; color: var(--ct-muted); line-height: 1.7; font-family: var(--ct-sans); overflow-wrap: anywhere; }
.ct-label { font-weight: 600; font-size: 1rem; overflow-wrap: anywhere; }
@media (max-width: 560px) {
  .ct-legal__inner { padding-block: .55rem; }
  .ct-legal__title { font-size: 1rem; }
  .ct-legal__text { font-size: .9rem; }
  .ct-legal__list { font-size: .9rem; }
}
/* 確定後の表の下の条項の見出しの一覧は、左から読む */
.ct-table tfoot tr.ct-tfoot-mark th { text-align: left; }
.ct-table tfoot tr.ct-tfoot-mark td { white-space: nowrap; }

/* 2 周目の点検で足したもの */
/* 「直す」を開いたときの説明と、契約書の全体を見るボタン（印の枠が隠れるので、見比べる物をいつでも出せるように） */
.ct-editor__top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0 .9rem; }
.ct-editor__top .ct-why { flex: 1 1 14em; margin-top: 0 !important; }
.ct-editor__top .ct-link { flex: none; }
/* 確定のあとの、人が直した所の一覧 */
.ct-edits { margin-top: .5rem; font-size: .95rem; line-height: 1.7; font-family: var(--ct-sans); }
.ct-edits__title { font-weight: 700; color: var(--ct-ok-ink); }
.ct-edits ul { list-style: disc; margin: .1rem 0 0; padding-left: 1.2em; }
.ct-edits li { overflow-wrap: anywhere; word-break: auto-phrase; text-wrap: pretty; }
.ct-table td.is-nomark { color: var(--ct-muted); }
/* 見出しの上の小さな文を 1 行に収める（折れると飾りの線が右に離れて崩れて見える） */
@media (max-width: 400px) {
  .ct-hero .can-eyebrow { letter-spacing: .08em; text-align: left; }
  .ct-hero .can-eyebrow::after { display: none; }
}
/* スマホの図は 2 段（月額＝印あり、支払い）だけにする。隠す段は「触ってみる」で見られる */
@media (max-width: 560px) {
  .ct-fig__row:nth-child(-n+2) { display: none; }
  .ct-fig__row:nth-child(3) { border-top: 0; }
}
/* 1 字だけ次の行へ折れないようにする */
.ct-prior, .ct-disc__text, .ct-why, .ct-say, .ct-diff, .ct-sec__note, .ct-note__list li, .ct-tool__notice p, .ct-tool__lead, .ct-fig__cap, .ct-legal__list li, .ct-legal__text, .ct-lead { text-wrap: pretty; }
.ct-done__title { word-break: auto-phrase; text-wrap: balance; }
.ct-match, .ct-label, .ct-srccol__title, .ct-paper__meta { word-break: auto-phrase; text-wrap: pretty; }
.ct-table td { word-break: auto-phrase; text-wrap: pretty; }
/* 文の中のリンクも押しやすくする（行の高さは変えない） */
.ct-contact__text a { padding-block: .75rem; }
@media (max-width: 560px) {
  /* 表の幅を少しでも広くとり、「サンプル（架空）」の札で「契約の台/帳」と折れないようにする */
  .ct-paper { padding: .7rem .6rem .8rem; }
  .ct-paper__mark { position: static; display: inline-block; margin-bottom: .35rem !important; }
  .ct-paper__title { padding-right: 0; }
}

/* 全サンプル共通の整え（2026-11-06）: 最後の行に 1〜2 字だけ残さない・語の途中で折らない。押す所は 44px。word-break は Safari で効かないので、数字や日付など絶対に割りたくない所は nowrap の span にする */
main { text-wrap: pretty; }
main :where(p, li, h1, h2, h3, h4, dd, dt, figcaption, button, a, label, summary, caption) { word-break: auto-phrase; overflow-wrap: break-word; }
.policy-header__back { display: inline-flex; align-items: center; min-height: 44px; margin-block: -3px; }
.site-header .brand { min-height: 44px; margin-block: -3px; }
.policy-footer .site-footer__nav a { display: inline-flex; align-items: center; min-height: 44px; }

/* この本の打ち消しと折れ方（3 周目） */
/* 共通の整えはヘッダーの高さを 73px から 67px に変える。この本は --ct-head: 73px で帯を止めているので、スマホ以外は元に戻す */
@media (min-width: 561px) {
  .site-header .brand { margin-block: 0; }
  .policy-header__back { margin-block: -4px; }
}
/* 切れ目（JS が入れる <wbr>）の所だけで折る。Safari でも Edge でも同じ折れ方になる。入りきらない長い字だけ、はみ出さないように折る */
main .ct-soft { word-break: keep-all; overflow-wrap: break-word; }
/* 共通の整えが a に auto-phrase を指定するので、文の中のリンクも同じ折り方に戻す（Edge で「お問い／合わせ欄」と割れないように） */
main .ct-soft a { word-break: keep-all; }
/* 表の下の条項の間は全角の空白ではなく余白であける（折れた行の頭に全角の空白が残って字下げに見えないように） */
.ct-tclause { margin-right: 1em; }
/* 切れ目と text-wrap:pretty を一緒に使うと、WebKit で同じ字が 2 度描かれることがある。切れ目で語は割れないので pretty は外す */
/* text-wrap:wrap と書くと nowrap まで消えるので、折り方の指定だけを戻す */
main .ct-soft { text-wrap-style: auto; }
/* 大見出しは Edge では左右の釣り合いを取る（Safari は末尾の指定で止まる） */
main .can-title.ct-soft { text-wrap-style: balance; }
/* 最後の印を決めたあと、確定のボタンが画面に入らないときの 1 行 */
.ct-tofinish { margin-top: .4rem !important; font-size: .9rem; font-weight: 600; line-height: 1.6; color: var(--cp-primary); font-family: var(--ct-sans); }
/* フッターの連絡先も切れ目の所だけで折る（幅 320px の「承り／ます」を防ぐ） */
.policy-footer .site-footer__contact p { word-break: keep-all; overflow-wrap: break-word; }
/* 4 列の表は列の幅を決める（切れ目のある字でも、中身の長さで表が枠からはみ出さないように） */
@media (min-width: 641px) and (max-width: 900px), (min-width: 1101px) {
  .ct-table { table-layout: fixed; }
  .ct-table thead th:nth-child(1) { width: 23%; }
  .ct-table thead th:nth-child(2) { width: 28%; }
  .ct-table thead th:nth-child(3) { width: 27%; }
  .ct-table thead th:nth-child(4) { width: 22%; }
}

/* Safari（auto-phrase が効かない）では text-wrap の pretty / balance と wbr・nowrap が重なると同じ字が 2 回描かれるので、折り方を普通に戻す（2026-11-07） */
@supports not (word-break:auto-phrase){main,main *,.policy-footer,.policy-footer *{text-wrap-style:auto!important}}
