/*
 * compat.css — AFFINGER 時代の本文装飾を、本文を書き換えずに表示するための CSS
 *
 * 対象（2026-09-25 公開51件の実数）:
 *   is-style-st-* のリスト・段落・見出し・表 約1,400か所 / st-blocks（ボックス・見出しボックス・ボタン・タブ）約390 /
 *   マーカー st-mymarker-s(-b) 238 / アイコン st-fa 480
 * 吹き出し・マイブロック・Rinker の表示は pcr-core が新しい部品として出すので components.css 側で扱う。
 * 新しく書く記事ではこれらを使わず、標準ブロックで書く（README.md 参照）。
 */

/* ---------- アイコン（<i class="st-fa st-svg-*">）を線画のマスクで描く ---------- */
.pcr-entry .st-fa{
  display: inline-block;
  width: 1.05em; height: 1.05em;
  margin-right: .35em;
  vertical-align: -.16em;
  background: currentColor;
  -webkit-mask: var(--pcr-i) center / contain no-repeat;
          mask: var(--pcr-i) center / contain no-repeat;
}
.st-svg-check           { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E"); }
.st-svg-check-circle    { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9.5'/%3E%3Cpath d='m7.5 12 3 3 6-6'/%3E%3C/svg%3E"); }
.st-svg-times           { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round'%3E%3Cpath d='M6 6l12 12M18 6 6 18'/%3E%3C/svg%3E"); }
.st-svg-circle-o        { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6'%3E%3Ccircle cx='12' cy='12' r='7.5'/%3E%3C/svg%3E"); }
.st-svg-exclamation-circle { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9.5'/%3E%3Cpath d='M12 7v6.5M12 16.8v.2'/%3E%3C/svg%3E"); }
.st-svg-info-circle     { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9.5'/%3E%3Cpath d='M12 11v6M12 7.3v.2'/%3E%3C/svg%3E"); }
.st-svg-question-circle { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9.5'/%3E%3Cpath d='M9.4 9.3a2.7 2.7 0 1 1 3.8 2.5c-.8.4-1.2 1-1.2 1.9M12 17v.2'/%3E%3C/svg%3E"); }
.st-svg-file-text-o     { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 3H6v18h12V7zM14 3v4h4M9 12h6M9 16h6'/%3E%3C/svg%3E"); }
.st-svg-pencil          { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4 20 4.2-1L19.5 7.7a2.1 2.1 0 0 0-3-3L5.2 15.8zM14.5 6.5l3 3'/%3E%3C/svg%3E"); }
.st-svg-link            { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 14a4 4 0 0 0 5.7 0l3-3A4 4 0 0 0 13 5.3l-1 1M14 10a4 4 0 0 0-5.7 0l-3 3A4 4 0 0 0 11 18.7l1-1'/%3E%3C/svg%3E"); }
.st-svg-search          { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='6.5'/%3E%3Cpath d='m16 16 4.5 4.5'/%3E%3C/svg%3E"); }
.st-svg-chevron-right   { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m9 6 6 6-6 6'/%3E%3C/svg%3E"); }
.st-svg-oukan           { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linejoin='round'%3E%3Cpath d='m3 8 4.5 4L12 5l4.5 7L21 8l-2 11H5z'/%3E%3C/svg%3E"); }
.st-svg-lightbulb-o     { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 18h6M10 21h4M12 3a6 6 0 0 0-4 10.5c.7.7 1 1.5 1 2.5h6c0-1 .3-1.8 1-2.5A6 6 0 0 0 12 3z'/%3E%3C/svg%3E"); }
.st-fa.st-svg-after { margin-right: 0; margin-left: .35em; }

/* ---------- マーカー ---------- */
.st-mymarker-s,
.st-mymarker-s-b {
  background: linear-gradient(transparent 62%, rgba(237, 237, 0, .55) 62%);
  padding-inline: .1em;
}
.st-mymarker-s-b { font-weight: 700; }

/* ---------- 色パレット（AFFINGER が定義していた分だけ） ---------- */
.has-very-light-gray-background-color { background-color: #fafafa; }

/* ---------- リスト ---------- */
.pcr-entry ul[class*="is-style-st-"],
.pcr-entry ol[class*="is-style-st-"]{
  padding-left: 0;
  list-style: none;
}
.pcr-entry [class*="is-style-st-"] > li{
  position: relative;
  padding: .35em 0 .35em 1.9em;
  border-bottom: 1px dashed var(--pcr-line);
}
.pcr-entry [class*="is-style-st-"] > li + li { margin-top: 0; }
.pcr-entry [class*="is-style-st-"] > li:last-child { border-bottom: 0; }
.pcr-entry .is-style-st-no-border > li,
.pcr-entry .is-style-st-square-checkbox-no-border > li { border-bottom: 0; }
.pcr-entry [class*="is-style-st-"] > li::before{
  content: "";
  position: absolute; left: .1em; top: .72em;
  width: 1.15em; height: 1.15em;
  background: var(--pcr-amber-deep);
  -webkit-mask: var(--pcr-i) center / contain no-repeat;
          mask: var(--pcr-i) center / contain no-repeat;
}
/* 並び順は使用数順 */
.is-style-st-square-checkbox > li::before,
.is-style-st-square-checkbox-no-border > li::before {
  --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3.5' y='3.5' width='17' height='17' rx='2.5'/%3E%3Cpath d='m8 12 3 3 5.5-6'/%3E%3C/svg%3E");
}
.pcr-entry .is-style-st-circle-border > li::before,
.pcr-entry .is-style-st-circle > li::before {
  --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='5' fill='black'/%3E%3C/svg%3E");
  background: var(--pcr-amber);
}
.is-style-st-correct-list > li::before,
.is-style-st-maruck > li::before {
  --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9.5'/%3E%3Cpath d='m7.5 12 3 3 6-6'/%3E%3C/svg%3E");
}
.pcr-entry .is-style-st-wrong-list > li::before {
  --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9.5'/%3E%3Cpath d='m8.5 8.5 7 7M15.5 8.5l-7 7'/%3E%3C/svg%3E");
  background: var(--pcr-red);
}
.pcr-entry .is-style-st-no-border > li::before,
.pcr-entry .is-style-st-border > li::before {
  --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='4' fill='black'/%3E%3C/svg%3E");
  background: var(--pcr-ink);
}
/* 丸数字 */
.pcr-entry .is-style-st-maruno { counter-reset: pcr-no; }
.pcr-entry .is-style-st-maruno > li { counter-increment: pcr-no; }
.pcr-entry .is-style-st-maruno > li::before {
  content: counter(pcr-no);
  -webkit-mask: none; mask: none;
  width: 1.5em; height: 1.5em; top: .5em; left: 0;
  border-radius: 0;
  background: var(--pcr-ink); color: #fff;
  font-size: .8em; font-weight: 700; line-height: 1.5em; text-align: center;
}

/* 枠付きリスト（has-st-border） */
.pcr-entry .has-st-border {
  padding: 14px 18px;
  border: 2px solid var(--pcr-line);
  border-radius: var(--pcr-radius);
}
.pcr-entry .has-st-thick-border-width { border-width: 3px; }
.pcr-entry .has-st-medium-border-width { border-width: 2px; }
.pcr-entry .has-st-border.is-style-st-square-checkbox,
.pcr-entry .has-st-border.is-style-st-correct-list { border-color: var(--pcr-amber); background: #fffcf2; }
.pcr-entry .has-st-border.is-style-st-wrong-list { border-color: #f0c3c8; background: #fffafa; }
.pcr-entry .has-no-st-margin-bottom { margin-bottom: 0; }

/* ---------- 段落の装飾 ---------- */
.pcr-entry p[class*="is-style-st-paragraph-"]{
  position: relative;
  padding: 14px 16px 14px 46px;
  border-radius: var(--pcr-radius);
  font-size: .94em; line-height: 1.85;
}
.pcr-entry p[class*="is-style-st-paragraph-"]::before{
  content: "";
  position: absolute; left: 16px; top: 16px;
  width: 20px; height: 20px;
  background: var(--pcr-ink-2);
  -webkit-mask: var(--pcr-i) center / contain no-repeat;
          mask: var(--pcr-i) center / contain no-repeat;
}
.is-style-st-paragraph-attention-gray { background: #f3f2ef; color: var(--pcr-ink-2); }
.is-style-st-paragraph-attention-gray::before,
.is-style-st-paragraph-attention::before { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9.5'/%3E%3Cpath d='M12 7v6.5M12 16.8v.2'/%3E%3C/svg%3E"); }
.pcr-entry p.is-style-st-paragraph-attention { background: var(--pcr-red-soft); }
.pcr-entry p.is-style-st-paragraph-attention::before { background: var(--pcr-red); }
.pcr-entry p.is-style-st-paragraph-point { background: var(--pcr-amber-soft); }
.pcr-entry p.is-style-st-paragraph-point::before { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 18h6M10 21h4M12 3a6 6 0 0 0-4 10.5c.7.7 1 1.5 1 2.5h6c0-1 .3-1.8 1-2.5A6 6 0 0 0 12 3z'/%3E%3C/svg%3E"); background: var(--pcr-amber-deep); }
.pcr-entry p.is-style-st-paragraph-info-circle { background: #eef4fa; }
.pcr-entry p.is-style-st-paragraph-info-circle::before { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9.5'/%3E%3Cpath d='M12 11v6M12 7.3v.2'/%3E%3C/svg%3E"); background: var(--pcr-link); }
.pcr-entry p.is-style-st-paragraph-memo-txt,
.pcr-entry p.is-style-st-paragraph-pen { background: var(--pcr-paper-2); }
.pcr-entry p.is-style-st-paragraph-memo-txt::before,
.pcr-entry p.is-style-st-paragraph-pen::before { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4 20 4.2-1L19.5 7.7a2.1 2.1 0 0 0-3-3L5.2 15.8zM14.5 6.5l3 3'/%3E%3C/svg%3E"); }
/* リンク段落・PR行は枠を付けない */
.pcr-entry p.is-style-st-paragraph-link,
.pcr-entry p.is-style-st-paragraph-check{
  padding: 0 0 0 1.6em; border-radius: 0; background: none;
}
.pcr-entry p.is-style-st-paragraph-link::before,
.pcr-entry p.is-style-st-paragraph-check::before{ left: 0; top: .42em; width: 1.1em; height: 1.1em; }
.is-style-st-paragraph-link::before { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m9 6 6 6-6 6'/%3E%3C/svg%3E"); }
.is-style-st-paragraph-check { color: var(--pcr-ink-2); font-size: 13px !important; font-weight: 700; }
.is-style-st-paragraph-check::before { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E"); background: var(--pcr-amber-deep) !important; }

/* ---------- 見出しの装飾 ---------- */
.st-h-copy {
  display: inline-block;
  margin-right: .6em; padding: .1em .55em;
  background: var(--pcr-ink); color: var(--pcr-amber);
  border-radius: 0;
  font-size: .72em; letter-spacing: .08em; vertical-align: .15em;
}
.pcr-entry .is-style-st-heading-custom-attention { border-left-color: var(--pcr-red); color: var(--pcr-red); }

/* ---------- 表 ---------- */
.pcr-entry .is-style-st-centertable td,
.pcr-entry .is-style-st-centertable th { text-align: center; }
.pcr-entry .is-style-st-table-line-2 td,
.pcr-entry .is-style-st-table-line-2 th,
.pcr-entry .is-style-st-table-line td,
.pcr-entry .is-style-st-table-line th { border-left: 0; border-right: 0; }

/* ---------- ボックス（st-blocks/my-box）：枠の上にタイトルを載せる ---------- */
.pcr-entry .st-mybox {
  position: relative;
  margin-top: 2em !important;
  padding: 22px 18px 16px;
  border: 2px solid var(--pcr-ink);
  border-radius: var(--pcr-radius) !important;
}
.pcr-entry .st-mybox-title {
  position: absolute; top: -.95em; left: 12px;
  padding: 0 8px;
  background: var(--pcr-paper) !important;
  font-size: 15px; line-height: 1.8;
}
.pcr-entry .st-in-mybox > :first-child { margin-top: 0; }
.pcr-entry .st-in-mybox > * + * { margin-top: 1em; }
.pcr-entry .st-in-mybox ul { margin: 0; }

/* ---------- 見出しボックス（st-blocks/midashi-box） ---------- */
.pcr-entry .freebox {
  border: 2px solid var(--pcr-ink);
  border-radius: var(--pcr-radius) !important;
  overflow: hidden;
}
.pcr-entry .freebox .p-free { margin: 0; }
.pcr-entry .freebox .p-entry-f {
  display: inline-block;
  padding: 6px 14px;
  background: var(--pcr-ink); color: #fff;
  border-radius: 0 0 var(--pcr-radius) 0 !important;
  font-size: 14px;
}
.pcr-entry .free-inbox { padding: 12px 18px 16px; }
.pcr-entry .free-inbox > * + * { margin-top: 1em; }
.pcr-entry .free-inbox ul { margin: 0; }

/* ---------- ボタン（st-blocks/my-button）：色は本文側の指定があればそれを優先 ---------- */
.pcr-entry p.st-mybtn{
  display: block;
  max-width: 480px;
  margin: 1.6em auto 0;
  padding: 0 !important;
  background-color: var(--pcr-red);
  border-radius: 0;
  box-shadow: 0 4px 0 rgba(90, 10, 20, .35) !important;
  text-align: center;
  transition: transform .15s ease, box-shadow .15s ease, filter .15s ease;
}
.pcr-entry p.st-mybtn:hover{ filter: brightness(1.06); transform: translateY(-1px); }
.pcr-entry p.st-mybtn:active{ transform: translateY(3px); box-shadow: 0 1px 0 rgba(90, 10, 20, .35) !important; }
.pcr-entry p.st-mybtn a{
  display: block;
  padding: 15px 22px;
  color: #fff !important; font-weight: 700; line-height: 1.5; text-decoration: none;
}

/* ---------- タブ（st-blocks/tabs）。開閉はプラグインの view.js が hidden 属性で行う ---------- */
.pcr-entry .st-tabs__tab-list { display: flex; flex-wrap: wrap; gap: 4px; margin: 0; padding: 0; list-style: none; }
.pcr-entry .st-tabs__tab-list-item { margin: 0 !important; }
.pcr-entry .st-tabs__tab {
  padding: 8px 14px;
  border: 2px solid var(--pcr-ink); border-bottom: 0;
  border-radius: var(--pcr-radius-s) var(--pcr-radius-s) 0 0;
  background: var(--pcr-paper); color: var(--pcr-ink);
  font: inherit; font-size: 13px; line-height: 1.5; cursor: pointer;
}
.pcr-entry .st-tabs__tab[aria-selected="true"] { background: var(--pcr-ink); color: #fff; }
.pcr-entry .st-tabs__tab-content-group { margin-top: 0 !important; padding: 16px 18px; border: 2px solid var(--pcr-ink); border-radius: 0 var(--pcr-radius) var(--pcr-radius) var(--pcr-radius); }
.pcr-entry .st-tabs__tab-content[hidden] { display: none; }
.pcr-entry .st-tabs__tab-content > * + * { margin-top: 1em; }

/* ---------- 旧マイブロック（業者CTAの台帳に対応が無いものだけがこの形で出る） ---------- */
.pcr-myblock { margin-block: 1.8em; }
.pcr-myblock > * + * { margin-top: .8em; }

/* 評価の星（業者ランキングの旧マイブロック 1187・1373 で使用） */
.st-svg-star { --pcr-i: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M12 2.5l2.9 6.1 6.6.8-4.9 4.6 1.3 6.6L12 17.3l-5.9 3.3 1.3-6.6-4.9-4.6 6.6-.8z'/%3E%3C/svg%3E"); }
.pcr-entry .st-fa.st-svg-star { margin-right: 1px; background: var(--pcr-amber); }
/* 本文側で直接書かれた角丸（border-radius:60px など）もサイトの決まりに合わせて外す */
.pcr-entry p.st-mybtn { border-radius: 0 !important; }
