@charset "UTF-8";
/*
    Template: swell
    Theme Name: SWELL CHILD
    Theme URI: https://swell-theme.com/
    Description: SWELLの子テーマ
    Version: 1.0.0
    Author: LOOS WEB STUDIO
    Author URI: https://loos-web-studio.com/

    License: GNU General Public License
    License URI: http://www.gnu.org/licenses/gpl.html
*/


// カテゴリーページのLCP画像を自動プリロード
function auto_preload_category_hero_images() {
    if (is_category() || is_archive()) {
        echo '<link rel="preload" as="image" href="" imagesrcset="" imagesizes="" fetchpriority="high">';
        // 最初に表示される画像を自動検出してプリロード
    }
}
add_action('wp_head', 'auto_preload_category_hero_images', 1);

.p-termContent{
	margin-top: 1em;
}

#main_content .p-toc {
    margin: 2em auto;
}


/*------------------------------検索結果の改修----------------*/

/* 検索フォームのスタイル */
.p-searchForm {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.p-searchForm .searchform {
    max-width: 500px;
    margin: 0 auto;
}

/* 検索結果件数のスタイル */
.p-searchCount {
    text-align: center;
    margin: 20px 0;
}

.c-searchCount__text {
    font-size: 14px;
    color: #6c757d;
    margin: 0;
}

.c-searchCount__number {
    font-weight: 600;
    color: #007cba;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
    .p-searchForm {
        padding: 15px;
        margin: 0 10px;
    }
    
    .c-searchCount__text {
        font-size: 13px;
    }
}


/*------------------------------タイトル部分のCSS（ユニーククラス名）----------------*/

/* ✅ タイトル部分（背景色あり） */
.roof-form-header-container {
    max-width: 960px;
    margin: 0 auto;
    padding: 25px 20px 20px;
    background: linear-gradient(135deg, #42A9BB 0%, #2E8A99 100%);
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
    scroll-margin-top: 110px; /* 固定ヘッダー対応のオフセット */
}

/* 背景装飾 */
.roof-form-header-container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    animation: roof-form-header-float 6s ease-in-out infinite;
}

@keyframes roof-form-header-float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(180deg); }
}

/* メインタイトル */
.roof-form-header-main-title {
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 8px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    position: relative;
    z-index: 2;
}

.roof-form-header-highlight {
    color: #FFFF73;
    font-weight: 900;
}

/* サブタイトル */
.roof-form-header-sub-title {
    font-size: 16px;
    font-weight: 600;
    background: rgba(255,255,255,0.9);
    color: #333;
    padding: 6px 16px;
    border-radius: 20px;
    display: inline-block;
    position: relative;
    z-index: 2;
}

/* 白背景部分 */
.roof-form-header-content-section {
    max-width: 960px;
    margin: 0 auto;
    padding: 25px 20px;
    background: white;
    text-align: center;
}

/* ディスクリプション */
.roof-form-header-description {
    font-size: 14px;
    margin-bottom: 20px;
    line-height: 1.6;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    color: #333;
}

/* 特徴リスト */
.roof-form-header-features {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.roof-form-header-feature-item {
    display: flex;
    align-items: center;
    gap: 6px;
    background: #f8f9fa;
    padding: 8px 16px;
    border-radius: 16px;
    border: 1px solid #e9ecef;
}

.roof-form-header-feature-icon {
    width: 18px;
    height: 18px;
    background: #4CAF50;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 9px;
    color: white;
}

.roof-form-header-feature-text {
    font-size: 13px;
    font-weight: 500;
    color: #333;
}

/* CTA（Call to Action）ボタン風 */
.roof-form-header-cta-text {
    font-size: 18px;
    font-weight: bold;
    background: #42A9BB;
    color: white;
    padding: 12px 25px;
    border-radius: 25px;
    display: inline-block;
    transition: all 0.3s ease;
    margin-bottom: 15px;
}

.roof-form-header-cta-text:hover {
    background: #2E8A99;
    transform: translateY(-2px);
}

.roof-form-header-cta-icon {
    margin: 0 6px;
    font-size: 16px;
}

/* フォーム配置用のスペース（PC版） */
.roof-form-header-form-container {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 20px;
    background: white;
}

/* PC版でのフォーム調整 */
@media screen and (min-width: 769px) {
    .roof-form-header-container {
        scroll-margin-top: 80px; /* PC版では少し控えめなオフセット */
    }
    
    .roof-form-header-form-container {
        max-width: 960px; /* PC版では幅制限 */
        margin: 0 auto; /* 中央配置 */
        padding: 0 20px;
    }
    
    #custom-inquiry-form-wrap {
        width: 100%;
        margin: 0;
    }
    
    #custom-inquiry-form {
        padding: 24px 0; /* 上下のみpadding */
        width: 100%;
    }
}

/* レスポンシブ対応 */
@media screen and (max-width: 768px) {
    /* スマホ版：タイトル部分を画面いっぱいに */
    .roof-form-header-container {
        width: 100vw; /* ビューポート幅いっぱい */
        max-width: none; /* max-width制限を削除 */
        margin: 0;
        margin-left: calc(-50vw + 50%); /* 画面中央から左端まで広げる */
        padding: 20px 0 15px; /* 左右のpaddingを0に */
        position: relative;
        scroll-margin-top: 100px; /* スマホ版では少し多めのオフセット */
    }

    .roof-form-header-content-section {
        width: 100vw; /* ビューポート幅いっぱい */
        max-width: none; /* max-width制限を削除 */
        margin: 0;
        margin-left: calc(-50vw + 50%); /* 画面中央から左端まで広げる */
        padding: 20px 15px;
        position: relative;
    }

    .roof-form-header-form-container {
        width: 100vw; /* ビューポート幅いっぱい */
        max-width: none; /* max-width制限を削除 */
        margin: 0;
        margin-left: calc(-50vw + 50%); /* 画面中央から左端まで広げる */
        padding: 0 15px; /* 少しだけ内側に余白 */
    }

    .roof-form-header-main-title {
        font-size: 20px;
        line-height: 1.3;
        padding: 0 15px; /* タイトルにも内側余白を追加 */
    }

    .roof-form-header-sub-title {
        font-size: 14px;
        padding: 5px 14px;
    }

    .roof-form-header-description {
        font-size: 13px;
        line-height: 1.5;
        margin-bottom: 15px;
    }

    .roof-form-header-features {
        gap: 12px;
        margin-bottom: 15px;
    }

    .roof-form-header-feature-item {
        padding: 6px 12px;
    }

    .roof-form-header-feature-text {
        font-size: 12px;
    }

    .roof-form-header-cta-text {
        font-size: 16px;
        padding: 10px 20px;
        margin-bottom: 10px;
    }
}

/*------------------------------一括問い合わせフォーム（改修版）----------------*/
/* ✅ フォーム全体 */
#custom-inquiry-form-wrap {
  width: 100%;
  background: #fff;
}

#custom-inquiry-form {
  width: 100%;
}

/* ✅ 質問ブロック全体（テーブルレイアウト） */
.form-question-row {
  display: table;
  width: 100%;
  margin-bottom: 8px; /* 超タイトに詰める */
}

/* ✅ 左側：質問タイトル */
.form-label {
  display: table-cell;
  width: 260px;
  background-color: #F4F4F4;
  color: #000;
  padding: 12px;
  font-weight: bold;
  vertical-align: middle;
  text-align: left;
}

/* ✅ 質問タイトル内の必須マーク */
.form-label .required {
  display: inline-block;
  margin-top: 4px;
  background: red;
  color: #fff;
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 4px;
}

/* ✅ 質問タイトル内の任意マーク */
.form-label .optional {
  display: inline-block;
  margin-top: 4px;
  background: #999;
  color: #fff;
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 4px;
}

/* ✅ 右側：回答部分 */
.form-input {
  display: table-cell;
  padding: 12px;
  vertical-align: middle;
}

/* ✅ 回答内のボックスグリッド（2列固定） */
.radio-box-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(2, 1fr); /* 常に2列固定 */
  width: 100%; /* 幅を100%に */
}

/* ✅ ラジオボックス（選択肢1個分） */
.radio-box {
  display: flex;
  border: 2px solid #ccc;
  border-radius: 8px;
  padding: 10px;
  background: #fff;
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: center;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  width: 100%; /* 幅を100%に */
  box-sizing: border-box; /* paddingとborderを幅に含める */
}

.radio-box:hover {
  border-color: #0073aa;
}

.radio-box input[type="radio"] {
  display: none;
}

.radio-box-content {
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 500;
  font-size: 14px;
  text-align: center;
  width: 100%;
}

/* ★選択されたら背景色＋枠線色を変える */
@supports(selector(:has(*))) {
  .radio-box:has(input[type="radio"]:checked) {
    border-color: #0073AA;
    background: #EAF4FC;
  }
  .radio-box:has(input[type="radio"]:checked) .radio-box-content {
    color: #597CB8;
    font-weight: bold;
  }
}

/* 古いブラウザ対応 */
.radio-box input[type="radio"]:checked + .radio-box-content {
  background: #EAF4FC;
  border-radius: 6px;
  color: #597CB8;
  font-weight: bold;
}

/* ✅ テキスト入力欄・テキストエリア */
input[type="text"],
input[type="email"],
input[type="tel"],
textarea {
  width: 100%;
  max-width: 100%; /* 最大幅も100%に制限 */
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 14px;
  box-sizing: border-box; /* paddingとborderを幅に含める */
}

textarea {
  min-height: 130px;
}

/* ✅ プライバシーポリシーと送信ボタンの独立レイアウト */
.center-align {
  text-align: center;
  margin: 24px 0 16px;
}

.privacy {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
}

/* ✅ 送信ボタン（幅80%＋影付き） */
.submit-button {
  background-color: #00B894;
  color: #fff;
  width: 80%;
  max-width: 400px;
  padding: 14px 0;
  font-size: 18px;
  font-weight: bold;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  transition: background-color 0.3s, box-shadow 0.3s;
  display: block;
  margin: 0 auto;
  text-align: center;
}

.submit-button:hover {
  background-color: #00997A;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.25);
}

/* 質問タイトル */
.label-title {
  font-size: 16px;
  font-weight: bold;
  margin-bottom: 6px;
}

/* --- スマホサイズ対応（画面幅768px以下） --- */
@media screen and (max-width: 768px) {

  /* フォーム全体もスマホで画面いっぱいに */
  #custom-inquiry-form-wrap {
    width: 100%;
    max-width: none; /* max-width制限を削除 */
    margin: 0;
    padding: 0;
  }

  #custom-inquiry-form {
    width: 100%;
    max-width: none; /* max-width制限を削除 */
    padding: 20px 0; /* 左右paddingを0に */
  }

  /* 質問ブロック全体：縦並びに */
  .form-question-row {
    display: block;
    margin-bottom: 16px;
    width: 100%; /* 横幅を100%に */
  }

  /* ラベルと回答欄：縦並びに */
  .form-label,
  .form-input {
    display: block;
    width: 100%;
    max-width: none; /* max-width制限を削除 */
    padding: 8px 0; /* 左右paddingを0に調整 */
  }

  /* 質問タイトル（背景色＋黒文字） */
  .form-label {
    background-color: #F4F4F4;
    color: #000;
    text-align: left;
    font-size: 15px;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px; /* 内側に適切な余白 */
    margin-bottom: 8px; /* 下にマージン追加 */
  }

  .form-input {
    padding: 0 12px 8px; /* 左右と下にpadding */
  }

  /* 設問タイトル */
  .label-title {
    font-size: 15px;
    font-weight: bold;
  }

  /* 必須マーク（左側に配置） */
  #custom-inquiry-form .form-label .required {
    display: inline-block;
    background: #e74c3c;
    color: #fff;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 3px;
    order: -1;
    flex-shrink: 0;
    margin-top: 0;
  }

  /* 任意マーク（左側に配置） */
  #custom-inquiry-form .form-label .optional {
    display: inline-block;
    background: #999;
    color: #fff;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 3px;
    order: -1;
    flex-shrink: 0;
    margin-top: 0;
  }

  /* ラジオボックスグリッド：スマホでは2列を維持 */
  .radio-box-grid {
    display: grid;
    grid-template-columns: 1fr 1fr; /* スマホでは2列固定 */
    gap: 12px;
    width: 100%; /* 幅を100%に */
    max-width: none; /* max-width制限を削除 */
  }

  /* ラジオボックス自体（枠） */
  .radio-box {
    margin-bottom: 0;
    padding: 12px 8px;
    border: 2px solid #ccc;
    border-radius: 8px;
    background: #fff;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%; /* 幅を100%に */
    box-sizing: border-box; /* paddingとborderを幅に含める */
  }

  .radio-box:hover {
    border-color: #0073aa;
  }

  .radio-box input[type="radio"] {
    display: none;
  }

  /* ラジオボックスの中身（テキストを中央寄せ） */
  .radio-box-content {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-weight: 500;
    font-size: 13px;
    line-height: 1.3;
  }

  /* 選択状態の表示 */
  @supports(selector(:has(*))) {
    .radio-box:has(input[type="radio"]:checked) {
      border-color: #0073AA;
      background: #EAF4FC;
    }
    .radio-box:has(input[type="radio"]:checked) .radio-box-content {
      color: #597CB8;
      font-weight: bold;
    }
  }

  .radio-box input[type="radio"]:checked + .radio-box-content {
    background: #eaf4fc;
    border-radius: 6px;
    color: #597CB8;
    font-weight: bold;
  }

  /* テキスト入力欄・テキストエリア */
  input[type="text"],
  input[type="email"],
  input[type="tel"],
  textarea {
    width: 100%;
    max-width: 100%; /* 最大幅も100%に制限 */
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 14px;
    box-sizing: border-box; /* paddingとborderを幅に含める */
  }

  textarea {
    min-height: 130px;
  }

  /* プライバシーポリシーと送信ボタン中央寄せ */
  .center-align {
    text-align: center;
    margin: 24px 0 16px;
    width: 100%; /* 幅を100%に */
  }

  .privacy {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
  }

  /* 送信ボタンもスマホサイズ調整 */
  .submit-button {
    background-color: #00B894;
    color: #fff;
    width: 90%;
    max-width: 360px;
    padding: 14px 0;
    font-size: 18px;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transition: background-color 0.3s, box-shadow 0.3s;
    display: block;
    margin: 16px auto 0;
    text-align: center;
    box-sizing: border-box; /* paddingとborderを幅に含める */
  }

  .submit-button:hover {
    background-color: #00997A;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.25);
  }
}













	
/*--------------------無料相談フォーム誘導ボタン----------------*/
	
.button-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: nowrap;
  margin: 20px 0;
  margin-bottom: 0;
}

.custom-box-button {
  display: flex;
  align-items: center;
  **justify-content: flex-start;** /* ←左寄せに変更 */
  width: 80%;
  max-width: 500px;
  **padding: 8px 15px;** /* ←縦横のpaddingを小さくしてコンパクト化 */
  background: linear-gradient(45deg, #00c853, #64dd17);
  color: #fff;
  text-decoration: none;
  border-radius: 8px;
  font-size: 18px;
  font-weight: bold;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
  white-space: normal; /* ←改行許可（nowrapは外す） */
}

.custom-box-button:hover {
  background: linear-gradient(45deg, #00b248, #558b2f);
  box-shadow: 0 6px 8px rgba(0, 0, 0, 0.3);
}

.button-icon {
  margin-right: 10px;
  font-size: 22px;
}

.button-text {
  font-size: 16px;
  **line-height: 1.2;** /* ←行間をできるだけ詰める */
  text-align: left; /* ←テキストも左寄せ */
}

.pointing-icon-img {
  width: 40px;
  height: auto;
  animation: bounce 1.5s infinite;
}

@keyframes bounce {
  0%, 100% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(-5px);
  }
}

@media (max-width: 480px) {
  .custom-box-button {
    font-size: 15px;
    padding: 8px 12px;
  }
  .button-text {
    font-size: 15px;
    line-height: 1.2;
  }
  .button-icon {
    font-size: 20px;
  }
  .pointing-icon-img {
    width: 32px;
  }
}


:root {
  --swell-h2-margin--y: 2em;
}
	
@media (min-width: 768px) {
  .custom-box-button {
    padding: 6px 10px;
  }
}