/* ========================================================
   テーマ用 カスタム追加CSS（PHPインラインから分離）
   ======================================================== */

/* ====== グローバルフッター ====== */
.site-footer {
    background-color: #111; /* 漆黒 */
    color: #ccc;
    font-size: 14px;
    padding-top: 50px;
    position: relative; /* スタッキングコンテキストを確立する */
    z-index: 10; /* LPの#aiオーバーレイ（z-index:6）より上に表示 */
}
.site-footer__inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px 40px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 40px;
}
/* 左ブロック: ブランド情報 */
.site-footer__brand {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
/* ロゴ&住所ラッパー: PCは縦積み、SPは横並び */
.site-footer__brand-row {
    display: flex;
    flex-direction: column; /* PC: ロゴ上→住所下 */
    gap: 10px;
}
.site-footer__logo-text {
    color: #aaa;
    font-size: 12px;
    margin: 0;
}
.site-footer__logo {
    filter: brightness(0) invert(1); /* ロゴを白色反転させる */
    width: 160px;
    height: auto;
}
.site-footer__address {
    font-style: normal;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.site-footer__tel {
    color: #fff;
    font-size: 22px;
    font-weight: bold;
    text-decoration: none;
    letter-spacing: 0.05em;
}
/* LPのグローバルCSS(a:link,a:visited)を上書きして白色を強制 */
.site-footer__tel:link,
.site-footer__tel:visited {
    color: #fff;
}
.site-footer__tel:hover,
.site-footer__tel:link:hover,
.site-footer__tel:visited:hover {
    color: #E9C405;
}
.site-footer__hours {
    color: #aaa;
    font-size: 12px;
}
/* 右ブロック: ナビ コンテナ（PC: 2列横並び） */
.site-footer__nav {
    display: flex;
    flex-direction: row; /* PC: 左列・右列を横に並べる */
    gap: 40px;
    align-items: flex-start;
}
.site-footer__nav-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.site-footer__nav-list a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.2s;
}
.site-footer__nav-list a::before {
    content: '— '; /* ダッシュ区切り */
    color: #E9C405;
}
.site-footer__nav-list a:hover {
    color: #E9C405;
}
/* コピーライト（PC: ブランドブロック内、左寄せ） */
.site-footer__copyright-text {
    color: #555;
    font-size: 12px;
    margin: 12px 0 0 0;
    text-align: left;
}
/* 旧ボトムメニューの名残スペーサー（PC: 高さ80px相当 / 現在は上部固定メニュー） */
.site-footer__spacer {
    height: 90px;
}

/* レスポンシブ: SPで縦並び */
@media screen and (max-width: 768px) {
    .site-footer__inner {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    /* SP: メニューを上・ブランド情報を下に入れ替え */
    .site-footer__nav   { order: 1; }
    .site-footer__brand { order: 2; }
    /* ブランドブロック: 完全中央揃え */
    .site-footer__brand {
        align-items: center;
        text-align: center;
        width: 100%;
    }
    /* SP時: ロゴ（左）と住所（右）を横並び */
    .site-footer__brand-row {
        flex-direction: row;
        align-items: center;
        gap: 16px;
    }
    .site-footer__logo {
        width: 100px; /* SP時は小さめに */
    }
    .site-footer__address {
        text-align: left; /* 住所は左寄せ */
    }
    .site-footer__copyright-text {
        text-align: center; /* SP時は中央 */
    }
    .site-footer__nav-list {
        /* SP時: 左寄せ（中央から左に変更） */
        align-items: flex-start;
    }
    /* SP: 旧ボトムメニューの名残スペーサー（メニュー上部移動により重なり防止としては不要ですが念のため残置） */
    .site-footer__spacer {
        height: 80px;
    }
}

/* サブページ用: ヘッダーをグラデーションに変更し、absoluteを解除する */
.site-header--solid-yellow {
    position: relative !important;
    display: flex; /* 全体を横並び＆上下中央揃えの基礎にする */
    align-items: center; /* 上下方向の中央揃えを実現 */
    justify-content: space-between; /* 左右の端に寄せる */
    background: radial-gradient(circle at 40% 120%, #E9C405 0%, #D8B10A 40%, #CEA50C 70%, #C3990F 100%);
    padding-bottom: 20px;
    z-index: 100;
}
/* ヘッダーのロゴや連絡先もFlexboxに合わせて調整（既存デザイン崩れ防止） */
.site-header--solid-yellow .site-header__logo-wrap {
    flex-shrink: 0;
}
.site-header--solid-yellow .site-header__contact {
    flex-shrink: 0;
}
.site-header--solid-yellow .site-header__contact a {
    text-decoration: none;
}
/* 空きスペースの中央レイアウト（真の中央への絶対配置） */
.site-header__page-title {
    position: absolute; /* Flexboxの並びから切り離す */
    left: 50%; /* 親要素（ヘッダー全体）の左端からきっちり50%の位置 */
    top: 50%; /* 親要素の上端からきっちり50%の位置 */
    transform: translate(-50%, -50%); /* 自身の幅と高さの半分だけ戻して、完全な「十字の中心」を合わせる */
    margin: 0;
    padding: 0 0 5px 0; /* 下線との隙間を作る（上・右・下・左） */
    width: auto;
    text-align: center;
    font-size: 28px;
    font-weight: bold;
    color: #fff;
    text-shadow: 1px 1px 5px rgba(0, 0, 0, 0.4);
    white-space: nowrap;
}
/* ページタイトルの下線装飾 */
.site-header__page-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: #E9C405; /* ヘッダーのアクセントカラー（黄色系） */
    border-radius: 2px;
}
/* コンテンツ側スマホタイトル（デフォルト非表示） */
.subpage-title--mobile-only {
    display: none;
}
/* サブページのメインコンテンツ領域 */
.subpage-main {
    padding: 60px 30px;
    max-width: 1000px;
    margin: 0 auto;
    min-height: 50vh;
}
/* ====== サブページ コンテンツ タイポグラフィ（LPに合わせてゆとりを持たせた設定） ====== */
/* 通常テキスト（段落） */
.subpage-main p {
    font-size: 1.8rem;        /* LP本文より少し大きめ */
    line-height: 2.2;         /* 行間: ゆったり */
    letter-spacing: 0.08em;   /* 文字間隔: 少し広め */
    margin-bottom: 2.4em;     /* 段落間の余白: たっぷり */
}
/* 見出し h2 */
.subpage-main h2 {
    font-size: 2.8rem;
    font-weight: bold;
    line-height: 1.5;
    letter-spacing: 0.06em;
    margin-top: 3em;
    margin-bottom: 1em;
    padding-left: 0.6em;
    border-left: 5px solid #E9C405; /* アクセントカラー */
}
/* 見出し h3 */
.subpage-main h3 {
    font-size: 2.2rem;
    font-weight: bold;
    line-height: 1.5;
    letter-spacing: 0.05em;
    margin-top: 2.4em;
    margin-bottom: 0.8em;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 0.3em;
}
/* リスト */
.subpage-main ul,
.subpage-main ol {
    font-size: 1.8rem;
    line-height: 2.0;
    letter-spacing: 0.06em;
    margin-bottom: 2em;
    padding-left: 2em;
}
.subpage-main li {
    margin-bottom: 0.6em;
}
/* テーブル */
.subpage-main table {
    width: 100%;
    border-collapse: collapse;
    font-size: 1.8rem;
    letter-spacing: 0.06em;
    line-height: 2.0;
    margin-bottom: 2.4em;
}
.subpage-main th,
.subpage-main td {
    border: 1px solid #ddd;
    padding: 0.8em 1em;
    text-align: left;
}
.subpage-main th {
    background-color: #f5f5f5;
    font-weight: bold;
}
/* ====== 投稿ページ（.post-content）にも同じタイポグラフィを適用 ====== */
/* p / ul / ol */
.post-content p,
.post-content ul,
.post-content ol {
    font-size: 1.8rem;
    line-height: 2.2;
    letter-spacing: 0.08em;
    margin-bottom: 2.4em;
}
.post-content ul,
.post-content ol { padding-left: 2em; }
.post-content li { margin-bottom: 0.6em; }
/* 見出し */
.post-content h2 {
    font-size: 2.8rem;
    font-weight: bold;
    line-height: 1.5;
    letter-spacing: 0.06em;
    margin-top: 3em;
    margin-bottom: 1em;
    padding-left: 0.6em;
    border-left: 5px solid #E9C405;
}
.post-content h3 {
    font-size: 2.2rem;
    font-weight: bold;
    line-height: 1.5;
    letter-spacing: 0.05em;
    margin-top: 2.4em;
    margin-bottom: 0.8em;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 0.3em;
}
/* テーブル */
.post-content table {
    width: 100%;
    border-collapse: collapse;
    font-size: 1.8rem;
    letter-spacing: 0.06em;
    line-height: 2.0;
    margin-bottom: 2.4em;
}
.post-content th,
.post-content td {
    border: 1px solid #ddd;
    padding: 0.8em 1em;
    text-align: left;
}
.post-content th {
    background-color: #f5f5f5;
    font-weight: bold;
}
/* レスポンシブ切り替え（100px早く、横幅1124px以下に縮んだ段階でタイトル位置をフリップする） */
@media screen and (max-width: 1124px) {
    .site-header__page-title {
        display: none !important;
    }
    .subpage-title--mobile-only {
        display: block !important;
        text-align: center;
        font-size: 24px;
        font-weight: bold;
        margin-top: 10px;
        margin-bottom: 30px;
        color: #333;
        border-bottom: 2px solid #ffc600;
        padding-bottom: 10px;
    }
}

/* --------------------------------------------------------
   安心な理由エリア（直後に新セクションが入ったための余白調整）
   -------------------------------------------------------- */
.reason {
    padding-bottom: 20px !important;
}

/* --------------------------------------------------------
   他社より安く定額で提供できる理由エリア
   -------------------------------------------------------- */
.cheap-reason {
    overflow: hidden; /* 横スクロールによる「画面右端の白浮き」を根本から防止 */
    padding: 80px 0 140px; /* 下部余白を微増（+20px） */
    background-color: #fff;
    scroll-margin-top: 64px; /* 固定ヘッダーのアンカーリンク対策 */
}
.cheap-reason .main-title {
    margin-bottom: 60px;
}
.cheap-reason__list {
    display: flex;
    flex-direction: column;
    gap: 40px;
    max-width: 900px;
    margin: 0 auto;
}
.cheap-reason__item {
    position: relative;
    z-index: 1;
    overflow: hidden;
    background: #f8f8f8;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}
.cheap-reason__head {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
}
.cheap-reason__num {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    background-color: #ffc600;
    color: #000;
    font-size: 30px;
    font-weight: 900;
    border-radius: 50%;
    box-shadow: 2px 2px 0px #e6b200;
}
.cheap-reason__title {
    font-size: 24px;
    font-weight: bold;
    color: #333;
    line-height: 1.4;
    margin: 0;
}
.cheap-reason__text {
    font-size: 16px;
    line-height: 1.8;
    color: #555;
    margin: 0;
}
.cheap-reason__icon {
    position: absolute;
    right: -20px;
    bottom: -30px;
    font-size: 180px;
    color: rgba(255, 198, 0, 0.15); /* うっすらとした黄色透かし */
    z-index: -1;
    transform: rotate(-10deg);
    pointer-events: none;
}

@media screen and (min-width: 768px) {
    .reason {
        padding-bottom: 30px !important; /* 新セクションとの重なりを防ぐため限界まで縮小 */
    }
    .cheap-reason {
        padding-bottom: 280px; /* 次のセクションの斜めカット（上に170px被さる）を避けつつ微調整（+40px） */
    }
    .cheap-reason .main-title {
        margin-bottom: 90px; /* 余白を適正値に縮小 */
    }
    .cheap-reason .main-title__en {
        width: 100%;
        left: 0;
        text-align: center;
        line-height: 0.8;
        top: -0.4em; /* 位置微調整 */
    }
}

@media screen and (max-width: 767px) {
    .cheap-reason {
        padding: 60px 0 120px; /* 微増（+20px） */
    }
    .cheap-reason__item {
        padding: 25px 20px;
    }
    .cheap-reason__head {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    .cheap-reason__num {
        width: 50px;
        height: 50px;
        font-size: 24px;
    }
    .cheap-reason__title {
        font-size: 20px;
    }
    .cheap-reason__text {
        font-size: 15px;
    }
    .cheap-reason__icon {
        font-size: 120px;
        right: -10px;
        bottom: -20px;
    }
}

/* --------------------------------------------------------
   AI見積モーダルの重なり順調整（ヘッダー被り対策）
   -------------------------------------------------------- */
/* サブページのヘッダー(z-index: 100)や固定メニュー(99999)よりも手前に表示するよう強制 */
#ai {
    z-index: 999999 !important;
}

/* --------------------------------------------------------
   スクロール追従型のAI見積ボタン (Floating Action Button)
   -------------------------------------------------------- */
.floating-ai-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9998; /* モーダル(#ai:999999)やトップメニュー(9999)より下 */
    
    /* ----- 右上ボタン（.site-header__btn）と同じスタイル ----- */
    background-image: -webkit-gradient(linear,left bottom,left top,from(#158d3d),to(#1dc215));
    background-image: linear-gradient(to top,#158d3d,#1dc215);
    color: #fff;
    text-shadow: 0 0 5px rgba(0,0,0,.88);
    border-radius: 5px;
    border: solid 2px #2e590e;
    font-weight: 700;
    font-size: 1.1rem;
    padding: .2em .5em;
    font-family: "FOT-UD角ゴC80 Pro B", UDKakugoC80Pro-B, sans-serif;
    cursor: pointer;
    
    /* 初期状態は非表示（透明＋クリック不可＋少し下にずらす） */
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: opacity 0.4s ease, visibility 0.4s ease, transform 0.4s ease, box-shadow 0.3s ease;
}

.floating-ai-btn span {
    font-size: 120%;
}

/* クラス付与で表示 */
.floating-ai-btn.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* ホバーエフェクト（右上ボタンと同じ動き） */
.floating-ai-btn.is-visible:hover {
    transform: translateY(-3px);
    box-shadow: 3px 3px 10px rgba(0,0,0,.2);
}

/* レスポンシブ対応 (.site-header__btn準拠) */
@media screen and (min-width: 768px) {
    .floating-ai-btn {
        border-radius: 10px;
        font-size: 2.4rem;
        bottom: 30px;
        right: 30px;
    }
}

@media screen and (max-width: 767px) {
    .floating-ai-btn {
        bottom: 15px;
        right: 15px;
        font-size: 1.45rem; /* 拡大 */
        padding: 10px 18px; /* 拡大 */
        line-height: 1.25;
    }
}
/* --------------------------------------------------------
   スクロール追従型の電話ボタン (左側配置)
   -------------------------------------------------------- */
.floating-tel-btn {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 9998;
    background-color: rgba(233, 196, 5, 0.2); /* 薄い黄色 */
    border: 2px solid rgba(233, 196, 5, 0.5);
    border-radius: 5px;
    padding: 10px 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    text-decoration: none;
    transition: opacity 0.4s ease, visibility 0.4s ease, transform 0.4s ease, box-shadow 0.3s ease;
    
    /* 初期状態は非表示 */
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
}

.floating-tel-btn.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.floating-tel-btn__img {
    height: 38px;
    width: auto;
    display: block;
}

.floating-tel-btn__icon {
    display: none;
    color: #158d3d; /* 緑色のアイコン */
}

.floating-tel-btn__number {
    display: none;
}

/* レスポンシブ */
@media screen and (min-width: 768px) {
    .floating-tel-btn {
        bottom: 30px;
        left: 30px;
        border-radius: 10px;
        background-color: rgba(255, 255, 255, 0.9); /* PCはより視認性の高い白寄りの薄黄色 */
        border: 2px solid #E9C405;
        padding: 5px 20px;
    }
    .floating-tel-btn:hover {
        transform: translateY(-3px);
        box-shadow: 0 6px 20px rgba(0,0,0,0.2);
    }
}

@media screen and (max-width: 767px) {
    .floating-tel-btn {
        bottom: 15px;
        left: 15px;
        padding: 0;
        width: 65px;
        height: 65px;
        border-radius: 50%;
        background-color: #d9333f; /* 黄色から赤系に変更 */
        border: 2px solid #fff;
    }
    .floating-tel-btn__img {
        display: none; /* スマホ時は画像ではなくアイコン */
    }
    .floating-tel-btn__icon {
        display: block;
        color: #fff; /* 赤背景に合わせてアイコンを白に変更（視認性向上） */
        font-size: 3.2rem;
    }
}

/* --------------------------------------------------------
   最新のお知らせセクション（グレー背景案：脱・赤色）
   -------------------------------------------------------- */
.news {
    padding-top: 100px;
    padding-bottom: 80px;
}
.news .main-title__jp {
    color: #000; /* 通常の黒タイトル */
}
.news .main-title__en {
    color: #ebeaea; /* 通常の薄いグレーEN */
}
.news-list {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    margin-top: 40px;
}
.news-item {
    width: calc((100% - 60px) / 3);
    background: #fff; /* カードは白 */
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}
.news-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}
.news-item__img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    background-color: #eee;
    display: block;
}
.news-item__content {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}
.news-item__meta {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    font-size: 1.2rem;
    color: #888;
}
.news-item__cat {
    background: #ffc600;
    color: #000;
    padding: 2px 10px;
    border-radius: 4px;
    font-weight: bold;
}
.news-item__title {
    font-size: 1.8rem;
    font-weight: bold;
    line-height: 1.4;
    margin-bottom: 15px;
    color: #333;
}
.news-item__title a {
    color: inherit;
    text-decoration: none;
}
.news-item__excerpt {
    font-size: 1.4rem;
    line-height: 1.7;
    color: #555;
    margin-bottom: 20px;
    flex-grow: 1;
}
.news-item__link {
    display: inline-block;
    color: #000;
    background-color: #ffc600;
    padding: 12px 28px;
    border-radius: 25px;
    font-weight: bold;
    font-size: 1.5rem;
    text-decoration: none;
    text-align: center;
    transition: background-color 0.3s, transform 0.2s, color 0.3s;
}
.news-item__link:hover {
    background-color: #000;
    color: #ffc600;
    transform: scale(1.05);
}

@media screen and (max-width: 1024px) {
    .news-item {
        width: calc((100% - 30px) / 2);
    }
}
@media screen and (max-width: 767px) {
    .news {
        padding-top: 80px;
        padding-bottom: 60px;
    }
    .news-item {
        width: 100%;
    }
    .news-item__title {
        font-size: 1.7rem;
    }
}

/* 「すべてのコラムを見る」ボタンのリッチなデザイン */
.news-archive-link {
    text-align: left;
    margin-top: 60px; /* 記事との間隔を確保 */
}

.news-archive-btn {
    display: inline-block;
    position: relative;
    background: linear-gradient(135deg, #ffc600 0%, #ffbb00 100%);
    color: #000;
    padding: 18px 80px 18px 40px;
    border-radius: 50px;
    font-weight: 800;
    font-size: 1.8rem;
    text-decoration: none;
    box-shadow: 0 6px 20px rgba(255, 198, 0, 0.3);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: none;
    line-height: 1;
}

/* 矢印（擬似要素）の作成 */
.news-archive-btn::after {
    content: "";
    position: absolute;
    right: 30px;
    top: 50%;
    width: 25px;
    height: 2px;
    background-color: #000;
    transform: translateY(-50%);
    transition: all 0.3s ease;
}

.news-archive-btn::before {
    content: "";
    position: absolute;
    right: 30px;
    top: 50%;
    width: 10px;
    height: 10px;
    border-top: 2px solid #000;
    border-right: 2px solid #000;
    transform: translateY(-50%) rotate(45deg);
    transition: all 0.3s ease;
}

/* ホバーエフェクト */
.news-archive-btn:hover {
    background: #000;
    color: #ffc600;
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
}

.news-archive-btn:hover::after {
    background-color: #ffc600;
    transform: translateY(-50%) translateX(10px);
}

.news-archive-btn:hover::before {
    border-color: #ffc600;
    transform: translateY(-50%) translateX(10px) rotate(45deg);
}

@media screen and (max-width: 767px) {
    .news-archive-link {
        text-align: center;
        margin-top: 40px;
    }
    .news-archive-btn {
        width: 100%;
        max-width: 320px;
        font-size: 1.6rem;
        padding: 16px 60px 16px 30px;
    }
    .news-archive-btn::after,
    .news-archive-btn::before {
        right: 25px;
    }
}

