/*
Theme Name: AFFINGER Child
Template: affinger
Description: AFFINGER6 対応
Version: 20210719
*/

/* ================================
   Media Queries（統一）
   - SP:  ～599px
   - TB:  600～959px
   - PC:  960px～
   ================================ */

/* SPのみ */
@media screen and (max-width: 599px) {
  /* スマホ専用スタイルがあればここに */
}

/* タブレットのみ */
@media screen and (min-width: 600px) and (max-width: 959px) {
  /* タブレット専用スタイルがあればここに */
}

/* PCのみ */
@media screen and (min-width: 960px) {
  /* PC専用スタイルがあればここに */
  .sp-only-button {
    display: none !important;
  }
}

/* ================================
   ページ別（白文字化／レイアウト）
   ※ 意図しない全ページ反映を防ぐため page-id 指定でスコープ
   ================================ */

/* 保全事業ページ（ID:347）: 文字を白＆不透明に */
.page-id-347 .entry-title,
.page-id-347 .entry-content,
.page-id-347 .entry-content * {
  color: #ffffff !important;
  opacity: 1 !important;
}

.page-id-347 .wp-block-st-block-headline {
  margin-left: 0 !important;
  padding-left: 0 !important;
  text-align: left !important;
}

/* ページID:349 タイトル白 */
.page-id-349 .entry-title {
  color: #ffffff !important;
}

/* ページID:349 見出し類の白＆不透明 */
.page-id-349 h1,
.page-id-349 .post_title,
.page-id-349 .entry-title,
.page-id-349 .page-title {
  color: #ffffff !important;
  opacity: 1 !important;
}

/* ページID:345：タイトル／本文／パンくず白 */
.page-id-345 .entry-title,
.page-id-345 .entry-content,
.page-id-345 .breadcrumb,
.page-id-345 .breadcrumb a {
  color: #ffffff !important;
}

/* 事業名などのテキスト白（対象ページのみ） */
.page-id-345 .entry-content .st-text-center,
.page-id-345 .entry-content .st-kaiwa-box,
.page-id-345 .entry-content .st-catname,
.page-id-345 .entry-content .st-cardbox .st-cardbox-title,
.page-id-345 .entry-content h3,
.page-id-347 .entry-content .st-text-center,
.page-id-347 .entry-content .st-kaiwa-box,
.page-id-347 .entry-content .st-catname,
.page-id-347 .entry-content .st-cardbox .st-cardbox-title,
.page-id-347 .entry-content h3,
.page-id-349 .entry-content .st-text-center,
.page-id-349 .entry-content .st-kaiwa-box,
.page-id-349 .entry-content .st-catname,
.page-id-349 .entry-content .st-cardbox .st-cardbox-title,
.page-id-349 .entry-content h3 {
  color: #ffffff !important;
}

/* 円の下などのリンクも白（対象ページのみ） */
.page-id-345 .entry-content a,
.page-id-347 .entry-content a,
.page-id-349 .entry-content a {
  color: #ffffff !important;
}

/* キャプション内リンクの体裁（必要なら白を維持） */
.wp-element-caption a {
  font-size: 1.6em;
  font-weight: bold;
  color: #ffffff;
  text-align: center;
  display: block;
}

/* ================================
   Contact Form 7（フォーム可読性向上）
   ================================ */

/* 本体レイアウト */
div.wpcf7,
div[id^="wpcf7-f"] {
  max-width: 600px;
  margin: 0 auto !important;
  padding: 20px;
}

/* 入力欄の統一 */
div.wpcf7 input[type="text"],
div.wpcf7 input[type="email"],
div.wpcf7 textarea,
div[id^="wpcf7-f"] input[type="text"],
div[id^="wpcf7-f"] input[type="email"],
div[id^="wpcf7-f"] textarea {
  width: 100% !important;
  box-sizing: border-box;
  padding: 10px;
  margin-bottom: 16px;
  background-color: #fff !important;
  color: #000 !important;
}

/* プレースホルダ黒 */
div.wpcf7 input::placeholder,
div.wpcf7 textarea::placeholder,
div[id^="wpcf7-f"] input::placeholder,
div[id^="wpcf7-f"] textarea::placeholder {
  color: #000 !important;
  opacity: 1 !important;
}

/* 送信ボタン */
div.wpcf7 input[type="submit"],
div[id^="wpcf7-f"] input[type="submit"] {
  width: 100% !important;
  padding: 12px;
  font-size: 16px;
  font-weight: bold;
  color: #fff !important;
  background-color: #0033cc !important;
  border: 1px solid #ffffff;
  border-radius: 6px;
  cursor: pointer;
  -webkit-text-fill-color: #ffffff !important;
}

/* フォーム内リンクは可読色に（全体の白リンク指定を打ち消し） */
div.wpcf7 a,
div[id^="wpcf7-f"] a {
  color: #0033cc !important;
  text-decoration: underline;
}
