/* --- 基本（背景や余白） --- */
@page {
  size: A4 portrait;           /* A4縦。横は landscape */
  /* margin: 12mm;                余白は閲覧目的に合わせて調整 */
}
@media print {
  html, body {
    color: #000;
    background: #fff;
    -webkit-print-color-adjust: exact; /* 背景色や図形色を忠実に */
    print-color-adjust: exact;
  }

  /* 不要要素を非表示（ヘッダー、フッター、ナビ等） */
  #h_fixed, footer, aside, #news-list,
  .site-header, .site-footer, .sidebar, .pagetop,
  .cookie-banner, .ad, .breadcrumb, .screen-only, .no-print {
    display: none !important;
  }

  /* コンテンツ幅をフルに */
  /* .site-main, main, .container {
    width: 100% !important;
    max-width: none !important;
  } */

  /* 余白・行間を印刷向けに */
  /* body { line-height: 1.5; }
  p, li { orphans: 3; widows: 3; } */

  /* 画像や表のはみ出し防止 */
  /* img, svg, canvas, video { max-width: 100% !important; height: auto !important; }
  table { width: 100%; border-collapse: collapse; }
  th, td { border: 1px solid #999; padding: 4px 6px; } */

  /* テーブル見出しを各ページ先頭に繰り返す */
  thead { display: table-header-group; }
  tfoot { display: table-footer-group; }

  /* セクション途中改ページを避ける（必要に応じて） */
  h1, h2, h3, h4 { page-break-after: avoid; break-after: avoid-page; }
  .card, .box, .section {
    break-inside: avoid;
    page-break-inside: avoid;
  }

  /* 影やアニメは無効化してインク節約＆汚れ防止 */
  * { box-shadow: none !important; text-shadow: none !important; animation: none !important; }

  /* リンク先URLを本文に出す（資料化に便利） */
  a[href^="http"]:after {
    content: " (" attr(href) ")";
    font-size: 90%;
  }
  /* ページ内リンクや電話・メールはURL表示しない */
  a[href^="#"]:after, a[href^="tel:"]:after, a[href^="mailto:"]:after { content: ""; }

  /* Bootstrap使用時の細かい調整（任意） */
  /* .row, [class*="col-"] { display: block !important; width: 100% !important; padding: 0 !important; }
  .btn, .badge, .alert { border: 1px solid #777 !important; background: transparent !important; color: #000 !important; } */
}

  /* --- 共通：ボタンの外観をアウトライン化 --- */
  .btn,
  .btn[class*="btn-"],
  a.btn,
  button.btn,
  .wp-block-button__link,
  .wp-element-button {
    background: transparent !important;      /* 背景を無色 */
    background-image: none !important;       /* グラデ等も無効 */
    color: #000 !important;                  /* 文字は黒 */
    border: 1px solid #000 !important;       /* 黒枠 */
    box-shadow: none !important;             /* 影を消す */
    text-shadow: none !important;
  }

  /* --- 特に .btn-dark を確実に上書き --- */
  .btn.btn-dark,
  a.btn.btn-dark,
  button.btn.btn-dark {
    background: transparent !important;
    color: #000 !important;
    border-color: #000 !important;
  }

  /* --- WPブロックの囲み（.wp-block-button）経由の強い指定に勝つ用 --- */
  .wp-block-button .wp-block-button__link,
  .wp-block-button .wp-element-button {
    background: transparent !important;
    color: #000 !important;
    border: 1px solid #000 !important;
  }

  /* --- アイコン（Font Awesome等）も黒に --- */
  .btn i,
  .wp-block-button__link i,
  .wp-element-button i {
    color: #000 !important;
  }

  /* --- hover/active系の色を無効化（念のため） --- */
  .btn:hover,
  .btn:active,
  .btn:focus,
  .wp-block-button__link:hover,
  .wp-element-button:hover {
    background: transparent !important;
    color: #000 !important;
    border-color: #000 !important;
  }

  /* --- インライン style の opacity などに備える（任意） --- */
  .btn[style*="opacity"] { opacity: 1 !important; }