/*
Theme Name: Saijo Original Theme
Theme URI: https://saijosyoji.com/
Author: Yusaku Ito
Author URI: https://c-foxs.com/
Description: 西條商事用オリジナルテーマ
Version: 1.0
Text Domain: saijo-theme
*/

/* -----------------------------------------------------
  フォント設定
----------------------------------------------------- */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@400;500;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Roboto+Condensed:wght@300;700&display=swap');

/* -----------------------------------------------------
  ベース設定
----------------------------------------------------- */
:root {
  --color-main-red: #e60012;   /* メインレッド */
  --color-base-bg : #ffffff;
  --color-base-text: #333333;
  --color-accent: #00bcd4;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 62.5%; /* 1rem = 10px */
  scroll-behavior: smooth;
}

body {
  margin: 0;
  padding: 0;
  font-family: 'Noto Sans JP', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 1.6rem;
  line-height: 1.7;
  color: var(--color-base-text);
  background-color: var(--color-base-bg);
}

img {
  max-width: 100%;
  height: auto;
  vertical-align: bottom;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  text-decoration: none;
}

/* スクリーンリーダー専用テキスト */
.screen-reader-text {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* 英字見出し用 */
.en-heading {
  font-family: 'Roboto Condensed', sans-serif;
}

/* ページ全体 */
.site {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ヘッダー固定分の余白（PC：上下２段ぶん） */
.site-main {
  flex: 1 0 auto;
  /* padding-top: 120px; */
}

/* 管理バーがある場合（ログイン時） */
.admin-bar .site-header {
  top: 32px;
}

@media (max-width: 782px) {
  .admin-bar .site-header {
    top: 46px;
  }
}

/* -----------------------------------------------------
  ヘッダー共通
  PC：
    上段 右にメール＆Instagram（右端揃え）
    下段 左にロゴ、グロナビは右寄せ（右端を上段と揃える）
  SP：
    上段非表示／ナビ非表示／ロゴ＋ハンバーガー
----------------------------------------------------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 999;
  width: 100%;
  background-color: #ffffff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
  transition: box-shadow 0.3s ease, background-color 0.3s ease;
}

/* スクロール時：わずかにシャドウ強め */
.site-header.scrolled {
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.12);
}

/* 上段：メール＆Instagram（PCのみ表示）
   → 画面右側に寄せつつ、右端を下段と揃えるため padding-right を固定値に */
.site-header__upper {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 16px;
  margin: 0;
  padding: 8px 60px 4px;  /* ← 右端位置を決める値。下段と合わせる */
}

.header-upper__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.header-upper__icon img {
  width: 24px;
  height: auto;
  display: block;
}

.header-upper__icon:hover {
  opacity: 0.85;
  transform: translateY(-1px);
}

/* 下段：ロゴ（左）＋グロナビ＋SPハンバーガー
   → ロゴを左側に寄せ、グロナビは右端寄せ。右端は上段と揃えるため padding-right を上段と同じ 60px に。 */
.site-header__lower {
  display: flex;
  align-items: center;
  margin: 0;
  padding: 6px 60px 10px; /* ← 右端位置を上段と揃える */
}

/* -----------------------------------------------------
  ロゴ（左端寄り）
----------------------------------------------------- */
.site-header__logo {
  order: 0;
}

.site-header__logo a {
  display: inline-flex;
  align-items: center;
}

.site-header__logo-image {
  display: block;
  height: 48px;
  width: auto;
}

/* WPカスタムロゴ用（もし使う場合） */
.site-header .custom-logo {
  max-height: 48px;
  width: auto;
}

/* -----------------------------------------------------
  PC用グローバルナビ
  → ロゴの右側に配置しつつ、右端は padding-right 60px で揃える
----------------------------------------------------- */
.global-nav {
  order: 1;
  margin-left: auto;   /* ロゴとの間は自動で空けつつ、全体を右端に寄せる */
}

.global-nav__list {
  display: flex;
  align-items: center;
  gap: 24px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.global-nav__list li {
  position: relative;
}

.global-nav__list a {
  position: relative;
  display: inline-block;
  padding: 4px 0;
  font-size: 1.5rem;
  font-weight: 500;
  color: #444444;
  transition: opacity 0.25s ease, color 0.25s ease;
}

/* 下線アニメーション */
.global-nav__list a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0;
  height: 2px;
  background-color: var(--color-main-red);
  transition: width 0.25s ease;
}

.global-nav__list a:hover {
  opacity: 0.8;
  color: var(--color-main-red);
}

.global-nav__list a:hover::after {
  width: 100%;
}

/* 現在ページ用（WP付与クラス） */
.global-nav__list .current-menu-item > a::after,
.global-nav__list .current_page_item > a::after {
  width: 100%;
}

/* -----------------------------------------------------
  ハンバーガーメニュー（SPのみ表示）
----------------------------------------------------- */
.header-hamburger {
  order: 2;
  display: none; /* PCでは非表示 */
  width: 28px;
  height: 22px;
  padding: 0;
  margin-left: 12px;
  border: none;
  background: none;
  cursor: pointer;
}

.header-hamburger span {
  display: block;
  width: 100%;
  height: 2px;
  margin-bottom: 4px;
  background-color: var(--color-main-red);
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.header-hamburger span:last-child {
  margin-bottom: 0;
}

/* 開いたときに「×」に変形 */
body.is-drawer-open .header-hamburger span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}
body.is-drawer-open .header-hamburger span:nth-child(2) {
  opacity: 0;
}
body.is-drawer-open .header-hamburger span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* -----------------------------------------------------
  SPドロワーメニュー（全画面）
----------------------------------------------------- */

/* PCでは非表示 */
.sp-drawer,
.sp-drawer-overlay {
  display: none;
}

/* SPのみ表示 */
@media (max-width: 768px) {

  .sp-drawer-overlay {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
    z-index: 998;
  }

  /* 全画面の白いドロワー本体（右から左にスライドイン） */
  .sp-drawer {
    display: flex;
    flex-direction: column;
    position: fixed;
    inset: 0;
    background-color: #ffffff;

    transform: translateX(100%);  /* 画面の右外側で待機 */
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition:
      transform 0.25s ease,
      opacity 0.25s ease,
      visibility 0.25s ease;
    z-index: 999;
  }

  .sp-drawer__inner {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 80px 0 0; /* 上はヘッダー分を空ける */
  }

  /* メニュー（中央〜上部） */
  .sp-drawer__nav {
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .sp-drawer__list {
    list-style: none;
    margin: 0;
    padding: 0;
    text-align: center;
  }

  .sp-drawer__list li + li {
    margin-top: 20px;
  }

  .sp-drawer__list a {
    display: inline-block;
    font-size: 1.8rem;
    font-weight: 500;
    color: #333333;
    padding-bottom: 6px;
    border-bottom: 1px solid #eeeeee;
  }

  .sp-drawer__list a:hover {
    opacity: 0.8;
    color: var(--color-main-red);
  }

  /* 下部：フッターと同じブロック */
  .sp-drawer__footer {
    flex-shrink: 0;
    background-color: var(--color-main-red);
    color: #ffffff;
    padding: 24px 16px 20px;  /* 左右いっぱいの赤帯＋左右16pxの余白 */
  }

  .sp-drawer__footer-inner {
    position: relative;
    max-width: none;
    margin: 0;
  }


  /* ここは既存の footer と同じクラスを使っているので、
     footer のCSSがそのまま効きます */

  /* ドロワーを開いたときの状態 */
  body.is-drawer-open {
    overflow: hidden;
  }

  body.is-drawer-open .sp-drawer {
    transform: translateX(0);    /* 右→左にスライドイン */
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  body.is-drawer-open .sp-drawer-overlay {
    opacity: 1;
    visibility: visible;
  }

    /* 右上の × ボタン */
  .sp-drawer__close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 24px;
    height: 24px;
    padding: 0;
    border: none;
    background: none;
    cursor: pointer;
    z-index: 1000; /* 念のため一番上 */
  }

  .sp-drawer__close span {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 2px;
    background-color: var(--color-main-red);
    transform-origin: center;
  }

  .sp-drawer__close span:nth-child(1) {
    transform: translateY(-50%) rotate(45deg);
  }

  .sp-drawer__close span:nth-child(2) {
    transform: translateY(-50%) rotate(-45deg);
  }

}

/* -----------------------------------------------------
  メインビジュアル（ウィンドウ高フル）
----------------------------------------------------- */
.main-visual {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

.main-visual__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.main-visual__inner {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 8%;
  color: #ffffff;
}

.main-visual__catch {
  font-size: 3.2rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.main-visual__sub {
  font-size: 1.6rem;
}

/* -----------------------------------------------------
  スクロールフェードイン
----------------------------------------------------- */
.fadein {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fadein.active {
  opacity: 1;
  transform: none;
}

/* -----------------------------------------------------
  共通ボタン
----------------------------------------------------- */
.btn,
.wp-block-button__link {
  display: inline-block;
  padding: 12px 32px;
  border-radius: 999px;
  background-color: var(--color-main-red);
  color: #ffffff;
  font-size: 1.5rem;
  font-weight: 700;
  text-align: center;
  letter-spacing: 0.08em;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.btn:hover,
.wp-block-button__link:hover {
  opacity: 0.87;
  transform: translateY(-1px);
}

/* -----------------------------------------------------
  セクション共通
----------------------------------------------------- */
.section {
  padding: 80px 20px;
}

.section--gray {
  background-color: #f5f5f5;
}

/* -----------------------------------------------------
  フッター
----------------------------------------------------- */
.site-footer {
  flex-shrink: 0;
  background-color: var(--color-main-red);
  color: #ffffff;
  font-size: 1.4rem;
}

/* 赤い大きなフッターエリア */
.site-footer__inner {
  position: relative;
  width: 100%;
  padding: 56px 8vw 48px 12vw; /* 左から少し空ける */
}

/* 画面幅の45%のところに縦線を固定配置 */
.site-footer__inner::after {
  content: "";
  position: absolute;
  top: 40px;
  bottom: 40px;
  left: 45%;
  width: 2px;
  background-color: #ffffff;
}

/* メインラッパー（左ブロックだけ通常フロー） */
.footer-main {
  /* 特にレイアウトは持たせず、左ブロックだけ配置 */
}

/* 左ブロック ------------------------------------------------ */
.footer-main__left {
  max-width: 520px;
}

.footer-company__name {
  margin: 0 0 16px;
  font-size: 2.6rem;
  font-weight: 700;
}

.footer-company__address {
  margin: 0 0 40px;
  font-size: 1.6rem;
  line-height: 1.8;
}

/* 電話部分 */
.footer-phone {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 32px;
}

.footer-phone__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
}

.footer-phone__icon img {
  width: 100%;
  height: auto;
  display: block;
}

.footer-phone__number {
  font-size: 4.4rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #ffffff;
}

/* SNSアイコン（電話の下に配置） */
.footer-sns {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 8px;
}

.footer-sns__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.footer-sns__icon img {
  width: 64px;
  height: 64px;
  display: block;
}

/* 右ブロック：縦メニュー ------------------------------------ */
/* 縦線より右側に、絶対配置で中央寄せ */
.footer-main__nav {
  position: absolute;
  top: 50%;
  left: calc(45% + 32px);  /* 縦線から32px右 */
  transform: translateY(-50%);
}

.footer-nav__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-nav__list li {
  margin-bottom: 18px;
}

.footer-nav__list a {
  color: #ffffff;
  font-size: 1.6rem;
  font-weight: 500;
  text-decoration: none;
  transition: opacity 0.25s ease;
}

.footer-nav__list a:hover {
  opacity: 0.8;
}

/* コピーライト（黒帯） -------------------------------------- */
.site-footer__copy {
  border-top: 1px solid rgba(0, 0, 0, 0.15);
  background-color: #000000;
  color: rgba(255, 255, 255, 0.7);
  text-align: center;
  padding: 8px 12px 10px;
  font-size: 1.2rem;
}

/* -----------------------------------------------------
  レスポンシブ
----------------------------------------------------- */
@media (max-width: 1024px) {

  .site-header__upper {
    padding-left: 32px;
    padding-right: 32px;
  }

  .site-header__lower {
    padding-left: 32px;
    padding-right: 32px;
  }

  .global-nav__list {
    gap: 16px;
  }

  .section {
    padding: 60px 16px;
  }
}

@media (max-width: 768px) {

  /* SPでは上段を非表示、ナビもドロワー内に移動 */
  .site-header__upper {
    display: none;
  }

  .global-nav {
    display: none;
  }

  .header-hamburger {
    display: block;
  }

  .site-header__lower {
    padding: 8px 16px;
    justify-content: space-between;
  }

  .site-header__logo-image {
    height: 40px;
  }

  /* SPヘッダーは1段になるので余白を減らす */
  .site-main {
    /* padding-top: 70px; */
  }

  .main-visual__catch {
    font-size: 2.4rem;
  }

  .section {
    padding: 40px 12px;
  }

  /* --- フッターSP --- */
  .site-footer__inner {
    padding: 32px 16px 32px;
  }

  /* スマホでは縦線を消す */
  .site-footer__inner::after {
    content: none;
  }

  .footer-main__left {
    max-width: 100%;
  }

  .footer-company__name {
    font-size: 2.2rem;
    margin-bottom: 8px;
  }

  .footer-company__address {
    font-size: 1.4rem;
    margin-bottom: 24px;
  }

  /* 電話：左寄せ＆少し小さめ */
  .footer-phone {
    justify-content: flex-start;
    margin-bottom: 28px;
  }

  .footer-phone__icon {
    width: 50px;
    height: 50px;
  }

  .footer-phone__number {
    font-size: 3.2rem;
    letter-spacing: 0.06em;
  }

  /* SNS：右上に大きめで配置 */
  .footer-sns {
    position: absolute;
    top: 10px;
    right: 10px;
    margin-top: 0;
  }

  .footer-sns__icon img {
    width: 50px;
    height: 50px;
  }

  /* スマホではメニュー非表示 */
  .footer-main__nav {
    display: none;
  }
}

/* -----------------------------------------------------
  フロントページ：メインビジュアル（レイヤー構造）
----------------------------------------------------- */
.front-hero {
  position: relative;
  width: 100%;
  height: 100vh;         /* 画面いっぱい */
  background: #e60012;
  overflow: hidden;
}

/* ①全面の赤背景 */
.front-hero__bg {
  position: absolute;
  inset: 0;
  background-color: var(--color-main-red);
  z-index: 1;
}

/* ② 右 80% に動画を敷くレイヤー */
.front-hero__video-wrap {
  position: absolute;
  top: 0;
  right: 0;
  width: 80%;
  height: 100%;
  overflow: hidden;
  z-index: 2;
}

.front-hero__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ③ テキスト（最上位）。左 10% の位置に固定 */
.front-hero__text {
  position: absolute;
  top: 80%;
  left: 10%;               /* 指定どおり左10% */
  transform: translateY(-50%);
  z-index: 3;
  color: #ffffff;
  max-width: 80%;          /* テキスト幅は任意。調整可能 */
}

.front-hero__en {
  font-size: 4rem;
  letter-spacing: 0.12em;
  margin: 0 0 10px;
}

.front-hero__copy {
  font-size: 5rem;
  font-weight: 700;
  line-height: 1.6;
  margin: 0 0 16px;
}

.front-hero__sub {
  font-size: 1.4rem;
  opacity: 0.9;
}

/* PC では SP版を非表示 */
.front-hero__copy--sp {
  display: none;
}

/* -----------------------------------------------------
  スマホ表示（SP）では縦積み
----------------------------------------------------- */
@media (max-width: 768px) {

  .front-hero {
    height: 100vh;          /* 画面高ぴったり */
    overflow: hidden;
  }

  /* 下だけ赤にする（下 35vh が赤帯） */
  .front-hero__bg {
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 35vh;           /* 赤帯の高さ。30〜40vhで調整OK */
    background-color: var(--color-main-red);
    z-index: 1;
  }

  /* 動画は上 65vh に表示 */
  .front-hero__video-wrap {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 75vh;           /* 上部の動画エリア */
    overflow: hidden;
    z-index: 2;
  }

  .front-hero__video {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  /* テキストは赤帯の中に収める */
  .front-hero__text {
    position: absolute;
    left: 8%;
    right: 8%;
    top: 73%;
    transform: none;
    max-width: none;
    z-index: 3;
    color: #ffffff;
  }

  .front-hero__en {
    font-size: 5.5vw;
    margin-bottom: 8px;
  }

  .front-hero__copy {
    font-size: 5vw;
    line-height: 1.6;
    margin-bottom: 8px;
  }

  .front-hero__sub {
    font-size: 1.3rem;
  }

  .front-hero__copy--pc {
    display: none;
  }

  .front-hero__copy--sp {
    display: block;
  }
}
/* -----------------------------------------------------
  修正履歴：不要になった余白設定をコメントアウト