/*
Theme Name: Lightning Child
Template: lightning
Version: 0.6.1
*/

/* ============================================
▼ 共通スタイル設定
============================================ */

/* --- 横スクロール防止 --- */
body {
  overflow-x: hidden;
}

/* --- 投稿者情報・メタ情報など不要な表示を非表示にする --- */
.entry-meta-item-author,
.entry-meta-data-list,
.vk_post_imgOuter_singleTermLabel,
.site-footer-copyright p:nth-of-type(2),
.swiper-pagination,
.page_top_btn {
  display: none !important;
}

/* --- h5見出しに下線を追加 --- */
h5 {
  border-bottom: 0.5px solid #333;
  padding-bottom: 5px;
}

/* ============================================
▼ ヘッダー関連のスタイル
============================================ */

/* --- ヘッダー全体のレイアウトと背景色（共通） --- */
.site-header,
body.header_scrolled #site-header {
  height: 70px !important;
  display: flex;
  align-items: center;
  padding: 0 20px;
  box-sizing: border-box;
  background-color: rgba(137, 137, 137, 0.8);
}

/* --- スクロール前のヘッダーを上に重ねて表示 --- */
body:not(.header_scrolled) #site-header {
  position: absolute;
}

/* --- ロゴ画像の高さ制限 --- */
.site-header-logo img {
  max-height: 40px;
  width: auto;
  height: auto;
}

/* --- スマホ・タブレット表示（1024px以下） --- */
@media screen and (max-width: 1024px) {
  /* --- スマホ時のヘッダー高さ調整 --- */
  .site-header {
    height: 45px !important;
  }
}

/* ============================================
▼ グローバルナビゲーション設定
============================================ */

/* --- グローバルナビのレイアウト調整 --- */
#global-nav {
  display: flex;
  align-items: center;
  height: 7%;
}

/* --- ナビゲーションリンクの見た目とホバー時の色変更 --- */
#global-nav li a {
  display: flex;
  align-items: center;
  height: 60px;
  padding: 10px 30px;
  font-size: 1rem;
  color: #fff;
  white-space: nowrap;
  text-decoration: none;
  transition: color 0.3s ease;
}

#global-nav li a:hover {
  color: #000;
}

/* --- ナビゲーション項目の下線（通常・ホバー時） --- */
.global-nav-list > li::before {
  border-bottom: 1px solid #fff !important;
}

.global-nav-list > li:hover::before {
  border-bottom-color: #000 !important;
}

/* --- スマホ・タブレット表示（1024px以下） --- */
@media screen and (max-width: 1024px) {
  /* --- グローバルナビゲーションを非表示 --- */
  #global-nav {
    display: none !important;
  }
}

/* ============================================
▼ 固定ページのヘッダー（アイキャッチ部分）
============================================ */

/* --- ページヘッダーの背景画像とレイアウト設定 --- */
.page-header {
  height: 600px;
  min-height: min(360px, 50vw);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 0 80px;
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  color: #fff;
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  text-align: left;
  position: relative;
  margin-top: 0 !important;
}

/* --- ページヘッダーの背景に半透明の黒いレイヤーを追加 --- */
.page-header::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1;
}

/* --- ヘッダー内のテキストを前面に表示 --- */
.page-header > * {
  position: relative;
  z-index: 2;
}

/* --- ヘッダー見出しのスタイル --- */
.page-header h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin: 0;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  line-height: 1.0;
}

/* --- ヘッダーの抜粋（サブテキスト） --- */
.page-header .page-excerpt {
  margin-top: 12px;
  font-size: 1.2rem;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.75);
  max-width: 600px;
  line-height: 1.4;
}

/* --- スマホ・タブレット表示（1024px以下） --- */
@media screen and (max-width: 1024px) {
  /* --- ヘッダー画像の縮小対応 --- */
  .page-header {
    height: 400px !important;
    background-repeat: no-repeat;
    background-position: center top;
    background-attachment: scroll;
  }

  /* --- 見出しのフォントサイズ調整 --- */
  .page-header h1 {
    font-size: 2.0rem;
  }
}

/* ============================================
▼ 施工事例スライダー（Swiper本体）
============================================ */

/* --- スライダー全体の幅とパディング調整 --- */
.works-slider {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px 30px;
  box-sizing: border-box;
  overflow: hidden;
}

/* --- スライド1枚ごとの見た目 --- */
.works-slider .swiper-slide {
  background: transparent;
  border: none;
  text-align: center;
  padding: 15px;
  transition: transform 0.3s;
  flex-shrink: 0;
  box-sizing: border-box;
}

/* ============================================
▼ 施工事例カード（スライド内コンテンツ）
============================================ */

/* --- 画像のスタイルとホバー時の明度調整 --- */
.work-card img {
  width: 100%;
  height: auto;
  display: block;
  margin-bottom: 10px;
  transition: filter 0.5s ease;
}

.work-card:hover img {
  filter: brightness(70%);
}

/* --- カードのタイトル装飾とホバー時の強調 --- */
.work-card h3 {
  border-bottom: 1px solid #333 !important;
  background: none !important;
  box-shadow: none !important;
  transition: color 0.3s ease, text-shadow 0.3s ease;
}

.work-card:hover h3 {
  color: #000 !important;
  text-shadow: 0 0 5px rgba(255, 255, 255, 0.7);
}

/* --- タイトル前後の不要装飾を無効化 --- */
.work-card h3::before,
.work-card h3::after {
  content: none !important;
  border: none !important;
  background: none !important;
  box-shadow: none !important;
}

/* --- 投稿日付のスタイル --- */
.work-card time {
  font-size: 0.875rem;
  color: #888;
}

/* ============================================
▼ スライダー矢印（前へ・次へボタン）
============================================ */

/* --- 共通スタイル（位置・デザイン） --- */
.swiper-button-prev,
.swiper-button-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  color: #333;
  font-size: 24px;
  background: none;
  border: none;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
}

/* --- 矢印の左右位置 --- */
.swiper-button-prev {
  left: 0;
}

.swiper-button-next {
  right: 0;
}

/* ============================================
▼ お問い合わせボタン
============================================ */

/* --- 共通スタイル --- */
.floating-contact {
  z-index: 9999;
  font-family: "Yu Gothic", "Segoe UI", sans-serif;
  position: fixed;
  background: transparent;
  padding: 0;
  border-radius: 8px;
  display: flex;
  gap: 10px;
}

.floating-contact .btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 16px;
  color: #444;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  box-sizing: border-box;
  border-left: 3px solid transparent;
  transition: background-color 0.3s ease, border-left-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
  background-color: #e0e0e0;
  border-radius: 8px;
}

.floating-contact .btn i {
  font-size: 20px;
  margin-right: 8px;
  vertical-align: middle;
  color: #666;
  transition: color 0.3s ease;
}

.floating-contact .btn:hover {
  box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.floating-contact .btn:hover i {
  color: inherit;
}

/* --- btnごとの色設定 --- */
.btn.line {
  border-left-color: #06C755;
}

.btn.line:hover {
  background-color: #c0f2d8;
  color: #06C755;
}

.btn.tel {
  border-left-color: #007AFF;
}

.btn.tel:hover {
  background-color: #cce5ff;
  color: #007AFF;
}

.btn.contact {
  border-left-color: #FF9500;
}

.btn.contact:hover {
  background-color: #ffe5b4;
  color: #FF9500;
}

/* --- スマホ表示：画面下部に横並び（767px以下） --- */
@media screen and (max-width: 767px) {
  .floating-contact {
    bottom: 0;
    top: auto;
    right: 0;
    width: 100%;
    background: #f9f9f9;
    border-top: 1px solid #ddd;
    flex-direction: row;
    padding: 10px 15px;
    border-radius: 0;
  }

  .floating-contact .btn {
    flex-grow: 1;
    margin: 0;
    border-left: none;
    border-right: 1px solid #ddd;
    justify-content: center;
    padding: 12px 0;
    font-size: 14px;
    border-radius: 6px; /* 0 → 6pxで少し丸く */
  }

  .floating-contact .btn:last-child {
    border-right: none;
  }

  .floating-contact .btn i {
    margin-right: 6px;
    font-size: 18px;
  }

  /* --- 下部メニューの高さ分、bodyに余白追加 --- */
  body {
    padding-bottom: 60px;
  }
}

/* --- PC・タブレット表示（768px以上） --- */
@media screen and (min-width: 768px) {
  .floating-contact {
    top: auto;
    bottom: 40px;
    right: 0px;
    width: auto;
    padding: 0 0 0 0;
    flex-direction: column;
  }

  .floating-contact .btn {
    width: 80px;
    height: 80px;
    padding: 8px 0;
    border-radius: 10px 0 0 10px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    margin: 0;
    border-left: none;
    font-size: 12px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    background-color: rgba(224, 224, 224, 0.85);
  }

  .floating-contact .btn i {
    font-size: 28px;
    margin: 0 0 6px 0;
  }
}
