/* HOTOMARU 生成AIコンプライアンス セルフチェック
   WordPressテーマ内でも崩れないよう、すべて .hac 配下に限定する */
.hac {
  --hac-navy: #122540;
  --hac-blue: #2E5F8A;
  --hac-gold: #F4C021;
  --hac-gold-soft: #E7CD85;
  --hac-gray: #F6F6F6;
  --hac-bluegray: #9FB0C3;
  --hac-line: #DDE3EA;
  --hac-text: #1F2A37;
  --hac-muted: #5B6B7D;
  --hac-ok: #2E7D5B;
  --hac-part: #B7860B;
  --hac-ng: #B23A3A;
  --hac-na: #7A8794;
  color: var(--hac-text);
  font-size: 15px;
  line-height: 1.7;
  max-width: 1040px;
  margin: 0 auto;
  box-sizing: border-box;
}
.hac *, .hac *::before, .hac *::after { box-sizing: inherit; }
.hac button { font: inherit; cursor: pointer; }
.hac a { color: var(--hac-blue); }

/* ヘッダー */
.hac-head {
  background: var(--hac-navy);
  color: #fff;
  border-radius: 16px;
  padding: 22px 24px 18px;
  position: sticky;
  top: 0;
  z-index: 5;
}
.hac-eyebrow { color: var(--hac-gold-soft); font-size: 12px; letter-spacing: .12em; margin: 0; }
.hac-title { margin: 2px 0 12px; font-size: 22px; line-height: 1.4; color: #fff; }
.hac-title::after { content: ""; display: block; width: 48px; height: 3px; background: var(--hac-gold); margin-top: 8px; }
.hac-progress-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.hac-progress { flex: 1 1 220px; height: 8px; background: rgba(255,255,255,.18); border-radius: 99px; overflow: hidden; }
.hac-progress > span { display: block; height: 100%; background: var(--hac-gold); transition: width .3s; }
.hac-progress-text { font-size: 13px; color: var(--hac-gold-soft); white-space: nowrap; }
/* ボタン：サイト共通の gv-btn（ピル型）に合わせる */
.hac-btn {
  display: inline-block; border: 0; border-radius: 999px; padding: 12px 26px; font-weight: 700; font-size: 15px; line-height: 1.5;
  background: var(--hac-gold); color: var(--hac-navy); text-decoration: none; text-align: center;
  box-shadow: 0 4px 14px rgba(18, 37, 64, .18);
}
.hac a.hac-btn { color: var(--hac-navy); text-decoration: none; }
.hac-btn:hover { opacity: .85; }
.hac-btn--ghost { background: #fff; color: var(--hac-navy); border: 2px solid var(--hac-navy); box-shadow: none; padding: 10px 22px; font-size: 14px; }
.hac-btn--navy { background: var(--hac-navy); color: #fff; box-shadow: none; }
.hac a.hac-btn--navy { color: #fff; }

/* タブ */
.hac-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 18px 0 14px; }
.hac-tab {
  border: 1px solid var(--hac-line); background: #fff; color: var(--hac-text);
  border-radius: 99px; padding: 5px 12px; font-size: 13px; display: inline-flex; align-items: center; gap: 6px;
}
.hac-tab[aria-selected="true"] { background: var(--hac-blue); border-color: var(--hac-blue); color: #fff; }
.hac-tab .hac-count { font-size: 11px; opacity: .75; }
.hac-tab--done .hac-count::before { content: "✓ "; }
.hac-tab--locked { color: var(--hac-na); background: var(--hac-gray); }
.hac-tab--result { border-color: var(--hac-gold); font-weight: 700; }
.hac-lock { width: 12px; height: 12px; fill: currentColor; }

/* 設問カード */
.hac-cat-title { font-size: 18px; margin: 4px 0 4px; color: var(--hac-navy); }
.hac-cat-note { color: var(--hac-muted); font-size: 13px; margin: 0 0 12px; }
/* 設問カード：12問セルフチェック（.hc-q）と同じ見た目 */
.hac-item { border: 1px solid #E6E2D8; border-radius: 12px; padding: 18px 20px 16px; margin-bottom: 14px; background: #fff; }
.hac-item--answered { border-color: var(--hac-blue); }
.hac-item-meta { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; font-size: 12.5px; font-weight: 700; color: var(--hac-blue); }
.hac-badge { border-radius: 4px; padding: 1px 7px; font-size: 11px; font-weight: 700; border: 1px solid currentColor; }
.hac-badge--高 { color: var(--hac-ng); }
.hac-badge--中 { color: var(--hac-part); }
.hac-badge--低 { color: var(--hac-na); }
.hac-badge--law { background: var(--hac-navy); color: #fff; border-color: var(--hac-navy); }
.hac-badge--pre { background: var(--hac-gold-soft); color: var(--hac-navy); border-color: var(--hac-gold-soft); }
.hac-item-text { margin: .3em 0 .8em; font-size: 15px; font-weight: 700; color: var(--hac-navy); line-height: 1.7; }
.hac-answers { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.hac-answers label { position: relative; display: flex; cursor: pointer; }
.hac-answers input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
/* 回答ボタン：12問セルフチェック（.wpcf7-radio）と同じ見た目。選んだものだけ紺で塗る */
.hac-answers span {
  flex: 1; display: flex; align-items: center; justify-content: center; text-align: center; border: 1px solid #CFD6DF; border-radius: 8px;
  padding: 11px 6px; font-size: 13.5px; font-weight: 700; line-height: 1.4; background: #fff; color: var(--hac-navy); cursor: pointer;
  transition: color .15s, border-color .15s, background-color .15s;
}
.hac-answers input:focus-visible + span { outline: 3px solid var(--hac-gold); outline-offset: 2px; }
/* マウスを乗せたら文字と枠を青にして、押せることを伝える（選択済みのボタンは紺のまま） */
.hac-answers label:hover input:not(:checked) + span { color: var(--hac-blue); border-color: var(--hac-blue); background: #EEF3F8; }
.hac-answers input:checked + span { background: var(--hac-navy); border-color: var(--hac-navy); color: #fff; font-weight: 700; }
.hac-basis { margin-top: 8px; font-size: 13px; color: var(--hac-muted); }
.hac-basis summary { cursor: pointer; }
.hac-basis ul { margin: 4px 0 0; padding-left: 18px; }
.hac-basis li { word-break: break-all; }
.hac-memo { width: 100%; margin-top: 6px; border: 1px solid var(--hac-line); border-radius: 6px; padding: 6px 8px; font: inherit; font-size: 13px; }
.hac-nav { display: flex; justify-content: space-between; gap: 8px; margin: 16px 0 8px; }

/* 結果 */
.hac-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 6px 0 18px; }
.hac-kpi { background: var(--hac-gray); border-radius: 12px; padding: 12px 14px; }
.hac-kpi b { display: block; font-size: 28px; color: var(--hac-navy); line-height: 1.2; font-variant-numeric: tabular-nums; }
.hac-kpi small { color: var(--hac-muted); font-size: 12px; }
.hac-result-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
.hac-panel { border: 1px solid #E6E2D8; border-radius: 12px; padding: 14px 16px; background: #fff; margin-bottom: 18px; }
.hac-panel h4 { margin: 0 0 8px; font-size: 15px; color: var(--hac-navy); }
.hac-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.hac-table th, .hac-table td { padding: 5px 6px; border-bottom: 1px solid var(--hac-line); text-align: left; vertical-align: middle; }
.hac-table td.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.hac-bar { height: 8px; background: var(--hac-gray); border-radius: 99px; overflow: hidden; min-width: 60px; }
.hac-bar > span { display: block; height: 100%; background: var(--hac-blue); }
.hac-radar text { font-size: 11px; fill: var(--hac-muted); }
.hac-priority ol { list-style: decimal; padding-left: 1.6em; margin: 0; }
.hac-priority li { list-style: decimal; margin-bottom: 6px; font-size: 13px; }
.hac-priority .hac-ans { font-weight: 700; margin-right: 4px; }
.hac-toolbar { display: flex; gap: 8px; flex-wrap: wrap; margin: 4px 0 18px; }

/* 会員案内 */
.hac-upsell { background: var(--hac-navy); color: #fff; border-radius: 16px; padding: 20px 22px; margin: 18px 0; }
.hac-upsell h4 { color: #fff; margin: 0 0 6px; font-size: 17px; }
.hac-upsell p { margin: 0 0 12px; color: #E3E9F0; font-size: 14px; }
.hac-plans { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.hac-plan { background: #fff; color: var(--hac-text); border-radius: 8px; padding: 14px 16px; }
.hac-plan h5 { margin: 0; font-size: 15px; color: var(--hac-navy); }
.hac-plan .hac-price { font-size: 20px; font-weight: 700; color: var(--hac-blue); margin: 4px 0; }
.hac-plan ul { margin: 6px 0 10px; padding-left: 18px; font-size: 13px; }
.hac-plan--premium { outline: 3px solid var(--hac-gold); }
.hac-locked-list { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; padding: 0; list-style: none; }
.hac-locked-list li { background: rgba(255,255,255,.1); border-radius: 4px; padding: 2px 8px; font-size: 12px; color: var(--hac-gold-soft); }

.hac-btn:disabled { opacity: .55; cursor: wait; }
.hac-quota { margin: 8px 0 0; font-size: 13px; color: var(--hac-gold-soft); }

/* 診断書発行 */
.hac-issue { border: 2px solid var(--hac-navy); border-radius: 16px; padding: 20px 22px 18px; margin: 6px 0 18px; background: #fff; }
.hac-legend { font-size: 11.5px; color: var(--hac-muted); margin: 8px 0 0; }
.hac-company { display: block; font-size: 13px; color: var(--hac-muted); margin-bottom: 10px; }
.hac-company input { display: block; width: 100%; max-width: 360px; margin-top: 4px; border: 1px solid var(--hac-line); border-radius: 6px; padding: 7px 10px; font: inherit; font-size: 15px; color: var(--hac-text); }
.hac-issue-note { font-size: 13px; color: var(--hac-muted); margin: 8px 0 0; }
.hac-issue-msg { font-size: 13px; color: var(--hac-ng); font-weight: 700; margin: 8px 0 0; }
.hac-plan-term { font-size: 12px; color: var(--hac-muted); margin: 0; }
.hac-login { margin: 12px 0 0; font-size: 13px; }
.hac-login a { color: var(--hac-gold-soft); }

/* PDF診断書（画面外で描画してPDF化する） */
.hac-report { padding: 0; font-size: 13px; max-width: none; margin: 0; }
.hac-report-head { display: flex; justify-content: space-between; gap: 16px; background: var(--hac-navy); color: #fff; border-radius: 8px; padding: 18px 20px; margin-bottom: 12px; }
.hac-report-head h2 { margin: 2px 0 0; font-size: 22px; color: #fff; }
.hac-report-head dl { display: grid; grid-template-columns: auto auto; gap: 2px 10px; margin: 0; font-size: 11px; align-content: center; }
.hac-report-head dt { color: var(--hac-gold-soft); }
.hac-report-head dd { margin: 0; }
.hac-report-company { font-size: 16px; font-weight: 700; margin: 4px 0 10px; }
.hac-report .hac-kpi b { font-size: 24px; }
.hac-report .hac-kpis { grid-template-columns: repeat(4, 1fr); }
.hac-report .hac-result-grid { grid-template-columns: 1fr; }
/* PDFはスマホから発行しても同じレイアウトになるよう、幅による切り替えを打ち消す */
.hac-report .hac-radar { display: block; width: 620px !important; height: 380px !important; margin: 0 auto; }

.hac-disclaimer { font-size: 12px; color: var(--hac-muted); border-top: 1px solid var(--hac-line); padding-top: 10px; margin-top: 18px; }

/* 申込ページの決済ボタン（Simple Membership が出力）をサイトの gv-btn-main に合わせる */
.hac-buy { text-align: center; margin: 2em 0 1em; }
.hac-buy .swpm-payment-button { display: inline-block; }
.hac-buy .swpm-payment-button button,
.hac-buy .swpm-payment-button input[type="submit"] {
  display: inline-block; min-width: 320px; border: 0; border-radius: 999px; padding: 16px 40px;
  background: #F4C021; color: #122540; font-weight: 700; font-size: 17px; line-height: 1.5; cursor: pointer;
  box-shadow: 0 4px 14px rgba(18, 37, 64, .18);
}
.hac-buy .swpm-payment-button button:hover { opacity: .85; }
/* Stripe 標準ボタンは内側の span に青いグラデーションが付くので打ち消す */
.hac-buy .swpm-payment-button button span {
  display: inline !important; background: none !important; box-shadow: none !important; text-shadow: none !important;
  color: inherit !important; font: inherit !important; height: auto !important; line-height: inherit !important;
  padding: 0 !important; border-radius: 0 !important; min-height: 0 !important;
}
.hac-buy-note { font-size: 12.5px; color: #5B6472; margin: .8em 0 0; }

@media (max-width: 720px) {
  .hac-buy .swpm-payment-button,
  .hac-buy .swpm-payment-button button { display: block; width: 100%; min-width: 0; }
  .hac-head { position: static; padding: 18px 16px 14px; }
  .hac-title { font-size: 19px; }
  .hac-kpis { grid-template-columns: repeat(2, 1fr); }
  .hac-result-grid, .hac-plans { grid-template-columns: 1fr; }
  .hac-answers { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hac-answers label:last-child { grid-column: span 2; }
  .hac-item { padding: 16px 14px 14px; }
  .hac-item-text { font-size: 14.5px; }
  .hac-tabs { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; -webkit-overflow-scrolling: touch; }
  .hac-tab { flex: 0 0 auto; }
}

@media print {
  .hac-tabs, .hac-toolbar, .hac-upsell, .hac-nav, .hac-issue { display: none !important; }
  .hac-head { position: static; }
  .hac-panel, .hac-kpi { break-inside: avoid; }
  .hac-result-grid { grid-template-columns: 1fr 1fr; }
}

/* 会員のお知らせ（有料会員にだけ、ツールの上に表示） */
.hac-notices { max-width: 1040px; margin: 0 auto 24px; background: #fff; border: 1px solid #E6E2D8; border-radius: 12px; padding: 18px 22px 8px; box-sizing: border-box; }
.hac-notices .hac-notices-head { margin: 0 0 10px; padding: 0 0 0 10px; border-left: 4px solid #F4C021; font-size: 17px; font-weight: 700; color: #122540; line-height: 1.5; }
.hac-notices .hac-notice { border-top: 1px solid #E6E2D8; }
.hac-notices .hac-notice summary { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 12px 0; cursor: pointer; list-style: none; color: #122540; font-weight: 700; font-size: 15px; }
.hac-notices .hac-notice summary::-webkit-details-marker { display: none; }
.hac-notices .hac-notice summary::after { content: "＋"; margin-left: auto; color: #2E5F8A; font-weight: 700; }
.hac-notices .hac-notice[open] summary::after { content: "－"; }
.hac-notices .hac-notice summary:hover .hac-notice-title { color: #2E5F8A; }
.hac-notices .hac-notice-date { font-size: 13px; font-weight: 700; color: #5B6B7D; font-variant-numeric: tabular-nums; }
.hac-notices .hac-notice-new { font-size: 11px; font-weight: 700; letter-spacing: .06em; background: #F4C021; color: #122540; border-radius: 999px; padding: 1px 9px; }
.hac-notices .hac-notice-title { flex: 1 1 60%; }
.hac-notices .hac-notice-body { padding: 0 0 14px; font-size: 14.5px; line-height: 1.85; color: #1F2A37; }
.hac-notices .hac-notice-body p { margin: 0 0 .8em; }
@media (max-width: 720px) {
  .hac-notices { padding: 14px 16px 4px; }
  .hac-notices .hac-notice-title { flex-basis: 100%; }
}

/* ===== 会員ページ（v1.3.0） ===== */
/* 会員が見ているときは、ページ内の会員以外向けの案内を隠す */
.hac-is-member .hac-guest-only { display: none !important; }

/* 会員情報の帯 */
.hac-member { max-width: 1040px; margin: 0 auto 18px; box-sizing: border-box; background: #122540; border-radius: 16px; padding: 20px 26px; display: flex; flex-wrap: wrap; align-items: center; gap: 14px 26px; }
.hac-member p { margin: 0; }
.hac-member-who { flex: 1 1 220px; }
.hac-member .hac-member-hi { font-size: 12px; letter-spacing: .12em; color: #E7CD85; }
.hac-member .hac-member-name { font-size: 20px; font-weight: 700; color: #fff; line-height: 1.4; }
.hac-member-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.hac-member-chip { background: rgba(255, 255, 255, .1); border: 1px solid rgba(231, 205, 133, .6); color: #fff; font-size: 13px; border-radius: 999px; padding: 5px 14px; }
.hac-member-chip b { color: #F4C021; font-weight: 700; margin-left: 6px; }
.hac-member-acts, .hac-member-alert-btns { display: flex; flex-wrap: wrap; gap: 8px; }
a.hac-member-btn { display: inline-block; font-size: 13px; font-weight: 700; border-radius: 999px; padding: 8px 18px; border: 1.5px solid #fff; color: #fff !important; background: transparent; text-decoration: none !important; transition: background-color .2s, color .2s; }
a.hac-member-btn:hover { background: #fff; color: #122540 !important; opacity: 1 !important; }
a.hac-member-btn.is-gold { background: #F4C021; border-color: #F4C021; color: #122540 !important; }
a.hac-member-btn.is-gold:hover { background: #fff; border-color: #fff; }
a.hac-member-btn.is-navy { background: #fff; border-color: #122540; color: #122540 !important; }
a.hac-member-btn.is-navy:hover { background: #122540; color: #fff !important; }

/* 期限切れ・回数切れの案内 */
.hac-member-alert { max-width: 1040px; margin: 0 auto 18px; box-sizing: border-box; background: #FBF3DC; border: 1.5px solid #E7CD85; border-radius: 16px; padding: 18px 24px; }
.hac-member-alert p { margin: 0 0 12px; color: #5A4A1E; font-size: 14px; line-height: 1.8; }
.hac-member-alert .hac-member-alert-head { margin: 0 0 4px; font-size: 17px; font-weight: 700; color: #122540; }

/* 前回のセルフチェックの結果 */
.hac-last { background: #fff; border: 1px solid #E6E2D8; border-radius: 12px; padding: 18px 22px 6px; margin: 0 0 22px; }
.hac-last .hac-last-head { margin: 0 0 6px; padding: 0 0 0 10px; border-left: 4px solid #F4C021; font-size: 17px; font-weight: 700; color: #122540; line-height: 1.5; }
.hac-last .hac-last-meta { margin: 0 0 12px; font-size: 13px; color: #5B6B7D; }
.hac-last .hac-last-note { margin: 0 0 14px; font-size: 14px; line-height: 1.8; color: #3C4552; }
.hac-last .hac-toolbar { margin: 0 0 14px; }

@media (max-width: 720px) {
  .hac-member { padding: 18px 18px; }
  .hac-member .hac-member-name { font-size: 18px; }
  .hac-member-alert { padding: 16px 18px; }
  .hac-last { padding: 14px 16px 4px; }
}

/* ===== 会員ページ（v1.4.0）：GAICセルフチェックの説明・これまでの結果カード・GAICセルフチェックをはじめるボタン ===== */
.hac-about { max-width: 1040px; margin: 0 auto 14px; box-sizing: border-box; background: #EAF4FB; border: 1px solid #B9D8EE; border-radius: 12px; padding: 12px 18px; font-size: 14px; line-height: 1.8; color: #122540; }
.hac-about b { color: #2E5F8A; }

.hac-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 6px 0 20px; }
.hac-card { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; background: #fff; border: 1px solid #E6E2D8; border-radius: 14px; padding: 16px 14px 16px; }
.hac-card.is-latest { border: 2px solid #F4C021; }
.hac-card p { margin: 0; }
.hac-card-tag { display: inline-block; font-size: 12px; font-weight: 700; background: #F4C021; color: #122540; border-radius: 999px; padding: 2px 14px; margin: 0 0 6px; }
.hac-card-tag.is-old { background: #EEF3F8; color: #2E5F8A; }
.hac-card .hac-card-meta { font-size: 12px; color: #5B6B7D; font-variant-numeric: tabular-nums; }
.hac-card .hac-card-rate { font-size: 34px; font-weight: 700; color: #122540; line-height: 1.2; margin-top: 6px; }
.hac-card .hac-card-rate small { font-size: 15px; margin-left: 2px; }
.hac-card .hac-card-sub { font-size: 12px; color: #5B6B7D; }
.hac-card .hac-card-high { font-size: 13px; font-weight: 700; color: #2E5F8A; margin-top: 4px; }
.hac-card .hac-card-note { font-size: 13px; line-height: 1.7; color: #5B6B7D; margin-top: 12px; }
.hac-radar-mini { display: block; width: 100%; max-width: 240px; height: auto; margin: 6px auto 8px; }
.hac-card-pdf { margin-top: auto; padding: 9px 22px; font-size: 14px; }

.hac-go { text-align: center; margin: 4px 0 16px; }
.hac .hac-go .hac-go-btn {
  display: inline-flex; flex-direction: column; align-items: center; gap: 4px; min-width: 380px; padding: 18px 40px 16px;
  border: 3px solid #F4C021; border-radius: 999px; background: #F4C021; color: #122540; cursor: pointer;
  box-shadow: 0 6px 18px rgba(18, 37, 64, .2); transition: background-color .2s, color .2s, border-color .2s, transform .2s, box-shadow .2s;
}
.hac .hac-go .hac-go-main { display: flex; align-items: center; gap: 10px; font-size: 22px; font-weight: 700; letter-spacing: .04em; line-height: 1.3; }
.hac .hac-go .hac-go-sub { font-size: 13px; font-weight: 700; opacity: .85; }
.hac .hac-go .hac-go-arrow { display: inline-block; transition: transform .2s; }
/* マウスを乗せたら紺に反転し、少し浮き上がって矢印が進む */
.hac .hac-go .hac-go-btn:hover, .hac .hac-go .hac-go-btn:focus-visible { background: #122540; border-color: #F4C021; color: #F4C021; transform: translateY(-3px); box-shadow: 0 10px 24px rgba(18, 37, 64, .3); opacity: 1; }
.hac .hac-go .hac-go-btn:hover .hac-go-arrow { transform: translateX(6px); }
.hac .hac-go .hac-go-btn:focus-visible { outline: 3px solid #2E5F8A; outline-offset: 3px; }
.hac .hac-go .hac-go-btn.is-open { background: #fff; border-color: #122540; color: #122540; box-shadow: none; }
.hac .hac-go .hac-go-btn.is-open:hover { background: #122540; color: #fff; }
.hac-go .hac-go-note { margin: 8px 0 0; font-size: 13px; color: #5B6B7D; }
.hac.is-tool-closed > .hac-app { display: none; }

@media (max-width: 860px) {
  .hac-cards { grid-template-columns: 1fr; }
  .hac .hac-go .hac-go-btn { min-width: 0; width: 100%; max-width: 100%; padding: 16px 12px 14px; }
  .hac .hac-go .hac-go-main { font-size: 17px; font-size: min(17px, calc((100vw - 110px) / 18.5)); letter-spacing: 0; gap: 6px; white-space: nowrap; justify-content: center; }
  .hac .hac-go .hac-go-sub { font-size: 11px; }
}

/* PDF出力時の文字の重なり・ずれ防止（ブラウザごとの文字幅の差を吸収する） */
.hac-pdf,
.hac-pdf * {
  letter-spacing: 0 !important;
  font-feature-settings: normal !important;
  font-variant-ligatures: none;
  text-rendering: auto !important;
}
.hac-pdf {
  box-sizing: border-box;
  font-family: "Noto Sans JP", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
}

/* ===== 分類リスクボタン（v1.5.4） ===== */
.hac .hac-rk-btn {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 44px; padding: 8px 18px; margin: 2px 0 14px;
  border: 1.5px solid #122540; border-radius: 999px;
  background: #fff; color: #122540;
  font-size: 14px; font-weight: 700; line-height: 1.4; text-align: left;
  transition: background-color .15s, color .15s;
  -webkit-tap-highlight-color: transparent;
}
.hac .hac-rk-btn:hover { background: #122540; color: #fff; }
.hac .hac-rk-btn:focus-visible { outline: 3px solid #F4C021; outline-offset: 2px; }
.hac .hac-rk-ic {
  flex: none; width: 20px; height: 20px; border-radius: 50%;
  background: #FBEFD0; color: #7A5A00;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 900; line-height: 1;
}

html.hac-rk-lock, html.hac-rk-lock body { overflow: hidden; }
.hac-rk {
  box-sizing: border-box;
  padding: 0; border: 0; margin: auto;
  width: min(920px, calc(100vw - 48px)); max-width: none;
  max-height: calc(100vh - 64px); max-height: calc(100dvh - 64px);
  border-radius: 16px; background: #fff; color: #1F2A37;
  box-shadow: 0 24px 60px rgba(18, 37, 64, .35);
  overflow: hidden;
  font-family: "Noto Sans JP", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
  font-size: 15px; line-height: 1.8; text-align: left;
}
.hac-rk *, .hac-rk *::before, .hac-rk *::after { box-sizing: border-box; }
.hac-rk[open] { display: flex; flex-direction: column; }
.hac-rk::backdrop { background: rgba(18, 37, 64, .55); }
.hac-rk-grip { display: none; }
.hac-rk-head {
  flex: none; display: flex; align-items: center; gap: 12px;
  padding: 18px 18px 14px 24px; border-bottom: 1px solid #DDE3EA;
}
.hac-rk-headin { flex: 1; min-width: 0; display: flex; align-items: center; gap: 14px; }
.hac-rk-headin .hrk-t { flex: 1; min-width: 0; }
.hac-rk-headin .hrk-bs { margin-left: 0; flex-wrap: wrap; justify-content: flex-end; }
.hac-rk .hac-rk-x {
  flex: none; width: 44px; height: 44px; padding: 0;
  border: 0; border-radius: 50%; background: #F1F5F9; color: #122540;
  font: inherit; font-size: 24px; line-height: 1; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.hac-rk .hac-rk-x:hover { background: #E3ECF5; }
.hac-rk-scroll {
  flex: 1 1 auto; min-height: 0; overflow-y: auto;
  overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
}
.hac-rk-scroll .hrk-body { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; padding: 20px 24px; }
.hac-rk-foot {
  flex: none; display: flex; justify-content: flex-end;
  padding: 14px 24px; border-top: 1px solid #DDE3EA; background: #fff;
}
.hac-rk .hac-rk-done {
  min-height: 48px; padding: 10px 28px;
  border: 0; border-radius: 999px; background: #122540; color: #fff;
  font: inherit; font-size: 15px; font-weight: 700; cursor: pointer;
}
.hac-rk .hac-rk-done:hover { background: #2E5F8A; }
.hac-rk .hac-rk-x:focus-visible, .hac-rk .hac-rk-done:focus-visible { outline: 3px solid #F4C021; outline-offset: 2px; }

@media (max-width: 767px) {
  .hac-rk {
    width: 100%; max-width: 100%;
    max-height: 88vh; max-height: 88dvh;
    margin: auto 0 0; border-radius: 18px 18px 0 0;
    box-shadow: 0 -8px 30px rgba(18, 37, 64, .25);
  }
  .hac-rk[open] { animation: hac-rk-up .25s ease-out; }
  .hac-rk-grip { display: block; flex: none; width: 40px; height: 5px; border-radius: 3px; background: #C9D2DC; margin: 8px auto 0; }
  .hac-rk-head { align-items: flex-start; padding: 10px 10px 12px 16px; }
  .hac-rk-headin { display: grid; grid-template-columns: 36px 1fr; gap: 6px 12px; align-items: start; }
  .hac-rk-headin .hrk-id { grid-column: 1; grid-row: 1 / span 2; width: 36px; height: 36px; font-size: 16px; }
  .hac-rk-headin .hrk-t { grid-column: 2; grid-row: 1; }
  .hac-rk-headin .hrk-bs { grid-column: 2; grid-row: 2; justify-content: flex-start; margin: 0; }
  .hac-rk-headin .hrk-name { font-size: 16px; }
  .hac-rk-scroll .hrk-body { grid-template-columns: 1fr; gap: 12px; padding: 14px 16px; }
  .hac-rk-foot { padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px)); }
  .hac-rk .hac-rk-done { width: 100%; }
}
@keyframes hac-rk-up { from { transform: translateY(100%); } to { transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .hac-rk[open] { animation: none; }
}
